Makefile.am 27 KB

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