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 |
4544
|
12 AWK = @AWK@ |
|
13 export AWK |
|
14 |
4084
|
15 SED = @SED@ |
4299
|
16 export SED |
4084
|
17 |
5465
|
18 PERL = @PERL@ |
5495
|
19 PYTHON = @PYTHON@ |
5465
|
20 |
5468
|
21 DESKTOP_FILE_INSTALL = @DESKTOP_FILE_INSTALL@ |
|
22 |
3029
|
23 # A shell command to extract the version number from version.h. |
4449
|
24 getversion = $(SED) -e '/OCTAVE_VERSION/!d' -e 's/.*"\(.*\)".*$$/\1/' -e q |
|
25 |
|
26 # A shell command to extract the API version number from version.h. |
|
27 getapiversion = $(SED) -e '/OCTAVE_API_VERSION/!d' -e 's/.*"\(.*\)".*$$/\1/' -e q |
3029
|
28 |
|
29 # Look for version.h to get version information. |
|
30 xfiles := $(TOPDIR)/src/version.h $(srcdir)/$(TOPDIR)/src/version.h |
|
31 version_file := $(firstword $(foreach file, $(xfiles), $(wildcard $(file)))) |
|
32 version := $(shell $(getversion) $(version_file)) |
5658
|
33 api_version := $(shell $(getapiversion) $(version_file)) |
3029
|
34 |
5
|
35 #### Start of system configuration section. #### |
|
36 |
3892
|
37 EXEEXT = @EXEEXT@ |
2577
|
38 |
4098
|
39 BUILD_EXEEXT = @BUILD_EXEEXT@ |
|
40 |
5
|
41 LEX = @LEX@ |
|
42 LFLAGS = @LFLAGS@ |
|
43 LEXLIB = @LEXLIB@ |
|
44 |
|
45 YACC = @YACC@ |
|
46 YFLAGS = -dv |
|
47 |
3675
|
48 GPERF = @GPERF@ |
|
49 |
1462
|
50 AR = @AR@ |
|
51 ARFLAGS = @ARFLAGS@ |
|
52 |
3775
|
53 TEMPLATE_AR = @TEMPLATE_AR@ |
|
54 TEMPLATE_ARFLAGS = @TEMPLATE_ARFLAGS@ |
|
55 |
5
|
56 RANLIB = @RANLIB@ |
|
57 |
1722
|
58 LN_S = @LN_S@ |
|
59 |
5
|
60 RUNTEST = @RUNTEST@ |
|
61 |
5934
|
62 MAKEINFO = @MAKEINFO@ |
|
63 TEXI2DVI = @TEXI2DVI@ |
|
64 TEXI2PDF = @TEXI2PDF@ |
|
65 |
|
66 GHOSTSCRIPT = @GHOSTSCRIPT@ |
2518
|
67 |
5
|
68 DEFAULT_PAGER = @DEFAULT_PAGER@ |
|
69 |
4128
|
70 ENABLE_DYNAMIC_LINKING = @ENABLE_DYNAMIC_LINKING@ |
702
|
71 |
3034
|
72 STATIC_LIBS = @STATIC_LIBS@ |
|
73 |
1679
|
74 SHARED_LIBS = @SHARED_LIBS@ |
|
75 SHLEXT = @SHLEXT@ |
4126
|
76 SHLEXT_VER = @SHLEXT_VER@ |
4102
|
77 SHLLIB = @SHLLIB@ |
4627
|
78 SHLLIB_VER = @SHLLIB_VER@ |
4102
|
79 SHLBIN = @SHLBIN@ |
4126
|
80 SHLBIN_VER = @SHLBIN_VER@ |
|
81 SHLLINKEXT= |
4102
|
82 |
3029
|
83 LIBEXT = a |
6051
|
84 LIBPRE = @LIBPRE@ |
1667
|
85 |
5
|
86 # Fortran to C translator and associated flags. |
|
87 |
|
88 F2C = @F2C@ |
|
89 F2CFLAGS = @F2CFLAGS@ |
|
90 |
|
91 # Fortran compiler flags. |
|
92 |
1163
|
93 FC = @FC@ |
798
|
94 F77 = @F77@ |
5
|
95 FFLAGS = @FFLAGS@ |
1832
|
96 FPICFLAG = @FPICFLAG@ |
2610
|
97 ALL_FFLAGS = $(FFLAGS) |
5498
|
98 F77_FLOAT_STORE_FLAG = @F77_FLOAT_STORE_FLAG@ |
5
|
99 |
6102
|
100 F77_TOLOWER=@F77_TOLOWER@ |
|
101 F77_APPEND_UNDERSCORE=@F77_TOLOWER@ |
|
102 F77_APPEND_EXTRA_UNDERSCORE=@F77_TOLOWER@ |
|
103 |
5
|
104 # cc and associated flags. |
|
105 |
2064
|
106 DLFCN_INCFLAGS = @DLFCN_INCFLAGS@ |
|
107 |
236
|
108 # Clean up INCFLAGS a bit if we are not compiling in a separate |
|
109 # directory. |
|
110 ifeq ($(srcdir),.) |
2546
|
111 TMP_IF_1 = -I. |
236
|
112 else |
2546
|
113 TMP_IF_1 = -I. -I$(srcdir) |
236
|
114 endif |
404
|
115 ifeq ($(TOPDIR),$(top_srcdir)) |
5164
|
116 TMP_IF_2 = \ |
|
117 -I$(TOPDIR) \ |
|
118 -I$(TOPDIR)/liboctave \ |
|
119 -I$(TOPDIR)/src \ |
|
120 -I$(TOPDIR)/libcruft/misc |
236
|
121 else |
5164
|
122 TMP_IF_2 = \ |
|
123 -I$(TOPDIR) \ |
|
124 -I$(TOPDIR)/liboctave \ |
|
125 -I$(TOPDIR)/src \ |
|
126 -I$(TOPDIR)/libcruft/misc \ |
|
127 -I$(top_srcdir) \ |
|
128 -I$(top_srcdir)/liboctave \ |
|
129 -I$(top_srcdir)/src \ |
|
130 -I$(top_srcdir)/libcruft/misc |
236
|
131 endif |
5169
|
132 INCFLAGS = $(TMP_IF_1) $(TMP_IF_2) $(DLFCN_INCFLAGS) |
236
|
133 |
5
|
134 LIBFLAGS = -L$(TOPDIR) |
236
|
135 |
5
|
136 DEFS = @DEFS@ |
|
137 |
2032
|
138 UGLY_DEFS = @UGLY_DEFS@ |
|
139 |
5
|
140 CC = @CC@ |
1891
|
141 CC_VERSION = @CC_VERSION@ |
5
|
142 CFLAGS = @CFLAGS@ |
1832
|
143 CPICFLAG = @CPICFLAG@ |
3126
|
144 XTRA_CFLAGS = @XTRA_CFLAGS@ |
4626
|
145 WARN_CFLAGS = @WARN_CFLAGS@ |
6087
|
146 ALL_CFLAGS = $(INCFLAGS) $(XTRA_CDEFS) $(DEFS) $(XTRA_CFLAGS) $(WARN_CFLAGS) $(CFLAGS) |
4626
|
147 BUG_CFLAGS = $(DEFS) $(XTRA_CFLAGS) $(WARN_CFLAGS) $(CFLAGS) |
798
|
148 |
4094
|
149 BUILD_CC = @BUILD_CC@ |
|
150 BUILD_CFLAGS = @BUILD_CFLAGS@ |
4093
|
151 |
3775
|
152 DEPEND_FLAGS = @DEPEND_FLAGS@ |
|
153 DEPEND_EXTRA_SED_PATTERN = @DEPEND_EXTRA_SED_PATTERN@ |
6087
|
154 INCLUDE_DEPS = @INCLUDE_DEPS@ |
|
155 ifeq ($(INCLUDE_DEPS),false) |
|
156 omit_deps = true; |
|
157 endif |
3775
|
158 |
198
|
159 CXX = @CXX@ |
1891
|
160 CXX_VERSION = @CXX_VERSION@ |
518
|
161 CXXCPP = @CXXCPP@ |
198
|
162 CXXFLAGS = @CXXFLAGS@ |
1832
|
163 CXXPICFLAG = @CXXPICFLAG@ |
3126
|
164 XTRA_CXXFLAGS = @XTRA_CXXFLAGS@ |
4626
|
165 WARN_CXXFLAGS = @WARN_CXXFLAGS@ |
|
166 ALL_CXXFLAGS = \ |
6087
|
167 $(INCFLAGS) $(XTRA_CXXDEFS) $(DEFS) $(XTRA_CXXFLAGS) $(WARN_CXXFLAGS) $(CXXFLAGS) |
4626
|
168 BUG_CXXFLAGS = $(DEFS) $(XTRA_CXXFLAGS) $(WARN_CXXFLAGS) $(CXXFLAGS) |
5
|
169 |
4094
|
170 BUILD_CXX = @BUILD_CXX@ |
|
171 BUILD_CXXFLAGS = @BUILD_CXXFLAGS@ |
4093
|
172 |
858
|
173 CPPFLAGS = @CPPFLAGS@ |
|
174 |
3705
|
175 LD_CXX = @LD_CXX@ |
5
|
176 LDFLAGS = @LDFLAGS@ |
708
|
177 LD_STATIC_FLAG = @LD_STATIC_FLAG@ |
3887
|
178 ALL_LDFLAGS = $(LIBFLAGS) $(LD_STATIC_FLAG) $(CPICFLAG) $(LDFLAGS) |
5
|
179 |
4298
|
180 BUILD_LDFLAGS = @BUILD_LDFLAGS@ |
|
181 |
2676
|
182 SH_LD = @SH_LD@ |
|
183 SH_LDFLAGS = @SH_LDFLAGS@ |
|
184 |
4759
|
185 DL_LD = @DL_LD@ |
|
186 DL_LDFLAGS = @DL_LDFLAGS@ |
|
187 |
3036
|
188 SONAME_FLAGS = @SONAME_FLAGS@ |
|
189 |
3233
|
190 RDYNAMIC_FLAG = @RDYNAMIC_FLAG@ |
|
191 |
2674
|
192 RLD_FLAG = @RLD_FLAG@ |
|
193 |
5
|
194 FLIBS = @FLIBS@ |
708
|
195 |
2930
|
196 LIBDLFCN = @LIBDLFCN@ |
5451
|
197 LIBGLOB = @LIBGLOB@ |
3156
|
198 LIBOCTINTERP = @LIBOCTINTERP@ |
|
199 LIBOCTAVE = @LIBOCTAVE@ |
|
200 LIBCRUFT = @LIBCRUFT@ |
4102
|
201 LIBREADLINE = @LIBREADLINE@ |
|
202 TERMLIBS = @TERMLIBS@ |
3726
|
203 |
5585
|
204 REGEX_LIBS = @REGEX_LIBS@ |
3726
|
205 BLAS_LIBS = @BLAS_LIBS@ |
3827
|
206 FFTW_LIBS = @FFTW_LIBS@ |
5235
|
207 GLPK_LIBS = @GLPK_LIBS@ |
6043
|
208 CURL_LIBS = @CURL_LIBS@ |
5451
|
209 AMD_LIBS = @AMD_LIBS@ |
6024
|
210 CAMD_LIBS = @CAMD_LIBS@ |
5270
|
211 UMFPACK_LIBS = @UMFPACK_LIBS@ |
5451
|
212 COLAMD_LIBS = @COLAMD_LIBS@ |
|
213 CCOLAMD_LIBS = @CCOLAMD_LIBS@ |
|
214 CHOLMOD_LIBS = @CHOLMOD_LIBS@ |
5610
|
215 CXSPARSE_LIBS = @CXSPARSE_LIBS@ |
3726
|
216 LIBS = @LIBS@ |
5
|
217 |
5275
|
218 USE_64_BIT_IDX_T = @USE_64_BIT_IDX_T@ |
|
219 |
5708
|
220 TEXINFO_COLAMD = @TEXINFO_COLAMD@ |
|
221 TEXINFO_CHOLMOD = @TEXINFO_CHOLMOD@ |
|
222 TEXINFO_UMFPACK = @TEXINFO_UMFPACK@ |
|
223 |
2155
|
224 # The arguments passed to configure. |
2156
|
225 config_opts = @config_opts@ |
2155
|
226 |
666
|
227 # ==================== Where To Install Things ==================== |
5
|
228 |
666
|
229 # The default location for installation. Everything is placed in |
|
230 # subdirectories of this directory. The default values for many of |
|
231 # the variables below are expressed in terms of this one, so you may |
|
232 # not need to change them. This defaults to /usr/local. |
|
233 prefix = @prefix@ |
5
|
234 |
666
|
235 # Like `prefix', but used for architecture-specific files. |
|
236 exec_prefix = @exec_prefix@ |
|
237 |
|
238 # Where to install Octave and other binaries that people will want to |
|
239 # run directly. |
|
240 bindir = @bindir@ |
5
|
241 |
4411
|
242 # Normally the directory for installing executables that system |
|
243 # administrators run. This is the same as libexecdir on Cygwin systems. |
|
244 sbindir = @sbindir@ |
|
245 |
5844
|
246 # The root of the directory tree for read-only |
|
247 # architecture-independent data files. |
|
248 datarootdir = @datarootdir@ |
|
249 |
666
|
250 # Where to install architecture-independent data files. ${fcnfiledir} |
|
251 # and ${localfcnfiledir} are subdirectories of this. |
|
252 datadir = @datadir@ |
5
|
253 |
3141
|
254 libdir = @libdir@ |
|
255 |
666
|
256 # Where to install and expect libraries like libcruft.a, liboctave.a, |
3141
|
257 # and other architecture-dependent data. |
|
258 octlibdir = @octlibdir@ |
5
|
259 |
1720
|
260 # Where to install and expect executable programs to be run by Octave |
|
261 # rather than directly by users. |
|
262 libexecdir = @libexecdir@ |
|
263 |
2141
|
264 # The prefix for Octave's include file directory. The default is |
|
265 # ${prefix}/include |
2223
|
266 includedir = @includedir@ |
2141
|
267 |
666
|
268 # Where to install Octave's man pages, and what extension they should |
|
269 # have. The default is ${prefix}/man/man1 |
|
270 mandir = @mandir@ |
2223
|
271 man1dir = @man1dir@ |
|
272 man1ext = @man1ext@ |
5
|
273 |
666
|
274 # Where to install and expect the info files describing Octave.. |
|
275 infodir = @infodir@ |
|
276 |
2512
|
277 # The fill path to the default info file. |
|
278 infofile = @infofile@ |
|
279 |
666
|
280 # ==================== Octave-specific directories ==================== |
|
281 |
2993
|
282 # These variables hold the values specific to Octave. They are |
666
|
283 # based on the values of the standard Make variables above. |
|
284 |
5451
|
285 # What is the path separation character |
|
286 sepchar = @sepchar@ |
|
287 |
3597
|
288 # Where to install Octave's include files (they will actually be |
|
289 # installed in a subdirectory called octave). The default is |
2993
|
290 # ${includedir}/octave-${version} |
|
291 octincludedir = @octincludedir@ |
|
292 |
666
|
293 # Where to install the function file distributed with |
|
294 # Octave. This includes the Octave version, so that the |
|
295 # function files for different versions of Octave will install |
|
296 # themselves in separate directories. |
|
297 fcnfiledir = @fcnfiledir@ |
|
298 |
|
299 # Directories Octave should search for function files specific |
|
300 # to this site (i.e. customizations), before consulting |
|
301 # ${fcnfiledir}. This should be a colon-separated list of |
|
302 # directories. |
827
|
303 localfcnfiledir = @localfcnfiledir@ |
4449
|
304 localapifcnfiledir = @localapifcnfiledir@ |
3597
|
305 localverfcnfiledir = @localverfcnfiledir@ |
5
|
306 |
666
|
307 # Where to put executables to be run by Octave rather than |
|
308 # the user. This path usually includes the Octave version |
|
309 # and configuration name, so that multiple configurations |
|
310 # for multiple versions of Octave may be installed at once. |
|
311 archlibdir = @archlibdir@ |
|
312 |
2439
|
313 # Where to put executables to be run by Octave rather than by the |
|
314 # user that are specific to this site. |
|
315 localarchlibdir = @localarchlibdir@ |
5909
|
316 localapiarchlibdir = @localapiarchlibdir@ |
3597
|
317 localverarchlibdir = @localverarchlibdir@ |
2439
|
318 |
666
|
319 # Where to put object files that will by dynamically loaded. |
|
320 # This path usually includes the Octave version and configuration |
|
321 # name, so that multiple configurations for multiple versions of |
|
322 # Octave may be installed at once. |
|
323 octfiledir = @octfiledir@ |
5
|
324 |
666
|
325 # Directories Octave should search for object files that will be |
|
326 # dynamically loaded and that are specific to this site |
|
327 # (i.e. customizations), before consulting ${octfiledir}. This should |
|
328 # be a colon-separated list of directories. |
827
|
329 localoctfiledir = @localoctfiledir@ |
4449
|
330 localapioctfiledir = @localapioctfiledir@ |
3597
|
331 localveroctfiledir = @localveroctfiledir@ |
666
|
332 |
5814
|
333 # Where Octave will search to find image files. |
827
|
334 imagedir = @imagedir@ |
685
|
335 |
5
|
336 # The type of computer we are running on. |
3136
|
337 canonical_host_type = @canonical_host_type@ |
5
|
338 |
4443
|
339 # Where Octave will look for startup files |
|
340 startupfiledir = ${fcnfiledir}/startup |
|
341 localstartupfiledir = ${localfcnfiledir}/startup |
|
342 |
6028
|
343 # LD_LIBRARY_PATH, DYLD_LIBRARY_PATH, PATH, ... |
|
344 library_path_var = @library_path_var@ |
|
345 |
3591
|
346 # The -I flags to use for the mkoctfile script. |
4302
|
347 ifeq ($(includedir),/usr/include) |
4301
|
348 MKOCTFILE_INCFLAGS = \ |
|
349 -I$(octincludedir) -I$(octincludedir)/octave |
|
350 else |
|
351 MKOCTFILE_INCFLAGS = \ |
|
352 -I$(octincludedir) -I$(octincludedir)/octave -I$(includedir) |
|
353 endif |
3591
|
354 |
3859
|
355 # The -L flags to use for the mkoctfile scrip (for --link-stand-alone) |
|
356 MKOCTFILE_LFLAGS = -L$(octlibdir) |
|
357 |
4761
|
358 MKOCTFILE_DL_LDFLAGS = @MKOCTFILE_DL_LDFLAGS@ |
4199
|
359 |
|
360 NO_OCT_FILE_STRIP = @NO_OCT_FILE_STRIP@ |
|
361 |
5
|
362 # The following pattern rules and the substitution functions require |
|
363 # GNU make. If you don't have it, get it! |
|
364 |
1679
|
365 # Rules for making object files from Fortran source. |
994
|
366 # |
|
367 # If we are using f2c there will be a command for the `%.c : %.f' |
|
368 # pattern and no command for the `%.o : %.f' pattern, so that make |
|
369 # will not invoke the fortran compiler by mistake. |
|
370 # |
|
371 # If we are not using f2c, it should be ok to have an empty rule for |
|
372 # the pattern `%.c : %.f', but we don't want to replace make's default |
|
373 # rule for making object from Fortran source files, so there should be |
|
374 # no pattern or command for that. |
5
|
375 |
1679
|
376 @f77_rules_frag@ |
994
|
377 |
1668
|
378 # How to make .o files: |
5
|
379 |
1984
|
380 %.o : %.c |
3615
|
381 $(CC) -c $(CPPFLAGS) $(ALL_CFLAGS) $< -o $@ |
5
|
382 |
1984
|
383 %.o : %.cc |
3615
|
384 $(CXX) -c $(CPPFLAGS) $(ALL_CXXFLAGS) $< -o $@ |
308
|
385 |
1984
|
386 pic/%.o : %.c |
|
387 $(CC) -c $(CPPFLAGS) $(CPICFLAG) $(ALL_CFLAGS) $< -o $@ |
|
388 |
|
389 pic/%.o : %.cc |
|
390 $(CXX) -c $(CPPFLAGS) $(CXXPICFLAG) $(ALL_CXXFLAGS) $< -o $@ |
|
391 |
308
|
392 # Here is a rule for generating dependencies for .cc files: |
|
393 |
1984
|
394 %.d : %.cc |
518
|
395 @echo making $@ from $< |
|
396 @rm -f $@ |
3775
|
397 @$(CXX) $(DEPEND_FLAGS) $(CPPFLAGS) $(ALL_CXXFLAGS) $< | \ |
4084
|
398 $(SED) \ |
3775
|
399 $(DEPEND_EXTRA_SED_PATTERN) \ |
|
400 -e 's,^[^:]*/\(.*\.o\):,\1:,' \ |
4050
|
401 -e 's,$*\.o,pic/& & $*.df $@,g' > $@-t |
4014
|
402 @mv $@-t $@ |
308
|
403 |
|
404 # And one for .c files.too: |
|
405 |
1984
|
406 %.d : %.c |
518
|
407 @echo making $@ from $< |
|
408 @rm -f $@ |
3775
|
409 @$(CC) $(DEPEND_FLAGS) $(CPPFLAGS) $(ALL_CFLAGS) $< | \ |
4084
|
410 $(SED) \ |
3775
|
411 $(DEPEND_EXTRA_SED_PATTERN) \ |
|
412 -e 's,^[^:]*/\(.*\.o\):,\1:,' \ |
4014
|
413 -e 's,$*\.o,pic/& & $@,g' > $@-t |
|
414 @mv $@-t $@ |
1166
|
415 |
1685
|
416 define do-subdir-for-command |
4414
|
417 echo making $@ in $d; $(MAKE) -C $d $@; |
1166
|
418 endef |
1685
|
419 |
|
420 define subdir-for-command |
|
421 $(foreach d, $(SUBDIRS), $(do-subdir-for-command)) |
|
422 endef |
2157
|
423 |
2862
|
424 # Yes, the second sed command near the end is needed, to avoid limits |
|
425 # in command lengths for some versions of sed. UGLY_DEFS is often |
|
426 # quite large, so it makes sense to split this command there. |
|
427 |
2157
|
428 define do-subst-config-vals |
2223
|
429 echo "making $@ from $<" |
4084
|
430 $(SED) < $< \ |
5451
|
431 -e "s|%NO_OCT_FILE_STRIP%|${NO_OCT_FILE_STRIP}|" \ |
|
432 -e "s|%OCTAVE_BINDIR%|\"${bindir}\"|" \ |
|
433 -e "s|%OCTAVE_CONF_ALL_CFLAGS%|\"${ALL_CFLAGS}\"|" \ |
|
434 -e "s|%OCTAVE_CONF_ALL_CXXFLAGS%|\"${ALL_CXXFLAGS}\"|" \ |
|
435 -e "s|%OCTAVE_CONF_ALL_FFLAGS%|\"${ALL_FFLAGS}\"|" \ |
|
436 -e "s|%OCTAVE_CONF_ALL_LDFLAGS%|\"${ALL_LDFLAGS}\"|" \ |
|
437 -e "s|%OCTAVE_CONF_AR%|\"${AR}\"|" \ |
|
438 -e "s|%OCTAVE_CONF_ARFLAGS%|\"${ARFLAGS}\"|" \ |
|
439 -e "s|%OCTAVE_CONF_BLAS_LIBS%|\"${BLAS_LIBS}\"|" \ |
|
440 -e "s|%OCTAVE_CONF_CANONICAL_HOST_TYPE%|\"${canonical_host_type}\"|" \ |
|
441 -e "s|%OCTAVE_CONF_CC%|\"${CC}\"|" \ |
|
442 -e "s|%OCTAVE_CONF_CC_VERSION%|\"${CC_VERSION}\"|" \ |
|
443 -e "s|%OCTAVE_CONF_CFLAGS%|\"${CFLAGS}\"|" \ |
|
444 -e "s|%OCTAVE_CONF_CPICFLAG%|\"${CPICFLAG}\"|" \ |
|
445 -e "s|%OCTAVE_CONF_CPPFLAGS%|\"${CPPFLAGS}\"|" \ |
6043
|
446 -e "s|%OCTAVE_CONF_CURL_LIBS%|\"${CURL_LIBS}\"|" \ |
5451
|
447 -e "s|%OCTAVE_CONF_CXX%|\"${CXX}\"|" \ |
|
448 -e "s|%OCTAVE_CONF_CXXCPP%|\"${CXXCPP}\"|" \ |
|
449 -e "s|%OCTAVE_CONF_CXXFLAGS%|\"${CXXFLAGS}\"|" \ |
|
450 -e "s|%OCTAVE_CONF_CXXPICFLAG%|\"${CXXPICFLAG}\"|" \ |
|
451 -e "s|%OCTAVE_CONF_CXX_VERSION%|\"${CXX_VERSION}\"|" \ |
|
452 -e "s|%OCTAVE_CONF_DEFAULT_PAGER%|\"${DEFAULT_PAGER}\"|" \ |
|
453 -e "s|%OCTAVE_CONF_DEPEND_FLAGS%|\"${DEPEND_FLAGS}\"|" \ |
|
454 -e "s|%OCTAVE_CONF_DEPEND_EXTRA_SED_PATTERN%|\"${DEPEND_EXTRA_SED_PATTERN}\"|" \ |
|
455 -e "s|%OCTAVE_CONF_DLFCN_INCFLAGS%|\"${DLFCN_INCFLAGS}\"|" \ |
|
456 -e "s|%OCTAVE_CONF_DL_LD%|\"${DL_LD}\"|" \ |
|
457 -e "s|%OCTAVE_CONF_DL_LDFLAGS%|\"${DL_LDFLAGS}\"|" \ |
|
458 -e "s|%OCTAVE_CONF_EXEEXT%|\"${EXEEXT}\"|" \ |
|
459 -e "s|%OCTAVE_CONF_F2C%|\"${F2C}\"|" \ |
|
460 -e "s|%OCTAVE_CONF_F2CFLAGS%|\"${F2CFLAGS}\"|" \ |
|
461 -e "s|%OCTAVE_CONF_F77%|\"${F77}\"|" \ |
5498
|
462 -e "s|%OCTAVE_CONF_F77_FLOAT_STORE_FLAG%|\"${F77_FLOAT_STORE_FLAG}\"|" \ |
5451
|
463 -e "s|%OCTAVE_CONF_FC%|\"${FC}\"|" \ |
|
464 -e "s|%OCTAVE_CONF_FFLAGS%|\"${FFLAGS}\"|" \ |
|
465 -e "s|%OCTAVE_CONF_FFTW_LIBS%|\"${FFTW_LIBS}\"|" \ |
|
466 -e "s|%OCTAVE_CONF_FLIBS%|\"${FLIBS}\"|" \ |
|
467 -e "s|%OCTAVE_CONF_FPICFLAG%|\"${FPICFLAG}\"|" \ |
|
468 -e "s|%OCTAVE_CONF_GLPK_LIBS%|\"${GLPK_LIBS}\"|" \ |
|
469 -e "s|%OCTAVE_CONF_INCFLAGS%|\"${INCFLAGS}\"|" \ |
|
470 -e "s|%OCTAVE_CONF_LD_CXX%|\"${LD_CXX}\"|" \ |
|
471 -e "s|%OCTAVE_CONF_LDFLAGS%|\"${LDFLAGS}\"|" \ |
|
472 -e "s|%OCTAVE_CONF_LD_STATIC_FLAG%|\"${LD_STATIC_FLAG}\"|" \ |
|
473 -e "s|%OCTAVE_CONF_LEX%|\"${LEX}\"|" \ |
|
474 -e "s|%OCTAVE_CONF_LEXLIB%|\"${LEXLIB}\"|" \ |
|
475 -e "s|%OCTAVE_CONF_LFLAGS%|\"${LFLAGS}\"|" \ |
|
476 -e "s|%OCTAVE_CONF_LIBCRUFT%|\"${LIBCRUFT}\"|" \ |
|
477 -e "s|%OCTAVE_CONF_LIBDLFCN%|\"${LIBDLFCN}\"|" \ |
|
478 -e "s|%OCTAVE_CONF_LIBEXT%|\"${LIBEXT}\"|" \ |
|
479 -e "s|%OCTAVE_CONF_LIBFLAGS%|\"${LIBFLAGS}\"|" \ |
|
480 -e "s|%OCTAVE_CONF_LIBGLOB%|\"${LIBGLOB}\"|" \ |
|
481 -e "s|%OCTAVE_CONF_LIBOCTAVE%|\"${LIBOCTAVE}\"|" \ |
|
482 -e "s|%OCTAVE_CONF_LIBOCTINTERP%|\"${LIBOCTINTERP}\"|" \ |
|
483 -e "s|%OCTAVE_CONF_LIBREADLINE%|\"${LIBREADLINE}\"|" \ |
|
484 -e "s|%OCTAVE_CONF_LIBS%|\"${LIBS}\"|" \ |
|
485 -e "s|%OCTAVE_CONF_LN_S%|\"${LN_S}\"|" \ |
|
486 -e "s|%OCTAVE_CONF_MKOCTFILE_DL_LDFLAGS%|\"${MKOCTFILE_DL_LDFLAGS}\"|" \ |
|
487 -e "s|%OCTAVE_CONF_MKOCTFILE_INCFLAGS%|\"${MKOCTFILE_INCFLAGS}\"|" \ |
|
488 -e "s|%OCTAVE_CONF_MKOCTFILE_LFLAGS%|\"${MKOCTFILE_LFLAGS}\"|" \ |
|
489 -e "s|%OCTAVE_CONF_RANLIB%|\"${RANLIB}\"|" \ |
|
490 -e "s|%OCTAVE_CONF_RDYNAMIC_FLAG%|\"${RDYNAMIC_FLAG}\"|" \ |
|
491 -e "s|%OCTAVE_CONF_RLD_FLAG%|\"${RLD_FLAG}\"|" \ |
|
492 -e "s|%OCTAVE_CONF_RUNTEST%|\"${RUNTEST}\"|" \ |
|
493 -e "s|%OCTAVE_CONF_SED%|\"${SED}\"|" \ |
|
494 -e "s|%OCTAVE_CONF_SHARED_LIBS%|\"${SHARED_LIBS}\"|" \ |
|
495 -e "s|%OCTAVE_CONF_SHLEXT%|\"${SHLEXT}\"|" \ |
|
496 -e "s|%OCTAVE_CONF_SHLLINKEXT%|\"${SHLLINKEXT}\"|" \ |
|
497 -e "s|%OCTAVE_CONF_SHLEXT_VER%|\"${SHLEXT_VER}\"|" \ |
|
498 -e "s|%OCTAVE_CONF_SH_LD%|\"${SH_LD}\"|" \ |
|
499 -e "s|%OCTAVE_CONF_SH_LDFLAGS%|\"${SH_LDFLAGS}\"|" \ |
|
500 -e "s|%OCTAVE_CONF_SONAME_FLAGS%|\"${SONAME_FLAGS}\"|" \ |
|
501 -e "s|%OCTAVE_CONF_STATIC_LIBS%|\"${STATIC_LIBS}\"|" \ |
|
502 -e "s|%OCTAVE_CONF_UGLY_DEFS%|\"${UGLY_DEFS}\"|" \ |
|
503 -e "s|%OCTAVE_CONF_USE_64_BIT_IDX_T%|\"${USE_64_BIT_IDX_T}\"|" \ |
|
504 -e "s|%OCTAVE_CONF_VERSION%|\"${version}\"|" \ |
|
505 -e "s|%OCTAVE_CONF_ENABLE_DYNAMIC_LINKING%|\"${ENABLE_DYNAMIC_LINKING}\"|" \ |
|
506 -e "s|%OCTAVE_CONF_XTRA_CFLAGS%|\"${XTRA_CFLAGS}\"|" \ |
|
507 -e "s|%OCTAVE_CONF_XTRA_CXXFLAGS%|\"${XTRA_CXXFLAGS}\"|" \ |
|
508 -e "s|%OCTAVE_CONF_YACC%|\"${YACC}\"|" \ |
|
509 -e "s|%OCTAVE_CONF_YFLAGS%|\"${YFLAGS}\"|" \ |
|
510 -e "s|%OCTAVE_CONF_config_opts%|\"${config_opts}\"|" | \ |
|
511 $(SED) -e "s|%OCTAVE_CONF_DEFS%|\"${UGLY_DEFS}\"|" > $@-t |
4014
|
512 $(top_srcdir)/move-if-change $@-t $@ |
2157
|
513 endef |
|
514 |
|
515 define do-subst-default-vals |
2223
|
516 echo "making $@ from $<" |
4084
|
517 $(SED) < $< > $@-t \ |
5451
|
518 -e "s|%OCTAVE_ARCHLIBDIR%|\"${archlibdir}\"|" \ |
|
519 -e "s|%OCTAVE_BINDIR%|\"${bindir}\"|" \ |
|
520 -e "s|%OCTAVE_CANONICAL_HOST_TYPE%|\"${canonical_host_type}\"|" \ |
|
521 -e "s|%OCTAVE_DATADIR%|\"${datadir}\"|" \ |
5847
|
522 -e "s|%OCTAVE_DATAROOTDIR%|\"${datarootdir}\"|" \ |
5451
|
523 -e "s|%OCTAVE_DEFAULT_PAGER%|\"${DEFAULT_PAGER}\"|" \ |
|
524 -e "s|%OCTAVE_EXEC_PREFIX%|\"${exec_prefix}\"|" \ |
|
525 -e "s|%OCTAVE_FCNFILEDIR%|\"${fcnfiledir}\"|" \ |
|
526 -e "s|%OCTAVE_IMAGEDIR%|\"${imagedir}\"|" \ |
|
527 -e "s|%OCTAVE_INCLUDEDIR%|\"${includedir}\"|" \ |
|
528 -e "s|%OCTAVE_INFODIR%|\"${infodir}\"|" \ |
|
529 -e "s|%OCTAVE_INFOFILE%|\"${infofile}\"|" \ |
|
530 -e "s|%OCTAVE_LIBDIR%|\"${libdir}\"|" \ |
|
531 -e "s|%OCTAVE_LIBEXECDIR%|\"${libexecdir}\"|" \ |
|
532 -e "s|%OCTAVE_LOCALAPIFCNFILEDIR%|\"${localapifcnfiledir}\"|" \ |
|
533 -e "s|%OCTAVE_LOCALAPIOCTFILEDIR%|\"${localapioctfiledir}\"|" \ |
|
534 -e "s|%OCTAVE_LOCALARCHLIBDIR%|\"${localarchlibdir}\"|" \ |
|
535 -e "s|%OCTAVE_LOCALFCNFILEDIR%|\"${localfcnfiledir}\"|" \ |
|
536 -e "s|%OCTAVE_LOCALOCTFILEDIR%|\"${localoctfiledir}\"|" \ |
|
537 -e "s|%OCTAVE_LOCALSTARTUPFILEDIR%|\"${localstartupfiledir}\"|" \ |
5909
|
538 -e "s|%OCTAVE_LOCALAPIARCHLIBDIR%|\"${localapiarchlibdir}\"|" \ |
5451
|
539 -e "s|%OCTAVE_LOCALVERARCHLIBDIR%|\"${localverarchlibdir}\"|" \ |
|
540 -e "s|%OCTAVE_LOCALVERFCNFILEDIR%|\"${localverfcnfiledir}\"|" \ |
|
541 -e "s|%OCTAVE_LOCALVEROCTFILEDIR%|\"${localveroctfiledir}\"|" \ |
|
542 -e "s|%OCTAVE_MAN1DIR%|\"${man1dir}\"|" \ |
|
543 -e "s|%OCTAVE_MAN1EXT%|\"${man1ext}\"|" \ |
|
544 -e "s|%OCTAVE_MANDIR%|\"${mandir}\"|" \ |
|
545 -e "s|%OCTAVE_OCTFILEDIR%|\"${octfiledir}\"|" \ |
|
546 -e "s|%OCTAVE_OCTINCLUDEDIR%|\"${octincludedir}\"|" \ |
|
547 -e "s|%OCTAVE_OCTLIBDIR%|\"${octlibdir}\"|" \ |
|
548 -e "s|%OCTAVE_STARTUPFILEDIR%|\"${startupfiledir}\"|" \ |
|
549 -e "s|%OCTAVE_PREFIX%|\"${prefix}\"|" \ |
5658
|
550 -e "s|%OCTAVE_API_VERSION%|\"${api_version}\"|" \ |
|
551 -e "s|%OCTAVE_RELEASE%|\"${OCTAVE_RELEASE}\"|" \ |
5451
|
552 -e "s|%OCTAVE_VERSION%|\"${version}\"|" |
4014
|
553 $(top_srcdir)/move-if-change $@-t $@ |
2157
|
554 endef |
4227
|
555 |
5708
|
556 define do-subst-texinfo-vals |
|
557 echo "making $@ from $<" |
|
558 $(SED) < $< \ |
|
559 -e "s|%OCTAVE_HOME%|${prefix}|" \ |
|
560 -e "s|%OCTAVE_VERSION%|${version}|" \ |
|
561 -e "s|%TEXINFO_COLAMD%|${TEXINFO_COLAMD}|" \ |
|
562 -e "s|%TEXINFO_CHOLMOD%|${TEXINFO_CHOLMOD}|" \ |
|
563 -e "s|%TEXINFO_UMFPACK%|${TEXINFO_UMFPACK}|" | \ |
5942
|
564 $(SED) -e "s|%OCTAVE_CONF_DEFS%|\"${UGLY_DEFS}\"|" > $@-t |
5708
|
565 $(top_srcdir)/move-if-change $@-t $@ |
|
566 endef |
|
567 |
5776
|
568 define do-subst-script-vals |
|
569 echo "making $@ from $<" |
|
570 $(SED) < $< \ |
6028
|
571 -e "s|%library_path_var%|${library_path_var}|g" \ |
5776
|
572 -e "s|%srcdir%|${srcdir}|" \ |
|
573 -e "s|%top_srcdir%|${top_srcdir}|" \ |
5793
|
574 -e "s|%abs_top_srcdir%|${abs_top_srcdir}|" \ |
5776
|
575 -e "s|%builddir%|$(shell pwd)|" > $@-t |
|
576 $(top_srcdir)/move-if-change $@-t $@ |
|
577 endef |
|
578 |
6102
|
579 define do-subst-f77-mangling |
|
580 echo "making $@ from $<" |
|
581 $(SED) < $< \ |
|
582 -e "s|%F77_TOLOWER%|${F77_TOLOWER}|g" \ |
|
583 -e "s|%F77_APPEND_UNDERSCORE%|${F77_APPEND_UNDERSCORE}|" \ |
|
584 -e "s|%F77_APPEND_EXTRA_UNDERSCORE%|${F77_APPEND_EXTRA_UNDERSCORE}|" > $@-t |
|
585 $(top_srcdir)/move-if-change $@-t $@ |
|
586 endef |
|
587 |
5597
|
588 define do-mkpkgadd |
|
589 $(top_srcdir)/mkpkgadd $(srcdir) > PKG_ADD.t |
|
590 if [ -n "`cat PKG_ADD.t`" ]; then \ |
|
591 mv PKG_ADD.t PKG_ADD ; \ |
|
592 else \ |
|
593 rm -f PKG_ADD.t ; \ |
|
594 fi |
|
595 endef |
|
596 |
4227
|
597 define do-script-install |
4413
|
598 $(top_srcdir)/mkinstalldirs \ |
|
599 $(addprefix $(DESTDIR), $(fcnfiledir)/$(script_sub_dir)) |
4227
|
600 for f in $(FCN_FILES_NO_DIR); do \ |
4413
|
601 rm -f $(DESTDIR)$(fcnfiledir)/$(script_sub_dir)/$$f; \ |
|
602 $(INSTALL_DATA) $(srcdir)/$$f $(DESTDIR)$(fcnfiledir)/$(script_sub_dir)/$$f; \ |
4227
|
603 done |
4413
|
604 $(top_srcdir)/mkpkgadd $(DESTDIR)$(fcnfiledir)/$(script_sub_dir) > $(DESTDIR)$(fcnfiledir)/$(script_sub_dir)/PKG_ADD.t |
|
605 if [ -n "`cat $(DESTDIR)$(fcnfiledir)/$(script_sub_dir)/PKG_ADD.t`" ]; then \ |
|
606 mv $(DESTDIR)$(fcnfiledir)/$(script_sub_dir)/PKG_ADD.t $(DESTDIR)$(fcnfiledir)/$(script_sub_dir)/PKG_ADD ; \ |
4227
|
607 else \ |
4413
|
608 rm -f $(DESTDIR)$(fcnfiledir)/$(script_sub_dir)/PKG_ADD.t ; \ |
4227
|
609 fi |
|
610 endef |
|
611 |
|
612 define do-script-uninstall |
|
613 for f in $(FCN_FILES_NO_DIR); \ |
4413
|
614 do rm -f $(DESTDIR)$(fcnfiledir)/$(script_sub_dir)/$$f; \ |
4227
|
615 done |
|
616 endef |