-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathkernel
More file actions
28 lines (23 loc) · 757 Bytes
/
kernel
File metadata and controls
28 lines (23 loc) · 757 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
function kernel-build
{
arch=$1
if [[ "$arch" == "x86" || "$arch" == "i386" || "$arch" == "32-bit" ]] ; then
flags="ARCH=i386"
fi
echo "+make ${flags} bzImage modules"
make ${flags} bzImage modules
}
function kernel-install
{
target=$1
arch=$2
if [ -z "$target" ] ; then
echo "usage: kernel-install path/to/installation [arch]"
echo " arch is optional flag, i386 is an example"
fi
if [[ "$arch" == "x86" || "$arch" == "i386" || "$arch" == "32-bit" ]] ; then
flags="ARCH=i386"
fi
echo "+make ${flags} INSTALL_PATH=${target}/boot INSTALL_MOD_PATH=${target} install modules_install"
make INSTALL_PATH=${target}/boot INSTALL_MOD_PATH=${target} install modules_install
}