• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# ;;; -*- Mode:makefile;-*-
2# Generated automatically from Makefile.in by configure.
3# This requires GNU make.
4
5srcdir = .
6VPATH = .
7SHELL=/bin/sh
8
9# point this to proper location
10STL_INCL=-I../../stlport
11
12AUX_LIST=TestClass.cpp main.cpp nc_alloc.cpp random_number.cpp
13
14TEST_LIST=test_algo.cpp  \
15test_algobase.cpp     test_list.cpp test_slist.cpp \
16test_bit_vector.cpp   test_vector.cpp \
17test_deque.cpp test_set.cpp test_map.cpp \
18test_hash_map.cpp  test_hash_set.cpp test_rope.cpp \
19test_string.cpp test_bitset.cpp test_valarray.cpp
20
21LIST=${AUX_LIST} ${TEST_LIST}
22
23OBJECTS = $(LIST:%.cpp=obj/%.o) $(STAT_MODULE)
24D_OBJECTS = $(LIST:%.cpp=d_obj/%.o) $(STAT_MODULE)
25NOSGI_OBJECTS = $(LIST:%.cpp=nosgi_obj/%.o) $(STAT_MODULE)
26
27EXECS = $(LIST:%.cpp=%)
28TESTS = $(LIST:%.cpp=%.out)
29TEST_EXE  = ./eh_test
30D_TEST_EXE = ./eh_test_d
31NOSGI_TEST_EXE = ./eh_test_nosgi
32
33TEST  = ./eh_test.out
34D_TEST = ./eh_test_d.out
35NOSGI_TEST = ./eh_test_nosgi.out
36
37CC = c++
38CXX = $(CC)
39
40# dwa 12/22/99 -- had to turn off -ansi flag so we could use SGI IOSTREAMS
41# also, test_slist won't compile with -O3/-O2 when targeting PPC. It fails
42# in the assembler with 'invalid relocation type'
43CXXFLAGS = -Wall -g -O ${STL_INCL} -I. ${CXX_EXTRA_FLAGS} -DEH_VECTOR_OPERATOR_NEW
44D_CXXFLAGS = -Wall -g -O ${STL_INCL} -I. ${CXX_EXTRA_FLAGS} -DEH_VECTOR_OPERATOR_NEW -D_STLP_DEBUG -D_STLP_USE_STATIC_LIB
45NOSGI_CXXFLAGS = -Wall -g -O2 ${STL_INCL} -I. ${CXX_EXTRA_FLAGS} -D_STLP_NO_OWN_IOSTREAMS -D_STLP_DEBUG_UNINITIALIZED -DEH_VECTOR_OPERATOR_NEW
46
47check: $(TEST)
48
49LIBS = -lm -lpthread
50D_LIBSTLPORT = -L../../lib -R../../lib -lstlport_gcc_stldebug
51LIBSTLPORT = -L../../lib -R../../lib -lstlport_gcc
52
53all: $(TEST_EXE) $(D_TEST_EXE) $(NOSGI_TEST_EXE)
54
55check_nosgi: $(NOSGI_TEST)
56check_d: $(D_TEST)
57
58OBJDIR=obj
59D_OBJDIR=d_obj
60NOSGI_OBJDIR=nosgi_obj
61
62$(OBJDIR):
63	mkdir obj
64$(D_OBJDIR):
65	mkdir d_obj
66$(NOSGI_OBJDIR):
67	mkdir nosgi_obj
68
69$(TEST_EXE) : $(OBJDIR) $(OBJECTS)
70	$(CXX) $(CXXFLAGS) $(OBJECTS) $(LIBSTLPORT) $(LIBS) -o $(TEST_EXE)
71
72$(D_TEST_EXE) : $(D_OBJDIR) $(D_OBJECTS)
73	$(CXX) $(D_CXXFLAGS) $(D_OBJECTS) $(D_LIBSTLPORT) $(LIBS) -o $(D_TEST_EXE)
74
75$(NOSGI_TEST_EXE) : $(NOSGI_OBJDIR) $(NOSGI_OBJECTS)
76	$(CXX) $(NOSGI_CXXFLAGS) $(NOSGI_OBJECTS) $(LIBS) -o $(NOSGI_TEST_EXE)
77
78
79$(TEST) : $(TEST_EXE)
80	LD_LIBRARY_PATH="../../lib:$(LD_LIBRARY_PATH)" ./$(TEST_EXE) -s 100
81
82$(D_TEST) : $(D_TEST_EXE)
83	LD_LIBRARY_PATH="../../lib:$(LD_LIBRARY_PATH)" ./$(D_TEST_EXE) -s 100
84
85
86$(NOSGI_TEST) : $(NOSGI_TEST_EXE)
87	$(NOSGI_TEST_EXE)
88
89SUFFIXES: .cpp.o.exe.out.res
90
91nosgi_obj/%.o : %.cpp
92	$(CXX) $(NOSGI_CXXFLAGS) $< -c -o $@
93
94d_obj/%.o : %.cpp
95	$(CXX) $(D_CXXFLAGS) $< -c -o $@
96
97obj/%.o : %.cpp
98	$(CXX) $(CXXFLAGS) $< -c -o $@
99
100nosgi_obj/%.i : %.cpp
101	$(CXX) $(NOSGI_CXXFLAGS) $< -E -H > $@
102
103d_obj/%.i : %.cpp
104	$(CXX) $(D_CXXFLAGS) $< -E -H > $@
105
106obj/%.i : %.cpp
107	$(CXX) $(CXXFLAGS) $< -E -H > $@
108
109%.out: %.cpp
110	$(CXX) $(CXXFLAGS) $< -c -USINGLE -DMAIN -g -o $*.o
111	$(CXX) $(CXXFLAGS) $*.o $(LIBS) -o $*
112	./$* > $@
113	-rm -f $*
114
115%.s: %.cpp
116	$(CXX) $(CXXFLAGS) -O4 -S -pto $<  -o $@
117
118%.E: %.cpp
119	$(CXX) $(CXXFLAGS) -E $<  -o $@
120
121clean:
122	-rm -fr ${TEST_EXE} *.o */*.o *.rpo *.obj *.out core *~ Templates.DB
123