1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-16 18:50:23 +02:00
Commit graph

341 commits

Author SHA1 Message Date
Cedric Cellier
c27411f180 Default to using poll(2) in `fport_input_waiting'.
* libguile/fports.c (fport_input_waiting): Use poll(2) instead of
  select(2) when possible.  Cosmetic changes by Ludovic Courtès.

* configure.in: Look for <poll.h> and `poll'.
2011-10-19 17:21:52 +02:00
Ludovic Courtès
de8ab91a76 Work around the lack of a vsnprintf(3) declaration on AIX 5.3.
* configure.in: Check for the vsnprintf(3) declaration.

* libguile/deprecation.c [!HAVE_DECL_VSNPRINTF]: Provide vsnprintf(3)
  declaration.  This is needed on `powerpc-ibm-aix5.3.0.0'.
2009-07-05 21:13:02 +02:00
Ludovic Courtès
7747b2d4f0 Fix the `BUILD_PTHREAD_SUPPORT' Automake conditional when not using pthread.
* configure.in: Set $build_pthread_support to "no" when thread support
  isn't built.  This fixes the `BUILD_PTHREAD_SUPPORT' Automake
  conditional.
2009-07-05 21:10:35 +02:00
Ludovic Courtès
3cd9d9bae2 Aggregate makefiles under `ice-9'.
* configure.in: Remove `ice-9/{debugger,debugging}/Makefile' from
  `AC_CONFIG_FILES'.

* ice-9/Makefile.am (SUBDIRS): Remove.
  (ice9_debugger_sources, ice9_debugging_sources): New variables.
  (subpkgdata_DATA): Remove
  (nobase_subpkgdata_DATA): New.
  (TAGS_FILES): Point to $(nobase_subpkgdata_DATA).
  (EXTRA_DIST): Add `$(ice9_debugger_sources) $(ice9_debugging_sources)'.
2009-07-04 01:57:44 +02:00
Neil Jerram
5e9dc714ca Remove AC_SYS_RESTARTABLE_SYSCALLS and related code
As the Autoconf documentation says, "These days portable programs
[...] should not rely on `HAVE_RESTARTABLE_SYSCALLS', since nowadays
whether a system call is restartable is a dynamic issue, not a
configuration-time issue."

In other words, if we ever rely on HAVE_RESTARTABLE_SYSCALLS, we are
at the mercy of any code that Guile happens to be linked with, because
that code could install a signal handler without the SA_RESTART flag,
and then a Guile system call could unexpectedly return EINTR.

The readline part of this goes back to this problem report:
excellent example of the above paragraph.  It was noted during the
discussion that undefining HAVE_RESTARTABLE_SYSCALLS would fix the
problem, but that solution wasn't adopted - I guess because Guile was
still using cooperative threads then (not pthreads) and so there was a
significant concern (whether founded or not) that not using
restartable syscalls (where available) could lead to a loss of
performance.

Now Guile's default mode of operation is with pthreads, where we
already don't assume that HAVE_RESTARTABLE_SYSCALLS is reliable, so
there is no possible further performance loss.  And in any case we
really have no choice, if we want correct operation.

* configure.in (AC_SYS_RESTARTABLE_SYSCALLS): Removed.

* doc/ref/posix.texi (Signals): Remove statement that Guile always
  sets SA_RESTART flag.

* guile-readline/configure.in (GUILE_SIGWINCH_SA_RESTART_CLEARED):
  Remove this setting, together with its test code.
  (HAVE_RL_PRE_INPUT_HOOK): Remove this setting and its code, as no
  longer needed.

* guile-readline/readline.c (sigwinch_enable_restart): Removed.
  (scm_init_readline): Remove setting of rl_pre_input_hook.

* libguile/_scm.h (SCM_SYSCALL): Remove the definition that relies on
  HAVE_RESTARTABLE_SYSCALLS.

* libguile/scmsigs.c (scm_sigaction_for_thread): Don't always set the
  SA_RESTART flag if available.  Update docstring accordingly.
  (scm_init_scmsigs): Remove code that sets SA_RESTART flag for all
  signals.
2009-06-18 20:35:45 +01:00
Ludovic Courtès
5d8f339fd8 Work around lack of flock(2) declaration on Tru64 5.1b.
* configure.in: Check for the declaration of flock(2).

* libguile/posix.c [!__MINGW32__][!HAVE_DECL_FLOCK]: Provide an flock(2)
  declaration, needed on Tru64 5.1b.
2009-05-11 22:54:45 +02:00
Ludovic Courtès
cabfe198fd Ask for IEEE floating point behavior on Alpha and SH.
* configure.in (CPPFLAGS): Add `-mieee' or `-ieee' on Alpha and SH.

* libguile/numbers.c (guile_ieee_init): Make sure `-mieee' was passed
  when using GCC on Alpha.

* NEWS: Update.
2009-05-11 22:11:25 +02:00
Ludovic Courtès
c50764e72e Use <machine/fpu.h> instead of <fenv.h> when needed (e.g., Tru64 5.1b).
* configure.in: Look for <machine/fpu.h>.

* test-suite/standalone/test-round.c: Use <machine/fpu.h> if available.
2009-04-23 22:51:27 +02:00
Ludovic Courtès
fbcc27cfef Work around lack of cuserid(3) declaration on Tru64 5.1b.
* configure.in: Check for a cuserid(3) declaration.

* libguile/posix.c [HAVE_CUSERID][!HAVE_DECL_CUSERID]: Provide a
  declaration.
2009-04-23 22:24:32 +02:00
Ludovic Courtès
d2469ca702 Work around the lack of hstrerror(3) declaration on Tru64.
* configure.in: Look for the declaration of hstrerror(3).

* libguile/net_db.c: Add hstrerror(3) declaration if
  `HAVE_DECL_HSTRERROR' is undefined.
2009-04-23 22:04:05 +02:00
Ludovic Courtès
df2870d385 Fix use of unsetenv(3) on Tru64.
* configure.in: Check for the declaration of unsetenv(3), which Tru64
  5.1b doesn't have.

* libguile/posix.c: Include <stdlib.h> since that's where POSIX says
  unsetenv(3) should reside.
  (scm_putenv): Don't attempt to use unsetenv(3) if its declaration
  isn't available since that wouldn't work well on Tru64.
