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

33 commits

Author SHA1 Message Date
Rob Browning
17403ebcaf * _scm.h: fix various preprocessor usages of new public symbols to
expect 0 or 1 values rather than 1 or undefined.  i.e. change
#ifdef to #if, etc.
2003-03-27 19:55:45 +00:00
Rob Browning
b49ed9c97f * _scm.h: #include <config.h> if HAVE_CONFIG_H.
Rename usage of USE_PTHREAD_THREADS to SCM_USE_PTHREAD_THREADS.
2003-03-25 23:52:18 +00:00
Mikael Djurfeldt
9bc4701cd3 * __scm.h (SCM_ALLOW_INTS_ONLY): Removed.
(SCM_NONREC_CRITICAL_SECTION_START,
SCM_NONREC_CRITICAL_SECTION_END, SCM_REC_CRITICAL_SECTION_START,
SCM_REC_CRITICAL_SECTION_END): New macros.
(SCM_CRITICAL_SECTION_START/END): Defined here.

* eval.c: Insert SOURCE_SECTION_START / SOURCE_SECTION_END around
the three calls to scm_m_expand_body.

* gc.h: #include "libguile/pthread-threads.h";
(SCM_FREELIST_CREATE, SCM_FREELIST_LOC): New macros.

* gc.c (scm_i_freelist, scm_i_freelist2): Defined to be of type
scm_t_key;

* gc.c, gc-freelist.c, inline.h: Use SCM_FREELIST_LOC for freelist
access.

* gc-freelist.c (scm_gc_init_freelist): Create freelist keys.

* gc-freelist.c, threads.c (really_launch): Use
SCM_FREELIST_CREATE.

* gc-malloc.c (scm_realloc, scm_gc_register_collectable_memory):

* gc.c (scm_i_expensive_validation_check, scm_gc,
scm_gc_for_newcell): Put threads to sleep before doing GC-related
heap administration so that those pieces of code are executed
single-threaded.  We might consider rewriting these code sections
in terms of a "call_gc_code_singly_threaded" construct instead of
calling the pair of scm_i_thread_put_to_sleep () and
scm_i_thread_wake_up ().  Also, we would want to have as many of
these sections eleminated.

* init.c (scm_init_guile_1): Call scm_threads_prehistory.

* inline.h: #include "libguile/threads.h"

* pthread-threads.h: Macros now conform more closely to the
pthreads interface.  Some of them now take a second argument.

* threads.c, threads.h: Many changes.

* configure.in: Temporarily replaced "copt" threads option with new
option "pthreads".
(USE_PTHREAD_THREADS): Define if pthreads configured.
2002-12-09 13:42:58 +00:00
Marius Vollmer
3d7f708f21 * __scm.h (USE_THREADS, GUILE_ISELECT): Define when
SCM_DEBUG_DEPRECATED.  Removed their use thru-out Guile.
2002-11-03 22:09:20 +00:00
Marius Vollmer
845944c3d9 (HAVE_RESTARTABLE_SYSCALLS): Do define even when
SCM_COPT_THREADS is defined.
(SCM_SYSCALL): Use EINTR-expection version when SCM_COPT_THREADS
is defined.
2002-11-03 01:01:43 +00:00
Marius Vollmer
cfe062d097 Include <errno.h< so that SCM_SYSCALL is correctly
defined when HAVE_RESTARTABLE_SYSCALLS is not defined.
(HAVE_RESTARTABLE_SYSCALLS): Do not define when USE_COPT_THREADS
is defined.
2002-11-02 01:01:00 +00:00
Han-Wen Nienhuys
34d19ef643 2002-07-20 Han-Wen <hanwen@cs.uu.nl>
* *.c: add space after commas everywhere.

* *.c: use SCM_VECTOR_SET everywhere, where a vector is written.
Document cases where SCM_WRITABLE_VELTS() is used.

* vectors.h (SCM_VELTS): prepare for write barrier, and let
SCM_VELTS() return a const pointer
(SCM_VECTOR_SET): add macro.

* autogen.sh (mscripts): find and check version number of
autoconf. Complain if 2.53 is not found.
2002-07-20 14:08:34 +00:00
Marius Vollmer
0f633e6683 Include "libguile/inline.h". 2001-11-25 15:03:28 +00:00
Dirk Herrmann
0527e68763 * Renamed header macros to the SCM_<filename>_H format. 2001-08-31 10:42:19 +00:00
Martin Grabmüller
82893676f4 Make compilation under Windows easier. 2001-06-26 17:53:09 +00:00
Marius Vollmer
86d31dfe7d Merge from mvo-vcell-cleanup-1-branch. 2001-05-15 14:57:22 +00:00
Mikael Djurfeldt
e6e2e95aa5 * _scm.h: Removed #include <errno.h>.
* error.c, net_db.c, putenv.c, stime.c: Removed declaration of
errno variable (can be a macro on some systems, for example when
using linux libc with threads).

