Browse Source

[trunk] -> [extra] 'dconf-0.32.0-3' add

master
artoo 2 months ago
parent
commit
b4c8044ab1
Signed by: artoo <artoo@artixlinux.org> GPG Key ID: 3292CD0BB0DB310B

+ 12
- 5
dconf/repos/extra-x86_64/PKGBUILD View File

@@ -3,16 +3,20 @@
3 3
 
4 4
 pkgname=dconf
5 5
 pkgver=0.32.0
6
-pkgrel=1
6
+pkgrel=3
7 7
 pkgdesc="Configuration database system"
8 8
 url="https://wiki.gnome.org/Projects/dconf"
9 9
 arch=(x86_64)
10 10
 license=(LGPL2.1)
11 11
 depends=(glib2)
12 12
 makedepends=(vala dbus git gtk-doc python meson bash-completion)
13
+install=dconf.install
13 14
 _commit=7419a726a2dbaca7781cec4eeb65bd1334a523d7  # tags/0.32.0^0
14
-source=("git+https://gitlab.gnome.org/GNOME/dconf.git#commit=$_commit")
15
-sha256sums=('SKIP')
15
+source=("git+https://gitlab.gnome.org/GNOME/dconf.git#commit=$_commit"
16
+        dconf-update.{hook,script})
17
+sha256sums=('SKIP'
18
+            '51b5c5570eac4792eb4a0efe820e3451b2019501855e57974fcd18986cf86977'
19
+            '330142605370f82f4229e8a94b245f911407eb629b50f1497f415c70164a90ec')
16 20
 
17 21
 pkgver() {
18 22
   cd $pkgname
@@ -29,11 +33,14 @@ build() {
29 33
 }
30 34
 
31 35
 check() {
32
-  meson test -C build
36
+  meson test -C build --print-errorlogs
33 37
 }
34 38
 
35 39
 package() {
36 40
   DESTDIR="$pkgdir" meson install -C build
41
+  install -Dt "$pkgdir/usr/share/libalpm/hooks" -m644 dconf-update.hook
42
+  install -D dconf-update.script "$pkgdir/usr/share/libalpm/scripts/dconf-update"
43
+  install -Dm644 /dev/null "$pkgdir/etc/dconf/db/.placeholder"
37 44
 }
38 45
 
39
-# vim:set ts=2 sw=2 et:
46
+# vim:set sw=2 et:

+ 12
- 0
dconf/repos/extra-x86_64/dconf-update.hook View File

@@ -0,0 +1,12 @@
1
+[Trigger]
2
+Type = File
3
+Operation = Install
4
+Operation = Upgrade
5
+Operation = Remove
6
+Target = etc/dconf/db/*.d/
7
+
8
+[Action]
9
+Description = Updating system dconf databases...
10
+When = PostTransaction
11
+Exec = /usr/share/libalpm/scripts/dconf-update
12
+NeedsTargets

+ 9
- 0
dconf/repos/extra-x86_64/dconf-update.script View File

@@ -0,0 +1,9 @@
1
+#!/bin/bash
2
+
3
+while read -r d; do
4
+  if [[ ! -d $d ]]; then
5
+    rm -f "${d%.d/}"
6
+  fi
7
+done
8
+
9
+dconf update

+ 11
- 0
dconf/repos/extra-x86_64/dconf.install View File

@@ -0,0 +1,11 @@
1
+post_install() {
2
+  post_upgrade $1 0
3
+}
4
+
5
+post_upgrade() {
6
+  if (( $(vercmp $2 0.32.0-2) < 0 )); then
7
+    dconf update
8
+  fi
9
+}
10
+
11
+# vim:set sw=2 et:

+ 12
- 5
dconf/trunk/PKGBUILD View File

@@ -3,16 +3,20 @@
3 3
 
4 4
 pkgname=dconf
5 5
 pkgver=0.32.0
6
-pkgrel=1
6
+pkgrel=3
7 7
 pkgdesc="Configuration database system"
8 8
 url="https://wiki.gnome.org/Projects/dconf"
9 9
 arch=(x86_64)
10 10
 license=(LGPL2.1)
11 11
 depends=(glib2)
12 12
 makedepends=(vala dbus git gtk-doc python meson bash-completion)
13
+install=dconf.install
13 14
 _commit=7419a726a2dbaca7781cec4eeb65bd1334a523d7  # tags/0.32.0^0
14
-source=("git+https://gitlab.gnome.org/GNOME/dconf.git#commit=$_commit")
15
-sha256sums=('SKIP')
15
+source=("git+https://gitlab.gnome.org/GNOME/dconf.git#commit=$_commit"
16
+        dconf-update.{hook,script})
17
+sha256sums=('SKIP'
18
+            '51b5c5570eac4792eb4a0efe820e3451b2019501855e57974fcd18986cf86977'
19
+            '330142605370f82f4229e8a94b245f911407eb629b50f1497f415c70164a90ec')
16 20
 
17 21
 pkgver() {
18 22
   cd $pkgname
@@ -29,11 +33,14 @@ build() {
29 33
 }
30 34
 
31 35
 check() {
32
-  meson test -C build
36
+  meson test -C build --print-errorlogs
33 37
 }
34 38
 
35 39
 package() {
36 40
   DESTDIR="$pkgdir" meson install -C build
41
+  install -Dt "$pkgdir/usr/share/libalpm/hooks" -m644 dconf-update.hook
42
+  install -D dconf-update.script "$pkgdir/usr/share/libalpm/scripts/dconf-update"
43
+  install -Dm644 /dev/null "$pkgdir/etc/dconf/db/.placeholder"
37 44
 }
38 45
 
39
-# vim:set ts=2 sw=2 et:
46
+# vim:set sw=2 et:

+ 12
- 0
dconf/trunk/dconf-update.hook View File

@@ -0,0 +1,12 @@
1
+[Trigger]
2
+Type = File
3
+Operation = Install
4
+Operation = Upgrade
5
+Operation = Remove
6
+Target = etc/dconf/db/*.d/
7
+
8
+[Action]
9
+Description = Updating system dconf databases...
10
+When = PostTransaction
11
+Exec = /usr/share/libalpm/scripts/dconf-update
12
+NeedsTargets

+ 9
- 0
dconf/trunk/dconf-update.script View File

@@ -0,0 +1,9 @@
1
+#!/bin/bash
2
+
3
+while read -r d; do
4
+  if [[ ! -d $d ]]; then
5
+    rm -f "${d%.d/}"
6
+  fi
7
+done
8
+
9
+dconf update

+ 11
- 0
dconf/trunk/dconf.install View File

@@ -0,0 +1,11 @@
1
+post_install() {
2
+  post_upgrade $1 0
3
+}
4
+
5
+post_upgrade() {
6
+  if (( $(vercmp $2 0.32.0-2) < 0 )); then
7
+    dconf update
8
+  fi
9
+}
10
+
11
+# vim:set sw=2 et:

Loading…
Cancel
Save