From 6c1a2cfab139bb4a61e7bcf5f4cafe3b7498f64e Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 23 Sep 2007 14:46:24 +0200 Subject: Adding casper 1.66+debian-1. --- debian/casper.dirs | 4 +++ debian/casper.init | 45 ++++++++++++++++++++++++++++++++ debian/casper.install | 6 +++++ debian/casper.postinst | 5 ++++ debian/changelog | 7 +++++ debian/changelog.upstream | 10 ++++++++ debian/control | 4 +-- debian/control.debian | 17 +++++++++++++ debian/control.ubuntu | 25 ++++++++++++++++++ debian/dirs | 4 --- debian/init.d | 45 -------------------------------- debian/install | 6 ----- debian/postinst | 5 ---- debian/rules | 65 +++++++++++++++++++++++++++++++++++++---------- 14 files changed, 173 insertions(+), 75 deletions(-) create mode 100644 debian/casper.dirs create mode 100644 debian/casper.init create mode 100644 debian/casper.install create mode 100644 debian/casper.postinst create mode 100644 debian/control.debian create mode 100644 debian/control.ubuntu delete mode 100644 debian/dirs delete mode 100644 debian/init.d delete mode 100644 debian/install delete mode 100644 debian/postinst (limited to 'debian') diff --git a/debian/casper.dirs b/debian/casper.dirs new file mode 100644 index 0000000..bb225f1 --- /dev/null +++ b/debian/casper.dirs @@ -0,0 +1,4 @@ +/etc +/usr/lib/casper +/usr/share/initramfs-tools/hooks +/usr/share/initramfs-tools/scripts diff --git a/debian/casper.init b/debian/casper.init new file mode 100644 index 0000000..e0522e0 --- /dev/null +++ b/debian/casper.init @@ -0,0 +1,45 @@ +#! /bin/sh + +# check for netboot +if grep -qs netboot /proc/cmdline || grep -qsi root=/dev/nfs /proc/cmdline || grep -qsi root=/dev/cifs /proc/cmdline ; then + exit 0 +fi + +grep -qs boot=casper /proc/cmdline || exit 0 + +# Try to cache everything we're likely to need after ejecting. This +# is fragile and simple-minded, but our options are limited. +cache_path() { + path="$1" + + if [ -d "$path" ]; then + find "$path" -type f | xargs cat > /dev/null 2>&1 + elif [ -f "$path" ]; then + if [ -x "$path" ]; then + if file "$path" | grep -q 'dynamically linked'; then + for lib in $(ldd "$path" | awk '{ print $3 }'); do + cache_path "$lib" + done + fi + fi + cat "$path" >/dev/null 2>&1 + fi +} + +for path in $(which halt) $(which reboot) /etc/rc?.d /etc/default; do + cache_path "$path" +done + +eject -p -m /live_media >/dev/null 2>&1 + +# XXX - i18n +echo -n "Please remove the disc and close the tray (if any) then press ENTER: " +if [ -x /sbin/usplash_write ]; then + /sbin/usplash_write "TIMEOUT 0" + /sbin/usplash_write "TEXT Please remove the disc, close the tray (if any)" + /sbin/usplash_write "TEXT and press ENTER to continue" +fi + +read x < /dev/console + +exit 0 diff --git a/debian/casper.install b/debian/casper.install new file mode 100644 index 0000000..2514756 --- /dev/null +++ b/debian/casper.install @@ -0,0 +1,6 @@ +bin/casper-reconfigure usr/share/casper +bin/casper-preseed usr/share/casper +bin/casper-getty sbin +bin/casper-login sbin +hooks usr/share/initramfs-tools +scripts usr/share/initramfs-tools diff --git a/debian/casper.postinst b/debian/casper.postinst new file mode 100644 index 0000000..d7bc14d --- /dev/null +++ b/debian/casper.postinst @@ -0,0 +1,5 @@ +#!/bin/sh + +update-initramfs -u + +#DEBHELPER# diff --git a/debian/changelog b/debian/changelog index 9da2e97..33da0a9 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +casper (1.66+debian-1) unstable; urgency=low + + * Added "magic" to make it work seamlessy also on ubuntu systems. + * Default user password now "live". + + -- Marco Amadori Fri, 1 Sep 2006 17:18:07 +0200 + casper (1.65+debian-1) unstable; urgency=low * New upstream release. diff --git a/debian/changelog.upstream b/debian/changelog.upstream index 8e20a26..6eb6873 100644 --- a/debian/changelog.upstream +++ b/debian/changelog.upstream @@ -1,3 +1,13 @@ +casper (1.66) edgy; urgency=low + + * Fix use of db_get in ubiquity accessibility hook. + * Use sudo instead of su to get to the live session user from the + initramfs or to the newly-installed user from ubiquity. su's argument + handling has changed so that the previous code no longer worked, and su + was never all that good for arguments containing spaces anyway. + + -- Colin Watson Mon, 4 Sep 2006 15:46:55 +0100 + casper (1.65) edgy; urgency=low * Update to call udevsettle/udevtrigger instead of udevplug diff --git a/debian/control b/debian/control index 4445546..cd9eee6 100644 --- a/debian/control +++ b/debian/control @@ -1,9 +1,9 @@ Source: casper Section: misc -Priority: optional +Priority: extra Maintainer: Debian Live Uploaders: Marco Amadori , Daniel Baumann -Build-Depends: debhelper (>= 4) +Build-Depends: debhelper (>= 4), lsb-release Standards-Version: 3.7.2 Package: casper diff --git a/debian/control.debian b/debian/control.debian new file mode 100644 index 0000000..cd9eee6 --- /dev/null +++ b/debian/control.debian @@ -0,0 +1,17 @@ +Source: casper +Section: misc +Priority: extra +Maintainer: Debian Live +Uploaders: Marco Amadori , Daniel Baumann +Build-Depends: debhelper (>= 4), lsb-release +Standards-Version: 3.7.2 + +Package: casper +Architecture: any +Depends: initramfs-tools (>= 0.40), user-setup +Conflicts: usplash (<< 0.1-30) +Recommends: live-package +Suggests: dmsetup +Description: Debian Live initramfs generator + Casper provides an initramfs generator suited for booting a Debian Live systems + from read only media. Useful to build live CDs. diff --git a/debian/control.ubuntu b/debian/control.ubuntu new file mode 100644 index 0000000..a8ab8de --- /dev/null +++ b/debian/control.ubuntu @@ -0,0 +1,25 @@ +Source: casper +Section: misc +Priority: optional +Maintainer: Tollef Fog Heen +Build-Depends: debhelper (>> 4.2.0), lsb-release +Standards-Version: 3.6.1 + +Package: casper +Architecture: any +Section: misc +Priority: extra +Depends: initramfs-tools (>= 0.40ubuntu11), dmsetup, user-setup, sudo +Conflicts: usplash (<< 0.1-30) +Description: Run a "live" preinstalled system from read-only media + +Package: ubiquity-casper +Architecture: all +Depends: laptop-detect, sudo +Conflicts: espresso-casper +Replaces: espresso-casper +Enhances: ubiquity +Description: Configuration hooks for live installer + This package provides hook scripts for the Ubiquity live installer that + repeat some pieces of configuration done by the live system boot process in + the system installed by Ubiquity. diff --git a/debian/dirs b/debian/dirs deleted file mode 100644 index bb225f1..0000000 --- a/debian/dirs +++ /dev/null @@ -1,4 +0,0 @@ -/etc -/usr/lib/casper -/usr/share/initramfs-tools/hooks -/usr/share/initramfs-tools/scripts diff --git a/debian/init.d b/debian/init.d deleted file mode 100644 index 424c024..0000000 --- a/debian/init.d +++ /dev/null @@ -1,45 +0,0 @@ -#! /bin/sh - -# check for netboot -if grep -qs netboot /proc/cmdline || grep -qsi root=/dev/nfs /proc/cmdline || grep -qsi root=/dev/cifs /proc/cmdline ; then - exit 0 -fi - -grep -qs boot=casper /proc/cmdline || exit 0 - -# Try to cache everything we're likely to need after ejecting. This -# is fragile and simple-minded, but our options are limited. -cache_path() { - path="$1" - - if [ -d "$path" ]; then - find "$path" -type f | xargs cat > /dev/null 2>&1 - elif [ -f "$path" ]; then - if [ -x "$path" ]; then - if file "$path" | grep -q 'dynamically linked'; then - for lib in $(ldd "$path" | awk '{ print $3 }'); do - cache_path "$lib" - done - fi - fi - cat "$path" >/dev/null 2>&1 - fi -} - -for path in $(which halt) $(which reboot) /etc/rc?.d /etc/default; do - cache_path "$path" -done - -eject -p -m /live_media >/dev/null 2>&1 - -# XXX - i18n -echo -n "Please remove the disc (if any), close the tray (if any) and press ENTER: " -if [ -x /sbin/usplash_write ]; then - /sbin/usplash_write "TIMEOUT 0" - /sbin/usplash_write "TEXT Please remove the disc, close the tray (if any)" - /sbin/usplash_write "TEXT and press ENTER to continue" -fi - -read x < /dev/console - -exit 0 diff --git a/debian/install b/debian/install deleted file mode 100644 index 2514756..0000000 --- a/debian/install +++ /dev/null @@ -1,6 +0,0 @@ -bin/casper-reconfigure usr/share/casper -bin/casper-preseed usr/share/casper -bin/casper-getty sbin -bin/casper-login sbin -hooks usr/share/initramfs-tools -scripts usr/share/initramfs-tools diff --git a/debian/postinst b/debian/postinst deleted file mode 100644 index d7bc14d..0000000 --- a/debian/postinst +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/sh - -update-initramfs -u - -#DEBHELPER# diff --git a/debian/rules b/debian/rules index bd01663..d1d44a5 100755 --- a/debian/rules +++ b/debian/rules @@ -3,25 +3,42 @@ # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 +# Looking in which build system we are +BUILD_SYSTEM := $(shell lsb_release --short --id) + build: build-stamp build-stamp: dh_testdir - + # Setting BUILD_SYSTEM in the binary package + sed -i -e 's/\(BUILD_SYSTEM="\).*"/\1'$(BUILD_SYSTEM)'"/g' casper.conf +ifeq ($(BUILD_SYSTEM),Debian) + cp debian/control.debian debian/control +else + cp debian/control.ubuntu debian/control +endif + # Building package $(MAKE) -C casper-md5check touch build-stamp clean: + dh_testdir rm -f build-stamp # Cleaning package -$(MAKE) -C casper-md5check clean + # Putting back default files + cp -f debian/control.debian debian/control + sed -i -e 's/\(BUILD_SYSTEM="\).*"/\1'Debian'"/g' casper.conf + dh_clean + install: build + dh_testdir dh_testroot dh_clean -k @@ -37,23 +54,45 @@ install: build # Installing lintian override install -D -m 0644 debian/lintian debian/casper/usr/share/lintian/overrides/casper + # Install casper.conf + install -m 0644 casper.conf debian/casper/etc/casper.conf + binary-indep: build install +ifneq ($(BUILD_SYSTEM),Debian) + # Conditionally build Ubiquity + dh_testdir + dh_testroot + dh_installexamples -i + dh_installdocs -i + dh_installchangelogs -i + dh_compress -i + dh_fixperms -i + dh_installdeb -i + dh_gencontrol -i + dh_md5sums -i + dh_builddeb -i +endif binary-arch: build install + dh_testdir dh_testroot - dh_installchangelogs debian/changelog.upstream - dh_installdocs - dh_installexamples - dh_installinit -r --no-start -- start 89 0 6 . - dh_link - dh_strip - dh_compress - dh_fixperms - dh_installdeb - dh_gencontrol - dh_md5sums - dh_builddeb +ifeq ($(BUILD_SYSTEM),Debian) + dh_installchangelogs -a debian/changelog.upstream +else + dh_installchangelogs -a +endif + dh_installdocs -a + dh_installexamples -a + dh_installinit -a -r --no-start -- start 89 0 6 . + dh_link -a + dh_strip -a + dh_compress -a + dh_fixperms -a + dh_installdeb -a + dh_gencontrol -a + dh_md5sums -a + dh_builddeb -a binary: binary-arch binary-indep .PHONY: build clean binary-indep binary-arch binary install -- cgit v1.2.3