* error.c, filesys.c, gc.c, ioext.c, iselect.c, net_db.c, ports.c,
posix.c, print.c, putenv.c, scmsigs.c, script.c, simpos.c, smob.c,
socket.c, srcprop.c, stime.c, strop.c, unif.c, vports.c: Added
#include <errno.h> in these 20 out of 100 files.
2001-03-10 16:56:09 +00:00
Dirk Herrmann
5610071627 * Makefile.am: Let 'make clean' remove *.x and *.doc files.
* Renamed SCM_STRICT_TYPING to SCM_DEBUG_TYPING_STRICTNESS.
* Removed conditionally compiled code for Turbo C.
* gdbint.c:  Eliminated call to scm_tag.
2000-05-16 12:11:08 +00:00
Mikael Djurfeldt
a059974535 * Makefile.am (DEFS): Added. automake adds -I options to DEFS,
and we don't want that.
(INCLUDES): Removed all -I options except for the root source
directory and the root build directory.

* *.*: Change includes so that they always use the "prefixes"
libguile/, qt/, guile-readline/, or libltdl/.
(Thanks to Tim Mooney.)
2000-04-21 14:16:44 +00:00
Michael Livshin
89e00824a0 * *.[hc]: add Emacs magic at the end of file, to ensure GNU
indentation style.
2000-03-19 19:01:16 +00:00
Dirk Herrmann
28b3236d36 Only include async.h where it is actually needed. 2000-03-18 09:16:48 +00:00
Dirk Herrmann
ba11fd4cb6 Only include root.h where it is actually needed. 2000-03-18 08:44:04 +00:00
Dirk Herrmann
7ab3fdd51f Only include strings.h where it is actually needed. 2000-03-17 18:11:58 +00:00
Dirk Herrmann
f04d8caf82 Only include ports.h where it is actually needed. 2000-03-17 16:10:13 +00:00
Dirk Herrmann
003d1fd046 Only include vectors.h in those files, where it is actually needed. 2000-03-17 15:23:03 +00:00
Jim Blandy
176067df1a Doc fix. 2000-03-16 21:11:45 +00:00
Gary Houston
08b8c6948d 1999-09-18 Gary Houston <ghouston@freewire.co.uk>
* configure.in: use AC_SYS_RESTARTABLE_SYSCALLS instead of
	testing for SA_RESTART.

1999-09-18  Gary Houston  <ghouston@freewire.co.uk>

	* _scm.h, scmsigs.c: replace HAVE_RESTARTS with
	HAVE_RESTARTABLE_SYSCALLS.
1999-09-18 17:13:38 +00:00
Gary Houston
e1a191a8ca * scmsigs.h, async.h: updated.
* _scm.h: if HAVE_RESTARTS is defined then don't use a SYSCALL
loop.

* posix.c (scm_uname): interpret only negative values as an error.
Solaris normally returns a positive value.

* script.c (scm_compile_shell_switches): if we are not going into
an interactive repl, set scm_mask_ints to zero so that asyncs can
run.

* simpos.c (scm_system):  don't ignore/unignore signals around
the "system" call.

* posix.c (scm_open_pipe): don't ignore/unignore signals around
the "popen" call.

* init.c (scm_boot_guile_1): don't call scm_init_signals, it's
done in boot-9.scm instead.

* scmsigs.c, async.c: Major rewriting of signal handling code.
(scm_sigaction): new procedure.
(scm_sleep): don't wrap sleep in SCM_SYSCALL, it would mess up the
timing.
(scm_raise): return unspecified, throw error on failure.

* boot-9.scm: signal-handler, alarm-thunk: removed.
don't define ticks-interrupt etc.
top-repl: install signal handlers for SIGINT, SIGFPE, SIGSEGV, SIGBUS
during call to scm-style-repl.

