diff options
author | dequis <dx@dxzone.com.ar> | 2018-04-11 02:58:33 -0300 |
---|---|---|
committer | dequis <dx@dxzone.com.ar> | 2018-04-11 03:16:02 -0300 |
commit | f8d2cffce09b9990689a1f33b3abcc153482f42b (patch) | |
tree | 28691251512c139c2a4567e6b9ace1aeca3def47 /debian/rules | |
parent | 8d7b0a4e9e47c2d392f6fc8f8749d4c5fe6e2604 (diff) |
debian: turn -common and -dev into arch:any to safely use --link-doc
This started with trying to remove something that says "remove the hack
below once Hardy and Lenny are deprecated". Hardy and Lenny have been
deprecated for years, this should be easy, right?
Turns out that the symlink stuff we were doing can result in broken
packages with binNMU, see debbug#767839. This is also documented in the
dh_installdocs man page:
> CAVEAT 2: The use of --link-doc should only be done when the packages
> have same "architecture" type. A link from a architecture independent
> package to a architecture dependent package (or vice versa) will not
> work. Since compat 10, debhelper will actively reject unsupported
> combinations.
And we were doing essentially the same wrong thing but manually.
The easiest way to solve this is to stop mixing arch:any and arch:all,
and to make everything arch:any. Let's hope this is as easy as it looks.
Thanks to bunk, nthykier and olly from #debian-devel for help with this.
Diffstat (limited to 'debian/rules')
-rwxr-xr-x | debian/rules | 17 |
1 files changed, 4 insertions, 13 deletions
diff --git a/debian/rules b/debian/rules index 08111792..4fabddfa 100755 --- a/debian/rules +++ b/debian/rules @@ -34,10 +34,7 @@ CONFIGURE_OVERRIDES:=CPPFLAGS="$(CPPFLAGS)" CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAG HAS_DH_SYSTEMD:=$(shell dpkg-query -W -f='$${Status}' dh-systemd 2>/dev/null | grep -c "ok installed") -# No difference at the build stage so just call main build target. -# (Well indep could be docs-only but we prebuild them plus it's really -# not that much work.) -build-arch build-indep: build +build-arch: build build: build-stamp build-stamp: @@ -97,10 +94,7 @@ binary-common: dh_installchangelogs doc/CHANGES dh_installexamples - dh_installdocs #--link-doc=bitlbee-common - # TODO: Restore --link-doc up here and remove the hack below once - # Hardy and Lenny are deprecated. - for p in bitlbee bitlbee-libpurple bitlbee-dev bitlbee-plugin-otr; do rm -r debian/$$p/usr/share/doc/$$p && ln -s bitlbee-common debian/$$p/usr/share/doc/$$p || true; done + dh_installdocs --link-doc=bitlbee-common dh_installdebconf ifeq ($(HAS_DH_SYSTEMD),1) dh_systemd_enable -p bitlbee-common --no-enable bitlbee.socket @@ -122,14 +116,11 @@ endif dh_md5sums dh_builddeb -binary-indep: build install - DH_OPTIONS=-i $(MAKE) -f debian/rules binary-common - binary-arch: build install DH_OPTIONS=-a $(MAKE) -f debian/rules binary-common binary-%: build install DH_OPTIONS=-p$* $(MAKE) -f debian/rules binary-common -binary: binary-indep binary-arch -.PHONY: build clean binary-indep binary-arch binary-common binary install +binary: binary-arch +.PHONY: build clean binary-arch binary-common binary install |