svn commit: trunk/uClibc

psm at uclibc.org psm at uclibc.org
Thu Oct 27 12:44:14 UTC 2005


Author: psm
Date: 2005-10-27 05:44:11 -0700 (Thu, 27 Oct 2005)
New Revision: 11930

Log:
Hope to catch --combine flag properly on all gcc versions

Modified:
   trunk/uClibc/Rules.mak


Changeset:
Modified: trunk/uClibc/Rules.mak
===================================================================
--- trunk/uClibc/Rules.mak	2005-10-27 12:07:45 UTC (rev 11929)
+++ trunk/uClibc/Rules.mak	2005-10-27 12:44:11 UTC (rev 11930)
@@ -259,9 +259,20 @@
 OPTIMIZATION+=$(call check_gcc,-Os,-O2)
 # Use the gcc 3.4 -funit-at-a-time optimization when available
 OPTIMIZATION+=$(call check_gcc,-funit-at-a-time,)
-# gcc 4.x needs -fcombine, else building all sources at once fails
-OPTIMIZATION+=$(call check_gcc,-fcombine,)
 
+# we try to compile all sources at once into an object (IMA), but
+# gcc-3.3.x does not support it
+# gcc-3.4.x supports it, but does not need and support --combine
+# gcc-4.0.x supports it, supports the --combine flag, but does not need it
+# gcc-4.1(200506xx) supports it, but needs the --combine flag, else libs are useless
+GCC_VER?=$(shell $(CC) -dumpversion | cut -d . -f 1,2)
+ifeq ($(GCC_VER),3.3)
+# not supported
+DOMULTI=n
+else
+OPTIMIZATION+=$(call check_gcc,--combine,)
+endif
+
 # Add a bunch of extra pedantic annoyingly strict checks
 XWARNINGS=$(subst ",, $(strip $(WARNINGS))) -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing
 XARCH_CFLAGS=$(subst ",, $(strip $(ARCH_CFLAGS)))




More information about the uClibc-cvs mailing list