[compute] 05/07: Conditionally build examples and testsuite via nocheck.

Ghislain Vaillant ghisvail-guest at moszumanska.debian.org
Tue Dec 22 07:12:58 UTC 2015


This is an automated email from the git hooks/post-receive script.

ghisvail-guest pushed a commit to branch debian/sid
in repository compute.

commit 477ce48d1b1cd69d55a87e096ca5ce60e1fe18f4
Author: Ghislain Antony Vaillant <ghisvail at gmail.com>
Date:   Mon Dec 21 19:05:25 2015 +0000

    Conditionally build examples and testsuite via nocheck.
---
 debian/control |  2 ++
 debian/rules   | 23 +++++++++++++++++++----
 2 files changed, 21 insertions(+), 4 deletions(-)

diff --git a/debian/control b/debian/control
index 51400c7..74d2f7c 100644
--- a/debian/control
+++ b/debian/control
@@ -10,6 +10,8 @@ Build-Depends: cmake,
                docbook-xsl,
                doxygen,
                libboost-dev (>= 1.48),
+               libboost-program-options-dev (>= 1.48),
+               libboost-test-dev (>= 1.48),
                libboost-tools-dev,
                ocl-icd-opencl-dev | opencl-dev,
                xsltproc
diff --git a/debian/rules b/debian/rules
index 4c490c2..751df79 100755
--- a/debian/rules
+++ b/debian/rules
@@ -7,16 +7,28 @@
 %:
 	dh $@
 
+BUILD_OPTIONS = \
+	-DBOOST_COMPUTE_BUILD_BENCHMARKS=OFF \
+	-DBOOST_COMPUTE_ENABLE_COVERAGE=OFF
+
+# Disable build of examples and testsuite if no check requested.
+ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
+BUILD_OPTIONS += \
+	-DBOOST_COMPUTE_BUILD_EXAMPLES=ON \
+	-DBOOST_COMPUTE_BUILD_TESTS=ON
+else
+BUILD_OPTIONS += \
+	-DBOOST_COMPUTE_BUILD_EXAMPLES=OFF \
+	-DBOOST_COMPUTE_BUILD_TESTS=OFF
+endif
+
 override_dh_auto_clean:
 	dh_auto_clean
 	rm -rf bin doc/bin doc/html
 	rm -f Jamroot doc/*.jam doc/*.xml
 
 override_dh_auto_configure:
-	dh_auto_configure -- \
-		-DBOOST_COMPUTE_BUILD_BENCHMARKS=OFF \
-		-DBOOST_COMPUTE_BUILD_EXAMPLES=OFF \
-		-DBOOST_COMPUTE_BUILD_TESTS=OFF
+	dh_auto_configure -- $(BUILD_OPTIONS)
 
 override_dh_auto_build:
 	dh_auto_build
@@ -25,5 +37,8 @@ override_dh_auto_build:
 	printf "using boostbook ;\nusing quickbook ;\nusing doxygen ;" >> ./user-config.jam  && \
 	bjam --v2 --user-config=./user-config.jam html
 
+override_dh_auto_test:
+	# No-op.
+
 override_dh_compress:
 	dh_compress --exclude=examples

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/compute.git



More information about the debian-science-commits mailing list