summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorNIIBE Yutaka <gniibe@fsij.org>2022-04-01 10:26:32 +0900
committerNIIBE Yutaka <gniibe@fsij.org>2022-04-01 10:29:53 +0900
commita054a0a7cfb086e2cd80c64043a8694c3c1f525d (patch)
tree52a37a17f8f0df6abc505b3fa9768f7105aa1244 /configure.ac
parenta8125eba05beb33823657f095acc72191543b07f (diff)
downloadlibassuan-a054a0a7cfb086e2cd80c64043a8694c3c1f525d.tar.gz
build: Better cross build support.
* configure.ac: Use AX_CC_FOR_BUILD. * src/Makefile.am: Use EXEEXT_FOR_BUILD. * m4/ax_cc_for_build.m4: New from libgpg-error. -- Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac17
1 files changed, 2 insertions, 15 deletions
diff --git a/configure.ac b/configure.ac
index ec26580..3257c9c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -189,21 +189,8 @@ AC_PROG_LN_S
AC_PROG_MAKE_SET
#AC_ARG_PROGRAM
-# We need to compile and run a program on the build machine. A
-# comment in libgpg-error says that the AC_PROG_CC_FOR_BUILD macro in
-# the AC archive is broken for autoconf 2.57. Given that there is no
-# newer version of that macro, we assume that it is also broken for
-# autoconf 2.61 and thus we use a simple but usually sufficient
-# approach.
-AC_MSG_CHECKING(for cc for build)
-if test "$cross_compiling" = "yes"; then
- CC_FOR_BUILD="${CC_FOR_BUILD-cc}"
-else
- CC_FOR_BUILD="${CC_FOR_BUILD-$CC}"
-fi
-AC_MSG_RESULT($CC_FOR_BUILD)
-AC_ARG_VAR(CC_FOR_BUILD,[build system C compiler])
-
+# We need to compile and run a program on the build machine.
+AX_CC_FOR_BUILD
if test "$GCC" = yes; then
CFLAGS="$CFLAGS -Wall -Wcast-align -Wshadow -Wstrict-prototypes"