texinfo-commits
[Top][All Lists]
Advanced

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

branch master updated: * tp/Texinfo/XS/configure.ac (HAVE_USABLE_GETENV_


From: Patrice Dumas
Subject: branch master updated: * tp/Texinfo/XS/configure.ac (HAVE_USABLE_GETENV_IN_XS): redirect stderr to /dev/null for test too. Fix the use of AC_DEFINE to define only if the test succeeded.
Date: Mon, 14 Oct 2024 15:58:52 -0400

This is an automated email from the git hooks/post-receive script.

pertusus pushed a commit to branch master
in repository texinfo.

The following commit(s) were added to refs/heads/master by this push:
     new 539159a556 * tp/Texinfo/XS/configure.ac (HAVE_USABLE_GETENV_IN_XS): 
redirect stderr to /dev/null for test too.  Fix the use of AC_DEFINE to define 
only if the test succeeded.
539159a556 is described below

commit 539159a5560cc34f6aacddff01770191e0ec5a64
Author: Patrice Dumas <pertusus@free.fr>
AuthorDate: Mon Oct 14 21:58:42 2024 +0200

    * tp/Texinfo/XS/configure.ac (HAVE_USABLE_GETENV_IN_XS): redirect
    stderr to /dev/null for test too.  Fix the use of AC_DEFINE to define
    only if the test succeeded.
    
    * tp/Texinfo/XS/main/call_perl_function.c
    (call_translations_translate_string): fix Perl function name.
---
 ChangeLog                               | 15 ++++++++++++---
 tp/TODO                                 |  2 +-
 tp/Texinfo/XS/configure.ac              |  9 +++++----
 tp/Texinfo/XS/main/call_perl_function.c |  2 +-
 4 files changed, 19 insertions(+), 9 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index b36d2f401b..23dcbac94f 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,10 +1,19 @@
+2024-10-13  Patrice Dumas  <pertusus@free.fr>
+
+       * tp/Texinfo/XS/configure.ac (HAVE_USABLE_GETENV_IN_XS): redirect
+       stderr to /dev/null for test too.  Fix the use of AC_DEFINE to define
+       only if the test succeeded.
+
+       * tp/Texinfo/XS/main/call_perl_function.c
+       (call_translations_translate_string): fix Perl function name.
+
 2024-10-13  Patrice Dumas  <pertusus@free.fr>
 
        * NEWS, tp/Texinfo/Convert/HTML.pm (_external_node_href),
        tp/Texinfo/XS/convert/format_html.c (external_node_href): remove .inf
-       or .info in cross-reference manual names, but warn that they should be
-       removed.  There are indeed manuals with .info in cross-references,
-       for instance the glibc manual.  Report from Gavin.
+       or .info in cross-reference manual names, but warn that they should
+       not have been there.  There are indeed manuals with .info in
+       cross-references, for instance the glibc manual.  Report from Gavin.
 
 2024-10-13  Patrice Dumas  <pertusus@free.fr>
 
diff --git a/tp/TODO b/tp/TODO
index 861c37ace3..a2eef0353e 100644
--- a/tp/TODO
+++ b/tp/TODO
@@ -921,7 +921,7 @@ SUM: 98
 Setting flags
 # some features are only enabled at -O2, but sometime -O0 is better
 # for debugging with valgrind
-our_CFLAGS='-g -O0 -Wformat-security -Wstrict-prototypes -Wall 
-Wno-parentheses -Wno-missing-braces -Wno-unused-parameter -Wextra'
+our_CFLAGS='-g -O0 -Wformat-security -Wstrict-prototypes -Wall 
-Wno-parentheses -Wno-unused-parameter -Wextra'
 # keep cpp expanded files
 # -save-temps
 # Without -Wstack-protector there is no message on functions not protected.
diff --git a/tp/Texinfo/XS/configure.ac b/tp/Texinfo/XS/configure.ac
index 1dc5c1aa9b..b94528ddc2 100644
--- a/tp/Texinfo/XS/configure.ac
+++ b/tp/Texinfo/XS/configure.ac
@@ -20,17 +20,18 @@ AC_SUBST([CONVERTER])
 
 AC_PATH_PROG([PERL], [perl])
 
+# Before Perl 5.38.0 getenv/setenv and similar cannot be reliably used in
+# XS and could lead to memory corruption, depending on the platform.
 usable_getenv_in_XS=no
 AC_MSG_CHECKING([Perl XS with usable getenv])
-if $PERL -e "use 5.038" >/dev/null ; then
+if $PERL -e "use 5.038" >/dev/null 2>&1; then
   usable_getenv_in_XS=yes
 fi
 AC_MSG_RESULT($usable_getenv_in_XS)
 
-AC_DEFINE([HAVE_USABLE_GETENV_IN_XS], [], [whether getenv can be used in XS])
-
 if test $usable_getenv_in_XS = yes ; then
-  AC_DEFINE([HAVE_USABLE_GETENV_IN_XS], [1])
+  AC_DEFINE([HAVE_USABLE_GETENV_IN_XS], [1],
+            [Define to 1 if getenv can be used in XS])
 fi
 
 b='\'
diff --git a/tp/Texinfo/XS/main/call_perl_function.c 
b/tp/Texinfo/XS/main/call_perl_function.c
index 53bfaa2fd6..115f621faf 100644
--- a/tp/Texinfo/XS/main/call_perl_function.c
+++ b/tp/Texinfo/XS/main/call_perl_function.c
@@ -148,7 +148,7 @@ call_translations_translate_string (const char *string, 
const char *in_lang,
   PUTBACK;
 
   count = call_pv (
-    "Texinfo::Translation::translate_string",
+    "Texinfo::Translations::translate_string",
     G_SCALAR);
 
   SPAGAIN;



reply via email to

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