1 |
# ASCEND Interface Makefile |
2 |
# Kirk Abbott. Ben Allan |
3 |
# November 24, 1993 |
4 |
# $Revision: 1.37 $ |
5 |
# $Date: 2004/07/13 07:42:31 $ |
6 |
# $Author: ballan $ |
7 |
# $Source: /afs/cs.cmu.edu/project/ascend/Repository/ascend4/interface/Makefile.in,v $ |
8 |
# |
9 |
|
10 |
|
11 |
SHELL = /bin/sh |
12 |
#AWW20041206: builddir = .. |
13 |
builddir = .. |
14 |
srcdir = @srcdir@/../../../tcltk98/generic |
15 |
VPATH = @srcdir@/../../../tcltk98/generic |
16 |
|
17 |
|
18 |
|
19 |
# The next variables are the primary executables and/or libraries that |
20 |
# this makefile is responsible for, and the default target of this |
21 |
# makefile. |
22 |
|
23 |
EXECUTABLE = $(builddir)/bin/ascend4 |
24 |
|
25 |
PURIFIED_EXEC = $(builddir)/bin/ascend4p |
26 |
|
27 |
QUANTIFIED_EXEC = $(builddir)/bin/ascend4q |
28 |
|
29 |
LIBRARY = libascif.a |
30 |
|
31 |
|
32 |
default: $(LIBRARY) $(EXECUTABLE) |
33 |
|
34 |
|
35 |
|
36 |
# Defines and Includes that are specific to this directory |
37 |
|
38 |
DIR_SPECIFIC_DEFS = $(SOLVER_DEFS) |
39 |
DIR_SPECIFIC_INCS = $(TK_INCS) $(X11_INCS) |
40 |
|
41 |
|
42 |
|
43 |
|
44 |
# The next variables list the source files (EXEC_SCRS) to compile |
45 |
# into the object files (EXEC_OBJS) that are linked with the |
46 |
# library files (EXEC_LIBS) to make EXECUTABLE |
47 |
|
48 |
EXEC_SRCS = Driver.c |
49 |
|
50 |
EXEC_OBJS = Driver.o |
51 |
|
52 |
EXEC_LIBS = $(ASC_LIBS) $(FOR_LIBS) $(TK_LIBS) $(TKTABLE_LIB) $(X11_LIBS) \ |
53 |
$(MATH_LIBS) $(DEBUG_LIBS) |
54 |
|
55 |
|
56 |
|
57 |
# The next variables list the source files (LIB_SCRS) to compile |
58 |
# into the object files (LIB_OBJS) that are combined to make LIBRARY |
59 |
|
60 |
LIB_SRCS = \ |
61 |
AscBitmaps.c BrowLogRel_io.c BrowWhen_io.c BrowserDag.c \ |
62 |
BrowserMethod.c BrowserProc.c BrowserQuery.c BrowserRel_io.c \ |
63 |
CodeGen.c CodeGen2.c Commands.c DebugProc.c DisplayProc.c \ |
64 |
EnvVarProc.c HelpProc.c Integrators.c \ |
65 |
LibraryProc.c Lsode.c MtxProc.c ProbeProc.c Qlfdid.c \ |
66 |
ScriptProc.c Sensitivity.c SimsProc.c SlvProc.c \ |
67 |
SolverProc.c UnitsProc.c UserData.c \ |
68 |
plot.c tkConsole.c typelex.c old_utils.c |
69 |
|
70 |
LIB_OBJS = \ |
71 |
AscBitmaps.o BrowLogRel_io.o BrowWhen_io.o \ |
72 |
BrowserMethod.o BrowserProc.o BrowserQuery.o BrowserRel_io.o \ |
73 |
Commands.o DebugProc.o DisplayProc.o \ |
74 |
EnvVarProc.o HelpProc.o Integrators.o \ |
75 |
LibraryProc.o Lsode.o MtxProc.o ProbeProc.o Qlfdid.o \ |
76 |
ScriptProc.o Sensitivity.o SimsProc.o SlvProc.o \ |
77 |
SolverProc.o UnitsProc.o UserData.o \ |
78 |
plot.o tkConsole.o typelex.o old_utils.o |
79 |
|
80 |
|
81 |
|
82 |
|
83 |
# The global makefile macros (ConfigAscend) and global rules (Makefile.Rules) |
84 |
# |
85 |
#AWW $builddir is currently pointing to: base/generic |
86 |
# |
87 |
include $(builddir)/ConfigAscend |
88 |
include $(builddir)/Makefile.Rules |
89 |
|
90 |
|
91 |
|
92 |
# Some aliases for targets |
93 |
|
94 |
ascend4 GUI: $(EXECUTABLE) |
95 |
|
96 |
ascend4p: $(PURIFIED_EXEC) |
97 |
|
98 |
ascend4q: $(QUANTIFIED_EXEC) |
99 |
|
100 |
|
101 |
|
102 |
# File specific rules |
103 |
|
104 |
DriverNoTickle.o: Driver.date |
105 |
$(CC) $(CC_SWITCHES) $(HAVE_TKTABLE) $(TIMESTAMP) -c $(srcdir)/DriverNoTickle.c |
106 |
$(RM) Driver.date |
107 |
|
108 |
|
109 |
# Force an update of Driver.o so we update the value |
110 |
# of TIMESTAMP in the ascend binary |
111 |
|
112 |
Driver.o: Driver.date |
113 |
$(CC) $(CC_SWITCHES) $(HAVE_TKTABLE) $(TIMESTAMP) -c $(srcdir)/Driver.c |
114 |
$(RM) Driver.date |
115 |
|
116 |
Driver.date: $(srcdir)/Driver.c |
117 |
$(ECHO) 'A file to force a timestamp update' > Driver.date |
118 |
|
119 |
|
120 |
|
121 |
# The C file for the typer (typelex.c) can either be generated by flex, |
122 |
# or it can come from a pregenerated C file. The configure script will |
123 |
# set the $(MAKE) line under the ``typelex'' target to maker either |
124 |
# typelex.c.from.flex ---to generate the typer using flex |
125 |
# typelex.c.from.c ---to use the pregenerated C file |
126 |
# depending on the value of $(LEX). |
127 |
|
128 |
typelex.o: $(srcdir)/typelex.l $(srcdir)/typelex.c.no.flex |
129 |
$(MAKE) @typer_src@ |
130 |
$(CC) $(CC_SWITCHES) -DYY_USE_CONST -c typelex.c |
131 |
|
132 |
typelex.c.from.flex: $(srcdir)/typelex.l |
133 |
$(LEX) -Ptyp_ -t $(srcdir)/typelex.l > typelex.c |
134 |
|
135 |
typelex.c.from.c: $(srcdir)/typelex.c.no.flex |
136 |
$(CP) $(srcdir)/typelex.c.no.flex typelex.c |
137 |
|
138 |
typelex.c: $(srcdir)/typelex.l $(srcdir)/typelex.c.no.flex |
139 |
$(MAKE) @typer_src@ |
140 |
|
141 |
|
142 |
|
143 |
# Files to install |
144 |
|
145 |
install-binaries:: |
146 |
@if test ! -d $(BIN_DIR) ; then \ |
147 |
echo Making directory $(BIN_DIR) ; \ |
148 |
mkdir -p $(BIN_DIR) ; \ |
149 |
fi |
150 |
@if $(CMP) -s $(EXECUTABLE) $(BIN_DIR)/$(EXECUTABLE) ; then \ |
151 |
echo "Skipping $(EXECUTABLE) (up to date)" ; \ |
152 |
else \ |
153 |
echo "Installing $(EXECUTABLE) --> $(BIN_DIR)" ; \ |
154 |
$(INSTALL_PROGRAM) $(EXECUTABLE) $(BIN_DIR) ; \ |
155 |
fi |
156 |
|
157 |
|
158 |
|
159 |
# Files, in addition to the default, to remove when we `make clean' |
160 |
|
161 |
clean:: |
162 |
-$(RM) typelex.c Driver.date |
163 |
|
164 |
|
165 |
|
166 |
# DO NOT DELETE THIS LINE -- g++dep uses it. |
167 |
# DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY. |
168 |
|
169 |
|
170 |
# IF YOU PUT ANYTHING HERE IT WILL GO AWAY |