##// END OF EJS Templates
Merge pull request #3 from drtyhlpr/master...
burnbabyburn -
r329:02f0baa56ac1 Fusion
parent child
Show More
@@ -176,7 +176,7 Install and enable OpenSSH service. The default configuration of the service doe
176 176 Allow the installation of non-free Debian packages that do not comply with the DFSG. This is required to install closed-source firmware binary blobs.
177 177
178 178 ##### `ENABLE_WIRELESS`=false
179 Download and install the [closed-source firmware binary blob](https://github.com/RPi-Distro/firmware-nonfree/tree/master/brcm80211/brcm) that is required to run the internal wireless interface of the Raspberry Pi model `3`. This parameter is ignored if the specified `RPI_MODEL` is not `3`.
179 Download and install the [closed-source firmware binary blob](https://github.com/RPi-Distro/firmware-nonfree/raw/master/brcm) that is required to run the internal wireless interface of the Raspberry Pi model `3`. This parameter is ignored if the specified `RPI_MODEL` is not `3`.
180 180
181 181 ##### `ENABLE_RSYSLOG`=true
182 182 If set to false, disable and uninstall rsyslog (so logs will be available only
@@ -200,6 +200,9 Install Xorg open-source X Window System.
200 200 ##### `ENABLE_WM`=""
201 201 Install a user defined window manager for the X Window System. To make sure all X related package dependencies are getting installed `ENABLE_XORG` will automatically get enabled if `ENABLE_WM` is used. The `rpi23-gen-image.sh` script has been tested with the following list of window managers: `blackbox`, `openbox`, `fluxbox`, `jwm`, `dwm`, `xfce4`, `awesome`.
202 202
203 ##### `ENABLE_SYSVINIT`=false
204 Support for halt,init,poweroff,reboot,runlevel,shutdown,telinit commands
205
203 206 ---
204 207
205 208 #### Advanced system features:
@@ -7,7 +7,6
7 7
8 8 VARIANT=""
9 9 COMPONENTS="main"
10 EXCLUDES=""
11 10
12 11 # Use non-free Debian packages if needed
13 12 if [ "$ENABLE_NONFREE" = true ] ; then
@@ -19,13 +18,8 if [ "$ENABLE_MINBASE" = true ] ; then
19 18 VARIANT="--variant=minbase"
20 19 fi
21 20
22 # Exclude packages if required by Debian release
23 if [ "$RELEASE" = "stretch" ] || [ "$RELEASE" = "buster" ] ; then
24 EXCLUDES="--exclude=init,systemd-sysv"
25 fi
26
27 21 # Base debootstrap (unpack only)
28 http_proxy=${APT_PROXY} debootstrap ${EXCLUDES} --arch="${RELEASE_ARCH}" --foreign ${VARIANT} --components="${COMPONENTS}" --include="${APT_INCLUDES}" "${RELEASE}" "${R}" "http://${APT_SERVER}/debian"
22 http_proxy=${APT_PROXY} debootstrap ${APT_EXCLUDES} --arch="${RELEASE_ARCH}" --foreign ${VARIANT} --components="${COMPONENTS}" --include="${APT_INCLUDES}" "${RELEASE}" "${R}" "http://${APT_SERVER}/debian"
29 23
30 24 # Copy qemu emulator binary to chroot
31 25 install -m 755 -o root -g root "${QEMU_BINARY}" "${R}${QEMU_BINARY}"
@@ -28,10 +28,10 if [ $(echo "$APT_INCLUDES" | grep ",locales") ] ; then
28 28 chroot_exec update-locale LANG="${DEFLOCAL}"
29 29
30 30 # Install and setup default keyboard configuration
31 if [ "$XKB_MODEL" != "" ] ; then
31 if [ "$XKB_MODEL" != "pc105" ] ; then
32 32 sed -i "s/^XKBMODEL.*/XKBMODEL=\"${XKB_MODEL}\"/" "${ETC_DIR}/default/keyboard"
33 33 fi
34 if [ "$XKB_LAYOUT" != "" ] ; then
34 if [ "$XKB_LAYOUT" != "us" ] ; then
35 35 sed -i "s/^XKBLAYOUT.*/XKBLAYOUT=\"${XKB_LAYOUT}\"/" "${ETC_DIR}/default/keyboard"
36 36 fi
37 37 if [ "$XKB_VARIANT" != "" ] ; then
@@ -95,7 +95,7 if [ "$ENABLE_INITRAMFS" = true ] ; then
95 95 fi
96 96
97 97 # Disable RPi3 Bluetooth and restore ttyAMA0 serial device
98 if [ "$RPI_MODEL" = 3 ] || [ "$RPI_MODEL" = 3P ]; then
98 if [ "$RPI_MODEL" = 3 ] || [ "$RPI_MODEL" = 3P ] ; then
99 99 if [ "$ENABLE_CONSOLE" = true ] && [ "$ENABLE_UBOOT" = false ] ; then
100 100 echo "dtoverlay=pi3-disable-bt" >> "${BOOT_DIR}/config.txt"
101 101 echo "enable_uart=1" >> "${BOOT_DIR}/config.txt"
@@ -107,7 +107,7 if [ "$ENABLE_WIRELESS" = true ] ; then
107 107 as_nobody wget -q -O "${temp_dir}/brcmfmac43455-sdio.bin" "${WLAN_FIRMWARE_URL}/brcmfmac43455-sdio.bin"
108 108 as_nobody wget -q -O "${temp_dir}/brcmfmac43455-sdio.txt" "${WLAN_FIRMWARE_URL}/brcmfmac43455-sdio.txt"
109 109 as_nobody wget -q -O "${temp_dir}/brcmfmac43455-sdio.clm_blob" "${WLAN_FIRMWARE_URL}/brcmfmac43455-sdio.clm_blob"
110 else
110 elif [ "$RPI_MODEL" = 3 ] || [ "$RPI_MODEL" = 0 ] ; then
111 111 # Fetch firmware binary blob for RPI3
112 112 as_nobody wget -q -O "${temp_dir}/brcmfmac43430-sdio.bin" "${WLAN_FIRMWARE_URL}/brcmfmac43430-sdio.bin"
113 113 as_nobody wget -q -O "${temp_dir}/brcmfmac43430-sdio.txt" "${WLAN_FIRMWARE_URL}/brcmfmac43430-sdio.txt"
@@ -116,7 +116,7 if [ "$ENABLE_WIRELESS" = true ] ; then
116 116 # Move downloaded firmware binary blob
117 117 if [ "$RPI_MODEL" = 3P ] ; then
118 118 mv "${temp_dir}/brcmfmac43455-sdio."* "${WLAN_FIRMWARE_DIR}/"
119 else
119 elif [ "$RPI_MODEL" = 3 ] || [ "$RPI_MODEL" = 0 ] ; then
120 120 mv "${temp_dir}/brcmfmac43430-sdio."* "${WLAN_FIRMWARE_DIR}/"
121 121 fi
122 122
@@ -127,7 +127,7 if [ "$ENABLE_WIRELESS" = true ] ; then
127 127 if [ "$RPI_MODEL" = 3P ] ; then
128 128 chown root:root "${WLAN_FIRMWARE_DIR}/brcmfmac43455-sdio."*
129 129 chmod 600 "${WLAN_FIRMWARE_DIR}/brcmfmac43455-sdio."*
130 else
130 elif [ "$RPI_MODEL" = 3 ] || [ "$RPI_MODEL" = 0 ] ; then
131 131 chown root:root "${WLAN_FIRMWARE_DIR}/brcmfmac43430-sdio."*
132 132 chmod 600 "${WLAN_FIRMWARE_DIR}/brcmfmac43430-sdio."*
133 133 fi
@@ -10,9 +10,9 if [ "$ENABLE_IPTABLES" = true ] ; then
10 10 mkdir -p "${ETC_DIR}/iptables"
11 11
12 12 # make sure iptables-legacy,iptables-legacy-restore and iptables-legacy-save are the used alternatives
13 chroot_exec update-alternatives --verbose --set iptables /usr/bin/iptables-legacy
14 chroot_exec update-alternatives --verbose --set iptables-save /usr/bin/iptables-legacy-save
15 chroot_exec update-alternatives --verbose --set iptables-restore /usr/bin/iptables-legacy-restore
13 chroot_exec update-alternatives --verbose --set iptables /usr/sbin/iptables-legacy
14 chroot_exec update-alternatives --verbose --set iptables-save /usr/sbin/iptables-legacy-save
15 chroot_exec update-alternatives --verbose --set iptables-restore /usr/sbin/iptables-legacy-restore
16 16
17 17 # Install iptables systemd service
18 18 install_readonly files/iptables/iptables.service "${ETC_DIR}/systemd/system/iptables.service"
@@ -176,6 +176,7 ENABLE_USER=${ENABLE_USER:=true}
176 176 USER_NAME=${USER_NAME:="pi"}
177 177 ENABLE_ROOT=${ENABLE_ROOT:=false}
178 178 ENABLE_QEMU=${ENABLE_QEMU:=false}
179 ENABLE_SYSVINIT=${ENABLE_SYSVINIT:=false}
179 180
180 181 # SSH settings
181 182 SSH_ENABLE_ROOT=${SSH_ENABLE_ROOT:=false}
@@ -244,6 +245,9 CHROOT_SCRIPTS=${CHROOT_SCRIPTS:=""}
244 245 APT_INCLUDES=${APT_INCLUDES:=""}
245 246 APT_INCLUDES="${APT_INCLUDES},apt-transport-https,apt-utils,ca-certificates,debian-archive-keyring,dialog,sudo,systemd,sysvinit-utils"
246 247
248 #Packages to exclude from chroot build environment
249 APT_EXCLUDES=${APT_EXCLUDES:=""}
250
247 251 # Packages required for bootstrapping
248 252 REQUIRED_PACKAGES="debootstrap debian-archive-keyring qemu-user-static binfmt-support dosfstools rsync bmap-tools whois git bc psmisc dbus sudo"
249 253 MISSING_PACKAGES=""
@@ -253,6 +257,11 COMPILER_PACKAGES=""
253 257
254 258 set +x
255 259
260 #If init and systemd-sysv are wanted e.g. halt/reboot/shutdown scripts
261 if [ "$ENABLE_SYSVINIT" = false ] ; then
262 APT_EXCLUDES="--exclude=${APT_EXCLUDES},init,systemd-sysv"
263 fi
264
256 265 # Set Raspberry Pi model specific configuration
257 266 if [ "$RPI_MODEL" = 0 ] ; then
258 267 DTB_FILE=${RPI0_DTB_FILE}
@@ -306,9 +315,9 if [ "$BUILD_KERNEL" = true ] ; then
306 315 if [ "$RELEASE_ARCH" = "armhf" ]; then
307 316 REQUIRED_PACKAGES="${REQUIRED_PACKAGES} crossbuild-essential-armhf"
308 317 fi
309 if [ "$RELEASE_ARCH" = "arm64" ]; then
310 REQUIRED_PACKAGES="${REQUIRED_PACKAGES} crossbuild-essential-arm64"
311 fi
318 fi
319 if [ "$RELEASE_ARCH" = "arm64" ]; then
320 REQUIRED_PACKAGES="${REQUIRED_PACKAGES} crossbuild-essential-arm64"
312 321 fi
313 322 fi
314 323
@@ -448,7 +457,7 if [ "$ENABLE_MINBASE" = true ] ; then
448 457 fi
449 458
450 459 # Add required locales packages
451 if [ "$DEFLOCAL" != "en_US.UTF-8" ] ; then
460 if [ "$DEFLOCAL" != "en_US.UTF-8" ] || ([ -n XKB_MODEL ] || [ -n XKB_LAYOUT ] || [ -n XKB_VARIANT ] || [ -n XKB_OPTIONS ]); then
452 461 APT_INCLUDES="${APT_INCLUDES},locales,keyboard-configuration,console-setup"
453 462 fi
454 463
@@ -464,7 +473,7 fi
464 473
465 474 # Add iptables IPv4/IPv6 package
466 475 if [ "$ENABLE_IPTABLES" = true ] ; then
467 APT_INCLUDES="${APT_INCLUDES},iptables"
476 APT_INCLUDES="${APT_INCLUDES},iptables,iptables-persistent"
468 477 fi
469 478
470 479 # Add openssh server package
General Comments 0
Vous devez vous connecter pour laisser un commentaire. Se connecter maintenant