860
|
1 # @configure_input@ |
5
|
2 # |
|
3 # Common configuration rules for all of octave's Makefiles. |
|
4 # |
|
5 # John W. Eaton |
1450
|
6 # jwe@bevo.che.wisc.edu |
|
7 # University of Wisconsin-Madison |
5
|
8 # Department of Chemical Engineering |
1450
|
9 |
5
|
10 SHELL = /bin/sh |
|
11 |
3029
|
12 # A shell command to extract the version number from version.h. |
|
13 getversion = sed -e '/VERSION/!d' -e 's/.*"\(.*\)".*$$/\1/' -e q |
|
14 |
|
15 # Look for version.h to get version information. |
|
16 xfiles := $(TOPDIR)/src/version.h $(srcdir)/$(TOPDIR)/src/version.h |
|
17 version_file := $(firstword $(foreach file, $(xfiles), $(wildcard $(file)))) |
|
18 version := $(shell $(getversion) $(version_file)) |
|
19 |
5
|
20 #### Start of system configuration section. #### |
|
21 |
2577
|
22 EXE = @EXE@ |
|
23 |
5
|
24 LEX = @LEX@ |
|
25 LFLAGS = @LFLAGS@ |
|
26 LEXLIB = @LEXLIB@ |
|
27 |
|
28 YACC = @YACC@ |
|
29 YFLAGS = -dv |
|
30 |
3675
|
31 GPERF = @GPERF@ |
|
32 |
1462
|
33 AR = @AR@ |
|
34 ARFLAGS = @ARFLAGS@ |
|
35 |
5
|
36 RANLIB = @RANLIB@ |
|
37 |
1722
|
38 LN_S = @LN_S@ |
|
39 |
5
|
40 RUNTEST = @RUNTEST@ |
|
41 |
2518
|
42 TEXI2DVI = $(top_srcdir)/texi2dvi |
|
43 |
5
|
44 DEFAULT_PAGER = @DEFAULT_PAGER@ |
|
45 |
1679
|
46 WITH_DL = @WITH_DL@ |
|
47 WITH_SHL = @WITH_SHL@ |
|
48 |
|
49 WITH_DYNAMIC_LINKING = @WITH_DYNAMIC_LINKING@ |
702
|
50 |
1679
|
51 OCTAVE_LITE = @OCTAVE_LITE@ |
702
|
52 |
3034
|
53 STATIC_LIBS = @STATIC_LIBS@ |
|
54 |
1679
|
55 SHARED_LIBS = @SHARED_LIBS@ |
|
56 SHLEXT = @SHLEXT@ |
3029
|
57 SHLEXT_VER = $(SHLEXT).$(version) |
|
58 |
|
59 LIBEXT = a |
1667
|
60 |
5
|
61 # Fortran to C translator and associated flags. |
|
62 |
|
63 F2C = @F2C@ |
|
64 F2CFLAGS = @F2CFLAGS@ |
|
65 |
|
66 # Fortran compiler flags. |
|
67 |
1163
|
68 FC = @FC@ |
798
|
69 F77 = @F77@ |
5
|
70 FFLAGS = @FFLAGS@ |
1832
|
71 FPICFLAG = @FPICFLAG@ |
2566
|
72 FORTRAN_MAIN_FLAG = @FORTRAN_MAIN_FLAG@ |
2610
|
73 ALL_FFLAGS = $(FFLAGS) |
5
|
74 |
|
75 # cc and associated flags. |
|
76 |
2064
|
77 DLFCN_INCFLAGS = @DLFCN_INCFLAGS@ |
3215
|
78 GLOB_INCFLAGS = @GLOB_INCFLAGS@ |
2064
|
79 |
236
|
80 # Clean up INCFLAGS a bit if we are not compiling in a separate |
|
81 # directory. |
|
82 ifeq ($(srcdir),.) |
2546
|
83 TMP_IF_1 = -I. |
236
|
84 else |
2546
|
85 TMP_IF_1 = -I. -I$(srcdir) |
236
|
86 endif |
404
|
87 ifeq ($(TOPDIR),$(top_srcdir)) |
1832
|
88 TMP_IF_2 = -I$(TOPDIR) -I$(TOPDIR)/liboctave -I$(TOPDIR)/src \ |
3156
|
89 -I$(TOPDIR)/libcruft/misc |
236
|
90 else |
507
|
91 TMP_IF_2 = -I$(TOPDIR) -I$(TOPDIR)/liboctave -I$(TOPDIR)/src \ |
3156
|
92 -I$(TOPDIR)/libcruft/misc -I$(top_srcdir) \ |
2546
|
93 -I$(top_srcdir)/liboctave -I$(top_srcdir)/src \ |
3156
|
94 -I$(top_srcdir)/libcruft/misc |
236
|
95 endif |
3156
|
96 INCFLAGS = $(TMP_IF_1) $(TMP_IF_2) $(DLFCN_INCFLAGS) $(GLOB_INCFLAGS) |
236
|
97 |
5
|
98 LIBFLAGS = -L$(TOPDIR) |
236
|
99 |
5
|
100 DEFS = @DEFS@ |
|
101 |
2032
|
102 UGLY_DEFS = @UGLY_DEFS@ |
|
103 |
5
|
104 CC = @CC@ |
1891
|
105 CC_VERSION = @CC_VERSION@ |
5
|
106 CFLAGS = @CFLAGS@ |
1832
|
107 CPICFLAG = @CPICFLAG@ |
3126
|
108 XTRA_CFLAGS = @XTRA_CFLAGS@ |
|
109 ALL_CFLAGS = $(INCFLAGS) $(DEFS) $(XTRA_CFLAGS) $(CFLAGS) |
|
110 BUG_CFLAGS = $(DEFS) $(XTRA_CFLAGS) $(CFLAGS) |
798
|
111 |
198
|
112 CXX = @CXX@ |
1891
|
113 CXX_VERSION = @CXX_VERSION@ |
518
|
114 CXXCPP = @CXXCPP@ |
198
|
115 CXXFLAGS = @CXXFLAGS@ |
1832
|
116 CXXPICFLAG = @CXXPICFLAG@ |
3126
|
117 XTRA_CXXFLAGS = @XTRA_CXXFLAGS@ |
|
118 ALL_CXXFLAGS = $(INCFLAGS) $(DEFS) $(XTRA_CXXFLAGS) $(CXXFLAGS) |
|
119 UGLY_ALL_CXXFLAGS = $(INCFLAGS) $(UGLY_DEFS) $(XTRA_CXXFLAGS) $(CXXFLAGS) |
|
120 BUG_CXXFLAGS = $(DEFS) $(XTRA_CXXFLAGS) $(CXXFLAGS) |
5
|
121 |
858
|
122 CPPFLAGS = @CPPFLAGS@ |
|
123 |
3705
|
124 LD_CXX = @LD_CXX@ |
5
|
125 LDFLAGS = @LDFLAGS@ |
708
|
126 LD_STATIC_FLAG = @LD_STATIC_FLAG@ |
3126
|
127 ALL_LDFLAGS = $(LIBFLAGS) $(FORTRAN_MAIN_FLAG) \ |
2592
|
128 $(LD_STATIC_FLAG) $(CPICFLAG) $(LDFLAGS) |
5
|
129 |
2676
|
130 SH_LD = @SH_LD@ |
|
131 SH_LDFLAGS = @SH_LDFLAGS@ |
|
132 |
3036
|
133 SONAME_FLAGS = @SONAME_FLAGS@ |
|
134 |
3233
|
135 RDYNAMIC_FLAG = @RDYNAMIC_FLAG@ |
|
136 |
2674
|
137 RLD_FLAG = @RLD_FLAG@ |
|
138 |
5
|
139 FLIBS = @FLIBS@ |
708
|
140 |
2147
|
141 TERMLIBS = @TERMLIBS@ |
2930
|
142 LIBDLFCN = @LIBDLFCN@ |
3215
|
143 LIBGLOB = @LIBGLOB@ |
2147
|
144 LIBPLPLOT = @LIBPLPLOT@ |
2930
|
145 LIBREADLINE = @LIBREADLINE@ |
3156
|
146 LIBKPATHSEA = @LIBKPATHSEA@ |
|
147 LIBOCTINTERP = @LIBOCTINTERP@ |
|
148 LIBOCTAVE = @LIBOCTAVE@ |
|
149 LIBCRUFT = @LIBCRUFT@ |
3111
|
150 SPECIAL_MATH_LIB = @SPECIAL_MATH_LIB@ |
5
|
151 |
2155
|
152 # The arguments passed to configure. |
2156
|
153 config_opts = @config_opts@ |
2155
|
154 |
666
|
155 # ==================== Where To Install Things ==================== |
5
|
156 |
666
|
157 # The default location for installation. Everything is placed in |
|
158 # subdirectories of this directory. The default values for many of |
|
159 # the variables below are expressed in terms of this one, so you may |
|
160 # not need to change them. This defaults to /usr/local. |
|
161 prefix = @prefix@ |
5
|
162 |
666
|
163 # Like `prefix', but used for architecture-specific files. |
|
164 exec_prefix = @exec_prefix@ |
|
165 |
|
166 # Where to install Octave and other binaries that people will want to |
|
167 # run directly. |
|
168 bindir = @bindir@ |
5
|
169 |
666
|
170 # Where to install architecture-independent data files. ${fcnfiledir} |
|
171 # and ${localfcnfiledir} are subdirectories of this. |
|
172 datadir = @datadir@ |
5
|
173 |
3141
|
174 libdir = @libdir@ |
|
175 |
666
|
176 # Where to install and expect libraries like libcruft.a, liboctave.a, |
3141
|
177 # and other architecture-dependent data. |
|
178 octlibdir = @octlibdir@ |
5
|
179 |
1720
|
180 # Where to install and expect executable programs to be run by Octave |
|
181 # rather than directly by users. |
|
182 libexecdir = @libexecdir@ |
|
183 |
2141
|
184 # The prefix for Octave's include file directory. The default is |
|
185 # ${prefix}/include |
2223
|
186 includedir = @includedir@ |
2141
|
187 |
666
|
188 # Where to install Octave's man pages, and what extension they should |
|
189 # have. The default is ${prefix}/man/man1 |
|
190 mandir = @mandir@ |
2223
|
191 man1dir = @man1dir@ |
|
192 man1ext = @man1ext@ |
5
|
193 |
666
|
194 # Where to install and expect the info files describing Octave.. |
|
195 infodir = @infodir@ |
|
196 |
2512
|
197 # The fill path to the default info file. |
|
198 infofile = @infofile@ |
|
199 |
666
|
200 # ==================== Octave-specific directories ==================== |
|
201 |
2993
|
202 # These variables hold the values specific to Octave. They are |
666
|
203 # based on the values of the standard Make variables above. |
|
204 |
3597
|
205 # Where to install Octave's include files (they will actually be |
|
206 # installed in a subdirectory called octave). The default is |
2993
|
207 # ${includedir}/octave-${version} |
|
208 octincludedir = @octincludedir@ |
|
209 |
666
|
210 # Where to install the function file distributed with |
|
211 # Octave. This includes the Octave version, so that the |
|
212 # function files for different versions of Octave will install |
|
213 # themselves in separate directories. |
|
214 fcnfiledir = @fcnfiledir@ |
|
215 |
|
216 # Directories Octave should search for function files specific |
|
217 # to this site (i.e. customizations), before consulting |
|
218 # ${fcnfiledir}. This should be a colon-separated list of |
|
219 # directories. |
827
|
220 localfcnfiledir = @localfcnfiledir@ |
3597
|
221 localverfcnfiledir = @localverfcnfiledir@ |
666
|
222 localfcnfilepath = @localfcnfilepath@ |
5
|
223 |
666
|
224 # Where to put executables to be run by Octave rather than |
|
225 # the user. This path usually includes the Octave version |
|
226 # and configuration name, so that multiple configurations |
|
227 # for multiple versions of Octave may be installed at once. |
|
228 archlibdir = @archlibdir@ |
|
229 |
2439
|
230 # Where to put executables to be run by Octave rather than by the |
|
231 # user that are specific to this site. |
|
232 localarchlibdir = @localarchlibdir@ |
3597
|
233 localverarchlibdir = @localverarchlibdir@ |
2439
|
234 |
666
|
235 # Where to put object files that will by dynamically loaded. |
|
236 # This path usually includes the Octave version and configuration |
|
237 # name, so that multiple configurations for multiple versions of |
|
238 # Octave may be installed at once. |
|
239 octfiledir = @octfiledir@ |
5
|
240 |
666
|
241 # Directories Octave should search for object files that will be |
|
242 # dynamically loaded and that are specific to this site |
|
243 # (i.e. customizations), before consulting ${octfiledir}. This should |
|
244 # be a colon-separated list of directories. |
827
|
245 localoctfiledir = @localoctfiledir@ |
3597
|
246 localveroctfiledir = @localveroctfiledir@ |
666
|
247 localoctfilepath = @localoctfilepath@ |
|
248 |
|
249 # Where Octave will search to find its function files. Before |
|
250 # changing this, check to see if your purpose wouldn't |
|
251 # better be served by changing localfcnfilepath. This |
|
252 # should be a colon-separated list of directories. |
|
253 fcnfilepath = @fcnfilepath@ |
5
|
254 |
685
|
255 # Where Octave will search to find image files.es. |
827
|
256 imagedir = @imagedir@ |
685
|
257 imagepath = @imagepath@ |
|
258 |
5
|
259 # The type of computer we are running on. |
3136
|
260 canonical_host_type = @canonical_host_type@ |
5
|
261 |
3591
|
262 # The -I flags to use for the mkoctfile script. |
3597
|
263 MKOCTFILE_INCFLAGS = \ |
|
264 -I$(octincludedir) -I$(octincludedir)/octave -I$(includedir) |
3591
|
265 |
5
|
266 # The following pattern rules and the substitution functions require |
|
267 # GNU make. If you don't have it, get it! |
|
268 |
1679
|
269 # Rules for making object files from Fortran source. |
994
|
270 # |
|
271 # If we are using f2c there will be a command for the `%.c : %.f' |
|
272 # pattern and no command for the `%.o : %.f' pattern, so that make |
|
273 # will not invoke the fortran compiler by mistake. |
|
274 # |
|
275 # If we are not using f2c, it should be ok to have an empty rule for |
|
276 # the pattern `%.c : %.f', but we don't want to replace make's default |
|
277 # rule for making object from Fortran source files, so there should be |
|
278 # no pattern or command for that. |
5
|
279 |
1679
|
280 @f77_rules_frag@ |
994
|
281 |
1668
|
282 # How to make .o files: |
5
|
283 |
1984
|
284 %.o : %.c |
3615
|
285 $(CC) -c $(CPPFLAGS) $(ALL_CFLAGS) $< -o $@ |
5
|
286 |
1984
|
287 %.o : %.cc |
3615
|
288 $(CXX) -c $(CPPFLAGS) $(ALL_CXXFLAGS) $< -o $@ |
308
|
289 |
1984
|
290 pic/%.o : %.c |
|
291 $(CC) -c $(CPPFLAGS) $(CPICFLAG) $(ALL_CFLAGS) $< -o $@ |
|
292 |
|
293 pic/%.o : %.cc |
|
294 $(CXX) -c $(CPPFLAGS) $(CXXPICFLAG) $(ALL_CXXFLAGS) $< -o $@ |
|
295 |
308
|
296 # Here is a rule for generating dependencies for .cc files: |
|
297 |
1984
|
298 %.d : %.cc |
518
|
299 @echo making $@ from $< |
|
300 @rm -f $@ |
2647
|
301 @$(CXX) -M $(CPPFLAGS) $(ALL_CXXFLAGS) $< | \ |
|
302 sed -e 's,$*\.o,pic/& & $@,g' > $@.tmp |
518
|
303 @mv $@.tmp $@ |
308
|
304 |
|
305 # And one for .c files.too: |
|
306 |
1984
|
307 %.d : %.c |
518
|
308 @echo making $@ from $< |
|
309 @rm -f $@ |
2647
|
310 @$(CC) -M $(CPPFLAGS) $(ALL_CFLAGS) $< | \ |
|
311 sed -e 's,$*\.o,pic/& & $@,g' > $@.tmp |
518
|
312 @mv $@.tmp $@ |
1166
|
313 |
1685
|
314 define do-subdir-for-command |
|
315 echo making $@ in $d; cd $d; $(MAKE) $@; cd ..; |
1166
|
316 endef |
1685
|
317 |
|
318 define subdir-for-command |
|
319 $(foreach d, $(SUBDIRS), $(do-subdir-for-command)) |
|
320 endef |
2157
|
321 |
2862
|
322 # Yes, the second sed command near the end is needed, to avoid limits |
|
323 # in command lengths for some versions of sed. UGLY_DEFS is often |
|
324 # quite large, so it makes sense to split this command there. |
|
325 |
2157
|
326 define do-subst-config-vals |
2223
|
327 echo "making $@ from $<" |
2439
|
328 sed < $< \ |
3584
|
329 -e "s;%OCTAVE_CONF_ALL_CFLAGS%;\"${ALL_CFLAGS}\";" \ |
|
330 -e "s;%OCTAVE_CONF_ALL_CXXFLAGS%;\"${ALL_CXXFLAGS}\";" \ |
|
331 -e "s;%OCTAVE_CONF_ALL_FFLAGS%;\"${ALL_FFLAGS}\";" \ |
|
332 -e "s;%OCTAVE_CONF_ALL_LDFLAGS%;\"${ALL_LDFLAGS}\";" \ |
|
333 -e "s;%OCTAVE_CONF_AR%;\"${AR}\";" \ |
|
334 -e "s;%OCTAVE_CONF_ARFLAGS%;\"${ARFLAGS}\";" \ |
|
335 -e "s;%OCTAVE_CONF_CC%;\"${CC}\";" \ |
|
336 -e "s;%OCTAVE_CONF_CC_VERSION%;\"${CC_VERSION}\";" \ |
|
337 -e "s;%OCTAVE_CONF_CFLAGS%;\"${CFLAGS}\";" \ |
|
338 -e "s;%OCTAVE_CONF_CPICFLAG%;\"${CPICFLAG}\";" \ |
|
339 -e "s;%OCTAVE_CONF_CPPFLAGS%;\"${CPPFLAGS}\";" \ |
|
340 -e "s;%OCTAVE_CONF_CXX%;\"${CXX}\";" \ |
|
341 -e "s;%OCTAVE_CONF_CXXCPP%;\"${CXXCPP}\";" \ |
|
342 -e "s;%OCTAVE_CONF_CXXFLAGS%;\"${CXXFLAGS}\";" \ |
|
343 -e "s;%OCTAVE_CONF_CXXPICFLAG%;\"${CXXPICFLAG}\";" \ |
|
344 -e "s;%OCTAVE_CONF_CXX_VERSION%;\"${CXX_VERSION}\";" \ |
|
345 -e "s;%OCTAVE_CONF_DEFAULT_PAGER%;\"${DEFAULT_PAGER}\";" \ |
|
346 -e "s;%OCTAVE_CONF_DLFCN_INCFLAGS%;\"${DLFCN_INCFLAGS}\";" \ |
|
347 -e "s;%OCTAVE_CONF_EXE%;\"${EXE}\";" \ |
|
348 -e "s;%OCTAVE_CONF_F2C%;\"${F2C}\";" \ |
|
349 -e "s;%OCTAVE_CONF_F2CFLAGS%;\"${F2CFLAGS}\";" \ |
|
350 -e "s;%OCTAVE_CONF_F77%;\"${F77}\";" \ |
|
351 -e "s;%OCTAVE_CONF_FC%;\"${FC}\";" \ |
|
352 -e "s;%OCTAVE_CONF_FFLAGS%;\"${FFLAGS}\";" \ |
|
353 -e "s;%OCTAVE_CONF_FLIBS%;\"${FLIBS}\";" \ |
|
354 -e "s;%OCTAVE_CONF_FORTRAN_MAIN_FLAG%;\"${FORTRAN_MAIN_FLAG}\";" \ |
|
355 -e "s;%OCTAVE_CONF_FPICFLAG%;\"${FPICFLAG}\";" \ |
|
356 -e "s;%OCTAVE_CONF_GLOB_INCFLAGS%;\"${GLOB_INCFLAGS}\";" \ |
|
357 -e "s;%OCTAVE_CONF_INCFLAGS%;\"${INCFLAGS}\";" \ |
|
358 -e "s;%OCTAVE_CONF_LDFLAGS%;\"${LDFLAGS}\";" \ |
|
359 -e "s;%OCTAVE_CONF_LD_STATIC_FLAG%;\"${LD_STATIC_FLAG}\";" \ |
|
360 -e "s;%OCTAVE_CONF_LEX%;\"${LEX}\";" \ |
|
361 -e "s;%OCTAVE_CONF_LEXLIB%;\"${LEXLIB}\";" \ |
|
362 -e "s;%OCTAVE_CONF_LFLAGS%;\"${LFLAGS}\";" \ |
|
363 -e "s;%OCTAVE_CONF_LIBCRUFT%;\"${LIBCRUFT}\";" \ |
|
364 -e "s;%OCTAVE_CONF_LIBDLFCN%;\"${LIBDLFCN}\";" \ |
|
365 -e "s;%OCTAVE_CONF_LIBEXT%;\"${LIBEXT}\";" \ |
|
366 -e "s;%OCTAVE_CONF_LIBFLAGS%;\"${LIBFLAGS}\";" \ |
|
367 -e "s;%OCTAVE_CONF_LIBGLOB%;\"${LIBGLOB}\";" \ |
|
368 -e "s;%OCTAVE_CONF_LIBKPATHSEA%;\"${LIBKPATHSEA}\";" \ |
|
369 -e "s;%OCTAVE_CONF_LIBOCTAVE%;\"${LIBOCTAVE}\";" \ |
|
370 -e "s;%OCTAVE_CONF_LIBOCTINTERP%;\"${LIBOCTINTERP}\";" \ |
|
371 -e "s;%OCTAVE_CONF_LIBPLPLOT%;\"${LIBPLPLOT}\";" \ |
|
372 -e "s;%OCTAVE_CONF_LIBREADLINE%;\"${LIBREADLINE}\";" \ |
|
373 -e "s;%OCTAVE_CONF_LIBS%;\"${LIBS}\";" \ |
|
374 -e "s;%OCTAVE_CONF_LN_S%;\"${LN_S}\";" \ |
3591
|
375 -e "s;%OCTAVE_CONF_MKOCTFILE_INCFLAGS%;\"${MKOCTFILE_INCFLAGS}\";" \ |
3584
|
376 -e "s;%OCTAVE_CONF_OCTAVE_LITE%;\"${OCTAVE_LITE}\";" \ |
|
377 -e "s;%OCTAVE_CONF_RANLIB%;\"${RANLIB}\";" \ |
|
378 -e "s;%OCTAVE_CONF_RDYNAMIC_FLAG%;\"${RDYNAMIC_FLAG}\";" \ |
|
379 -e "s;%OCTAVE_CONF_RLD_FLAG%;\"${RLD_FLAG}\";" \ |
|
380 -e "s;%OCTAVE_CONF_RUNTEST%;\"${RUNTEST}\";" \ |
|
381 -e "s;%OCTAVE_CONF_SHARED_LIBS%;\"${SHARED_LIBS}\";" \ |
|
382 -e "s;%OCTAVE_CONF_SHLEXT%;\"${SHLEXT}\";" \ |
|
383 -e "s;%OCTAVE_CONF_SHLEXT_VER%;\"${SHLEXT_VER}\";" \ |
|
384 -e "s;%OCTAVE_CONF_SH_LD%;\"${SH_LD}\";" \ |
|
385 -e "s;%OCTAVE_CONF_SH_LDFLAGS%;\"${SH_LDFLAGS}\";" \ |
|
386 -e "s;%OCTAVE_CONF_SONAME_FLAGS%;\"${SONAME_FLAGS}\";" \ |
|
387 -e "s;%OCTAVE_CONF_SPECIAL_MATH_LIB%;\"${SPECIAL_MATH_LIB}\";" \ |
|
388 -e "s;%OCTAVE_CONF_STATIC_LIBS%;\"${STATIC_LIBS}\";" \ |
|
389 -e "s;%OCTAVE_CONF_TERMLIBS%;\"${TERMLIBS}\";" \ |
|
390 -e "s;%OCTAVE_CONF_UGLY_DEFS%;\"${UGLY_DEFS}\";" \ |
|
391 -e "s;%OCTAVE_CONF_VERSION%;\"${version}\";" \ |
|
392 -e "s;%OCTAVE_CONF_WITH_DL%;\"${WITH_DL}\";" \ |
|
393 -e "s;%OCTAVE_CONF_WITH_DYNAMIC_LINKING%;\"${WITH_DYNAMIC_LINKING}\";" \ |
|
394 -e "s;%OCTAVE_CONF_WITH_SHL%;\"${WITH_SHL}\";" \ |
|
395 -e "s;%OCTAVE_CONF_XTRA_CFLAGS%;\"${XTRA_CFLAGS}\";" \ |
|
396 -e "s;%OCTAVE_CONF_XTRA_CXXFLAGS%;\"${XTRA_CXXFLAGS}\";" \ |
|
397 -e "s;%OCTAVE_CONF_YACC%;\"${YACC}\";" \ |
|
398 -e "s;%OCTAVE_CONF_YFLAGS%;\"${YFLAGS}\";" \ |
|
399 -e "s;%OCTAVE_CONF_config_opts%;\"${config_opts}\";" | \ |
|
400 sed -e "s;%OCTAVE_CONF_DEFS%;\"${UGLY_DEFS}\";" > $@.tmp |
2157
|
401 $(top_srcdir)/move-if-change $@.tmp $@ |
|
402 endef |
|
403 |
|
404 define do-subst-default-vals |
2223
|
405 echo "making $@ from $<" |
|
406 sed < $< > $@.tmp \ |
2862
|
407 -e "s;%OCTAVE_ARCHLIBDIR%;\"${archlibdir}\";" \ |
|
408 -e "s;%OCTAVE_BINDIR%;\"${bindir}\";" \ |
3584
|
409 -e "s;%OCTAVE_CANONICAL_HOST_TYPE%;\"${canonical_host_type}\";" \ |
2157
|
410 -e "s;%OCTAVE_DATADIR%;\"${datadir}\";" \ |
3584
|
411 -e "s;%OCTAVE_DEFAULT_PAGER%;\"${DEFAULT_PAGER}\";" \ |
2862
|
412 -e "s;%OCTAVE_EXEC_PREFIX%;\"${exec_prefix}\";" \ |
|
413 -e "s;%OCTAVE_FCNFILEDIR%;\"${fcnfiledir}\";" \ |
|
414 -e "s;%OCTAVE_FCNFILEPATH%;\"${fcnfilepath}\";" \ |
3584
|
415 -e "s;%OCTAVE_IMAGEDIR%;\"${imagedir}\";" \ |
2862
|
416 -e "s;%OCTAVE_IMAGEPATH%;\"${imagepath}\";" \ |
3584
|
417 -e "s;%OCTAVE_INCLUDEDIR%;\"${includedir}\";" \ |
2157
|
418 -e "s;%OCTAVE_INFODIR%;\"${infodir}\";" \ |
2512
|
419 -e "s;%OCTAVE_INFOFILE%;\"${infofile}\";" \ |
2862
|
420 -e "s;%OCTAVE_LIBDIR%;\"${libdir}\";" \ |
3584
|
421 -e "s;%OCTAVE_LIBEXECDIR%;\"${libexecdir}\";" \ |
2862
|
422 -e "s;%OCTAVE_LOCALARCHLIBDIR%;\"${localarchlibdir}\";" \ |
2157
|
423 -e "s;%OCTAVE_LOCALFCNFILEDIR%;\"${localfcnfiledir}\";" \ |
|
424 -e "s;%OCTAVE_LOCALFCNFILEPATH%;\"${localfcnfilepath}\";" \ |
3584
|
425 -e "s;%OCTAVE_LOCALOCTFILEDIR%;\"${localoctfiledir}\";" \ |
2862
|
426 -e "s;%OCTAVE_LOCALOCTFILEPATH%;\"${localoctfilepath}\";" \ |
3597
|
427 -e "s;%OCTAVE_LOCALVERARCHLIBDIR%;\"${localverarchlibdir}\";" \ |
|
428 -e "s;%OCTAVE_LOCALVERFCNFILEDIR%;\"${localverfcnfiledir}\";" \ |
|
429 -e "s;%OCTAVE_LOCALVEROCTFILEDIR%;\"${localveroctfiledir}\";" \ |
3584
|
430 -e "s;%OCTAVE_MAN1DIR%;\"${man1dir}\";" \ |
|
431 -e "s;%OCTAVE_MAN1EXT%;\"${man1ext}\";" \ |
|
432 -e "s;%OCTAVE_MANDIR%;\"${mandir}\";" \ |
2157
|
433 -e "s;%OCTAVE_OCTFILEDIR%;\"${octfiledir}\";" \ |
3584
|
434 -e "s;%OCTAVE_OCTINCLUDEDIR%;\"${octincludedir}\";" \ |
|
435 -e "s;%OCTAVE_OCTLIBDIR%;\"${octlibdir}\";" \ |
|
436 -e "s;%OCTAVE_PREFIX%;\"${prefix}\";" |
2157
|
437 $(top_srcdir)/move-if-change $@.tmp $@ |
|
438 endef |
2993
|
439 |
3597
|
440 # Make a relative symbolic link from $includedir/octave to |
|
441 # $octincludedir/octave. |
2993
|
442 |
|
443 # XXX FIXME XXX -- this assumes that $octincludedir is a subdirectory |
|
444 # of $includedir. |
|
445 |
|
446 define mk-includedir-link |
3597
|
447 src=`echo $(octincludedir)/octave | sed 's|^$(includedir)/*||'`; \ |
3029
|
448 echo $$src; \ |
|
449 if [ "$$src" = "octave" ]; then \ |
|
450 true; \ |
2993
|
451 else \ |
3029
|
452 cd $(includedir); \ |
|
453 rm -f octave; \ |
|
454 $(LN_S) $$src octave; \ |
2993
|
455 fi |
|
456 endef |
3141
|
457 |
|
458 # Make a relative symbolic link from $libdir/octave to $octlibdir. |
|
459 |
|
460 # XXX FIXME XXX -- this assumes that $octlibdir is a subdirectory |
|
461 # of $libdir. |
|
462 |
|
463 define mk-libdir-link |
|
464 src=`echo $(octlibdir) | sed 's|^$(libdir)/*||'` ; \ |
|
465 echo $$src ; \ |
|
466 if [ "$$src" = "octave" ] ; then \ |
|
467 true ; \ |
|
468 else \ |
3152
|
469 if [ -d "$(libdir)/octave" ] ; then \ |
|
470 true ; \ |
|
471 else \ |
|
472 cd $(libdir) ; \ |
|
473 rm -f octave ; \ |
|
474 $(LN_S) $$src octave ; \ |
|
475 fi ; \ |
3141
|
476 fi |
|
477 endef |