From a7930dc869e936a21d44480eaa5001ac2e107b1c Mon Sep 17 00:00:00 2001 From: Lifan Su Date: Wed, 1 May 2024 03:14:34 +0000 Subject: [PATCH] [linux] Do not embed kernel version in CFLAGS This change makes building on Linux reproducible, closing issue #310. --- configure.ac | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index 343b822c..c7bd15f2 100644 --- a/configure.ac +++ b/configure.ac @@ -242,8 +242,10 @@ AM_CONDITIONAL([SOLARIS], [test x$LSOF_DIALECT_DIR = xsun]) AM_CONDITIONAL([AIX], [test x$LSOF_DIALECT_DIR = xaix]) # Pass OS version -LSOF_TMP=$(echo $LSOF_VSTR | sed 's/(/\\\\(/g' | sed 's/)/\\\\)/g') -CFLAGS="$CFLAGS -DLSOF_VSTR=\\\"$LSOF_TMP\\\"" +AS_IF([test x$LSOF_DIALECT_DIR != xlinux], [ + LSOF_TMP=$(echo $LSOF_VSTR | sed 's/(/\\\\(/g' | sed 's/)/\\\\)/g') + CFLAGS="$CFLAGS -DLSOF_VSTR=\\\"$LSOF_TMP\\\"" +]) # Pass LSOF_DIALECT/LSOF_DIALECT_DIR to Makefile.am AC_SUBST([LSOF_DIALECT])