[Lunar-commits] CVS: moonbase/kernel/linux-2.6 BUILD, NONE,
1.1 BUILD.alpha, NONE, 1.1 CONFIGURE, NONE, 1.1 DEPENDS, NONE,
1.1 DETAILS, NONE, 1.1 POST_INSTALL, NONE, 1.1 PRE_BUILD, NONE, 1.1
Moritz Heiber
moe at lunar-linux.org
Tue Oct 19 08:15:34 UTC 2004
Update of /var/cvs/lunar/moonbase/kernel/linux-2.6
In directory espresso.foo-projects.org:/tmp/cvs-serv693/linux-2.6
Added Files:
BUILD BUILD.alpha CONFIGURE DEPENDS DETAILS POST_INSTALL
PRE_BUILD
Log Message:
Woohoo .. here we go for linux-2.6. Note: This module is a bit
different from the usual module structure (so this is not just
cp -R linux-beta linux-2.6). I've tested it carefully though
and I hope it works as good for you as it works for you. Enjoy!
--- NEW FILE: BUILD ---
cd $BUILD_DIRECTORY/linux
while
case $CONFIG_KERNEL in
y|Y)
case $CONFIG_METHOD in
xconfig )
if [ "$DISPLAY" ]; then
make xconfig || make menuconfig || make config
else
make menuconfig || make config
fi
;;
menuconfig )
make menuconfig || make config ;;
config )
make config ;;
esac
if query "Repeat $CONFIG_METHOD? " n ; then
CONFIG_KERNEL=y
else
CONFIG_KERNEL=n
fi
;;
*)
false ;;
esac
do
true
done
(
yes n | make oldconfig
cp .config $CONFIG_CACHE/.config.2.6.stable
rm -f arch/i386/boot/bzImage
# Because parallel make seems not to work, a hack
optimize_make &&
KMAKES=${MAKES:=1} &&
make -j${KMAKES} bzImage &&
make -j${KMAKES} modules &&
backup_mods_krnl linux-${VERSION} &&
prepare_install &&
make modules_install
cp arch/i386/boot/bzImage /boot/linux-${VERSION}
cp System.map /boot/System.map-${VERSION}
) > $C_FIFO 2>&1
--- NEW FILE: BUILD.alpha ---
cd $BUILD_DIRECTORY/linux
while
case $CONFIG_KERNEL in
y|Y)
case $CONFIG_METHOD in
xconfig )
if [ "$DISPLAY" ]; then
make xconfig || make menuconfig || make config
else
make menuconfig || make config
fi
;;
menuconfig )
make menuconfig || make config ;;
config )
make config ;;
esac
if query "Repeat $CONFIG_METHOD? " n ; then
CONFIG_KERNEL=y
else
CONFIG_KERNEL=n
fi
;;
*)
false ;;
esac
do
true
done
(
yes n | make oldconfig
cp .config $CONFIG_CACHE/.config.2.6.stable
rm -f arch/alpha/boot/vmlinux.gz
# Because parallel make seems not to work, a hack
optimize_make &&
KMAKES=${MAKES:=1} &&
make -j${KMAKES} boot &&
make -j${KMAKES} modules &&
backup_mods_krnl linux-${VERSION} &&
prepare_install &&
make modules_install
cp arch/alpha/boot/vmlinux.gz /boot/linux-${VERSION}
) > $C_FIFO 2>&1
--- NEW FILE: CONFIGURE ---
if ! grep -q "BOOT_LOADER" $MODULE_CONFIG; then
# message "The Linux Kernel requires a boot loader"
message "Choose either GRUB or LILO"
# BOOT_LOADER=lilo
if query "Use LILO?" y ; then
BOOT_LOADER=lilo
else
BOOT_LOADER=grub
fi
echo "BOOT_LOADER=$BOOT_LOADER" >> $MODULE_CONFIG
fi
CONFIG_GRUB="n"
CONFIG_LILO="n"
if grep -q "BOOT_LOADER=grub" $MODULE_CONFIG && query "Configure grub?" n ; then
CONFIG_GRUB=y
fi
if grep -q "BOOT_LOADER=lilo" $MODULE_CONFIG && query "Configure lilo?" n ; then
CONFIG_LILO=y
fi
if ! grep -q "CONFIG_METHOD=" $MODULE_CONFIG ; then
if query "Do you prefer make menuconfig over make config" y ; then
CONFIG_METHOD="menuconfig"
else
CONFIG_METHOD="config"
fi
echo "CONFIG_METHOD=$CONFIG_METHOD" >> $MODULE_CONFIG
fi
if [ ! -f $CONFIG_CACHE/.config.beta ] && [ ! -f $CONFIG_CACHE/.config ]; then
message "Preparing to make menuconfig."
CONFIG_KERNEL="y"
else
message "Reconfiguration is optional."
if query "Configure linux kernel?" n ; then
CONFIG_KERNEL=y
else
CONFIG_KERNEL=n
fi
fi
TEMP=`grep -v "CONFIG_KERNEL=" $MODULE_CONFIG |
grep -v "CONFIG_LILO=" |
grep -v "CONFIG_GRUB="`
echo "$TEMP" > $MODULE_CONFIG
echo "CONFIG_KERNEL=$CONFIG_KERNEL" >> $MODULE_CONFIG
echo "CONFIG_LILO=$CONFIG_LILO" >> $MODULE_CONFIG
echo "CONFIG_GRUB=$CONFIG_GRUB" >> $MODULE_CONFIG
--- NEW FILE: DEPENDS ---
depends autoconf &&
depends module-init-tools
--- NEW FILE: DETAILS ---
MODULE=linux-2.6
VERSION=2.6.9
SOURCE=linux-${VERSION}.tar.bz2
SOURCE_URL[0]=$KERNEL_URL/pub/linux/kernel/v2.6/
SOURCE_URL[1]=http://www.kernel.org/pub/linux/kernel/v2.6/
SOURCE_VFY=sha1:dd8f8b0c43b83339a42246d322cb48c6f2323236
WEB_SITE=http://www.kernel.org
ENTERED=20041019
UPDATED=20041019
SHORT="The Linux kernel is the core of a Linux GNU Operating System."
cat << EOF
This is the stable version of the 2.6.x branch.
Linux is a clone of the Unix kernel, written from scratch by Linus
Torvalds with assistance from a loosely-knit team of hackers across the
Net. It aims towards POSIX and Single UNIX Specification compliance. It
has all the features you would expect in a modern fully-fledged Unix
kernel, including true multitasking, virtual memory, shared libraries,
demand loading, shared copy-on-write executables, proper memory
management, and TCP/IP networking.
EOF
--- NEW FILE: POST_INSTALL ---
# Done to shorten the boot label for lilo
LABEL=`echo ${VERSION} | sed 's/-//g'`
case $BOOT_LOADER in
lilo) update_lilo linux-${VERSION} ${LABEL} ;;
grub) update_grub linux-${VERSION} ${LABEL} ;;
aboot) update_aboot linux-${VERSION} ${LABEL} ;;
esac
# Reinstall packages that add their own kernel modules
lin -c kernel-reqs
--- NEW FILE: PRE_BUILD ---
cd $BUILD_DIRECTORY
if [ ! -d linux-${VERSION} ]; then
rm -rf linux-${VERSION}
rm -rf linux
unpack $SOURCE
ln -sf linux-${VERSION} linux
chown root.root $BUILD_DIRECTORY/linux
chown -R root.root $BUILD_DIRECTORY/linux-${VERSION}
cd linux/
if [ -f $CONFIG_CACHE/.config.2.6.stable ]; then
cp $CONFIG_CACHE/.config.2.6.stable $BUILD_DIRECTORY/linux/.config;
elif [ -f $CONFIG_CACHE/.config.beta ]; then
cp $CONFIG_CACHE/.config.beta $BUILD_DIRECTORY/linux/.config;
fi
else
message "Sources found: $BUILD_DIRECTORY/linux-${VERSION}"
if [ "`readlink linux`" != "linux-${VERSION}" ]; then
rm -rf linux
ln -s linux-${VERSION} linux
fi
fi
More information about the Lunar-commits
mailing list