Commit | Line | Data |
---|---|---|
733943b9 | 1 | ## Process this file with Automake to create Makefile.in |
2764bd99 | 2 | ## |
79488112 | 3 | ## Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc. |
2764bd99 JB |
4 | ## |
5 | ## This file is part of GUILE. | |
54f16aec | 6 | ## |
53befeb7 NJ |
7 | ## GUILE is free software; you can redistribute it and/or modify it |
8 | ## under the terms of the GNU Lesser General Public License as | |
9 | ## published by the Free Software Foundation; either version 3, or | |
2764bd99 | 10 | ## (at your option) any later version. |
54f16aec | 11 | ## |
2764bd99 JB |
12 | ## GUILE is distributed in the hope that it will be useful, but |
13 | ## WITHOUT ANY WARRANTY; without even the implied warranty of | |
14 | ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
53befeb7 | 15 | ## GNU Lesser General Public License for more details. |
54f16aec | 16 | ## |
53befeb7 NJ |
17 | ## You should have received a copy of the GNU Lesser General Public |
18 | ## License along with GUILE; see the file COPYING.LESSER. If not, | |
19 | ## write to the Free Software Foundation, Inc., 51 Franklin Street, | |
20 | ## Fifth Floor, Boston, MA 02110-1301 USA | |
733943b9 | 21 | |
a572fc95 NI |
22 | include $(top_srcdir)/am/snarf |
23 | ||
3307df95 | 24 | AUTOMAKE_OPTIONS = gnu |
733943b9 | 25 | |
a0599745 | 26 | ## Prevent automake from adding extra -I options |
8f99e3f3 | 27 | DEFS = @DEFS@ |
535b3592 LC |
28 | |
29 | # Override Automake's `DEFAULT_INCLUDES'. By default, it contains | |
30 | # "-I$(srcdir)", which causes problems on Tru64 where our "random.h" | |
31 | # is picked up by <stdlib.h> instead of the libc's <random.h>. | |
32 | DEFAULT_INCLUDES = | |
33 | ||
733943b9 TT |
34 | ## Check for headers in $(srcdir)/.., so that #include |
35 | ## <libguile/MUMBLE.h> will find MUMBLE.h in this dir when we're | |
6caac03c | 36 | ## building. Also look for Gnulib headers in `lib'. |
442f3f20 | 37 | AM_CPPFLAGS = -DBUILDING_LIBGUILE=1 -I$(top_srcdir) -I$(top_builddir) \ |
d8b04f04 | 38 | -I$(top_srcdir)/lib -I$(top_builddir)/lib $(LIBFFI_CFLAGS) |
6caac03c | 39 | |
d8b04f04 | 40 | AM_CFLAGS = $(GCC_CFLAGS) $(CFLAG_VISIBILITY) |
6caac03c LC |
41 | |
42 | ## The Gnulib Libtool archive. | |
43 | gnulib_library = $(top_builddir)/lib/libgnu.la | |
733943b9 | 44 | |
4079f87e | 45 | ETAGS_ARGS = --regex='/SCM_\(GLOBAL_\)?\(G?PROC\|G?PROC1\|SYMBOL\|VCELL\|CONST_LONG\).*\"\([^\"]\)*\"/\3/' \ |
abc049a9 | 46 | --regex='/[ \t]*SCM_[G]?DEFINE1?[ \t]*(\([^,]*\),[^,]*/\1/' |
fef07353 | 47 | |
44602b08 | 48 | lib_LTLIBRARIES = libguile-@GUILE_EFFECTIVE_VERSION@.la |
f94b6524 | 49 | bin_PROGRAMS = guile |
b32fca0f | 50 | |
64c2db80 RB |
51 | noinst_PROGRAMS = guile_filter_doc_snarfage gen-scmconfig |
52 | ||
53 | gen_scmconfig_SOURCES = gen-scmconfig.c | |
54 | ||
a04e5749 AW |
55 | ## Override default rule; this should be compiled for BUILD host. Note |
56 | ## that we don't add $(AM_CPPFLAGS) here, as we need to run this | |
57 | ## program, but $(top_srcdir)/lib has a gnulib configured for the | |
58 | ## target. Instead we manually add $(top_builddir), in order to pick up | |
59 | ## the generated config.h and gen-scmconfig.h. Nothing else from Guile | |
60 | ## is included by this code generator. | |
64c2db80 | 61 | gen-scmconfig.$(OBJEXT): gen-scmconfig.c |
ad378da9 AW |
62 | $(AM_V_GEN) \ |
63 | if [ "$(cross_compiling)" = "yes" ]; then \ | |
a04e5749 AW |
64 | $(CC_FOR_BUILD) $(DEFS) $(DEFAULT_INCLUDES) -I$(top_builddir) \ |
65 | -c -o $@ $<; \ | |
ad378da9 AW |
66 | else \ |
67 | $(COMPILE) -c -o $@ $<; \ | |
64c2db80 RB |
68 | fi |
69 | ||
2e945bcc | 70 | ## Override default rule; this should run on BUILD host. |
6a6df187 | 71 | gen-scmconfig$(EXEEXT): $(gen_scmconfig_OBJECTS) $(gen_scmconfig_DEPENDENCIES) |
a572fc95 NI |
72 | $(AM_V_GEN) \ |
73 | rm -f gen-scmconfig$(EXEEXT); \ | |
2e945bcc SJ |
74 | if [ "$(cross_compiling)" = "yes" ]; then \ |
75 | $(CCLD_FOR_BUILD) -o $@ $(gen_scmconfig_OBJECTS); \ | |
76 | else \ | |
77 | $(LINK) $(gen_scmconfig_OBJECTS) $(LDADD) $(LIBS); \ | |
78 | fi | |
79 | ||
80 | scmconfig.h: ${top_builddir}/config.h gen-scmconfig$(EXEEXT) | |
a572fc95 NI |
81 | $(AM_V_GEN)(rm -f scmconfig.h.tmp; \ |
82 | cat $(srcdir)/scmconfig.h.top > scmconfig.h.tmp; \ | |
83 | ./gen-scmconfig$(EXEEXT) >> scmconfig.h.tmp; \ | |
84 | chmod 444 scmconfig.h.tmp; \ | |
85 | rm -f scmconfig.h; \ | |
86 | mv scmconfig.h.tmp scmconfig.h) | |
87 | ||
64c2db80 | 88 | |
b32fca0f MV |
89 | guile_filter_doc_snarfage_SOURCES = c-tokenize.c |
90 | ||
91 | ## Override default rule; this should be compiled for BUILD host. | |
92 | ## For some reason, OBJEXT does not include the dot | |
93 | c-tokenize.$(OBJEXT): c-tokenize.c | |
a572fc95 | 94 | $(AM_V_GEN) \ |
b32fca0f | 95 | if [ "$(cross_compiling)" = "yes" ]; then \ |
bb5b36d0 | 96 | $(CC_FOR_BUILD) -c -o $@ $<; \ |
b32fca0f | 97 | else \ |
4ea57d5b | 98 | $(COMPILE) -c -o $@ $<; \ |
b32fca0f MV |
99 | fi |
100 | ||
101 | ## Override default rule; this should run on BUILD host. | |
6a6df187 | 102 | guile_filter_doc_snarfage$(EXEEXT): $(guile_filter_doc_snarfage_OBJECTS) $(guile_filter_doc_snarfage_DEPENDENCIES) |
a572fc95 NI |
103 | $(AM_V_GEN) \ |
104 | rm -f guile_filter_doc_snarfage$(EXEEXT); \ | |
b32fca0f MV |
105 | if [ "$(cross_compiling)" = "yes" ]; then \ |
106 | $(CCLD_FOR_BUILD) -o $@ $(guile_filter_doc_snarfage_OBJECTS); \ | |
107 | else \ | |
108 | $(LINK) $(guile_filter_doc_snarfage_OBJECTS) $(LDADD) $(LIBS); \ | |
109 | fi | |
110 | ||
549436de JB |
111 | |
112 | guile_SOURCES = guile.c | |
bfb2e113 | 113 | guile_CFLAGS = $(GUILE_CFLAGS) $(AM_CFLAGS) |
44602b08 | 114 | guile_LDADD = libguile-@GUILE_EFFECTIVE_VERSION@.la |
de7d32d0 | 115 | guile_LDFLAGS = $(GUILE_CFLAGS) |
5bbc5359 | 116 | |
44602b08 | 117 | libguile_@GUILE_EFFECTIVE_VERSION@_la_CFLAGS = $(GUILE_CFLAGS) $(AM_CFLAGS) |
ee2a8b9b | 118 | |
44602b08 | 119 | libguile_@GUILE_EFFECTIVE_VERSION@_la_SOURCES = \ |
a4a0d399 AW |
120 | alist.c \ |
121 | arbiters.c \ | |
c53c0893 | 122 | array-handle.c \ |
5d1b3b2d | 123 | array-map.c \ |
2fa901a5 | 124 | arrays.c \ |
a4a0d399 AW |
125 | async.c \ |
126 | backtrace.c \ | |
127 | boolean.c \ | |
cf396142 | 128 | bitvectors.c \ |
a4a0d399 AW |
129 | bytevectors.c \ |
130 | chars.c \ | |
b9c100d0 | 131 | control.c \ |
a4a0d399 AW |
132 | continuations.c \ |
133 | debug.c \ | |
134 | deprecated.c \ | |
135 | deprecation.c \ | |
a4a0d399 AW |
136 | dynwind.c \ |
137 | eq.c \ | |
138 | error.c \ | |
139 | eval.c \ | |
140 | evalext.c \ | |
dc3e203e | 141 | expand.c \ |
a4a0d399 AW |
142 | extensions.c \ |
143 | feature.c \ | |
073167ef | 144 | filesys.c \ |
a4a0d399 | 145 | fluids.c \ |
e2c2a699 | 146 | foreign.c \ |
a4a0d399 AW |
147 | fports.c \ |
148 | frames.c \ | |
a4a0d399 | 149 | gc-malloc.c \ |
a4a0d399 | 150 | gc.c \ |
a4a0d399 AW |
151 | gdbint.c \ |
152 | gettext.c \ | |
1030b450 | 153 | generalized-arrays.c \ |
f332e957 | 154 | generalized-vectors.c \ |
a4a0d399 AW |
155 | goops.c \ |
156 | gsubr.c \ | |
157 | guardians.c \ | |
158 | hash.c \ | |
159 | hashtab.c \ | |
160 | hooks.c \ | |
756e8a3a | 161 | i18n.c \ |
a4a0d399 AW |
162 | init.c \ |
163 | inline.c \ | |
164 | instructions.c \ | |
165 | ioext.c \ | |
166 | keywords.c \ | |
a4a0d399 AW |
167 | list.c \ |
168 | load.c \ | |
169 | macros.c \ | |
170 | mallocs.c \ | |
b7742c6b | 171 | memoize.c \ |
a4a0d399 AW |
172 | modules.c \ |
173 | null-threads.c \ | |
174 | numbers.c \ | |
175 | objcodes.c \ | |
a4a0d399 AW |
176 | objprop.c \ |
177 | options.c \ | |
178 | pairs.c \ | |
6f81b18a | 179 | poll.c \ |
a4a0d399 AW |
180 | ports.c \ |
181 | print.c \ | |
182 | procprop.c \ | |
183 | procs.c \ | |
184 | programs.c \ | |
7b893819 | 185 | promises.c \ |
a4a0d399 | 186 | r6rs-ports.c \ |
a4a0d399 AW |
187 | random.c \ |
188 | rdelim.c \ | |
189 | read.c \ | |
190 | root.c \ | |
191 | rw.c \ | |
192 | scmsigs.c \ | |
193 | script.c \ | |
194 | simpos.c \ | |
195 | smob.c \ | |
196 | sort.c \ | |
197 | srcprop.c \ | |
37710f7e AW |
198 | srfi-1.c \ |
199 | srfi-4.c \ | |
a4a0d399 AW |
200 | srfi-13.c \ |
201 | srfi-14.c \ | |
37710f7e | 202 | srfi-60.c \ |
a4a0d399 AW |
203 | stackchk.c \ |
204 | stacks.c \ | |
205 | stime.c \ | |
206 | strings.c \ | |
207 | strorder.c \ | |
208 | strports.c \ | |
209 | struct.c \ | |
210 | symbols.c \ | |
211 | threads.c \ | |
212 | throw.c \ | |
0f458a37 | 213 | trees.c \ |
476b894c | 214 | uniform.c \ |
a4a0d399 AW |
215 | values.c \ |
216 | variable.c \ | |
217 | vectors.c \ | |
218 | version.c \ | |
219 | vm.c \ | |
220 | vports.c \ | |
221 | weaks.c | |
83495480 | 222 | |
a4a0d399 AW |
223 | DOT_X_FILES = \ |
224 | alist.x \ | |
225 | arbiters.x \ | |
c53c0893 | 226 | array-handle.x \ |
5d1b3b2d | 227 | array-map.x \ |
2fa901a5 | 228 | arrays.x \ |
a4a0d399 AW |
229 | async.x \ |
230 | backtrace.x \ | |
231 | boolean.x \ | |
cf396142 | 232 | bitvectors.x \ |
a4a0d399 AW |
233 | bytevectors.x \ |
234 | chars.x \ | |
b9c100d0 | 235 | control.x \ |
a4a0d399 AW |
236 | continuations.x \ |
237 | debug.x \ | |
238 | deprecated.x \ | |
239 | deprecation.x \ | |
a4a0d399 AW |
240 | dynl.x \ |
241 | dynwind.x \ | |
242 | eq.x \ | |
243 | error.x \ | |
244 | eval.x \ | |
245 | evalext.x \ | |
dc3e203e | 246 | expand.x \ |
a4a0d399 AW |
247 | extensions.x \ |
248 | feature.x \ | |
ee037cee | 249 | filesys.x \ |
a4a0d399 | 250 | fluids.x \ |
e2c2a699 | 251 | foreign.x \ |
a4a0d399 | 252 | fports.x \ |
a4a0d399 | 253 | gc-malloc.x \ |
a4a0d399 AW |
254 | gc.x \ |
255 | gettext.x \ | |
1030b450 | 256 | generalized-arrays.x \ |
f332e957 | 257 | generalized-vectors.x \ |
a4a0d399 AW |
258 | goops.x \ |
259 | gsubr.x \ | |
260 | guardians.x \ | |
261 | hash.x \ | |
262 | hashtab.x \ | |
263 | hooks.x \ | |
264 | i18n.x \ | |
265 | init.x \ | |
266 | ioext.x \ | |
267 | keywords.x \ | |
a4a0d399 AW |
268 | list.x \ |
269 | load.x \ | |
270 | macros.x \ | |
271 | mallocs.x \ | |
b7742c6b | 272 | memoize.x \ |
a4a0d399 AW |
273 | modules.x \ |
274 | numbers.x \ | |
a4a0d399 AW |
275 | objprop.x \ |
276 | options.x \ | |
277 | pairs.x \ | |
278 | ports.x \ | |
279 | print.x \ | |
280 | procprop.x \ | |
281 | procs.x \ | |
7b893819 | 282 | promises.x \ |
a4a0d399 | 283 | r6rs-ports.x \ |
a4a0d399 AW |
284 | random.x \ |
285 | rdelim.x \ | |
286 | read.x \ | |
287 | root.x \ | |
288 | rw.x \ | |
289 | scmsigs.x \ | |
290 | script.x \ | |
291 | simpos.x \ | |
292 | smob.x \ | |
293 | sort.x \ | |
294 | srcprop.x \ | |
37710f7e AW |
295 | srfi-1.x \ |
296 | srfi-4.x \ | |
a4a0d399 AW |
297 | srfi-13.x \ |
298 | srfi-14.x \ | |
37710f7e | 299 | srfi-60.x \ |
a4a0d399 AW |
300 | stackchk.x \ |
301 | stacks.x \ | |
302 | stime.x \ | |
303 | strings.x \ | |
304 | strorder.x \ | |
305 | strports.x \ | |
306 | struct.x \ | |
307 | symbols.x \ | |
308 | threads.x \ | |
309 | throw.x \ | |
0f458a37 | 310 | trees.x \ |
476b894c | 311 | uniform.x \ |
a4a0d399 AW |
312 | values.x \ |
313 | variable.x \ | |
314 | vectors.x \ | |
315 | version.x \ | |
316 | vports.x \ | |
317 | weaks.x | |
8bee78b3 | 318 | |
83495480 AW |
319 | # vm-related snarfs |
320 | DOT_X_FILES += frames.x instructions.x objcodes.x programs.x vm.x | |
321 | ||
e9e225e5 | 322 | EXTRA_DOT_X_FILES = @EXTRA_DOT_X_FILES@ |
8bee78b3 | 323 | |
a4a0d399 AW |
324 | DOT_DOC_FILES = \ |
325 | alist.doc \ | |
326 | arbiters.doc \ | |
c53c0893 | 327 | array-handle.doc \ |
5d1b3b2d | 328 | array-map.doc \ |
2fa901a5 | 329 | arrays.doc \ |
a4a0d399 AW |
330 | async.doc \ |
331 | backtrace.doc \ | |
332 | boolean.doc \ | |
cf396142 | 333 | bitvectors.doc \ |
a4a0d399 AW |
334 | bytevectors.doc \ |
335 | chars.doc \ | |
b9c100d0 | 336 | control.doc \ |
a4a0d399 AW |
337 | continuations.doc \ |
338 | debug.doc \ | |
339 | deprecated.doc \ | |
340 | deprecation.doc \ | |
a4a0d399 AW |
341 | dynl.doc \ |
342 | dynwind.doc \ | |
343 | eq.doc \ | |
344 | error.doc \ | |
345 | eval.doc \ | |
346 | evalext.doc \ | |
dc3e203e | 347 | expand.doc \ |
a4a0d399 AW |
348 | extensions.doc \ |
349 | feature.doc \ | |
073167ef | 350 | filesys.doc \ |
a4a0d399 | 351 | fluids.doc \ |
e2c2a699 | 352 | foreign.doc \ |
a4a0d399 | 353 | fports.doc \ |
a4a0d399 | 354 | gc-malloc.doc \ |
a4a0d399 AW |
355 | gc.doc \ |
356 | gettext.doc \ | |
1030b450 | 357 | generalized-arrays.doc \ |
476b894c | 358 | generalized-vectors.doc \ |
a4a0d399 AW |
359 | goops.doc \ |
360 | gsubr.doc \ | |
361 | guardians.doc \ | |
362 | hash.doc \ | |
363 | hashtab.doc \ | |
364 | hooks.doc \ | |
365 | i18n.doc \ | |
366 | init.doc \ | |
367 | ioext.doc \ | |
368 | keywords.doc \ | |
a4a0d399 AW |
369 | list.doc \ |
370 | load.doc \ | |
371 | macros.doc \ | |
372 | mallocs.doc \ | |
b7742c6b | 373 | memoize.doc \ |
a4a0d399 AW |
374 | modules.doc \ |
375 | numbers.doc \ | |
a4a0d399 AW |
376 | objprop.doc \ |
377 | options.doc \ | |
378 | pairs.doc \ | |
379 | ports.doc \ | |
380 | print.doc \ | |
381 | procprop.doc \ | |
382 | procs.doc \ | |
7b893819 | 383 | promises.doc \ |
a4a0d399 | 384 | r6rs-ports.doc \ |
a4a0d399 AW |
385 | random.doc \ |
386 | rdelim.doc \ | |
387 | read.doc \ | |
388 | root.doc \ | |
389 | rw.doc \ | |
390 | scmsigs.doc \ | |
391 | script.doc \ | |
392 | simpos.doc \ | |
393 | smob.doc \ | |
394 | sort.doc \ | |
395 | srcprop.doc \ | |
37710f7e AW |
396 | srfi-1.doc \ |
397 | srfi-4.doc \ | |
a4a0d399 AW |
398 | srfi-13.doc \ |
399 | srfi-14.doc \ | |
37710f7e | 400 | srfi-60.doc \ |
a4a0d399 AW |
401 | stackchk.doc \ |
402 | stacks.doc \ | |
403 | stime.doc \ | |
404 | strings.doc \ | |
405 | strorder.doc \ | |
406 | strports.doc \ | |
407 | struct.doc \ | |
408 | symbols.doc \ | |
409 | threads.doc \ | |
410 | throw.doc \ | |
0f458a37 | 411 | trees.doc \ |
476b894c | 412 | uniform.doc \ |
a4a0d399 AW |
413 | values.doc \ |
414 | variable.doc \ | |
415 | vectors.doc \ | |
416 | version.doc \ | |
417 | vports.doc \ | |
418 | weaks.doc | |
a3365d47 | 419 | |
2ce88b54 | 420 | EXTRA_DOT_DOC_FILES = @EXTRA_DOT_DOC_FILES@ |
9515eae6 | 421 | |
83495480 AW |
422 | DOT_I_FILES = vm-i-system.i vm-i-scheme.i vm-i-loader.i |
423 | ||
424 | .c.i: | |
a572fc95 | 425 | $(AM_V_GEN)$(GREP) '^VM_DEFINE' $< > $@ |
83495480 | 426 | |
648da032 | 427 | BUILT_SOURCES = cpp-E.c cpp-SIG.c libpath.h \ |
b405cdb4 | 428 | scmconfig.h \ |
83495480 | 429 | $(DOT_I_FILES) $(DOT_X_FILES) $(EXTRA_DOT_X_FILES) |
9515eae6 | 430 | |
44602b08 | 431 | EXTRA_libguile_@GUILE_EFFECTIVE_VERSION@_la_SOURCES = _scm.h \ |
c32b39b9 | 432 | memmove.c strerror.c \ |
f731051e | 433 | dynl.c regex-posix.c \ |
073167ef | 434 | posix.c net_db.c socket.c \ |
29627818 | 435 | debug-malloc.c mkstemp.c \ |
b89c4943 LC |
436 | win32-uname.c win32-dirent.c win32-socket.c \ |
437 | locale-categories.h | |
7bfd3b9e | 438 | |
413a1367 ML |
439 | ## delete guile-snarf.awk from the installation bindir, in case it's |
440 | ## lingering there due to an earlier guile version not having been | |
441 | ## wiped out. | |
442 | install-exec-hook: | |
b27b814d | 443 | rm -f $(DESTDIR)$(bindir)/guile-snarf.awk |
413a1367 | 444 | |
7bfd3b9e | 445 | ## This is kind of nasty... there are ".c" files that we don't want to |
1be6b49c ML |
446 | ## compile, since they are #included. So instead we list them here. |
447 | ## Perhaps we can deal with them normally once the merge seems to be | |
448 | ## working. | |
4b126598 | 449 | noinst_HEADERS = conv-integer.i.c conv-uinteger.i.c \ |
71560395 | 450 | ieee-754.h \ |
71560395 | 451 | srfi-14.i.c \ |
06f9c814 | 452 | quicksort.i.c \ |
340c49bf | 453 | win32-uname.h win32-dirent.h win32-socket.h \ |
981ff600 | 454 | private-gc.h private-options.h |
7bfd3b9e | 455 | |
83495480 AW |
456 | # vm instructions |
457 | noinst_HEADERS += vm-engine.c vm-i-system.c vm-i-scheme.c vm-i-loader.c | |
458 | ||
44602b08 | 459 | libguile_@GUILE_EFFECTIVE_VERSION@_la_DEPENDENCIES = @LIBLOBJS@ |
abd7e37a | 460 | |
18f2d5aa | 461 | libguile_@GUILE_EFFECTIVE_VERSION@_la_LIBADD = \ |
cae0945c LC |
462 | @LIBLOBJS@ $(gnulib_library) $(LTLIBGMP) $(LTLIBLTDL) |
463 | ||
464 | # Libtool version info. | |
465 | version_info = @LIBGUILE_INTERFACE_CURRENT@:@LIBGUILE_INTERFACE_REVISION@:@LIBGUILE_INTERFACE_AGE@ | |
466 | ||
467 | libguile_@GUILE_EFFECTIVE_VERSION@_la_LDFLAGS = \ | |
468 | $(BDW_GC_LIBS) $(LIBFFI_LIBS) \ | |
dd36ce77 | 469 | $(CEIL_LIBM) \ |
cae0945c | 470 | $(FLOOR_LIBM) \ |
dd36ce77 | 471 | $(FREXP_LIBM) \ |
cae0945c LC |
472 | $(GETADDRINFO_LIB) \ |
473 | $(HOSTENT_LIB) \ | |
474 | $(INET_NTOP_LIB) \ | |
475 | $(INET_PTON_LIB) \ | |
476 | $(ISNAND_LIBM) \ | |
477 | $(ISNANF_LIBM) \ | |
478 | $(ISNANL_LIBM) \ | |
dd36ce77 | 479 | $(LDEXP_LIBM) \ |
e3b8bce8 | 480 | $(LIB_CLOCK_GETTIME) \ |
cae0945c LC |
481 | $(LIBSOCKET) \ |
482 | $(LOG1P_LIBM) \ | |
483 | $(LTLIBICONV) \ | |
484 | $(LTLIBINTL) \ | |
485 | $(LTLIBUNISTRING) \ | |
cae0945c LC |
486 | $(SERVENT_LIB) \ |
487 | $(TRUNC_LIBM) \ | |
488 | -version-info $(version_info) \ | |
489 | -export-dynamic -no-undefined \ | |
76e8a758 | 490 | $(GNU_LD_FLAGS) |
733943b9 | 491 | |
9af080f7 LC |
492 | if HAVE_LD_VERSION_SCRIPT |
493 | ||
44602b08 | 494 | libguile_@GUILE_EFFECTIVE_VERSION@_la_LDFLAGS += -Wl,--version-script="$(srcdir)/libguile.map" |
9af080f7 LC |
495 | |
496 | endif HAVE_LD_VERSION_SCRIPT | |
497 | ||
498 | ||
54f16aec | 499 | # These are headers visible as <guile/mumble.h> |
6a6df187 | 500 | pkginclude_HEADERS = |
ee2a8b9b | 501 | |
733943b9 | 502 | # These are headers visible as <libguile/mumble.h>. |
718815d7 | 503 | modincludedir = $(pkgincludedir)/$(GUILE_EFFECTIVE_VERSION)/libguile |
a4a0d399 AW |
504 | modinclude_HEADERS = \ |
505 | __scm.h \ | |
506 | alist.h \ | |
507 | arbiters.h \ | |
c53c0893 | 508 | array-handle.h \ |
5d1b3b2d | 509 | array-map.h \ |
2fa901a5 | 510 | arrays.h \ |
a4a0d399 AW |
511 | async.h \ |
512 | backtrace.h \ | |
1c44468d | 513 | bdw-gc.h \ |
a4a0d399 | 514 | boolean.h \ |
cf396142 | 515 | bitvectors.h \ |
a4a0d399 AW |
516 | bytevectors.h \ |
517 | chars.h \ | |
b9c100d0 | 518 | control.h \ |
a4a0d399 AW |
519 | continuations.h \ |
520 | debug-malloc.h \ | |
521 | debug.h \ | |
522 | deprecated.h \ | |
523 | deprecation.h \ | |
a4a0d399 AW |
524 | dynl.h \ |
525 | dynwind.h \ | |
526 | eq.h \ | |
527 | error.h \ | |
528 | eval.h \ | |
529 | evalext.h \ | |
dc3e203e | 530 | expand.h \ |
a4a0d399 AW |
531 | extensions.h \ |
532 | feature.h \ | |
533 | filesys.h \ | |
534 | fluids.h \ | |
e2c2a699 | 535 | foreign.h \ |
a4a0d399 AW |
536 | fports.h \ |
537 | frames.h \ | |
a4a0d399 AW |
538 | gc.h \ |
539 | gdb_interface.h \ | |
540 | gdbint.h \ | |
541 | gettext.h \ | |
1030b450 | 542 | generalized-arrays.h \ |
f332e957 | 543 | generalized-vectors.h \ |
a4a0d399 AW |
544 | goops.h \ |
545 | gsubr.h \ | |
546 | guardians.h \ | |
547 | hash.h \ | |
548 | hashtab.h \ | |
549 | hooks.h \ | |
550 | i18n.h \ | |
551 | init.h \ | |
552 | inline.h \ | |
553 | instructions.h \ | |
554 | ioext.h \ | |
555 | iselect.h \ | |
556 | keywords.h \ | |
a4a0d399 AW |
557 | list.h \ |
558 | load.h \ | |
559 | macros.h \ | |
560 | mallocs.h \ | |
b7742c6b | 561 | memoize.h \ |
a4a0d399 AW |
562 | modules.h \ |
563 | net_db.h \ | |
564 | null-threads.h \ | |
565 | numbers.h \ | |
566 | objcodes.h \ | |
a4a0d399 AW |
567 | objprop.h \ |
568 | options.h \ | |
569 | pairs.h \ | |
6f81b18a | 570 | poll.h \ |
a4a0d399 AW |
571 | ports.h \ |
572 | posix.h \ | |
573 | print.h \ | |
574 | procprop.h \ | |
575 | procs.h \ | |
576 | programs.h \ | |
7b893819 | 577 | promises.h \ |
a4a0d399 AW |
578 | pthread-threads.h \ |
579 | r6rs-ports.h \ | |
a4a0d399 AW |
580 | random.h \ |
581 | rdelim.h \ | |
582 | read.h \ | |
583 | regex-posix.h \ | |
584 | root.h \ | |
585 | rw.h \ | |
586 | scmsigs.h \ | |
587 | script.h \ | |
588 | simpos.h \ | |
589 | smob.h \ | |
590 | snarf.h \ | |
591 | socket.h \ | |
592 | sort.h \ | |
593 | srcprop.h \ | |
37710f7e AW |
594 | srfi-1.h \ |
595 | srfi-4.h \ | |
a4a0d399 AW |
596 | srfi-13.h \ |
597 | srfi-14.h \ | |
37710f7e | 598 | srfi-60.h \ |
a4a0d399 AW |
599 | stackchk.h \ |
600 | stacks.h \ | |
601 | stime.h \ | |
602 | strings.h \ | |
603 | strorder.h \ | |
604 | strports.h \ | |
605 | struct.h \ | |
606 | symbols.h \ | |
607 | tags.h \ | |
608 | threads.h \ | |
609 | throw.h \ | |
0f458a37 | 610 | trees.h \ |
a4a0d399 | 611 | validate.h \ |
476b894c | 612 | uniform.h \ |
a4a0d399 AW |
613 | values.h \ |
614 | variable.h \ | |
615 | vectors.h \ | |
a4a0d399 AW |
616 | vm-engine.h \ |
617 | vm-expand.h \ | |
618 | vm.h \ | |
619 | vports.h \ | |
620 | weaks.h | |
83495480 | 621 | |
93ff93f6 | 622 | nodist_modinclude_HEADERS = version.h scmconfig.h |
733943b9 | 623 | |
604a672e TTN |
624 | bin_SCRIPTS = guile-snarf |
625 | ||
f94b6524 TTN |
626 | # We can re-enable install for some of these if/when they are documented |
627 | # and people feel like maintaining them. For now, this is not the case. | |
2d6a14ad | 628 | noinst_SCRIPTS = guile-snarf-docs |
adb75a41 | 629 | |
89bc270d | 630 | EXTRA_DIST = ChangeLog-scm ChangeLog-threads \ |
648da032 | 631 | ChangeLog-1996-1999 ChangeLog-2000 ChangeLog-2008 \ |
2d6a14ad | 632 | guile-func-name-check \ |
648da032 | 633 | cpp-E.syms cpp-E.c cpp-SIG.syms cpp-SIG.c \ |
b405cdb4 | 634 | c-tokenize.lex \ |
f49dbcad | 635 | scmconfig.h.top libgettext.h unidata_to_charset.pl libguile.map |
c99f9605 ML |
636 | # $(DOT_DOC_FILES) $(EXTRA_DOT_DOC_FILES) \ |
637 | # guile-procedures.txt guile.texi | |
733943b9 | 638 | |
fef07353 | 639 | ## FIXME: Consider using timestamp file, to avoid unnecessary rebuilds. |
90ff3ec5 | 640 | libpath.h: $(srcdir)/Makefile.in $(top_builddir)/config.status |
e151bee6 JB |
641 | @rm -f libpath.tmp |
642 | @echo '/* generated by Makefile */' > libpath.tmp | |
643 | @echo '#define SCM_PKGDATA_DIR "$(pkgdatadir)"' >> libpath.tmp | |
d8a20ddb | 644 | @echo '#define SCM_LIBRARY_DIR "$(pkgdatadir)/$(GUILE_EFFECTIVE_VERSION)"'>>libpath.tmp |
d5a1a8cd | 645 | @echo '#define SCM_SITE_DIR "$(sitedir)"' >> libpath.tmp |
bc325e76 | 646 | @echo '#define SCM_GLOBAL_SITE_DIR "$(pkgdatadir)/site"' >> libpath.tmp |
28af5ee5 AW |
647 | @echo '#define SCM_LIB_DIR "$(libdir)"' >> libpath.tmp |
648 | @echo '#define SCM_EXTENSIONS_DIR "$(pkglibdir)/$(GUILE_EFFECTIVE_VERSION)/extensions"' >> libpath.tmp | |
5b197db8 AW |
649 | @echo '#define SCM_CCACHE_DIR "$(pkglibdir)/$(GUILE_EFFECTIVE_VERSION)/ccache"' >> libpath.tmp |
650 | @echo '#define SCM_EFFECTIVE_VERSION "$(GUILE_EFFECTIVE_VERSION)"' >> libpath.tmp | |
e151bee6 JB |
651 | @echo '#define SCM_BUILD_INFO { \' >> libpath.tmp |
652 | @echo ' { "srcdir", "'"`cd @srcdir@; pwd`"'" }, \' >> libpath.tmp | |
c565712c | 653 | @echo ' { "top_srcdir", "@top_srcdir_absolute@" }, \' >> libpath.tmp |
e151bee6 JB |
654 | @echo ' { "prefix", "@prefix@" }, \' >> libpath.tmp |
655 | @echo ' { "exec_prefix", "@exec_prefix@" }, \' >> libpath.tmp | |
656 | @echo ' { "bindir", "@bindir@" }, \' >> libpath.tmp | |
657 | @echo ' { "sbindir", "@sbindir@" }, \' >> libpath.tmp | |
658 | @echo ' { "libexecdir", "@libexecdir@" }, \' >> libpath.tmp | |
659 | @echo ' { "datadir", "@datadir@" }, \' >> libpath.tmp | |
660 | @echo ' { "sysconfdir", "@sysconfdir@" }, \' >> libpath.tmp | |
661 | @echo ' { "sharedstatedir", "@sharedstatedir@" }, \' >> libpath.tmp | |
662 | @echo ' { "localstatedir", "@localstatedir@" }, \' >> libpath.tmp | |
663 | @echo ' { "libdir", "@libdir@" }, \' >> libpath.tmp | |
5b197db8 | 664 | @echo ' { "ccachedir", SCM_CCACHE_DIR }, \' >> libpath.tmp |
e151bee6 JB |
665 | @echo ' { "infodir", "@infodir@" }, \' >> libpath.tmp |
666 | @echo ' { "mandir", "@mandir@" }, \' >> libpath.tmp | |
667 | @echo ' { "includedir", "@includedir@" }, \' >> libpath.tmp | |
eb350124 AW |
668 | @echo ' { "pkgdatadir", "$(pkgdatadir)" }, \' >> libpath.tmp |
669 | @echo ' { "pkglibdir", "$(pkglibdir)" }, \' >> libpath.tmp | |
670 | @echo ' { "pkgincludedir", "$(pkgincludedir)" }, \' \ | |
e151bee6 | 671 | >> libpath.tmp |
869bfe86 | 672 | @echo ' { "extensiondir", "$(pkglibdir)/$(GUILE_EFFECTIVE_VERSION)/extensions" }, \' >> libpath.tmp |
b6fae158 | 673 | @echo ' { "guileversion", "@GUILE_VERSION@" }, \' >> libpath.tmp |
54f16aec TTN |
674 | @echo ' { "libguileinterface", "@LIBGUILE_INTERFACE@" }, \' \ |
675 | >> libpath.tmp | |
30dda257 | 676 | @echo ' { "LIBS", "@GUILE_LIBS@" }, \' >> libpath.tmp |
5bbc5359 | 677 | @echo ' { "CFLAGS", "@GUILE_CFLAGS@" }, \' >> libpath.tmp |
a6025413 | 678 | @echo ' { "buildstamp", "'`date -u +'%Y-%m-%d %T'`'" }, \' >> libpath.tmp |
e151bee6 | 679 | @echo '}' >> libpath.tmp |
a572fc95 | 680 | $(AM_V_GEN)mv libpath.tmp libpath.h |
733943b9 | 681 | |
3dc81fba | 682 | |
47871d5a | 683 | snarfcppopts = $(DEFS) $(AM_CPPFLAGS) $(CPPFLAGS) $(CFLAGS) |
e9c3d3f9 | 684 | |
3dc81fba | 685 | SUFFIXES = .x .doc |
a572fc95 | 686 | |
733943b9 | 687 | .c.x: |
a572fc95 | 688 | $(AM_V_SNARF)$(GUILE_SNARF) -o $@ $< $(snarfcppopts) |
c99f9605 | 689 | .c.doc: |
e6d67f1e | 690 | $(AM_V_SNARF)./guile-snarf-docs -o $@ $< -- $(snarfcppopts) |
733943b9 | 691 | |
f9560a34 | 692 | $(DOT_X_FILES) $(EXTRA_DOT_X_FILES): scmconfig.h snarf.h guile-snarf.in version.h |
c99f9605 | 693 | |
23f2b9a3 | 694 | $(DOT_DOC_FILES) $(EXTRA_DOT_DOC_FILES): scmconfig.h snarf.h guile-snarf-docs.in guile_filter_doc_snarfage$(EXEEXT) |
66418d34 | 695 | |
648da032 TTN |
696 | error.x: cpp-E.c |
697 | posix.x: cpp-SIG.c | |
faf6a29b MV |
698 | load.x: libpath.h |
699 | ||
f8241358 | 700 | alldotdocfiles = $(DOT_DOC_FILES) $(EXTRA_DOT_DOC_FILES) |
e27f640a | 701 | snarf2checkedtexi = GUILE_AUTO_COMPILE=0 $(top_builddir)/meta/uninstalled-env guile-tools snarf-check-and-output-texi |
f8241358 TTN |
702 | dotdoc2texi = cat $(alldotdocfiles) | $(snarf2checkedtexi) |
703 | ||
2e945bcc | 704 | guile.texi: $(alldotdocfiles) guile$(EXEEXT) |
f8241358 TTN |
705 | $(dotdoc2texi) --manual > $@ || { rm $@; false; } |
706 | ||
2e945bcc | 707 | guile-procedures.texi: $(alldotdocfiles) guile$(EXEEXT) |
a572fc95 | 708 | $(AM_V_GEN)$(dotdoc2texi) > $@ || { rm $@; false; } |
9d29e990 | 709 | |
9df3eecc MV |
710 | if HAVE_MAKEINFO |
711 | ||
cecb4a5e | 712 | guile-procedures.txt: guile-procedures.texi |
9d29e990 | 713 | rm -f $@ |
f7742034 | 714 | makeinfo --force -o $@ guile-procedures.texi || test -f $@ |
4079f87e | 715 | |
9df3eecc MV |
716 | else |
717 | ||
718 | guile-procedures.txt: guile-procedures.texi | |
f7742034 | 719 | cp guile-procedures.texi $@ |
9df3eecc MV |
720 | |
721 | endif | |
722 | ||
30e3be5a | 723 | c-tokenize.c: c-tokenize.lex |
47ac1e47 | 724 | flex -t $(srcdir)/c-tokenize.lex > $@ || { rm $@; false; } |
30e3be5a | 725 | |
d8a20ddb | 726 | schemelibdir = $(pkgdatadir)/$(GUILE_EFFECTIVE_VERSION) |
8dc9439f | 727 | schemelib_DATA = guile-procedures.txt |
4079f87e | 728 | |
733943b9 | 729 | ## Add -MG to make the .x magic work with auto-dep code. |
47871d5a | 730 | MKDEP = gcc -M -MG $(DEFS) $(AM_CPPFLAGS) $(CPPFLAGS) $(CFLAGS) |
ee78fbb0 | 731 | |
648da032 TTN |
732 | \f |
733 | # This page is for maintenance of the lists of CPP symbols that are eventually | |
734 | # included in error.c (‘errno’ values: E*) and posix.c (signal names: SIG*), | |
735 | # in the funcs scm_init_{error,posix}, respectively. | |
736 | # | |
737 | # The lists (files cpp-{E,SIG}.syms) are not included verbatim, but processed | |
738 | # (via pattern rule ‘.syms.c’ below) so that each CPP symbol is transformed to | |
739 | # fragment of #ifdef'd C code that defines a Scheme variable of the same name. | |
740 | # The resulting files, cpp-{E,SIG}.c, are the ones #include:d. | |
741 | # | |
742 | # To maintain the (source) lists of symbols, we use a GCC-specific feature | |
743 | # to list all symbols #define:d when expanding <{errno,signal}.h>, grep | |
744 | # the output for {E,SIG}*, massage the result into a usable form, and | |
745 | # construct a union of the current and new symbols. This is written to | |
746 | # files cpp-{E,SIG}.syms.NEW for review. If things look ok, you can then | |
747 | # "mv foo.NEW foo" and commit. Generating the foo.NEW files and showing | |
748 | # an informative message is the job of targets chknew-{E,SIG}. | |
749 | ||
750 | # For each line in foo.syms, transform: | |
751 | # SYMBOL | |
752 | # to: | |
753 | # #ifdef SYMBOL | |
754 | # scm_c_define ("SYMBOL", scm_from_int (SYMBOL)); | |
755 | # #endif | |
319b53dd TTN |
756 | # writing output to foo.c. We use a while-read loop instead of a |
757 | # one-line sed script because some seds (e.g., FreeBSD) don't read | |
758 | # '\n' as a newline (like GNU sed does). Sad, but true. | |
648da032 | 759 | .syms.c: |
bfebf099 | 760 | $(AM_V_GEN) \ |
319b53dd TTN |
761 | cat $< | while read sym ; do \ |
762 | echo "#ifdef $$sym" ; \ | |
763 | echo "scm_c_define (\"$$sym\", scm_from_int ($$sym));" ; \ | |
764 | echo "#endif" ; \ | |
765 | done > $@T | |
bfebf099 | 766 | @mv $@T $@ |
648da032 TTN |
767 | |
768 | # Write $(srcdir)/cpp-{E,SIG}.syms.NEW if there are any not-yet-seen | |
769 | # ("new" to us) E* or SIG* symbols in <errno.h> or <signal.h>, respectively. | |
9253d090 | 770 | chknew-E chknew-SIG: \ |
648da032 TTN |
771 | @bit=`echo $@ | sed s/^chknew-//` ; \ |
772 | old="$(srcdir)/cpp-$$bit.syms" ; \ | |
773 | echo "#include <$${bit}.h>" \ | |
774 | | sed 's/E/errno/;s/SIG/signal/' \ | |
9253d090 | 775 | | gcc -dM -E - \ |
648da032 TTN |
776 | | sed 's/^#define //;/^'$$bit'[A-Z][A-Z]*/!d;s/ .*//' \ |
777 | | sort | diff -u $$old - | sed '1,2d;/^+/!d;s/^.//' \ | |
778 | > TMP ; \ | |
779 | if [ -s TMP ] ; then new="$$old.NEW" ; \ | |
780 | cat $$old TMP | sort > $$new ; \ | |
781 | echo "$$new: `sed -n '$$=' TMP` new symbol(s)." ; \ | |
782 | sed 's/^/ /' TMP ; \ | |
783 | else echo "No new symbols found." ; \ | |
784 | fi ; rm TMP | |
785 | ||
786 | \f | |
67ec3667 | 787 | |
ad6b30a0 | 788 | MOSTLYCLEANFILES = \ |
23ccb831 | 789 | scmconfig.h scmconfig.h.tmp |
ad6b30a0 | 790 | |
84595266 AW |
791 | CLEANFILES = libpath.h *.x *.doc guile-procedures.txt guile-procedures.texi guile.texi \ |
792 | vm-i-*.i | |
ee0c0e03 ML |
793 | |
794 | MAINTAINERCLEANFILES = c-tokenize.c |