aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'targets/netboot')
-rwxr-xr-xtargets/netboot/netboot-chroot.sh20
-rwxr-xr-xtargets/netboot/netboot-controller.sh75
2 files changed, 95 insertions, 0 deletions
diff --git a/targets/netboot/netboot-chroot.sh b/targets/netboot/netboot-chroot.sh
new file mode 100755
index 00000000..5ab595a9
--- /dev/null
+++ b/targets/netboot/netboot-chroot.sh
@@ -0,0 +1,20 @@
+#!/bin/bash
+# Copyright 1999-2004 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo/src/catalyst/targets/netboot/netboot-chroot.sh,v 1.1 2005/04/04 17:50:30 rocket Exp $
+. /tmp/chroot-functions.sh
+
+update_env_settings
+
+check_portage_version
+setup_myfeatures
+setup_myemergeopts
+
+# setup our environment
+export FEATURES="${clst_myfeatures}"
+export CONFIG_PROTECT="-*"
+export USE_ORDER="env:pkg:conf:defaults"
+
+# START BUILD
+
+run_emerge ${clst_myemergeopts} ${clst_packages}
diff --git a/targets/netboot/netboot-controller.sh b/targets/netboot/netboot-controller.sh
new file mode 100755
index 00000000..ea6ef36b
--- /dev/null
+++ b/targets/netboot/netboot-controller.sh
@@ -0,0 +1,75 @@
+#!/bin/bash
+# Copyright 1999-2004 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo/src/catalyst/targets/netboot/netboot-controller.sh,v 1.1 2005/04/04 17:50:30 rocket Exp $
+. ${clst_sharedir}/targets/support/functions.sh
+. ${clst_sharedir}/targets/support/filesystem-functions.sh
+
+
+case ${1} in
+
+ #### Couldnt busybox step be in packages ....
+
+ build_packages)
+ shift
+ clst_root_path="/" \
+ clst_packages="$*" \
+ exec_in_chroot ${clst_sharedir}/targets/${clst_target}/${clst_target}-chroot.sh
+ ;;
+
+ busybox)
+ # Custom busybox config support
+ if [ -f "${clst_netboot_busybox_config}" ]
+ then
+ mkdir -p ${clst_chroot_path}/etc/busybox/${clst_CHOST}
+ cp -v ${clst_netboot_busybox_config} ${clst_chroot_path}/etc/busybox/${clst_CHOST}/busybox.config
+ clst_netboot_use="savedconfig"
+ fi
+
+ # Main Busybox emerge
+ clst_root_path="/" \
+ clst_netboot_use="${clst_netboot_use} netboot" \
+ clst_myemergeopts="${clst_myemergeopts} -O" \
+ clst_packages="busybox" \
+ exec_in_chroot ${clst_sharedir}/targets/${clst_target}/${clst_target}-chroot.sh
+ ;;
+
+ kernel)
+ shift
+ export clst_kname="$1"
+ export clst_root_path="/"
+ #exec_in_chroot ${clst_sharedir}/targets/support/pre-kmerge.sh
+ #exec_in_chroot ${clst_sharedir}/targets/support/kmerge.sh
+ #exec_in_chroot ${clst_sharedir}/targets/support/post-kmerge.sh
+ #extract_kernels kernels
+
+ ;;
+
+ image)
+ #Creates the base initrd image for the netboot
+
+ shift
+
+ # Could this step be a parameter in case there is a different baselayout to add???
+ clst_myemergeopts="${clst_myemergeopts} --nodeps" \
+ clst_packages="netboot-base" \
+ exec_in_chroot ${clst_sharedir}/targets/${clst_target}/${clst_target}-chroot.sh
+
+ clst_files="${@}" \
+ exec_in_chroot ${clst_sharedir}/targets/${clst_target}/${clst_target}-image.sh
+ ;;
+
+ finish)
+
+
+
+ ${clst_sharedir}/targets/${clst_target}/${clst_target}-combine.sh
+ ;;
+
+ clean)
+ exit 0;;
+ *)
+ exit 1;;
+esac
+
+exit 0