svn commit: trunk/buildroot/package/ltp-testsuite

sjhill at uclibc.org sjhill at uclibc.org
Wed Jul 5 05:14:25 UTC 2006


Author: sjhill
Date: 2006-07-04 22:14:24 -0700 (Tue, 04 Jul 2006)
New Revision: 15612

Log:
Add patch for building and running the Open POSIX Testsuite if NPTL has been selected with uClibc along with make directives. If someone has a cleaner way of handling things in the makefile, feel free to change it.


Added:
   trunk/buildroot/package/ltp-testsuite/ltp-testsuite-enable-openposix-for-nptl.patch

Modified:
   trunk/buildroot/package/ltp-testsuite/ltp-testsuite.mk


Changeset:
Added: trunk/buildroot/package/ltp-testsuite/ltp-testsuite-enable-openposix-for-nptl.patch
===================================================================
--- trunk/buildroot/package/ltp-testsuite/ltp-testsuite-enable-openposix-for-nptl.patch	2006-07-05 05:12:51 UTC (rev 15611)
+++ trunk/buildroot/package/ltp-testsuite/ltp-testsuite-enable-openposix-for-nptl.patch	2006-07-05 05:14:24 UTC (rev 15612)
@@ -0,0 +1,33 @@
+diff -ur ltp-full-20060615/testcases/Makefile ltp-full-20060615-patched/testcases/Makefile
+--- ltp-full-20060615/testcases/Makefile	2006-01-31 08:48:38.000000000 -0600
++++ ltp-full-20060615-patched/testcases/Makefile	2006-07-04 22:20:40.298850250 -0500
+@@ -1,4 +1,4 @@
+-SUBDIRS = `ls */Makefile | sed "s/Makefile//g" | grep -v open | grep -v pounder | grep -v DOTS`
++SUBDIRS = `ls */Makefile | sed "s/Makefile//g" | grep -v open_hpi | grep -v pounder | grep -v DOTS`
+ UCLINUX_SUBDIRS = kernel
+ 
+ all:
+diff -ur ltp-full-20060615/testcases/open_posix_testsuite/LDFLAGS ltp-full-20060615-patched/testcases/open_posix_testsuite/LDFLAGS
+--- ltp-full-20060615/testcases/open_posix_testsuite/LDFLAGS	2005-06-03 11:29:49.000000000 -0500
++++ ltp-full-20060615-patched/testcases/open_posix_testsuite/LDFLAGS	2006-07-04 22:21:34.322226500 -0500
+@@ -14,3 +14,5 @@
+ # allow for the NPTL-specific compilation (used in some test cases)
+ # Note: this sometimes require the package nptl-devel.*.rpm to be installed.
+ #-I /usr/include/nptl -L /usr/lib/nptl -D_XOPEN_SOURCE=600 -lpthread -lrt -lm
++
++-D_XOPEN_SOURCE=600 -lpthread -lrt -lm -D_GNU_SOURCE
+diff -ur ltp-full-20060615/testcases/open_posix_testsuite/Makefile ltp-full-20060615-patched/testcases/open_posix_testsuite/Makefile
+--- ltp-full-20060615/testcases/open_posix_testsuite/Makefile	2006-05-21 18:38:52.000000000 -0500
++++ ltp-full-20060615-patched/testcases/open_posix_testsuite/Makefile	2006-07-04 22:22:16.660872500 -0500
+@@ -45,7 +45,10 @@
+ TIMEOUT = $(top_builddir)/t0 $(TIMEOUT_VAL)
+ 
+ 
+-all: build-tests run-tests 
++all: build-tests $(top_builddir)/t0
++
++install:
++	@echo " "
+ 
+ build-tests: $(BUILD_TESTS:.c=.test)
+ run-tests: $(RUN_TESTS:.test=.run-test)

Modified: trunk/buildroot/package/ltp-testsuite/ltp-testsuite.mk
===================================================================
--- trunk/buildroot/package/ltp-testsuite/ltp-testsuite.mk	2006-07-05 05:12:51 UTC (rev 15611)
+++ trunk/buildroot/package/ltp-testsuite/ltp-testsuite.mk	2006-07-05 05:14:24 UTC (rev 15612)
@@ -10,7 +10,18 @@
 LTP_TESTSUITE_ROOT:=$(TARGET_DIR)/root
 LTP_TESTSUITE_DIR:=$(LTP_TESTSUITE_ROOT)/ltp-full-$(LTP_TESTSUITE_VERSION)
 
+#
+# We enable Open POSIX Testsuite if Native POSIX Threads Library (NPTL)
+# is selected. Otherwise, we filter out the patch for it.
+#
+LTP_PATCHES:=$(subst package/ltp-testsuite/,,				 \
+	     $(wildcard package/ltp-testsuite/*.patch))
+ifneq ($(BR2_PTHREADS_NATIVE),y)
+LTP_PATCHES:=$(filter-out ltp-testsuite-enable-openposix-for-nptl.patch, \
+	     $(LTP_PATCHES))
+endif
 
+
 $(DL_DIR)/$(LTP_TESTSUITE_SOURCE):
 	 $(WGET) -P $(DL_DIR) $(LTP_TESTSUITE_SITE)/$(LTP_TESTSUITE_SOURCE)
 
@@ -18,7 +29,7 @@
 
 $(LTP_TESTSUITE_DIR)/Makefile: $(DL_DIR)/$(LTP_TESTSUITE_SOURCE)
 	$(LTP_TESTSUITE_CAT) $(DL_DIR)/$(LTP_TESTSUITE_SOURCE) | tar -C $(LTP_TESTSUITE_ROOT) $(TAR_OPTIONS) -
-	toolchain/patch-kernel.sh $(LTP_TESTSUITE_DIR) package/ltp-testsuite/ ltp-testsuite\*.patch
+	toolchain/patch-kernel.sh $(LTP_TESTSUITE_DIR) package/ltp-testsuite/ $(LTP_PATCHES)
 	touch -c $(LTP_TESTSUITE_DIR)/Makefile
 
 $(LTP_TESTSUITE_DIR)/.compiled: $(LTP_TESTSUITE_DIR)/Makefile




More information about the uClibc-cvs mailing list