summaryrefslogtreecommitdiff
path: root/user/shared-mime-info
diff options
context:
space:
mode:
authorA. Wilcox <AWilcox@Wilcox-Tech.com>2018-07-06 03:36:45 -0500
committerA. Wilcox <AWilcox@Wilcox-Tech.com>2018-07-06 03:36:50 -0500
commit08f00007e11dfded1ce9c65b5eb212164079c237 (patch)
tree3955a9afd17b9f46fa26c8edb0c316c4b628fa29 /user/shared-mime-info
parentaa7977f03becc5d5941c97d1ad2ef8dd33a14c7f (diff)
downloadpackages-08f00007e11dfded1ce9c65b5eb212164079c237.tar.gz
packages-08f00007e11dfded1ce9c65b5eb212164079c237.tar.bz2
packages-08f00007e11dfded1ce9c65b5eb212164079c237.tar.xz
packages-08f00007e11dfded1ce9c65b5eb212164079c237.zip
user/shared-mime-info: pull in, bump, take, fix
Diffstat (limited to 'user/shared-mime-info')
-rw-r--r--user/shared-mime-info/APKBUILD37
-rw-r--r--user/shared-mime-info/shared-mime-info.post-deinstall10
-rw-r--r--user/shared-mime-info/shared-mime-info.trigger8
3 files changed, 55 insertions, 0 deletions
diff --git a/user/shared-mime-info/APKBUILD b/user/shared-mime-info/APKBUILD
new file mode 100644
index 000000000..e28f8915f
--- /dev/null
+++ b/user/shared-mime-info/APKBUILD
@@ -0,0 +1,37 @@
+# Maintainer: A. Wilcox <awilfox@adelielinux.org>
+pkgname=shared-mime-info
+pkgver=1.10
+pkgrel=0
+pkgdesc="MIME database for desktop software"
+url="https://freedesktop.org/wiki/Software/shared-mime-info"
+arch="all"
+license="GPL-2.0+"
+makedepends="glib-dev intltool libxml2-dev libxml2-utils"
+depends=
+install="$pkgname.post-deinstall"
+triggers="$pkgname.trigger=/usr/share/mime"
+subpackages="$pkgname-doc $pkgname-lang"
+source="https://freedesktop.org/~hadess/$pkgname-$pkgver.tar.xz"
+
+build() {
+ cd "$builddir"
+ ac_cv_func_fdatasync=no ./configure \
+ --build=$CBUILD \
+ --host=$CHOST \
+ --prefix=/usr \
+ --enable-default-make-check \
+ --disable-update-mimedb
+ make -j1
+}
+
+check() {
+ cd "$builddir"
+ make check
+}
+
+package() {
+ cd "$builddir"
+ make -j1 DESTDIR="$pkgdir" install
+}
+
+sha512sums="efc2b63cae11e6b0332f8607ba57a885dec68a23ac299bbda3eb6e2c7ed071c7c40dba73e9cf23ab675fcaa86ea3777fa931a9f25000a08ec6a748734c88beda shared-mime-info-1.10.tar.xz"
diff --git a/user/shared-mime-info/shared-mime-info.post-deinstall b/user/shared-mime-info/shared-mime-info.post-deinstall
new file mode 100644
index 000000000..6c3172902
--- /dev/null
+++ b/user/shared-mime-info/shared-mime-info.post-deinstall
@@ -0,0 +1,10 @@
+#!/bin/sh
+
+cd /usr/share/mime
+rm -rf globs globs2 icons treemagic generic-icons types magic XMLnamespaces \
+ subclasses aliases mime.cache \
+ application audio image inode message model multipart text video \
+ x-content x-epoc
+rmdir /usr/share/mime 2>/dev/null
+
+exit 0
diff --git a/user/shared-mime-info/shared-mime-info.trigger b/user/shared-mime-info/shared-mime-info.trigger
new file mode 100644
index 000000000..be5371242
--- /dev/null
+++ b/user/shared-mime-info/shared-mime-info.trigger
@@ -0,0 +1,8 @@
+#!/bin/sh
+
+for i in "$@"; do
+ if [ -d "$i" ]; then
+ update-mime-database "$i" > /dev/null 2>&1
+ fi
+done
+sync