build: Fix missing variable quotes

When dlopen and pthread_create are in libc the variable is
set to "none required", therefore running configure will show
the following errors:

./configure: line 8997: test: too many arguments
./configure: line 8999: test: too many arguments
./configure: line 9003: test: too many arguments
./configure: line 9005: test: =: unary operator expected

gcc/configure also has a similar problem on
gcc_cv_as_mips_explicit_relocs:

./gcc/configure: line 30242: test: =: unary operator expected

ChangeLog:

	* configure.ac: Quote variable result of AC_SEARCH_LIBS.
	* configure: Regenerate.

gcc/ChangeLog:

	* configure.ac: Add missing quotation of variable
	gcc_cv_as_mips_explicit_relocs.
	* configure: Regenerate.

Signed-off-by: Collin Funk <collin.funk1@gmail.com>
This commit is contained in:
Collin Funk 2024-06-13 17:53:55 -07:00 committed by YunQiang Su
parent a73744a4f8
commit c6a9ab8c92
4 changed files with 11 additions and 11 deletions

10
configure vendored
View File

@ -8994,15 +8994,15 @@ if test "$ac_res" != no; then :
fi
if test $ac_cv_search_dlopen = -ldl; then
if test "$ac_cv_search_dlopen" = -ldl; then
CRAB1_LIBS="$CRAB1_LIBS -ldl"
elif test $ac_cv_search_dlopen = no; then
elif test "$ac_cv_search_dlopen" = no; then
missing_rust_dynlibs="libdl"
fi
if test $ac_cv_search_pthread_create = -lpthread; then
if test "$ac_cv_search_pthread_create" = -lpthread; then
CRAB1_LIBS="$CRAB1_LIBS -lpthread"
elif test $ac_cv_search_pthread_crate = no; then
elif test "$ac_cv_search_pthread_crate" = no; then
missing_rust_dynlibs="$missing_rust_dynlibs, libpthread"
fi
@ -19746,7 +19746,7 @@ config.status
configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\"
Copyright (C) 2012 Free Software Foundation, Inc.
Copyright (C) Free Software Foundation, Inc.
This config.status script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it."

View File

@ -2045,15 +2045,15 @@ missing_rust_dynlibs=none
AC_SEARCH_LIBS([dlopen], [dl])
AC_SEARCH_LIBS([pthread_create], [pthread])
if test $ac_cv_search_dlopen = -ldl; then
if test "$ac_cv_search_dlopen" = -ldl; then
CRAB1_LIBS="$CRAB1_LIBS -ldl"
elif test $ac_cv_search_dlopen = no; then
elif test "$ac_cv_search_dlopen" = no; then
missing_rust_dynlibs="libdl"
fi
if test $ac_cv_search_pthread_create = -lpthread; then
if test "$ac_cv_search_pthread_create" = -lpthread; then
CRAB1_LIBS="$CRAB1_LIBS -lpthread"
elif test $ac_cv_search_pthread_crate = no; then
elif test "$ac_cv_search_pthread_crate" = no; then
missing_rust_dynlibs="$missing_rust_dynlibs, libpthread"
fi

2
gcc/configure vendored
View File

@ -30239,7 +30239,7 @@ else
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_mips_explicit_relocs_pcrel" >&5
$as_echo "$gcc_cv_as_mips_explicit_relocs_pcrel" >&6; }
if test $gcc_cv_as_mips_explicit_relocs_pcrel = yes; then
if test "x$gcc_cv_as_mips_explicit_relocs_pcrel" = "xyes"; then
$as_echo "#define MIPS_EXPLICIT_RELOCS MIPS_EXPLICIT_RELOCS_PCREL" >>confdefs.h

View File

@ -5317,7 +5317,7 @@ x:
AC_MSG_CHECKING(assembler and linker for explicit JALR relocation)
gcc_cv_as_ld_jalr_reloc=no
if test $gcc_cv_as_mips_explicit_relocs = yes; then
if test "x$gcc_cv_as_mips_explicit_relocs" = "xyes"; then
if test $in_tree_ld = yes ; then
if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 20 -o "$gcc_cv_gld_major_version" -gt 2 \
&& test $in_tree_ld_is_elf = yes; then