Commit before push.

This commit is contained in:
cyteen 2024-03-13 03:37:15 +00:00
parent 522ce8f9b9
commit 22e84071b3
33 changed files with 3328 additions and 178 deletions

View File

@ -1,3 +1,7 @@
NB. These helper functions are falling behind the arm-sdk blend helpers.
currently /space/code_repositories/decode-os/os-build-system/blends/devuan-desktop is the working place.
Helper scripts and configs for devuan sdk to form a blend to produce minimized docker images and install devuan to multiple harddrives using zfs.

View File

@ -1,7 +1,15 @@
metal
/boot/grub not mounted by fstab, mountpoint on bpool not available
------
connman not set up, might not like it.
-----
bluez missing
-----
default devuan user disappears
-----
change /tmp to tmpfs
------
rewrite the docker helpers that just set config in apt-conf.d to the sysconf pattern.
@ -17,7 +25,7 @@ Move the metal blend and associated file into its own blend directory.
add submodules, dockerfile and gitlab-ci.yml so that images can be build automatically.
---------------------
----------------
debootstrap has the option 'doing_variant' that accepts
1. minbase - base="$devuan_required apt"

View File

@ -53,6 +53,7 @@ base_packages+=(
openssh-client
sudo
alsa-utils
alsa-ucm-conf
mawk
tmux
tmuxp
@ -92,7 +93,6 @@ extra_packages+=(
firmware-bnx2
firmware-bnx2x
firmware-brcm80211
firmware-intelwimax
firmware-iwlwifi
firmware-libertas
firmware-linux-free
@ -173,7 +173,6 @@ extra_packages+=(
firmware-bnx2
firmware-bnx2x
firmware-brcm80211
firmware-intelwimax
firmware-iwlwifi
firmware-libertas
firmware-linux-nonfree
@ -190,7 +189,6 @@ extra_packages+=(
refractasnapshot-gui
linux-headers-${arch}
zfs-dkms
spl-dkms
zfsutils-linux
avahi-daemon
)

View File

@ -6,13 +6,34 @@ arrs+=(disk_name efi_partitions swap_partitions custom_deb_packages)
blend_name="devuan-desktop-metal_"
# release="jessie"
# version="1.0.0"
# release="ascii"
# version="2.0.0"
# release="beowulf"
# version="3.0.0"
# release="chimaera"
# version="4.0.0"
release="daedalus"
version="5.0.0"
version="5.0.0"
# release="excalibur"
# version="6.0.0"
# release="freia"
# version="7.0.0"
hostname="devuan"
username="devuan"
userpass="devuan"
userskel="/etc/skel"
user_skel="/etc/skel"
user_groups="sudo,docker"
user_shell="/usr/bin/zsh"
default_shell="/usr/bin/zsh"
# comment to disable:
@ -26,26 +47,24 @@ default_shell="/usr/bin/zsh"
# >>> ${bootstrap_options} \ <<<
# --arch
# Currently we have put a wrapper in blend_helpers-docker to add these optiions using an alias.
bootstrap_options=("\
--force-check-gpg \
--no-merged-usr \
--variant=minbase" \
)
debootstrap_options=("--force-check-gpg --no-merged-usr --variant=minbase")
debootstrap_purge_packages=()
debootstrap_cache="/tmp/debootstrap_cache"
# debootstrap mirror
#mirror="tor+http://devuanauxrkggcowgm2vcs6go3c5pgxdidd5wqjpg7zpfaxkmgspr6id.onion/merged"
#mirror="http://pkgmaster.devuan.org/merged" #
#mirror="http://deb.devuan.org" #
#mirror="http://localhost:3142/deb.devuan.org/merged/" # apt-cacher-ng
#mirror="http://192.168.1.50:3142/deb.devuan.org/merged/" # apt-cacher-ng
mirror="http://192.168.1.50:3142" # apt-cacher-ng
#mirror="http://192.168.1.49:3142/deb.devuan.org/merged/" # apt-cacher-ng
mirror="http://192.168.1.49:3142" # apt-cacher-ng
# the mirror to use in /etc/apt/apt.conf.d/02proxy
apt_proxy="http://192.168.1.50:3142"
apt_proxy="http://192.168.1.49:3142"
host_arch="$(dpkg-architecture -q DEB_BUILD_ARCH)"
arch=arm64
#arch=amd64
arch="amd64"
#arch="arm64"
#arch="i386"
case "$arch" in
# for minimal-live
@ -59,15 +78,16 @@ case "$arch" in
arm64) extra_packages+=(linux-image-arm64) ;;
esac
kernel_version="5.10.0-13"
#kernel_version="5.17.3-1" = requires daedalus
kernel_version="6.1.0-10"
# ZFS install parameters
rootfs="zfs"
disk_path="/dev/disk/by-id"
disk_name="ata-HGST_HTS541010A9E680_JA1000102T3RVP"
disk2_name="ata-HGST_HTS541010A9E680_JB10001329MG7R"
disk_name="ata-CT1000MX500SSD1_2321E6DBE216"
disk2_name="ata-CT1000MX500SSD1_2321E6DBE1D2"
# disk_name="ata-HGST_HTS541010A9E680_JA1000102T3RVP"
# disk2_name="ata-HGST_HTS541010A9E680_JB10001329MG7R"
#raid=unset # raid0: striped 1 or more
raid=mirror # raid1: mirror 2
@ -152,11 +172,7 @@ fi
# Uncomment for amd64
if [[ dpkg-architecture --is amd64 ]]; then
base_packages+=(grub-efi-amd64-bin grub-efi-ia32-bin)
else
echo "Build u-boot instead of grub: not implemetned yet."
fi
base_packages+=(grub-efi-amd64-bin grub-efi-ia32-bin)
# devuan grub themes: cinnabar-grub darkpurpy-grub deepsea-grub
# grub themes must be placed on filesystems visable to grub ie not zfs.
@ -164,7 +180,7 @@ grub_theme="deepsea-grub"
grub_gfxmode="1920x1200x32,1920x1200x8"
mirror="http://deb.devuan.org/merged"
section="main contrib non-free"
section="main contrib non-free non-free-firmware"
# need to add to the debootstrap command in lib/libdevuansdk/zlibs/bootstrap
#debootstrap_options="--extra-suites=ascii-proposed-updates --include=libupower-glib3,dbus-x11,xfce4"

185
blend_config.mirror Normal file
View File

@ -0,0 +1,185 @@
#!/usr/bin/env zsh
## configuration file for devuan-desktop-live blend
vars+=(username userpass default_shell mkefi grubversion hookscripts)
arrs+=(disk_name efi_partitions swap_partitions custom_deb_packages)
blend_name="devuan-desktop-metal_"
release="daedalus"
version="5.0.0"
hostname="devuan"
username="devuan"
userpass="devuan"
userskel="/etc/skel"
default_shell="/usr/bin/zsh"
# comment to disable:
#hookscripts="yes"
# debootstrap options
# From lib/libdevuansdk/zlib/bootstrap we need to add the options variable.
# debootstrap --keyring="$LIBPATH/extra/devuan-keyring/keyrings/devuan-archive-keyring.gpg" \
# --include=devuan-keyring,wget,ca-certificates \
# --foreign \
# >>> ${bootstrap_options} \ <<<
# --arch
# Currently we have put a wrapper in blend_helpers-docker to add these optiions using an alias.
bootstrap_options=("\
--force-check-gpg \
--no-merged-usr \
--variant=minbase" \
)
# debootstrap mirror
#mirror="tor+http://devuanauxrkggcowgm2vcs6go3c5pgxdidd5wqjpg7zpfaxkmgspr6id.onion/merged"
#mirror="http://pkgmaster.devuan.org/merged" #
#mirror="http://deb.devuan.org" #
#mirror="http://localhost:3142/deb.devuan.org/merged/" # apt-cacher-ng
#mirror="http://192.168.1.50:3142/deb.devuan.org/merged/" # apt-cacher-ng
mirror="http://192.168.1.50:3142" # apt-cacher-ng
# the mirror to use in /etc/apt/apt.conf.d/02proxy
apt_proxy="http://192.168.1.50:3142"
host_arch="$(dpkg-architecture -q DEB_BUILD_ARCH)"
arch=arm64
#arch=amd64
case "$arch" in
# for minimal-live
#i386) extra_packages+=(linux-image-686) ;;
# for desktop-live
#i386) extra_packages+=(linux-image-686-pae) ;;
amd64) extra_packages+=(linux-image-amd64) ;;
arm64) extra_packages+=(linux-image-arm64) ;;
esac
kernel_version="5.10.0-13"
#kernel_version="5.17.3-1" = requires daedalus
# ZFS install parameters
rootfs="zfs"
disk_path="/dev/disk/by-id"
disk_name="ata-HGST_HTS541010A9E680_JA1000102T3RVP"
disk2_name="ata-HGST_HTS541010A9E680_JB10001329MG7R"
#raid=unset # raid0: striped 1 or more
raid=mirror # raid1: mirror 2
#raid=raidz # raid1: mirror 3
#raid=raidz2 # raid2: mirror 4
#raid=raidz3 # raid3: mirror 5
#raid=stripedmirror # raid10: mirror 4 and paired
available_disks=("${disk_name}")
if [[ -v $raid ]]; then
available_disks+="${disk2_name}"
fi
root_name="devuan-1"
rpool_name="rpool"
bpool_name="bpool"
#encrypt=yes
# polite to use somewhere other than /etc/zfs rather than squash it.
#zpool_cache_dir="/etc/zfs"
zpool_cache_dir="/var/tmp"
## underlying physical block size for zpool create.
# ashift=9 means 512B sectors (used by all ancient drives),
# ashift=12 means 4K sectors (used by most modern hard drives), and
# ashift=13 means 8K sectors (used by some modern SSDs).
ashift=12
bios_part_number="1"
efi_part_number="2"
swap_part_number="3"
boot_part_number="4"
root_part_number="5"
efi_start="2048"
bios_part_size="1MB"
efi_part_size="512MB"
swap_part_size="8GB"
boot_part_size="2GB"
# zvol requires resume to be disabled
#swap_type="zvol"
swap_type="physical"
tmp_exec_state="off"
var_tmp_exec_state="on"
# uncomment to create uefi-bootable iso causes iso_make_efi and iso_write_grub_cfg
# to be called in blend_postinst
#MKEFI=1
efi_work="$BLENDPATH/${release}/efi-files"
zero_uefi="no"
#efi=1
if [[ -n $efi ]];then
grub_mount="/boot/efi"
grubversion="grub-efi-${arch}"
case "arch" in
amd64) grub_efi_target="x86_64-efi" ;;
arm64) grub_efi_target="arm64-efi" ;;
i386) grub_efi_target="i386-efi" ;;
esac
else
grub_mount="/boot/grub"
grubversion="grub-pc"
fi
efi_partitions+=("/dev/disk/by-id/${disk_name}-part${efi_part_number}")
if [[ -v ${raid} ]]; then
efi_partitions+="/dev/disk/by-id/${disk2_name}-part${efi_part_number}"
fi
swap_partitions+=("/dev/disk/by-id/${disk_name}-part${swap_part_number}")
if [[ -v ${raid} ]]; then
swap_partitions+="/dev/disk/by-id/${disk2_name}-part${swap_part_number}"
fi
# Uncomment for amd64
if [[ $(dpkg-architecture --is amd64) ]]; then
base_packages+=(grub-efi-amd64-bin grub-efi-ia32-bin)
else
echo "Build u-boot instead of grub: not implemented yet."
fi
# devuan grub themes: cinnabar-grub darkpurpy-grub deepsea-grub
# grub themes must be placed on filesystems visable to grub ie not zfs.
grub_theme="deepsea-grub"
grub_gfxmode="1920x1200x32,1920x1200x8"
mirror="http://deb.devuan.org/merged"
section="main contrib non-free"
# need to add to the debootstrap command in lib/libdevuansdk/zlibs/bootstrap
#debootstrap_options="--extra-suites=ascii-proposed-updates --include=libupower-glib3,dbus-x11,xfce4"
base_packages_option=(--no-install-recommends)
extra_packages_option=(--no-install-recommends)
release_conf="$BLENDPATH/${release}/config"
### package sets are defined in the corresponding $release/config file
source $release_conf
## image_name depends on release and version
image_name="${os}_${release}_${version}_${arch}_desktop"

View File

@ -0,0 +1,326 @@
#!/usr/bin/env zsh
# shellcheck shell=bash
## configuration file for devuan-minimal-docker blend -- Chimaera release
# -o options to apt-get install.
# APT::Get::Mark-Auto=true
# APT::Get::AllowUnauthenticated=true
# Dpkg::Progress and Dpkg::Progress-Fancy=true
#
# The following would be useful if pulling old releases
#core_packages_option(-o Acquire::Check-Valid-Until=false -o Acquire::AllowReleaseInfoChange=true)
#base_packages_option(-o Acquire::Check-Valid-Until=false -o Acquire::AllowReleaseInfoChange=true)
#extra_packages_option(-o Acquire::Check-Valid-Until=false -o Acquire::AllowReleaseInfoChange=true)
# Override base_packages and core_packages from: lib/libdevuansdk/config
core_packages=()
base_packages=()
extra_packages=()
# these are the differences between debian and devuan slim images that are not in 'required'.
# If they are in /usr/share/debootstrap/scripts/ceres it doesn't have to be here.
# devuan_required="devuan-keyring sysvinit-core"
#
base_packages=(
bootlogd
innserv
eudev
)
# bootstrap_stage4
extra_packages=(
vim-tiny
)
### now we include all the package sets
#base_packages+=(
# $minimal_base_packages
# $minimal_admin_packages
# $minimal_editors_packages
# $minimal_net_packages
# $minimal_prod_packages
# $minimal_devel_packages
# $minimal_games_packages
# $minimal_a11y_packages
# $minimal_media_packages
# $minimal_misc_packages
#)
##
## definition of package sets
##
### base package set
minimal_base_packages+=(
acpi
acpi-support-base
acpid
acpi-fakekey
at
bash
bash-completion
bc
busybox
console-common
console-data
console-setup
console-setup-linux
coreutils
dash
dc
dialog
discover
dselect
file
groff-base
$grubversion
info
kbd
laptop-detect
locales
lsof
syslinux
util-linux-locales
zsh
)
## admin package set
minimal_admin_packages+=(
cryptsetup
cryptsetup-bin
debootstrap
dosfstools
entr
gddrescue
gdisk
htop
iftop
iotop
iw
lvm2
mdadm
mtr-tiny
multitail
ncdu
parted
pciutils
psmisc
sudo
time
usbutils
wavemon
wireless-tools
wpasupplicant
)
## editors package set
minimal_editors_packages+=(
ed
nano
vim-tiny
zile
)
## networking package set
minimal_net_packages+=(
bind9-host
# bittornado ### not in chimaera
ceni
curl
dnsutils
edbrowse
fetchmail
ftp
geoip-bin
haveged
irssi
lftp
links2
lrzsz
mcabber
minicom
mosh
msmtp
mutt
netcat
net-tools
nfacct
# nrss # not in beowulf. Use rsstail instead.
openssh-client
openssh-server
procmail
rfkill
rsstail
rsync
# setnet # use ascii deb package for beowulf and chimaera
telnet
traceroute
transmission-cli
w3m
wget
whois
)
## productivity package set
minimal_prod_packages+=(
abook
apcalc
aspell
aspell-en
calcurse
clex
dvtm
fbi
fbterm
ghostscript
gnupg
gnupg2
gnupg-agent
mc
parallel
poppler-utils
rpl
rename
sc
screen
taskwarrior
tmux
)
## programming package set
minimal_devel_packages+=(
tcc
libc6-dev
m4
patch
perl
perl-base
perl-modules-5.36
python3.11-minimal
gawk
guile-3.0
guile-3.0-libs
)
## games package set
# minimal_games_packages+=(
# bastet
# bombardier
# bsdgames
# cavezofphear
# crawl
# curseofwar
# empire
# freesweep
# gnuchess
# greed
# matanza
# moria
# nethack-console
# ninvaders
# omega-rpg
# pacman4console
# pente
# sudoku
# )
## accessibility package set
minimal_a11y_packages+=(
beep
brltty
espeak
espeakup
yasr
)
## multimedia package set
minimal_media_packages+=(
alsa-utils
caca-utils
fmtools
hasciicam
imagemagick
jhead
moc
# radio # Not in beowulf. Replaced with fmtools.
sox
)
## misc package set
minimal_misc_packages+=(
cmatrix
cowsay
eject
figlet
fortunes-min
fortune-mod
gpm
man-db
manpages
manpages-dev
mlocate
# termsaver ### not in chimaera
toilet
toilet-fonts
ttyrec
unzip
)
#### TODO: REPLACE twidge (twitter client)
#### ADDED: geoip-bin
#extra_packages+=(
# atmel-firmware
# bluez-firmware
# dahdi-firmware-nonfree
# firmware-amd-graphics
# firmware-ath9k-htc
# firmware-atheros
# firmware-bnx2
# firmware-bnx2x
# firmware-brcm80211
# firmware-cavium
## firmware-crystalhd
# firmware-intel-sound
# firmware-intelwimax
## firmware-ipw2x00 ### These two exist but fail today.
## firmware-ivtv ### ...they require EULA
# firmware-iwlwifi
# firmware-libertas
# firmware-linux-free
# firmware-linux-nonfree
# firmware-myricom
# firmware-netxen
# firmware-qlogic
## firmware-ralink
# firmware-realtek
# firmware-ti-connectivity
# firmware-zd1211
# refractainstaller-base
# refractasnapshot-base
#)
#purge_packages=(
# elinks
# elinks-data
# liberror-perl
# libfsplib0
# libtre5
# openntpd
# tasksel
# tasksel-data
#)
#custom_deb_packages+=(
# memtest86+_5.01-3.1_${arch}.deb
# setnet_0.4+devuan1_all.deb
#)

