--- libatasmart-0.17.orig/debian/rules +++ libatasmart-0.17/debian/rules @@ -0,0 +1,18 @@ +#!/usr/bin/make -f + +include /usr/share/cdbs/1/rules/debhelper.mk +include /usr/share/cdbs/1/class/autotools.mk +include /usr/share/cdbs/1/rules/utils.mk +include /usr/share/cdbs/1/rules/patchsys-quilt.mk + +LDFLAGS += -Wl,--as-needed + +install/libatasmart-dev:: + dh_link -p$(cdbs_curpkg) lib/$$(basename $$(readlink debian/tmp/usr/lib/libatasmart.so)) usr/lib/libatasmart.so + +binary-install/libatasmart4:: + # when building for Ubuntu, install Apport hook + if [ "`lsb_release -is 2>/dev/null`" = "Ubuntu" ]; then \ + install -m 644 -D debian/local/apport-hook.py debian/$(cdbs_curpkg)/usr/share/apport/package-hooks/$(cdbs_curpkg).py; \ + fi + --- libatasmart-0.17.orig/debian/changelog +++ libatasmart-0.17/debian/changelog @@ -0,0 +1,70 @@ +libatasmart (0.17-1git1) lucid; urgency=low + + Upload current Debian git head. + + * debian/control: Wrap build dependencies. + * Add debian/local/apport-hook.py: Apport package hook for collecting + devkit-disks --dump and available SMART blobs. Install it in debian/rules + when building on Ubuntu. Add "lsb-release" build dependency for this. + + -- Martin Pitt Sat, 14 Nov 2009 16:45:19 -0600 + +libatasmart (0.17-1) unstable; urgency=low + + * New upstream release. + * debian/patches/01-export-symbols.patch + - Restrict the list of exported symbols to sk_*. + * debian/patches/99-autoreconf.patch + - Run automake to update the build system for the changes in + 01-export-symbols.patch. + * Use quilt to apply the patches. + + -- Michael Biebl Tue, 27 Oct 2009 05:24:25 +0100 + +libatasmart (0.16-1) unstable; urgency=low + + * New upstream release. + - Blacklist some more JMicron bridges. This includes the changes from + 0.15-3. + + -- Michael Biebl Tue, 29 Sep 2009 06:25:13 +0200 + +libatasmart (0.15-3) unstable; urgency=low + + * atasmart.c: Blacklist JMicron drives 152d:233[89] as well, since they were + also confirmed to cause USB resets on SMART probing. (LP: #387161, + https://bugzilla.redhat.com/show_bug.cgi?id=515881) + + -- Martin Pitt Thu, 24 Sep 2009 11:26:24 +0200 + +libatasmart (0.15-2) unstable; urgency=low + + * Move libatasmart4 to /lib so DeviceKit-disks and its udev helper will + work without /usr being mounted. + + -- Michael Biebl Wed, 23 Sep 2009 16:17:21 +0200 + +libatasmart (0.15-1) unstable; urgency=low + + * New upstream bug fix release. In particular, this blacklists + the JMicron SATA bridge 152d:2329, since it causes USB resets when being + probed for SMART. (https://bugzilla.redhat.com/show_bug.cgi?id=515881, + LP: #387161) + * Bump Standards-Version to 3.8.3 (no changes necessary). + + -- Martin Pitt Fri, 18 Sep 2009 09:31:34 +0200 + +libatasmart (0.14-1) unstable; urgency=low + + * New upstream version. + * Update *.install, *.symbols, and debian/control for 0 → 4 library soname + change. + * Add myself to uploaders. + + -- Martin Pitt Fri, 07 Aug 2009 10:13:42 +0100 + +libatasmart (0.13-1) unstable; urgency=low + + * Initial release. (Closes: #527305) + + -- Michael Biebl Wed, 06 May 2009 21:43:52 +0200 --- libatasmart-0.17.orig/debian/watch +++ libatasmart-0.17/debian/watch @@ -0,0 +1,2 @@ +version=3 +http://0pointer.de/public/libatasmart-(.*).tar.gz --- libatasmart-0.17.orig/debian/libatasmart4.symbols +++ libatasmart-0.17/debian/libatasmart4.symbols @@ -0,0 +1,28 @@ +libatasmart.so.4 libatasmart4 #MINVER# + sk_disk_check_sleep_mode@Base 0.13 + sk_disk_dump@Base 0.13 + sk_disk_free@Base 0.13 + sk_disk_get_blob@Base 0.13 + sk_disk_get_size@Base 0.13 + sk_disk_identify_is_available@Base 0.13 + sk_disk_identify_parse@Base 0.13 + sk_disk_open@Base 0.13 + sk_disk_set_blob@Base 0.13 + sk_disk_smart_get_bad@Base 0.13 + sk_disk_smart_get_overall@Base 0.13 + sk_disk_smart_get_power_cycle@Base 0.13 + sk_disk_smart_get_power_on@Base 0.13 + sk_disk_smart_get_temperature@Base 0.13 + sk_disk_smart_is_available@Base 0.13 + sk_disk_smart_parse@Base 0.13 + sk_disk_smart_parse_attributes@Base 0.13 + sk_disk_smart_read_data@Base 0.13 + sk_disk_smart_self_test@Base 0.13 + sk_disk_smart_status@Base 0.13 + sk_smart_attribute_unit_to_string@Base 0.13 + sk_smart_offline_data_collection_status_to_string@Base 0.13 + sk_smart_overall_to_string@Base 0.13 + sk_smart_self_test_available@Base 0.13 + sk_smart_self_test_execution_status_to_string@Base 0.13 + sk_smart_self_test_polling_minutes@Base 0.13 + sk_smart_self_test_to_string@Base 0.13 --- libatasmart-0.17.orig/debian/copyright +++ libatasmart-0.17/debian/copyright @@ -0,0 +1,39 @@ +This package was debianized by Michael Biebl on +Wed, 06 May 2009 21:43:52 +0200 + +It was downloaded from http://git.0pointer.de/?p=libatasmart.git;a=summary + +Upstream Author: + + Lennart Poettering + +Copyright: + + Copyright 2008 Lennart Poettering + +License: + + This package is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + This package is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with this package; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + +On Debian systems, the complete text of the GNU Lesser General +Public License can be found in `/usr/share/common-licenses/LGPL-2.1'. + +The Debian packaging is: + + Copyright (C) 2009 Michael Biebl + +and is licensed under the GPL version 3, +see `/usr/share/common-licenses/GPL-3'. + --- libatasmart-0.17.orig/debian/libatasmart-bin.install +++ libatasmart-0.17/debian/libatasmart-bin.install @@ -0,0 +1 @@ +usr/sbin/ --- libatasmart-0.17.orig/debian/compat +++ libatasmart-0.17/debian/compat @@ -0,0 +1 @@ +7 --- libatasmart-0.17.orig/debian/libatasmart-dev.install +++ libatasmart-0.17/debian/libatasmart-dev.install @@ -0,0 +1,3 @@ +usr/include/* +usr/lib/libatasmart.a +usr/lib/pkgconfig/* --- libatasmart-0.17.orig/debian/libatasmart4.install +++ libatasmart-0.17/debian/libatasmart4.install @@ -0,0 +1 @@ +usr/lib/libatasmart.so.* lib/ --- libatasmart-0.17.orig/debian/control +++ libatasmart-0.17/debian/control @@ -0,0 +1,47 @@ +Source: libatasmart +Section: libs +Priority: optional +Maintainer: Utopia Maintenance Team +Uploaders: Michael Biebl , Martin Pitt +Build-Depends: debhelper (>= 7), + cdbs, + autotools-dev, + quilt, + lsb-release, + pkg-config, + libudev-dev +Standards-Version: 3.8.3 +Vcs-Git: git://git.debian.org/git/pkg-utopia/libatasmart.git +Vcs-Browser: http://git.debian.org/?p=pkg-utopia/libatasmart.git;a=summary +Homepage: http://0pointer.de/blog/projects/being-smart.html + +Package: libatasmart-dev +Section: libdevel +Architecture: any +Depends: libatasmart4 (= ${binary:Version}), ${misc:Depends} +Description: ATA S.M.A.R.T. reading and parsing library - development files + A small and lightweight parser library for ATA S.M.A.R.T. hard disk + health monitoring. + . + This package contains the development files. + +Package: libatasmart4 +Section: libs +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: ATA S.M.A.R.T. reading and parsing library + A small and lightweight parser library for ATA S.M.A.R.T. hard disk + health monitoring. + . + This package contains the shared library. + +Package: libatasmart-bin +Section: utils +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: ATA S.M.A.R.T. reading and parsing library - utilities + A small and lightweight parser library for ATA S.M.A.R.T. hard disk + health monitoring. + . + This package contains utilities which allow to query the S.M.A.R.T. + information. --- libatasmart-0.17.orig/debian/local/apport-hook.py +++ libatasmart-0.17/debian/local/apport-hook.py @@ -0,0 +1,32 @@ +'''apport package hook for libatasmart + +(c) 2009 Canonical Ltd. +Author: Martin Pitt +''' + +import os +import os.path +import apport.hookutils +import dbus + +DK_D = 'org.freedesktop.DeviceKit.Disks' + +def add_info(report): + report['DevkitDisksDump'] = apport.hookutils.command_output(['devkit-disks', '--dump']) + + # grab SMART blobs + dkd = dbus.Interface(dbus.SystemBus().get_object(DK_D, + '/org/freedesktop/DeviceKit/Disks'), DK_D) + for d in dkd.EnumerateDevices(): + dev_props = dbus.Interface(dbus.SystemBus().get_object(DK_D, d), + dbus.PROPERTIES_IFACE) + blob = dev_props.Get(DK_D, 'DriveAtaSmartBlob') + if len(blob) > 0: + report['AtaSmartBlob_' + os.path.basename(d)] = ''.join(map(chr, blob)) + +if __name__ == '__main__': + r = {} + add_info(r) + for k, v in r.iteritems(): + print '%s: "%s"' % (k, v) + --- libatasmart-0.17.orig/debian/patches/series +++ libatasmart-0.17/debian/patches/series @@ -0,0 +1,3 @@ +# Debian patches for libatasmart +01-export-symbols.patch +99-autoreconf.patch --- libatasmart-0.17.orig/debian/patches/99-autoreconf.patch +++ libatasmart-0.17/debian/patches/99-autoreconf.patch @@ -0,0 +1,14 @@ +diff --git a/Makefile.in b/Makefile.in +index 48630be..1ca8027 100644 +--- a/Makefile.in ++++ b/Makefile.in +@@ -380,7 +380,8 @@ libatasmart_la_SOURCES = \ + atasmart.strpool.c atasmart.h + + libatasmart_la_LDFLAGS = \ +- -version-info $(LIBATASMART_VERSION_INFO) ++ -version-info $(LIBATASMART_VERSION_INFO) \ ++ -export-symbols-regex '(^sk_.*)' + + libatasmart_la_LIBADD = \ + $(LIBUDEV_LIBS) --- libatasmart-0.17.orig/debian/patches/01-export-symbols.patch +++ libatasmart-0.17/debian/patches/01-export-symbols.patch @@ -0,0 +1,18 @@ +Description: Restrict the list of exported symbols to sk_.* + Use libtools' -export-symbols-regex to restrict the list of exported symbols + so we not accidentally export symbols like init_smart +Author: Michael Biebl +diff --git a/Makefile.am b/Makefile.am +index 381e920..b5f9476 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -83,7 +83,8 @@ sktest_LDADD = \ + libatasmart_la_SOURCES = \ + atasmart.strpool.c atasmart.h + libatasmart_la_LDFLAGS = \ +- -version-info $(LIBATASMART_VERSION_INFO) ++ -version-info $(LIBATASMART_VERSION_INFO) \ ++ -export-symbols-regex '(^sk_.*)' + libatasmart_la_LIBADD = \ + $(LIBUDEV_LIBS) + libatasmart_la_CFLAGS = \