[Pkg-ganeti-devel] [ganeti] 13/29: htools: ship direct links to the versioned binaries

Apollon Oikonomopoulos apoikos at moszumanska.debian.org
Fri Mar 7 10:15:05 UTC 2014


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

apoikos pushed a commit to branch master
in repository ganeti.

commit a0a98f90c286f9a994fa8ac7aa2e2e1e096e866a
Author: Apollon Oikonomopoulos <apoikos at debian.org>
Date:   Thu Feb 27 16:15:57 2014 +0200

    htools: ship direct links to the versioned binaries
    
    ganeti-htools is intended for stand-alone installation on non-cluster
    systems. To resolve potential conflicts over the control of the symlinks
    in /etc/ganeti by ganeti and ganeti-htools, we recreate the symlinks to
    point directly to the versioned subtree and not /usr/lib/ganeti/default.
---
 debian/rules | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/debian/rules b/debian/rules
index 9d62575..9891fb9 100755
--- a/debian/rules
+++ b/debian/rules
@@ -109,6 +109,15 @@ override_dh_compress:
 		ln -sf "$${target}.gz" "$${file}.gz"; \
 	done
 
+override_dh_link:
+	# Fix the links in ganeti-htools to refer directly to the version at hand
+	for file in $$(find $(CURDIR)/debian/ganeti-htools/usr -type l); do \
+		target="$$(readlink "$$file" | sed -r -e 's#/usr/(lib|share)/ganeti/default/#/usr/\1/ganeti/$(VER)/#')"; \
+		ln -sf "$$target" "$$file"; \
+	done
+
+	# Now let dh_link fix all symlinks
+	dh_link
 
 # Disable dh_sphinxdoc for binary-arch, as it will raise an error
 override_dh_sphinxdoc-arch:
@@ -121,4 +130,4 @@ override_dh_auto_test:
 .PHONY: override_dh_auto_configure override_dh_auto_clean override_dh_auto_build \
 	override_dh_installinit override_dh_install-indep override_dh_sphinxdoc-arch \
 	override_dh_auto_test override_dh_compress override_dh_python2 \
-	genfiles
+	override_dh_link genfiles

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ganeti/ganeti.git



More information about the Pkg-ganeti-devel mailing list