##// END OF EJS Templates
- removed wrong/old logic for locales...
Unknown -
r431:d23b6c103389
parent child
Show More
@@ -153,7 +153,7 Set the IP address for the second NTP server.
153 153
154 154 #### Basic system features:
155 155 ##### `ENABLE_CONSOLE`=true
156 Enable serial console interface. Recommended if no monitor or keyboard is connected to the RPi2/3. In case of problems fe. if the network (auto) configuration failed - the serial console can be used to access the system.
156 Enable serial console interface. Recommended if no monitor or keyboard is connected to the RPi2/3. In case of problems fe. if the network (auto) configuration failed - the serial console can be used to access the system. On `RPI_MODEL= 0,3,3P` - Bluetooth gets auto enabled if `ENABLE_CONSOLE` and `ENABLE_UBOOT` are set to `false`
157 157
158 158 ##### `ENABLE_I2C`=false
159 159 Enable I2C interface on the RPi2/3. Please check the [RPi2/3 pinout diagrams](https://elinux.org/RPi_Low-level_peripherals) to connect the right GPIO pins.
@@ -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" != "pc105" ] ; then
31 if [ "$XKB_MODEL" != "" ] ; then
32 32 sed -i "s/^XKBMODEL.*/XKBMODEL=\"${XKB_MODEL}\"/" "${ETC_DIR}/default/keyboard"
33 33 fi
34 if [ "$XKB_LAYOUT" != "us" ] ; then
34 if [ "$XKB_LAYOUT" != "" ] ; then
35 35 sed -i "s/^XKBLAYOUT.*/XKBLAYOUT=\"${XKB_LAYOUT}\"/" "${ETC_DIR}/default/keyboard"
36 36 fi
37 37 if [ "$XKB_VARIANT" != "" ] ; then
@@ -79,7 +79,7 if [ "$ENABLE_UBOOT" = true ] ; then
79 79 fi
80 80
81 81 # Set mkfile to use the correct dtb file
82 sed -i "s/^\(setenv dtbfile \).*/\1${DTB_FILE}/" "${BOOT_DIR}/uboot.mkimage"
82 sed -i "s|bcm2709-rpi-2-b.dtb|${DTB_FILE}|" "${BOOT_DIR}/uboot.mkimage"
83 83
84 84 # Set mkfile to use the correct mach id
85 85 if [ "$ENABLE_QEMU" = true ] ; then
@@ -87,7 +87,7 if [ "$ENABLE_UBOOT" = true ] ; then
87 87 fi
88 88
89 89 # Set mkfile to use kernel image
90 sed -i "s/^\(fatload mmc 0:1 \${kernel_addr_r} \).*/\1${KERNEL_IMAGE}/" "${BOOT_DIR}/uboot.mkimage"
90 sed -i "s|kernel7.img|${KERNEL_IMAGE}|" "${BOOT_DIR}/uboot.mkimage"
91 91
92 92 # Remove all leading blank lines
93 93 sed -i "/./,\$!d" "${BOOT_DIR}/uboot.mkimage"
@@ -59,7 +59,8 VIDEOCORE_URL=${VIDEOCORE_URL:=https://github.com/raspberrypi/userland}
59 59 BLUETOOTH_URL=${BLUETOOTH_URL:=https://github.com/RPi-Distro/pi-bluetooth.git}
60 60
61 61 # Build directories
62 BASEDIR=${BASEDIR:=$(pwd)/images/${RELEASE}}
62 WORKDIR=$(pwd)
63 BASEDIR=${BASEDIR:=${WORKDIR}/images/${RELEASE}}
63 64 BUILDDIR="${BASEDIR}/build"
64 65
65 66 # Chroot directories
@@ -186,7 +187,7 CHROOT_SCRIPTS=${CHROOT_SCRIPTS:=""}
186 187
187 188 # Packages required in the chroot build environment
188 189 APT_INCLUDES=${APT_INCLUDES:=""}
189 APT_INCLUDES="${APT_INCLUDES},apt-transport-https,apt-utils,ca-certificates,debian-archive-keyring,dialog,sudo,systemd,sysvinit-utils,locales,keyboard-configuration,console-setup"
190 APT_INCLUDES="${APT_INCLUDES},apt-transport-https,apt-utils,ca-certificates,debian-archive-keyring,dialog,sudo,systemd,sysvinit-utils,locales,keyboard-configuration,console-setup,libnss-systemd"
190 191
191 192 # Packages to exclude from chroot build environment
192 193 APT_EXCLUDES=${APT_EXCLUDES:=""}
@@ -200,6 +201,11 COMPILER_PACKAGES=""
200 201
201 202 set +x
202 203
204 #Check if apt-cacher-ng has its default port open on and set APT_PROXY
205 if [ -n "$(lsof -i :3142)" ] ; then
206 HTTP_PROXY=http://127.0.0.1:3142/
207 fi
208
203 209 # Setup architecture specific settings
204 210 if [ -n "$SET_ARCH" ] ; then
205 211 # 64 bit configuration
@@ -252,37 +258,37 else
252 258 echo "error: Please set '32' or '64' as value for SET_ARCH"
253 259 exit 1
254 260 fi
255 # Device specific configuration and U-Boot configuration
256 case "$RPI_MODEL" in
257 0)
258 DTB_FILE=${DTB_FILE:=bcm2708-rpi-0-w.dtb}
259 UBOOT_CONFIG=${UBOOT_CONFIG:=rpi_defconfig}
260 ;;
261 1)
262 DTB_FILE=${DTB_FILE:=bcm2708-rpi-b.dtb}
263 UBOOT_CONFIG=${UBOOT_CONFIG:=rpi_defconfig}
264 ;;
265 1P)
266 DTB_FILE=${DTB_FILE:=bcm2708-rpi-b-plus.dtb}
267 UBOOT_CONFIG=${UBOOT_CONFIG:=rpi_defconfig}
268 ;;
269 2)
270 DTB_FILE=${DTB_FILE:=bcm2709-rpi-2-b.dtb}
271 UBOOT_CONFIG=${UBOOT_CONFIG:=rpi_2_defconfig}
272 ;;
273 3)
274 DTB_FILE=${DTB_FILE:=bcm2710-rpi-3-b.dtb}
275 UBOOT_CONFIG=${UBOOT_CONFIG:=rpi_3_defconfig}
276 ;;
277 3P)
278 DTB_FILE=${DTB_FILE:=bcm2710-rpi-3-b.dtb}
279 UBOOT_CONFIG=${UBOOT_CONFIG:=rpi_3_defconfig}
280 ;;
281 *)
282 echo "error: Raspberry Pi model $RPI_MODEL is not supported!"
283 exit 1
284 ;;
285 esac
261 # Device specific configuration and U-Boot configuration
262 case "$RPI_MODEL" in
263 0)
264 DTB_FILE=${DTB_FILE:=bcm2708-rpi-0-w.dtb}
265 UBOOT_CONFIG=${UBOOT_CONFIG:=rpi_defconfig}
266 ;;
267 1)
268 DTB_FILE=${DTB_FILE:=bcm2708-rpi-b.dtb}
269 UBOOT_CONFIG=${UBOOT_CONFIG:=rpi_defconfig}
270 ;;
271 1P)
272 DTB_FILE=${DTB_FILE:=bcm2708-rpi-b-plus.dtb}
273 UBOOT_CONFIG=${UBOOT_CONFIG:=rpi_defconfig}
274 ;;
275 2)
276 DTB_FILE=${DTB_FILE:=bcm2709-rpi-2-b.dtb}
277 UBOOT_CONFIG=${UBOOT_CONFIG:=rpi_2_defconfig}
278 ;;
279 3)
280 DTB_FILE=${DTB_FILE:=bcm2710-rpi-3-b.dtb}
281 UBOOT_CONFIG=${UBOOT_CONFIG:=rpi_3_defconfig}
282 ;;
283 3P)
284 DTB_FILE=${DTB_FILE:=bcm2710-rpi-3-b.dtb}
285 UBOOT_CONFIG=${UBOOT_CONFIG:=rpi_3_defconfig}
286 ;;
287 *)
288 echo "error: Raspberry Pi model $RPI_MODEL is not supported!"
289 exit 1
290 ;;
291 esac
286 292
287 293 # Prepare date string for default image file name
288 294 DATE="$(date +%Y-%m-%d)"
@@ -297,8 +303,6 if [ "$ENABLE_WIRELESS" = true ] ; then
297 303 if [ "$RPI_MODEL" = 1 ] || [ "$RPI_MODEL" = 1P ] || [ "$RPI_MODEL" = 2 ] ; then
298 304 echo "error: The selected Raspberry Pi model has no internal wireless interface"
299 305 exit 1
300 else
301 echo "Raspberry Pi $RPI_MODEL has WIFI support"
302 306 fi
303 307 fi
304 308
@@ -365,7 +369,7 fi
365 369
366 370 # Check if all required packages are installed on the build system
367 371 for package in $REQUIRED_PACKAGES ; do
368 if [ "$(dpkg-query -W -f='${Status}' $package)" != "install ok installed" ] ; then
372 if [ "$(dpkg-query -W -f='${Status}' "$package")" != "install ok installed" ] ; then
369 373 MISSING_PACKAGES="${MISSING_PACKAGES} $package"
370 374 fi
371 375 done
General Comments 0
Vous devez vous connecter pour laisser un commentaire. Se connecter maintenant