Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

snap: migrate to core24 #177

Merged
merged 7 commits into from
May 6, 2024
Merged
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 .github/workflows/close-snap.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ jobs:
uses: canonical/actions/close-snap@release
continue-on-error: true
with:
channel: 22/edge/pr${{ github.event.number }}
channel: 24/edge/pr${{ github.event.number }}
snapcraft-token: ${{ secrets.SNAPCRAFT_TOKEN }}
1 change: 0 additions & 1 deletion .github/workflows/refresh-downstreams.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ jobs:
matrix:
ref:
- mir-libs-build
- core24

steps:
- name: Check out code
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/snap.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,4 +39,4 @@ jobs:
launchpad-credentials: ${{ secrets.LAUNCHPAD_CREDENTIALS }}
launchpad-accept-public-upload: true
publish: ${{ github.event_name == 'pull_request' && github.repository == github.event.pull_request.head.repo.full_name }}
publish-channel: 22/edge/pr${{ github.event.number }}
publish-channel: 24/edge/pr${{ github.event.number }}
4 changes: 2 additions & 2 deletions snap/hooks/configure
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,9 @@ EOT
fi


if [ -f "$SNAP/graphics/mir-quirks" ]
if [ -f "$SNAP/gpu-2404/mir-quirks" ]
then
cat "$SNAP/graphics/mir-quirks" >> "${config_temp}"
cat "$SNAP/gpu-2404/mir-quirks" >> "${config_temp}"
fi

# Fill in defaults for any options not already supplied
Expand Down
38 changes: 20 additions & 18 deletions snap/snapcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,18 @@ adopt-info: ubuntu-frame
summary: The foundation for many embedded graphical display implementations
description: ubuntu-frame is a simple fullscreen shell (based on Wayland) used for kiosks, industrial displays, digital signage, smart mirrors, etc.
confinement: strict
base: core22
base: core24
license: GPL-3.0
compression: lzo
package-repositories:
- type: apt
ppa: mir-team/release

architectures:
- build-on: amd64
- build-on: arm64
- build-on: armhf
- build-on: riscv64
platforms:
amd64:
arm64:
armhf:
riscv64:

environment:
# Prep for Mir
Expand All @@ -30,15 +30,15 @@ layout:
bind: $SNAP/usr/share/icons
/usr/share/fonts:
bind: $SNAP/usr/share/fonts
/usr/share/drirc.d: # Used by mesa-core22 for app specific workarounds
symlink: $SNAP_COMMON/graphics/drirc.d
/usr/share/drirc.d: # Used by mesa-2404 for app specific workarounds
symlink: $SNAP_COMMON/gpu-2404/drirc.d

apps:
ubuntu-frame:
command-chain:
- bin/run-user
- bin/run-frame
- bin/graphics-core22-wrapper
- bin/gpu-2404-wrapper
command: usr/local/bin/frame
plugs:
- opengl # for compositing
Expand All @@ -53,7 +53,7 @@ apps:
command-chain:
- bin/run-daemon
- bin/run-frame
- bin/graphics-core22-wrapper
- bin/gpu-2404-wrapper
command: usr/local/bin/frame
daemon: simple
restart-delay: 3s
Expand All @@ -71,7 +71,7 @@ apps:
command-chain:
- bin/anon-shm-preload
- bin/run-client
- bin/graphics-core22-wrapper
- bin/gpu-2404-wrapper
command: bin/screenshot
plugs:
- opengl
Expand All @@ -80,10 +80,10 @@ apps:
- wayland

plugs:
graphics-core22:
gpu-2404:
interface: content
target: $SNAP/graphics
default-provider: mesa-core22
target: $SNAP/gpu-2404
default-provider: mesa-2404

slots:
ubuntu-frame-diagnostic:
Expand Down Expand Up @@ -115,6 +115,7 @@ parts:
- libboost-iostreams1.74.0
# Stage libmiral<n> indirectly as we cannot (since core22) do `try:/else:`
- libmiral-dev
- xkb-data
prime:
# Do not prime the `-dev` part of libmiral-dev, we don't need it (just the libmiral<n> dependency)
- -usr/include
Expand All @@ -127,6 +128,7 @@ parts:
- fonts-ubuntu
prime:
- usr/share/fonts/truetype/ubuntu/Ubuntu-R.ttf
- usr/share/fonts/truetype/ubuntu/Ubuntu[wdth,wght].ttf

platform:
plugin: nil
Expand Down Expand Up @@ -158,20 +160,20 @@ parts:
prime:
- -usr/share/fonts/truetype/dejavu

graphics-core22:
gpu-snap:
Saviq marked this conversation as resolved.
Show resolved Hide resolved
after:
- ubuntu-frame
- assets
- platform
- icons
- scripts
- grim
source: https://github.com/MirServer/graphics-core22.git
source: https://github.com/canonical/gpu-snap.git
plugin: dump
override-prime: |
craftctl default
${CRAFT_PART_SRC}/bin/graphics-core22-cleanup mesa-core22
${CRAFT_PART_SRC}/bin/gpu-2404-cleanup mesa-2404
rm -rf ${CRAFT_PRIME}/usr/{doc,man,lintian,pkgconfig,X11}

prime:
- bin/graphics-core22-wrapper
- bin/gpu-2404-wrapper