[SCM] libdvdcss-pkg/master: use substvars to get guest package Depends, Recommends, Suggests and Description

onlyjob at users.alioth.debian.org onlyjob at users.alioth.debian.org
Sat May 11 02:16:11 UTC 2013


The following commit has been merged in the master branch:
commit f7fe1d80e83f84d40676af4befa66a30cdf9502b
Author: Dmitry Smirnov <onlyjob at member.fsf.org>
Date:   Sat May 11 05:03:25 2013 +1000

    use substvars to get guest package Depends, Recommends, Suggests and Description

diff --git a/debian/control b/debian/control
index 613a2c7..a5f2fb0 100644
--- a/debian/control
+++ b/debian/control
@@ -10,16 +10,13 @@ Vcs-Browser: http://anonscm.debian.org/gitweb/?p=pkg-multimedia/libdvdcss-pkg.gi
 
 Package: libdvdcss-pkg
 Architecture: all
-Depends: ${misc:Depends}
-        ,build-essential
-        ,debhelper (>= 9)
-        ,devscripts
-        ,dh-autoreconf
+Depends: ${misc:Depends} ,build-essential
+        ,${guest:Build-Depends}
+Recommends: ${guest:Recommends}
+Suggests: ${guest:Suggests}
 Description: download, build and install libdvdcss package
  This package will automatically download, build and install
  libdvdcss on your system.
  .
- libdvdcss is a library for accessing and unscrambling DVDs encrypted
- with the Content Scramble System (CSS).
- libdvdcss is a free software but Debian is not shipping it
- due to fears of running afoul of DMCA-style laws.
+ .
+ ${guest}: ${guest:Description}
diff --git a/debian/rules b/debian/rules
index 0a50e16..b72612b 100755
--- a/debian/rules
+++ b/debian/rules
@@ -21,6 +21,14 @@ debian/po/templates.pot:
 override_dh_installchangelogs:
 	dh_installchangelogs $(PKGG)/debian/changelog
 
+override_dh_gencontrol:
+	dh_gencontrol -v -- \
+          -Vguest:Build-Depends="$(shell perl -0n -E 's{^#.*$$}{}mg;' -E 'print $$1 if m{^Build-Depends:([^:A-Z]+)}ms;' $(PKGG)/debian/control)" \
+          -Vguest:Recommends="$(shell perl -0n -E 'print $$1 if m{^Recommends:([^:A-Z]+)}ms;' $(PKGG)/debian/control)" \
+          -Vguest:Suggests="$(shell perl -0n -E 'print $$1 if m{^Suggests:([^:A-Z]+)}ms;' $(PKGG)/debian/control)" \
+          -Vguest:Description="$(shell perl -0n -E 's/^Description:[^\n]+\K/./sm; s/\n\n|\Z/EEooDD/smg; s/\n\s+\.?/\\\$${Newline}/smg; print $$1 if m/^Description:\s*(.+?)EEooDD/ms;' $(PKGG)/debian/control)" \
+          -Vguest="$(PKGG)"
+
 override_dh_builddeb:
 	dh_builddeb -- -Zxz
 

-- 
libdvdcss-pkg packaging



More information about the pkg-multimedia-commits mailing list