tkernel - libdevuansdk - common library for devuan's simple distro kits
HTML git clone https://git.parazyd.org/libdevuansdk
DIR Log
DIR Files
DIR Refs
DIR Submodules
DIR README
DIR LICENSE
---
tkernel (1274B)
---
1 #!/usr/bin/env zsh
2 # Copyright (c) 2016-2017 Dyne.org Foundation
3 # libdevuansdk is maintained by Ivan J. <parazyd@dyne.org>
4 #
5 # This file is part of libdevuansdk
6 #
7 # This source code is free software: you can redistribute it and/or modify
8 # it under the terms of the GNU General Public License as published by
9 # the Free Software Foundation, either version 3 of the License, or
10 # (at your option) any later version.
11 #
12 # This software is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 # GNU General Public License for more details.
16 #
17 # You should have received a copy of the GNU General Public License
18 # along with this source code. If not, see <http://www.gnu.org/licenses/>.
19
20 ## all windows users are suckers
21
22 build_kernel_${arch}() {
23 fn build_kernel_${arch}
24 req=(strapdir arch)
25 ckreq || return 1
26
27 local kernel_base="linux-image"
28 case "$arch" in
29 amd64) local kernel="${kernel_base}-amd64";;
30 i386) local kernel="${kernel_base}-586";;
31 esac
32
33 notice "installing stock kernel for $arch"
34
35 cat <<EOF | sudo tee ${strapdir}/install-linux
36 #!/bin/sh
37 apt-get --yes --force-yes install ${kernel}
38 EOF
39 chroot-script -d install-linux || zerr
40 }