fix plot build to use CC from Makefiles; fix fallout in Mac build

to clean up the hack of putting -m32 in CC instead of CFLAGS
This commit is contained in:
Matthew Flatt 2010-11-10 07:19:28 -07:00
parent 69b858a7f5
commit 11f45cd2fd
5 changed files with 18 additions and 29 deletions

17
src/configure vendored
View File

@ -5321,19 +5321,16 @@ case $OS in
fi fi
fi fi
# Force 32-bit build, for now # Force 32-bit build unless mac64 is enabled:
if test "${enable_mac64}" != "yes" ; then if test "${enable_mac64}" != "yes" ; then
if test `${UNAME} -m` = "i386" ; then if test `${UNAME} -m` = "i386" ; then
if test "${ORIG_CC}" = "" ; then if test "${ORIG_CC}" = "" ; then
CC="${CC} -m32" PREFLAGS="${PREFLAGS} -m32"
SUB_CONFIGURE_EXTRAS="${SUB_CONFIGURE_EXTRAS} CC="'"'"${CC}"'"' CPPFLAGS="${CPPFLAGS} -m32"
fi LDFLAGS="${LDFLAGS} -m32"
if test "${ORIG_CPP}" = "" ; then # To make the libffi build work, we have to fold -m32 into CC
CPP="${CPP} -m32" # instead of CFLAGS:
SUB_CONFIGURE_EXTRAS="${SUB_CONFIGURE_EXTRAS} CPP="'"'"${CPP}"'"' SUB_CONFIGURE_EXTRAS="${SUB_CONFIGURE_EXTRAS} CC="'"'"${CC}"' -m32"'
fi
if test "${ORIG_CC_FOR_BUILD}" = "" ; then
CC_FOR_BUILD="${CC_FOR_BUILD} -m32"
fi fi
fi fi
fi fi

View File

@ -69,7 +69,7 @@ wx_mac_EXTRAFLAGS =
EXTRAFLAGS = $(@WXVARIANT@_EXTRAFLAGS) EXTRAFLAGS = $(@WXVARIANT@_EXTRAFLAGS)
grmain.@LTO@: xsrc/grmain.c grmain.@LTO@: xsrc/grmain.c
$(CC) $(EXTRAFLAGS) -DGC2_JUST_MACROS $(GCPREINC) -c $(POSTFLAGS) -o grmain.@LTO@ xsrc/grmain.c $(CC) $(CFLAGS) $(EXTRAFLAGS) -DGC2_JUST_MACROS $(GCPREINC) -c $(POSTFLAGS) -o grmain.@LTO@ xsrc/grmain.c
XSRCS = xsrc/grmain.c XSRCS = xsrc/grmain.c

View File

@ -12,12 +12,7 @@ ICP=@ICP@
CC = @CC@ CC = @CC@
# Setting the compiler and linker when using dynext WITH_ENV = env CC="@PLAIN_CC@" CFLAGS="@CFLAGS@ @COMPFLAGS@ @PREFLAGS@" LDFLAGS="@LDFLAGS@"
# seems like a good idea, but it doesn't work with
# libtool as the compiler. So, we trust the configuration
# that is built into dynext, instead.
# WITH-ENV = env CC="$(CC)" LD="@MZLINKER@" ...
WITH_ENV = env CFLAGS="@CFLAGS@ @COMPFLAGS@ @PREFLAGS@" LDFLAGS="@LDFLAGS@"
PLPLOT_SRCS = $(srcdir)/plplot/dc_drv.c \ PLPLOT_SRCS = $(srcdir)/plplot/dc_drv.c \
$(srcdir)/plplot/plcont.c \ $(srcdir)/plplot/plcont.c \

View File

@ -16,7 +16,7 @@
# GC2OPTIONS - GC2-only flags # GC2OPTIONS - GC2-only flags
# #
# Note: we use CPPFLAGS for configure-time testing only because # Note: we use CPPFLAGS for configure-time testing only because
# it needs to include C++ flags that we don't want for Racket. # it used to include C++ flags that we didn't want for Racket.
# hence PREFLAGS, which is initialized to the original CPPFLAGS. # hence PREFLAGS, which is initialized to the original CPPFLAGS.
AC_INIT([Racket]) AC_INIT([Racket])
@ -651,19 +651,16 @@ case $OS in
fi fi
fi fi
# Force 32-bit build, for now # Force 32-bit build unless mac64 is enabled:
if test "${enable_mac64}" != "yes" ; then if test "${enable_mac64}" != "yes" ; then
if test `${UNAME} -m` = "i386" ; then if test `${UNAME} -m` = "i386" ; then
if test "${ORIG_CC}" = "" ; then if test "${ORIG_CC}" = "" ; then
CC="${CC} -m32" PREFLAGS="${PREFLAGS} -m32"
SUB_CONFIGURE_EXTRAS="${SUB_CONFIGURE_EXTRAS} CC="'"'"${CC}"'"' CPPFLAGS="${CPPFLAGS} -m32"
fi LDFLAGS="${LDFLAGS} -m32"
if test "${ORIG_CPP}" = "" ; then # To make the libffi build work, we have to fold -m32 into CC
CPP="${CPP} -m32" # instead of CFLAGS:
SUB_CONFIGURE_EXTRAS="${SUB_CONFIGURE_EXTRAS} CPP="'"'"${CPP}"'"' SUB_CONFIGURE_EXTRAS="${SUB_CONFIGURE_EXTRAS} CC="'"'"${CC}"' -m32"'
fi
if test "${ORIG_CC_FOR_BUILD}" = "" ; then
CC_FOR_BUILD="${CC_FOR_BUILD} -m32"
fi fi
fi fi
fi fi

View File

@ -434,7 +434,7 @@ CURSES= -lcurses -ltermlib
# the SHELL environment variable. # the SHELL environment variable.
SHELL= /bin/sh SHELL= /bin/sh
SPECIALCFLAGS = -I$(srcdir)/include -I$(AO_INSTALL_DIR)/include SPECIALCFLAGS = -I$(srcdir)/include -I$(AO_INSTALL_DIR)/include @CFLAGS@ @COMPFLAGS@ @PREFLAGS@
# Alternative flags to the C compiler for mach_dep.c. # Alternative flags to the C compiler for mach_dep.c.
# Mach_dep.c often doesn't like optimization, and it's # Mach_dep.c often doesn't like optimization, and it's
# not time-critical anyway. # not time-critical anyway.