open_posix_testsuite: Propagate configure params
PATCH 1/1 open_posix_testsuite: Propagate configure params
The open_posix_testsuite can be enabled to build from the top level configure but none of the parameters passed to it are propagated which confuses users and has been discussed a few times on the LTP ML.
This commit propagates CC, CFLAGS and LDFLAGS. If config-openposix.mk was created by the top level configure script the generate-makefiles.sh script includes its content in the generated Makefiles.
This fixes issue #54.
--- .gitignore | 1 + configure.ac | 1 + include/mk/config-openposix.mk.in | 5 +++++ testcases/open_posix_testsuite/scripts/generate-makefiles.sh | 7 ++++++- 4 files changed, 13 insertions(+), 1 deletion(-) create mode 100644 include/mk/config-openposix.mk.in
.gitignore +1 -0
@@ -32,6 +32,7 @@ autom4te.cache /README.ltp-devel /Version /include/mk/config.mk +/include/mk/config-openposix.mk /include/mk/features.mk /m4/ltp-version.m4 /lib/ltp.pc
configure.ac +1 -0
@@ -6,6 +6,7 @@ AC_CONFIG_HEADERS([include/config.h]) AC_CONFIG_MACRO_DIR([m4]) AC_CONFIG_FILES([ \ include/mk/config.mk \ + include/mk/config-openposix.mk \ include/mk/features.mk \ lib/ltp.pc \ m4/Makefile \
include/mk/config-openposix.mk.in new file +5 -0
@@ -0,0 +1,5 @@ +# Parameters from the top level configure +CC= @CC@ +CFLAGS+= @CFLAGS@ +LDLIBS+= @LIBS@ +LDFLAGS+= @LDFLAGS@
testcases/open_posix_testsuite/scripts/generate-makefiles.sh +6 -1
@@ -27,7 +27,6 @@ generate_locate_test_makefile() { generate_makefiles make-gen.$maketype $* rm -f make-gen.$maketype - } generate_makefile() {
@@ -290,6 +289,8 @@ TOP_SRCDIR=${TOP_SRCDIR:=`dirname "$0"`/..} GLOBAL_BOILERPLATE="${TOP_SRCDIR}/.global_boilerplate" +CONFIG_MK="../../include/mk/config-openposix.mk" + rm -f "$GLOBAL_BOILERPLATE" for var in CFLAGS LDFLAGS LDLIBS; do
@@ -300,6 +301,10 @@ EOF fi done +if [ -f "$CONFIG_MK" ]; then + cat "$CONFIG_MK" >> "$GLOBAL_BOILERPLATE" +fi + # For the generic cases. generate_locate_test_makefile buildonly '.test' '-c' generate_locate_test_makefile runnable '.run-test'
Signature · 6 lines
2.4.10 -- Cyril Hrubis [email protected]
PATCH 1/1 open_posix_testsuite: Propagate configure params
----- Original Message -----
Quoted 9 lines
From: "Cyril Hrubis" <[email protected]>
To: [email protected]
Sent: Wednesday, 20 April, 2016 6:23:53 PM
Subject: [LTP] [PATCH]open_posix_testsuite: Propagate configure paramsThe
open_posix_testsuitecan be enabled to build from the top level configure but none of the parameters passed to it are propagated which confuses users and has been discussed a few times on the LTP ML.
Quoted 7 lines
This commit propagates CC, CFLAGS and LDFLAGS. If config-openposix.mk was created by the top level configure script the
generate-makefiles.shscript includes its content in the generated Makefiles.This fixes issue #54.
Signed-off-by Cyril Hrubis <[email protected]>
Looks good to me.
Regards,
Jan