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