Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# To build large images, the debos resource defaults are not sufficient. These
# provide defaults that work for us as universally as we can manage.
FAKEMACHINE_BACKEND = $(shell [ -c /dev/kvm ] && echo kvm || echo qemu)
DEBOS_OPTS := --fakemachine-backend $(FAKEMACHINE_BACKEND) --memory 1GiB --scratchsize 4GiB
DEBOS_OPTS := --fakemachine-backend $(FAKEMACHINE_BACKEND) --memory 1GiB --scratchsize 6GiB
DEBOS := debos $(DEBOS_OPTS)

# Use http_proxy from the environment, or apt's http_proxy if set, to speed up
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,7 @@ debos --fakemachine-backend qemu --memory 1GiB --scratchsize 4GiB debos-recipes/
A few options are provided in the debos recipes; for the root filesystem recipe:
- `localdebs`: path to a directory with local deb packages to install (NB: debos expects relative pathnames)
- `xfcedesktop`: install an Xfce desktop environment; default: console only environment
- `gnomedesktop`: install a Gnome desktop environment; default: console only environment

For the image recipe:
- `dtb`: override the firmware provided device tree with one from the Linux kernel, e.g. `qcom/qcs6490-rb3gen2.dtb`; default: don't override
Expand Down
2 changes: 1 addition & 1 deletion debos-recipes/qualcomm-linux-debian-image.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{{- $dtb := or .dtb "firmware" }}
{{- $imagesize := or .imagesize "4.5GiB" }}
{{- $imagesize := or .imagesize "5.5GiB" }}
{{- $imagetype := or .imagetype "ufs" }}
{{- $image := printf "disk-%s.img" $imagetype }}

Expand Down
37 changes: 37 additions & 0 deletions debos-recipes/qualcomm-linux-debian-rootfs.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{{- $xfcedesktop := or .xfcedesktop "false" }}
{{- $gnomedesktop := or .gnomedesktop "false" }}
{{- $localdebs := or .localdebs "none" }}
{{- $aptlocalrepo := or .aptlocalrepo "none" }}
{{- $kernelpackage := or .kernelpackage "linux-image-arm64" }}
Expand Down Expand Up @@ -252,6 +253,40 @@ actions:
- libcamera-v4l2
{{- end }}

{{- if eq $gnomedesktop "true" }}
- action: apt
description: Install Gnome desktop
recommends: false
packages:
- plymouth-label- # we probably don't need a boot splash
# from task-gnome-desktop
- gnome-core
# from task-desktop
- desktop-base
- xdg-utils
- fonts-symbola
- avahi-daemon
- libnss-mdns
# browser
- chromium
# bluetooth settings
- blueman
# audio: wireplumber for session integration, pipewire-pulse for chromium
- pavucontrol
- pipewire-pulse
- wireplumber
# camera: mostly supported through pipewire, but pull the qcam app
# and cam CLI tool from libcamera-tools; also install libcamera
# gstreamer plugins for for gstreamer based apps; ideally, cam and
# qcam would be packaged separately as to allow pulling the CLI
# version outside of the desktop list. libcamera-v4l2 provides a
# LD_PRELOAD library for compatiblity with apps relying on v4l2
# (similar to pipewire and pulse situation)
- gstreamer1.0-libcamera
- libcamera-tools
- libcamera-v4l2
{{- end }}

- action: run
description: Set default locale
chroot: true
Expand All @@ -274,6 +309,8 @@ actions:
echo "BUILD_ID={{$buildid}}" >>/etc/buildinfo
{{- if eq $xfcedesktop "true" }}
echo "VARIANT_ID=xfce" >>/etc/buildinfo
{{- else if eq $gnomedesktop "true" }}
echo "VARIANT_ID=gnome" >>/etc/buildinfo
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Both variants can be selected though :-)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes I know… I did not have the courage to consider the case when both are selected by a funny user. The image creation may fail in the first place due to a lack of space for installing both the GNOME and XFCE desktops though. I will see what can be done in the templating language, we should probably bail out if both are selected.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you can do something like:

{{ if eq $architecture "amd64" }}
      - linux-image-amd64/trixie-backports
{{ else if eq $architecture "arm64" }}
      - linux-image-arm64/trixie-backports
  {{ fail "architecture not supported" }}
{{ else }}
  {{ fail "architecture not supported" }}
{{ end }}

{{- else }}
echo "VARIANT_ID=console" >>/etc/buildinfo
{{- end }}
Expand Down
Loading