mirror of
https://git.postgresql.org/git/postgresql.git
synced 2025-02-05 19:09:58 +08:00
Run AC_PROG_GCC_TRADITIONAL only when running AC_PROG_CC,
ie, not when user specifies --with-CC. This corrects a scripting error that I'm surprised hasn't been reported more often. Moving the macro call to the earlier point in the script is correct anyway: if -traditional is needed, it should get added to CFLAGS before we start using the compiler for other tests.
This commit is contained in:
parent
9e38dcfd43
commit
579b72c5de
@ -335,7 +335,10 @@ AC_ARG_WITH(CC,
|
|||||||
esac
|
esac
|
||||||
CC="$withval"
|
CC="$withval"
|
||||||
],
|
],
|
||||||
[ AC_PROG_CC])
|
[
|
||||||
|
AC_PROG_CC
|
||||||
|
AC_PROG_GCC_TRADITIONAL
|
||||||
|
])
|
||||||
|
|
||||||
if test "$CC" = "gcc"
|
if test "$CC" = "gcc"
|
||||||
then
|
then
|
||||||
@ -346,11 +349,9 @@ fi
|
|||||||
AC_SUBST(CC_VERSION)
|
AC_SUBST(CC_VERSION)
|
||||||
|
|
||||||
CPPFLAGS="$CPPFLAGS $PGSQL_CPPFLAGS"
|
CPPFLAGS="$CPPFLAGS $PGSQL_CPPFLAGS"
|
||||||
export CPPFLAGS
|
|
||||||
echo "- setting CPPFLAGS=$CPPFLAGS"
|
echo "- setting CPPFLAGS=$CPPFLAGS"
|
||||||
|
|
||||||
LDFLAGS="$LDFLAGS $PGSQL_LDFLAGS"
|
LDFLAGS="$LDFLAGS $PGSQL_LDFLAGS"
|
||||||
export LDFLAGS
|
|
||||||
echo "- setting LDFLAGS=$LDFLAGS"
|
echo "- setting LDFLAGS=$LDFLAGS"
|
||||||
|
|
||||||
dnl Checks for programs.
|
dnl Checks for programs.
|
||||||
@ -668,7 +669,6 @@ main() {
|
|||||||
AC_MSG_RESULT(assuming not on target machine))
|
AC_MSG_RESULT(assuming not on target machine))
|
||||||
|
|
||||||
dnl Checks for library functions.
|
dnl Checks for library functions.
|
||||||
AC_PROG_GCC_TRADITIONAL
|
|
||||||
AC_FUNC_MEMCMP
|
AC_FUNC_MEMCMP
|
||||||
AC_TYPE_SIGNAL
|
AC_TYPE_SIGNAL
|
||||||
AC_FUNC_VPRINTF
|
AC_FUNC_VPRINTF
|
||||||
|
Loading…
Reference in New Issue
Block a user