소스 검색

upgrade to bullseye

pull/64/head
Luigi Cruz 3 년 전
부모
커밋
4ed63af963
22개의 변경된 파일128개의 추가작업 그리고 99개의 파일을 삭제
  1. +2
    -2
      Dockerfile
  2. +14
    -0
      LICENSE
  3. +5
    -9
      build-docker.sh
  4. +1
    -1
      build.sh
  5. +3
    -1
      depends
  6. +5
    -2
      scripts/common
  7. +20
    -5
      scripts/dependencies_check
  8. +3
    -3
      scripts/qcow2_handling
  9. +1
    -1
      stage1/00-boot-files/files/cmdline.txt
  10. +23
    -8
      stage1/00-boot-files/files/config.txt
  11. +3
    -1
      stage1/02-net-tweaks/00-run.sh
  12. +1
    -1
      stage1/03-install-packages/00-packages
  13. +3
    -4
      stage2/01-sys-tweaks/00-packages
  14. +2
    -2
      stage2/01-sys-tweaks/00-patches/07-resize-init.diff
  15. +4
    -3
      stage2/02-net-tweaks/01-run.sh
  16. +0
    -3
      stage2/02-net-tweaks/files/wait.conf
  17. +1
    -1
      stage3/00-install-packages/00-packages
  18. +3
    -1
      stage3/01-tweaks/00-run.sh
  19. +10
    -10
      stage4/00-install-packages/00-packages
  20. +22
    -22
      stage4/00-install-packages/01-packages
  21. +2
    -0
      stage4/04-pisdr-system/00-packages
  22. +0
    -19
      stage4/04-pisdr-system/05-run.sh

+ 2
- 2
Dockerfile 파일 보기

@@ -1,4 +1,4 @@
ARG BASE_IMAGE=debian:buster
ARG BASE_IMAGE=debian:bullseye
FROM ${BASE_IMAGE}

