From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Thien-Thi Nguyen Newsgroups: gmane.lisp.guile.bugs Subject: [PATCH] Declare `GC_dump' ourselves if doesn't. Date: Sat, 09 Jan 2010 14:28:38 +0100 Message-ID: <87zl4nmmpl.fsf@ambire.localdomain> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1263043891 29781 80.91.229.12 (9 Jan 2010 13:31:31 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 9 Jan 2010 13:31:31 +0000 (UTC) To: bug-guile@gnu.org Original-X-From: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Sat Jan 09 14:31:23 2010 Return-path: Envelope-to: guile-bugs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1NTbPV-0005oo-Fw for guile-bugs@m.gmane.org; Sat, 09 Jan 2010 14:31:21 +0100 Original-Received: from localhost ([127.0.0.1]:55193 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NTbPV-0006vQ-Mi for guile-bugs@m.gmane.org; Sat, 09 Jan 2010 08:31:21 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NTbPN-0006tj-HH for bug-guile@gnu.org; Sat, 09 Jan 2010 08:31:13 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NTbPI-0006ns-Fi for bug-guile@gnu.org; Sat, 09 Jan 2010 08:31:12 -0500 Original-Received: from [199.232.76.173] (port=47445 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NTbPI-0006nZ-An for bug-guile@gnu.org; Sat, 09 Jan 2010 08:31:08 -0500 Original-Received: from smtp-out05a.alice.it ([85.33.3.5]:3854) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NTbPH-0000hK-RA for bug-guile@gnu.org; Sat, 09 Jan 2010 08:31:08 -0500 Original-Received: from FBCMMO03.fbc.local ([192.168.68.197]) by smtp-OUT05A.alice.it with Microsoft SMTPSVC(6.0.3790.3959); Sat, 9 Jan 2010 14:31:04 +0100 Original-Received: from FBCMCL01B01.fbc.local ([192.168.69.82]) by FBCMMO03.fbc.local with Microsoft SMTPSVC(6.0.3790.3959); Sat, 9 Jan 2010 14:31:04 +0100 Original-Received: from ambire.localdomain ([95.236.25.135]) by FBCMCL01B01.fbc.local with Microsoft SMTPSVC(6.0.3790.3959); Sat, 9 Jan 2010 14:31:04 +0100 Original-Received: from ttn by ambire.localdomain with local (Exim 4.63) (envelope-from ) id 1NTbMs-00071G-U5 for bug-guile@gnu.org; Sat, 09 Jan 2010 14:28:38 +0100 X-OriginalArrivalTime: 09 Jan 2010 13:31:04.0596 (UTC) FILETIME=[FE180D40:01CA912F] X-detected-operating-system: by monty-python.gnu.org: Windows 2000 SP4, XP SP1+ X-BeenThere: bug-guile@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GUILE, GNU's Ubiquitous Extension Language" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Errors-To: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.bugs:4428 Archived-At: This patch removes a harmless but annoying warning. thi ___________________________________________________________________________ >From 39fd870610ff2cc1177e0cd0aba845806f0213c6 Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Sat, 9 Jan 2010 14:17:20 +0100 Subject: [PATCH] Declare `GC_dump' ourselves if doesn't. * configure.ac: Check for `GC_dump' declaration. Define `HAVE_DECL_GC_DUMP' if provides it. * libguile/gc.c [!HAVE_DECL_GC_DUMP] (GC_dump): Declare it. Signed-off-by: Thien-Thi Nguyen --- configure.ac | 8 ++++++++ libguile/gc.c | 4 ++++ 2 files changed, 12 insertions(+), 0 deletions(-) diff --git a/configure.ac b/configure.ac index 5143dcc..78c6418 100644 --- a/configure.ac +++ b/configure.ac @@ -1227,6 +1227,14 @@ PKG_CHECK_MODULES([BDW_GC], [bdw-gc]) CFLAGS="$BDW_GC_CFLAGS $CFLAGS" LIBS="$BDW_GC_LIBS $LIBS" +# `GC_dump' is available in GC 6.8 but not declared. +AC_CHECK_FUNCS([GC_dump]) +AC_CHECK_DECL([GC_dump], + [AC_DEFINE([HAVE_DECL_GC_DUMP], [1], + [Define this if the `GC_dump' function is declared])], + [], + [#include ]) + # `GC_do_blocking ()' is available in GC 7.1 but not declared. AC_CHECK_FUNCS([GC_do_blocking]) AC_CHECK_DECL([GC_do_blocking], diff --git a/libguile/gc.c b/libguile/gc.c index 700f3a4..295b663 100644 --- a/libguile/gc.c +++ b/libguile/gc.c @@ -69,6 +69,10 @@ extern unsigned long * __libc_ia64_register_backing_store_base; #include #endif +#ifndef HAVE_DECL_GC_DUMP +extern void GC_dump (void); +#endif + /* Lock this mutex before doing lazy sweeping. */ scm_i_pthread_mutex_t scm_i_sweep_mutex = SCM_I_PTHREAD_MUTEX_INITIALIZER; -- 1.6.3.2