[Utnubu-maintainers] Bug#396762: /sbin/dmraid depends on
/usr/lib/libz.so.1
Steve Langasek
vorlon at debian.org
Fri Nov 3 23:42:23 CET 2006
tags 396762 patch
thanks
FWIW, here's a patch to only link zlib statically to dmraid while linking
dynamically to the other libs.
Since crc32 is the only function used from zlib, the size difference is
minimal. On i386, here's the before:
$ du -sh debian/dmraid/sbin/dmraid
160K debian/dmraid/sbin/dmraid
and the after:
$ du -sh debian/dmraid/sbin/dmraid
172K debian/dmraid/sbin/dmraid
The patch is not suitable in its present form for platforms that don't use
the GNU linker, but those platforms suck anyway. ;)
Cheers,
--
Steve Langasek Give me a lever long enough and a Free OS
Debian Developer to set it on, and I can move the world.
vorlon at debian.org http://www.debian.org/
-------------- next part --------------
diff -u dmraid-1.0.0.rc13/debian/changelog dmraid-1.0.0.rc13/debian/changelog
--- dmraid-1.0.0.rc13/debian/changelog
+++ dmraid-1.0.0.rc13/debian/changelog
@@ -1,3 +1,12 @@
+dmraid (1.0.0.rc13-1.1) unstable; urgency=low
+
+ * Non-maintainer upload.
+ * Statically link against libz, since we only need crc32 from it and
+ we can't have binaries in /sbin depending on libs in /usr/lib.
+ Closes: #396762.
+
+ -- Steve Langasek <vorlon at debian.org> Fri, 3 Nov 2006 14:38:54 -0800
+
dmraid (1.0.0.rc13-1) unstable; urgency=low
* New upstream release; closes: #391499.
only in patch2:
unchanged:
--- dmraid-1.0.0.rc13.orig/1.0.0.rc13/tools/Makefile.in
+++ dmraid-1.0.0.rc13/1.0.0.rc13/tools/Makefile.in
@@ -20,7 +20,7 @@
TARGETS=\
dmraid
-DMRAIDLIBS=-ldmraid -lz
+DMRAIDLIBS=-ldmraid -Wl,-Bstatic -lz -Wl,-Bdynamic
include $(top_srcdir)/make.tmpl
More information about the Utnubu-maintainers
mailing list