Patch "Run `autoreconf -vf` throughout" broke the rtems-bfin build on FreeBSD

Sebastian Huber
2020-08-20T06:22:19Z

Hello,

this commit

commit f693213d126a823f7c81e61f3ef05b501b862bce
Author: Simon Marchi <simon.marchi@efficios.com>
Date:   Wed Jul 29 16:02:57 2020 -0400

Run `autoreconf -vf` throughout

includes this change in "sim/bfin/configure":

-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
-$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
-
+PKG_PROG_PKG_CONFIG
+PKG_CHECK_MODULES(SDL, sdl,
+       AC_CHECK_LIB(dl, dlopen, [
SDL_CFLAGS="${SDL_CFLAGS} -DHAVE_SDL"
SDL_LIBS="-ldl"
-
-else
-  SDL_CFLAGS= SDL_LIBS=
-fi
-
-
-fi
+               ], [SDL_CFLAGS= SDL_LIBS=])
+       , :)

This looks like an incomplete macro expansion. It cases a shell syntax
error on FreeBSD:

checking for /usr/bin/cc -O2 -pipe -fbracket-depth=1024
-I/usr/home/user/rtems-source-builder/rtems/build/tmp/sb-1001/6/rtems-bfin/usr/local/rtems/6/include
option to produce PIC... -fPIC -DPIC
../../../sourceware-mirror-binutils-gdb-c2fd7fa/sim/bfin/configure:
PKG_PROG_PKG_CONFIG: not found
../../../sourceware-mirror-binutils-gdb-c2fd7fa/sim/bfin/configure:
13930: Syntax error: word unexpected (expecting ")")