archrelease: copy trunk to extra-x86_64
[arch-packages.git] / gnome-desktop / trunk / PKGBUILD
blob736872ee054afc1cc80d7d35927fca1951071aa0
1 # Maintainer: Jan Alexander Steffens (heftig) <heftig@archlinux.org>
2 # Contributor: Jan de Groot <jan@archlinux.org>
4 pkgbase=gnome-desktop
5 pkgname=(
6   gnome-desktop-common
7   gnome-desktop
8   gnome-desktop-4
10 pkgver=44.0
11 pkgrel=1
12 epoch=1
13 pkgdesc="Library with common API for various GNOME modules"
14 url="https://gitlab.gnome.org/GNOME/gnome-desktop"
15 arch=(x86_64)
16 license=(
17   GPL
18   LGPL
20 makedepends=(
21   bubblewrap
22   git
23   gobject-introspection
24   gsettings-desktop-schemas
25   gtk-doc
26   gtk3
27   gtk4
28   iso-codes
29   libseccomp
30   libxkbcommon
31   meson
32   systemd
33   xkeyboard-config
34   yelp-tools
36 checkdepends=(xorg-server-xvfb)
37 _commit=97c0344b3ba955bb6f6fe74ca03cc399a81acaa5  # tags/44.0^0
38 source=("git+https://gitlab.gnome.org/GNOME/gnome-desktop.git#commit=$_commit")
39 sha256sums=('SKIP')
41 pkgver() {
42   cd $pkgbase
43   git describe --tags | sed 's/[^-]*-g/r&/;s/-/+/g'
46 prepare() {
47   cd $pkgbase
50 build() {
51   local meson_options=(
52     -D debug_tools=false
53     -D gtk_doc=true
54   )
56   arch-meson $pkgbase build "${meson_options[@]}"
57   meson compile -C build
60 check() {
61   dbus-run-session xvfb-run -s '-nolisten local' \
62     meson test -C build --print-errorlogs
65 _pick() {
66   local p="$1" f d; shift
67   for f; do
68     d="$srcdir/$p/${f#$pkgdir/}"
69     mkdir -p "$(dirname "$d")"
70     mv "$f" "$d"
71     rmdir -p --ignore-fail-on-non-empty "$(dirname "$f")"
72   done
75 package_gnome-desktop-common() {
76   pkgdesc+=" (common files)"
77   depends=(
78     bubblewrap
79     gsettings-desktop-schemas
80     iso-codes
81     libseccomp
82     libxkbcommon
83     systemd
84     xkeyboard-config
85   )
87   meson install -C build --destdir "$pkgdir"
89   cd "$pkgdir"
91   _pick gtk3 usr/include/gnome-desktop-3.0
92   _pick gtk3 usr/lib/libgnome-desktop-3.so*
93   _pick gtk3 usr/lib/pkgconfig/gnome-desktop-3.0.pc
94   _pick gtk3 usr/lib/girepository-1.0/GnomeDesktop-3.0.typelib
95   _pick gtk3 usr/share/gir-1.0/GnomeDesktop-3.0.gir
97   _pick gtk4 usr/include/gnome-desktop-4.0
98   _pick gtk4 usr/lib/libgnome-*-4.so*
99   _pick gtk4 usr/lib/pkgconfig/gnome-*-4.pc
100   _pick gtk4 usr/lib/girepository-1.0/Gnome*-4.0.typelib
101   _pick gtk4 usr/share/gir-1.0/Gnome*-4.0.gir
104 package_gnome-desktop() {
105   pkgdesc+=" (GTK3)"
106   depends=(
107     gnome-desktop-common="$epoch:$pkgver-$pkgrel"
108     gtk3
109   )
110   provides=(libgnome-desktop-3.so)
112   mv gtk3/* "$pkgdir"
115 package_gnome-desktop-4() {
116   pkgdesc+=" (GTK4)"
117   depends=(
118     gnome-desktop-common="$epoch:$pkgver-$pkgrel"
119     gtk4
120   )
121   provides=(libgnome-{bg,desktop,rr}-4.so)
123   mv gtk4/* "$pkgdir"
126 # vim:set sw=2 sts=-1 et: