diff options
| author | Paul Eggert <eggert@cs.ucla.edu> | 2025-12-09 18:03:10 -0800 |
|---|---|---|
| committer | Paul Eggert <eggert@cs.ucla.edu> | 2025-12-09 18:04:29 -0800 |
| commit | b9b0c7ed512575a6c2faa06df60d2486faa5eee5 (patch) | |
| tree | d36ca404fcc7162f6498fff7361f39b5acf22170 | |
| parent | bc65fb74865483c33a30bf5641686d7bc2b7d04b (diff) | |
Work even if aclocal is invoked by hand
Problem reported by Ulrich Müller (bug#79974).
* configure.ac (gl_ALIGNASOF): Arrange for it to be defined
even if aclocal is invoked other than via admin/merge-gnulib.
Also, change comments from # to dnl as they don’t make
much sense in the shell script.
| -rw-r--r-- | configure.ac | 20 |
1 files changed, 14 insertions, 6 deletions
diff --git a/configure.ac b/configure.ac index f131735460e..80991f3866c 100644 --- a/configure.ac +++ b/configure.ac @@ -3277,12 +3277,20 @@ if test "$emacs_cv_struct_alignment" = yes; then structure to an N-byte boundary.]) fi -# Check for alignas now rather than waiting for gl_INIT to do it, -# as the system_malloc=no test below needs $gl_cv_header_working_stdalign_h. -# Do not simply call gl_INIT here, as the ac_cv_func_pthread_sigmask=yes -# assignment below affects how gl_INIT works. -# Instead, call gl_ALIGNASOF, the only part of gl_INIT needed here. -# Then make gl_ALIGNASOF a no-op so gl_INIT does not duplicate its code. +dnl Work around a glitch if aclocal is invoked outside of autogen.sh. +dnl Such an invocation generates an aclocal.m4 that lacks m4/stdalign.m4. +dnl The following hack checks the otherwise-uninvolved macro gl_STDALIGN_H +dnl so that the hack itself does not generate a diagnostic. +m4_divert_push([KILL]) +m4_ifdef([gl_STDALIGN_H], [], [m4_include([m4/stdalign.m4])]) +m4_divert_pop([KILL]) + +dnl Check for alignas now rather than waiting for gl_INIT to do it, +dnl as the system_malloc=no test below needs $gl_cv_header_working_stdalign_h. +dnl Do not simply call gl_INIT here, as the ac_cv_func_pthread_sigmask=yes +dnl assignment below affects how gl_INIT works. +dnl Instead, call gl_ALIGNASOF, the only part of gl_INIT needed here. +dnl Then make gl_ALIGNASOF a no-op so gl_INIT does not duplicate its code. gl_ALIGNASOF AC_DEFUN([gl_ALIGNASOF]) |
