Skip to content

Commit 3284ae5

Browse files
committed
flatpak: add development variant
This variant is built in Debug mode and is given a different desktop file so it could be installed side-by-side with regular Ghostty.
1 parent a3c2e62 commit 3284ae5

File tree

3 files changed

+130
-57
lines changed

3 files changed

+130
-57
lines changed

Diff for: flatpak/com.mitchellh.ghostty.Devel.yml

+63
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
app-id: com.mitchellh.ghostty.Devel
2+
runtime: org.gnome.Platform
3+
runtime-version: "47"
4+
sdk: org.gnome.Sdk
5+
sdk-extensions:
6+
- org.freedesktop.Sdk.Extension.ziglang
7+
default-branch: tip
8+
command: ghostty
9+
# Integrate the rename into zig build, maybe?
10+
rename-desktop-file: com.mitchellh.ghostty.desktop
11+
rename-appdata-file: com.mitchellh.ghostty.metainfo.xml
12+
rename-icon: com.mitchellh.ghostty
13+
desktop-file-name-suffix: " (Devel)"
14+
finish-args:
15+
# 3D rendering
16+
- --device=dri
17+
# Windowing
18+
- --share=ipc
19+
- --socket=fallback-x11
20+
- --socket=wayland
21+
# Allow user to specify additional config files in home by default
22+
- --filesystem=home:ro
23+
# So we can escape the sandbox
24+
- --talk-name=org.freedesktop.Flatpak
25+
cleanup:
26+
- /include
27+
- /lib/girepository-1.0
28+
- /lib/pkgconfig
29+
- /share/gir-1.0
30+
- /share/pkgconfig
31+
- /share/vala
32+
- '*.la'
33+
- '*.a'
34+
- '*.so'
35+
36+
modules:
37+
- dependencies.yml
38+
39+
- name: ghostty
40+
buildsystem: simple
41+
build-options:
42+
append-path: /usr/lib/sdk/ziglang
43+
build-commands:
44+
- zig build
45+
-Doptimize=Debug
46+
-Dcpu=baseline
47+
-Dflatpak=true
48+
-Dstrip=false
49+
-fno-sys=oniguruma
50+
--prefix /app
51+
--search-prefix /app
52+
--system $PWD/vendor/p
53+
sources:
54+
- type: dir
55+
path: ..
56+
skip:
57+
- flatpak/.flatpak-builder
58+
- flatpak/builddir
59+
- flatpak/repo
60+
- zig-cache
61+
- zig-out
62+
63+
- zig-packages.json

Diff for: flatpak/com.mitchellh.ghostty.yml

+1-57
Original file line numberDiff line numberDiff line change
@@ -29,63 +29,7 @@ cleanup:
2929
- '*.so'
3030

3131
modules:
32-
- name: bzip2-redirect
33-
buildsystem: simple
34-
build-commands:
35-
- install -dm755 /app/lib
36-
- echo "INPUT(libbz2.so)" > /app/lib/libbzip2.so
37-
38-
- name: blueprint-compiler
39-
buildsystem: meson
40-
cleanup:
41-
- '*'
42-
sources:
43-
- type: git
44-
url: https://gitlab.gnome.org/jwestman/blueprint-compiler.git
45-
tag: v0.16.0
46-
commit: 04ef0944db56ab01307a29aaa7303df6067cb3c0
47-
x-checker-data:
48-
type: git
49-
tag-pattern: ^v([\d.]+)$
50-
51-
- name: gtk4-layer-shell
52-
buildsystem: meson
53-
sources:
54-
- type: git
55-
url: https://github.com/wmww/gtk4-layer-shell.git
56-
tag: v1.1.0
57-
commit: 93550245220cdc514be4701b517acd374a86acc2
58-
x-checker-data:
59-
type: git
60-
tag-pattern: ^v([\d.]+)$
61-
62-
- name: pandoc
63-
buildsystem: simple
64-
cleanup:
65-
- '*'
66-
build-commands:
67-
- install -Dm755 bin/pandoc /app/bin/pandoc
68-
sources:
69-
- type: archive
70-
sha256: d04c95c138202f87d6b00ac19aa3dd874c681f60a9feb3b55c74f764d6d1a17d
71-
url: https://github.com/jgm/pandoc/releases/download/3.6.3/pandoc-3.6.3-linux-amd64.tar.gz
72-
only-arches: [x86_64]
73-
x-checker-data:
74-
type: json
75-
url: https://api.github.com/repos/jgm/pandoc/releases/latest
76-
url-query: .assets[] | select(.name=="pandoc-" + $version + "-linux-amd64.tar.gz")
77-
| .browser_download_url
78-
version-query: .tag_name
79-
- type: archive
80-
sha256: 4e774cb1bdb6e56bc55b8eb79200bd9aa6a39905a04ecda7267f5149116f0881
81-
url: https://github.com/jgm/pandoc/releases/download/3.6.3/pandoc-3.6.3-linux-arm64.tar.gz
82-
only-arches: [aarch64]
83-
x-checker-data:
84-
type: json
85-
url: https://api.github.com/repos/jgm/pandoc/releases/latest
86-
url-query: .assets[] | select(.name=="pandoc-" + $version + "-linux-arm64.tar.gz")
87-
| .browser_download_url
88-
version-query: .tag_name
32+
- dependencies.yml
8933

9034
- name: ghostty
9135
buildsystem: simple

Diff for: flatpak/dependencies.yml

+66
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
name: dependencies-meta
2+
buildsystem: simple
3+
build-commands:
4+
- true
5+
modules:
6+
- name: bzip2-redirect
7+
buildsystem: simple
8+
build-commands:
9+
- install -Dm644 libbzip2.so /app/lib/libbzip2.so
10+
sources:
11+
- type: inline
12+
contents: INPUT(libbz2.so)
13+
dest-filename: libbzip2.so
14+
15+
- name: blueprint-compiler
16+
buildsystem: meson
17+
cleanup:
18+
- '*'
19+
sources:
20+
- type: git
21+
url: https://gitlab.gnome.org/jwestman/blueprint-compiler.git
22+
tag: v0.16.0
23+
commit: 04ef0944db56ab01307a29aaa7303df6067cb3c0
24+
x-checker-data:
25+
type: git
26+
tag-pattern: ^v([\d.]+)$
27+
28+
- name: gtk4-layer-shell
29+
buildsystem: meson
30+
sources:
31+
- type: git
32+
url: https://github.com/wmww/gtk4-layer-shell.git
33+
tag: v1.1.0
34+
commit: 93550245220cdc514be4701b517acd374a86acc2
35+
x-checker-data:
36+
type: git
37+
tag-pattern: ^v([\d.]+)$
38+
39+
- name: pandoc
40+
buildsystem: simple
41+
cleanup:
42+
- '*'
43+
build-commands:
44+
- install -Dm755 bin/pandoc /app/bin/pandoc
45+
sources:
46+
- type: archive
47+
sha256: d04c95c138202f87d6b00ac19aa3dd874c681f60a9feb3b55c74f764d6d1a17d
48+
url: https://github.com/jgm/pandoc/releases/download/3.6.3/pandoc-3.6.3-linux-amd64.tar.gz
49+
only-arches: [x86_64]
50+
x-checker-data:
51+
type: json
52+
url: https://api.github.com/repos/jgm/pandoc/releases/latest
53+
url-query: .assets[] | select(.name=="pandoc-" + $version + "-linux-amd64.tar.gz")
54+
| .browser_download_url
55+
version-query: .tag_name
56+
- type: archive
57+
sha256: 4e774cb1bdb6e56bc55b8eb79200bd9aa6a39905a04ecda7267f5149116f0881
58+
url: https://github.com/jgm/pandoc/releases/download/3.6.3/pandoc-3.6.3-linux-arm64.tar.gz
59+
only-arches: [aarch64]
60+
x-checker-data:
61+
type: json
62+
url: https://api.github.com/repos/jgm/pandoc/releases/latest
63+
url-query: .assets[] | select(.name=="pandoc-" + $version + "-linux-arm64.tar.gz")
64+
| .browser_download_url
65+
version-query: .tag_name
66+

0 commit comments

Comments
 (0)