[RFC] laptop-detect being installed just on useful architectures
Hello,
I plan to commit this cuple of packages tomorrow, if noone objects, to
address the laptop-detect issue.
This changes laptop-detect from a dependency, on tasksel, to a
recommendation and let d-i to install it. This way we avoid the
changing of tasksel to architecture dependent package and solves the
problem of getting laptop-detect installed on every arch.
TIA,
>From 97b227a78fca9df976e2af528cb902d4292a96a0 Mon Sep 17 00:00:00 2001
From: Otavio Salvador <otavio@ossystems.com.br>
Date: Fri, 8 Feb 2008 10:03:50 -0200
Subject: [PATCH] pkgsel: installs laptop-detect on architectures know to have laptops
The architectures that're know to have laptops are i386, amd64,
powerpc and sparc (few but they exist) and then we install
laptop-detect only on those.
This change will just work if tasksel newer then 2.72 is used.
---
packages/pkgsel/debian/changelog | 7 ++++++-
packages/pkgsel/debian/rules | 1 +
packages/pkgsel/pre-pkgsel.d/10laptop-detect | 12 ++++++++++++
3 files changed, 19 insertions(+), 1 deletions(-)
create mode 100755 packages/pkgsel/pre-pkgsel.d/10laptop-detect
diff --git a/packages/pkgsel/debian/changelog b/packages/pkgsel/debian/changelog
index a87fd7f..a884bee 100644
--- a/packages/pkgsel/debian/changelog
+++ b/packages/pkgsel/debian/changelog
@@ -1,10 +1,15 @@
pkgsel (0.17) UNRELEASED; urgency=low
+ [ Colin Watson ]
* Pass pkgsel/include to aptitude following "--" to prevent typos in
preseed files being interpreted as aptitude options by accident.
* Silence syslog noise if /usr/lib/pre-pkgsel.d is empty.
- -- Colin Watson <cjwatson@debian.org> Thu, 10 Jan 2008 09:41:19 +0000
+ [ Otavio Salvador ]
+ * Install laptop-detect only when running at i386, amd64, sparc and
+ powerpc.
+
+ -- Otavio Salvador <otavio@ossystems.com.br> Fri, 08 Feb 2008 10:07:05 -0200
pkgsel (0.16) unstable; urgency=low
diff --git a/packages/pkgsel/debian/rules b/packages/pkgsel/debian/rules
index cc7ed2f..fff0e80 100755
--- a/packages/pkgsel/debian/rules
+++ b/packages/pkgsel/debian/rules
@@ -14,6 +14,7 @@ install: build
dh_clean -k
dh_installdirs
install -m755 pre-pkgsel.d/10popcon debian/pkgsel/usr/lib/pre-pkgsel.d
+ install -m755 pre-pkgsel.d/10laptop-detect debian/pkgsel/usr/lib/pre-pkgsel.d
dh_install
binary-indep: build install
diff --git a/packages/pkgsel/pre-pkgsel.d/10laptop-detect b/packages/pkgsel/pre-pkgsel.d/10laptop-detect
new file mode 100755
index 0000000..57cdd69
--- /dev/null
+++ b/packages/pkgsel/pre-pkgsel.d/10laptop-detect
@@ -0,0 +1,12 @@
+#!/bin/sh -e
+
+# Install laptop-detect on architectures know to have laptops
+arch="$(archdetect)"
+case "$arch" in
+ i386/*|amd64/*|powerpc/*|sparc/*)
+ apt-install laptop-detect || true
+ ;;
+ *)
+ logger -t pkgsel "$arch is not suppose to have laptops, skiping laptop-detect install"
+ ;;
+esac
--
1.5.4
Index: debian/control
===================================================================
--- debian/control (revisão 2058)
+++ debian/control (cópia de trabalho)
@@ -17,7 +17,8 @@
Package: tasksel-data
Architecture: all
-Depends: tasksel, laptop-detect
+Depends: tasksel
+Recommends: laptop-detect
Conflicts: tasksel (<< 2.67)
Description: Official tasks used for installation of Debian systems
This package contains data about the standard tasks available on a Debian
Index: debian/changelog
===================================================================
--- debian/changelog (revisão 2058)
+++ debian/changelog (cópia de trabalho)
@@ -3,6 +3,10 @@
[ Joey Hess ]
* Add smartmontools to the file-server task.
+ [ Otavio Salvador ]
+ * Change laptop-detect from a dependency to a recommendation. It will be
+ installed by d-i on specific architectures.
+
[ Translations of tasks ]
* Portuguese updated.
* Galician updated.
@@ -15,7 +19,7 @@
* Lithuanian updated.
* Korean updated.
- -- Bart Cornelis (cobaco) <cobaco@linux.be> Sat, 12 Jan 2008 18:00:12 +0100
+ -- Otavio Salvador <otavio@debian.org> Fri, 08 Feb 2008 10:13:49 -0200
tasksel (2.71) unstable; urgency=low
--
O T A V I O S A L V A D O R
---------------------------------------------
E-mail: otavio@debian.org UIN: 5906116
GNU/Linux User: 239058 GPG ID: 49A5F855
Home Page: http://otavio.ossystems.com.br
---------------------------------------------
"Microsoft sells you Windows ... Linux gives
you the whole house."
Reply to: