Code

Added libcollectdclient0 and libcollectdclient-dev binary packages.
authorSebastian Harl <sh@tokkee.org>
Sun, 22 Feb 2009 14:16:57 +0000 (15:16 +0100)
committerSebastian Harl <sh@tokkee.org>
Sun, 22 Feb 2009 14:55:29 +0000 (15:55 +0100)
I'm now using dh_install and *.install files to specify which package some
file belongs to.

Thanks to Peter Palfrader, Ron Lee and Tollef Fog Heen for their suggestions
about the package description.

debian/collectd-dev.install [new file with mode: 0644]
debian/collectd.install [new file with mode: 0644]
debian/control
debian/libcollectdclient-dev.install [new file with mode: 0644]
debian/libcollectdclient0.install [new file with mode: 0644]
debian/rules

diff --git a/debian/collectd-dev.install b/debian/collectd-dev.install
new file mode 100644 (file)
index 0000000..ea6252f
--- /dev/null
@@ -0,0 +1,3 @@
+src/liboconfig/oconfig.h usr/include/collectd/liboconfig
+src/*.h usr/include/collectd
+
diff --git a/debian/collectd.install b/debian/collectd.install
new file mode 100644 (file)
index 0000000..8a3c55c
--- /dev/null
@@ -0,0 +1,11 @@
+../../contrib/migrate-3-4.px usr/lib/collectd/utils
+../../contrib/rrd_filter.px usr/lib/collectd/utils
+../collectd.conf ../collection.conf ../thresholds.conf etc/collectd/
+usr/bin
+usr/lib/collectd/*.so
+usr/sbin
+usr/share/collectd
+usr/share/man
+usr/share/perl5
+var
+
index 6fb4d7c43e95026aa139d2ad93d100832ee6fafd..d891a49954b7a90516cc059837a6c5bead1e027d 100644 (file)
@@ -119,3 +119,30 @@ Description: statistics collection and monitoring daemon (development files)
  This package contains the development files needed to create your own
  plugins.
 
+Package: libcollectdclient-dev
+Section: libdevel
+Architecture: any
+Depends: libcollectdclient0 (>= ${source:Version}), ${misc:Depends}
+Description: client library for collectd's control interface (development files)
+ libcollectdclient provides an API to access the control interface provided by
+ the unixsock plugin of collectd, a statistics collection and monitoring
+ daemon. It can be used to access values collected by collectd or dispatch new
+ values and notifications to the daemon. This allows for integration with
+ other applications such as monitoring solutions.
+ .
+ This package contains the header files and the static library.
+
+Package: libcollectdclient0
+Section: libs
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Recommends: collectd
+Description: client library for collectd's control interface
+ libcollectdclient provides an API to access the control interface provided by
+ the unixsock plugin of collectd, a statistics collection and monitoring
+ daemon. It can be used to access values collected by collectd or dispatch new
+ values and notifications to the daemon. This allows for integration with
+ other applications such as monitoring solutions.
+ .
+ This package contains the shared library.
+
diff --git a/debian/libcollectdclient-dev.install b/debian/libcollectdclient-dev.install
new file mode 100644 (file)
index 0000000..fd27cc5
--- /dev/null
@@ -0,0 +1,6 @@
+usr/include/collectd/client.h usr/include/collectd
+usr/include/collectd/lcc_features.h usr/include/collectd
+usr/lib/pkgconfig/libcollectdclient.pc
+usr/lib/libcollectdclient.la
+usr/lib/libcollectdclient.so
+
diff --git a/debian/libcollectdclient0.install b/debian/libcollectdclient0.install
new file mode 100644 (file)
index 0000000..7b98d64
--- /dev/null
@@ -0,0 +1,2 @@
+usr/lib/libcollectdclient.so.*
+
index beebe96fb9132c86345b921c9a3866fed8da35d0..bb1030de5184ee6d29bf329d61e03e98f3adcf35 100755 (executable)
@@ -81,7 +81,7 @@ clean: unpatch
        rm -f debian/README.Debian.plugins
        rm -f src/*.1 src/*.5
        
-       dh_clean 
+       dh_clean
        debconf-updatepo
 
 install-indep:
@@ -89,35 +89,20 @@ install-indep:
        dh_testroot
        dh_clean -k
        dh_installdirs -i
-       
-       include_dir=debian/collectd-dev/usr/include/collectd/ \
-               && mkdir -p $$include_dir/liboconfig \
-               && cp src/*.h $$include_dir \
-               && cp src/liboconfig/oconfig.h $$include_dir/liboconfig
+       dh_install -i
 
 install-arch: build
        dh_testdir
        dh_testroot
-       dh_clean -k 
+       dh_clean -k
        dh_installdirs -a
        
-       $(MAKE) install DESTDIR=$(CURDIR)/debian/collectd
-       
-       rm -rf debian/collectd/usr/include/
-       rm -f debian/collectd/usr/lib/collectd/*.la
+       $(MAKE) install DESTDIR=$(CURDIR)/debian/tmp
        
-       rm -f debian/collectd/etc/collectd.conf
-       install -D -m 0644 debian/collectd.conf \
-               debian/collectd/etc/collectd/collectd.conf
-       install -m 0644 debian/collection.conf \
-               debian/collectd/etc/collectd/collection.conf
-       install -m 0644 debian/thresholds.conf \
-               debian/collectd/etc/collectd/thresholds.conf
+       rm -f debian/tmp/usr/lib/collectd/*.la
+       rm -f debian/tmp/etc/collectd.conf
        
-       mkdir -p debian/collectd/usr/lib/collectd/utils/
-       for UTIL in rrd_filter.px migrate-3-4.px; do \
-               cp contrib/$$UTIL debian/collectd/usr/lib/collectd/utils/; \
-       done
+       dh_install -a --sourcedir=$(CURDIR)/debian/tmp --fail-missing
        
        perl ./debian/bin/gen_plugin_deps.pl
        
@@ -158,11 +143,13 @@ binary-arch: build install-arch
        dh_strip -a --dbg-package=collectd-dbg
        dh_compress -a -Xexamples/
        dh_fixperms -a
+       dh_makeshlibs -a
        dh_installdeb -a
        dpkg-shlibdeps -Tdebian/collectd.substvars \
                -dDepends debian/collectd/usr/bin/* debian/collectd/usr/sbin/* \
                        debian/collectd/usr/lib/collectd/rrdtool.so \
                -dRecommends debian/collectd/usr/lib/collectd/*.so
+       dh_shlibdeps -a -Ncollectd
        dh_gencontrol -a
        dh_md5sums -a
        dh_builddeb -a