[complement-svn] SF.net SVN: complement: [1888] trunk/complement/explore
Status: Pre-Alpha
Brought to you by:
complement
From: <com...@us...> - 2008-06-06 14:41:48
|
Revision: 1888 http://complement.svn.sourceforge.net/complement/?rev=1888&view=rev Author: complement Date: 2008-06-06 07:41:32 -0700 (Fri, 06 Jun 2008) Log Message: ----------- take into account extra CFLAGS and LDFLAGS; configurable via 'configure'; don't assume presence of STLport. Modified Paths: -------------- trunk/complement/explore/Makefiles/ChangeLog trunk/complement/explore/Makefiles/gmake/extern.mak trunk/complement/explore/Makefiles/gmake/gcc.mak trunk/complement/explore/Makefiles/gmake/top.mak trunk/complement/explore/configure Modified: trunk/complement/explore/Makefiles/ChangeLog =================================================================== --- trunk/complement/explore/Makefiles/ChangeLog 2008-06-06 12:29:52 UTC (rev 1887) +++ trunk/complement/explore/Makefiles/ChangeLog 2008-06-06 14:41:32 UTC (rev 1888) @@ -3,8 +3,13 @@ * gmake/targetdirs.mak: use $(DESTDIR) as in common practice (change root of installation, but don't change run paths); - * gmake/depend.mak: fix options for ctags/etags. + * gmake/depend.mak: fix options for ctags/etags; + * gmake/gcc.mak, gmake/top.mak, configure: take into account + extra CFLAGS and LDFLAGS; configurable via 'configure'; + + * gmake/extern.mak: don't assume presence of STLport. + 2008-02-27 Petr Ovtchenkov <pt...@is...> * gmake/lib/gcc.mak: 3.3 is normal compiler, just some Modified: trunk/complement/explore/Makefiles/gmake/extern.mak =================================================================== --- trunk/complement/explore/Makefiles/gmake/extern.mak 2008-06-06 12:29:52 UTC (rev 1887) +++ trunk/complement/explore/Makefiles/gmake/extern.mak 2008-06-06 14:41:32 UTC (rev 1888) @@ -1,6 +1,6 @@ -# Time-stamp: <07/03/08 22:41:26 ptr> +# Time-stamp: <08/06/06 17:06:16 yeti> # -# Copyright (c) 1997-1999, 2002, 2003, 2005, 2006 +# Copyright (c) 1997-1999, 2002, 2003, 2005, 2006, 2008 # Petr Ovtchenkov # # Portion Copyright (c) 1999-2001 @@ -30,9 +30,11 @@ # STLport library +ifndef STLPORT_DIR ifndef WITHOUT_STLPORT -STLPORT_DIR ?= ${HOME}/STLport.lab/STLport +WITHOUT_STLPORT = 1 endif +endif ifdef STLPORT_DIR STLPORT_LIB_DIR ?= $(STLPORT_DIR)/${TARGET_NAME}lib Modified: trunk/complement/explore/Makefiles/gmake/gcc.mak =================================================================== --- trunk/complement/explore/Makefiles/gmake/gcc.mak 2008-06-06 12:29:52 UTC (rev 1887) +++ trunk/complement/explore/Makefiles/gmake/gcc.mak 2008-06-06 14:41:32 UTC (rev 1888) @@ -1,4 +1,4 @@ -# Time-stamp: <08/02/26 13:46:36 ptr> +# Time-stamp: <08/06/06 17:38:26 yeti> # # Copyright (c) 1997-1999, 2002, 2003, 2005-2008 # Petr Ovtchenkov @@ -179,6 +179,10 @@ CXXFLAGS += ${EXTRA_CXXFLAGS} endif +ifdef EXTRA_CFLAGS +CFLAGS += ${EXTRA_CFLAGS} +endif + CDEPFLAGS = -E -M CCDEPFLAGS = -E -M Modified: trunk/complement/explore/Makefiles/gmake/top.mak =================================================================== --- trunk/complement/explore/Makefiles/gmake/top.mak 2008-06-06 12:29:52 UTC (rev 1887) +++ trunk/complement/explore/Makefiles/gmake/top.mak 2008-06-06 14:41:32 UTC (rev 1888) @@ -1,4 +1,4 @@ -# Time-stamp: <07/07/12 10:55:41 ptr> +# Time-stamp: <08/06/06 17:28:38 yeti> # # Copyright (c) 1997-1999, 2002, 2003, 2005-2007 # Petr Ovtchenkov @@ -25,6 +25,10 @@ COMPILER_NAME := gcc endif +ifndef LDFLAGS +LDFLAGS := +endif + ifndef ALL_TAGS ifndef _NO_SHARED_BUILD @@ -91,6 +95,8 @@ # os-specific local rules (or other project-specific definitions) -include specific.mak +LDFLAGS += ${EXTRA_LDFLAGS} + # derive common targets (*.o, *.d), # build rules (including output catalogs) include ${RULESBASE}/gmake/targets.mak Modified: trunk/complement/explore/configure =================================================================== --- trunk/complement/explore/configure 2008-06-06 12:29:52 UTC (rev 1887) +++ trunk/complement/explore/configure 2008-06-06 14:41:32 UTC (rev 1888) @@ -1,6 +1,6 @@ #!/bin/sh -# Time-stamp: <08/02/26 16:02:32 yeti> +# Time-stamp: <08/06/06 17:44:52 yeti> base=`cd \`dirname $0\`; echo $PWD` @@ -47,6 +47,10 @@ --with-mssdk=<dir> use MS SDK from this catalog --with-extra-cxxflags=<options> pass extra options to C++ compiler + --with-extra-cflags=<options> + pass extra options to C compiler + --with-extra-ldflags=<options> + pass extra options to linker (via C/C++) --use-static-gcc use static gcc libs instead of shared libgcc_s (useful for gcc compiler, that was builded with --enable-shared [default]; if compiler was builded with --disable-shared, static libraries will be used in any case) @@ -69,6 +73,8 @@ \$CXX C++ compiler name (use --target= for cross-compilation) \$CC C compiler name (use --target= for cross-compilation) \$CXXFLAGS pass extra options to C++ compiler + \$CFLAGS pass extra options to C compiler + \$LDFLAGS pass extra options to linker (via C/C++) Options has preference over environment variables. @@ -156,6 +162,14 @@ write_option "$option" EXTRA_CXXFLAGS cxxflags_set=y ;; + --with-extra-cflags=*) + write_option "$option" EXTRA_CFLAGS + cflags_set=y + ;; + --with-extra-ldflags=*) + write_option "$option" EXTRA_LDFLAGS + ldflags_set=y + ;; --use-static-gcc) write_option "1" USE_STATIC_LIBGCC ;; @@ -236,6 +250,22 @@ fi fi +if [ "$CFLAGS" != "" ]; then + if [ "$cflags_set" = "" ]; then + write_option "$CFLAGS" EXTRA_CFLAGS + else + echo "Both --with-extra-cflags and \$CFLAGS set, using the first" + fi +fi + +if [ "$LDFLAGS" != "" ]; then + if [ "$ldflags_set" = "" ]; then + write_option "$LDFLAGS" EXTRA_LDFLAGS + else + echo "Both --with-extra-ldflags and \$LDFLAGS set, using the first" + fi +fi + # default settings default_settings This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |