Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Creating Flatpak packages without flatpak-builder
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Bartłomiej Piotrowski
November 09, 2021
Programming
96
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Creating Flatpak packages without flatpak-builder
Bartłomiej Piotrowski
November 09, 2021
More Decks by Bartłomiej Piotrowski
See All by Bartłomiej Piotrowski
Flathub: The State of the Union
barthalion
0
33
OpenStack Swift
barthalion
0
72
Reproducible builds
barthalion
0
300
Alpine Linux
barthalion
0
420
Wprowadzenie do tworzenia pakietów w Arch Linuksie
barthalion
0
460
Arch Linux
barthalion
0
77
Other Decks in Programming
See All in Programming
freee が目指す データ マネジメント戦略 AI-Ready 時代を支える 攻めのガバナンスとは
freee
PRO
0
470
Go を使い始めて 2 ヶ月の学び / My first two months with Go
contour_gara
0
370
Gmail/Google DriveをトリガーにAIエージェントを動かそう! / Run AI agents with Gmail/Google Drive as triggers!
har1101
2
430
in-process GraphQL のすすめ #ginzajs
izumin5210
4
1.5k
Detecting Compromised CI with eBPF and Cilium Tetragon
lizrice
0
250
Cloudflare is Agents
chimame
0
180
ソフトウェアラスタライザ
fadis
1
600
freeeにおけるEvalsの実践例の紹介
freee
PRO
0
150
人間の目はかわらない、だからJPEGは30年もつ
yuzneri
12
19k
DynamoDBの基礎を振り返りながらベクトル検索機能を理解する
musan
2
160
AI Engineeringは、AIプロダクトだけのものか? 〜AIがソフトウェアを作る時代の新しい当たり前〜 / No AI in your product. AI Engineering in your development.
rkaga
5
520
Flow は今どうなっているか
mizdra
PRO
0
690
Featured
See All Featured
Rebuilding a faster, lazier Slack
samanthasiow
85
9.6k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
38
3k
Paper Plane (Part 1)
katiecoart
PRO
1
10k
KATA
mclloyd
PRO
35
15k
Imperfection Machines: The Place of Print at Facebook
scottboms
270
14k
16th Malabo Montpellier Forum Presentation
akademiya2063
PRO
0
360
Design of three-dimensional binary manipulators for pick-and-place task avoiding obstacles (IECON2024)
konakalab
0
550
HU Berlin: Industrial-Strength Natural Language Processing with spaCy and Prodigy
inesmontani
PRO
0
660
Building a A Zero-Code AI SEO Workflow
portentint
PRO
0
690
YesSQL, Process and Tooling at Scale
rocio
174
15k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
52
6k
Building a Modern Day E-commerce SEO Strategy
aleyda
45
9.2k
Transcript
Building Flatpak apps without flatpak-builder Bartłomiej Piotrowski PackagingCon 2021
What is Flatpak?
app-id: org.flatpak.Hello runtime: org.freedesktop.Platform runtime-version: '21.08' sdk: org.freedesktop.Sdk command: hello
modules: - name: hello buildsystem: autotools sources: - type: archive url: https://ftp.gnu.org/gnu/hello/hello-2.10.tar.gz sha256: 31e066137(..)
CI is hard (and gotta go fast)
Let’s build a somewhat portable binary!
None
$ cat builddir/metadata [Application] name=org.flatpak.ncdu runtime=org.freedesktop.Platform/x86_64/21.08 sdk=org.freedesktop.Sdk/x86_64/21.08 command=ncdu
$ tree builddir builddir ├── export ├── files │ ├──
bin │ │ └── ncdu │ ├── lib │ │ ├── libncurses.so.5 │ │ └── libtinfo.so.5 │ └── share │ ├── locale -> /app/share/runtime/locale │ └── runtime │ └── locale │ └── en │ └── batman
$ tree builddir builddir ├── export ├── files │ ├──
bin │ │ └── ncdu │ ├── lib │ │ ├── libncurses.so.5 │ │ └── libtinfo.so.5 │ └── share │ ├── locale -> /app/share/runtime/locale │ └── runtime │ └── locale │ └── en │ └── batman
$ tree builddir builddir ├── export ├── files │ ├──
bin │ │ └── ncdu │ ├── lib │ │ ├── libncurses.so.5 │ │ └── libtinfo.so.5 │ └── share │ ├── locale -> /app/share/runtime/locale │ └── runtime │ └── locale │ └── en │ └── batman
$ cat << EOF > metadata [Extension org.flatpak.ncdu.Locale] directory=share/runtime/locale autodelete=true
locale-subset=true EOF
$ cat builddir/metadata.locale [Runtime] name=org.flatpak.ncdu.Locale [ExtensionOf] ref=app/org.flatpak.ncdu/x86_64/master
$ flatpak build-finish \ --filesystem=home \ builddir $ cat builddir/metadata
(...) [Context] filesystems=home;
$ flatpak build-export \ --exclude='/share/runtime/locale/*/*' \ repo build master $
flatpak build-export \ --metadata=metadata.locale \ --files=files/share/runtime/locale \ repo build master
$ flatpak build-export \ --exclude='/share/runtime/locale/*/*' \ repo build master $
flatpak build-export \ --metadata=metadata.locale \ --files=files/share/runtime/locale \ repo build master
$ flatpak build-export \ --exclude='/share/runtime/locale/*/*' \ repo build master $
flatpak build-export \ --metadata=metadata.locale \ --files=files/share/runtime/locale \ repo build master
https://hg.mozilla.org/mozilla-central/file/tip/ taskcluster/docker/firefox-flatpak/runme.sh
https://buildstream.build/ https://pagure.io/flatpak-module-tools
Demo
Thank you!
[email protected]
https://barthalion.blog Twitter: @barthalion https://flatpak.org https://flathub.org