From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Paolo Bonzini Newsgroups: gmane.lisp.guile.bugs Subject: bug#14404: regexp_exec thread-unsafe Date: Mon, 27 May 2013 00:11:57 +0200 Message-ID: <51A288AD.4070405__22898.9681033001$1369617239$gmane$org@gnu.org> References: <87ehd9i7fc.fsf@gnu.org> <5199448F.9050608@cs.ucla.edu> <87d2slu413.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Trace: ger.gmane.org 1369617233 14268 80.91.229.3 (27 May 2013 01:13:53 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 27 May 2013 01:13:53 +0000 (UTC) Cc: 14404@debbugs.gnu.org, Paul Eggert , bug-gnulib@gnu.org To: Ludovic =?UTF-8?Q?Court=C3=A8s?= Original-X-From: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Mon May 27 03:13:52 2013 Return-path: Envelope-to: guile-bugs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Ugm0R-0007yB-Dx for guile-bugs@m.gmane.org; Mon, 27 May 2013 03:13:47 +0200 Original-Received: from localhost ([::1]:37896 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ugm0Q-0007xg-QX for guile-bugs@m.gmane.org; Sun, 26 May 2013 21:13:46 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:58969) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UgjBX-0003nM-D0 for bug-guile@gnu.org; Sun, 26 May 2013 18:13:09 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UgjBN-0002fe-NN for bug-guile@gnu.org; Sun, 26 May 2013 18:13:03 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:47453) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UgjBN-0002ei-Jd for bug-guile@gnu.org; Sun, 26 May 2013 18:12:53 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1UgjCU-0006jH-0o for bug-guile@gnu.org; Sun, 26 May 2013 18:14:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Paolo Bonzini Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-guile@gnu.org Resent-Date: Sun, 26 May 2013 22:14:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 14404 X-GNU-PR-Package: guile X-GNU-PR-Keywords: Original-Received: via spool by 14404-submit@debbugs.gnu.org id=B14404.136960640425798 (code B ref 14404); Sun, 26 May 2013 22:14:01 +0000 Original-Received: (at 14404) by debbugs.gnu.org; 26 May 2013 22:13:24 +0000 Original-Received: from localhost ([127.0.0.1]:35811 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UgjBr-0006i2-V7 for submit@debbugs.gnu.org; Sun, 26 May 2013 18:13:24 -0400 Original-Received: from mail-ee0-f50.google.com ([74.125.83.50]:40844) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UgjBp-0006hq-7L for 14404@debbugs.gnu.org; Sun, 26 May 2013 18:13:22 -0400 Original-Received: by mail-ee0-f50.google.com with SMTP id c41so3755477eek.9 for <14404@debbugs.gnu.org>; Sun, 26 May 2013 15:12:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:x-enigmail-version:content-type :content-transfer-encoding; bh=OE7N1rcRTxe4FdtDhquCqE8QE4JtxB3sBPSw8rLWJbk=; b=Jbrr3lkLR3NW3pNikOVc5mHEFGt9zN18DblkcXrCJKK+U4QWSvil6+6l3+e1pclGFt uvKgq+2Chx8RW2w1JVTSW7Z5EEsfsNBaQdv49rPkghwRcOxqPdnpGz7U5JBa8WBnqBQK UYzKCKYVOJgaGOzAdMuPVMyO4Jt72KDhn/dIprGWlkF41jN2twqxCPnd2Fq+sqlUt2ko Vn0KBx1iNLkEaVhxOY3nhysim8CoeAtaBcq/tLnl+F55MwBXunxZ7/FgOrM9j6chvOV9 MkLNHqCWmaFqgnpbDfr5j48IKLluJm3dk+W4rBfc4aGlC1Wqpuv418TLJ8Io6d17nmwO e8Yg== X-Received: by 10.15.111.75 with SMTP id ci51mr51824366eeb.7.1369606326591; Sun, 26 May 2013 15:12:06 -0700 (PDT) Original-Received: from yakj.usersys.redhat.com (net-37-117-138-128.cust.dsl.vodafone.it. [37.117.138.128]) by mx.google.com with ESMTPSA id c5sm22207021eeu.8.2013.05.26.15.12.03 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Sun, 26 May 2013 15:12:05 -0700 (PDT) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130514 Thunderbird/17.0.6 In-Reply-To: <87d2slu413.fsf@gnu.org> X-Enigmail-Version: 1.5.1 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 140.186.70.43 X-Mailman-Approved-At: Sun, 26 May 2013 21:13:44 -0400 X-BeenThere: bug-guile@gnu.org List-Id: "Bug reports for GUILE, GNU's Ubiquitous Extension Language" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Original-Sender: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.bugs:7132 Archived-At: Il 20/05/2013 16:20, Ludovic Courtès ha scritto: > Paul Eggert skribis: > >> On 05/14/2013 02:21 PM, Ludovic Courtès wrote: >> >>> How should that be fixed? Shouldn’t __libc_lock_unlock & co. be rebased >>> on top of pthread_mutex_t? >> >> Yes, thanks, that sounds right. I pushed the following patch into gnulib; >> could you please see whether it fixes the problem for you? It'd be >> helpful to try it on non-glibc systems too, if possible. > > Thank you for the quick reply. I haven’t tested yet, but I have a question: > >> --- a/modules/regex >> +++ b/modules/regex >> @@ -24,6 +24,7 @@ memmove [test $ac_use_included_regex = yes] >> mbrtowc [test $ac_use_included_regex = yes] >> mbsinit [test $ac_use_included_regex = yes] >> nl_langinfo [test $ac_use_included_regex = yes] >> +pthread [test $ac_use_included_regex = yes] >> stdbool [test $ac_use_included_regex = yes] >> stdint [test $ac_use_included_regex = yes] >> wchar [test $ac_use_included_regex = yes] > > Seems like this is going to add -lpthread to LDFLAGS, right? > > That would raise two issues: first, it should add -pthread to both > CFLAGS and LDFLAGS, not just -lpthread. > > Second, Guile can be compiled with and without thread support. In the > latter case, we wouldn’t want Gnulib to stealthily pull in pthreads. > How can this be addressed? Use the lock module instead. Paolo