diff --git a/packaging/debian/cciss-vol-status/cciss-vol-status.cciss-vol-statusd.init b/packaging/debian/cciss-vol-status/cciss-vol-status.cciss-vol-statusd.init index cb6edef..135df05 100644 --- a/packaging/debian/cciss-vol-status/cciss-vol-status.cciss-vol-statusd.init +++ b/packaging/debian/cciss-vol-status/cciss-vol-status.cciss-vol-statusd.init @@ -6,6 +6,7 @@ # ### BEGIN INIT INFO # Provides: cciss-vol-statusd +# Description: Check cciss_vol_status values in the background. # Required-Start: $remote_fs $syslog # Required-Stop: $remote_fs $syslog # Default-Start: 2 3 4 5 @@ -15,7 +16,7 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin DESC="cciss-vol-status monitor" -NAME="cciss-vol-statusd" +NAME=cciss-vol-statusd PIDFILE=/var/run/$NAME.pid STATUSFILE=/var/run/$NAME.status SCRIPTNAME=/etc/init.d/$NAME @@ -102,7 +103,12 @@ EOF echo "Report from $0 on $hostname" ) | mail -s "info: CCISS raid status change on $hostname" $MAILTO fi - sleep $PERIOD + sleep $PERIOD & + # Kill sleep if we're signaled to exit, otherwise we will stay defunct + # until sleep terminates. + trap "kill $!; exit" TERM + wait $! + trap - TERM done } @@ -176,6 +182,10 @@ case "$1" in check_cciss) check_cciss ;; + status) + status_of_proc /usr/bin/daemon $NAME + exit $? + ;; restart|force-reload) log_begin_msg "Restarting $DESC: $NAME" d_stop_by_restart diff --git a/packaging/debian/cciss-vol-status/changelog b/packaging/debian/cciss-vol-status/changelog index af45144..3ecc261 100644 --- a/packaging/debian/cciss-vol-status/changelog +++ b/packaging/debian/cciss-vol-status/changelog @@ -1,21 +1,72 @@ -cciss-vol-status (1:1.10-1hwraid1) unstable; urgency=low +cciss-vol-status (1.12-1+hwraid1) unstable; urgency=medium - * New upstream release. - * Drop allow_short_persnickety_option patch. + * Use lsb-release to add unique distribution tag in pkgs version. + * Relax debhelper compat from 10 to 5 to support very old distributions. + * Rewrite rules to use regular legacy debhelper. + * Re-add dependency on bsd-mail | mailx. + * Switch source/format to 1.0 and introduce manual quilt for patch mgmt. + * Turn into a periodic service as cciss-vol-statusd based on work done + in mpt-status package. - -- Adam Cécile (Le_Vert) Tue, 05 Feb 2013 16:55:37 +0100 + -- Adam Cecile Wed, 03 Jul 2019 12:44:51 +0200 -cciss-vol-status (1:1.09-2hwraid1) unstable; urgency=low +cciss-vol-status (1.12-1) unstable; urgency=medium - * Brand new package based on 1.09-2 debian's one. - * Fully backported to debhelper 5 to keep old releases compatibility. - * Improved init script by importing fixes from mpt-status 1.2.0-7 package. - * Add an epoch to be sure it will be installed over debian's official - package (Closes: #90). - * Binary renamed from cciss-vol-status to cciss_vol_status to match - upstream's and Debian's name (Add debian/NEWS). + * New upstream version 1.12 + * Remove new-ids patch, upstream has updated their list + * Update Standards-Version to 4.0.0 - -- Adam Cécile (Le_Vert) Tue, 31 Jan 2012 14:31:50 +0100 + -- Christian Hofstaedtler Tue, 11 Jul 2017 10:43:40 +0000 + +cciss-vol-status (1.11-4) unstable; urgency=medium + + * Use https:// in Vcs-* URLs + * Enable hardening=+all + * Update Standards-Version to 3.9.8 (no changes) + + -- Christian Hofstaedtler Sun, 17 Jul 2016 19:53:09 +0000 + +cciss-vol-status (1.11-3) unstable; urgency=medium + + * Moved packaging git to collab-maint + * Set Standards-Version to 3.9.6 (no addtl. changes) + * Update controller names (based on kernel 4.0) + + -- Christian Hofstaedtler Sun, 28 Jun 2015 22:52:09 +0200 + +cciss-vol-status (1.11-2) unstable; urgency=medium + + * Use dh-autoreconf instead of manually running autoreconf + * Update my E-Mail Address + * Refresh patch: fix-manpage + * Add patch: add new PCI IDs + * Bump Standards-Version to 3.9.5 (no further changes) + + -- Christian Hofstaedtler Sat, 05 Jul 2014 21:53:52 +0200 + +cciss-vol-status (1.11-1) unstable; urgency=low + + * New Upstream version 1.11 + * Replace 'automake1.11' with 'automake' + * Bump Standards-Version to 3.9.4 + + -- Christian Hofstaedtler Mon, 10 Jun 2013 10:39:58 +0200 + +cciss-vol-status (1.10-1) unstable; urgency=low + + * Imported Upstream version 1.10 + * Remove local patch 'device_ids' + * Remove local patch 'allow_short_persnickety_option' + + -- Christian Hofstaedtler Fri, 24 Aug 2012 13:12:48 +0200 + +cciss-vol-status (1.09-3) unstable; urgency=low + + * Add new hardware IDs for HP G8 servers. (Closes: #680310) + * Bump Standards-Version to 3.9.3. + * Build with debhelper 9, to import dpkg buildflags. + + -- Christian Hofstaedtler Tue, 24 Jul 2012 23:22:06 +0200 cciss-vol-status (1.09-2) unstable; urgency=low diff --git a/packaging/debian/cciss-vol-status/control b/packaging/debian/cciss-vol-status/control index 2fbcd18..399b44a 100644 --- a/packaging/debian/cciss-vol-status/control +++ b/packaging/debian/cciss-vol-status/control @@ -1,17 +1,27 @@ Source: cciss-vol-status Section: admin -Priority: extra -Maintainer: Adam Cécile (Le_Vert) -Build-Depends: debhelper (>= 5), autotools-dev, quilt -Standards-Version: 3.9.2 +Priority: optional +Maintainer: Christian Hofstaedtler +Build-Depends: autoconf, + automake, + debhelper (>= 5), + autotools-dev, + quilt, + lsb-release, +Build-Conflicts: autoconf2.13, + automake1.4 +Standards-Version: 4.0.0 Homepage: http://cciss.sourceforge.net/ -Vcs-Browser: http://github.com/zeha/cciss-vol-status/ -Vcs-Git: git://github.com/zeha/cciss-vol-status.git -DM-Upload-Allowed: yes +Vcs-Browser: https://anonscm.debian.org/cgit/collab-maint/cciss-vol-status.git/ +Vcs-Git: https://anonscm.debian.org/git/collab-maint/cciss-vol-status.git Package: cciss-vol-status Architecture: amd64 i386 -Depends: ${shlibs:Depends}, ${misc:Depends}, lsb-base, daemon, bsd-mailx | mailx +Depends: ${misc:Depends}, + ${shlibs:Depends}, + lsb-base, + daemon, + bsd-mailx | mailx, Description: HP SmartArray RAID Volume Status Checker A RAID monitor for HP SmartArray Controllers, as supported by the "cciss", "hpsa", "hpahcisr" kernel drivers. diff --git a/packaging/debian/cciss-vol-status/docs b/packaging/debian/cciss-vol-status/docs new file mode 100644 index 0000000..c710d1c --- /dev/null +++ b/packaging/debian/cciss-vol-status/docs @@ -0,0 +1,3 @@ +NEWS +README +debian/README.Debian diff --git a/packaging/debian/cciss-vol-status/gbp.conf b/packaging/debian/cciss-vol-status/gbp.conf new file mode 100644 index 0000000..cec628c --- /dev/null +++ b/packaging/debian/cciss-vol-status/gbp.conf @@ -0,0 +1,2 @@ +[DEFAULT] +pristine-tar = True diff --git a/packaging/debian/cciss-vol-status/patches/fix-manpage b/packaging/debian/cciss-vol-status/patches/fix-manpage index 7883476..832b857 100644 --- a/packaging/debian/cciss-vol-status/patches/fix-manpage +++ b/packaging/debian/cciss-vol-status/patches/fix-manpage @@ -1,13 +1,13 @@ Description: man does not understand LD macro -Author: Christian Hofstaedtler +Author: Christian Hofstaedtler Forwarded: no Last-Update: 2010-02-04 -Index: cciss-vol-status-1.06/cciss_vol_status.8 +Index: cciss-vol-status/cciss_vol_status.8 =================================================================== ---- cciss-vol-status-1.06.orig/cciss_vol_status.8 2010-02-04 19:13:34.302683423 +0000 -+++ cciss-vol-status-1.06/cciss_vol_status.8 2010-02-04 19:14:40.797930573 +0000 -@@ -101,7 +101,7 @@ +--- cciss-vol-status.orig/cciss_vol_status.8 2014-06-06 06:18:34.121832596 +0200 ++++ cciss-vol-status/cciss_vol_status.8 2014-06-06 06:18:34.117832773 +0200 +@@ -112,7 +112,7 @@ /dev/sg node to use with cciss_vol_status: .PP .nf @@ -16,7 +16,7 @@ Index: cciss-vol-status-1.06/cciss_vol_status.8 wumpus:/home/scameron # ls -l /sys/class/scsi_generic/* lrwxrwxrwx 1 root root 0 2009-11-18 12:31 /sys/class/scsi_generic/sg0 -> ../../devices/pci0000:00/0000:00:02.0/0000:02:00.0/0000:03:03.0/host0/target0:0:0/0:0:0:0/scsi_generic/sg0 lrwxrwxrwx 1 root root 0 2009-11-18 12:31 /sys/class/scsi_generic/sg1 -> ../../devices/pci0000:00/0000:00:1f.1/host2/target2:0:0/2:0:0:0/scsi_generic/sg1 -@@ -128,7 +128,7 @@ +@@ -139,7 +139,7 @@ which corresponds to the HP P800 RAID controller listed in /proc/scsi/scsi. .SH EXAMPLE .nf @@ -25,7 +25,7 @@ Index: cciss-vol-status-1.06/cciss_vol_status.8 [root@somehost]# cciss_vol_status -q /dev/cciss/c*d0 /dev/cciss/c0d0: (Smart Array P800) RAID 0 Volume 0 status: OK. /dev/cciss/c0d0: (Smart Array P800) RAID 0 Volume 1 status: OK. -@@ -206,7 +206,7 @@ +@@ -249,7 +249,7 @@ drive status: .PP .nf @@ -34,7 +34,7 @@ Index: cciss-vol-status-1.06/cciss_vol_status.8 "At least one spare drive designated" "At least one spare drive activated and currently rebuilding" "At least one activated on-line spare drive is completely rebuilt on this logical drive" -@@ -220,7 +220,7 @@ +@@ -265,7 +265,7 @@ physical drives, if more than zero, will be reported as: .TP .nf @@ -43,7 +43,7 @@ Index: cciss-vol-status-1.06/cciss_vol_status.8 "Total of n failed physical drives detected on this logical drive." .DE .fi -@@ -231,7 +231,7 @@ +@@ -286,7 +286,7 @@ power supplies, and temperature are reported as follows: .PP .nf @@ -52,7 +52,7 @@ Index: cciss-vol-status-1.06/cciss_vol_status.8 "Fan failed" "Temperature problem" "Door alert" -@@ -265,7 +265,7 @@ +@@ -324,7 +324,7 @@ warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. .SH "SEE ALSO" http://cciss.sourceforge.net @@ -61,7 +61,7 @@ Index: cciss-vol-status-1.06/cciss_vol_status.8 The /dev/cciss/c*d0 device nodes of the cciss driver do double duty. They serve as an access point to both the RAID controllers, and to the first logical drive of each RAID controller. Notice that a /dev/cciss/c*d0 -@@ -277,4 +277,3 @@ +@@ -336,4 +336,3 @@ were statically allocated at compile time, and were in short supply. Changing this behavior at this point would break lots of userland programs. diff --git a/packaging/debian/cciss-vol-status/patches/new-ids b/packaging/debian/cciss-vol-status/patches/new-ids new file mode 100644 index 0000000..8277393 --- /dev/null +++ b/packaging/debian/cciss-vol-status/patches/new-ids @@ -0,0 +1,80 @@ +Description: Add new PCI IDs and update names +Author: Christian Hofstaedtler +Forwarded: no +Last-Update: 2014-07-05 + +Index: cciss-vol-status/cciss_vol_status.c +=================================================================== +--- cciss-vol-status.orig/cciss_vol_status.c ++++ cciss-vol-status/cciss_vol_status.c +@@ -139,15 +139,12 @@ struct smartarray_id_t { + { 0x3223103C, "Smart Array P800", 0, 1}, + { 0x3237103c, "Smart Array E500", 0, 1}, + { 0x323D103C, "Smart Array P700m", 0, 1}, ++ /* start of hpsa list */ + { 0x3241103C, "Smart Array P212", 0, 1}, + { 0x3243103C, "Smart Array P410", 0, 1}, + { 0x3245103C, "Smart Array P410i", 0, 1}, + { 0x3247103C, "Smart Array P411", 0, 1}, + { 0x3249103C, "Smart Array P812", 0, 1}, +- { 0xe0110e11, "HP MSA500", 1, 0}, /* aka Smart Array CL */ +- { 0xe0200e11, "HP MSA500 G2", 1, 0}, +- { 0xe0300e11, "HP MSA20", 1, 0}, +- { 0x3118103c, "HP B110i", 0, 1}, + { 0x324A103C, "Smart Array P712m", 0, 1}, + { 0x324B103C, "Smart Array P711m", 0, 1}, + { 0x3350103C, "Smart Array P222", 0, 1}, +@@ -157,15 +154,44 @@ struct smartarray_id_t { + { 0x3354103C, "Smart Array P420i", 0, 1}, + { 0x3355103C, "Smart Array P220i", 0, 1}, + { 0x3356103C, "Smart Array P721m", 0, 1}, +- { 0x1920103C, "Smart Array", 0, 1}, +- { 0x1921103C, "Smart Array", 0, 1}, +- { 0x1922103C, "Smart Array", 0, 1}, +- { 0x1923103C, "Smart Array", 0, 1}, +- { 0x1924103C, "Smart Array", 0, 1}, +- { 0x1925103C, "Smart Array", 0, 1}, +- { 0x1926103C, "Smart Array", 0, 1}, +- { 0x1928103C, "Smart Array", 0, 1}, +- { 0x334D103C, "Smart Array P822se", 0, 1}, ++ { 0x1920103C, "Smart Array P430i", 0, 1}, ++ { 0x1921103C, "Smart Array P830i", 0, 1}, ++ { 0x1922103C, "Smart Array P430", 0, 1}, ++ { 0x1923103C, "Smart Array P431", 0, 1}, ++ { 0x1924103C, "Smart Array P830", 0, 1}, ++ { 0x1925103C, "Smart Array P831", 0, 1}, ++ { 0x1926103C, "Smart Array P731m", 0, 1}, ++ { 0x1928103C, "Smart Array P230i", 0, 1}, ++ { 0x1929103C, "Smart Array P530", 0, 1}, ++ { 0x192A103C, "Smart Array P531", 0, 1}, ++ { 0x21BD103C, "Smart Array P244br", 0, 1}, ++ { 0x21BE103C, "Smart Array P741m", 0, 1}, ++ { 0x21BF103C, "Smart HBA H240ar", 0, 1}, ++ { 0x21C0103C, "Smart Array P440ar", 0, 1}, ++ { 0x21C1103C, "Smart Array P840ar", 0, 1}, ++ { 0x21C2103C, "Smart Array P440", 0, 1}, ++ { 0x21C3103C, "Smart Array P441", 0, 1}, ++ { 0x21C4103C, "Smart Array", 0, 1}, ++ { 0x21C5103C, "Smart Array P841", 0, 1}, ++ { 0x21C6103C, "Smart HBA H244br", 0, 1}, ++ { 0x21C7103C, "Smart HBA H240", 0, 1}, ++ { 0x21C8103C, "Smart HBA H241", 0, 1}, ++ { 0x21C9103C, "Smart Array", 0, 1}, ++ { 0x21CA103C, "Smart Array P246br", 0, 1}, ++ { 0x21CB103C, "Smart Array P840", 0, 1}, ++ { 0x21CC103C, "Smart Array", 0, 1}, ++ { 0x21CD103C, "Smart Array", 0, 1}, ++ { 0x21CE103C, "Smart HBA", 0, 1}, ++ { 0x00761590, "HP Storage P1224 Array Controller", 0, 1}, /* VID = 3PAR */ ++ { 0x00871590, "HP Storage P1224e Array Controller", 0, 1}, ++ { 0x007D1590, "HP Storage P1228 Array Controller", 0, 1}, ++ { 0x00881590, "HP Storage P1228e Array Controller", 0, 1}, ++ { 0x333f103c, "HP StorageWorks 1210m Array Controller", 0, 1}, ++ /* end of hpsa list */ ++ { 0xe0110e11, "HP MSA500", 1, 0}, /* aka Smart Array CL */ ++ { 0xe0200e11, "HP MSA500 G2", 1, 0}, ++ { 0xe0300e11, "HP MSA20", 1, 0}, ++ { 0x3118103c, "HP B110i", 0, 1}, + { 0x00451590, "Dynamic Smart Array B320i", 0, 1}, + { 0x00471590, "Dynamic Smart Array B320i", 0, 1}, + { 0x00481590, "Dynamic Smart Array B120i", 0, 1}, diff --git a/packaging/debian/cciss-vol-status/rules b/packaging/debian/cciss-vol-status/rules index ebd6d62..f49f465 100755 --- a/packaging/debian/cciss-vol-status/rules +++ b/packaging/debian/cciss-vol-status/rules @@ -18,6 +18,20 @@ endif DESTDIR=$(CURDIR)/debian/cciss-vol-status +CFLAGS := $(shell dpkg-buildflags --get CFLAGS) +LDFLAGS := $(shell dpkg-buildflags --get LDFLAGS) +export DEB_BUILD_MAINT_OPTIONS = hardening=+all + +# Get version from changelog as well as lsb_release +# to compute unique build version (useful for repo mirroring systems doing file pooling) +PKG_VERSION := $(shell dpkg-parsechangelog | egrep '^Version:' | cut -f2 -d' ') +DIST_NAME := $(shell lsb_release -si) +DIST_RELEASE := $(shell lsb_release -sc) +DIST_VERSION := $(shell lsb_release -sr) +PKG_VERSION_TAG := $(PKG_VERSION)+$(DIST_NAME).$(DIST_RELEASE).$(DIST_VERSION) +SUBSTVARS_BINARY_VERSION := -Vbinary:Version="$(PKG_VERSION_TAG)" +SUBSTVARS_SOURCE_VERSION := -Vsource:Version="$(PKG_VERSION_TAG)" + configure: patch config.status: configure @@ -33,7 +47,7 @@ endif --bindir=/usr/sbin \ --mandir=/usr/share/man \ CFLAGS="$(CFLAGS)" \ - LDFLAGS="-Wl,-z,defs" + LDFLAGS="$(LDFLAGS)" build: build-arch build-indep build-indep: @@ -62,7 +76,8 @@ binary-arch: build install dh_testdir dh_testroot dh_installchangelogs ChangeLog - dh_installdocs + dh_installdocs -XREADME + dh_installexamples dh_installman dh_installinit --name=cciss-vol-statusd dh_link @@ -71,7 +86,7 @@ binary-arch: build install dh_fixperms dh_installdeb dh_shlibdeps - dh_gencontrol + dh_gencontrol -- -v"$(PKG_VERSION_TAG)" $(SUBSTVARS_BINARY_VERSION) $(SUBSTVARS_SOURCE_VERSION) dh_md5sums dh_builddeb