1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-10 14:00:21 +02:00

Fix builds `--without-threads'.

This commit is contained in:
Ludovic Courtès 2008-08-27 23:05:44 +02:00
parent f85ea2a85f
commit 70eca63557
5 changed files with 23 additions and 3 deletions

View file

@ -1,3 +1,12 @@
2008-08-27 Ludovic Courtès <ludo@gnu.org>
Fix builds `--without-threads'. Reported by Han-Wen Nienhuys
<hanwen@xs4all.nl>.
* scmsigs.c (scm_i_close_signal_pipe): Don't refer to
`signal_pipe' unless `SCM_USE_PTHREAD_THREADS' is true.
* threads.c (scm_leave_guile_cleanup): Mark as `SCM_UNUSED'.
2008-08-25 Ludovic Courtès <ludo@gnu.org>
* Makefile.am (AM_CFLAGS): New.

View file

@ -1,4 +1,4 @@
/* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2004, 2006, 2007 Free Software Foundation, Inc.
/* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2004, 2006, 2007, 2008 Free Software Foundation, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@ -680,8 +680,10 @@ scm_i_close_signal_pipe()
been launched at this point, it never will be before shutdown. */
scm_i_pthread_mutex_lock (&signal_delivery_thread_mutex);
#if SCM_USE_PTHREAD_THREADS
if (scm_i_signal_delivery_thread != NULL)
close (signal_pipe[1]);
#endif
scm_i_pthread_mutex_unlock (&signal_delivery_thread_mutex);
}

View file

@ -784,7 +784,7 @@ scm_with_guile (void *(*func)(void *), void *data)
scm_i_default_dynamic_state);
}
static void
SCM_UNUSED static void
scm_leave_guile_cleanup (void *x)
{
scm_leave_guile ();

View file

@ -1,3 +1,8 @@
2008-08-27 Ludovic Courtès <ludo@gnu.org>
* tests/srfi-18.test: Don't run the tests unless
"(provided? 'threads)" is true.
2008-08-25 Ludovic Courtès <ludo@gnu.org>
* standalone/Makefile.am (test_cflags): Add `$(GCC_CFLAGS)'.

View file

@ -1,7 +1,7 @@
;;;; srfi-18.test --- Test suite for Guile's SRFI-18 functions. -*- scheme -*-
;;;; Julian Graham, 2007-10-26
;;;;
;;;; Copyright (C) 2007 Free Software Foundation, Inc.
;;;; Copyright (C) 2007, 2008 Free Software Foundation, Inc.
;;;;
;;;; This program is free software; you can redistribute it and/or modify
;;;; it under the terms of the GNU General Public License as published by
@ -22,6 +22,8 @@
#:use-module (test-suite lib)
#:use-module (srfi srfi-18))
(and (provided? 'threads)
(with-test-prefix "current-thread"
(pass-if "current-thread eq current-thread"
@ -475,3 +477,5 @@
(set! success #t)))
(lambda () (thread-join! t)))
success)))
)