Skip to content

Commit

Permalink
Adding live-initramfs 1.87.2-1.
Browse files Browse the repository at this point in the history
  • Loading branch information
daniel-baumann committed Sep 23, 2007
1 parent 85b2d27 commit 292e65d
Show file tree
Hide file tree
Showing 58 changed files with 194 additions and 261 deletions.
15 changes: 0 additions & 15 deletions bin/casper-getty

This file was deleted.

6 changes: 0 additions & 6 deletions bin/casper-login

This file was deleted.

20 changes: 20 additions & 0 deletions bin/live-getty
@@ -0,0 +1,20 @@
#!/bin/sh

set -e

AUTOLOGIN="1"

for ARGUMENT in "${@}"
do
if [ "${ARGUMENT}" = "-l" ] || [ "${ARGUMENT}" = "-n" ]
then
AUTOLOGIN="0"
fi
done

if [ "${AUTOLOGIN}" = "1" ]
then
exec /sbin/getty -n -l /sbin/live-login ${*}
else
exec /sbin/getty ${*}
fi
12 changes: 12 additions & 0 deletions bin/live-login
@@ -0,0 +1,12 @@
#!/bin/sh

set -e

USERNAME="root"

if [ -f /etc/live.conf ]
then
. /etc/live.conf
fi

exec /bin/login -f "${USERNAME}"
4 changes: 2 additions & 2 deletions casper-md5check/Makefile → bin/live-md5check/Makefile
Expand Up @@ -3,7 +3,7 @@ CC=gcc
LDFLAGS=-lm
CFLAGS=$(getconf LFS_CFLAGS) -Wall -O2

casper-md5check: casper-md5check.c md5.c
live-md5check: live-md5check.c md5.c

clean:
rm -f *.o casper-md5check
rm -f *.o live-md5check
File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 2 additions & 2 deletions bin/casper-preseed → bin/live-preseed
Expand Up @@ -8,8 +8,8 @@ value="$3"
seen="$4"
[ "$seen" ] || seen=true

if ! (echo "SET $question $value"; echo "FSET $question seen $seen") | chroot "$1" debconf-communicate -fnoninteractive casper >/dev/null; then
chroot "$1" debconf-communicate -fnoninteractive casper >/dev/null <<EOF
if ! (echo "SET $question $value"; echo "FSET $question seen $seen") | chroot "$1" debconf-communicate -fnoninteractive live-initramfs >/dev/null; then
chroot "$1" debconf-communicate -fnoninteractive live-initramfs >/dev/null <<EOF
REGISTER debian-installer/dummy $question
SET $question $value
FSET $question seen $seen
Expand Down
File renamed without changes.
20 changes: 10 additions & 10 deletions bin/casper-snapshot → bin/live-snapshot
Expand Up @@ -29,9 +29,9 @@ PROGRAM="`basename $0`"
VERSION=0.0.1


# Source casper conf
if [ -e /etc/casper.conf ]; then
. /etc/casper.conf
# Source live conf
if [ -e /etc/live.conf ]; then
. /etc/live.conf
else
USERNAME=$(cat /etc/passwd | grep "999" | cut -f1 -d ':')
HOSTNAME=$(hostname)
Expand All @@ -41,7 +41,7 @@ fi
export USERNAME USERFULLNAME HOSTNAME BUILD_SYSTEM

# Source helper functions
helpers="/usr/share/initramfs-tools/scripts/casper-helpers"
helpers="/usr/share/initramfs-tools/scripts/live-helpers"
if [ -e "${helpers}" ]; then
. "${helpers}"
else
Expand Down Expand Up @@ -95,7 +95,7 @@ Help ()
echo " -o, --output: specifies the output image file (default: $type dependent)."
echo " -r, --resync-string: internally used to resync previous made snapshots."
echo " -t, --type: specifies the snapshot type between \"squashfs\", \"ext2\" or \"cpio\".gz archive (default: cpio)"
echo -e "\nLook at casper-snapshot(1) man page for more information."
echo -e "\nLook at live-snapshot(1) man page for more information."
exit 0
}

Expand Down Expand Up @@ -211,8 +211,8 @@ Mount_device ()
if [ -z "${dev}" ]; then
# create a temp
mount -t tmpfs -o rw tmpfs "${MOUNTP}"
if [ ! -L /home/$USERNAME/Desktop/casper-snapshot ]; then
ln -s "${MOUNTP}" /home/$USERNAME/Desktop/casper-snapshot
if [ ! -L /home/$USERNAME/Desktop/live-snapshot ]; then
ln -s "${MOUNTP}" /home/$USERNAME/Desktop/live-snapshot
fi
else
if [ -b "${dev}" ] ; then
Expand All @@ -223,12 +223,12 @@ Mount_device ()