299
blend_daedalus_config Normal file
View File

@ -0,0 +1,299 @@
#!/usr/bin/env zsh
## configuration file for devuan-desktop-live blend -- Daedalus release
base_packages+=(
lsof
bash-completion
texinfo
acpi-support-base
acpi-fakekey
aptitude
apt-listchanges
debootstrap
discover
dnsutils
doc-debian
docutils-common
docutils-doc
ftp
gettext
gnupg2
gparted
mtd-utils
u-boot-tools
grub-pc-bin
$grubversion
iw
laptop-detect
lvm2
mdadm
mlocate
mutt
ncurses-term
net-tools
netcat-traditional
nfs-common
procmail
reportbug
rfkill
telnet
traceroute
usbutils
util-linux-locales
w3m
whois
)
base_packages+=(
apt-utils
dselect
parted
openssh-server
openssh-client
sudo
alsa-utils
alsa-ucm-conf
mawk
tmux
tmuxp
screen
ntp
wpasupplicant
wireless-tools
elinks
firmware-linux-free
zsh
rsync
git
strace
)
extra_packages+=(
task-desktop
task-laptop
task-xfce-desktop
fontsnaps
# task-print-server ## no package
popularity-contest
# refractainstaller-base
# refractasnapshot-base
# yad
# refractainstaller-gui
# refractasnapshot-gui
# libgtk3-perl #need to add this for graphical debconf - THIS SUCKS! (buttons off-screen)
gvfs-backends
)
extra_packages+=(
firmware-atheros
firmware-bnx2
firmware-bnx2x
firmware-brcm80211
firmware-iwlwifi
firmware-libertas
firmware-linux-free
firmware-linux-nonfree
firmware-misc-nonfree
firmware-myricom
firmware-netxen
firmware-qlogic
# firmware-ralink # no package
firmware-realtek
firmware-ti-connectivity
firmware-zd1211
)
extra_packages+=(
fonts-quicksand
fonts-liberation
fonts-symbola
xserver-xorg-input-all
xserver-xorg-video-all
anacron
bluetooth
iw
powertop
vim-gtk3
wireless-tools
wpasupplicant
tasksel
xfce4
xfce4-goodies
xfce4-power-manager
xfce4-terminal
atril
dbus-x11
hunspell-en-gb
hyphen-en-gb
mythes-en-us
synaptic
system-config-printer
tango-icon-theme
xsane
enlightenment
terminology
rox-filer
rsync
lsof
gdisk
gnupg-utils
schroot
debootstrap
debhelper
makedev
curl
git
wget
qemu-user-static
build-essential
gcc-arm-none-eabi
gcc-multilib
lib32z1
u-boot-tools
device-tree-compiler
lzop
dosfstools
vboot-utils
vboot-kernel-utils
dpkg-dev
swig
bc
bison
flex
parted
kpartx
qemu-user-static
pinthread
neovim
firmware-atheros
firmware-bnx2
firmware-bnx2x
firmware-brcm80211
firmware-iwlwifi
firmware-libertas
firmware-linux-nonfree
firmware-misc-nonfree
firmware-myricom
firmware-netxen
firmware-qlogic
firmware-realtek
firmware-ti-connectivity
firmware-zd1211
sudo
# yad
# refractainstaller-gui
# refractasnapshot-gui
linux-headers-${arch}
zfs-dkms
zfsutils-linux
avahi-daemon
)
purge_packages=(
# devuan-baseconf
debian-keyring
elinks
elinks-data
# git
# git-core
# git-man
liberror-perl
libfsplib0
libtre5
# openntpd
# openssh-server
# openssh-sftp-server
# tmux
# zsh
# zsh-common
# intel-microcode
# iucode-tool
# amd64-microcode
)
purge_packages+=(
auditd
cups-browsed
gvfs-daemons
pulseaudio
pulseaudio-utils
libpulsedsp
xscreensaver
xscreensaver-data
packagekit
packagekit-tools
)
custom_deb_packages+=(
)
custom_scripts+=(
001_apt_get-selections.sh
001_apt-group.sh
001_apt-parallel_on.sh
001_apt-preferences.sh
001_apt-proxy_off.sh
001_apt-proxy_on.sh
001_apt-sources.sh
001_apt_suggests-recommends.sh
001_apt-verbose-versions.sh
001_docker_grub-commandline.sh
001_enable-binfmt-misc.sh
001_grub_gfxmode.sh
001_locales.sh
001_prevent_udev_net-rename.sh
# 001_resolvconf.sh
020_connman.sh
001_ssh.sh
001_swap-caps.sh
001_system_bell.sh
001_udev-rules.sh
001_virtual-mem.sh
010_sysctl.sh
010_generate-ssh.sh
010_apt-get.sh
001_system_bell.sh
010_saltstack.sh
020_console.sh
020_zsh_quickstart.sh
020_zsh_aliases.d.sh
020_lsd.sh
020_grc.sh
010_alsa.sh
020_conky.sh
020_djmount.sh
029_yarn.sh
020_vim.sh
020_meld.sh
020_themes.sh
020_audacity.sh
020_powerline-bash.sh
020_fonts.sh
020_nanorc.sh
020_neovim.sh
020_mutt-wizard.sh
020_mutt-notmuch.sh
020_mutt-khard.sh
020_shellcheck.sh
020_neofetch_motd.sh
020_tmux.sh
020_rox-filer.sh
020_hexchat.sh
020_pidgin.sh
020_brave_browser.sh
# 020_slim.sh
020_lightdm.sh
020_docker.sh
020_docker-compose_checkinstall.sh
050_remove_xscreensaver.sh
)

View File

@ -0,0 +1,326 @@
#!/usr/bin/env zsh
# shellcheck shell=bash
## configuration file for devuan-minimal-docker blend -- Chimaera release
# -o options to apt-get install.
# APT::Get::Mark-Auto=true
# APT::Get::AllowUnauthenticated=true
# Dpkg::Progress and Dpkg::Progress-Fancy=true
#
# The following would be useful if pulling old releases
#core_packages_option(-o Acquire::Check-Valid-Until=false -o Acquire::AllowReleaseInfoChange=true)
#base_packages_option(-o Acquire::Check-Valid-Until=false -o Acquire::AllowReleaseInfoChange=true)
#extra_packages_option(-o Acquire::Check-Valid-Until=false -o Acquire::AllowReleaseInfoChange=true)
# Override base_packages and core_packages from: lib/libdevuansdk/config
core_packages=()
base_packages=()
extra_packages=()
# these are the differences between debian and devuan slim images that are not in 'required'.
# If they are in /usr/share/debootstrap/scripts/ceres it doesn't have to be here.
# devuan_required="devuan-keyring sysvinit-core"
#
base_packages=(
bootlogd
innserv
eudev
)
# bootstrap_stage4
extra_packages=(
vim-tiny
)
### now we include all the package sets
#base_packages+=(
# $minimal_base_packages
# $minimal_admin_packages
# $minimal_editors_packages
# $minimal_net_packages
# $minimal_prod_packages
# $minimal_devel_packages
# $minimal_games_packages
# $minimal_a11y_packages
# $minimal_media_packages
# $minimal_misc_packages
#)
##
## definition of package sets
##
### base package set
minimal_base_packages+=(
acpi
acpi-support-base
acpid
acpi-fakekey
at
bash
bash-completion
bc
busybox
console-common
console-data
console-setup
console-setup-linux
coreutils
dash
dc
dialog
discover
dselect
file
groff-base
$grubversion
info
kbd
laptop-detect
locales
lsof
syslinux
util-linux-locales
zsh
)
## admin package set
minimal_admin_packages+=(
cryptsetup
cryptsetup-bin
debootstrap
dosfstools
entr
gddrescue
gdisk
htop
iftop
iotop
iw
lvm2
mdadm
mtr-tiny
multitail
ncdu
parted
pciutils
psmisc
sudo
time
usbutils
wavemon
wireless-tools
wpasupplicant
)
## editors package set
minimal_editors_packages+=(
ed
nano
vim-tiny
zile
)
## networking package set
minimal_net_packages+=(
bind9-host
# bittornado ### not in chimaera
ceni
curl
dnsutils
edbrowse
fetchmail
ftp
geoip-bin
haveged
irssi
lftp
links2
lrzsz
mcabber
minicom
mosh
msmtp
mutt
netcat
net-tools
nfacct
# nrss # not in beowulf. Use rsstail instead.
openssh-client
openssh-server
procmail
rfkill
rsstail
rsync
# setnet # use ascii deb package for beowulf and chimaera
telnet
traceroute
transmission-cli
w3m
wget
whois
)
## productivity package set
minimal_prod_packages+=(
abook
apcalc
aspell
aspell-en
calcurse
clex
dvtm
fbi
fbterm
ghostscript
gnupg
gnupg2
gnupg-agent
mc
parallel
poppler-utils
rpl
rename
sc
screen
taskwarrior
tmux
)
## programming package set
minimal_devel_packages+=(
tcc
libc6-dev
m4
patch
perl
perl-base
perl-modules-5.36
python3.11-minimal
gawk
guile-3.0
guile-3.0-libs
)
## games package set
# minimal_games_packages+=(
# bastet
# bombardier
# bsdgames
# cavezofphear
# crawl
# curseofwar
# empire
# freesweep
# gnuchess
# greed
# matanza
# moria
# nethack-console
# ninvaders
# omega-rpg
# pacman4console
# pente
# sudoku
# )
## accessibility package set
minimal_a11y_packages+=(
beep
brltty
espeak
espeakup
yasr
)
## multimedia package set
minimal_media_packages+=(
alsa-utils
caca-utils
fmtools
hasciicam
imagemagick
jhead
moc
# radio # Not in beowulf. Replaced with fmtools.
sox
)
## misc package set
minimal_misc_packages+=(
cmatrix
cowsay
eject
figlet
fortunes-min
fortune-mod
gpm
man-db
manpages
manpages-dev
mlocate
# termsaver ### not in chimaera
toilet
toilet-fonts
ttyrec
unzip
)
#### TODO: REPLACE twidge (twitter client)
#### ADDED: geoip-bin
#extra_packages+=(
# atmel-firmware
# bluez-firmware
# dahdi-firmware-nonfree
# firmware-amd-graphics
# firmware-ath9k-htc
# firmware-atheros
# firmware-bnx2
# firmware-bnx2x
# firmware-brcm80211
# firmware-cavium
## firmware-crystalhd
# firmware-intel-sound
# firmware-intelwimax
## firmware-ipw2x00 ### These two exist but fail today.
## firmware-ivtv ### ...they require EULA
# firmware-iwlwifi
# firmware-libertas
# firmware-linux-free
# firmware-linux-nonfree
# firmware-myricom
# firmware-netxen
# firmware-qlogic
## firmware-ralink
# firmware-realtek
# firmware-ti-connectivity
# firmware-zd1211
# refractainstaller-base
# refractasnapshot-base
#)
#purge_packages=(
# elinks
# elinks-data
# liberror-perl
# libfsplib0
# libtre5
# openntpd
# tasksel
# tasksel-data
#)
#custom_deb_packages+=(
# memtest86+_5.01-3.1_${arch}.deb
# setnet_0.4+devuan1_all.deb
#)

298
blend_excalibur_config Normal file
View File

@ -0,0 +1,298 @@
#!/usr/bin/env zsh
## configuration file for devuan-desktop-live blend -- Excalibur release
base_packages+=(
lsof
bash-completion
texinfo
acpi-support-base
acpi-fakekey
aptitude
apt-listchanges
debootstrap
discover
dnsutils
doc-debian
docutils-common
docutils-doc
ftp
gettext
gnupg2
gparted
mtd-utils
u-boot-tools
grub-pc-bin
$grubversion
iw
laptop-detect
lvm2
mdadm
mlocate
mutt
ncurses-term
net-tools
netcat-traditional
nfs-common
procmail
reportbug
rfkill
telnet
traceroute
usbutils
util-linux-locales
w3m
whois
)
base_packages+=(
apt-utils
dselect
parted
openssh-server
openssh-client
sudo
alsa-utils
mawk
tmux
tmuxp
screen
ntp
wpasupplicant
wireless-tools
elinks
firmware-linux-free
zsh
rsync
git
strace
)
extra_packages+=(
task-desktop
task-laptop
task-xfce-desktop
fontsnaps
# task-print-server ## no package
popularity-contest
# refractainstaller-base
# refractasnapshot-base
# yad
# refractainstaller-gui
# refractasnapshot-gui
# libgtk3-perl #need to add this for graphical debconf - THIS SUCKS! (buttons off-screen)
gvfs-backends
)
extra_packages+=(
firmware-atheros
firmware-bnx2
firmware-bnx2x
firmware-brcm80211
firmware-iwlwifi
firmware-libertas
firmware-linux-free
firmware-linux-nonfree
firmware-misc-nonfree
firmware-myricom
firmware-netxen
firmware-qlogic
# firmware-ralink # no package
firmware-realtek
firmware-ti-connectivity
firmware-zd1211
)
extra_packages+=(
fonts-quicksand
fonts-liberation
fonts-symbola
xserver-xorg-input-all
xserver-xorg-video-all
anacron
bluetooth
iw
powertop
vim-gtk3
wireless-tools
wpasupplicant
tasksel
xfce4
xfce4-goodies
xfce4-power-manager
xfce4-terminal
atril
dbus-x11
hunspell-en-gb
hyphen-en-gb
mythes-en-us
synaptic
system-config-printer
tango-icon-theme
xsane
enlightenment
terminology
rox-filer
rsync
lsof
gdisk
gnupg-utils
schroot
debootstrap
debhelper
makedev
curl
git
wget
qemu-user-static
build-essential
gcc-arm-none-eabi
gcc-multilib
lib32z1
u-boot-tools
device-tree-compiler
lzop
dosfstools
vboot-utils
vboot-kernel-utils
dpkg-dev
swig
bc
bison
flex
parted
kpartx
qemu-user-static
pinthread
neovim
firmware-atheros
firmware-bnx2
firmware-bnx2x
firmware-brcm80211
firmware-iwlwifi
firmware-libertas
firmware-linux-nonfree
firmware-misc-nonfree
firmware-myricom
firmware-netxen
firmware-qlogic
firmware-realtek
firmware-ti-connectivity
firmware-zd1211
sudo
# yad
# refractainstaller-gui
# refractasnapshot-gui
linux-headers-${arch}
zfs-dkms
zfsutils-linux
avahi-daemon
)
purge_packages=(
# devuan-baseconf
debian-keyring
elinks
elinks-data
# git
# git-core
# git-man
liberror-perl
libfsplib0
libtre5
# openntpd
# openssh-server
# openssh-sftp-server
# tmux
# zsh
# zsh-common
# intel-microcode
# iucode-tool
# amd64-microcode
)
purge_packages+=(
auditd
cups-browsed
gvfs-daemons
pulseaudio
pulseaudio-utils
libpulsedsp
xscreensaver
xscreensaver-data
packagekit
packagekit-tools
)
custom_deb_packages+=(
)
custom_scripts+=(
001_apt_get-selections.sh
001_apt-group.sh
001_apt-parallel_on.sh
001_apt-preferences.sh
001_apt-proxy_off.sh
001_apt-proxy_on.sh
001_apt-sources.sh
001_apt_suggests-recommends.sh
001_apt-verbose-versions.sh
001_docker_grub-commandline.sh
001_enable-binfmt-misc.sh
001_grub_gfxmode.sh
001_locales.sh
001_prevent_udev_net-rename.sh
# 001_resolvconf.sh
020_connman.sh
001_ssh.sh
001_swap-caps.sh
001_system_bell.sh
001_udev-rules.sh
001_virtual-mem.sh
010_sysctl.sh
010_generate-ssh.sh
010_apt-get.sh
001_system_bell.sh
010_saltstack.sh
020_console.sh
020_zsh_quickstart.sh
020_zsh_aliases.d.sh
020_lsd.sh
020_grc.sh
010_alsa.sh
020_conky.sh
020_djmount.sh
029_yarn.sh
020_vim.sh
020_meld.sh
020_themes.sh
020_audacity.sh
020_powerline-bash.sh
020_fonts.sh
020_nanorc.sh
020_neovim.sh
020_mutt-wizard.sh
020_mutt-notmuch.sh
020_mutt-khard.sh
020_shellcheck.sh
020_neofetch_motd.sh
020_tmux.sh
020_rox-filer.sh
020_hexchat.sh
020_pidgin.sh
020_brave_browser.sh
# 020_slim.sh
020_lightdm.sh
020_docker.sh
020_docker-compose_checkinstall.sh
050_remove_xscreensaver.sh
)

