You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@stdcxx.apache.org by vi...@apache.org on 2008/01/30 03:10:57 UTC
svn commit: r616588 - in /stdcxx/branches/4.2.x: GNUmakefile
etc/config/makefile.rules
Author: vitek
Date: Tue Jan 29 18:10:55 2008
New Revision: 616588
URL: http://svn.apache.org/viewvc?rev=616588&view=rev
Log:
2008-01-29 Travis Vitek <vi...@roguewave.com>
Merged rev 615419 with a fix for STDCXX-573 from trunk.
* etc/config/makefile.rules: Use WITH_PURIFY or WITH_CADVISE to enable
or disable purify and cadvise tools.
* GNUmakefile: Document new parameters and cache them in makefile.in.
Modified:
stdcxx/branches/4.2.x/GNUmakefile
stdcxx/branches/4.2.x/etc/config/makefile.rules
Modified: stdcxx/branches/4.2.x/GNUmakefile
URL: http://svn.apache.org/viewvc/stdcxx/branches/4.2.x/GNUmakefile?rev=616588&r1=616587&r2=616588&view=diff
==============================================================================
--- stdcxx/branches/4.2.x/GNUmakefile (original)
+++ stdcxx/branches/4.2.x/GNUmakefile Tue Jan 29 18:10:55 2008
@@ -151,6 +151,12 @@
#
# WARNFLAGS - any compiler warning options
#
+# WITH_PURIFY - set to `true' to build with purify. additional flags
+# can be specified in PURIFYFLAGS.
+#
+# WITH_CADVISE - set to `true' to build with cadvise. additional flags
+# can be specified in CADVISEFLAGS.
+#
########################################################################
SHELL = /bin/sh
@@ -642,6 +648,10 @@
&& echo "BUILDTAG = $(BUILDTAG)" >> $(MAKEFILE_IN) \
&& echo "PLATFORM = $(PLATFORM)" >> $(MAKEFILE_IN) \
&& echo "DEFAULT_SHROBJ = $(DEFAULT_SHROBJ)" >> $(MAKEFILE_IN) \
+ && echo "WITH_CADVISE = $(WITH_CADVISE)" >> $(MAKEFILE_IN) \
+ && echo "CADVISEFLAGS = $(CADVISEFLAGS)" >> $(MAKEFILE_IN) \
+ && echo "WITH_PURIFY = $(WITH_PURIFY)" >> $(MAKEFILE_IN) \
+ && echo "PURIFYFLAGS = $(PURIFYFLAGS)" >> $(MAKEFILE_IN) \
&& echo "CXX_REPOSITORY = $(CXX_REPOSITORY)" >> $(MAKEFILE_IN));
# creates the build directory tree and generates makefile.in
Modified: stdcxx/branches/4.2.x/etc/config/makefile.rules
URL: http://svn.apache.org/viewvc/stdcxx/branches/4.2.x/etc/config/makefile.rules?rev=616588&r1=616587&r2=616588&view=diff
==============================================================================
--- stdcxx/branches/4.2.x/etc/config/makefile.rules (original)
+++ stdcxx/branches/4.2.x/etc/config/makefile.rules Tue Jan 29 18:10:55 2008
@@ -70,6 +70,25 @@
-gencat $@ $^
+ifeq ($(WITH_PURIFY),true)
+ ifeq ($(PURIFYFLAGS),)
+ PURIFYFLAGS = -windows=no
+ PURIFYFLAGS += -log-file=stderr -view-file=$@.purify-view
+ endif
+
+ ifneq ($(OSNAME),AIX)
+ PURIFY = purify $(PURIFYFLAGS)
+ endif
+endif
+
+ifeq ($(WITH_CADVISE),true)
+ ifeq ($(CADVISEFLAGS),)
+ CADVISEFLAGS = +w
+ endif
+
+ CADVISE = cadvise $(CADVISEFLAGS)
+endif
+
########################################################################
# COMMON RULES
########################################################################
@@ -89,17 +108,17 @@
# make the rule match for sources matching *.out.cpp
%.out.o: %.out.cpp
- $(CXX) -c $(CPPFLAGS) $(CXXFLAGS) $(call CXX.repo,$<) $<
+ $(CADVISE) $(CXX) -c $(CPPFLAGS) $(CXXFLAGS) $(call CXX.repo,$<) $<
%.o: %.cpp
- $(CXX) -c $(CPPFLAGS) $(CXXFLAGS) $(call CXX.repo,$<) $<
+ $(CADVISE) $(CXX) -c $(CPPFLAGS) $(CXXFLAGS) $(call CXX.repo,$<) $<
# make the rule match for objects matching *.out.o
%.out: %.out.o
- $(LD) $< -o $@ $(LDFLAGS) $(LDLIBS) $(call CXX.repo,$<)
+ $(PURIFY) $(LD) $< -o $@ $(LDFLAGS) $(LDLIBS) $(call CXX.repo,$<)
%: %.o
- $(LD) $< -o $@ $(LDFLAGS) $(LDLIBS) $(call CXX.repo,$<)
+ $(PURIFY) $(LD) $< -o $@ $(LDFLAGS) $(LDLIBS) $(call CXX.repo,$<)
# disable compilation and linking in the same step
# %: %.cpp
@@ -108,8 +127,8 @@
# compile and link in one step to eliminate the space overhead of .o files
%: %.cpp
- $(CXX) $< -o $@ $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) $(LDLIBS) \
- $(call CXX.repo,$<)
+ $(CADVISE) $(PURIFY) $(CXX) $< -o $@ $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) \
+ $(LDLIBS) $(call CXX.repo,$<)
endif # eq ($(NO_DOT_O),)