[Build-common-hackers] Bug#433862: cdbs: please allow the possibility to filter out packages

Sune Vuorela reportbug at pusling.com
Thu Jul 19 22:26:38 UTC 2007

Package: cdbs
Version: 0.4.49
Severity: wishlist
Tags: patch


I have recently had the need for having a list of packages that
shouldn't be build under some conditions.

I tried different things, like -Npackage in DH_OPTIONS, but failed.

I ended up adapting buildvars.mk to my need - to support a DONT_BUILD
var to contain packages that shouldn't be build.

I think I have done it right - and I am currently using it in
It is there used as a workaround not being able to set 
Architecture: any !s390
in control file, as a negative list is easier to maintain than a
positive list.
so I wrap it in 
#if something
DONT_BUILD =pkgname

in my rules file.

I don't expect the final variable to be called DONT_BUILD, but it should
be easy to change.

Any comments welcome.


-- System Information:
Debian Release: lenny/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'testing'), (500, 'stable'), (200, 'experimental')
Architecture: i386 (i686)

Kernel: Linux 2.6.20-1-vserver-k7 (SMP w/1 CPU core)
Locale: LANG=en_GB, LC_CTYPE=en_GB (charmap=ISO-8859-1)
Shell: /bin/sh linked to /bin/dash

cdbs depends on no packages.

Versions of packages cdbs recommends:
ii  autotools-dev                 20070306.1 Update infrastructure for config.{
ii  debhelper                     5.0.53     helper programs for debian/rules

-- no debconf information
-------------- next part --------------
--- /usr/share/cdbs/1/rules/buildvars.mk	2007-05-20 18:13:10.000000000 +0200
+++ buildvars.mk	2007-07-10 21:35:51.000000000 +0200
@@ -35,25 +35,25 @@
 # Split into arch/indep packages
 ifneq ($(DEB_INDEP_PACKAGES),cdbs)
-DEB_INDEP_PACKAGES := $(strip $(shell $(_cdbs_scripts_path)/list-packages indep))
-DEB_ARCH_PACKAGES := $(filter-out $(DEB_INDEP_PACKAGES),$(strip $(shell $(_cdbs_scripts_path)/list-packages same)))
+DEB_INDEP_PACKAGES := $(filter-out $(DONT_BUILD), $(strip $(shell $(_cdbs_scripts_path)/list-packages indep)))
+DEB_ARCH_PACKAGES := $(filter-out $(DONT_BUILD), $(filter-out $(DEB_INDEP_PACKAGES),$(strip $(shell $(_cdbs_scripts_path)/list-packages same))))
 # Split into normal and udeb packages
+DEB_PACKAGES = $(filter-out $(DONT_BUILD), $(filter-out %-udeb, $(DEB_ARCH_PACKAGES) $(DEB_INDEP_PACKAGES)))
 # Too much bother for now.  If someone complains we'll fix it.
 # A handy list of every package, udeb or not
+DEB_DBG_PACKAGES = $(filter-out $(DONT_BUILD), $(filter %-dbg, $(DEB_ARCH_PACKAGES) $(DEB_INDEP_PACKAGES)))
 # Some support for srcdir != builddir builds.
 # These are relative to the root of the package

More information about the Build-common-hackers mailing list