From 14df8049d828f88e79ae1d3944e4e1d607f21f94 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Mathieu=20B=C3=A9rard?= Date: Thu, 10 Aug 2006 23:29:26 +0000 Subject: [PATCH] Update in Debian package (Thanks Julien Valroff) --- Makefile | 2 +- debian/changelog | 28 +++++-- debian/control | 14 +++- debian/control.modules.in | 6 +- debian/postinst.modules.in | 2 +- debian/postrm.modules.in | 2 +- debian/rules | 147 +++++++++++++------------------------ doc/ChangeLog | 1 + 8 files changed, 92 insertions(+), 110 deletions(-) diff --git a/Makefile b/Makefile index 52547e3..480affc 100644 --- a/Makefile +++ b/Makefile @@ -68,7 +68,7 @@ clean: install: all - # Removing module from old possible locations + # Removing module from locations used by previous versions $(RM) $(VMODDIR)/kernel/drivers/char/$(MODULE_NAME).ko $(RM) $(VMODDIR)/kernel/drivers/misc/$(MODULE_NAME).ko make INSTALL_MOD_PATH=$(DESTDIR) INSTALL_MOD_DIR=$(INSTDIR) -C $(KSRC) M=$(PWD) modules_install diff --git a/debian/changelog b/debian/changelog index 9dc03e8..6e6b9e1 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,14 +1,30 @@ -omnibook (1:2.20060809) unstable; urgency=low +omnibook (2:2.20060809-2) unstable; urgency=low - * New bugfix version + * Include copyright and Debian changelog in omnibook-module + * Fix Makefile issue in a more elegant way - -- Mathieu Bérard Wed, 9 Aug 2006 18:54:17 +0200 + -- Julien Valroff Thu, 10 Aug 2006 10:16:47 +0200 -omnibook (1:2.20060806) unstable; urgency=low +omnibook (2:2.20060809-1) unstable; urgency=low - * New major version (see changelog.gz for details). + * New upstream release: + + Addeed autodetection of the Toshiba Satellite M40X laptop - -- Mathieu Bérard Sun, 6 Aug 2006 23:26:00 +0200 + -- Julien Valroff Thu, 10 Aug 2006 09:40:45 +0200 + +omnibook (2:2.20060806-1) unstable; urgency=low + + * New upstream branch - Mathieu Bérard launched new project + * Added myself as co-maintainer + * Bumped upstream version and use epoch to ensure upgrades + * [debian/rules]: + + Clean-ups + + Recommends linux-image or kernel-image + * [debian/control] Improved long description + * [debian/post*.modules.in] Fixed bashisms + * Added patch to fix install target in Makefile + + -- Julien Valroff Thu, 10 Aug 2006 01:35:38 +0200 omnibook (20060126-1) unstable; urgency=low diff --git a/debian/control b/debian/control index 97f81fe..66023d3 100644 --- a/debian/control +++ b/debian/control @@ -2,12 +2,20 @@ Source: omnibook Section: misc Priority: optional Maintainer: Mathieu Bérard -Build-Depends: debhelper (>> 4.0.0) +Uploaders: Julien Valroff +Build-Depends: debhelper (>> 4.0.0), dpatch Standards-Version: 3.7.2 Package: omnibook-source Architecture: all -Depends: build-essential, debhelper, module-assistant, kernel-package +Depends: debhelper (>= 4.0.0), make, module-assistant, kernel-package Description: Source for the omnibook driver - This package provides the source code for the omnibook kernel module. + This package contains the loadable kernel modules for the HP OmniBooks, + Pavilions, Toshiba Satellites and some other laptops manufactured by + Compal Electronics, Inc as ODM. + . + This module is only compatible with Linux kernels >= 2.6.8 + . Kernel source is required to compile this module. + . + Homepage: http://sourceforge.net/projects/omnibook/ diff --git a/debian/control.modules.in b/debian/control.modules.in index 21b8718..954a712 100644 --- a/debian/control.modules.in +++ b/debian/control.modules.in @@ -2,12 +2,13 @@ Source: omnibook Section: misc Priority: optional Maintainer: Mathieu Bérard -Build-Depends: debhelper (>> 4.0.0), build-essential, module-assistant, kernel-package +Uploaders: Julien Valroff +Build-Depends: debhelper (>> 4.0.0) Standards-Version: 3.7.2 Package: omnibook-module-_KVERS_ Architecture: i386 -Depends: kernel-image-_KVERS_ | linux-image-_KVERS_ +Recommends: _STEM_-image-_KVERS_ Provides: omnibook-module Description: omnibook module for Linux (kernel _KVERS_) This package contains the loadable kernel modules for the HP OmniBooks, @@ -20,3 +21,4 @@ Description: omnibook module for Linux (kernel _KVERS_) your own omnibook-module. The omnibook-source package has been provided for use with the Debian kernel-package utility to produce a version of omnibook-module for your kernel. + diff --git a/debian/postinst.modules.in b/debian/postinst.modules.in index 29a0a71..4f6e28f 100644 --- a/debian/postinst.modules.in +++ b/debian/postinst.modules.in @@ -23,7 +23,7 @@ case "$1" in if [ "`uname -r`" = "_KVERS_" ] ; then depmod -a > /dev/null 2>&1 || true else - depmod "_KVERS_" &> /dev/null || true + depmod "_KVERS_" > /dev/null 2>&1 || true fi ;; diff --git a/debian/postrm.modules.in b/debian/postrm.modules.in index c0105b5..6bd42a0 100644 --- a/debian/postrm.modules.in +++ b/debian/postrm.modules.in @@ -24,7 +24,7 @@ case "$1" in if [ "`uname -r`" = "_KVERS_" ] ; then depmod -a > /dev/null 2>&1 || true else - depmod "_KVERS_" &> /dev/null || true + depmod "_KVERS_" > /dev/null 2>&1 || true fi diff --git a/debian/rules b/debian/rules index d9a4b5d..27b5631 100755 --- a/debian/rules +++ b/debian/rules @@ -1,20 +1,11 @@ #!/usr/bin/make -f # -*- makefile -*- -# Sample debian/rules that uses debhelper. -# This file was originally written by Joey Hess and Craig Small. -# As a special exception, when this file is copied by dh-make into a -# dh-make output file, you may use that output file without restriction. -# This special exception was added by Craig Small in version 0.37 of dh-make. -# -# This version is for a hypothetical package that can build a kernel modules -# architecture-dependant package via make-kpkg, as well as an -# architecture-independent module source package, and other packages -# either dep/indep for things like common files or userspace components -# needed for the kernel modules. # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 +include /usr/share/dpatch/dpatch.make + CFLAGS = -Wall -g ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) @@ -23,47 +14,15 @@ else CFLAGS += -O2 endif -# some default definitions, important! -# # Name of the source package psource := omnibook-source # The short upstream name, used for the module source directory sname := omnibook -### KERNEL SETUP -### Setup the stuff needed for making kernel module packages -### taken from /usr/share/kernel-package/sample.module.rules - # prefix of the target package name PACKAGE=omnibook-module -# modifieable for experiments or debugging m-a -MA_DIR ?= /usr/share/modass -# load generic variable handling --include $(MA_DIR)/include/generic.make -# load default rules, including kdist, kdist_image, ... --include $(MA_DIR)/include/common-rules.make - -# module assistant calculates all needed things for us and sets -# following variables: -# KSRC (kernel source directory), KVERS (kernel version string), KDREV -# (revision of the Debian kernel-image package), CC (the correct -# compiler), VERSION (the final package version string), PKGNAME (full -# package name with KVERS included), DEB_DESTDIR (path to store DEBs) - -# The kdist_configure target is called by make-kpkg modules_config and -# by kdist* rules by dependency. It should configure the module so it is -# ready for compilation (mostly useful for calling configure). -# prep-deb-files from module-assistant creates the neccessary debian/ files -kdist_config: prep-deb-files - -# the kdist_clean target is called by make-kpkg modules_clean and from -# kdist* rules. It is responsible for cleaning up any changes that have -# been made by the other kdist_commands (except for the .deb files created) -kdist_clean: - -$(MAKE) KSRC=$(KSRC) clean - dh_clean -# + ### end KERNEL SETUP configure: configure-stamp @@ -77,50 +36,22 @@ build-arch-stamp: dh_testdir touch build-arch-stamp -#k = $(shell echo $(KVERS) | grep -q ^2.6 && echo k) - -# the binary-modules rule is invoked by module-assistant while processing the -# kdist* targets. It is called by module-assistant or make-kpkg and *not* -# during a normal build -binary-modules: prep-deb-files - dh_testroot - dh_clean -k - dh_installdirs lib/modules/$(KVERS)/extra - - # Build the module - #$(MAKE) -C drivers KERNEL_DIR=$(KSRC) KVERS=$(KVERS) - $(MAKE) KSRC=$(KSRC) KVERS=$(KVERS) - - # Install the module - $(MAKE) install KSRC=$(KSRC) DESTDIR=$(CURDIR)/debian/$(PKGNAME) INSTDIR=extra DEPMOD="" - - dh_installdocs - dh_installchangelogs - dh_compress - dh_fixperms - dh_installdeb - dh_gencontrol -- -v$(VERSION) - dh_md5sums - dh_builddeb --destdir=$(DEB_DESTDIR) - dh_clean -k - -build-indep: configure-stamp build-indep-stamp +build-indep: patch configure-stamp build-indep-stamp build-indep-stamp: dh_testdir touch build-indep-stamp -build: build-arch build-indep +build: patch build-arch build-indep -clean: +clean: unpatch dh_testdir - #dh_testroot rm -f build-arch-stamp build-indep-stamp configure-stamp dh_clean install: DH_OPTIONS= -install: build +install: patch build dh_testdir dh_testroot dh_clean -k @@ -128,16 +59,12 @@ install: build # Create the directories to install the source into dh_installdirs -p$(psource) usr/src/modules/$(sname)/debian - cp debian/compat debian/rules debian/changelog \ - debian/copyright debian/control \ + debian/control debian/copyright debian/*.modules.in \ debian/$(psource)/usr/src/modules/$(sname)/debian - cp debian/*.modules.in debian/$(psource)/usr/src/modules/$(sname)/debian + cp Makefile *.c *.h *.lds debian/$(psource)/usr/src/modules/$(sname) - cp Makefile *.c *.h *.lds debian/$(psource)/usr/src/modules/$(sname)/ - cd debian/$(psource)/usr/src && tar c modules | gzip -9 > $(sname).tar.gz && rm -rf modules - dh_install # Build architecture-independent files here. @@ -148,32 +75,60 @@ binary-indep: build install dh_installchangelogs -i doc/ChangeLog dh_installdocs -i dh_installexamples -i -# dh_install -i -# dh_installmenu -i -# dh_installdebconf -i -# dh_installlogrotate -i -# dh_installemacsen -i -# dh_installpam -i -# dh_installmime -i -# dh_installinit -i -# dh_installcron -i -# dh_installinfo -i dh_installman -i dh_link -i dh_compress -i dh_fixperms -i dh_installdeb -i -# dh_perl -i -# dh_python -i -# dh_makeshlibs -i dh_installdeb -i dh_shlibdeps -i dh_gencontrol -i dh_md5sums -i dh_builddeb -i - + # Build architecture-dependent files here. binary-arch: build install +# modifieable for experiments or debugging m-a +MA_DIR ?= /usr/share/modass +# load generic variable handling +-include $(MA_DIR)/include/generic.make +# load default rules, including kdist, kdist_image, ... +-include $(MA_DIR)/include/common-rules.make + +ifndef KPKG_STEM +STEM:=kernel +else +STEM:=${KPKG_STEM} +endif + +kdist_clean: prep-deb-files + -$(MAKE) KSRC=$(KSRC) clean + dh_clean + +kdist_config: prep-deb-files + sed -i -e 's/_STEM_/$(STEM)/g' debian/control + +binary-modules: kdist_config prep-deb-files + dh_testroot + dh_clean -k + dh_installdirs lib/modules/$(KVERS)/extra + + # Build the module + $(MAKE) KSRC=$(KSRC) KVERS=$(KVERS) + + # Install the module + $(MAKE) install KSRC=$(KSRC) DESTDIR=$(CURDIR)/debian/$(PKGNAME) INSTDIR=extra DEPMOD="" + + dh_installdocs + dh_compress + dh_installchangelogs + dh_fixperms + dh_installdeb + dh_gencontrol -- -v$(VERSION) + dh_md5sums + dh_builddeb --destdir=$(DEB_DESTDIR) + dh_clean -k + binary: binary-indep binary-arch .PHONY: build clean binary-indep binary-arch binary install configure binary-modules kdist kdist_config kdist_image kdist_clean diff --git a/doc/ChangeLog b/doc/ChangeLog index 9de3b75..64cf65c 100644 --- a/doc/ChangeLog +++ b/doc/ChangeLog @@ -8,6 +8,7 @@ Changelog file for omnibook package: the support is pretty minimalistic (LCD brigtness only) this also inaugurate ectype 14 * Cleanup/Fix in Makefile +* Improvements in the Debian packages by Julien Valroff 2.20060809 Mathieu Bérard * Add dmi info for Toshiba Satellite M40X (Thanks Julien Valroff) -- 2.43.5