Simon Josefsson wrote: > While CROSS_COMPILING is a common variable used for this purpose, this > is bad namespace usage -- how about GL_CRC_CROSS_COMPILING, > GL_CROSS_COMPILING or GNULIB_CROSS_COMPILING instead?
Indeed, a search on codesearch.debian.net reveals that a number of packages use this variable with a different convention: value 1 or 0, not yes or no. So, it's adequate to namespace it: 2024-10-31 Bruno Haible <br...@clisp.org> crc: Avoid potential conflict with other configure.ac files. Suggested by Simon Josefsson. * modules/crc (configure.ac, Makefile.am): Rename CROSS_COMPILING to GL_CROSS_COMPILING. diff --git a/modules/crc b/modules/crc index e8b0d91ea6..f3122ddd3b 100644 --- a/modules/crc +++ b/modules/crc @@ -13,8 +13,10 @@ endian configure.ac: AC_REQUIRE([gl_CRC_SLICE_BY_8]) -CROSS_COMPILING=$cross_compiling -AC_SUBST([CROSS_COMPILING]) +# Set to 'yes' if executables created by the C compiler $CC can be run in the +# build environment, or to 'no' otherwise. +GL_CROSS_COMPILING=$cross_compiling +AC_SUBST([GL_CROSS_COMPILING]) AC_PROG_MKDIR_P Makefile.am: @@ -28,7 +30,7 @@ lib_SOURCES += crc.c # $(AM_LDFLAGS). And do the compilation in a temporary directory, where # gnulib-generated stdio.h and stdlib.h files are not visible. $(srcdir)/crc-sliceby8.h: $(srcdir)/crc-generate-table.c - if test @CROSS_COMPILING@ = no; then \ + if test @GL_CROSS_COMPILING@ = no; then \ $(MKDIR_P) crc-tmp \ && abs_srcdir=`cd $(srcdir) && pwd` \ && (cd crc-tmp \