1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-04-30 11:50:28 +02:00
Commit graph

32 commits

Author SHA1 Message Date
BT Templeton
95c1cfb550 fix guile-snarf
* libguile/snarf.h: New macro `SCM_SNARF_INIT_PREFIX'. (SCM_SNARF_INIT)
  Use `SCM_SNARF_INIT_PREFIX' instead of including a literal marker. If
  the preprocessor echoes #define directives to its output, this will
  prevent `guile-snarf' from snarfing the `SCM_SNARF_INIT' definition
  itself. Reported by Mike Gran <spk121@yahoo.com>.
* libguile/guile-snarf.in (modern_snarf): Don't output anything for
  lines in which only one of the magic snarfing markers is present.
  Modify the `sed' program for compatibility with POSIX `sed'. The new
  `sed' program is based on a version by Wolfgang Jenkner
  <wjenkner@inode.at>.
* test-suite/standalone/test-guile-snarf: New tests.
2011-03-20 10:22:44 +01:00
BT Templeton
fd029c35de guile-snarf: allow multiple init actions on one line
* libguile/guile-snarf.in (modern_snarf): Allow programs to specify
  multiple initialization actions on a single line. This makes it
  possible for C programs to define multiple subrs with a single macro
  invocation.

* test-suite/standalone/test-guile-snarf: Enable more tests.
2011-03-04 11:34:24 +01:00
Ludovic Courtès
5f236208d0 Merge branch 'boehm-demers-weiser-gc' into bdw-gc-static-alloc
Conflicts:
	acinclude.m4
	libguile/strings.c
2009-09-02 01:37:37 +02:00
Neil Jerram
53befeb700 Change Guile license to LGPLv3+
(Not quite finished, the following will be done tomorrow.
   module/srfi/*.scm
   module/rnrs/*.scm
   module/scripts/*.scm
   testsuite/*.scm
   guile-readline/*
)
2009-06-17 00:22:09 +01:00
Ludovic Courtès
6eca5d2b9b Allow several `SNARF_INIT ()' per CPP output line.
* libguile/guile-snarf.in (modern_snarf): Allow several `SNARF_INIT ()'
  per line.  This makes it possible to write snarffing macros that
  contain several `SNARF_INIT ()' invocations.
2009-01-31 21:06:40 +01:00
Ludovic Courtès
5b5179f895 guile-snarf: Honor $TMPDIR. 2008-02-12 14:26:37 +00:00
Kevin Ryde
2b829bbb3d merge from 1.8 branch 2006-04-17 00:05:42 +00:00
Marius Vollmer
92205699d0 The FSF has a new address. 2005-05-23 19:57:22 +00:00
Marius Vollmer
d9623da1f2 Instead of the non-portable mktemp, use mkdir to create a unique
temporary directory that we can safely use.  Thanks to Stefan
Nordhausen!
2004-01-10 23:30:23 +00:00
Marius Vollmer
27fca65629 Use mktemp to create a truely unique temporary file name. Thanks to
Stefan Nordhausen!
2004-01-10 21:20:55 +00:00
Marius Vollmer
34690e5338 Do not expect the input file to be the first argument after the
optional "-o" option, just pass everything to the pre-processor
without extracting the input file name.
2002-08-24 00:53:44 +00:00
Marius Vollmer
9d2cce766d Do not clean input file. This would write to the $(srcdir) during a
VPATH build, which is not allowed.  It also isn't needed since it only
works when an output filename has been specified and in that case we
don't need to clean the input file because the output file will
already exist.
2002-04-17 17:44:28 +00:00
Marius Vollmer
3be0d96d0f Install the trap for removing $cleanfile only when the value of
$cleanfile is actually known.
2002-04-16 20:12:10 +00:00
Marius Vollmer
66c4b10985 When the output filename is "-", write to stdout. When no "-o" option
is given, use "-" as the output filename (i.e., stdout).  Only 'clean'
the inputfile or remove the output file on error when the output file
name is not "-".  Define the preprocessor macro SCM_MAGIC_SNARFER
while snarfing.
2002-03-24 13:47:06 +00:00
Thien-Thi Nguyen
b193d130d8 Typofix. 2002-03-15 14:25:54 +00:00
Thien-Thi Nguyen
77b26c9397 Remove "--compat=1.4" support.
Add "-d" and "-D" support.