326
blend_freia-docker_config Normal file
View File

@ -0,0 +1,326 @@
#!/usr/bin/env zsh
# shellcheck shell=bash
## configuration file for devuan-minimal-docker blend -- Chimaera release
# -o options to apt-get install.
# APT::Get::Mark-Auto=true
# APT::Get::AllowUnauthenticated=true
# Dpkg::Progress and Dpkg::Progress-Fancy=true
#
# The following would be useful if pulling old releases
#core_packages_option(-o Acquire::Check-Valid-Until=false -o Acquire::AllowReleaseInfoChange=true)
#base_packages_option(-o Acquire::Check-Valid-Until=false -o Acquire::AllowReleaseInfoChange=true)
#extra_packages_option(-o Acquire::Check-Valid-Until=false -o Acquire::AllowReleaseInfoChange=true)
# Override base_packages and core_packages from: lib/libdevuansdk/config
core_packages=()
base_packages=()
extra_packages=()
# these are the differences between debian and devuan slim images that are not in 'required'.
# If they are in /usr/share/debootstrap/scripts/ceres it doesn't have to be here.
# devuan_required="devuan-keyring sysvinit-core"
#
base_packages=(
bootlogd
innserv
eudev
)
# bootstrap_stage4
extra_packages=(
vim-tiny
)
### now we include all the package sets
#base_packages+=(
# $minimal_base_packages
# $minimal_admin_packages
# $minimal_editors_packages
# $minimal_net_packages
# $minimal_prod_packages
# $minimal_devel_packages
# $minimal_games_packages
# $minimal_a11y_packages
# $minimal_media_packages
# $minimal_misc_packages
#)
##
## definition of package sets
##
### base package set
minimal_base_packages+=(
acpi
acpi-support-base
acpid
acpi-fakekey
at
bash
bash-completion
bc
busybox
console-common
console-data
console-setup
console-setup-linux
coreutils
dash
dc
dialog
discover
dselect
file
groff-base
$grubversion
info
kbd
laptop-detect
locales
lsof
syslinux
util-linux-locales
zsh
)
## admin package set
minimal_admin_packages+=(
cryptsetup
cryptsetup-bin
debootstrap
dosfstools
entr
gddrescue
gdisk
htop
iftop
iotop
iw
lvm2
mdadm
mtr-tiny
multitail
ncdu
parted
pciutils
psmisc
sudo
time
usbutils
wavemon
wireless-tools
wpasupplicant
)
## editors package set
minimal_editors_packages+=(
ed
nano
vim-tiny
zile
)
## networking package set
minimal_net_packages+=(
bind9-host
# bittornado ### not in chimaera
ceni
curl
dnsutils
edbrowse
fetchmail
ftp
geoip-bin
haveged
irssi
lftp
links2
lrzsz
mcabber
minicom
mosh
msmtp
mutt
netcat
net-tools
nfacct
# nrss # not in beowulf. Use rsstail instead.
openssh-client
openssh-server
procmail
rfkill
rsstail
rsync
# setnet # use ascii deb package for beowulf and chimaera
telnet
traceroute
transmission-cli
w3m
wget
whois
)
## productivity package set
minimal_prod_packages+=(
abook
apcalc
aspell
aspell-en
calcurse
clex
dvtm
fbi
fbterm
ghostscript
gnupg
gnupg2
gnupg-agent
mc
parallel
poppler-utils
rpl
rename
sc
screen
taskwarrior
tmux
)
## programming package set
minimal_devel_packages+=(
tcc
libc6-dev
m4
patch
perl
perl-base
perl-modules-5.36
python3.11-minimal
gawk
guile-3.0
guile-3.0-libs
)
## games package set
# minimal_games_packages+=(
# bastet
# bombardier
# bsdgames
# cavezofphear
# crawl
# curseofwar
# empire
# freesweep
# gnuchess
# greed
# matanza
# moria
# nethack-console
# ninvaders
# omega-rpg
# pacman4console
# pente
# sudoku
# )
## accessibility package set
minimal_a11y_packages+=(
beep
brltty
espeak
espeakup
yasr
)
## multimedia package set
minimal_media_packages+=(
alsa-utils
caca-utils
fmtools
hasciicam
imagemagick
jhead
moc
# radio # Not in beowulf. Replaced with fmtools.
sox
)
## misc package set
minimal_misc_packages+=(
cmatrix
cowsay
eject
figlet
fortunes-min
fortune-mod
gpm
man-db
manpages
manpages-dev
mlocate
# termsaver ### not in chimaera
toilet
toilet-fonts
ttyrec
unzip
)
#### TODO: REPLACE twidge (twitter client)
#### ADDED: geoip-bin
#extra_packages+=(
# atmel-firmware
# bluez-firmware
# dahdi-firmware-nonfree
# firmware-amd-graphics
# firmware-ath9k-htc
# firmware-atheros
# firmware-bnx2
# firmware-bnx2x
# firmware-brcm80211
# firmware-cavium
## firmware-crystalhd
# firmware-intel-sound
# firmware-intelwimax
## firmware-ipw2x00 ### These two exist but fail today.
## firmware-ivtv ### ...they require EULA
# firmware-iwlwifi
# firmware-libertas
# firmware-linux-free
# firmware-linux-nonfree
# firmware-myricom
# firmware-netxen
# firmware-qlogic
## firmware-ralink
# firmware-realtek
# firmware-ti-connectivity
# firmware-zd1211
# refractainstaller-base
# refractasnapshot-base
#)
#purge_packages=(
# elinks
# elinks-data
# liberror-perl
# libfsplib0
# libtre5
# openntpd
# tasksel
# tasksel-data
#)
#custom_deb_packages+=(
# memtest86+_5.01-3.1_${arch}.deb
# setnet_0.4+devuan1_all.deb
#)

299
blend_freia_config Normal file
View File

@ -0,0 +1,299 @@
#!/usr/bin/env zsh
## configuration file for devuan-desktop-live blend -- Freia release
base_packages+=(
lsof
bash-completion
texinfo
acpi-support-base
acpi-fakekey
aptitude
apt-listchanges
debootstrap
discover
dnsutils
doc-debian
docutils-common
docutils-doc
ftp
gettext
gnupg2
gparted
mtd-utils
u-boot-tools
grub-pc-bin
$grubversion
iw
laptop-detect
lvm2
mdadm
mlocate
mutt
ncurses-term
net-tools
netcat-traditional
nfs-common
procmail
reportbug
rfkill
telnet
traceroute
usbutils
util-linux-locales
w3m
whois
)
base_packages+=(
apt-utils
dselect
parted
openssh-server
openssh-client
sudo
alsa-utils
alsa-ucm-conf
mawk
tmux
tmuxp
screen
ntp
wpasupplicant
wireless-tools
elinks
firmware-linux-free
zsh
rsync
git
strace
)
extra_packages+=(
task-desktop
task-laptop
task-xfce-desktop
fontsnaps
# task-print-server ## no package
popularity-contest
# refractainstaller-base
# refractasnapshot-base
# yad
# refractainstaller-gui
# refractasnapshot-gui
# libgtk3-perl #need to add this for graphical debconf - THIS SUCKS! (buttons off-screen)
gvfs-backends
)
extra_packages+=(
firmware-atheros
firmware-bnx2
firmware-bnx2x
firmware-brcm80211
firmware-iwlwifi
firmware-libertas
firmware-linux-free
firmware-linux-nonfree
firmware-misc-nonfree
firmware-myricom
firmware-netxen
firmware-qlogic
# firmware-ralink # no package
firmware-realtek
firmware-ti-connectivity
firmware-zd1211
)
extra_packages+=(
fonts-quicksand
fonts-liberation
fonts-symbola
xserver-xorg-input-all
xserver-xorg-video-all
anacron
bluetooth
iw
powertop
vim-gtk3
wireless-tools
wpasupplicant
tasksel
xfce4
xfce4-goodies
xfce4-power-manager
xfce4-terminal
atril
dbus-x11
hunspell-en-gb
hyphen-en-gb
mythes-en-us
synaptic
system-config-printer
tango-icon-theme
xsane
enlightenment
terminology
rox-filer
rsync
lsof
gdisk
gnupg-utils
schroot
debootstrap
debhelper
makedev
curl
git
wget
qemu-user-static
build-essential
gcc-arm-none-eabi
gcc-multilib
lib32z1
u-boot-tools
device-tree-compiler
lzop
dosfstools
vboot-utils
vboot-kernel-utils
dpkg-dev
swig
bc
bison
flex
parted
kpartx
qemu-user-static
pinthread
neovim
firmware-atheros
firmware-bnx2
firmware-bnx2x
firmware-brcm80211
firmware-iwlwifi
firmware-libertas
firmware-linux-nonfree
firmware-misc-nonfree
firmware-myricom
firmware-netxen
firmware-qlogic
firmware-realtek
firmware-ti-connectivity
firmware-zd1211
sudo
# yad
# refractainstaller-gui
# refractasnapshot-gui
linux-headers-${arch}
zfs-dkms
zfsutils-linux
avahi-daemon
)
purge_packages=(
# devuan-baseconf
debian-keyring
elinks
elinks-data
# git
# git-core
# git-man
liberror-perl
libfsplib0
libtre5
# openntpd
# openssh-server
# openssh-sftp-server
# tmux
# zsh
# zsh-common
# intel-microcode
# iucode-tool
# amd64-microcode
)
purge_packages+=(
auditd
cups-browsed
gvfs-daemons
pulseaudio
pulseaudio-utils
libpulsedsp
xscreensaver
xscreensaver-data
packagekit
packagekit-tools
)
custom_deb_packages+=(
)
custom_scripts+=(
001_apt_get-selections.sh
001_apt-group.sh
001_apt-parallel_on.sh
001_apt-preferences.sh
001_apt-proxy_off.sh
001_apt-proxy_on.sh
001_apt-sources.sh
001_apt_suggests-recommends.sh
001_apt-verbose-versions.sh
001_docker_grub-commandline.sh
001_enable-binfmt-misc.sh
001_grub_gfxmode.sh
001_locales.sh
001_prevent_udev_net-rename.sh
# 001_resolvconf.sh
020_connman.sh
001_ssh.sh
001_swap-caps.sh
001_system_bell.sh
001_udev-rules.sh
001_virtual-mem.sh
010_sysctl.sh
010_generate-ssh.sh
010_apt-get.sh
001_system_bell.sh
010_saltstack.sh
020_console.sh
020_zsh_quickstart.sh
020_zsh_aliases.d.sh
020_lsd.sh
020_grc.sh
010_alsa.sh
020_conky.sh
020_djmount.sh
029_yarn.sh
020_vim.sh
020_meld.sh
020_themes.sh
020_audacity.sh
020_powerline-bash.sh
020_fonts.sh
020_nanorc.sh
020_neovim.sh
020_mutt-wizard.sh
020_mutt-notmuch.sh
020_mutt-khard.sh
020_shellcheck.sh
020_neofetch_motd.sh
020_tmux.sh
020_rox-filer.sh
020_hexchat.sh
020_pidgin.sh
020_brave_browser.sh
# 020_slim.sh
020_lightdm.sh
020_docker.sh
020_docker-compose_checkinstall.sh
050_remove_xscreensaver.sh
)

View File

