summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorsTiKyt2021-03-30 19:37:09 +0300
committersTiKyt2021-03-30 19:37:09 +0300
commit8d38462605d5b128472f443a930dbc56a2af4767 (patch)
tree32c6df91b899595057d9bc084d50525a872d8949
parent5cf966457da3ee1963fcae89d93dcf7050cffdbb (diff)
downloadaur-8d38462605d5b128472f443a930dbc56a2af4767.tar.gz
Added .desktop entry generation and installation
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD24
2 files changed, 24 insertions, 2 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 045c67a6b5fb..c60955c67e8c 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,5 +1,5 @@
pkgbase = draquet-polyglot-bin
- pkgdesc = PolyGlot is a conlang construction toolkit.
+ pkgdesc = PolyGlot is a conlang construction toolkit
pkgver = 3.3
pkgrel = 1
url = http://draquet.github.io/PolyGlot/index.html
diff --git a/PKGBUILD b/PKGBUILD
index d769d9f77918..97a3b6f6538c 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -13,14 +13,36 @@ provides=('draquet-polyglot')
install=
source=("${pkgname}-${pkgver}-${pkgrel}.deb::https://github.com/DraqueT/PolyGlot/releases/download/${pkgver}/PolyGlot-Ins-Lin.deb")
md5sums=('24ebc0a74fc8d4f429fed9cd2a61904e')
+
+desktopname=draquet-polyglot.desktop
+
prepare() {
cd "$srcdir"
tar -xf data.tar.xz
}
+build() {
+ # Generate .desktop entry
+ echo "[Desktop Entry]" > $desktopname
+ echo "Name=PolyGlot" >> $desktopname
+ echo "Comment=${pkgdesc}"
+ echo "Icon=draquet-polyglot" >> $desktopname
+ echo "Exec=PolyGlot" >> $desktopname
+ echo "Type=Application" >> $desktopname
+ echo "Encoding=UTF-8" >> $desktopname
+ echo "Terminal=false" >> $desktopname
+ echo "Categories=Development;Science;Translation;Dictionary;TextTools;Languages;" >> $desktopname
+}
+
package() {
- install -Dm755 $srcdir/opt/polyglot-linear-a/bin/PolyGlot "$pkgdir/usr/bin/PolyGlot"
+ # Install PolyGlot to necessary folders
+ install -Dm755 $srcdir/opt/polyglot-linear-a/bin/PolyGlot "$pkgdir/usr/bin/PolyGlot"
install -Dm644 $srcdir/opt/polyglot-linear-a/share/doc/copyright "$pkgdir/usr/share/doc/copyright"
mkdir -p "$pkgdir/usr/lib/"
cp -r $srcdir/opt/polyglot-linear-a/lib/* "$pkgdir/usr/lib/"
+
+ # Install Icon
+ install -Dm644 $srcdir/opt/polyglot-linear-a/lib/application-zip.png "$pkgdir/usr/share/pixmaps/draquet-polyglot.png"
+ # Install .desktop entry
+ install -Dm644 $srcdir/$desktopname "$pkgdir/usr/share/applications/$desktopname"
}