configure: append {C{,XX,PP},LD}FLAGS after checking compilter features.
This commit is contained in:
parent
8d7c899d48
commit
e1a3e44e2a
20
configure
vendored
20
configure
vendored
@ -178,14 +178,8 @@ fi
|
|||||||
|
|
||||||
echo "CC = $CC" >>$CONFIG_MK
|
echo "CC = $CC" >>$CONFIG_MK
|
||||||
echo "CFLAGS = -O2 -pthread" >>$CONFIG_MK
|
echo "CFLAGS = -O2 -pthread" >>$CONFIG_MK
|
||||||
if [ -n "$CFLAGS" ]; then
|
|
||||||
echo "CFLAGS += $CFLAGS" >>$CONFIG_MK
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo "LDFLAGS = -L\$(TOPDIR)/lib" >>$CONFIG_MK
|
echo "LDFLAGS = -L\$(TOPDIR)/lib" >>$CONFIG_MK
|
||||||
if [ -n "$LDFLAGS" ]; then
|
|
||||||
echo "LDFLAGS += $LDFLAGS" >>$CONFIG_MK
|
|
||||||
fi
|
|
||||||
echo "CPPFLAGS = -I. -I\$(TOPDIR) -I\$(TOPDIR)/include" >>$CONFIG_MK
|
echo "CPPFLAGS = -I. -I\$(TOPDIR) -I\$(TOPDIR)/include" >>$CONFIG_MK
|
||||||
echo "CPPFLAGS += -DHAVE_CONFIG_H" >>$CONFIG_MK
|
echo "CPPFLAGS += -DHAVE_CONFIG_H" >>$CONFIG_MK
|
||||||
echo "CPPFLAGS += -DXBPS_SYSCONF_PATH=\\\"${ETCDIR}\\\"" >>$CONFIG_MK
|
echo "CPPFLAGS += -DXBPS_SYSCONF_PATH=\\\"${ETCDIR}\\\"" >>$CONFIG_MK
|
||||||
@ -212,10 +206,6 @@ linux)
|
|||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
if [ -n "$CPPFLAGS" ]; then
|
|
||||||
echo "CPPFLAGS += $CPPFLAGS" >>$CONFIG_MK
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Add CPPFLAGS/CFLAGS/LDFLAGS to CC for testing features
|
# Add CPPFLAGS/CFLAGS/LDFLAGS to CC for testing features
|
||||||
XCC="$CC $CFLAGS $CPPFLAGS $LDFLAGS"
|
XCC="$CC $CFLAGS $CPPFLAGS $LDFLAGS"
|
||||||
# Make sure to disable --as-needed for CC tests.
|
# Make sure to disable --as-needed for CC tests.
|
||||||
@ -323,6 +313,16 @@ if [ $? -ne 0 ]; then
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [ -n "$CFLAGS" ]; then
|
||||||
|
echo "CFLAGS += $CFLAGS" >>$CONFIG_MK
|
||||||
|
fi
|
||||||
|
if [ -n "$LDFLAGS" ]; then
|
||||||
|
echo "LDFLAGS += $LDFLAGS" >>$CONFIG_MK
|
||||||
|
fi
|
||||||
|
if [ -n "$CPPFLAGS" ]; then
|
||||||
|
echo "CPPFLAGS += $CPPFLAGS" >>$CONFIG_MK
|
||||||
|
fi
|
||||||
|
|
||||||
# libfetch
|
# libfetch
|
||||||
echo "CPPFLAGS += -I\$(TOPDIR)/lib/fetch" >>$CONFIG_MK
|
echo "CPPFLAGS += -I\$(TOPDIR)/lib/fetch" >>$CONFIG_MK
|
||||||
echo "LDFLAGS += -lssl" >>$CONFIG_MK
|
echo "LDFLAGS += -lssl" >>$CONFIG_MK
|
||||||
|
Loading…
Reference in New Issue
Block a user