From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Thomas Klausner Newsgroups: gmane.lisp.guile.bugs Subject: bug#18898: Two portability patches Date: Thu, 30 Oct 2014 00:36:08 +0100 Message-ID: <20141029233608.GM29037@danbala.tuwien.ac.at> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="kORqDWCi7qDJ0mEj" X-Trace: ger.gmane.org 1414649999 5179 80.91.229.3 (30 Oct 2014 06:19:59 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 30 Oct 2014 06:19:59 +0000 (UTC) To: 18898@debbugs.gnu.org Original-X-From: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Thu Oct 30 07:19:52 2014 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 1Xjj5L-0008MU-VK for guile-bugs@m.gmane.org; Thu, 30 Oct 2014 07:19:52 +0100 Original-Received: from localhost ([::1]:50986 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xjj5L-0003Y0-Hn for guile-bugs@m.gmane.org; Thu, 30 Oct 2014 02:19:51 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:36128) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xjcwj-0008DS-7D for bug-guile@gnu.org; Wed, 29 Oct 2014 19:47:28 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XjcwF-0003wU-7C for bug-guile@gnu.org; Wed, 29 Oct 2014 19:46:33 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:47397) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XjcwF-0003wP-2n for bug-guile@gnu.org; Wed, 29 Oct 2014 19:46:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1XjcwE-00049M-Ir for bug-guile@gnu.org; Wed, 29 Oct 2014 19:46:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Thomas Klausner Original-Sender: "Debbugs-submit" Resent-CC: bug-guile@gnu.org Resent-Date: Wed, 29 Oct 2014 23:46:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 18898 X-GNU-PR-Package: guile X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-guile@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.141462634215913 (code B ref -1); Wed, 29 Oct 2014 23:46:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 29 Oct 2014 23:45:42 +0000 Original-Received: from localhost ([127.0.0.1]:39495 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Xjcvt-00048a-9h for submit@debbugs.gnu.org; Wed, 29 Oct 2014 19:45:41 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:60086) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Xjcn2-0003tu-41 for submit@debbugs.gnu.org; Wed, 29 Oct 2014 19:36:32 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Xjcmr-0000wZ-73 for submit@debbugs.gnu.org; Wed, 29 Oct 2014 19:36:26 -0400 Original-Received: from lists.gnu.org ([208.118.235.17]:48481) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xjcmr-0000wV-4i for submit@debbugs.gnu.org; Wed, 29 Oct 2014 19:36:21 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:33454) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xjcmm-0005ks-4H for bug-guile@gnu.org; Wed, 29 Oct 2014 19:36:21 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Xjcmh-0000r4-3Y for bug-guile@gnu.org; Wed, 29 Oct 2014 19:36:16 -0400 Original-Received: from danbala.ifoer.tuwien.ac.at ([128.130.168.64]:59054) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xjcmg-0000q2-RN for bug-guile@gnu.org; Wed, 29 Oct 2014 19:36:11 -0400 Original-Received: by danbala.ifoer.tuwien.ac.at (Postfix, from userid 116) id 64114A5AF; Thu, 30 Oct 2014 00:36:08 +0100 (CET) Content-Disposition: inline X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Mailman-Approved-At: Wed, 29 Oct 2014 19:45:38 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-Mailman-Approved-At: Thu, 30 Oct 2014 02:19:49 -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:7622 Archived-At: --kORqDWCi7qDJ0mEj Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hi! The attached patches against git as of right-now fix two issues: 1. test does not generally support '==' as comparison operator. It's a bash(1) feature; not even GNU coreutils test(1) supports it. Use '=' instead. 2. NetBSD provides newlocale and strcoll_l, but not uselocale. Please merge them. Thanks, Thomas --kORqDWCi7qDJ0mEj Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="0002-test-does-not-generally-support-as-comparison-operat.patch" >From e984213342d68ab81932baff9c8896bcee2ea704 Mon Sep 17 00:00:00 2001 From: Thomas Klausner Date: Thu, 30 Oct 2014 00:33:39 +0100 Subject: [PATCH 2/2] test does not generally support '==' as comparison operator. It's a bash(1) feature; not even GNU coreutils test(1) supports it. Use '=' instead. --- meta/guile.m4 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta/guile.m4 b/meta/guile.m4 index 441dcd4..dd3c212 100644 --- a/meta/guile.m4 +++ b/meta/guile.m4 @@ -231,7 +231,7 @@ AC_DEFUN([GUILE_PROGS], AC_MSG_ERROR([Guile $_guile_required_version required, but $_guile_prog_version found]) fi fi - elif test "$GUILE_EFFECTIVE_VERSION" == "$_major_version.$_minor_version" -a -z "$_micro_version"; then + elif test "$GUILE_EFFECTIVE_VERSION" = "$_major_version.$_minor_version" -a -z "$_micro_version"; then # Allow prereleases that have the right effective version. true else -- 2.1.2 --kORqDWCi7qDJ0mEj Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="0001-NetBSD-provides-newlocale-and-strcoll_l-but-not-usel.patch" >From 479533676f8a57dca645f02eeafb5de537a2251b Mon Sep 17 00:00:00 2001 From: Thomas Klausner Date: Thu, 30 Oct 2014 00:33:18 +0100 Subject: [PATCH 1/2] NetBSD provides newlocale and strcoll_l, but not uselocale. Adapt ifdefs to handle this case correctly. --- libguile/i18n.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libguile/i18n.c b/libguile/i18n.c index c6b9b84..6fa99fe 100644 --- a/libguile/i18n.c +++ b/libguile/i18n.c @@ -40,7 +40,7 @@ #include #include -#if (defined HAVE_NEWLOCALE) && (defined HAVE_STRCOLL_L) +#if (defined HAVE_NEWLOCALE) && (defined HAVE_STRCOLL_L) && (defined HAVE_USELOCALE) /* The GNU thread-aware locale API is documented in ``Thread-Aware Locale Model, a Proposal'', by Ulrich Drepper: -- 2.1.2 --kORqDWCi7qDJ0mEj--