2009-04-23 22:00:44 +02:00
daniel
5e5b073faa Make `--disable-deprecated' work.
* configure.in (enable_deprecated): Set SCM_WARN_DEPRECATED_DEFAULT
  even when --disable-deprecated is passed.
* libguile/deprecation.h: Declare deprecation-issuing methods even
  if SCM_ENABLE_DEPRECATED is not set.
* libguile/deprecation.c: Ditto.
  (scm_init_deprecation): Include full body even for unset
  SCM_ENABLE_DEPRECATED.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2009-04-21 22:11:48 +02:00
Ludovic Courtès
9a84dc8bbc Aggregate Makefile.am' files under examples/'.
* configure.in: Don't produce `examples/*/Makefile'.

* examples/Makefile.am (SUBDIRS): Remove.
  (EXTRA_DIST, AM_CFLAGS, AM_LIBS): New.
  (box/box, box/box.o, box-module/box, box-module/box.o, libbox.la,
  box-dynamic/box.lo, libbox-module.la, box-dynamic-module/box.lo,
  installcheck, CLEANFILES, clean-local): New targets, aggregated from
  `Makefile.am' files formerly in sub-directories.

* examples/check.test: New file, aggregated from `check.test' files in
  sub-directories.
2009-03-20 21:23:51 +01:00
Ludovic Courtès
60bdb533b2 Aggregate Makefile.am' files under lang/'.
* lang/Makefile.am (SUBDIRS): Remove.
  (elisp_sources): Aggregate the value of `elisp_SOURCES' formerly found
  in sub-directories' `Makefile.am'.
2009-03-08 22:29:02 +01:00
Neil Jerram
53a79cd060 Fix implementation of %fast-slot-ref and %fast-slot-set!
* libguile/goops.c (scm_sys_fast_slot_ref, scm_sys_fast_slot_set_x):
  Correct incantation for getting the number of slots of the specified
  instance.

* libguile/goops.h (SCM_NUMBER_OF_SLOTS): Removed (because wrong).

* test-suite/standalone/test-fast-slot-ref.in: New standalone test.

* configure.in: Generate test-suite/standalone/test-fast-slot-ref.

* test-suite/standalone/Makefile.am (check_SCRIPTS): Add
  test-fast-slot-ref.
2009-01-04 22:41:51 +00:00
Ludovic Courtès
200651f2d7 configure: Check for <ltdl.h>.
* configure.in: Check for <ltdl.h>, to clarify misconfigurations.
2008-12-10 10:06:46 +01:00
Ludovic Courtès
e6edcc18a5 configure: Don't substitute `DLPREOPEN'.
* configure.in: Don't substitute `DLPREOPEN' since it's no longer used
  (see commit 72db29f200).
2008-12-10 09:57:33 +01:00
Ludovic Courtès
0328bf6a0e Make GNU Libtool 2.2.x happier.
* configure.in: Use `AC_CONFIG_MACRO_DIR([m4])'.  Reverts patch
  b01284227e and makes `libtoolize' from
  Libtool 2 happier (removes a couple of warnings).

* Makefile.am (ACLOCAL_AMFLAGS): Remove `-I guile-config' since that
  directory only contains macros that we distribute, not macros that we
  use.
2008-11-30 19:37:29 +01:00
Neil Jerram
05675184ee Avoid Stack overflow' errors when running make check'
For explanation, see comments and text in the new file
libguile/measure-hwm.scm.

* .gitignore: Add libguile/stack-limit-calibration.scm.

* check-guile.in: Load libguile/stack-limit-calibration.scm.

* configure.in: Add AC_CONFIG_FILES to generate test-use-srfi from
  test-use-srfi.in.

* libguile/Makefile.am (TESTS, TESTS_ENVIRONMENT,
  stack-limit-calibration.scm): New targets, so that `make check'
  calibrates the stack limit before running the Guile test suite.

* libguile/measure-hwm.scm: New file, calibrates stack limit for `make
  check'.

* libguile/stackchk.c (scm_sys_get_stack_size): New primitive.

* libguile/stackchk.h (scm_sys_get_stack_size): New primitive
  (declaration).

* test-suite/standalone/test-use-srfi: Renamed test-use-srfi.in, so
  that ./configure can fill in variables in it.

* test-suite/standalone/test-use-srfi.in: Load
  libguile/stack-limit-calibration.scm.
2008-10-17 22:02:17 +01:00
Ludovic Courtès
b01284227e Use Simon Josefsson's `autobuild.m4'.
* Makefile.am (EXTRA_DIST): Add `m4/autobuild.m4'.
  (ACLOCAL_AMFLAGS): Add `-I m4'.

* configure.in: Invoke `AB_INIT'.

* m4/autobuild.m4: New file.
2008-09-11 21:48:23 +02:00
Ludovic Courtès
4e329a9569 Get rid of Automake's "maintainer mode".
* NEWS: Update.
* configure.in: Remove `AM_MAINTAINER_MODE' invocation.
* doc/Makefile.am, ice-9/Makefile.am: Ignore `MAINTAINER_MODE'
  conditional.
2008-09-09 18:07:03 +02:00
Ludovic Courtès
e210266510 Use AC_USE_SYSTEM_EXTENSIONS' instead of the obsolete AC_AIX', etc. 2008-08-20 19:02:41 +02:00
Ludovic Courtès
be97360245 Don't use AC_CONFIG_MACRO_DIR' in configure.in'. 2008-08-14 00:13:21 +02:00
Neil Jerram
adacd2dac5 Fix build failure on Debian hppa architecture (bad stack growth detection)
* configure.in (SCM_I_GSC_STACK_GROWS_UP): Remove use of
	AC_CACHE_CHECK, which was inadvertently causing
	SCM_I_GSC_STACK_GROWS_UP _always_ to be 0.
2008-08-07 23:26:21 +02:00
Ludovic Courtès
dc329592ff Handle lack of struct dirent64' and readdir64_r ()' on HP-UX 11.11. 2008-07-17 00:17:56 +02:00
Neil Jerram
9143131b27 Improve stack direction test
* configure.in: Update stack direction test to be like that in
	Autoconf _AC_LIBOBJ_ALLOCA and Gnulib; specifically in involving a
	function calling itself.
2008-07-12 19:32:35 +01:00
Ludovic Courtès
34ca35ed4d Update to Autoconf 2.61. 2008-07-06 21:03:37 +02:00
Ludovic Courtès
e01343d646 Modernize Automake files. 2008-06-28 22:14:40 +02:00
Ludovic Courtès
627bae78af Add `pkg-config' support. 2008-05-04 22:19:30 +02:00
Ludovic Courtès
e16733a84a Only run `test-with-guile-module' when pthread support is built. 2008-04-26 21:55:29 +02:00
Neil Jerram
b0f07fa20c Merge GDS (except for breakpoints) from CVS HEAD:
* debugger/commands.scm (evaluate, info-args, info-frame,
position, up, down): Improve/fix doc strings.

* Makefile.am (SUBDIRS): Add debugging.
(ice9_sources): Add gds-client.scm and gds-server.scm.

* scheme-debugging.texi: Remove lots of text that is now
duplicated (exactly) elsewhere, leaving only the `Tracing' node.

* guile.texi: Replace `Debugging Features' (scheme-debugging.texi)
by `Using Guile Interactively' and `Using Guile in Emacs'
(scheme-using.texi).  Move the `Tracing' content of
scheme-debugging.texi to the Modules section.

* api-options.texi (Evaluator trap options): Move doc for
with-traps and debug-object? to here.

* api-modules.texi (Included Guile Modules): Change reference from
`Debugging Features' to `Tracing'.

* api-evaluation.texi (Evaluator Behaviour): Add reference to
`Evaluator trap options'.

* api-debug.texi (Examining the Stack): Minor improvements to
display-backtrace doc.

* api-debug.texi (Debug on Error): New text on how to catch errors
and the error stack.

* api-debug.texi (High Level Traps): New.

* api-debug.texi (Debugging): New intro text.  New subsection
"Evaluation Model".  Moved existing subsections "Capturing the
Stack or Innermost Stack Frame", "Examining the Stack", "Examining
Stack Frames", "Source Properties", "Decoding Memoized Source
Expressions" and "Starting a New Stack" under "Evaluation Model".
(Capturing the Stack or Innermost Stack Frame): Some new text, and
correction to doc for last-stack-frame.
(Debug on Error): Renamed from "Interactive Debugging".

* configure.in (AC_CONFIG_FILES): Add emacs/Makefile and
ice-9/debugging/Makefile.

* Makefile.am (SUBDIRS): Add emacs.
2008-03-12 00:57:41 +00:00
Ludovic Courtès
6439b3dfd9 Look for `strncasecmp' declaration. 2008-02-22 09:24:37 +00:00
Ludovic Courtès
3034017fc5 Release Guile 1.8.4. 2008-02-17 00:13:16 +00:00
Neil Jerram
5826bf6572 Release stuff: missing NEWS and 2007/2008 copyrights. 2008-02-15 22:37:52 +00:00
Neil Jerram
809624f345 configure.in: additional note suggested by Greg Troxel 2008-02-12 20:58:59 +00:00
Neil Jerram
03a3c619ed * numbers.c (SCM_COMPLEX_VALUE): Use GUILE_I instead of _Complex_I
directly, and only if GUILE_I was defined by the configure step.
(scm_log, scm_log10, scm_exp, scm_sqrt): Use SCM_COMPLEX_VALUE
code only if SCM_COMPLEX_VALUE is defined.

* configure.in (--without-64-calls): Use AC_MSG_CHECKING and
AC_MSG_RESULT instead of just echo.
(GUILE_I): New programs to try using _Complex_I or 1.0fi for the
imaginary unit.
2008-02-11 21:02:15 +00:00
Neil Jerram
3d02a866a9 Default to --without-64-calls for
powerpc-ibm-aix*.  Thanks to Rainer Tammer for reporting that the
64 calls are a problem on that OS.
2008-02-06 22:27:59 +00:00
Neil Jerram
08f9eb4adc * configure.in (--without-64-calls): New option.
* fports.c (fport_seek): Make dependent on GUILE_USE_64_CALLS.

* _scm.h: Make definition of CHOOSE_LARGEFILE depend on
GUILE_USE_64_CALLS.
2008-02-05 22:04:52 +00:00
Ludovic Courtès
b560974ad9 Changes from arch/CVS synchronization 2007-10-10 16:58:57 +00:00
Kevin Ryde
6bc98ba721 (AC_CHECK_FUNCS): Add clog and cexp. 2007-09-02 22:32:55 +00:00
Ludovic Courtès
8482254ff1 Changes from arch/CVS synchronization 2007-08-11 10:48:28 +00:00
Ludovic Courtès
c60e7fe655 Changes from arch/CVS synchronization 2007-08-03 14:40:01 +00:00
Neil Jerram
97084119ee Merge of IA64 fix from CVS HEAD. 2007-01-28 16:36:38 +00:00
Kevin Ryde
84e4596bd0 (isinf, isnan): Use a volatile global to stop gcc
optimizing out the test.  In particular this fixes solaris where there
isn't an isinf or isnan (though gcc still optimizes as if there is).
Reported by Hugh Sasse.
(AC_C_VOLATILE): New.
2007-01-22 22:55:09 +00:00
Kevin Ryde
d9ff2e69aa (AC_INIT): Don't use "echo -n", it's not portable and
in particular fails on solaris (resulting in literal "-n"s going into
the output, making the resulting configure unusable).
2007-01-21 23:32:32 +00:00
Kevin Ryde
8fc6a6deec (pthread_sigmask): New test. 2006-12-26 23:32:48 +00:00
Kevin Ryde
11e49c4ee8 (pthread_get_stackaddr_np): New test. 2006-12-26 22:33:20 +00:00
Kevin Ryde
cd62ad8ff5 (-lm): No need to suppress libm on mingw, it's not
needed because it's empty, but including it does no harm.
(-lm): Look for "cos" instead of "main", since cos and friends are the
purpose of looking for libm.
(winsock etc): Test $host = *-*-mingw* rather than $MINGW32, autoconf
regards the latter as obsolete.
(AC_MINGW32): Remove test, $MINGW32 now unused.
(uint32_t): Look at HAVE_NETDB_H rather than hard-coding __MINGW32__
in the test program.
2006-12-22 20:40:26 +00:00
Kevin Ryde
0403bb28f4 (process.h, pipe, _pipe): New checks. 2006-12-14 23:18:38 +00:00
Kevin Ryde
80134d3973 (struct timespec, pthread.h): Look for struct timespec
in <pthread.h> as well as <time.h>, it's in pthread.h on mingw.
2006-12-13 23:28:58 +00:00