Subversion Repositories livecd

Rev

Rev 16 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 16 Rev 23
Line 8... Line 8...
8
# - add support to build for UP and SMP kernel
8
# - add support to build for UP and SMP kernel
9
#   SMP kernel is added to LiveCD, if variable $SMP is set
9
#   SMP kernel is added to LiveCD, if variable $SMP is set
10
# - copy System.map-* and config-* to CDDATA/boot
10
# - copy System.map-* and config-* to CDDATA/boot
11
#   and copy /boot/grub/splash.xpm.gz to CDDATA/boot/grub
11
#   and copy /boot/grub/splash.xpm.gz to CDDATA/boot/grub
12
#   both needed for install LiveCD in local harddisk
12
#   both needed for install LiveCD in local harddisk
-
 
13
# - config no longer sourced, we take ../livecd.conf
13
#
14
#
14
 
15
 
15
export LANG=C
16
export LANG=C
16
 
17
 
17
ARCH=$( /bin/arch )
18
ARCH=$( /bin/arch )
Line 23... Line 24...
23
CHANGEDIR="`dirname \`readlink -f $0\``"
24
CHANGEDIR="`dirname \`readlink -f $0\``"
24
echo "Changing current directory to $CHANGEDIR"
25
echo "Changing current directory to $CHANGEDIR"
25
cd $CHANGEDIR
26
cd $CHANGEDIR
26
 
27
 
27
. liblinuxlive || exit 1
28
. liblinuxlive || exit 1
28
. config || exit 1
29
# . config || exit 1
-
 
30
. ../livecd.conf || exit 1
29
 
31
 
30
./install $ROOT
32
./install $ROOT
31
 
33
 
32
VMLINUZ=$ROOT/boot/vmlinuz
34
VMLINUZ=$ROOT/boot/vmlinuz
33
if [ -L "$VMLINUZ" ]; then VMLINUZ=`readlink -f $VMLINUZ`; fi
35
if [ -L "$VMLINUZ" ]; then VMLINUZ=`readlink -f $VMLINUZ`; fi
Line 84... Line 86...
84
 
86
 
85
echo "creating initrd image..."
87
echo "creating initrd image..."
86
 
88
 
87
for BUILD_KERNEL in $BUILD_KERNELS; do
89
for BUILD_KERNEL in $BUILD_KERNELS; do
88
 
90
 
89
    echo "add kernel $BUILD_KERNEL"
-
 
90
    # Set KERNEL=$BUILD_KERNEL in config
-
 
91
    sed -i "s|^KERNEL=.*|KERNEL=$BUILD_KERNEL|" config
-
 
92
 
-
 
93
    cd initrd
91
    cd initrd
94
    ./initrd_create
92
    ./initrd_create $BUILD_KERNEL
95
    if [ "$?" -ne 0 ]; then exit; fi
93
    if [ "$?" -ne 0 ]; then exit; fi
96
    cd ..
94
    cd ..
97
 
-
 
98
    if [ "$BUILD_KERNEL" = "$KERNEL" ]; then
95
    if [ "$BUILD_KERNEL" = "$KERNEL" ]; then
-
 
96
	echo "add initrd.gz for kernel $BUILD_KERNEL"
99
	cp initrd/$INITRDIMG.gz $CDDATA/boot/initrd.gz        # UP Kernel
97
	cp initrd/$INITRDIMG.gz $CDDATA/boot/initrd.gz        # UP Kernel
100
    else
98
    else
-
 
99
	echo "add initrd${SMP}.gz for kernel $BUILD_KERNEL"
101
	cp initrd/$INITRDIMG.gz $CDDATA/boot/initrd${SMP}.gz  # SMP Kernel
100
	cp initrd/$INITRDIMG.gz $CDDATA/boot/initrd${SMP}.gz  # SMP Kernel
102
    fi
101
    fi
103
    rm initrd/$INITRDIMG.gz
102
    rm initrd/$INITRDIMG.gz
104
 
103
 
105
done
104
done