[pybind11] 05/07: Add support for the nocheck build profile

Ghislain Vaillant ghisvail-guest at moszumanska.debian.org
Tue Jan 3 16:15:09 UTC 2017


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

ghisvail-guest pushed a commit to branch master
in repository pybind11.

commit 6e6e014d2236e4116324a27997222f7bdc7dfd3a
Author: Ghislain Antony Vaillant <ghisvail at gmail.com>
Date:   Tue Jan 3 12:50:27 2017 +0000

    Add support for the nocheck build profile
    
    - Add versioned dependency on dpkg-dev
    - Mark build dependencies specific to testing as !nocheck
    - Do not build the test suite if nocheck is requested
---
 debian/control | 7 ++++---
 debian/rules   | 9 +++++++++
 2 files changed, 13 insertions(+), 3 deletions(-)

diff --git a/debian/control b/debian/control
index 580de70..b473869 100644
--- a/debian/control
+++ b/debian/control
@@ -5,15 +5,16 @@ Section: libs
 Priority: optional
 Build-Depends: cmake (>= 2.8.12),
                debhelper (>= 10),
+               dpkg-dev (>= 1.17.14),
                dh-python,
                python-all,
-               python-pytest,
+               python-pytest <!nocheck>,
                python-setuptools,
                python-sphinx,
                python-sphinx-rtd-theme,
                python3-all,
-               python3-dev,
-               python3-pytest,
+               python3-dev <!nocheck>,
+               python3-pytest <!nocheck>,
                python3-setuptools
 Standards-Version: 3.9.8
 Vcs-Browser: https://anonscm.debian.org/cgit/debian-science/packages/pybind11.git
diff --git a/debian/rules b/debian/rules
index 8bdb21f..04d3496 100755
--- a/debian/rules
+++ b/debian/rules
@@ -3,6 +3,12 @@
 # Uncomment this to turn on verbose mode.
 #export DH_VERBOSE = 1
 
+ifeq (,$(findstring nocheck,$(DEB_BUILD_PROFILES)))
+	BUILD_OPTIONS = -DPYBIND11_TEST=ON
+else
+	BUILD_OPTIONS = -DPYBIND11_TEST=OFF
+endif
+
 export PYBUILD_NAME = pybind11
 
 %:
@@ -12,6 +18,9 @@ override_dh_auto_clean:
 	dh_auto_clean
 	dh_auto_clean --buildsystem=pybuild
 
+override_dh_auto_configure:
+	dh_auto_configure -- $(BUILD_OPTIONS)
+
 override_dh_auto_build: export http_proxy=127.0.0.1:9
 override_dh_auto_build: export https_proxy=127.0.0.1:9
 override_dh_auto_build:

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



More information about the debian-science-commits mailing list