Defaults ()
{
MOUNTP="/mnt/casper-snapshot"
MOUNTP="/mnt/live-snapshot"
COW="/cow"
DEV=""
DEST="${MOUNTP}/casper-sn.cpio.gz"
DEST="${MOUNTP}/live-sn.cpio.gz"
TYPE="cpio"
DESKTOP_LINK=/home/$USERNAME/Desktop/casper-snapshot
DESKTOP_LINK=/home/$USERNAME/Desktop/live-snapshot

if [ -n "${SNAP_RSTRING}" ]; then
COW=$(echo "${SNAP_RSTRING}" | cut -f1 -d ':')
Expand Down
8 changes: 0 additions & 8 deletions casper.conf

This file was deleted.

30 changes: 0 additions & 30 deletions caspermon/GNOME_PythonAppletCasper.server

This file was deleted.

75 changes: 0 additions & 75 deletions caspermon/caspermon-applet

This file was deleted.

9 changes: 0 additions & 9 deletions caspermon/caspermond

This file was deleted.

9 changes: 9 additions & 0 deletions conf/live.conf
@@ -0,0 +1,9 @@
# /etc/live.conf: configuration file for live-initramfs

BUILD_SYSTEM="Debian"

USERNAME="user"
USERFULLNAME="Live session user"
HOST="debian"

export BUILD_SYSTEM USERNAME USERFULLNAME HOST
6 changes: 6 additions & 0 deletions debian/changelog
@@ -1,3 +1,9 @@
live-initramfs (1.87.2-1) unstable; urgency=low

* New upstream release.

-- Daniel Baumann <daniel@debian.org> Mon, 7 May 2007 00:00:00 +0200

live-initramfs (1.87.1-1) unstable; urgency=low

* Initial release, forking casper.
Expand Down
2 changes: 1 addition & 1 deletion debian/copyright
Expand Up @@ -36,7 +36,7 @@ License:
On Debian systems, the complete text of the GNU General Public License
can be found in /usr/share/common-licenses/GPL file.

License (casper-md5check/md5.c, casper-md5check/md5,h):
License (live-md5check/md5.c, live-md5check/md5,h):

Copyright (C) 1999-2002 Aladdin Enterprises
All rights reserved.
Expand Down
2 changes: 1 addition & 1 deletion debian/dirs
@@ -1,4 +1,4 @@
/etc
/usr/lib/casper
/usr/lib/live-initramfs
/usr/share/initramfs-tools/hooks
/usr/share/initramfs-tools/scripts
2 changes: 1 addition & 1 deletion debian/examples
@@ -1 +1 @@
casper.conf
conf/live.conf
12 changes: 6 additions & 6 deletions debian/init
@@ -1,6 +1,6 @@
#! /bin/sh
### BEGIN INIT INFO
# Provides: casper
# Provides: live-initramfs
# Required-Start: $syslog
# Required-Stop: $syslog
# Should-Start: $local_fs
Expand All @@ -16,15 +16,15 @@
# Marco Amadori <marco.amadori@gmail.com>
#
PATH=/usr/sbin:/usr/bin:/sbin:/bin
NAME=casper
NAME=live-initramfs
SCRIPTNAME=/etc/init.d/${NAME}
DO_SNAPSHOT=/sbin/${NAME}-snapshot
DO_SNAPSHOT=/sbin/live-snapshot

# Exit if system was not booted by casper
grep -qs boot=casper /proc/cmdline || exit 0
# Exit if system was not booted by live-initramfs
grep -qs boot=live /proc/cmdline || exit 0

# Read configuration variable file if it is present
[ -r /etc/$NAME.conf ] && . /etc/$NAME.conf
[ -r /etc/live.conf ] && . /etc/live.conf

# Load the VERBOSE setting and other rcS variables
[ -f /etc/default/rcS ] && . /etc/default/rcS
Expand Down
10 changes: 5 additions & 5 deletions debian/install
@@ -1,7 +1,7 @@
bin/casper-getty sbin
bin/casper-login sbin
bin/casper-preseed usr/share/casper
bin/casper-reconfigure usr/share/casper
bin/casper-snapshot sbin
bin/live-getty sbin
bin/live-login sbin
bin/live-preseed usr/share/live-initramfs
bin/live-reconfigure usr/share/live-initramfs
bin/live-snapshot sbin
hooks usr/share/initramfs-tools
scripts usr/share/initramfs-tools
4 changes: 2 additions & 2 deletions debian/links
@@ -1,2 +1,2 @@
/usr/share/man/man7/casper.7.gz /usr/share/man/man7/casper-getty.7.gz
/usr/share/man/man7/casper.7.gz /usr/share/man/man7/casper-login.7.gz
/usr/share/man/man7/casper.7.gz /usr/share/man/man7/live-getty.7.gz
/usr/share/man/man7/casper.7.gz /usr/share/man/man7/live-login.7.gz
2 changes: 1 addition & 1 deletion debian/manpages
@@ -1 +1 @@
debian/manpage/*
manpages/*
13 changes: 7 additions & 6 deletions debian/rules
Expand Up @@ -24,16 +24,16 @@ build-stamp:
dh_testdir

# Checking scripts
for SCRIPT in bin/* scripts/casper scripts/casper-bottom/*; \
for SCRIPT in scripts/live scripts/live-bottom/*; \
do \
sh -n $$SCRIPT || exit 1; \
done

# Setting BUILD_SYSTEM in the binary package
sed -i -e 's/\(BUILD_SYSTEM="\).*"/\1'$(BUILD_SYSTEM)'"/g' casper.conf
sed -e 's/\(BUILD_SYSTEM="\).*"/\1'$(BUILD_SYSTEM)'"/g' conf/live.conf > live.conf

# Building package
CFLAGS="$(CFLAGS)" $(MAKE) -C casper-md5check
CFLAGS="$(CFLAGS)" $(MAKE) -C bin/live-md5check

touch build-stamp

Expand All @@ -43,7 +43,8 @@ clean:
rm -f build-stamp

# Cleaning package
$(MAKE) -C casper-md5check clean
$(MAKE) -C bin/live-md5check clean
rm -f live.conf

dh_clean

Expand All @@ -54,8 +55,8 @@ install: build
dh_installdirs

# Installing package
install -m 0755 casper-md5check/casper-md5check debian/live-initramfs/usr/lib/casper
install -m 0644 casper.conf debian/live-initramfs/etc/casper.conf
install -m 0755 bin/live-md5check/live-md5check debian/live-initramfs/usr/lib/live-initramfs
install -m 0644 live.conf debian/live-initramfs/etc/live.conf

binary-indep: build install

Expand Down

0 comments on commit 292e65d

Please sign in to comment.