bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: more m4 quoting


From: Jim Meyering
Subject: Re: more m4 quoting
Date: Thu, 15 Jan 2009 13:11:17 +0100

Simon Josefsson <address@hidden> wrote:
> Jim Meyering <address@hidden> writes:
>
>>>  AC_DEFUN([_AC_LANG_OPENMP],
>>> -[_AC_LANG_DISPATCH([$0], [_AC_LANG], address@hidden)])
>>> +[_AC_LANG_DISPATCH([$0], _AC_LANG, address@hidden)])
>>
>> This one makes sense.
>> It fails on etch because it has autoconf < 2.62,
>> so the otherwise if'd out definition in openmp.m4 is used.
>> The tests passed for me because I used 2.63+, and then it
>> uses the definition of AC_OPENMP from autoconf.
>
> Ok.
>
>>>  # _AC_LANG_OPENMP(C)
>>>  # ------------------
>>> -m4_define([_AC_LANG_OPENMP([C])],
>>> +m4_define([_AC_LANG_OPENMP(C)],
>>
>> Is this change really necessary?
>
> Yes, otherwise I get:
>
> address@hidden:~$ gnulib-tool --test --with-tests openmp
> Module list with included dependencies:
>   openmp
> File list:
>   lib/dummy.c
>   m4/gnulib-common.m4
>   m4/onceonly.m4
>   m4/openmp.m4
> executing aclocal -I glm4
> configure.ac:101: error: _AC_LANG_OPENMP: unknown language: C

Thanks!
I've simply reverted all changes to that file, since all
of the affected code will be removed eventually anyhow.


>From 73a15056d9347aba42002778308ee398a20584c2 Mon Sep 17 00:00:00 2001
From: Jim Meyering <address@hidden>
Date: Thu, 15 Jan 2009 13:08:05 +0100
Subject: [PATCH] openmp.m4: revert quote-adding change, for portability to 
older autoconf

* m4/openmp.m4: Remove the quotes added on 2009-01-14.
This reverts part of 42d1eda5dcce2d68deab7a642e7f29bcd7144a0d.
Simon Josefsson noticed the problem when using autoconf-2.61.
---
 ChangeLog    |    7 +++++++
 m4/openmp.m4 |   12 ++++++------
 2 files changed, 13 insertions(+), 6 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index a905ee3..fb11852 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2009-01-15  Jim Meyering  <address@hidden>
+
+       openmp.m4: revert quote-adding change, for portability to older autoconf
+       * m4/openmp.m4: Remove the quotes added on 2009-01-14.
+       This reverts part of 42d1eda5dcce2d68deab7a642e7f29bcd7144a0d.
+       Simon Josefsson noticed the problem when using autoconf-2.61.
+
 2009-01-15  Bruno Haible  <address@hidden>

        * tests/test-fflush2.sh: Invoke test-fflush2 twice.
diff --git a/m4/openmp.m4 b/m4/openmp.m4
index 8c9c06f..116e6ce 100644
--- a/m4/openmp.m4
+++ b/m4/openmp.m4
@@ -1,4 +1,4 @@
-# openmp.m4 serial 6
+# openmp.m4 serial 7
 dnl Copyright (C) 2006-2009 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
@@ -15,11 +15,11 @@ m4_ifdef([AC_OPENMP], [], [
 # Expands to some language dependent source code for testing the presence of
 # OpenMP.
 AC_DEFUN([_AC_LANG_OPENMP],
-[_AC_LANG_DISPATCH([$0], [_AC_LANG], address@hidden)])
+[_AC_LANG_DISPATCH([$0], _AC_LANG, $@)])

 # _AC_LANG_OPENMP(C)
 # ------------------
-m4_define([_AC_LANG_OPENMP([C])],
+m4_define([_AC_LANG_OPENMP(C)],
 [
 #ifndef _OPENMP
  choke me
@@ -30,16 +30,16 @@ int main () { return omp_get_num_threads (); }

 # _AC_LANG_OPENMP(C++)
 # --------------------
-m4_copy([_AC_LANG_OPENMP([C])], [_AC_LANG_OPENMP([C++])])
+m4_copy([_AC_LANG_OPENMP(C)], [_AC_LANG_OPENMP(C++)])

 # _AC_LANG_OPENMP(Fortran 77)
 # ---------------------------
-m4_define([_AC_LANG_OPENMP([Fortran 77])],
+m4_define([_AC_LANG_OPENMP(Fortran 77)],
 [AC_LANG_FUNC_LINK_TRY([omp_get_num_threads])])

 # _AC_LANG_OPENMP(Fortran)
 # ---------------------------
-m4_copy([_AC_LANG_OPENMP([Fortran 77])], [_AC_LANG_OPENMP([Fortran])])
+m4_copy([_AC_LANG_OPENMP(Fortran 77)], [_AC_LANG_OPENMP(Fortran)])

 # AC_OPENMP
 # ---------
-- 
1.6.1.155.g1b01da




reply via email to

[Prev in Thread] Current Thread [Next in Thread]