stdcxx-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lnico...@apache.org
Subject svn commit: r510070 - /incubator/stdcxx/trunk/etc/config/icc.config
Date Wed, 21 Feb 2007 15:58:21 GMT
Author: lnicoara
Date: Wed Feb 21 07:58:20 2007
New Revision: 510070

URL: http://svn.apache.org/viewvc?view=rev&rev=510070
Log:
2007-02-21  lnicoara  <nicoara@roguewave.com>

     * etc/config/icc.config
       Changed build process for post-8.1 compilers to
       use the yet undocumented -cxxlib-nostd option. 


Modified:
    incubator/stdcxx/trunk/etc/config/icc.config

Modified: incubator/stdcxx/trunk/etc/config/icc.config
URL: http://svn.apache.org/viewvc/incubator/stdcxx/trunk/etc/config/icc.config?view=diff&rev=510070&r1=510069&r2=510070
==============================================================================
--- incubator/stdcxx/trunk/etc/config/icc.config (original)
+++ incubator/stdcxx/trunk/etc/config/icc.config Wed Feb 21 07:58:20 2007
@@ -15,8 +15,11 @@
 endif
 
 CCVER          := $(shell $(CXX) -V foo.c 2>&1 | sed -n "s/.*Version *\([0-9.]*\).*/\1/p")
+CXX_MAJOR      := $(shell echo "$(CCVER)" | sed "s/^\([1-9][0-9]*\).*/\1/")
+CXX_MINOR      := $(shell echo "$(CCVER)" | sed "s/[1-9]*\.\([0-9]*\).*/\1/")
+
+
 CPPFLAGS        = -I$(TOPDIR)/include/ansi
-CXXFLAGS        = -Xc -no_cpprt
 
 WARNFLAGS       = -w1
 PHWARNFLAGS     =
@@ -26,10 +29,21 @@
 
 ICCDIR          = `which $(CXX) | sed 's:bin/$(CXX):lib:'`
 
-LD              = $(CXX) -no_cpprt $(ICCDIR)/crtxi.o
-LDFLAGS         =
 LDSOFLAGS       = -shared
-LDLIBS          = -Bstatic -lcxa -lunwind -Bdynamic $(ICCDIR)/crtxn.o
+
+# -cxxlib-nostd, present in all compilers since 8.1, will be documented in 10.x
+ifeq ($(shell [ $(CXX_MAJOR) -gt 8 -o $(CXX_MAJOR) -eq 8 -a $(CXX_MINOR) -ge 1 ]), 0)
+  LD            = $(CXX) -no_cpprt $(ICCDIR)/crtxi.o
+  CXXFLAGS      = -Xc -no_cpprt
+  LDFLAGS       =
+  LDLIBS        = -Bstatic -lcxa -lunwind -Bdynamic $(ICCDIR)/crtxn.o
+else
+  LD            = $(CXX)
+  CXXFLAGS      = -cxxlib-nostd
+  LDFLAGS       = -cxxlib-nostd
+  LDLIBS        = -lcxaguard -lsupc++
+endif
+
 
 # The flag(s) to use to embed a library search path into generated executables.
 RPATH           = -Wl,-R



Mime
View raw message