source: git/factory/ftest/GNUmakefile.in @ 341696

spielwiese
Last change on this file since 341696 was 341696, checked in by Hans Schönemann <hannes@…>, 14 years ago
Adding Id property to all files git-svn-id: file:///usr/local/Singular/svn/trunk@12231 2c84dea3-7e68-4137-9b89-c4e89433aadc
  • Property mode set to 100644
File size: 3.3 KB
Line 
1# @configure_input@
2# $Id$
3
4#
5# GNUmakefile.in - used by `configure' to create `GNUmakefile', the
6#   makefile for the Factory Test Environment.
7#
8# In general, you should let `configure' guess the correct values
9# for the variables below.  But if something seriously goes wrong
10# in configuring, please inform the authors and feel free to
11# edit the marked section.
12#
13# See the `INSTALL' file for information on how to build the
14# Factory Test Environment.
15#
16# Note: Use GNU `make' (`gmake') to make with this makefile.
17#
18# Note: Allthough you may use this `GNUmakefile' directly you
19# better use the top level `GNUmakefile' to make the test
20# programs.  Furthermore, you first have to `make' Factory before
21# you can `make' the Factory Test Environment.
22#
23
24############### START OF CONFIGURABLE SECTION ###############
25
26SHELL =         /bin/sh
27
28#
29# - paths.
30#
31srcdir =        @srcdir@
32VPATH =         @srcdir@
33NTLPATH =       $(srcdir)/../../ntl-2.0
34
35#
36# - programs.
37#
38CXX =           @CXX@
39M4 =            @M4@
40
41#
42# - flags.
43#
44CPPFLAGS =      @CPPFLAGS@
45CXXFLAGS =      @CXXFLAGS@
46DEFS =          @DEFS@
47LDFLAGS =       @LDFLAGS@
48LIBS =          @LIBS@
49
50M4FLAGS =       @M4FLAGS@
51
52############### END OF CONFIGURABLE SECTION ###############
53
54#
55# - compiler flags.
56#
57WARNFLAGS =     -w
58
59# flags to translate library c++ files
60LIBCXXFLAGS =   $(WARNFLAGS) -fno-implicit-templates \
61                -I$(srcdir) -I.. -I$(srcdir)/.. \
62                $(DEFS) $(CPPFLAGS) $(CXXFLAGS)
63
64# flags to translate test programs
65FTESTCXXFLAGS = $(LIBCXXFLAGS)
66
67# flags to link test programs
68FTESTLDFLAGS =  $(LIBS) $(LDFLAGS)
69
70#
71# - source files.
72#
73
74# use value from environment if set, otherwise supply reasonable
75# default value
76ifndef ftestm4src
77ftestm4src :=   feval.m4
78endif
79ftestccsrc :=   $(ftestm4src:.m4=.cc)
80ftestobj :=     $(ftestm4src:.m4=.o)
81ftestexec :=    $(ftestm4src:.m4=)
82
83#
84# - phony and precious targets.
85#
86.PHONY:         all clean distclean
87.PRECIOUS:      %.cc %.o
88
89#
90# - pattern rules.
91#
92
93# cancel some builtin rules which may cause confusion
94%: %.o
95%: %.cc
96
97# how to link the ntl test files
98%.ntl: %.ntl.o ftest_util.o ftest_io.o ntl_util.o ../libcf.a ../libcfmem.a ../ftmpl_inst.o
99                $(CXX) $^ $(FTESTLDFLAGS) $(NTLPATH)/ntl.a -o $@
100
101# how to create the ntl test file objects
102%.ntl.o: %.ntl.cc ../factory.h ftest_util.h ftest_io.h ntl_util.h
103                $(CXX) -c $< -I$(NTLPATH) $(FTESTCXXFLAGS) -o $@
104
105# how to link the test files
106%: %.o ftest_util.o ftest_io.o ../libcf.a ../libcfmem.a ../ftmpl_inst.o
107                $(CXX) $^ $(FTESTLDFLAGS) -o $@
108
109# how to create the test file objects
110%.o: %.cc ../factory.h ftest_util.h ftest_io.h
111                $(CXX) -c $< $(FTESTCXXFLAGS) -o $@
112
113# how to create the test programs
114%.cc: %.m4 ftest_util.m4
115                $(M4) $(M4FLAGS) $(srcdir)/ftest_util.m4 $< > $@
116
117#
118# - create `feval'.
119#
120# This is a dummy target only just in case the user types `make'
121# in the FTE directory.
122#
123all:            feval
124
125#
126# - explicit targets.
127#
128
129# do not create ftest_util.cc from ftest_util.m4!
130ftest_util.cc:
131                touch $@
132
133ftest_util.o:   ftest_util.cc ftest_util.h ftest_io.h ../factory.h
134                $(CXX) -c $< $(LIBCXXFLAGS) -o $@
135
136ftest_io.o:     ftest_io.cc ftest_io.h ftest_util.h ../factory.h
137                $(CXX) -c $< $(LIBCXXFLAGS) -o $@
138
139ntl_util.o:     ntl_util.cc ntl_util.h ../factory.h
140                $(CXX) -c $< -I$(NTLPATH) $(LIBCXXFLAGS) -o $@
141
142#
143# - cleaning up.
144#
145clean:         
146                -rm -f $(ftestexec) $(ftestccsrc) *.o
147
148distclean:      clean
149                -rm -f GNUmakefile
150
151
152#
153# - configure stuff.
154#
155GNUmakefile:    GNUmakefile.in ../config.status
156                cd .. && CONFIG_FILES=ftest/GNUmakefile CONFIG_HEADERS= ./config.status
Note: See TracBrowser for help on using the repository browser.