unofficial mirror of bug-guile@gnu.org 
 help / color / mirror / Atom feed
* bug#18898: Two portability patches
@ 2014-10-29 23:36 Thomas Klausner
  2014-11-12  5:59 ` Mark H Weaver
  0 siblings, 1 reply; 2+ messages in thread
From: Thomas Klausner @ 2014-10-29 23:36 UTC (permalink / raw)
  To: 18898

[-- Attachment #1: Type: text/plain, Size: 329 bytes --]

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

[-- Attachment #2: 0002-test-does-not-generally-support-as-comparison-operat.patch --]
[-- Type: text/plain, Size: 985 bytes --]

From e984213342d68ab81932baff9c8896bcee2ea704 Mon Sep 17 00:00:00 2001
From: Thomas Klausner <wiz@NetBSD.org>
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


[-- Attachment #3: 0001-NetBSD-provides-newlocale-and-strcoll_l-but-not-usel.patch --]
[-- Type: text/plain, Size: 811 bytes --]

From 479533676f8a57dca645f02eeafb5de537a2251b Mon Sep 17 00:00:00 2001
From: Thomas Klausner <wiz@NetBSD.org>
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 <unicase.h>
 #include <unistr.h>
 
-#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


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* bug#18898: Two portability patches
  2014-10-29 23:36 bug#18898: Two portability patches Thomas Klausner
@ 2014-11-12  5:59 ` Mark H Weaver
  0 siblings, 0 replies; 2+ messages in thread
From: Mark H Weaver @ 2014-11-12  5:59 UTC (permalink / raw)
  To: Thomas Klausner; +Cc: 18898-done

Thomas Klausner <wiz@NetBSD.org> writes:

> test does not generally support '==' as comparison operator.
>     
> It's a bash(1) feature; not even GNU coreutils test(1) supports it.
> Use '=' instead.

Fixed in 03242f398f3520b1b27caf5885c8d5600094f944.

> NetBSD provides newlocale and strcoll_l, but not uselocale.

Fixed in 30c5982a9548a0ca0ea46111beb490f06d74a40a.

FYI, the patch you provided was not sufficient, because it neglected to
arrange for HAVE_USELOCALE to be set by configure.  This meant that the
thread-aware locale API would _never_ be used.

These commits are on the stable-2.0 branch and will be included in Guile
2.0.12.  I'm closing this bug now.

     Thanks,
       Mark





^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-11-12  5:59 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-10-29 23:36 bug#18898: Two portability patches Thomas Klausner
2014-11-12  5:59 ` Mark H Weaver

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).