ENV DEBIAN_FRONTEND noninteractive
@@ -7,7 +7,7 @@ RUN apt-get -y update && \
apt-get -y install --no-install-recommends \
git vim parted \
quilt coreutils qemu-user-static debootstrap zerofree zip dosfstools \
bsdtar libcap2-bin rsync grep udev xz-utils curl xxd file kmod bc\
libarchive-tools libcap2-bin rsync grep udev xz-utils curl xxd file kmod bc\
binfmt-support ca-certificates qemu-utils kpartx \
&& rm -rf /var/lib/apt/lists/*



+ 14
- 0
LICENSE 파일 보기

@@ -19,3 +19,17 @@ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

Copyright (c) 2015 Raspberry Pi (Trading) Ltd.

All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.

2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

+ 5
- 9
build-docker.sh 파일 보기

@@ -48,6 +48,7 @@ fi
CONTAINER_NAME=${CONTAINER_NAME:-pigen_work}
CONTINUE=${CONTINUE:-0}
PRESERVE_CONTAINER=${PRESERVE_CONTAINER:-0}
PIGEN_DOCKER_OPTS=${PIGEN_DOCKER_OPTS:-""}

if [ -z "${IMG_NAME}" ]; then
echo "IMG_NAME not set in 'config'" 1>&2
@@ -77,17 +78,10 @@ BUILD_OPTS="$(echo "${BUILD_OPTS:-}" | sed -E 's@\-c\s?([^ ]+)@-c /config@')"
# Check the arch of the machine we're running on. If it's 64-bit, use a 32-bit base image instead
case "$(uname -m)" in
x86_64|aarch64)
case "$(uname -m)" in
aarch64)
BASE_IMAGE=arm32v7/debian:buster
;;
*)
BASE_IMAGE=i386/debian:buster
;;
esac
BASE_IMAGE=i386/debian:bullseye
;;
*)
BASE_IMAGE=debian:buster
BASE_IMAGE=debian:bullseye
;;
esac
${DOCKER} build --build-arg BASE_IMAGE=${BASE_IMAGE} -t pi-gen "${DIR}"
@@ -98,6 +92,7 @@ if [ "${CONTAINER_EXISTS}" != "" ]; then
--cap-add=ALL \
-v /dev:/dev \
-v /lib/modules:/lib/modules \
${PIGEN_DOCKER_OPTS} \
--volume "${CONFIG_FILE}":/config:ro \
-e "GIT_HASH=${GIT_HASH}" \
--volumes-from="${CONTAINER_NAME}" --name "${CONTAINER_NAME}_cont" \
@@ -112,6 +107,7 @@ else
--cap-add=ALL \
-v /dev:/dev \
-v /lib/modules:/lib/modules \
${PIGEN_DOCKER_OPTS} \
--volume "${CONFIG_FILE}":/config:ro \
-e "GIT_HASH=${GIT_HASH}" \
pi-gen \


+ 1
- 1
build.sh 파일 보기

@@ -219,7 +219,7 @@ export TARGET_HOSTNAME=${TARGET_HOSTNAME:-raspberrypi}

export FIRST_USER_NAME=${FIRST_USER_NAME:-pi}
export FIRST_USER_PASS=${FIRST_USER_PASS:-raspberry}
export RELEASE=${RELEASE:-buster}
export RELEASE=${RELEASE:-bullseye}
export WPA_ESSID
export WPA_PASSWORD
export WPA_COUNTRY


+ 3
- 1
depends 파일 보기

@@ -7,7 +7,7 @@ zerofree
zip
mkdosfs:dosfstools
capsh:libcap2-bin
bsdtar
bsdtar:libarchive-tools
grep
rsync
xz:xz-utils
@@ -17,3 +17,5 @@ file
git
lsmod:kmod
bc
qemu-nbd:qemu-utils
kpartx

+ 5
- 2
scripts/common 파일 보기

@@ -16,13 +16,16 @@ bootstrap(){
BOOTSTRAP_ARGS+=(--arch armhf)
BOOTSTRAP_ARGS+=(--components "main,contrib,non-free")
BOOTSTRAP_ARGS+=(--keyring "${STAGE_DIR}/files/raspberrypi.gpg")
BOOTSTRAP_ARGS+=(--exclude=info)
BOOTSTRAP_ARGS+=("$@")
printf -v BOOTSTRAP_STR '%q ' "${BOOTSTRAP_ARGS[@]}"

setarch linux32 capsh --drop=cap_setfcap -- -c "'${BOOTSTRAP_CMD}' $BOOTSTRAP_STR" || true

if [ -d "$2/debootstrap" ]; then
rmdir "$2/debootstrap"
if [ -d "$2/debootstrap" ] && ! rmdir "$2/debootstrap"; then
cp "$2/debootstrap/debootstrap.log" "${STAGE_WORK_DIR}"
log "bootstrap failed: please check ${STAGE_WORK_DIR}/debootstrap.log"
return 1
fi
}
export -f bootstrap


+ 20
- 5
scripts/dependencies_check 파일 보기

@@ -28,11 +28,26 @@ dependencies_check()
false
fi

# If we're building on a native arm platform, we don't need to check for
# binfmt_misc or require it to be loaded.

if ! grep -q "/proc/sys/fs/binfmt_misc" /proc/mounts; then
echo "Module binfmt_misc not loaded in host"
echo "Please run:"
echo " sudo modprobe binfmt_misc"
exit 1
binfmt_misc_required=1

case $(uname -m) in
aarch64)
binfmt_misc_required=0
;;
arm*)
binfmt_misc_required=0
;;
esac

if [[ "${binfmt_misc_required}" == "1" ]]; then
if ! grep -q "/proc/sys/fs/binfmt_misc" /proc/mounts; then
echo "Module binfmt_misc not loaded in host"
echo "Please run:"
echo " sudo modprobe binfmt_misc"
exit 1
fi
fi
}

+ 3
- 3
scripts/qcow2_handling 파일 보기

@@ -36,7 +36,7 @@ connect_blkdev() {
init_nbd
qemu-nbd --discard=unmap -c $NBD_DEV "$1"
sync
kpartx -a $NBD_DEV
kpartx -as $NBD_DEV
sync
CURRENT_IMAGE="$1"
}
@@ -108,7 +108,7 @@ load_qimage() {
254MiB,,83;
EOF
sync
kpartx -a $NBD_DEV
kpartx -as $NBD_DEV
mkdosfs -n boot -F 32 -v $MAP_BOOT_DEV
mkfs.ext4 -L rootfs -O "^huge_file,^metadata_csum,^64bit" $MAP_ROOT_DEV
sync
@@ -123,7 +123,7 @@ EOF
sync
qemu-nbd --discard=unmap -c $NBD_DEV image-${STAGE}.qcow2
sync
kpartx -a $NBD_DEV
kpartx -as $NBD_DEV
fi

mount -v -t ext4 $MAP_ROOT_DEV "${ROOTFS_DIR}"


+ 1
- 1
stage1/00-boot-files/files/cmdline.txt 파일 보기

@@ -1 +1 @@
console=serial0,115200 console=tty1 root=ROOTDEV rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait
console=serial0,115200 console=tty1 root=ROOTDEV rootfstype=ext4 fsck.repair=yes rootwait

+ 23
- 8
stage1/00-boot-files/files/config.txt 파일 보기

@@ -5,10 +5,6 @@
# uncomment if you get no picture on HDMI for a default "safe" mode
#hdmi_safe=1

# uncomment this if your display has a black border of unused pixels visible
# and your display can output without overscan
#disable_overscan=1

# uncomment the following to adjust overscan. Use positive numbers if console
# goes off screen, and negative if there is too much border
#overscan_left=16
@@ -56,10 +52,29 @@
# Enable audio (loads snd_bcm2835)
dtparam=audio=on

[pi4]
# Enable DRM VC4 V3D driver on top of the dispmanx display stack
dtoverlay=vc4-fkms-v3d
# Automatically load overlays for detected cameras
camera_auto_detect=1

# Automatically load overlays for detected DSI displays
display_auto_detect=1

# Enable DRM VC4 V3D driver
dtoverlay=vc4-kms-v3d
max_framebuffers=2

# Disable compensation for displays with overscan
disable_overscan=1

[cm4]
# Enable host mode on the 2711 built-in XHCI USB controller.
# This line should be removed if the legacy DWC2 controller is required
# (e.g. for USB device mode) or if USB support is not required.
otg_mode=1

[all]

[pi4]
# Run as fast as firmware / board allows
arm_boost=1

[all]
#dtoverlay=vc4-fkms-v3d

+ 3
- 1
stage1/02-net-tweaks/00-run.sh 파일 보기

@@ -3,4 +3,6 @@
echo "${TARGET_HOSTNAME}" > "${ROOTFS_DIR}/etc/hostname"
echo "127.0.1.1 ${TARGET_HOSTNAME}" >> "${ROOTFS_DIR}/etc/hosts"

ln -sf /dev/null "${ROOTFS_DIR}/etc/systemd/network/99-default.link"
on_chroot << EOF
SUDO_USER="${FIRST_USER_NAME}" raspi-config nonint do_net_names 1
EOF

+ 1
- 1
stage1/03-install-packages/00-packages 파일 보기

@@ -1 +1 @@
libraspberrypi-bin libraspberrypi0 raspi-config
libraspberrypi-bin libraspberrypi0

+ 3
- 4
stage2/01-sys-tweaks/00-packages 파일 보기

@@ -1,8 +1,8 @@
ssh less fbset sudo psmisc strace ed ncdu crda
console-setup keyboard-configuration debconf-utils parted unzip
build-essential manpages-dev python bash-completion gdb pkg-config
python-rpi.gpio v4l-utils
python-gpiozero
build-essential manpages-dev bash-completion gdb pkg-config
python-is-python3
python3-rpi.gpio v4l-utils
python3-gpiozero
avahi-daemon
lua5.1
@@ -26,7 +26,6 @@ policykit-1
ssh-import-id
rng-tools
ethtool
vl805fw
ntfs-3g
pciutils
rpi-eeprom


+ 2
- 2
stage2/01-sys-tweaks/00-patches/07-resize-init.diff 파일 보기

@@ -1,5 +1,5 @@
--- stage2.orig/rootfs/boot/cmdline.txt
+++ stage2/rootfs/boot/cmdline.txt
@@ -1 +1 @@
-console=serial0,115200 console=tty1 root=ROOTDEV rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait
+console=serial0,115200 console=tty1 root=ROOTDEV rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait quiet init=/usr/lib/raspi-config/init_resize.sh
-console=serial0,115200 console=tty1 root=ROOTDEV rootfstype=ext4 fsck.repair=yes rootwait
+console=serial0,115200 console=tty1 root=ROOTDEV rootfstype=ext4 fsck.repair=yes rootwait quiet init=/usr/lib/raspi-config/init_resize.sh

+ 4
- 3
stage2/02-net-tweaks/01-run.sh 파일 보기

@@ -1,11 +1,12 @@
#!/bin/bash -e

install -v -d "${ROOTFS_DIR}/etc/systemd/system/dhcpcd.service.d"
install -v -m 644 files/wait.conf "${ROOTFS_DIR}/etc/systemd/system/dhcpcd.service.d/"

install -v -d "${ROOTFS_DIR}/etc/wpa_supplicant"
install -v -m 600 files/wpa_supplicant.conf "${ROOTFS_DIR}/etc/wpa_supplicant/"

on_chroot << EOF
SUDO_USER="${FIRST_USER_NAME}" raspi-config nonint do_boot_wait 0
EOF

if [ -v WPA_COUNTRY ]; then
echo "country=${WPA_COUNTRY}" >> "${ROOTFS_DIR}/etc/wpa_supplicant/wpa_supplicant.conf"
fi


+ 0
- 3
stage2/02-net-tweaks/files/wait.conf 파일 보기

@@ -1,3 +0,0 @@
[Service]
ExecStart=
ExecStart=/usr/lib/dhcpcd5/dhcpcd -q -w

+ 1
- 1
stage3/00-install-packages/00-packages 파일 보기

@@ -3,7 +3,6 @@ qpdfview gtk2-engines alsa-utils
desktop-base
git
omxplayer
raspberrypi-artwork
policykit-1
gvfs
rfkill
@@ -13,3 +12,4 @@ fonts-droid-fallback
fonts-liberation2
obconf
arandr
libcamera-tools

+ 3
- 1
stage3/01-tweaks/00-run.sh 파일 보기

@@ -1,3 +1,5 @@
#!/bin/bash -e

rm -f "${ROOTFS_DIR}/etc/systemd/system/dhcpcd.service.d/wait.conf"
on_chroot << EOF
SUDO_USER="${FIRST_USER_NAME}" raspi-config nonint do_boot_wait 1
EOF

+ 10
- 10
stage4/00-install-packages/00-packages 파일 보기

@@ -1,11 +1,11 @@
python python3-pygame python-pygame python-tk
python3 python3-tk thonny
python3-pygame
python3-tk thonny
python3-pgzero
python-serial python3-serial
python-picamera python3-picamera
python3-serial
python3-picamera
debian-reference-en dillo
raspberrypi-net-mods raspberrypi-ui-mods
python-pip python3-pip
python3-pip
python3-numpy
pypy
alacarte rc-gui sense-hat
@@ -13,11 +13,11 @@ tree
libgl1-mesa-dri libgles1 libgles2-mesa xcompmgr
geany
piclone
wiringpi pigpio python-pigpio python3-pigpio raspi-gpio python3-rpi.gpio
python-spidev python3-spidev
python-twython python3-twython
python-smbus python3-smbus
python-flask python3-flask
pigpio python3-pigpio raspi-gpio python3-rpi.gpio
python3-spidev
python3-twython
python3-smbus
python3-flask
pprompt
piwiz
rp-prefapps


+ 22
- 22
stage4/00-install-packages/01-packages 파일 보기

@@ -1,22 +1,22 @@
python-automationhat python3-automationhat
python-blinkt python3-blinkt
python-cap1xxx python3-cap1xxx
python-drumhat python3-drumhat
python-envirophat python3-envirophat
python-explorerhat python3-explorerhat
python-fourletterphat python3-fourletterphat
python-microdotphat python3-microdotphat
python-mote python3-mote
python-motephat python3-motephat
python-phatbeat python3-phatbeat
python-pianohat python3-pianohat
python-piglow python3-piglow
python-rainbowhat python3-rainbowhat
python-scrollphat python3-scrollphat
python-scrollphathd python3-scrollphathd
python-sn3218 python3-sn3218
python-skywriter python3-skywriter
python-touchphat python3-touchphat
python-buttonshim python3-buttonshim
python-unicornhathd python3-unicornhathd
python-pantilthat python3-pantilthat
python3-automationhat
python3-blinkt
python3-cap1xxx
python3-drumhat
python3-envirophat
python3-explorerhat
python3-fourletterphat
python3-microdotphat
python3-mote
python3-motephat
python3-phatbeat
python3-pianohat
python3-piglow
python3-rainbowhat
python3-scrollphat
python3-scrollphathd
python3-sn3218
python3-skywriter
python3-touchphat
python3-buttonshim
python3-unicornhathd
python3-pantilthat

+ 2
- 0
stage4/04-pisdr-system/00-packages 파일 보기

@@ -9,3 +9,5 @@ libssl-dev

libboost-dev
python3-pytest
pybind11-dev
python3-pybind11

+ 0
- 19
stage4/04-pisdr-system/05-run.sh 파일 보기

@@ -1,19 +0,0 @@
#!/bin/bash -e

on_chroot << EOF
mkdir -p "/home/${FIRST_USER_NAME}/PiSDR/System"
cd "/home/${FIRST_USER_NAME}/PiSDR/System"

if [ ! -d "pybind11" ]; then
git clone --depth 1 https://github.com/pybind/pybind11.git
fi

cd pybind11
mkdir -p build
cd build
cmake -GNinja ..
ninja install
ldconfig
cd ..
rm -fr build
EOF

불러오는 중...
취소
저장