gnuastro-commits
[Top][All Lists]
Advanced

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

[gnuastro-commits] master 0bd07e6: Bootstrapping: manual correction in a


From: Mohammad Akhlaghi
Subject: [gnuastro-commits] master 0bd07e6: Bootstrapping: manual correction in ax_pthread for autoconf 2.70
Date: Mon, 11 Jan 2021 09:55:41 -0500 (EST)

branch: master
commit 0bd07e68d57bb36ff615f9eb59ef6b15239359b6
Author: Mohammad Akhlaghi <mohammad@akhlaghi.org>
Commit: Mohammad Akhlaghi <mohammad@akhlaghi.org>

    Bootstrapping: manual correction in ax_pthread for autoconf 2.70
    
    I recently installed the recently released autoconf 2.70 on my system and
    noticed complaints about the ax_pthread test (which is maintained by GNU
    Autoconf archives) using the depreciated 'as_echo'.
    
    Until this issue is fixed upstream in the GNU Autoconf archives, I am
    manually replacing this line with a simple SED command in 'bootstrap.conf'.
---
 bootstrap.conf | 8 ++++++++
 configure.ac   | 2 +-
 2 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/bootstrap.conf b/bootstrap.conf
index 8372025..9611d58 100644
--- a/bootstrap.conf
+++ b/bootstrap.conf
@@ -123,6 +123,14 @@ bootstrap_post_import_hook()
     done
   fi
 
+  # With Autoconf 2.70, the 'as_echo' has been depreciated and will cause
+  # an error with autoreconf. But unfortunately the ax_pthread test still
+  # uses it. So until it is fixed there, we need to manually correct it
+  # here.
+  sed -e's|\$as_echo \"\$ac_link\"|AS_ECHO([\"\$ac_link\"])|' \
+      $m4_base/ax_pthread.m4 > $m4_base/ax_pthread_tmp.m4
+  mv $m4_base/ax_pthread_tmp.m4 $m4_base/ax_pthread.m4
+
   # Add a value pointer to 'argp_option' for easy setting of option values.
   awk '{                                                                    \
          if($1=="struct" && $2=="argp_option")                              \
diff --git a/configure.ac b/configure.ac
index db0c068..abeb585 100644
--- a/configure.ac
+++ b/configure.ac
@@ -144,7 +144,7 @@ AM_CONDITIONAL([COND_HASCXX], [test "x$has_cxx" = "xyes"])
 
 # Check for pthreads and add the appropriate compilation flags. AX_PTHREAD
 # comes from the GNU Autoconf Archive's ax_pthread.m4, see there for the
-# documentation. Note that
+# documentation.
 AX_PTHREAD([],[AC_MSG_ERROR([AC_PACKAGE_NAME Needs POSIX Threads (pthread)])])
 CXXFLAGS="$CXXFLAGS $PTHREAD_CFLAGS"
 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"



reply via email to

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