Commit | Line | Data |
---|---|---|
733943b9 | 1 | ## Process this file with Automake to create Makefile.in |
2764bd99 | 2 | ## |
535b3592 | 3 | ## Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2006, 2007, 2008 Free Software Foundation, Inc. |
2764bd99 JB |
4 | ## |
5 | ## This file is part of GUILE. | |
54f16aec | 6 | ## |
2764bd99 JB |
7 | ## GUILE is free software; you can redistribute it and/or modify |
8 | ## it under the terms of the GNU General Public License as | |
9 | ## published by the Free Software Foundation; either version 2, or | |
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 | |
15 | ## GNU General Public License for more details. | |
54f16aec | 16 | ## |
2764bd99 JB |
17 | ## You should have received a copy of the GNU General Public |
18 | ## License along with GUILE; see the file COPYING. If not, write | |
92205699 MV |
19 | ## to the Free Software Foundation, Inc., 51 Franklin Street, Fifth |
20 | ## Floor, Boston, MA 02110-1301 USA | |
733943b9 | 21 | |
3307df95 | 22 | AUTOMAKE_OPTIONS = gnu |
733943b9 | 23 | |
a0599745 | 24 | ## Prevent automake from adding extra -I options |
8f99e3f3 | 25 | DEFS = @DEFS@ |
535b3592 LC |
26 | |
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 | ||
733943b9 TT |
32 | ## Check for headers in $(srcdir)/.., so that #include |
33 | ## <libguile/MUMBLE.h> will find MUMBLE.h in this dir when we're | |
6caac03c | 34 | ## building. Also look for Gnulib headers in `lib'. |
535b3592 | 35 | INCLUDES = -I$(top_srcdir) -I$(top_builddir) \ |
6caac03c LC |
36 | -I$(top_srcdir)/lib -I$(top_builddir)/lib |
37 | ||
38 | ## The Gnulib Libtool archive. | |
39 | gnulib_library = $(top_builddir)/lib/libgnu.la | |
733943b9 | 40 | |
4079f87e | 41 | ETAGS_ARGS = --regex='/SCM_\(GLOBAL_\)?\(G?PROC\|G?PROC1\|SYMBOL\|VCELL\|CONST_LONG\).*\"\([^\"]\)*\"/\3/' \ |
abc049a9 | 42 | --regex='/[ \t]*SCM_[G]?DEFINE1?[ \t]*(\([^,]*\),[^,]*/\1/' |
fef07353 | 43 | |
b89c4943 LC |
44 | lib_LTLIBRARIES = libguile.la \ |
45 | libguile-i18n-v-@LIBGUILE_I18N_MAJOR@.la | |
f94b6524 | 46 | bin_PROGRAMS = guile |
b32fca0f | 47 | |
64c2db80 RB |
48 | noinst_PROGRAMS = guile_filter_doc_snarfage gen-scmconfig |
49 | ||
50 | gen_scmconfig_SOURCES = gen-scmconfig.c | |
51 | ||
52 | ## Override default rule; this should be compiled for BUILD host. | |
53 | ## For some reason, OBJEXT does not include the dot | |
54 | gen-scmconfig.$(OBJEXT): gen-scmconfig.c | |
55 | if [ "$(cross_compiling)" = "yes" ]; then \ | |
ecc9f40f | 56 | $(CC_FOR_BUILD) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) -c -o $@ $<; \ |
64c2db80 RB |
57 | else \ |
58 | $(COMPILE) -c -o $@ $<; \ | |
59 | fi | |
60 | ||
2e945bcc SJ |
61 | ## Override default rule; this should run on BUILD host. |
62 | gen-scmconfig$(EXEEXT): $(gen_scmconfig_OBJECTS) $(gen_scmconfig_DEPENDENCIES) | |
63 | @rm -f gen-scmconfig$(EXEEXT) | |
64 | if [ "$(cross_compiling)" = "yes" ]; then \ | |
65 | $(CCLD_FOR_BUILD) -o $@ $(gen_scmconfig_OBJECTS); \ | |
66 | else \ | |
67 | $(LINK) $(gen_scmconfig_OBJECTS) $(LDADD) $(LIBS); \ | |
68 | fi | |
69 | ||
70 | scmconfig.h: ${top_builddir}/config.h gen-scmconfig$(EXEEXT) | |
64c2db80 | 71 | rm -f scmconfig.h.tmp |
eaf94f77 | 72 | cat $(srcdir)/scmconfig.h.top > scmconfig.h.tmp |
2e945bcc | 73 | ./gen-scmconfig$(EXEEXT) >> scmconfig.h.tmp |
64c2db80 RB |
74 | chmod 444 scmconfig.h.tmp |
75 | rm -f scmconfig.h | |
76 | mv scmconfig.h.tmp scmconfig.h | |
77 | ||
b32fca0f MV |
78 | guile_filter_doc_snarfage_SOURCES = c-tokenize.c |
79 | ||
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 | if [ "$(cross_compiling)" = "yes" ]; then \ | |
2e945bcc | 84 | $(CC_FOR_BUILD) $(DEFS) $(INCLUDES) -c -o $@ $<; \ |
b32fca0f | 85 | else \ |
93eaa2a2 | 86 | $(COMPILE) -c -o $@ $<; \ |
b32fca0f MV |
87 | fi |
88 | ||
89 | ## Override default rule; this should run on BUILD host. | |
90 | guile_filter_doc_snarfage$(EXEEXT): $(guile_filter_doc_snarfage_OBJECTS) $(guile_filter_doc_snarfage_DEPENDENCIES) | |
91 | @rm -f guile_filter_doc_snarfage$(EXEEXT) | |
92 | if [ "$(cross_compiling)" = "yes" ]; then \ | |
93 | $(CCLD_FOR_BUILD) -o $@ $(guile_filter_doc_snarfage_OBJECTS); \ | |
94 | else \ | |
95 | $(LINK) $(guile_filter_doc_snarfage_OBJECTS) $(LDADD) $(LIBS); \ | |
96 | fi | |
97 | ||
549436de JB |
98 | |
99 | guile_SOURCES = guile.c | |
5bbc5359 | 100 | guile_CFLAGS = $(GUILE_CFLAGS) |
8f99e3f3 | 101 | guile_LDADD = libguile.la |
5bbc5359 MV |
102 | guile_LDFLAGS = @DLPREOPEN@ $(GUILE_CFLAGS) |
103 | ||
104 | libguile_la_CFLAGS = $(GUILE_CFLAGS) | |
ee2a8b9b | 105 | |
06f9c814 MV |
106 | libguile_la_SOURCES = alist.c arbiters.c async.c backtrace.c boolean.c \ |
107 | chars.c continuations.c convert.c debug.c deprecation.c \ | |
dd18d312 | 108 | deprecated.c discouraged.c dynwind.c eq.c error.c \ |
06f9c814 MV |
109 | eval.c evalext.c extensions.c feature.c fluids.c fports.c \ |
110 | futures.c gc.c gc-mark.c gc-segment.c gc-malloc.c gc-card.c \ | |
b89c4943 LC |
111 | gc-freelist.c gc_os_dep.c gdbint.c gettext.c \ |
112 | gh_data.c gh_eval.c gh_funcs.c \ | |
06f9c814 | 113 | gh_init.c gh_io.c gh_list.c gh_predicates.c goops.c gsubr.c \ |
b89c4943 | 114 | guardians.c hash.c hashtab.c hooks.c init.c inline.c \ |
06f9c814 MV |
115 | ioext.c keywords.c lang.c list.c load.c macros.c mallocs.c \ |
116 | modules.c numbers.c objects.c objprop.c options.c pairs.c ports.c \ | |
117 | print.c procprop.c procs.c properties.c random.c rdelim.c read.c \ | |
118 | root.c rw.c scmsigs.c script.c simpos.c smob.c sort.c srcprop.c \ | |
119 | stackchk.c stacks.c stime.c strings.c srfi-4.c srfi-13.c srfi-14.c \ | |
9b7952c0 MV |
120 | strorder.c strports.c struct.c symbols.c threads.c null-threads.c \ |
121 | throw.c values.c variable.c vectors.c version.c vports.c weaks.c \ | |
122 | ramap.c unif.c | |
06f9c814 | 123 | |
b89c4943 LC |
124 | libguile_i18n_v_@LIBGUILE_I18N_MAJOR@_la_SOURCES = i18n.c |
125 | libguile_i18n_v_@LIBGUILE_I18N_MAJOR@_la_CFLAGS = \ | |
126 | $(libguile_la_CFLAGS) | |
127 | libguile_i18n_v_@LIBGUILE_I18N_MAJOR@_la_LIBADD = \ | |
6caac03c | 128 | libguile.la $(gnulib_library) |
b89c4943 LC |
129 | libguile_i18n_v_@LIBGUILE_I18N_MAJOR@_la_LDFLAGS = \ |
130 | -module -L$(builddir) -lguile \ | |
131 | -version-info @LIBGUILE_I18N_INTERFACE@ | |
132 | ||
06f9c814 MV |
133 | DOT_X_FILES = alist.x arbiters.x async.x backtrace.x boolean.x chars.x \ |
134 | continuations.x debug.x deprecation.x deprecated.x discouraged.x \ | |
dd18d312 | 135 | dynl.x dynwind.x eq.x error.x eval.x evalext.x \ |
06f9c814 | 136 | extensions.x feature.x fluids.x fports.x futures.x gc.x gc-mark.x \ |
b89c4943 LC |
137 | gc-segment.x gc-malloc.x gc-card.x gettext.x goops.x \ |
138 | gsubr.x guardians.x \ | |
06f9c814 MV |
139 | hash.x hashtab.x hooks.x i18n.x init.x ioext.x keywords.x lang.x \ |
140 | list.x load.x macros.x mallocs.x modules.x numbers.x objects.x \ | |
141 | objprop.x options.x pairs.x ports.x print.x procprop.x procs.x \ | |
142 | properties.x random.x rdelim.x read.x root.x rw.x scmsigs.x \ | |
143 | script.x simpos.x smob.x sort.x srcprop.x stackchk.x stacks.x \ | |
144 | stime.x strings.x srfi-4.x srfi-13.x srfi-14.x strorder.x \ | |
145 | strports.x struct.x symbols.x threads.x throw.x values.x \ | |
146 | variable.x vectors.x version.x vports.x weaks.x ramap.x unif.x | |
8bee78b3 | 147 | |
e9e225e5 | 148 | EXTRA_DOT_X_FILES = @EXTRA_DOT_X_FILES@ |
8bee78b3 | 149 | |
06f9c814 MV |
150 | DOT_DOC_FILES = alist.doc arbiters.doc async.doc backtrace.doc \ |
151 | boolean.doc chars.doc continuations.doc debug.doc deprecation.doc \ | |
152 | deprecated.doc discouraged.doc dynl.doc dynwind.doc \ | |
dd18d312 | 153 | eq.doc error.doc eval.doc evalext.doc \ |
06f9c814 MV |
154 | extensions.doc feature.doc fluids.doc fports.doc futures.doc \ |
155 | gc.doc goops.doc gsubr.doc gc-mark.doc gc-segment.doc \ | |
b89c4943 LC |
156 | gc-malloc.doc gc-card.doc gettext.doc \ |
157 | guardians.doc hash.doc hashtab.doc \ | |
06f9c814 MV |
158 | hooks.doc i18n.doc init.doc ioext.doc keywords.doc lang.doc \ |
159 | list.doc load.doc macros.doc mallocs.doc modules.doc numbers.doc \ | |
160 | objects.doc objprop.doc options.doc pairs.doc ports.doc print.doc \ | |
161 | procprop.doc procs.doc properties.doc random.doc rdelim.doc \ | |
162 | read.doc root.doc rw.doc scmsigs.doc script.doc simpos.doc \ | |
163 | smob.doc sort.doc srcprop.doc stackchk.doc stacks.doc stime.doc \ | |
164 | strings.doc srfi-4.doc srfi-13.doc srfi-14.doc strorder.doc \ | |
165 | strports.doc struct.doc symbols.doc threads.doc throw.doc \ | |
166 | values.doc variable.doc vectors.doc version.doc vports.doc \ | |
167 | weaks.doc ramap.doc unif.doc | |
a3365d47 | 168 | |
2ce88b54 | 169 | EXTRA_DOT_DOC_FILES = @EXTRA_DOT_DOC_FILES@ |
9515eae6 | 170 | |
64c2db80 RB |
171 | BUILT_SOURCES = cpp_err_symbols.c cpp_sig_symbols.c libpath.h \ |
172 | version.h scmconfig.h \ | |
23f2b9a3 | 173 | $(DOT_X_FILES) $(EXTRA_DOT_X_FILES) |
9515eae6 | 174 | |
f731051e MV |
175 | EXTRA_libguile_la_SOURCES = _scm.h \ |
176 | inet_aton.c memmove.c putenv.c strerror.c \ | |
177 | dynl.c regex-posix.c \ | |
178 | filesys.c posix.c net_db.c socket.c \ | |
b89c4943 LC |
179 | debug-malloc.c mkstemp.c \ |
180 | win32-uname.c win32-dirent.c win32-socket.c \ | |
181 | locale-categories.h | |
7bfd3b9e | 182 | |
413a1367 ML |
183 | ## delete guile-snarf.awk from the installation bindir, in case it's |
184 | ## lingering there due to an earlier guile version not having been | |
185 | ## wiped out. | |
186 | install-exec-hook: | |
b27b814d | 187 | rm -f $(DESTDIR)$(bindir)/guile-snarf.awk |
413a1367 | 188 | |
7bfd3b9e | 189 | ## This is kind of nasty... there are ".c" files that we don't want to |
1be6b49c ML |
190 | ## compile, since they are #included. So instead we list them here. |
191 | ## Perhaps we can deal with them normally once the merge seems to be | |
192 | ## working. | |
02e22775 | 193 | noinst_HEADERS = convert.i.c \ |
7ff8176b | 194 | conv-integer.i.c conv-uinteger.i.c \ |
652dbce6 | 195 | eval.i.c \ |
02e22775 | 196 | srfi-4.i.c \ |
06f9c814 | 197 | quicksort.i.c \ |
340c49bf | 198 | win32-uname.h win32-dirent.h win32-socket.h \ |
03291373 | 199 | private-gc.h private-options.h |
7bfd3b9e | 200 | |
78bda5f3 | 201 | libguile_la_DEPENDENCIES = @LIBLOBJS@ |
6caac03c | 202 | libguile_la_LIBADD = @LIBLOBJS@ $(gnulib_library) |
88686555 | 203 | libguile_la_LDFLAGS = @LTLIBINTL@ -version-info @LIBGUILE_INTERFACE_CURRENT@:@LIBGUILE_INTERFACE_REVISION@:@LIBGUILE_INTERFACE_AGE@ -export-dynamic -no-undefined |
733943b9 | 204 | |
54f16aec | 205 | # These are headers visible as <guile/mumble.h> |
ee2a8b9b JB |
206 | pkginclude_HEADERS = gh.h |
207 | ||
733943b9 | 208 | # These are headers visible as <libguile/mumble.h>. |
5380de6b | 209 | modincludedir = $(includedir)/libguile |
9b7952c0 MV |
210 | modinclude_HEADERS = __scm.h alist.h arbiters.h async.h backtrace.h \ |
211 | boolean.h chars.h continuations.h convert.h debug.h debug-malloc.h \ | |
212 | deprecation.h deprecated.h discouraged.h dynl.h dynwind.h \ | |
dd18d312 | 213 | eq.h error.h eval.h evalext.h extensions.h \ |
9b7952c0 | 214 | feature.h filesys.h fluids.h fports.h futures.h gc.h \ |
b89c4943 LC |
215 | gdb_interface.h gdbint.h gettext.h goops.h \ |
216 | gsubr.h guardians.h hash.h \ | |
9b7952c0 MV |
217 | hashtab.h hooks.h i18n.h init.h inline.h ioext.h iselect.h \ |
218 | keywords.h lang.h list.h load.h macros.h mallocs.h modules.h \ | |
219 | net_db.h numbers.h objects.h objprop.h options.h pairs.h ports.h \ | |
220 | posix.h regex-posix.h print.h procprop.h procs.h properties.h \ | |
221 | random.h ramap.h rdelim.h read.h root.h rw.h scmsigs.h validate.h \ | |
222 | script.h simpos.h smob.h snarf.h socket.h sort.h srcprop.h \ | |
223 | stackchk.h stacks.h stime.h strings.h srfi-4.h srfi-13.h srfi-14.h \ | |
224 | strorder.h strports.h struct.h symbols.h tags.h threads.h \ | |
225 | pthread-threads.h null-threads.h throw.h unif.h values.h \ | |
226 | variable.h vectors.h vports.h weaks.h | |
4725c298 | 227 | |
93ff93f6 | 228 | nodist_modinclude_HEADERS = version.h scmconfig.h |
733943b9 | 229 | |
604a672e TTN |
230 | bin_SCRIPTS = guile-snarf |
231 | ||
f94b6524 TTN |
232 | # We can re-enable install for some of these if/when they are documented |
233 | # and people feel like maintaining them. For now, this is not the case. | |
604a672e | 234 | noinst_SCRIPTS = guile-doc-snarf guile-snarf-docs guile-func-name-check |
adb75a41 | 235 | |
41973b48 MV |
236 | EXTRA_DIST = ChangeLog-gh ChangeLog-scm ChangeLog-threads \ |
237 | ChangeLog-1996-1999 ChangeLog-2000 cpp_signal.c \ | |
a3451a59 MV |
238 | cpp_errno.c cpp_err_symbols.in cpp_err_symbols.c \ |
239 | cpp_sig_symbols.c cpp_sig_symbols.in cpp_cnvt.awk \ | |
9b7952c0 | 240 | c-tokenize.lex version.h.in \ |
b89c4943 | 241 | scmconfig.h.top libgettext.h |
c99f9605 ML |
242 | # $(DOT_DOC_FILES) $(EXTRA_DOT_DOC_FILES) \ |
243 | # guile-procedures.txt guile.texi | |
733943b9 | 244 | |
d8a20ddb RB |
245 | ## We use @-...-@ as the substitution brackets here, instead of the |
246 | ## usual @...@, so autoconf doesn't go and substitute the values | |
247 | ## directly into the left-hand sides of the sed substitutions. *sigh* | |
248 | version.h: version.h.in | |
8ab3d8a0 | 249 | sed < $(srcdir)/version.h.in > $@.tmp \ |
d8a20ddb RB |
250 | -e s:@-GUILE_MAJOR_VERSION-@:${GUILE_MAJOR_VERSION}: \ |
251 | -e s:@-GUILE_MINOR_VERSION-@:${GUILE_MINOR_VERSION}: \ | |
252 | -e s:@-GUILE_MICRO_VERSION-@:${GUILE_MICRO_VERSION}: | |
253 | mv $@.tmp $@ | |
254 | ||
fef07353 | 255 | ## FIXME: Consider using timestamp file, to avoid unnecessary rebuilds. |
90ff3ec5 | 256 | libpath.h: $(srcdir)/Makefile.in $(top_builddir)/config.status |
54f16aec | 257 | @echo "Generating libpath.h..." |
e151bee6 JB |
258 | @rm -f libpath.tmp |
259 | @echo '/* generated by Makefile */' > libpath.tmp | |
260 | @echo '#define SCM_PKGDATA_DIR "$(pkgdatadir)"' >> libpath.tmp | |
d8a20ddb | 261 | @echo '#define SCM_LIBRARY_DIR "$(pkgdatadir)/$(GUILE_EFFECTIVE_VERSION)"'>>libpath.tmp |
e151bee6 JB |
262 | @echo '#define SCM_SITE_DIR "$(pkgdatadir)/site"' >> libpath.tmp |
263 | @echo '#define SCM_BUILD_INFO { \' >> libpath.tmp | |
264 | @echo ' { "srcdir", "'"`cd @srcdir@; pwd`"'" }, \' >> libpath.tmp | |
c565712c | 265 | @echo ' { "top_srcdir", "@top_srcdir_absolute@" }, \' >> libpath.tmp |
e151bee6 JB |
266 | @echo ' { "prefix", "@prefix@" }, \' >> libpath.tmp |
267 | @echo ' { "exec_prefix", "@exec_prefix@" }, \' >> libpath.tmp | |
268 | @echo ' { "bindir", "@bindir@" }, \' >> libpath.tmp | |
269 | @echo ' { "sbindir", "@sbindir@" }, \' >> libpath.tmp | |
270 | @echo ' { "libexecdir", "@libexecdir@" }, \' >> libpath.tmp | |
271 | @echo ' { "datadir", "@datadir@" }, \' >> libpath.tmp | |
272 | @echo ' { "sysconfdir", "@sysconfdir@" }, \' >> libpath.tmp | |
273 | @echo ' { "sharedstatedir", "@sharedstatedir@" }, \' >> libpath.tmp | |
274 | @echo ' { "localstatedir", "@localstatedir@" }, \' >> libpath.tmp | |
275 | @echo ' { "libdir", "@libdir@" }, \' >> libpath.tmp | |
276 | @echo ' { "infodir", "@infodir@" }, \' >> libpath.tmp | |
277 | @echo ' { "mandir", "@mandir@" }, \' >> libpath.tmp | |
278 | @echo ' { "includedir", "@includedir@" }, \' >> libpath.tmp | |
279 | @echo ' { "pkgdatadir", "$(datadir)/@PACKAGE@" }, \' >> libpath.tmp | |
280 | @echo ' { "pkglibdir", "$(libdir)/@PACKAGE@" }, \' >> libpath.tmp | |
281 | @echo ' { "pkgincludedir", "$(includedir)/@PACKAGE@" }, \' \ | |
282 | >> libpath.tmp | |
b6fae158 | 283 | @echo ' { "guileversion", "@GUILE_VERSION@" }, \' >> libpath.tmp |
54f16aec TTN |
284 | @echo ' { "libguileinterface", "@LIBGUILE_INTERFACE@" }, \' \ |
285 | >> libpath.tmp | |
30dda257 | 286 | @echo ' { "LIBS", "@GUILE_LIBS@" }, \' >> libpath.tmp |
5bbc5359 | 287 | @echo ' { "CFLAGS", "@GUILE_CFLAGS@" }, \' >> libpath.tmp |
54f16aec | 288 | @echo ' { "buildstamp", "'"`date`"'" }, \' >> libpath.tmp |
e151bee6 JB |
289 | @echo '}' >> libpath.tmp |
290 | @mv libpath.tmp libpath.h | |
733943b9 | 291 | |
3dc81fba | 292 | |
e9c3d3f9 TTN |
293 | snarfcppopts = $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) |
294 | ||
3dc81fba | 295 | SUFFIXES = .x .doc |
733943b9 | 296 | .c.x: |
2c7a286a | 297 | ./guile-snarf -o $@ $< $(snarfcppopts) |
c99f9605 | 298 | .c.doc: |
23d72566 | 299 | -$(AWK) -f ./guile-func-name-check $< |
e9c3d3f9 | 300 | (./guile-snarf-docs $(snarfcppopts) $< | \ |
af68e5e5 | 301 | ./guile_filter_doc_snarfage$(EXEEXT) --filter-snarfage) > $@ || { rm $@; false; } |
733943b9 | 302 | |
23f2b9a3 | 303 | $(DOT_X_FILES) $(EXTRA_DOT_X_FILES): scmconfig.h snarf.h guile-snarf.in |
c99f9605 | 304 | |
23f2b9a3 | 305 | $(DOT_DOC_FILES) $(EXTRA_DOT_DOC_FILES): scmconfig.h snarf.h guile-snarf-docs.in guile_filter_doc_snarfage$(EXEEXT) |
66418d34 | 306 | |
faf6a29b MV |
307 | error.x: cpp_err_symbols.c |
308 | posix.x: cpp_sig_symbols.c | |
309 | load.x: libpath.h | |
310 | ||
58ed8bc6 | 311 | include $(top_srcdir)/am/pre-inst-guile |
cecb4a5e | 312 | |
f8241358 | 313 | alldotdocfiles = $(DOT_DOC_FILES) $(EXTRA_DOT_DOC_FILES) |
b32fca0f | 314 | snarf2checkedtexi = GUILE="$(GUILE_FOR_BUILD)" $(top_srcdir)/scripts/snarf-check-and-output-texi |
f8241358 TTN |
315 | dotdoc2texi = cat $(alldotdocfiles) | $(snarf2checkedtexi) |
316 | ||
2e945bcc | 317 | guile.texi: $(alldotdocfiles) guile$(EXEEXT) |
f8241358 TTN |
318 | $(dotdoc2texi) --manual > $@ || { rm $@; false; } |
319 | ||
2e945bcc | 320 | guile-procedures.texi: $(alldotdocfiles) guile$(EXEEXT) |
f8241358 | 321 | $(dotdoc2texi) > $@ || { rm $@; false; } |
9d29e990 | 322 | |
9df3eecc MV |
323 | if HAVE_MAKEINFO |
324 | ||
cecb4a5e | 325 | guile-procedures.txt: guile-procedures.texi |
9d29e990 | 326 | rm -f $@ |
f7742034 | 327 | makeinfo --force -o $@ guile-procedures.texi || test -f $@ |
4079f87e | 328 | |
9df3eecc MV |
329 | else |
330 | ||
331 | guile-procedures.txt: guile-procedures.texi | |
f7742034 | 332 | cp guile-procedures.texi $@ |
9df3eecc MV |
333 | |
334 | endif | |
335 | ||
30e3be5a | 336 | c-tokenize.c: c-tokenize.lex |
47ac1e47 | 337 | flex -t $(srcdir)/c-tokenize.lex > $@ || { rm $@; false; } |
30e3be5a | 338 | |
d8a20ddb | 339 | schemelibdir = $(pkgdatadir)/$(GUILE_EFFECTIVE_VERSION) |
8dc9439f | 340 | schemelib_DATA = guile-procedures.txt |
4079f87e | 341 | |
733943b9 TT |
342 | ## Add -MG to make the .x magic work with auto-dep code. |
343 | MKDEP = gcc -M -MG $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) | |
ee78fbb0 | 344 | |
a9c093e2 | 345 | cpp_err_symbols.c: cpp_err_symbols.in cpp_cnvt.awk |
a0e90145 | 346 | $(AWK) -f $(srcdir)/cpp_cnvt.awk < $(srcdir)/cpp_err_symbols.in > \ |
593d151f JB |
347 | cpp_err_symbols.tmp |
348 | mv cpp_err_symbols.tmp cpp_err_symbols.c | |
ee78fbb0 | 349 | |
a9c093e2 | 350 | cpp_sig_symbols.c: cpp_sig_symbols.in cpp_cnvt.awk |
a0e90145 | 351 | $(AWK) -f $(srcdir)/cpp_cnvt.awk < $(srcdir)/cpp_sig_symbols.in > \ |
593d151f JB |
352 | cpp_sig_symbols.tmp |
353 | mv cpp_sig_symbols.tmp cpp_sig_symbols.c | |
67ec3667 | 354 | |
a0e90145 | 355 | ## Create a new version of the cpp_sig_symbols.in file, including all SIGXXX |
67ec3667 GH |
356 | ## macros defined on this platform. |
357 | check_signals: | |
358 | gcc -undef -dM -E $(srcdir)/cpp_signal.c | egrep ' SIG[A-Z]+' \ | |
359 | | cut -f2 -d' ' | sort > cpp_sig_symbols_here | |
a0e90145 JB |
360 | diff -u $(srcdir)/cpp_sig_symbols.in cpp_sig_symbols_here \ |
361 | | egrep '^\+S' \ | |
67ec3667 GH |
362 | | cut -c2- > cpp_sig_symbols_diff |
363 | if test -s cpp_sig_symbols_diff ; then \ | |
a0e90145 | 364 | cat $(srcdir)/cpp_sig_symbols.in cpp_sig_symbols_diff \ |
67ec3667 GH |
365 | | sort > cpp_sig_symbols_new ;\ |
366 | echo "cpp_sig_symbols_new has the following additions:" ;\ | |
367 | cat cpp_sig_symbols_diff ;\ | |
368 | else echo "No new symbols found."; \ | |
369 | fi | |
370 | ||
a0e90145 | 371 | ## Likewise for cpp_err_symbols.in. |
67ec3667 GH |
372 | check_errnos: |
373 | gcc -undef -dM -E $(srcdir)/cpp_errno.c | egrep ' E.+' \ | |
374 | | cut -f2 -d' ' | sort > cpp_err_symbols_here | |
a0e90145 JB |
375 | diff -u $(srcdir)/cpp_err_symbols.in cpp_err_symbols_here \ |
376 | | egrep '^\+E' \ | |
67ec3667 GH |
377 | | cut -c2- > cpp_err_symbols_diff |
378 | if test -s cpp_err_symbols_diff ; then \ | |
a0e90145 | 379 | cat $(srcdir)/cpp_err_symbols.in cpp_err_symbols_diff \ |
67ec3667 GH |
380 | | sort > cpp_err_symbols_new ;\ |
381 | echo "cpp_err_symbols_new has the following additions:" ;\ | |
382 | cat cpp_err_symbols_diff ;\ | |
383 | else echo "No new symbols found."; \ | |
384 | fi | |
385 | ||
ad6b30a0 TP |
386 | MOSTLYCLEANFILES = \ |
387 | cpp_err_symbols_here cpp_err_symbols_diff cpp_err_symbols_new \ | |
d8a20ddb RB |
388 | cpp_sig_symbols_here cpp_sig_symbols_diff cpp_sig_symbols_new \ |
389 | version.h version.h.tmp \ | |
390 | scmconfig.h scmconfig.h.tmp | |
ad6b30a0 | 391 | |
cecb4a5e | 392 | CLEANFILES = libpath.h *.x *.doc guile-procedures.txt guile-procedures.texi guile.texi |
ee0c0e03 ML |
393 | |
394 | MAINTAINERCLEANFILES = c-tokenize.c |