aboutsummaryrefslogtreecommitdiffstats
path: root/community/gnome-software/APKBUILD
blob: c9edd2f784d0334e4b08d2de58b66b14ae16d32b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# Contributor: Rasmus Thomsen <oss@cogitri.dev>
# Maintainer: Rasmus Thomsen <oss@cogitri.dev>
pkgname=gnome-software
pkgver=3.38.2
pkgrel=0
pkgdesc="Software lets you install and update applications and system extensions"
url="https://wiki.gnome.org/Apps/Software"
arch="all !s390x !mips !mips64"
license="GPL-2.0-or-later"
makedepends="meson appstream-glib-dev gdk-pixbuf-dev libxmlb-dev glib-dev gtk+3.0-dev
	json-glib-dev libsoup-dev gnome-desktop-dev gspell-dev polkit-dev gtk-doc
	ostree-dev flatpak-dev libgudev-dev gnome-online-accounts-dev"
options="!check" # lots of failing tests
subpackages="$pkgname-lang $pkgname-doc $pkgname-dbg $pkgname-static
	$pkgname-dev $pkgname-plugin-flatpak:flatpak_plugin"
source="https://download.gnome.org/sources/gnome-software/${pkgver%.*}/gnome-software-$pkgver.tar.xz
	org.gnome.software.gschema.override"

case "$CARCH" in
	x86*) makedepends="$makedepends fwupd-dev" ;;
esac

build() {
	case "$CARCH" in
		x86*) conf="-Dfwupd=true" ;;
		*) conf="-Dfwupd=false" ;;
	esac


	abuild-meson \
		-Dvalgrind=false \
		-Dmalcontent=false \
		-Dpackagekit=false \
		-Dexternal_appstream=true \
		$conf \
		. output
	meson compile ${JOBS:+-j ${JOBS}} -C output
}

check() {
	meson test --no-rebuild -v -C output
}

package() {
	DESTDIR="$pkgdir" meson install --no-rebuild -C output
	mkdir -p "$pkgdir"/usr/share/glib-2.0/schemas/
	sed "s|@CARCH@|$CARCH|g" "$srcdir"/org.gnome.software.gschema.override > \
		"$pkgdir"/usr/share/glib-2.0/schemas/org.gnome.software.gschema.override
}

flatpak_plugin() {
	pkgdesc="$pkgdesc (flatpak plugin)"
	install_if="$pkgname=$pkgver-r$pkgrel flatpak"
	depends=""

	amove usr/lib/gs-plugins-13/libgs_plugin_flatpak.so
	amove usr/share/metainfo/org.gnome.Software.Plugin.Flatpak.metainfo.xml
}

sha512sums="f14f84cfb7cfce4d9d09d4d4053e8bcbc281aa2045e8d231f7c3bad9a9433334d91d6d93f787533ddf02a4161b808b8657d0301fd8bdca3f2d81da8c9b52518d  gnome-software-3.38.2.tar.xz
07f82ea072ba303d785964841b3b04c963b86b79a7b1cc127b295cc0854f061a4556f6e4af4f780ae0c4de63ddd9e722db2bccd860e0c2abc8ceb6769413281f  org.gnome.software.gschema.override"