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