(deprecated_list): New var.
(compat_mode_clean_xxx): Delete.
(grep_deprecated): New func.
("main"): If "-d" or "-D", call `grep_deprecated'.
2002-03-15 14:00:02 +00:00
Marius Vollmer
d3bd0027d4 (modern_snarf): Remove everything following and including "^:^" from
the output.
2002-03-14 22:21:53 +00:00
Thien-Thi Nguyen
9bc6fb0a7d Update copyright.
Rewrite to internalize error handling.
Add commentary.
2002-03-14 03:19:30 +00:00
Martin Grabmüller
58ade1022c * alist.c, arbiters.c, async.h, backtrace.h, boolean.c, chars.c,
chars.h, continuations.h, debug-malloc.h, dynl.c, feature.c,
	feature.h, filesys.h, fluids.h, fports.h, gc_os_dep.c,
	gdb_interface.h, gh_eval.c, gh_funcs.c, gh_io.c, gh_list.c,
	gh_predicates.c, gsubr.c, gsubr.h, guardians.h,
	guile-func-name-check.in, guile-snarf-docs-texi.in,
	guile-snarf-docs.in, guile-snarf.awk.in, guile-snarf.in,
	hashtab.h, iselect.h, keywords.h, lang.c, list.h, load.h,
	objprop.c, objprop.h, options.c, options.h, random.h,
	regex-posix.h, root.c, root.h, script.c, snarf.h, stackchk.c,
	strerror.c, strop.h, strports.h, threads.h, values.c, values.h,
	version.c, version.h: Updated copyright notice.
2001-07-19 21:08:49 +00:00
Michael Livshin
47bcd6465f * filter-doc-snarfage.c, guile-snarf.in: try to cope with spaces
inside cookies.  thanks to Matthias Köppe!
2001-06-08 13:48:39 +00:00
Michael Livshin
c99f960518 * guile-snarf-docs.in, guile-snarf-docs-texi.in,
filter-doc-snarfage.c: new files.

* Makefile.am: add stuff to [build,] use and distribute
guile-snarf-docs, guile-snarf-docs-texi, guile_filter_doc_snarfage.

* guile-snarf.in: grok the new snarf output.

* snarf.h: make the output both texttools- and `read'-friendly.

* guile-doc-snarf.in (bindir): reimplement in terms of guile-snarf
and guile-snarf-docs.  (should also deprecate, I guess.  maybe
not).
2001-05-31 13:15:54 +00:00
Marius Vollmer
d6a35f3f61 Added copyright and licence notice. 2001-02-21 20:15:15 +00:00
Dirk Herrmann
3c6d9d717f * Renamed SCM__X tokens to better readable ones that also follow the
SCM_SNARF_ prefix convention.
2000-06-21 08:43:12 +00:00
Mikael Djurfeldt
e8ec2fd062 * guile-snarf.in: Change regexp "^SCM__I" --> "^ *SCM__I".
(The preprocessor might insert spaces before the identifier.)
2000-06-12 14:39:42 +00:00
Mikael Djurfeldt
d80f396e99 * snarf.h, guile-snarf.awk.in, guile-snarf.in: Replaced snarf
markers with identifiers (SCM__I, SCM__D, SCM__S, SCM__E).
(Thanks to Bernard Urban.)
2000-06-08 18:48:24 +00:00
Mikael Djurfeldt
7180cf39a7 * guile-snarf.awk.in, guile-snarf.in: Made to work also for
preprocessors which interpret $$$ and other markers as three
separate tokens and puts spaces in between.  NOTE: We could
replace %%% etc with real identifiers.  However, before the 1.4
release, we instead make minimal changes to the existing
system. (Thanks to Bernard Urban.)
2000-06-08 16:50:49 +00:00
Greg J. Badros
3dc81fbace * snarf.h: Drop SCM_PROC, SCM_PROC1. Added extra output for
guile-doc-snarf script.

* guile-doc-snarf.in, guile-doc-snarf.awk: New, simple doc
extraction system.  Builds foo.x, foo.doc from foo.{c,cc}.
There are dependencies between these files and snarf.h.  This
replaces guile-snarf.

* guile-snarf.in: Drop everything after $$$ for the new snarf.h
macros.  This is obsoleted by guile-doc-snarf, but kept here for
now for good measure.

* Makefile.am: Added guile-doc-snarf, guile-doc-snarf.awk to
bin_SCRIPTS.  Added .doc to SUFFIXES, and give rule for creating
.doc files to use guile-doc-snarf.  Update the rule for creating
.x files to use guile-doc-snarf.
1999-12-12 23:37:40 +00:00
Jim Blandy
7677589ac6 * guile-snarf.in: Be sure to exit with an error if CPP does.
* Makefile.am (.c.x): Delete the .x file and exit with an error
status if guile-snarf exits with an error status.
* Makefile.in: Regenerated.
1999-09-05 13:47:23 +00:00
Jim Blandy
63a646c5c5 * guile-snarf.in: Never generate an empty file. (Thanks to
Richard Polton.)
Bug reports from Russ McManus:
* guile-snarf.in: If the CPP environment variable is set, use that
as the C preprocessor, instead of the preprocessor autoconf
found.
* snarf.h (SCM_PROC): Cast the function pointer passed to
scm_make_gsubr, to satisfy C++.
1998-10-24 20:55:15 +00:00
Jim Blandy
f131e6311a * guile-snarf.in: Pass args through to gcc in a way that preserves
whitespace boundaries.  (Thanks to Greg Badros.)
1997-12-03 17:30:39 +00:00
Tim Pierce
bee1449102 Fixed Guile snarfing problem with SunPro suite. 1997-06-20 16:52:19 +00:00
Tom Tromey
adb75a4155 guile-snarf script once again used for creating .x files 1996-12-10 06:25:08 +00:00