Author: sebor
Date: Wed Sep 21 11:39:43 2005
New Revision: 290780
URL: http://svn.apache.org/viewcvs?rev=290780&view=rev
Log:
2005-09-21 Martin Sebor <[EMAIL PROTECTED]>
* GNUmakefile.rwt: Set SRCDIRS correctly and let makefile.common
find all source files instead of doing it here.
Removed an unnecessary -I option from INCLUDES.
Replaced RWTESTSRCS and RWTESTOBJS with SRCS and OBJS (defined
in makefile.common).
Removed libstd from the all target since the librwtest archive
doesn't depend on it.
Removed the unused RUNFLAGS.
Modified:
incubator/stdcxx/trunk/etc/config/GNUmakefile.rwt
Modified: incubator/stdcxx/trunk/etc/config/GNUmakefile.rwt
URL:
http://svn.apache.org/viewcvs/incubator/stdcxx/trunk/etc/config/GNUmakefile.rwt?rev=290780&r1=290779&r2=290780&view=diff
==============================================================================
--- incubator/stdcxx/trunk/etc/config/GNUmakefile.rwt (original)
+++ incubator/stdcxx/trunk/etc/config/GNUmakefile.rwt Wed Sep 21 11:39:43 2005
@@ -18,10 +18,11 @@
# The place where the sources are looked for;
# used in the variables setup in makefile.common
+RWTESTDIR = $(TOPDIR)/../rwtest
TESTDIR = $(TOPDIR)/tests
-SRCDIRS = $(TESTDIR)/src
+SRCDIRS = $(RWTESTDIR)/src $(TOPDIR)/tests/src
-TARGET = $(TESTDIR)/$(TESTLIB)
+TARGET = $(RWTESTDIR)/$(RWTESTLIB)
# include common variables setting for all makefiles
ONE_REPOSITORY = 1
@@ -31,63 +32,55 @@
LIBSUFFIX = .a
# Target library to be built
-TESTLIB = librwtest$(BUILDTYPE)$(LIBSUFFIX)
+RWTESTLIB = librwtest$(BUILDTYPE)$(LIBSUFFIX)
# Additional include directories:
-INCLUDES += -I$(TESTDIR)/include
+INCLUDES += -I$(RWTESTDIR) -I$(TESTDIR)/include
# VPATH to look for sources in (appended dir for test.cpp)
-VPATH += $(TESTDIR)/src
-
-# sources and corresponding objects for the test driver library
-TESTSRCS = $(notdir $(shell echo $(TESTDIR)/src/*.cpp))
-TESTOBJS = $(patsubst %.cpp,%.o,$(TESTSRCS))
-
-RUNFLAGS += -X "-C $(CXX)-$(CCVER)"
+VPATH += $(RWTESTDIR)/src $(TESTDIR)/src
# For xlC 5.0.2.0
ifneq ($(DEFAULT_SHROBJ),)
-SOBJS = $(DEFAULT_SHROBJ)
+ SOBJS = $(DEFAULT_SHROBJ)
else
-SOBJS = $(TESTOBJS)
+ SOBJS = $(OBJS)
endif
# CXXPRELINK - command for compilers that use template
# instantiation models that require a prelink stage
ifneq ($(PRELINKFLAGS),)
-CXXPRELINK = $(CXX) $(CPPFLAGS) $(PRELINKFLAGS) $(TESTOBJS) $(LDFLAGS)
+CXXPRELINK = $(CXX) $(CPPFLAGS) $(PRELINKFLAGS) $(OBJS) $(LDFLAGS)
endif # ($(PRELINKFLAGS),)
##############################################################################
# TARGETS
##############################################################################
-all: $(LIBDIR)/$(LIBNAME) $(TESTLIB)
+all: $(RWTESTLIB)
-$(LIBDIR)/$(LIBNAME):
- @$(MAKE) -C $(LIBDIR)
# do any directory specific cleanup using the realclean target
realclean: clean dependclean
- rm -f $(TESTLIB)
+ rm -f $(RWTESTLIB)
# For the time being the rules are identical until we
# decide to build a shared library for rw test lib.
ifeq ($(findstring shared,$(BUILDMODE)),shared)
-$(TESTLIB): $(TESTOBJS)
+$(RWTESTLIB): $(OBJS)
@echo "$(CXXPRELINK)" >> $(LOGFILE)
$(CXXPRELINK) $(TEEOPTS)
- @echo "$(AR) $(ARFLAGS) $(TESTLIB) $(SOBJS)" >> $(LOGFILE)
- $(AR) $(ARFLAGS) $(TESTLIB) $(SOBJS)
+ @echo "$(AR) $(ARFLAGS) $(RWTESTLIB) $(SOBJS)" >> $(LOGFILE)
+ $(AR) $(ARFLAGS) $(RWTESTLIB) $(SOBJS)
else
-$(TESTLIB): $(TESTOBJS)
+$(RWTESTLIB): $(OBJS)
@echo "$(CXXPRELINK)" >> $(LOGFILE)
$(CXXPRELINK) $(TEEOPTS)
- @echo "$(AR) $(ARFLAGS) $(TESTLIB) $(SOBJS)" >> $(LOGFILE)
- $(AR) $(ARFLAGS) $(TESTLIB) $(SOBJS)
+ @echo "$(AR) $(ARFLAGS) $(RWTESTLIB) $(SOBJS)" >> $(LOGFILE)
+ $(AR) $(ARFLAGS) $(RWTESTLIB) $(SOBJS)
endif # ($(findstring shared,$(BUILDMODE)),shared)