forked from lorenzo-stoakes/kernel-scripts
-
Notifications
You must be signed in to change notification settings - Fork 0
/
kerndev-defaults.sh
executable file
·68 lines (60 loc) · 2.53 KB
/
kerndev-defaults.sh
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
#!/bin/bash
set -e; set -o pipefail
# This script is source'd by kerndev-shared.sh and contains config variables
# that can be set when running kerndev- scripts along with default values where
# appropriate.
debian_mirror_default=http://mirror.positive-internet.com/debian
debian_packages_default="netbase,ifupdown,net-tools,dhcpcd5,iproute,wget,sudo,\
zsh,curl,ca-certificates,man-db,git,pciutils,usbutils,iputils-ping,less,nano,\
kmod"
debian_version_default=jessie
image_size_default=30G
kerndev_path_default=$HOME/kerndev/qemu-images
# If we are in what looks like a kernel directory, then assume this is where we
# want to run.
if [[ "$PWD" =~ "$HOME/kerndev/kernels/" ]] || is_linux_dir $PWD; then
linux_dev_path_default=$PWD
else
linux_dev_path_default=$HOME/kerndev/kernels/linux
fi
qemu_cores_default=4
qemu_ram_default=8G
# Configuration options with default values:-
# DEBIAN_ options are used for the aarch64 build as Arch doesn't yet have an
# aarch64 build :(
DEBIAN_MIRROR=${DEBIAN_MIRROR:-$debian_mirror_default}
DEBIAN_PACKAGES=${DEBIAN_PACKAGES:-$debian_packages_default}
DEBIAN_VERSION=${DEBIAN_VERSION:-$debian_version_default}
# Size of image created by kerndev-create.
IMAGE_SIZE=${IMAGE_SIZE:-$image_size_default}
# Location to store image files in.
KERNDEV_PATH=${KERNDEV_PATH:-$kerndev_path_default}
# Location containing the kernel source code.
LINUX_DEV_PATH=${LINUX_DEV_PATH:-$linux_dev_path_default}
# QEMU settings.
QEMU_CORES=${QEMU_CORES:-$qemu_cores_default}
QEMU_RAM=${QEMU_RAM:-$qemu_ram_default}
# Configuration options which default to being unset, included here for
# documentation:-
# If set, run a chroot script in the development image.
ACCESS_CHROOT=${ACCESS_CHROOT:-}
# kerndev-build: If set, don't run kerndev-install after building.
DONT_INSTALL=${DONT_INSTALL:-}
# If set, enable gcov configuration settings, and copy kernel source into image.
ENABLE_GCOV=${ENABLE_GCOV:-}
# If set, enable kernel support for docker.
ENABLE_DOCKER_SUPPORT=${ENABLE_DOCKER_SUPPORT:-}
# If set, do not say 'Done!' when done :)
NO_DONE=${NO_DONE:-}
# Custom qemu settings, e.g. a USB device pass-through like
# '-usbdevice host:3.5'.
QEMU_CUSTOM_SETTINGS=${QEMU_CUSTOM_SETTINGS:-}
# kerndev-build: If set, forces rebuild.
REBUILD=${REBUILD:-}
# Set to define a root password, otherwise prompts for one on kerndev-create.
ROOT_PASSWORD=${ROOT_PASSWORD:-}
# If set, uses existing rootfs image on kerndev-create rather than creating a
# new one.
USE_EXISTING_IMAGE=${USE_EXISTING_IMAGE:-}
# If set, output from make is not silenced.
VERBOSE=${VERBOSE:-}