* acconfig.h: mention HAVE_RESTARTS.
* configure.in: check for sigaction and restartable system calls.
1997-05-31 19:02:38 +00:00
Jim Blandy
82892beda5 * Lots of files: New address for FSF. 1997-05-26 22:34:48 +00:00
Jim Blandy
7bfd3b9e94 Merge threads directory into libguile.
* coop-defs.h, coop-threads.c, coop-threads.h, coop.c, threads.c,
threads.h: New source files.
* Makefile.am (EXTRA_libguile_la_SOURCES): Add threads.c.
(noinst_HEADERS): Add coop-threads.c, coop-threads.h, coop.c
here; see comment.
(modinclude_HEADERS): Add threads.h, coop-defs.h.
(EXTRA_DIST): Add fsu-pthreads.h, mit-pthreads.c, mit-pthreads.h,
coop-threads.c.cygnus, coop-threads.h.cygnus.
* configure.in: If we're using threads, include threads.o in
LIBOBJS.
* _scm.h, libguile.h: threads.h lives in this directory now.
* fsu-pthreads.h, mit-pthreads.c, mit-pthreads.h,
coop-threads.c.cygnus, coop-threads.h.cygnus: New files, not
currently used, but brought along for information's sake.
* ChangeLog-threads: log from old 'threads' directory.
* Makefile.in, configure: Rebuilt.
1997-04-15 01:34:36 +00:00
Mikael Djurfeldt
e412e180d4 * _scm.h: Added #ifndef around definition of macros min and max. 1996-11-02 20:52:58 +00:00
Jim Blandy
5b4215a8b5 * snarf.h: New file.
* guile-snarf.sh: New file.
* Makefile.in (inner_h_files): Added snarf.h
(ancillary, install, uninstall, distclean): Added actions for
guile-snarf.
(.c.x): Use guile-snarf.
(guile-snarf): New rule, to produce guile-snarf from guile-snarf.sh.
(gen_c_files): Note that these depend on guile-snarf.
* _scm.h: Removed the snarfing macros (SCM_PROC, etc). They are
now in "snarf.h".  Added #include "snarf.h" to get them.
* configure.in: Added guile-snarf to AC_OUTPUT
* libguile.h: Added #include "snarf.h".
(Patches applied and tweaked by Jim Blandy.)
1996-10-29 20:49:56 +00:00
Mikael Djurfeldt
462a6f1f0c * _scm.h (min, max): Added.
* async.c: Moved `min' macro to _scm.h.
1996-10-14 03:24:01 +00:00
Jim Blandy
ddef832786 * _scm.h: #include "print.h" here, since it seems to be used just
about everywhere.
* eval.c, gdbint.c, genio.h, numbers.h, smob.h, srcprop.c,
strports.c, unif.h: Don't #include "print.h".
1996-10-03 05:44:52 +00:00
Mikael Djurfeldt
1764973d10 * _scm.h: Added conditional #include "threads.h" 1996-10-01 03:15:33 +00:00
Jim Blandy
c01fdefe6e * _scm.h (SCM_PROC): Extraneous semicolon (outside functions)
removed.
1996-09-11 20:23:30 +00:00
Jim Blandy
20e6290e38 C files should #include only the header files they need, not
libguile.h (which #includes all the header files); the pointless
recompilation was wasting my time.
* Makefile.in (all .o dependency lists): Regenerated.
* libguile.h: Don't try to get a definition for size_t here...
* __scm.h: Do it here.
* _scm.h: Since this is the internal libguile header, put things
here that all (or a majority) of the libguile files will want.
Don't #include <libguile.h> here; that generates dependencies on
way too much.  Instead, get "__scm.h", "error.h", "pairs.h",
"list.h", "gc.h", "gsubr.h", "procs.h", "numbers.h", "symbols.h",
"boolean.h", "strings.h", "vectors.h", "root.h", "ports.h", and
"async.h".
* alist.c: Get "eq.h", "list.h", "alist.h".
* append.c: Get "append.h", "list.h".
* arbiters.c: Get "arbiters.h", "smob.h".
* async.c: Get "async.h", "smob.h", "throw.h", "eval.h".
* boolean.c: Get "boolean.h".
* chars.c: Get "chars.h".
* continuations.c: Get "continuations.h", "dynwind.h", "debug.h",
"stackchk.h".
* debug.c: Get "debug.h", "feature.h", "read.h", "strports.h",
"continuations.h", "alist.h", "srcprop.h", "procprop.h", "smob.h",
"genio.h", "throw.h", "eval.h".
* dynwind.c: Get "dynwind.h", "alist.h", "eval.h".
* eq.c: Get "eq.h", "unif.h", "smob.h", "strorder.h",
"stackchk.h".
* error.c: Get "error.h", "throw.h", "genio.h", "pairs.h".
* eval.c: Get "eval.h", "stackchk.h", "srcprop.h", "debug.h",
"hashtab.h", "procprop.h", "markers.h", "smob.h", "throw.h",
"continuations.h", "eq.h", "sequences.h", "alist.h", "append.h",
"debug.h".
* fdsocket.c: Get "fdsocket.h", "unif.h", "filesys.h".
* feature.c: Get "feature.h".
* files.c: Get "files.h".
* filesys.c: Get "filesys.h", "smob.h", "genio.h".
* fports.c: Get "fports.h", "markers.h".
* gc.c: Get "async.h", "unif.h", "smob.h", "weaks.h",
"genio.h", "struct.h", "stackchk.h", "stime.h".
* gdbint.c: Get "gdbint.h", "chars.h", "eval.h", "print.h",
"read.h", "strports.h", "tag.h".
* genio.c: Get "genio.h", "chars.h".
* gsubr.c: Get "gsubr.h", "genio.h".
* hash.c: Get "hash.h", "chars.h".
* hashtab.c: Get "hashtab.h", "eval.h", "hash.h", "alist.h".
* init.c: Get everyone who has an scm_init_mumble function:
"weaks.h", "vports.h", "version.h", "vectors.h", "variable.h",
"unif.h", "throw.h", "tag.h", "symbols.h", "struct.h",
"strports.h", "strorder.h", "strop.h", "strings.h", "stime.h",
"stackchk.h", "srcprop.h", "socket.h", "simpos.h", "sequences.h",
"scmsigs.h", "read.h", "ramap.h", "procs.h", "procprop.h",
"print.h", "posix.h", "ports.h", "pairs.h", "options.h",
"objprop.h", "numbers.h", "mbstrings.h", "mallocs.h", "load.h",
"list.h", "kw.h", "ioext.h", "hashtab.h", "hash.h", "gsubr.h",
"gdbint.h", "gc.h", "fports.h", "filesys.h", "files.h",
"feature.h", "fdsocket.h", "eval.h", "error.h", "eq.h",
"dynwind.h", "debug.h", "continuations.h", "chars.h", "boolean.h",
"async.h", "arbiters.h", "append.h", "alist.h".
* ioext.c: Get "ioext.h", "fports.h".
* kw.c: Get "kw.h", "smob.h", "mbstrings.h", "genio.h".
* list.c: Get "list.h", "eq.h".
* load.c: Get "load.h", "eval.h", "read.h", "fports.h".
* mallocs.c: Get "smob.h", "genio.h".
* markers.c: Get "markers.h".
* mbstrings.c: Get "mbstrings.h", "read.h", "genio.h", "unif.h",
"chars.h".
* numbers.c: Get "unif.h", "genio.h".
* objprop.c: Get "objprop.h", "weaks.h", "alist.h", "hashtab.h".
* options.c: Get "options.h".
* ports.c: Get "ports.h", "vports.h", "strports.h", "fports.h",
"markers.h", "chars.h", "genio.h".
* posix.c: Get "posix.h", "sequences.h", "feature.h", "unif.h",
"read.h", "scmsigs.h", "genio.h", "fports.h".
* print.c: Get "print.h",  "unif.h", "weaks.h", "read.h",
"procprop.h", "eval.h", "smob.h", "mbstrings.h", "genio.h",
"chars.h".
* procprop.c: Get "procprop.h", "eval.h", "alist.h".
* procs.c: Get "procs.h".
* ramap.c: Get "ramap.h", "feature.h", "eval.h", "eq.h",
"chars.h", "smob.h", "unif.h".
* read.c: Get "alist.h", "kw.h", "mbstrings.h", "unif.h",
"eval.h", "genio.h", "chars.h".
* root.c: Get "root.h", "stackchk.h".
* scmsigs.c: Get "scmsigs.h".
* sequences.c: Get "sequences.h".
* simpos.c: Get "simpos.h", "scmsigs.h".
* smob.c: Get "smob.h".
* socket.c: Get "socket.h", "feature.h".
* srcprop.c: Get "srcprop.h", "weaks.h", "hashtab.h", "debug.h",
"alist.h", "smob.h".
* stackchk.c: Get "stackchk.h", "genio.h".
* stime.c: Get "stime.h"."libguile/continuations.h".
* strings.c: Get "strings.h", "chars.h".
* strop.c: Get "strop.h", "chars.h".
* strorder.c: Get "strorder.h", "chars.h".
* strports.c: Get "strports.h", "print.h", "eval.h", "unif.h".
* struct.c: Get "struct.h", "chars.h".
* symbols.c: Get "symbols.h", "mbstrings.h", "alist.h",
"variable.h", "eval.h", "chars.h".
* tag.c: Get "tag.h", "struct.h", "chars.h".
* throw.c: Get "throw.h", "continuations.h", "debug.h",
"dynwind.h", "eval.h", "alist.h", "smob.h", "genio.h".
* unif.c: Get "unif.h", "feature.h", "strop.h", "sequences.h",
"smob.h", "genio.h", "eval.h", "chars.h".
* variable.c: Get "variable.h", "smob.h", "genio.h".
* vectors.c: Get "vectors.h", "eq.h".
* version.c: Get "version.h".
* vports.c: Get "vports.h", "fports.h", "chars.h", "eval.h".
* weaks.c: Get "weaks.h".
1996-09-10 02:26:07 +00:00
Jim Blandy
0f2d19dd46 maintainer changed: was lord, now jimb; first import 1996-07-25 22:56:11 +00:00