diff --git a/configure b/configure index 81b7916db7..a826ead951 100755 --- a/configure +++ b/configure @@ -804,6 +804,9 @@ FGREP SED LIBTOOL SET_MAKE +LFS_LIBS +LFS_LDFLAGS +LFS_CFLAGS EGREP GREP CPP @@ -3895,6 +3898,14 @@ $as_echo "$ac_cv_safe_to_define___extensions__" >&6; } +LFS_CFLAGS=`getconf LFS_CFLAGS 2>/dev/null` +LFS_LDFLAGS=`getconf LFS_LDFLAGS 2>/dev/null` +LFS_LIBS=`getconf LFS_LIBS 2>/dev/null` + + + + + # Enable RFC 3542 APIs on macOS $as_echo "#define __APPLE_USE_RFC_3542 1" >>confdefs.h diff --git a/configure.ac b/configure.ac index 08d2540f72..a2850594be 100644 --- a/configure.ac +++ b/configure.ac @@ -16,6 +16,14 @@ AC_CONFIG_MACRO_DIR([m4]) AC_CANONICAL_HOST AC_USE_SYSTEM_EXTENSIONS +LFS_CFLAGS=`getconf LFS_CFLAGS 2>/dev/null` +LFS_LDFLAGS=`getconf LFS_LDFLAGS 2>/dev/null` +LFS_LIBS=`getconf LFS_LIBS 2>/dev/null` + +AC_SUBST([LFS_CFLAGS]) +AC_SUBST([LFS_LDFLAGS]) +AC_SUBST([LFS_LIBS]) + # Enable RFC 3542 APIs on macOS AC_DEFINE([__APPLE_USE_RFC_3542], [1], [Select RFC3542 IPv6 API on macOS]) diff --git a/lib/dns/Makefile.in b/lib/dns/Makefile.in index b7693f0921..4cc8a47276 100644 --- a/lib/dns/Makefile.in +++ b/lib/dns/Makefile.in @@ -167,9 +167,6 @@ include/dns/rdatastruct.h: gen \ code.h: gen ./gen -s ${srcdir} > code.h || { rm -f $@ ; exit 1; } -gen: LFS_CFLAGS = `getconf LFS_CFLAGS 2>/dev/null` -gen: LFS_LDFLAGS = `getconf LFS_LDFLAGS 2>/dev/null` -gen: LFS_LIBS = `getconf LFS_LIBS 2>/dev/null` gen: gen.c ${BUILD_CC} ${BUILD_CFLAGS} -I${top_srcdir}/lib/isc/include \ ${LFS_CFLAGS} ${LFS_LDFLAGS} \ diff --git a/make/rules.in b/make/rules.in index 8039856489..4ca7c63ec5 100644 --- a/make/rules.in +++ b/make/rules.in @@ -116,6 +116,10 @@ BUILD_CPPFLAGS = @BUILD_CPPFLAGS@ BUILD_LDFLAGS = @BUILD_LDFLAGS@ BUILD_LIBS = @BUILD_LIBS@ +LFS_CFLAGS = @LFS_CFLAGS@ +LFS_LDFLAGS = @LFS_LDFLAGS@ +LFS_LIBS = @LFS_LIBS@ + .SUFFIXES: .SUFFIXES: .c .@O@