@ -21,6 +21,8 @@ build_metal_dist() {
req=(arch)
req+=(workdir strapdir disk_name)
ckreq || return 1
notice "installing complete dist"
act "add release symlink to debootstrap scripts."
if [[ ! -f /usr/share/debootstrap/scripts/${release} ]]; then
ln -sf /usr/share/debootstrap/scripts/ceres \
@ -34,6 +36,31 @@ build_metal_dist() {
blend_postinst || { zerr; wrapup }
}
build_image_dist() {
fn build_image_dist
req=(arch size parted_type)
case "$parted_type" in
gpt) req+=(gpt_boot gpt_root) ;;
dos) req+=(parted_boot parted_root) ;;
*) die "Unknown parted_type: $parted_type. Supported is gpt|dos."
zerr; return 1
;;
esac
req+=(workdir strapdir image_name)
ckreq || return 1
notice "building complete dist image"
act "$image_name"
bootstrap_complete_base || { zerr; wrapup }
blend_preinst || { zerr; wrapup }
image_prepare_raw || { zerr; wrapup }
image_partition_raw_${parted_type} || { zerr; wrapup }
build_kernel_${arch} || { zerr; wrapup }
blend_postinst || { zerr; wrapup }
rsync_to_raw_image || { zerr; wrapup }
image_pack_dist || { zerr; wrapup }
}
build_arm_dist()
{
@ -41,7 +68,7 @@ build_arm_dist()
req=(workdir strapdir os arch size parted_type)
case "$parted_type" in
gpt) req+=(gpt_boot gpt_root) ;;
dos) req+=(dos_boot dos_root) ;;
dos) req+=(parted_boot parted_root) ;;
*) die "Unknown parted_type: $parted_type. Supported is gpt|dos."
zerr; return 1
;;
@ -54,7 +81,7 @@ build_arm_dist()
blend_preinst || { zerr; return 1; }
image_prepare_raw || { zerr; return 1; }
image_connect_raw || { zerr; return 1; }
image_partition_${parted_type} || { zerr; return 1; }
image_partition_raw_${parted_type} || { zerr; return 1; }
image_format_partitions || { zerr; return 1; }
build_kernel_${arch} || { zerr; return 1; }
image_mount || { zerr; return 1; }
@ -67,7 +94,27 @@ build_arm_dist()
}
# Overide the post 'debootstrap stage 2' placeholder function of zlib/debootstrap bootstrap_complete_base.
copy-root-overlay() {
fn copy-root-overlay "(override)"
req=(strapdir device_name bootpart_partuuid R)
ckreq || return 1
[[ -d $R/extra/generic-root ]] &&
notice "copying generic-root" && \
sudo cp -rfv $R/extra/generic-root/* $strapdir
sudo sed -e "s/{{{BOOTFS}}}/$bootfs/" -i "$strapdir/etc/fstab"
sudo sed -e "s/\/dev\/mmcblk0p1/PARTUUID=$bootpart_partuuid/" -i "$strapdir/etc/fstab"
[[ -d $R/extra/$device_name ]] && \
notice "copying ${device_name}-root" && \
sudo cp -rfv $R/extra/$device_name/* $strapdir
return 0
}
# Overide the post 'debootstrap stage 2' placeholder function of zlib/debootstrap
# bootstrap_complete_base.
# The default is just to return 0
blend_bootstrap_setup() {
fn blend_bootstrap_setup "noop"
@ -75,20 +122,73 @@ blend_bootstrap_setup() {
}
# the local bootstrap wrapper just adds an options variable
# via an alias to the debootstrap command
# the local bootstrap wrapper just adds an options variable
# via an alias to the debootstrap command
bootstrap_complete_base-wrapper() {
mkdir -p "$debootstrap_cache"
alias debootstrap='debootstrap \
--cache-dir="$debootstrap_cache" \
--exclude="$purge_packages" \
${bootstrap_options}'
--exclude="$debootstrap_purge_packages" \
${debootstrap_options}'
bootstrap_complete_base
}
image_partition_raw_gpt() {
fn image_partition_raw_gpt
req=(workdir image_name gpt_boot gpt_root bootpart_partuuid rootpart_partuuid)
ckreq || return 1
notice "partitioning raw gpt image..."
notice "workdir: $workdir"
notice "image_name: $image_name"
notice "gpt_boot: $gpt_boot"
notice "gpt_root: $gpt_root"
parted $workdir/${image_name}.img --script -- mklabel gpt || zerr
cgpt repair $workdir/${image_name}.img
cgpt create -z $workdir/${image_name}.img || zerr
cgpt create $workdir/${image_name}.img || zerr
notice 'cgpt add -i 1 -t kernel -b ${gpt_boot[1]} \
-s ${gpt_boot[2]} \
-l kernel -S 1 -T 5 -P 10 $workdir/${image_name}.img'
notice "cgpt add -i 1 -t kernel -b ${gpt_boot[1]} \
-s ${gpt_boot[2]} \
-l kernel -S 1 -T 5 -P 10 $workdir/${image_name}.img"
cgpt add -i 1 -t kernel -b ${gpt_boot[1]} \
-s ${gpt_boot[2]} \
-l kernel -S 1 -T 5 -P 10 $workdir/${image_name}.img
notice 'cgpt add -i 2 -t data -b ${gpt_root[1]} \
-s $(expr $(cgpt show $workdir/${image_name}.img | \
awk "/Sec GPT table/ {print $1}") - ${gpt_root[1]}) \
-l Root $workdir/${image_name}.img'
notice "cgpt add -i 2 -t data -b ${gpt_root[1]} \
-s $(expr $(cgpt show $workdir/${image_name}.img | \
awk '/Sec GPT table/ {print $1}') - ${gpt_root[1]}) \
-l Root $workdir/${image_name}.img"
cgpt add -i 2 -t data -b ${gpt_root[1]} \
-s $(expr $(cgpt show $workdir/${image_name}.img | \
awk '/Sec GPT table/ {print $1}') - ${gpt_root[1]}) \
-l Root $workdir/${image_name}.img
findloopdev
bootpart="${loopdevice}p1"
rootpart="${loopdevice}p2"
bootpart_partuuid=$(blkid -s PARTUUID -o value ${bootpart})
rootpart_partuuid=$(blkid -s PARTUUID -o value ${rootpart})
image_format_partitions
}
## Override the helper function:
# takes the 'apt-get -f' out of the loop so that dependency provided by other debs can be resolved.
# takes the 'apt-get -f' out of the loop so that dependency provided by other
# debs can be resolved.
# inside the loop it just uninstalls the deb because of unfullfilled deps.
install-custdebs() {
fn install-custdebs "(override)"
@ -113,10 +213,12 @@ install-custdebs() {
}
## Added function:
# In the style of install-custdebs above but for a collection of arbitrary scripts placed in a
# directory alongside the blend custom debs called automate.
# The scripts are copied from the blends scripts directory to extra/custom-scripts in blend_preinst() above.
# Called after install-customdebs because some need checkinstall which disappears from archives.
# In the style of install-custdebs above but for a collection of arbitrary
# scripts placed in a # directory alongside the blend custom debs called automate.
# The scripts are copied from the blends scripts directory to extra/custom-scripts
# in blend_preinst() above.
# Called after install-customdebs because some need checkinstall which disappears
# from archives.
install-custscripts() {
fn install-custscripts
req=(R strapdir custom_scripts)
@ -140,29 +242,51 @@ install-custscripts() {
chroot-script -d install-scripts
}
## Override the helper function:
# Allow an alternative skel directory
add-user() {
fn add-user $*
local user="$1"
local pass="$2"
local skel="$3"
req=(strapdir user pass skel)
copy-kernel-config() {
fn copy-kernel-config "(override)"
req=(device_name gitbranch)
ckreq || return 1
notice "adding user $user:$pass using $skel"
notice "copying available ${gitbranch} kernel config for ${device_name}"
notice "cp -f $R/boards/kernel-configs/${device_name}.config_${gitbranch} \
$R/tmp/kernels/$device_name/${device_name}-linux_$gitbranch/.config"
cp -f $R/boards/kernel-configs/${device_name}.config_${gitbranch} \
$R/tmp/kernels/$device_name/${device_name}-linux_$gitbranch/.config
}
cat <<-EOF | sudo tee ${strapdir}/adduser >/dev/null
## Override the helper function:
# Allow an alternative skel directory, defaults to /etc/skel
add-user() {
fn add-user
req=(strapdir username userpass user_shell)
ckreq || return 1
notice "adding user $user:$pass using $skel and shell $default_shell"
cat <<-EOF | sudo tee ${strapdir}/add-user >/dev/null
#!/bin/sh
set -x
if [ $(id -u ${user} 2>&1 >/dev/null) ]; then
if [ $(id -u ${username} 2>&1 >/dev/null) ]; then
echo "user not present, creating account."
useradd -m ${user} -k ${userskel:-/etc/skel}
echo "${user}:${pass}" | chpasswd
sudo useradd --create-home \
--shell $usershell \
--groups $usergroups \
--password $(openssl passwd -1 $userpass) \
--skel ${user_skel:-/etc/skel} \
$username
echo "${username}:${userpass}" | chpasswd
usermod -a -G ${user_groups} ${username}
if grep -q "${user_shell}" /etc/shells; then
usermod --shell "${user_shell}" "${username}"
else
echo "${user_shell} is not available, leaving unchanged."
fi
fi
EOF
chroot-script adduser || { zerr; return 0; }
chroot-script add-user || { zerr; return 0; }
}
@ -286,7 +410,7 @@ image_partition_disk_zfs() {
# See: https://didrocks.fr/2020/06/11/zfs-focus-on-ubuntu-20.04-lts-zsys-partition-layout/
for disk in "${available_disks[@]}"; do
TARGET="/dev/disk/by-id/${disk}"
local TARGET="/dev/disk/by-id/${disk}"
act "partitioning ${TARGET}"
/sbin/sgdisk --zap-all ${TARGET}
@ -319,7 +443,12 @@ image_partition_disk_zfs() {
act "Reread the current partition tables with partprobe."
# the second drive fails to update the kernel until reboot so added 2>
partprobe ${TARGET} 2>/dev/null || true
#partx --update ${TARGET}
#kpartx -a ${TARGET}
#hdparm -z ${TARGET}
#blockdev --rereadept ${TARGET}
#udevadm trigger --subsystem-match=block; udevadm settle --exit-if-exists=/dev/${TARGET}-part5
#echo 1 > /sys/block/sdX/device/rescan
done
}
@ -342,11 +471,11 @@ image_format_partitions_zfs() {
notice "formatting zfs partitions..."
for disk in "${available_disks[@]}"; do
gdisk -l /dev/disk/by-id/${disk}
done
# for disk in "${available_disks[@]}"; do
# gdisk -l /dev/disk/by-id/${disk}
# done
act "udev is slow recognize new partition so trigger sleep for 10 seconds"
act "udev is slow recognizing new partitions so trigger sleep for 10 seconds"
sleep 10
@ -381,8 +510,8 @@ image_format_partitions_zfs() {
-O normalization=formD \
-O relatime=on \
-O xattr=sa \
-O mountpoint=/boot -o altroot=${strapdir} \
${bpool_name} ${raid} /dev/disk/by-id/${disk_name}-part${boot_part_number} ${mirror_disk}
-O mountpoint=legacy -o altroot=${strapdir} \
${bpool_name} ${raid} /dev/disk/by-id/${disk_name}-part${boot_part_number} /dev/disk/by-id/${mirror_disk}-part${boot_part_number}
act "create the zfs root pool"
@ -398,20 +527,20 @@ image_format_partitions_zfs() {
-O relatime=on \
-O xattr=sa \
-O mountpoint=/ -o altroot=${strapdir} \
${rpool_name} ${raid} /dev/disk/by-id/${disk_name}-part${root_part_number} ${mirror_disk}
${rpool_name} ${raid} /dev/disk/by-id/${disk_name}-part${root_part_number} /dev/disk/by-id/${mirror_disk}-part${root_part_number}
## Physical swap used instead.
#act "create the zfs zvol for swap"
#zfs create -V ${swap_part_size} -b $(getconf PAGESIZE) \
# -o compression=zle \
# -o logbias=throughput \
# -o sync=always \
# -o primarycache=metadata \
# -o secondarycache=none \
# -o com.sun:auto-snapshot=false \
# ${rpool_name}/swap
#mkswap -f -L "Linux swap" /dev/zvol/${rpool_name}/swap
# act "create the zfs zvol for swap"
# zfs create -V ${swap_part_size} -b $(getconf PAGESIZE) \
# -o compression=zle \
# -o logbias=throughput \
# -o sync=always \
# -o primarycache=metadata \
# -o secondarycache=none \
# -o com.sun:auto-snapshot=false \
# ${rpool_name}/swap
# mkswap -f -L "Linux swap" /dev/zvol/${rpool_name}/swap
notice "zfs system installation"
act "create filesystem datasets to act as containers"
@ -426,8 +555,8 @@ image_format_partitions_zfs() {
#zfs create -o canmount=noauto -o mountpoint=/boot ${bpool_name}/BOOT/${root_name}
zfs create -o mountpoint=/boot ${bpool_name}/BOOT/${root_name}
# At this point rpool directory is created in the workdir
#zfs set mountpoint=/${rpool_name} ${rpool_name}
## At this point rpool directory is created in the workdir
# zfs set mountpoint=/${rpool_name} ${rpool_name}
TMP_EXEC_STATE=on
VAR_TMP_EXEC_STATE=on
@ -489,6 +618,7 @@ image_format_partitions_zfs() {
#chmod 1777 ${strapdir}/var/tmp
act "mount the efi partition on ${grub_mount} before debootstrap."
mkdir -p ${strapdir}${grub_mount}
mount /dev/disk/by-id/${disk_name}-part${efi_part_number} -t vfat ${strapdir}${grub_mount}
act "create zpool cache file"
@ -688,7 +818,7 @@ enablessh() {
#!/usr/bin/env zsh
set -x ; exec 2>${PWD}/enablessh.log
config_file="/tmp/sshd_config"
config_file="/etc/ssh/sshd_config"
typeset -A rules
rules=(
@ -840,8 +970,12 @@ install_grub(){
act "write grub-efi to available efi partitions."
for efi_partition in "${efi_partitions[@]}"; do
notice "writing to efi partitions: ${efi_partitions}"
act "mount the primary disks efi partition under ${grub_mount}"
mount ${disk_path}/${disk_name}-part${efi_part_number} ${strapdir}${grub_mount}
if ! /bin/mountpoint -q "${strapdir}${grub_mount}"; then
act "mount the primary disks efi partition under ${grub_mount}"
mount ${disk_path}/${disk_name}-part${efi_part_number} ${strapdir}${grub_mount}
else
notice "the mountpoint ${grub_mount} already in use. Skipping mount operation."
fi
cat <<-EOF | sudo tee ${strapdir}/update-grub_${disk_name} > /dev/null
#!/bin/sh
@ -862,10 +996,15 @@ install_grub(){
done
else
mkdir -p ${grub_mount}
for disk_name in "${available_disks[@]}"; do
notice "writing grub to available disks:"
act "mount the primary disks efi partition under ${grub_mount}"
mount ${disk_path}/${disk_name}-part${efi_part_number} ${strapdir}${grub_mount}
act "write grub to available efi partitions."
for disk_name in "${available_disks[@]}"; do
notice "writing grub to available ${disk_name}:"
if ! /bin/mountpoint -q "${strapdir}${grub_mount}"; then
act "mount the primary disks efi partition under ${grub_mount}"
mount ${disk_path}/${disk_name}-part${efi_part_number} ${strapdir}${grub_mount}
else
notice "The mount point ${grub_mount} is already in use. Skipping mount operation."
fi
cat <<-EOF | sudo tee ${strapdir}/update-grub_${disk_name} > /dev/null
#!/bin/sh
@ -1002,6 +1141,7 @@ build_uboot(){
artifact=u-boot
notice "Build u-boot"
"FIXME: AUTOBOOT was too chatty at the configure stage with these entries do its disabled for now."
git clone --depth 1 "$ubootgit" -b "$uboot_branch" "$R/tmp/kernels/u-boot-rockpro64" || zer
pushd "$R/tmp/kernels/u-boot-rockpro64"
make mrproper
@ -1011,8 +1151,6 @@ build_uboot(){
--enable CONFIG_CMD_ZFS \
--enable CONFIG_CMD_BOOTMENU \
--enable CONFIG_MENU \
--enable CONFIG_AUTOBOOT_KEYED \
--set-val CONFIG_BOOTDELAY 30 \
--enable CONFIG_MENU_SHOW \
--enable CONFIG_CFB_CONSOLE_ANSI \
--enable CONFIG_CMD_BOOTEFI \
@ -1024,18 +1162,19 @@ build_uboot(){
--enable CONFIG_BOOTM_NETBSD \
--enable CONFIG_BLK \
--enable CONFIG_VERSION_VARIABLE \
--enable CONFIG_PARTITIONS
--enable CONFIG_PARTITIONS \
--enable CONFIG_DM_VIDEO
#--enable CONFIG_AUTOBOOT_KEYED \
#--set-val CONFIG_BOOTDELAY 30
act "apply sigmaris changes to defconfig."
"$R/tmp/kernels/rockpro64/rockpro64-linux/scripts/config" --file .config \
--set-val CONFIG_DEFAULT_DEVICE_TREE "rk3399-rockpro64" \
--enable CONFIG_OF_BOARD_SETUP \
--enable CONFIG_MTD \
--enable CONFIG_SPI_FLASH_MTD \
--enable CONFIG_CMD_MTDPARTS \
--set-val CONFIG_MTDIDS_DEFAULT "nor0=spi0.0" \
--set-val CONFIG_MTDPARTS_DEFAULT="mtdparts=spi0.0:384k(u-boot-spl),3680k(u-boot),32k(u-boot-env),-(user)" \
--enable CONFIG_SPL_SPI_SUPPORT \
--enable CONFIG_SPL_MMC \
--enable CONFIG_SPL_SPI \
--enable CONFIG_SPI_FLASH_MTD \
--enable CONFIG_SPL_SPI_FLASH_SUPPORT \
--enable CONFIG_NVME \
--enable CONFIG_SCSI \
@ -1043,13 +1182,16 @@ build_uboot(){
--enable CONFIG_OF_LIBFDT_OVERLAY \
--enable CONFIG_FDT_FIXUP_PARTITIONS \
--enable CONFIG_SERVERIP_FROM_PROXYDHCP \
--set-val CONFIG_SERVERIP_FROM_PROXYDHCP_DELAY_MS 100 \
--enable CONFIG_AHCI \
--enable CONFIG_SCSI_AHCI \
--enable CONFIG_AHCI_PCI \
--enable CONFIG_DM_KEYBOARD \
--enable CONFIG_LED \
--enable CONFIG_LED_GPIO
--enable CONFIG_LED_GPIO \
--set-val CONFIG_DEFAULT_DEVICE_TREE "rk3399-rockpro64" \
--set-val CONFIG_SERVERIP_FROM_PROXYDHCP_DELAY_MS 100 \
--set-val CONFIG_MTDIDS_DEFAULT "nor0=spi0.0" \
--set-val CONFIG_MTDPARTS_DEFAULT="mtdparts=spi0.0:384k(u-boot-spl),3680k(u-boot),32k(u-boot-env),-(user)"
make -j$(nproc) $MAKEOPTS ARCH=arm CROSS_COMPILE=$compiler || zerr
@ -1198,7 +1340,7 @@ bootloader-version(){
req=(strapdir)
ckreq || return 1
# FIXME: Assumes partitions numbers
# FIXME: Assumes partitions number p1 or p6 and uses p1 for both
version() {
local DEVICE="${1/p6/p1}"
@ -1223,8 +1365,8 @@ upgrade-sd-bootloader(){
notice "Upgrading pre-existing bootloader."
# FIXME:
# extlinux, u-boot, grub, EFI
# Assumes a mounted efi partion
# Writes the rksd image only to a specific partition number on sd devices.
# Assumes u-boot written to a mounted efi partion
# Writes the rksd image only to a specific partition number on sd devices. Uses p1
if [[ $(findmnt -M /boot/efi) ]]; then
MNT_DEV=$(findmnt /boot/efi -n -o SOURCE)
else
@ -1234,7 +1376,7 @@ upgrade-sd-bootloader(){
# report current version
#bootloader-version "$MNT_DEV"
bootloader-version "$MNT_DEV"
write_sd() {
case "$1" in
@ -1260,7 +1402,7 @@ erase-sd-bootloader(){
ckreq || return 1
notice "Erasing pre-existing bootloader."
# FIXME: Writes/erases a specific partition number on sd devices.
# FIXME: Writes/erases a specific partition number on sd devices. Uses p1
MNT_DEV=$(findmnt /boot/efi -n -o SOURCE)
# report current version
@ -1333,7 +1475,7 @@ erase-spi-flash(){
# mtd1: 00398000 00001000 "u-boot"
# mtd2: 00008000 00001000 "u-boot-env"
# mtd3: 00c00000 00001000 "user"
#
if ! MTD=$(grep \"loader\" /proc/mtd | cut -d: -f1); then
echo "loader partition on MTD is not found"
return 1
@ -1370,12 +1512,14 @@ write-spi-flash(){
}
# u-boot menu has been deprecated, extlinux.conf is used instead and uutomatically
# updated with u-boot-update from u-boot-menu. see ARM-sdk/BOARDs/rockpro64-ayunfan.
create-u-boot-menu(){
fn create-u-boot-menu
req=(strapdir)
ckreq || return 1
# FIXME: Need to chosse a default and fix the other calls
# FIXME: Need to choose a default and fix the other calls
cat <<-EOF | tee scripts/boot.cmd > /dev/null
setenv bootmenu_0 Boot 1. kernel=bootm 0x82000000 # Set first menu entry
setenv bootmenu_1 Boot 2. kernel=bootm 0x83000000 # Set second menu entry

View File

@ -8,10 +8,19 @@ additional or overridden helper functions to add or test functionality or workar
specific to the blend to avoid changes to the sdk.
## build_arm_dist()
defines the sequence of calls that will result in an SDcard image with gpt partition table and u-boot.
* partition_type, gpt_boot and gpt_root must be set to gpt, and the boot and root size respectively in the blend
- partition_type=gpt
- gpt_boot=
- gpt_root=
## build_metal_dist()
defines the sequence of calls that will result in a devuan install with root and boot zfs to one or two disks (mirrored)
using either grub-pc or grub-efi to boot.
## image_partition_raw_gpt()
a partitioning function using cgpt to produce gpt partition table rather than parted to product dos partion table.
## blend_bootstrap_setup()
* Overide the post 'debootstrap stage 2' placeholder function of zlib/debootstrap bootstrap_complete_base.
@ -35,7 +44,7 @@ Override the helper function:
Added function:
* In the style of install-custdebs above but for a collection of arbitrary scripts placed in a
* directory alongside the blend custom debs called automate.
* The scripts are copied from the blends scripts directory to extra/custom-scripts in blend_preinst() above.
* The scripts are copied from the blends scripts directory ${blend_scripts} to $R/extra/custom-scripts in blend_preinst() above.
* Called after install-customdebs because some need checkinstall which disappears from archives.
## add-user()
@ -80,7 +89,9 @@ uses three files to replicate the installed packages of another system.
* /var/tmp/pkgs_manual.lst
## enablessh()
this function will allow a root or user login in the bootstrapped root using:
FIXME: currently changes /etc/ssh/ssh_config to allow password access.
Change this function will allow a root or user login in the bootstrapped root using:
* ssh-copy-id default@192.168.1.x
@ -137,20 +148,79 @@ with:
u-boot.itb
from $R/tmp/kernels/u-boot-rockpro64 to producing flash-spi.img.gz
## copy-kernel-config() override
extend the function to accept a kernel config name that includes a version not just device_name
## copy-root-overlay() override
re-write fstab to use PARTUUID as kernel does not guarantee the order of discovery and it is known to change between kernel versions.
We set boot_partuuid in image_partition_raw_${parted_type}
## set-bootloader()
Change SPI_LOADER to rksip or rksd depending on board. Called with -rockchip-rockpro64- sets the variable SD_LOADER, SPI_LOADER and BOARD to values consistant for the board, other boards: rock64, pinebookpro and rockpi4b
## bootloader-version()
FIXME
https://stackoverflow.com/questions/5781738/getting-u-boots-version-from-userspace
There's no defined way to do this. Once Linux boots, u-boot is no longer running and it's RAM is reclaimed for Linux's use. Linux doesn't even know about u-boot. Nor does it have to have been booted by u-boot.
If you really want to do this, the only way to do it is to add the u-boot version to the kernel's command line, write code to scan the u-boot image in flash for it's version, or if u-boot is still a mounted partition then you can extract this info from it with strings.
u-boot-tools packages fw_printenv in debian returns ver:
fw_printenv just looks for the printenv partition and dumps its data. So it's OK for normal variables, but it's not OK for the "ver" variable, which is dynamic, and whose value is initialized by u-boot when it boots. The value of this variable doesn't remain after u-boot exit, except if you manually save it to environment.
U-Boot > printenv ver
ver=U-Boot 2009.11-00393-g5ca9497-dirty (Nov 26 2012 - 11:08:44)
$ fw_printenv | grep ver=
ver=U-Boot 2009.11-00323-gbcc6e0e (Sep 21 2012 - 11:07:19)
U-Boot > saveenv
$ fw_printenv | grep ver=
ver=U-Boot 2009.11-00393-g5ca9497-dirty (Nov 26 2012 - 11:08:44)
So running the a u-boot script with saveenv prior to booting the kernel will set the ver properly in /boot/uboot.env:
https://stackoverflow.com/questions/67974867/fw-printenv-not-showing-env-variables-from-uboot-env
Find uboot partition, eg. for MTD device:
$ cat /proc/mtd
For /dev/mtd5:
$ cat /dev/mtd5 | hexdump -C -n 64
$ strings /dev/mtd0 | grep 'U-Boot [0-9]*\.[0-9]*.*\(Build.*)'
U-Boot 1.1.4-g1c8343c8-dirty (Feb 28 2014 - 13:56:54)
U-Boot
Now running in RAM - U-Boot at: %08lx
If you know for a fact that it's in the first megabyte, you can use dd to siphon off the first meg of data before you run strings on it to save yourself processing time.
The current strings method used by bootloader-version() sets DEVICE /dev/mtdp6 and mtdp1 to p1, if we strings "$DEVICE" | grep -b "^U-Boot [a-z0-9.-]*$" we can discover where the ver strings are located and use dd to select just that area rather than the complete partition.
If u-boot is residing in an MTD partition then this will work:
U_BOOT_VER=$(for part in `grep u-boot-[01] /proc/mtd | cut -f 1 -d ':'`; do strings /dev/${part} | grep "^U-Boot.*("; break; done)
## upgrade-sd-bootloader()
FIXME
# Assumes a mounted efi partion
# Writes the rksd image only to a specific partition number on sd/mvme/sd/mmc devices.
#
# /dev/mmcblk*p6|/dev/sd*p6|/dev/mapper/loop*p6|/dev/mapper/nvme*p6) with p6 being changed to p1
## erase-sd-bootloader()
FIXME
Writes /dev/zero to the partition returned by findmnt /boot/efi
## write-emmc-flash()
We need to prevent writing on an emmc when it is the current boot device.
@ -197,6 +267,8 @@ expects: $1 $2 where:
## create-u-boot-menu()
FIXME
Need to choose a default and fix the other calls
#-----------
#zfs specific commands can be seen in the boot loader prompt using
# UBOOT #help

View File

@ -1,6 +1,6 @@
conf_print_resolvconf() {
fn conf_print_resolvconf
fn conf_print_resolvconf "(override)"
cat <<-EOF
nameserver 1.1.1.1
@ -9,7 +9,7 @@ conf_print_resolvconf() {
}
conf_print_sourceslist() {
fn conf_print_sourceslist
fn conf_print_sourceslist "(override)"
req=(mirror release section)
ckreq || return 1

View File

@ -1,7 +1,7 @@
cp $strapdir/etc/zfs/zpool.cache log/
cp $strapdir/etc/fstab log/
cp $strapdir/etc/default/grub log/default_grub
cp $strapdir/boot/grub/grub.cfg log/
echo $(lsinitramfs $strapdir/boot/initrd.img-${kernel_version}-${arch} | grep zfs) > log/zfs_initramfs.txt
echo $(lsinitramfs $strapdir/boot/initrd.img-${kernel_version}-${arch}) > log/initramfs.txt
cp "${strapdir}"/etc/zfs/zpool.cache log/
cp "${strapdir}"/etc/fstab log/
cp "${strapdir}"/etc/default/grub log/default_grub
cp "${strapdir}"/boot/grub/grub.cfg log/
echo "$(lsinitramfs ${strapdir}/boot/initrd.img-${kernel_version}-${arch} | grep zfs)" > log/zfs_initramfs.txt
"$(lsinitramfs "${strapdir}"/boot/initrd.img-"${kernel_version}-${arch}")" > log/initramfs.txt

View File

@ -8,7 +8,7 @@ cat <<EOF > .zshrc
pushd \$ZDOTDIR > /dev/null
source sdk
load devuan devuan-desktop-metal chimaera
load devuan devuan-desktop-metal daedalus
popd > /dev/null
EOF

176
daedalus.config Normal file
View File

@ -0,0 +1,176 @@
#!/usr/bin/env zsh
## configuration file for devuan-desktop-live blend
vars+=(username userpass default_shell mkefi grubversion hookscripts)
arrs+=(disk_name efi_partitions swap_partitions custom_deb_packages)
blend_name="devuan-desktop-metal_"
release="daedalus"
version="5.0.1"
hostname="devuan"
username="devuan"
userpass="devuan"
userskel="/etc/skel"
default_shell="/usr/bin/zsh"
# comment to disable:
#hookscripts="yes"
# debootstrap options
# From lib/libdevuansdk/zlib/bootstrap we need to add the options variable.
# debootstrap --keyring="$LIBPATH/extra/devuan-keyring/keyrings/devuan-archive-keyring.gpg" \
# --include=devuan-keyring,wget,ca-certificates \
# --foreign \
# >>> ${bootstrap_options} \ <<<
# --arch
# Currently we have put a wrapper in blend_helpers-docker to add these optiions using an alias.
bootstrap_options=("--force-check-gpg --no-merged-usr --variant=minbase")
# debootstrap mirror
#mirror="tor+http://devuanauxrkggcowgm2vcs6go3c5pgxdidd5wqjpg7zpfaxkmgspr6id.onion/merged"
#mirror="http://pkgmaster.devuan.org/merged" #
#mirror="http://deb.devuan.org" #
#mirror="http://localhost:3142/deb.devuan.org/merged/" # apt-cacher-ng
#mirror="http://192.168.1.50:3142/deb.devuan.org/merged/" # apt-cacher-ng
mirror="http://192.168.1.50:3142" # apt-cacher-ng
# the mirror to use in /etc/apt/apt.conf.d/02proxy
apt_proxy="http://192.168.1.50:3142"
arch="amd64"
#arch="arm64"
#arch="i386"
case "$arch" in
# for minimal-live
#i386) extra_packages+=(linux-image-686) ;;
# for desktop-live
#i386) extra_packages+=(linux-image-686-pae) ;;
amd64) extra_packages+=(linux-image-amd64) ;;
arm64) extra_packages+=(linux-image-arm64) ;;
esac
kernel_version="5.10.0-11"
# ZFS install parameters
rootfs="zfs"
disk_path="/dev/disk/by-id"
disk_name="ata-HGST_HTS541010A9E680_JA1000102T3RVP"
disk2_name="ata-HGST_HTS541010A9E680_JB10001329MG7R"
#raid=unset # raid0: striped 1 or more
raid=mirror # raid1: mirror 2
#raid=raidz # raid1: mirror 3
#raid=raidz2 # raid2: mirror 4
#raid=raidz3 # raid3: mirror 5
#raid=stripedmirror # raid10: mirror 4 and paired
available_disks=("${disk_name}")
if [[ -v $raid ]]; then
available_disks+="${disk2_name}"
fi
root_name="devuan-1"
rpool_name="rpool"
bpool_name="bpool"
#encrypt=yes
# polite to use somewhere other than /etc/zfs rather than squash it.
#zpool_cache_dir="/etc/zfs"
zpool_cache_dir="/var/tmp"
## underlying physical block size for zpool create.
# ashift=9 means 512B sectors (used by all ancient drives),
# ashift=12 means 4K sectors (used by most modern hard drives), and
# ashift=13 means 8K sectors (used by some modern SSDs).
ashift=12
bios_part_number="1"
efi_part_number="2"
swap_part_number="3"
boot_part_number="4"
root_part_number="5"
efi_start="2048"
bios_part_size="1MB"
efi_part_size="512MB"
swap_part_size="8GB"
boot_part_size="2GB"
# zvol requires resume to be disabled
#swap_type="zvol"
swap_type="physical"
tmp_exec_state="off"
var_tmp_exec_state="on"
# uncomment to create uefi-bootable iso causes iso_make_efi and iso_write_grub_cfg
# to be called in blend_postinst
#MKEFI=1
efi_work="$BLENDPATH/${release}/efi-files"
zero_uefi="no"
#efi=1
if [[ -n $efi ]];then
grub_mount="/boot/efi"
grubversion="grub-efi-${arch}"
case "arch" in
amd64) grub_efi_target="x86_64-efi" ;;
arm64) grub_efi_target="arm64-efi" ;;
i386) grub_efi_target="i386-efi" ;;
esac
else
grub_mount="/boot/grub"
grubversion="grub-pc"
fi
efi_partitions+=("/dev/disk/by-id/${disk_name}-part${efi_part_number}")
if [[ -v ${raid} ]]; then
efi_partitions+="/dev/disk/by-id/${disk2_name}-part${efi_part_number}"
fi
swap_partitions+=("/dev/disk/by-id/${disk_name}-part${swap_part_number}")
if [[ -v ${raid} ]]; then
swap_partitions+="/dev/disk/by-id/${disk2_name}-part${swap_part_number}"
fi
# Uncomment for amd64
base_packages+=(grub-efi-amd64-bin grub-efi-ia32-bin)
# devuan grub themes: cinnabar-grub darkpurpy-grub deepsea-grub
# grub themes must be placed on filesystems visable to grub ie not zfs.
grub_theme="deepsea-grub"
grub_gfxmode="1920x1200x32,1920x1200x8"
mirror="http://deb.devuan.org/merged"
section="main contrib non-free"
# need to add to the debootstrap command in lib/libdevuansdk/zlibs/bootstrap
#debootstrap_options="--extra-suites=ascii-proposed-updates --include=libupower-glib3,dbus-x11,xfce4"
base_packages_option=(--no-install-recommends)
extra_packages_option=(--no-install-recommends)
release_conf="$BLENDPATH/${release}/config"
### package sets are defined in the corresponding $release/config file
source $release_conf
## image_name depends on release and version
image_name="${os}_${release}_${version}_${arch}_desktop"

13
devuan-debian_releases Normal file
View File

@ -0,0 +1,13 @@
# jessie caused a name collision with debian, capitalized ascii is already used
# for something and just an anoying choice, they calmed down after that
# (or someone left).
corresponds to Debian 7 Wheezy 20170617T034212Z
Devuan 1.0 Jessie corresponds to Debian 8 Jessie 20180623T023722Z
Devuan 2.0 ASCII corresponds to Debian 9 Stretch 20200717T204551Z
Devuan 3.0 Beowulf corresponds to Debian 10.4 Buster 20230611T103552Z
Devuan 4.0 Chimaera corresponds to Debian 11.1 Bullseye 20230611T103552Z
Devuan 5.0 Daedalus corresponds to Debian 12 Bookworm 20231007T150030Z
Devuan 6.0 Excalibur corresponds to Debian 13 Trixie testing
Devuan 7.0 Freia corresponds to Debian 14 Forky
Devuan Ceres corresponds to Debian Sid unstable

View File

@ -22,6 +22,7 @@ BLENDPATH="${BLENDPATH:-$(dirname $0)}"
source $BLENDPATH/config
source $BLENDPATH/helpers
source $BLENDPATH/sysconf
blend_release_path=$BLENDPATH/$release
blend_packages=${blend_release_path}/packages
@ -91,39 +92,9 @@ blend_preinst() {
chroot-script -d install-custompackages || { zerr; return 1; }
notice "adding user account."
act "customize the post-adduser script."
cat <<-EOF | sudo tee "$strapdir/usr/local/sbin/adduser.local" >/dev/null
#!/bin/sh
## Site-specific setup for newly-created users.
## adduser(8) will call this script after setting up a new user.
## Usage: adduser.local USER UID GID HOME
set -euo pipefail
if [[ "\$#" != 4 ]]; then
echo "usage: $0 username uid gid home" > /dev/stderr
fi
NEW_USERNAME="\${1:?}"
NEW_UID="\${2:?}"
NEW_GID="\${3:?}"
NEW_HOME="\${4:?}"
# EXAMPLE: adduser discards permissions when copying from /etc/skel.
#chgrp www-data ${NEW_HOME}/public_html
#chmod g+s ${NEW_HOME}/public_html
# EXAMPLE: create a matching MySQL User for the Unix user.
#mysql -vv -e "CREATE USER '${NEW_USERNAME}'@'localhost' IDENTIFIED WITH auth_socket;"
# Fetch the tmux plugins.
#su -c '/usr/share/tmux-plugin-manager/bin/install_plugins' ${NEW_USERNAME}
EOF
chmod u+x ${strapdir}/usr/local/sbin/adduser.local
act "create default user."
# that populate /etc/skel will be reflected in the new user directory.
add-user "${username}" "${userpass}" ${userskel:-/etc/skel} || exit 1
add-user
}
blend_postinst() {
@ -177,8 +148,8 @@ blend_finalize() {
notice "Finalizing."
act "enabling ssh."
enablessh
# act "enabling ssh."
# enablessh
act "create /etc/fstab"
pushd "${strapdir}"
@ -236,6 +207,7 @@ blend_finalize() {
# Disable contrib and non-free after installing firmware.
#sed -i 's/contrib//g' /etc/apt/sources.list
#sed -i 's/non-free//g' /etc/apt/sources.list
#sed -i 's/non-free-firmware//g' /etc/apt/sources.list
## package list - Why does this make an empty file?
#dpkg -l | awk '/^ii/ { print $2 " " $3 }' > /home/${username}/package_list

176
excalibur.config Normal file
View File

@ -0,0 +1,176 @@
#!/usr/bin/env zsh
## configuration file for devuan-desktop-live blend
vars+=(username userpass default_shell mkefi grubversion hookscripts)
arrs+=(disk_name efi_partitions swap_partitions custom_deb_packages)
blend_name="devuan-desktop-metal_"
release="excalibur"
version="6.0.0"
hostname="devuan"
username="devuan"
userpass="devuan"
userskel="/etc/skel"
default_shell="/usr/bin/zsh"
# comment to disable:
#hookscripts="yes"
# debootstrap options
# From lib/libdevuansdk/zlib/bootstrap we need to add the options variable.
# debootstrap --keyring="$LIBPATH/extra/devuan-keyring/keyrings/devuan-archive-keyring.gpg" \
# --include=devuan-keyring,wget,ca-certificates \
# --foreign \
# >>> ${bootstrap_options} \ <<<
# --arch
# Currently we have put a wrapper in blend_helpers-docker to add these optiions using an alias.
bootstrap_options=("--force-check-gpg --no-merged-usr --variant=minbase")
# debootstrap mirror
#mirror="tor+http://devuanauxrkggcowgm2vcs6go3c5pgxdidd5wqjpg7zpfaxkmgspr6id.onion/merged"
#mirror="http://pkgmaster.devuan.org/merged" #
#mirror="http://deb.devuan.org" #
#mirror="http://localhost:3142/deb.devuan.org/merged/" # apt-cacher-ng
#mirror="http://192.168.1.50:3142/deb.devuan.org/merged/" # apt-cacher-ng
mirror="http://192.168.1.50:3142" # apt-cacher-ng
# the mirror to use in /etc/apt/apt.conf.d/02proxy
apt_proxy="http://192.168.1.50:3142"
arch="amd64"
#arch="arm64"
#arch="i386"
case "$arch" in
# for minimal-live
#i386) extra_packages+=(linux-image-686) ;;
# for desktop-live
#i386) extra_packages+=(linux-image-686-pae) ;;
amd64) extra_packages+=(linux-image-amd64) ;;
arm64) extra_packages+=(linux-image-arm64) ;;
esac
kernel_version="5.10.0-11"
# ZFS install parameters
rootfs="zfs"
disk_path="/dev/disk/by-id"
disk_name="ata-HGST_HTS541010A9E680_JA1000102T3RVP"
disk2_name="ata-HGST_HTS541010A9E680_JB10001329MG7R"
#raid=unset # raid0: striped 1 or more
raid=mirror # raid1: mirror 2
#raid=raidz # raid1: mirror 3
#raid=raidz2 # raid2: mirror 4
#raid=raidz3 # raid3: mirror 5
#raid=stripedmirror # raid10: mirror 4 and paired
available_disks=("${disk_name}")
if [[ -v $raid ]]; then
available_disks+="${disk2_name}"
fi
root_name="devuan-1"
rpool_name="rpool"
bpool_name="bpool"
#encrypt=yes
# polite to use somewhere other than /etc/zfs rather than squash it.
#zpool_cache_dir="/etc/zfs"
zpool_cache_dir="/var/tmp"
## underlying physical block size for zpool create.
# ashift=9 means 512B sectors (used by all ancient drives),
# ashift=12 means 4K sectors (used by most modern hard drives), and
# ashift=13 means 8K sectors (used by some modern SSDs).
ashift=12
bios_part_number="1"
efi_part_number="2"
swap_part_number="3"
boot_part_number="4"
root_part_number="5"
efi_start="2048"
bios_part_size="1MB"
efi_part_size="512MB"
swap_part_size="8GB"
boot_part_size="2GB"
# zvol requires resume to be disabled
#swap_type="zvol"
swap_type="physical"
tmp_exec_state="off"
var_tmp_exec_state="on"
# uncomment to create uefi-bootable iso causes iso_make_efi and iso_write_grub_cfg
# to be called in blend_postinst
#MKEFI=1
efi_work="$BLENDPATH/${release}/efi-files"
zero_uefi="no"
#efi=1
if [[ -n $efi ]];then
grub_mount="/boot/efi"
grubversion="grub-efi-${arch}"
case "arch" in
amd64) grub_efi_target="x86_64-efi" ;;
arm64) grub_efi_target="arm64-efi" ;;
i386) grub_efi_target="i386-efi" ;;
esac
else
grub_mount="/boot/grub"
grubversion="grub-pc"
fi
efi_partitions+=("/dev/disk/by-id/${disk_name}-part${efi_part_number}")
if [[ -v ${raid} ]]; then
efi_partitions+="/dev/disk/by-id/${disk2_name}-part${efi_part_number}"
fi
swap_partitions+=("/dev/disk/by-id/${disk_name}-part${swap_part_number}")
if [[ -v ${raid} ]]; then
swap_partitions+="/dev/disk/by-id/${disk2_name}-part${swap_part_number}"
fi
# Uncomment for amd64
base_packages+=(grub-efi-amd64-bin grub-efi-ia32-bin)
# devuan grub themes: cinnabar-grub darkpurpy-grub deepsea-grub
# grub themes must be placed on filesystems visable to grub ie not zfs.
grub_theme="deepsea-grub"
grub_gfxmode="1920x1200x32,1920x1200x8"
mirror="http://deb.devuan.org/merged"
section="main contrib non-free"
# need to add to the debootstrap command in lib/libdevuansdk/zlibs/bootstrap
#debootstrap_options="--extra-suites=ascii-proposed-updates --include=libupower-glib3,dbus-x11,xfce4"
base_packages_option=(--no-install-recommends)
extra_packages_option=(--no-install-recommends)
release_conf="$BLENDPATH/${release}/config"
### package sets are defined in the corresponding $release/config file
source $release_conf
## image_name depends on release and version
image_name="${os}_${release}_${version}_${arch}_desktop"

176
freia.config Normal file
View File

@ -0,0 +1,176 @@
#!/usr/bin/env zsh
## configuration file for devuan-desktop-live blend
vars+=(username userpass default_shell mkefi grubversion hookscripts)
arrs+=(disk_name efi_partitions swap_partitions custom_deb_packages)
blend_name="devuan-desktop-metal_"
release="excalibur"
version="6.0.0"
hostname="devuan"
username="devuan"
userpass="devuan"
userskel="/etc/skel"
default_shell="/usr/bin/zsh"
# comment to disable:
#hookscripts="yes"
# debootstrap options
# From lib/libdevuansdk/zlib/bootstrap we need to add the options variable.
# debootstrap --keyring="$LIBPATH/extra/devuan-keyring/keyrings/devuan-archive-keyring.gpg" \
# --include=devuan-keyring,wget,ca-certificates \
# --foreign \
# >>> ${bootstrap_options} \ <<<
# --arch
# Currently we have put a wrapper in blend_helpers-docker to add these optiions using an alias.
bootstrap_options=("--force-check-gpg --no-merged-usr --variant=minbase")
# debootstrap mirror
#mirror="tor+http://devuanauxrkggcowgm2vcs6go3c5pgxdidd5wqjpg7zpfaxkmgspr6id.onion/merged"
#mirror="http://pkgmaster.devuan.org/merged" #
#mirror="http://deb.devuan.org" #
#mirror="http://localhost:3142/deb.devuan.org/merged/" # apt-cacher-ng
#mirror="http://192.168.1.50:3142/deb.devuan.org/merged/" # apt-cacher-ng
mirror="http://192.168.1.50:3142" # apt-cacher-ng
# the mirror to use in /etc/apt/apt.conf.d/02proxy
apt_proxy="http://192.168.1.50:3142"
arch="amd64"
#arch="arm64"
#arch="i386"
case "$arch" in
# for minimal-live
#i386) extra_packages+=(linux-image-686) ;;
# for desktop-live
#i386) extra_packages+=(linux-image-686-pae) ;;
amd64) extra_packages+=(linux-image-amd64) ;;
arm64) extra_packages+=(linux-image-arm64) ;;
esac
kernel_version="5.10.0-11"
# ZFS install parameters
rootfs="zfs"
disk_path="/dev/disk/by-id"
disk_name="ata-HGST_HTS541010A9E680_JA1000102T3RVP"
disk2_name="ata-HGST_HTS541010A9E680_JB10001329MG7R"
#raid=unset # raid0: striped 1 or more
raid=mirror # raid1: mirror 2
#raid=raidz # raid1: mirror 3
#raid=raidz2 # raid2: mirror 4
#raid=raidz3 # raid3: mirror 5
#raid=stripedmirror # raid10: mirror 4 and paired
available_disks=("${disk_name}")
if [[ -v $raid ]]; then
available_disks+="${disk2_name}"
fi
root_name="devuan-1"
rpool_name="rpool"
bpool_name="bpool"
#encrypt=yes
# polite to use somewhere other than /etc/zfs rather than squash it.
#zpool_cache_dir="/etc/zfs"
zpool_cache_dir="/var/tmp"
## underlying physical block size for zpool create.
# ashift=9 means 512B sectors (used by all ancient drives),
# ashift=12 means 4K sectors (used by most modern hard drives), and
# ashift=13 means 8K sectors (used by some modern SSDs).
ashift=12
bios_part_number="1"
efi_part_number="2"
swap_part_number="3"
boot_part_number="4"
root_part_number="5"
efi_start="2048"
bios_part_size="1MB"
efi_part_size="512MB"
swap_part_size="8GB"
boot_part_size="2GB"
# zvol requires resume to be disabled
#swap_type="zvol"
swap_type="physical"
tmp_exec_state="off"
var_tmp_exec_state="on"
# uncomment to create uefi-bootable iso causes iso_make_efi and iso_write_grub_cfg
# to be called in blend_postinst
#MKEFI=1
efi_work="$BLENDPATH/${release}/efi-files"
zero_uefi="no"
#efi=1
if [[ -n $efi ]];then
grub_mount="/boot/efi"
grubversion="grub-efi-${arch}"
case "arch" in
amd64) grub_efi_target="x86_64-efi" ;;
arm64) grub_efi_target="arm64-efi" ;;
i386) grub_efi_target="i386-efi" ;;
esac
else
grub_mount="/boot/grub"
grubversion="grub-pc"
fi
efi_partitions+=("/dev/disk/by-id/${disk_name}-part${efi_part_number}")
if [[ -v ${raid} ]]; then
efi_partitions+="/dev/disk/by-id/${disk2_name}-part${efi_part_number}"
fi
swap_partitions+=("/dev/disk/by-id/${disk_name}-part${swap_part_number}")
if [[ -v ${raid} ]]; then
swap_partitions+="/dev/disk/by-id/${disk2_name}-part${swap_part_number}"
fi
# Uncomment for amd64
base_packages+=(grub-efi-amd64-bin grub-efi-ia32-bin)
# devuan grub themes: cinnabar-grub darkpurpy-grub deepsea-grub
# grub themes must be placed on filesystems visable to grub ie not zfs.
grub_theme="deepsea-grub"
grub_gfxmode="1920x1200x32,1920x1200x8"
mirror="http://deb.devuan.org/merged"
section="main contrib non-free"
# need to add to the debootstrap command in lib/libdevuansdk/zlibs/bootstrap
#debootstrap_options="--extra-suites=ascii-proposed-updates --include=libupower-glib3,dbus-x11,xfce4"
base_packages_option=(--no-install-recommends)
extra_packages_option=(--no-install-recommends)
release_conf="$BLENDPATH/${release}/config"
### package sets are defined in the corresponding $release/config file
source $release_conf
## image_name depends on release and version
image_name="${os}_${release}_${version}_${arch}_desktop"

View File

@ -1,4 +1,33 @@
#!/usr/bin/env bash
# Once you have run this script you should be able to
#
# drive names must be changed in blends/devuan-desktop-metal/config
# blends/devuan-desktop-metal/daedalus/config has the installed package list
#
# then:
# $ cd /var/tmp/live-sdk
# $ tmuxp load .
#
# This will give you two frames, one in the live-sdk env and one not.
# Use ^B arrow to switch between them,
#
# To install run:
# $ build_metal_dist
# This script is intended to be run of an sdcard live image NOT a running system.
#
# It copies /var/tmp/live-sdk from 192.168.1.102 if the ssh key exchange does not
# fix password requests the default:default can be used.
#
# It takes the blends/devuan-desktop-live directory as a template and copies the
# configuration files in live-metal to the newly named blend directory.
#
# The sources.list will be updated to a snapshot.debian.org date that matches
# the live sdcard release (bookworm) if you change the live sdcard image you
# must change the date of the snapshot.
# check for the availability of color terminfoi, fix it if it's missing.
if [[ ! -f /lib/terminfo/t/tmux-256color ]]; then
wget -c https://raw.githubusercontent.com/jez/dotfiles/master/tmux-256color.terminfo
tic ./tmux-256color.terminfo
@ -27,57 +56,222 @@ rm /etc/apt/sources.list.d/brave-browser.list
rm /etc/apt/sources.list.d/nodesource.list
rm /etc/apt/sources.list.d/matrix-riot-im.list
# the snapshot.debian.org sources.list for the sdcard image.
# rm /etc/apt/sources.list
# To reduce the number of packages installed with an update we put a fixed date
# sources.list from snapshot.debian.org that matches the release of the live sdcard.
# jessie caused a name collision with debian, capitalized ascii is already used
# for something and just an anoying choice, they calmed down after that
# (or someone left).
# corresponds to Debian 7 Wheezy 20170617T034212Z
# Devuan 1.0 Jessie corresponds to Debian 8 Jessie 20180623T023722Z
# Devuan 2.0 ASCII corresponds to Debian 9 Stretch 20200717T204551Z
# Devuan 3.0 Beowulf corresponds to Debian 10.4 Buster 20230611T103552Z
# Devuan 4.0 Chimaera corresponds to Debian 11.1 Bullseye 20230611T103552Z
# Devuan 5.0 Daedalus corresponds to Debian 12 Bookworm 20231007T150030Z
# Devuan 6.0 Excalibur corresponds to Debian 13 Trixie testing
# Devuan 7.0 Freia corresponds to Debian 14 Forky
# Devuan Ceres corresponds to Debian Sid unstable
RELEASE_NAME=bookworm
SOURCES_DATE=20221017T031443Z
SNAPSHOT_SERVER="snapshot.debian.org"
# SNAPSHOT_SERVER="snapshot.notset.fr"
cat <<-EOF | sudo tee /etc/apt/sources.list.d/snapshot.sources.list
deb https://"${SNAPSHOT_SERVER}"/archive/debian/"${SOURCES_DATE}"/ "${RELEASE_NAME}" main contrib non-free non-free-firmware
deb-src https://"${SNAPSHOT_SERVER}"/archive/debian/"${SOURCES_DATE}"/ "${RELEASE_NAME}" main contrib non-free non-free-firmware
deb https://"${SNAPSHOT_SERVER}"/archive/debian-security/"${SOURCES_DATE}"/ "${RELEASE_NAME}"-security main contrib non-free non-free-firmware
deb-src https://"${SNAPSHOT_SERVER}"/archive/debian-security/"${SOURCES_DATE}"/ "${RELEASE_NAME}"-security main contrib non-free non-free-firmware
EOF
# cp ./snapshot.sources.list /etc/apt/sources.list.d/snapshot.sources.list
# Update apt even if upstream have shifted to a new release.
echo 'Acquire::Check-Valid-Until "false";' | sudo tee /etc/apt/apt.conf.d/99validuntil
echo 'Acquire::AllowReleaseInfoChange::Suite "true";' | sudo tee /etc/apt/apt.conf.d/99releaseinfochange
echo 'APT::Get::AllowUnauthenticated "true";' | sudo tee -a /etc/apt/apt.conf.d/99unauth
echo 'quiet::ReleaseInfoChange::Version "true";' | sudo tee -a /etc/apt/apt.conf.d/99releaseinfochange
# When a suite gets advanced from testing to stable the release info changes,
# allow to update without error.
apt-get update --allow-releaseinfo-change -y
apt-get install -y lsof gdisk hdparm debootstrap dosfstools rsync desktop-base
# Keep the existing kernel and headers to prevent multiple builds of the zfs
# module for additional kernels.
KERNEL_VERSION="$(uname -r)"
apt-mark hold \
linux-image-"${KERNEL_VERSION}" \
linux-headers-"${KERNEL_VERSION}" \
linux-image-amd64 \
linux-headers-amd64
apt-get install linux-headers-"${KERNEL_VERSION}" zfs-dkms
modprobe zfs
# Remove libreoffice, updating an installed libreoffice is time consuming and
# uses a lot of disk space on an sdcard image.
apt-get remove -y --purge \
libreoffice \
libreoffice-common \
libreoffice-calc \
libreoffice-core \
libreoffice-writer \
libreoffice-impress \
libreoffice-draw \
libreoffice-math \
libreoffice-base \
libreoffice-gtk3 \
liblibreoffice-java \
libreoffice-sdbc-hsqldb \
libreoffice-base-drivers
apt-get -y autoremove
apt-get install -y lsof jc jq gdisk hdparm debootstrap dosfstools rsync openssh-server sshpass eudev # desktop-base
apt-get clean
# install server public key for ssh from ~/.ssh/id_rsa.pub
mkdir -p ~/.ssh && cat ./sistarte-id_rsa.pub >> "${HOME}"/.ssh/authorized_keys
#
# Exchange ssh keys
AUTOMATE_IP="192.168.1.102"
LOCAL_USER_EMAIL="devuan@${AUTOMATE_IP}"
ssh-keygen -t rsa -b 4096 -N '' -C "${LOCAL_USER_EMAIL}" -f "${HOME}"/.ssh/id_rsa
sshpass -f sistarte_password.txt ssh-copy-id default@${AUTOMATE_IP}
#git clone https://git.devuan.org/devuan-sdk/live-sdk ../live-sdk
#cd ../livecd || exit; git submodule update --init --recursive --checkout
alias ssh="ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null"
rsync -avz -e ssh default@192.168.1.92:/var/tmp/automate /var/tmp/
rsync -avz -e ssh default@192.168.1.92:/var/tmp/live-sdk ..
mkdir -p /var/tmp/live-sdk/log
mkdir -p /var/tmp/live-sdk/tmp
rsync -avz -e ssh default@192.168.1.92:/var/tmp/"bootstrap-devuan-amd64-stage*.cpio.gz" /var/tmp/live-sdk/tmp/
# rsync -ratlz \
# --rsh="/usr/bin/sshpass -p password ssh -l username" \
# src_path \
# dest_path
rsync -avz \
--exclude='.git/*' \
--exclude='*gz' \
--exclude='*deb' \
-e ssh default@"${AUTOMATE_IP}":/var/tmp/automate \
../
ln -sf ../automate /var/tmp/automate
bash ../automate/010_generate-ssh.sh "${HOME}"
bash ../automate/001_ssh.sh
# SDCARD_ID="usb-Mass_Storage_Device_121220160204-0:0-part1"
# mkdir -p ../live-sdk
# if ! mountpoint -q ../live-sdk; then
# fsck.ext4 -f /dev/disk/by-id/${SDCARD_ID}
# mount /dev/disk/by-id/${SDCARD_ID} ../live-sdk
# else
# echo "mount point already in use, skipping mount operation."
# fi
rsync -avz \
--exclude='.git' \
--exclude='tmp/*' \
--exclude='dist/*' \
--exclude='git/*' \
-e ssh default@${AUTOMATE_IP}:/var/tmp/live-sdk \
../live-sdk
mkdir -p ../live-sdk/log
mkdir -p ../live-sdk/tmp
# Uncomment to speed up subsequent builds
# rsync -avz \
# -e ssh default@${AUTOMATE_IP}:/var/tmp/"bootstrap-devuan-amd64-stage*.cpio.gz" \
# /var/tmp/live-sdk/tmp/
# Install
# metal install chimaera (bare metal install to zfs following openzfs zfs rootfs)
RELEASE_NAME="daedalus"
BLEND_NAME=devuan-desktop-metal
TEMPLATE=devuan-desktop-live
sed -i "/blend_map=.*/ s/.*/&\n\t\t\"${BLEND_NAME}\" \"\$R\/blends\/${BLEND_NAME}\/${BLEND_NAME}.blend\"/" ../live-sdk/sdk
sed -i \
"/blend_map=.*/ s/.*/&\n\t\t\"${BLEND_NAME}\" \"\$R\/blends\/${BLEND_NAME}\/${BLEND_NAME}.blend\"/" \
../live-sdk/sdk
mkdir -p ../live-sdk/blends/${BLEND_NAME}/${RELEASE_NAME}
cp -a ../live-sdk/blends/${TEMPLATE} ../live-sdk/blends/${BLEND_NAME}
cp --backup blend_chimaera_config ../live-sdk/blends/${BLEND_NAME}/chimaera/config
cp --backup blend_config ../live-sdk/blends/${BLEND_NAME}/config
cp --backup blend_sysconf ../live-sdk/blends/${BLEND_NAME}/sysconf
cp --backup blend_sysconf.md ../live-sdk/blends/${BLEND_NAME}/sysconf.md
cp --backup blend_helpers ../live-sdk/blends/${BLEND_NAME}/helpers
cp --backup blend_helpers.md ../live-sdk/blends/${BLEND_NAME}/helpers.md
cp --backup devuan-desktop-metal.blend ../live-sdk/blends/${BLEND_NAME}/
cp --backup devuan-desktop-metal.md ../live-sdk/blends/${BLEND_NAME}/
cp --backup console_livesdk.sh ../live-sdk/
cp --backup dot_tmuxp.yaml_metal ../live-sdk/.tmuxp.yaml
cp blend_config ../live-sdk/blends/${BLEND_NAME}/config
cp blend_${RELEASE_NAME}_config ../live-sdk/blends/${BLEND_NAME}/${RELEASE_NAME}/config
cp blend_sysconf ../live-sdk/blends/${BLEND_NAME}/sysconf
cp blend_sysconf.md ../live-sdk/blends/${BLEND_NAME}/sysconf.md
cp blend_helpers ../live-sdk/blends/${BLEND_NAME}/helpers
cp blend_helpers.md ../live-sdk/blends/${BLEND_NAME}/helpers.md
cp devuan-desktop-metal.blend ../live-sdk/blends/${BLEND_NAME}/
cp devuan-desktop-metal.md ../live-sdk/blends/${BLEND_NAME}/
cp console_livesdk.sh ../live-sdk/
cp dot_tmuxp.yaml_metal ../live-sdk/.tmuxp.yaml
# docker image minimal (following debuerreotype methods)
BLEND_NAME=devuan-minimal-docker
TEMPLATE=devuan-minimal-live
sed -i "/blend_map=.*/ s/.*/&\n\t\t\"${BLEND_NAME}\" \"\$R\/blends\/${BLEND_NAME}\/${BLEND_NAME}.blend\"/" ../live-sdk/sdk
sed -i \
"/blend_map=.*/ s/.*/&\n\t\t\"${BLEND_NAME}\" \"\$R\/blends\/${BLEND_NAME}\/${BLEND_NAME}.blend\"/" \
../live-sdk/sdk
mkdir -p ../live-sdk/blends/${BLEND_NAME}/${RELEASE_NAME}
cp -a ../live-sdk/blends/${TEMPLATE} ../live-sdk/blends/${BLEND_NAME}
cp --backup blend_chimaera-docker_config ../live-sdk/blends/${BLEND_NAME}/chimaera/config
cp --backup blend_config-docker ../live-sdk/blends/${BLEND_NAME}/config-docker
cp --backup blend_sysconf ../live-sdk/blends/${BLEND_NAME}/sysconf
cp --backup blend_sysconf.md ../live-sdk/blends/${BLEND_NAME}/sysconf.md
cp --backup blend_helpers-docker ../live-sdk/blends/${BLEND_NAME}/helpers-docker
cp --backup blend_helpers-docker.md ../live-sdk/blends/${BLEND_NAME}/helpers-docker.md
cp --backup devuan-minimal-docker.blend ../live-sdk/blends/${BLEND_NAME}/
cp --backup devuan-minimal-docker.md ../live-sdk/blends/${BLEND_NAME}/
cp --backup tar-excludes ../live-sdk/blends/${BLEND_NAME}/
cp blend_${RELEASE_NAME}-docker_config ../live-sdk/blends/${BLEND_NAME}/${RELEASE_NAME}/config
cp blend_config-docker ../live-sdk/blends/${BLEND_NAME}/config-docker
cp blend_sysconf ../live-sdk/blends/${BLEND_NAME}/sysconf
cp blend_sysconf.md ../live-sdk/blends/${BLEND_NAME}/sysconf.md
cp blend_helpers-docker ../live-sdk/blends/${BLEND_NAME}/helpers-docker
cp blend_helpers-docker.md ../live-sdk/blends/${BLEND_NAME}/helpers-docker.md
cp devuan-minimal-docker.blend ../live-sdk/blends/${BLEND_NAME}/
cp devuan-minimal-docker.md ../live-sdk/blends/${BLEND_NAME}/
cp tar-excludes ../live-sdk/blends/${BLEND_NAME}/
# ln -sf ${RELEASE_NAME}.config config
bash /var/tmp/automate/010_zram.sh && /etc/init.d/zram start
bash /var/tmp/automate/020_tmux.sh
bash ../automate/010_zram.sh && /etc/init.d/zram start
bash ../automate/020_tmux.sh "${HOME}"
bash ../automate/020_zsh_quickstart.sh "${HOME}"
su '/usr/share/tmux-plugin-manager/bin/install_plugins' default
su '/usr/share/tmux-plugin-manager/bin/install_plugins' root
sudo -i -u devuan '/usr/share/tmux-plugin-manager/bin/install_plugins'
sudo -i '/usr/share/tmux-plugin-manager/bin/install_plugins'
ps aux > /var/tmp/live-sdk/log/psaux.pre
lsof > /var/tmp/live-sdk/log/lsof.pre
ps aux > ../live-sdk/log/psaux.pre
lsof > ../live-sdk/log/lsof.pre
# Fix the innumeration of drives to usbe ata-* rather than wwn-*
# could import from blend_config
# disk_path="/dev/disk/by-id"
# disk_name="ata-CT1000MX500SSD1_2321E6DBE216"
# disk2_name="ata-CT1000MX500SSD1_2321E6DBE1D2"
#
# raid=mirror
#
# available_disks=("${disk_name}")
# if [[ -v $raid ]]; then
# available_disks+="${disk2_name}"
# fi
# source blend_config
# for disk in "${available_disks[@]}"; do
# TARGET="/dev/disk/by-id/${disk}"
#
# UDEV_OUTPUT=$(udevadm info --query=all "${TARGET}" | jc --udevadm -p | jq 'del(.E.ID_MODEL_ENC)')
# MODEL=$(echo -n "${UDEV_OUTPUT}" | jq -r '.E.ID_MODEL')
# SERIAL=$(echo -n "${UDEV_OUTPUT}" | jq -r '.E.ID_SERIAL_SHORT')
# echo "SUBSYSTEM==\"block\", \
# ATTRS{model}=\"$MODEL\", \
# ATTRS{serial_short}=\"$SERIAL\", \
# SYMLINK+=\"disk/by-id/ata-\$attr{serial_short}\"" | \
# sudo tee /etc/udev/rules.d/99-custom-ata-names.rules
# done
# udevadm control --reload-rules && sudo udevadm trigger

1
sistarte-id_rsa.pub Normal file
View File

@ -0,0 +1 @@
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQC1p5qweYQBS/I0ir3xss8dTYpEKx19j3AeosVwNMlcXm3oD7MvyAkIeFI2g8/VZTXAX+AM9WFqzH9nGbdm7+xnjsTwfhzDgEEsJ/Dqfv5TVVB6swUzN2Xl4waxLSTDHf0J4qeemzecPgWLOG6O2QIrblkKjSXc3tWjwoYeqEvaq2kIz/wQQkjgKZWV+hm4GYLuFHgLDVvaR6Ltkf7eVcoGleCpeJ6d3Qq6GsTbm1h/sB2FmVpeyCHQKK2t2DO4tDf93pCqsMLSxdORDNcAZvnQi1w8sNLJPCzg9756Zdrmgt7IEiuF9tvzMnir4tfbR3q7zAjKBhU4jykhLv7AS4oqWr9EphVKHGciIpZvJMb7KqRSjMFbe5ofdDoWE/BrlzywFnu4eQHwvvLEnMYUWyrLWcDNZTv9CoUTsbiFcrC856H7NqA4J5HgRvFI04TCnh0Jkk10iu8KbsUA+KyzdxO2SVtqh1Hkxs2FjhsVdtYXziU7tsbEcSsMwako+DBec+8= default@sistarte

1
sistarte_password.txt Normal file
View File

@ -0,0 +1 @@
default

4
snapshot.sources.list Normal file
View File

@ -0,0 +1,4 @@
deb https://snapshot.debian.org/archive/debian/20221017T031443Z/ bookworm main contrib non-free non-free-firmware
deb-src https://snapshot.debian.org/archive/debian/20221017T031443Z/ bookworm main contrib non-free non-free-firmware
deb https://snapshot.debian.org/archive/debian-security/20221017T031443Z/ bookworm-security main contrib non-free non-free-firmware
deb-src https://snapshot.debian.org/archive/debian-security/20221017T031443Z/ bookworm-security main contrib non-free non-free-firmware

Binary file not shown.

After

Width:  |  Height:  |  Size: 227 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:cc="http://creativecommons.org/ns#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:svg="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" width="1350" height="1350" viewBox="0 0 1350 1349.9999" id="svg3668" version="1.1" inkscape:version="0.91 r13725" sodipodi:docname="devuan-emblem.svg" inkscape:export-filename="/home/hellekin/src/devuan/Editors/devuan-art/graphics/logo/devuan-emblem_600dpi.png" inkscape:export-xdpi="600.18597" inkscape:export-ydpi="600.18597">
<title id="title3714">Devuan Logo</title>
<defs id="defs3670"/>
<sodipodi:namedview id="base" pagecolor="#ffffff" bordercolor="#666666" borderopacity="1.0" inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="0.40962963" inkscape:cx="675" inkscape:cy="857.83455" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="false" fit-margin-top="0" fit-margin-left="0" fit-margin-right="0" fit-margin-bottom="0" inkscape:window-width="1366" inkscape:window-height="746" inkscape:window-x="0" inkscape:window-y="0" inkscape:window-maximized="1" units="px"/>
<metadata id="metadata3673">
<rdf:RDF>
<cc:Work rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage"/>
<dc:title>Devuan Logo</dc:title>
<dc:creator>
<cc:Agent>
<dc:title>hellekin</dc:title>
</cc:Agent>
</dc:creator>
<dc:publisher>
<cc:Agent>
<dc:title>Dyne.org Foundation</dc:title>
</cc:Agent>
</dc:publisher>
<dc:contributor>
<cc:Agent>
<dc:title>hellekin, golinux, Centurion_Dan</dc:title>
</cc:Agent>
</dc:contributor>
</cc:Work>
</rdf:RDF>
</metadata>
<g inkscape:label="Layer 1" inkscape:groupmode="layer" id="layer1" transform="translate(-461.83765,773.396)">
<path sodipodi:nodetypes="ccssscsc" style="display:inline;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.57134259;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" d="m 476.83763,-735.58372 c 2338.48797,558.0593 126.33114,1011.84705 126.33114,1011.84705 -43.58162,6.96435 -78.73605,29.66638 -99.90023,64.16464 -23.77501,38.75407 -25.78966,91.11744 -3.58794,127.93272 27.01568,44.79799 61.24559,60.29471 90.76791,66.96868 46.4478,10.50026 83.93944,-6.23205 83.93944,-6.23205 0,0 1130.90315,-336.07443 1122.40205,-671.77089 -4.2676,-168.52412 -346.7729,-453.57529 -1319.95237,-592.91015 z" id="path4338" inkscape:connector-curvature="0"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.8 KiB

BIN
u-boot-logo/Devuan-logo.bmp Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 445 KiB

BIN
u-boot-logo/Devuan-logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 86 KiB

View File

@ -0,0 +1,27 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:cc="http://creativecommons.org/ns#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:svg="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" width="290.88196mm" height="74.000595mm" viewBox="0 0 1030.6841 262.20683" id="svg4491" version="1.1" inkscape:version="0.91 r13725" sodipodi:docname="devuan-logo-with-registered-trademark-sign.svg">
<defs id="defs4493"/>
<sodipodi:namedview id="base" pagecolor="#ffffff" bordercolor="#666666" borderopacity="1.0" inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="0.78339844" inkscape:cx="264.00016" inkscape:cy="32.005932" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="false" fit-margin-top="10" fit-margin-left="10" fit-margin-right="10" fit-margin-bottom="10" inkscape:window-width="1366" inkscape:window-height="746" inkscape:window-x="0" inkscape:window-y="0" inkscape:window-maximized="1"/>
<metadata id="metadata4496">
<rdf:RDF>
<cc:Work rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage"/>
<dc:title/>
<cc:license rdf:resource=""/>
</cc:Work>
</rdf:RDF>
</metadata>
<g inkscape:label="Layer 1" inkscape:groupmode="layer" id="layer1" transform="translate(262.59708,-302.16131)">
<text xml:space="preserve" style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:20px;line-height:150%;font-family:'Open Sans';-inkscape-font-specification:'Open Sans, Normal';text-align:start;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" x="716.98987" y="505.97049" id="text4470" sodipodi:linespacing="150%"><tspan sodipodi:role="line" id="tspan4472" x="716.98987" y="505.97049">®</tspan></text>
<g style="display:inline" id="g4427" transform="translate(-283.36497,61.428879)">
<path style="color:#000000;font-style:normal;font-variant:normal;font-weight:100;font-stretch:normal;font-size:medium;line-height:150%;font-family:'Fira Sans';-inkscape-font-specification:'Fira Sans Thin';text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:0px;word-spacing:0px;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;baseline-shift:baseline;text-anchor:start;white-space:normal;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:19.91197014;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" d="m 369.8125,298.34766 a 9.9569807,9.9569807 0 0 0 -8.81445,14.58593 l 66.99414,127.49024 a 9.9569807,9.9569807 0 0 0 8.8125,5.32422 l 2.96484,0 a 9.9569807,9.9569807 0 0 0 8.83008,-5.35743 L 515,312.90234 a 9.9569807,9.9569807 0 0 0 -8.83008,-14.55468 l -2.37109,0 a 9.9569807,9.9569807 0 0 0 -8.83399,5.36132 L 438.26562,412.75 381.30469,303.69336 a 9.9569807,9.9569807 0 0 0 -8.82422,-5.3457 l -2.66797,0 z" id="path4401" inkscape:connector-curvature="0"/>
<path style="color:#000000;font-style:normal;font-variant:normal;font-weight:100;font-stretch:normal;font-size:medium;line-height:150%;font-family:'Fira Sans';-inkscape-font-specification:'Fira Sans Thin';text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:0px;word-spacing:0px;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;baseline-shift:baseline;text-anchor:start;white-space:normal;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:20;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" d="m 541.45898,297.73633 a 10.001,10.001 0 0 0 -10,10 l 0,88.48633 c 0,14.8854 6.49876,28.38398 18.16016,37.26367 12.24914,9.32706 29.37532,12.87109 51.08594,12.87109 21.50233,0 38.53211,-3.55834 50.75195,-12.84375 11.8361,-8.84931 18.49609,-22.37012 18.49609,-37.29101 l 0,-88.48633 a 10.001,10.001 0 0 0 -10,-10 l -2.36914,0 a 10.001,10.001 0 0 0 -10,10 l 0,88.29883 c 0,9.41271 -2.81974,15.15179 -9.71484,20.4414 -6.30803,4.83925 -18.59119,8.38867 -37.16406,8.38867 -18.57288,0 -30.85603,-3.54942 -37.16406,-8.38867 -6.8951,-5.28961 -9.7129,-11.02869 -9.7129,-20.4414 l 0,-88.29883 a 10.001,10.001 0 0 0 -10,-10 l -2.36914,0 z" id="path4403" inkscape:connector-curvature="0"/>
<path style="color:#000000;font-style:normal;font-variant:normal;font-weight:100;font-stretch:normal;font-size:medium;line-height:150%;font-family:'Fira Sans';-inkscape-font-specification:'Fira Sans Thin';text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:0px;word-spacing:0px;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;baseline-shift:baseline;text-anchor:start;white-space:normal;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:20;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" d="m 762.23633,297.25586 a 10.001,10.001 0 0 0 -8.88477,5.41016 L 686.40234,432.25 a 10.001,10.001 0 0 0 8.88282,14.58984 l 2.66601,0 a 10.001,10.001 0 0 0 8.89649,-5.43164 l 56.84961,-110.69922 56.58398,110.68164 a 10.001,10.001 0 0 0 8.9043,5.44922 l 2.36914,0 a 10.001,10.001 0 0 0 8.90039,-14.55859 L 774.09961,302.69727 a 10.001,10.001 0 0 0 -8.90234,-5.44141 l -2.96094,0 z" id="path4405" inkscape:connector-curvature="0"/>
<path style="color:#000000;font-style:normal;font-variant:normal;font-weight:100;font-stretch:normal;font-size:medium;line-height:150%;font-family:'Fira Sans';-inkscape-font-specification:'Fira Sans Thin';text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:0px;word-spacing:0px;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;baseline-shift:baseline;text-anchor:start;white-space:normal;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:20;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" d="m 926.13477,297.73633 c -21.71059,0 -38.83679,3.54404 -51.08594,12.87109 -11.66148,8.87957 -18.16016,22.38011 -18.16016,37.26563 l 0,88.48437 a 10.001,10.001 0 0 0 10,10 l 2.36914,0 a 10.001,10.001 0 0 0 10,-10 l 0,-88.29687 c 0,-9.41288 2.81783,-15.15181 9.71289,-20.44141 6.30803,-4.83925 18.59126,-8.38867 37.16407,-8.38867 18.57294,0 30.85605,3.54944 37.16406,8.38867 6.89507,5.28961 9.71484,11.02853 9.71484,20.44141 l 0,88.29687 a 10.001,10.001 0 0 0 10,10 l 2.36914,0 a 10.001,10.001 0 0 0 10,-10 l 0,-88.48437 c 0,-14.92619 -6.66394,-28.45176 -18.50781,-37.30078 -12.21906,-9.27908 -29.24448,-12.83594 -50.74023,-12.83594 z" id="path4407" inkscape:connector-curvature="0"/>
<path style="color:#000000;font-style:normal;font-variant:normal;font-weight:100;font-stretch:normal;font-size:medium;line-height:150%;font-family:'Fira Sans';-inkscape-font-specification:'Fira Sans Thin';text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:0px;word-spacing:0px;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;baseline-shift:baseline;text-anchor:start;white-space:normal;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:9.99139977;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" d="m 262.70352,299.1501 c -16.6902,0 -31.61821,6.64211 -41.77029,19.04358 -2.94743,3.54165 -5.4048,7.50325 -7.41715,11.86761 -5.24033,11.36537 12.50043,3.04762 12.50043,19.57243 0,9.33503 -19.2702,40.30646 -17.7395,48.03331 2.25488,11.38259 6.32742,20.96483 12.67969,28.58438 10.18167,12.2129 25.08385,18.69188 41.74682,18.69188 l 71.79612,0 c 5.52169,-2e-4 9.99848,-4.47505 10.0008,-9.9968 l 0,-2.51777 c -1e-4,-5.52315 -4.47755,-10.0006 -10.0008,-10.0008 l -71.58108,0 c -11.57153,0 -19.03219,-3.40673 -25.32255,-10.89617 -5.80518,-6.91154 -9.80922,-19.80543 -9.80922,-39.48315 -2e-5,-19.67793 4.00408,-32.57162 9.80922,-39.48316 6.2904,-7.48924 13.75112,-10.89997 25.32255,-10.89997 l 71.58108,0 c 5.52325,-2e-4 10.0007,-4.47766 10.0008,-10.00081 l 0,-2.51396 c -2.2e-4,-5.52315 -4.47763,-10.0004 -10.0008,-10.0006 z" clip-path="none" id="path4409" inkscape:connector-curvature="0" sodipodi:nodetypes="scsssssccccscsssccccs"/>
<path sodipodi:nodetypes="ccssscsc" style="fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.57134259;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" d="m 56.200956,276.1655 c 351.111544,83.78964 18.967955,151.92346 18.967955,151.92346 -6.543555,1.04566 -11.821798,4.45425 -14.999489,9.63398 -3.569697,5.81872 -3.872178,13.6808 -0.538715,19.20842 4.056259,6.72618 9.195703,9.05293 13.628318,10.05499 6.973891,1.57656 12.603069,-0.93571 12.603069,-0.93571 0,0 169.799086,-50.45979 168.522696,-100.86283 -0.64075,-25.303 -52.0661,-68.10192 -198.183834,-89.02231 z" id="path4411" inkscape:connector-curvature="0"/>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 11 KiB

75
u-boot-logo/README.md Normal file
View File

@ -0,0 +1,75 @@
Pinephone A64 native resolution 1440x720 18:9 2:1
Display size: 5.32" × 2.66" = 14.16in² (13.52cm × 6.76cm = 91.36cm²) at 270.58 PPI, 0.0939mm dot pitch, 73215 PPI²
https://developer.toradex.com/linux-bsp/how-to/boot/splash-screen-on-u-boot/
* Inkscape
Load the svg to inkscape and export png
* Converting from PNG to BMP
U-Boot can read a specific image format. Use the following command to convert the PNG image to BPM.
SVG="Devuan-logo.svg"
PNG="Devuan-logo.png"
BMP="Devuan-logo.bmp"
inkscape --export-type="png" ${SVG}
convert ${PNG} -type Palette -colors 224 -depth 8 -compress none -verbose BMP3:${PNG}
SVG="Devuan-logo-swoosh.svg"
PNG="Devuan-logo-swoosh.png"
BMP="Devuan-logo-swoosh.bmp"
inkscape --export-type="png" ${SVG}
convert ${PNG} -type Palette -colors 224 -depth 8 -compress none -verbose BMP3:${BMP}
# The u-boot makefile sets the location of the logo image in LOGO_BMP
# It will look for logos/$(BOARD).bmp and logos/$(VENDOR).bmp so
# we can write it their instead.
# copy to the existing denx generic logo image location.
# tools/bmp_logo --gen-info ./tools/logos/denx.bmp > include/bmp_logo.h
# tools/bmp_logo --gen-bmp ./tools/logos/denx.bmp > include/bmp_logo_data.h
cp ~/${BMP} ${UBOOT_HOME}/tools/logos/denx.bmp
-----
* Using GIMP image dump
https://developer.ridgerun.com/wiki/index.php/How_to_change_uboot_splash_image
# Get image that you want to show in resolution smaller than your display resolution.
# Open the image using GIMP graphic application.
# Save the image using "save as" option.
# In the select box "Select File Type (by Extension)" select the format "c source code"
# Then you will get one windows with some options, in this window deselect all options (Use glibs types, use macros instead of struct, Use 1 byte run-length-encoding, Save alpha channel)
# Then save this file (changing the file extension from .c to .h) to
#* $DEVDIR/bootloader/uboot.*/src/board/davinci/common
# Change the variable value CONFIG_SPLASH_LOGO_FILE with the name of file used above. The CONFIG_SPLASH_LOGO_FILE configuration setting can be found in the Splash Screen section in your board file in the directory
#* $DEVDIR/bootloader/uboot.*/src/include/configs
# Clean and compile the bootloader
The form of the image-file must be similar to:
<syntaxhighlight lang="c">
/* GIMP RGB C-Source image dump (image.c) */
static const struct {
unsigned int width;
unsigned int height;
unsigned int bytes_per_pixel; /* 3:RGB, 4:RGBA */
unsigned char pixel_data[200 * 100 * 3 + 1];
} gimp_image = {
200, 100, 3,
"(\237\306(\237\306(\237\306(\237\306(\237\306(\237\306(\237\306(\237\306"
"(\237\306(\237\306(\237\306(\237\306(\237\306(\237\306(\237\306(\237\306"
"(\237\306(\237\306(\237\306(\237\306(\237\306(\237\306(\237\306(\237\306"
"(\237\306(\237\306(\237\306(\237\306(\237\306(\237\306(\237\306(\237\306"
</syntaxhighlight>
Remember that normally the bootloader modifications are made using patches.