summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorshmilee2017-04-07 13:02:32 +0800
committershmilee2017-04-07 13:21:15 +0800
commit88d7ede39181c1d43216e35a7f3ec49741af54cf (patch)
tree6a555847461e08c16627e3197d1535faea3b6c8c
parent9451a5c2e75d99c00991e948524bc41d851cbe67 (diff)
downloadaur-88d7ede39181c1d43216e35a7f3ec49741af54cf.tar.gz
add translations, help files, jpeg2000 and PDF support
* about depends: ``` [$]ldd engauge|grep -E 'png|jp|poppler' libopenjp2.so.7 => /usr/lib/libopenjp2.so.7 (0x00007fb719897000) libpoppler-qt5.so.1 => /usr/lib/libpoppler-qt5.so.1 (0x00007fb71961d000) libpoppler.so.66 => /usr/lib/libpoppler.so.66 (0x00007fb715fb9000) libpng16.so.16 => /usr/lib/libpng16.so.16 (0x00007fb715643000) libjpeg.so.8 => /usr/lib/libjpeg.so.8 (0x00007fb7131ba000) ``` * no file /usr/share/doc/engauge/usermanual * add a shell script wrapper for engauge
-rw-r--r--PKGBUILD45
-rw-r--r--engauge.desktop6
-rw-r--r--engauge.install8
-rw-r--r--engauge.sh3
4 files changed, 42 insertions, 20 deletions
diff --git a/PKGBUILD b/PKGBUILD
index ce9ae0b2c85..860121ff8e6 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -10,27 +10,45 @@ pkgrel=1
url="http://markummitchell.github.io/engauge-digitizer/"
arch=('i686' 'x86_64')
license=('GPL')
-optdepends=('libpng12: For reading png image files'
- 'libjpeg-turbo: For reading jpeg image files'
- 'openjpeg: For reading jpeg2000 image files')
-source=("$pkgbase-$pkgver.tar.gz::https://github.com/markummitchell/$_pkgbase/archive/v$pkgver.tar.gz" "$pkgbase.desktop")
+makedepends=('qt5-tools' 'fftw' 'log4cpp' 'libjpeg-turbo' 'libpng' 'openjpeg2<2.2' 'poppler-qt5')
+source=("$pkgbase-$pkgver.tar.gz::https://github.com/markummitchell/$_pkgbase/archive/v$pkgver.tar.gz"
+ "$pkgbase.sh"
+ "$pkgbase.desktop")
md5sums=('24ca9841ccefff0645c157e2fa72daa9'
- '53def24f20c3d0178d3cf1b8c574fe15')
+ 'baa6e2963962785d145b63510ba4ee51'
+ '95398291d4e0bb4adc1fec22a16625b9')
install=engauge.install
build() {
cd "$srcdir/${_pkgbase}-$pkgver"
- qmake-qt5 engauge.pro
- make
+ export OPENJPEG_INCLUDE=/usr/include/openjpeg-2.1 OPENJPEG_LIB=/usr/lib # openjpeg2 2.1.x
+ export POPPLER_INCLUDE=/usr/include/poppler/qt5 POPPLER_LIB=/usr/lib
+ qmake-qt5 engauge.pro "CONFIG+=jpeg2000 pdf"
+ make -j2
+ lrelease engauge.pro
+ cd help/
+ ./build
}
package_engauge() {
pkgdesc="Extracts data points from images of graphs"
- depends=('qt5-tools' 'fftw' 'log4cpp')
+ depends=('qt5-tools' 'fftw' 'log4cpp' 'libpng' 'libjpeg-turbo' 'openjpeg2' 'poppler-qt5')
+
cd "$srcdir/${_pkgbase}-$pkgver"
- install -Dm755 bin/$pkgname "$pkgdir/usr/bin/$pkgname"
- install -Dm644 help/animation.png \
- "$pkgdir/usr/share/icons/$pkgname.png"
+ install -Dm755 ../$pkgbase.sh "$pkgdir/usr/bin/$pkgbase"
+ install -Dm755 bin/engauge "$pkgdir/usr/share/$_pkgbase/engauge"
+ # translations
+ install -dm755 "$pkgdir/usr/share/$_pkgbase/translations/"
+ cp translations/*.qm "$pkgdir/usr/share/$_pkgbase/translations/"
+ # help
+ install -Dm644 bin/documentation/engauge.qhc \
+ "$pkgdir/usr/share/$_pkgbase/documentation/engauge.qhc"
+ install -Dm644 bin/documentation/engauge.qch \
+ "$pkgdir/usr/share/$_pkgbase/documentation/engauge.qch"
+ # icon
+ install -Dm644 src/img/$_pkgbase.svg \
+ "$pkgdir/usr/share/icons/$_pkgbase.svg"
+ # desktop
install -Dm644 $srcdir/$pkgbase.desktop \
"$pkgdir/usr/share/applications/$pkgbase.desktop"
}
@@ -38,7 +56,8 @@ package_engauge() {
package_engauge-samples() {
pkgdesc="sample image files for engauge copied into the doc subdirectory"
arch=('any')
+
cd "$srcdir/${_pkgbase}-$pkgver"
- install -d "$pkgdir/usr/share/doc/$pkgbase"
- cp -r samples "$pkgdir/usr/share/doc/$pkgbase"
+ install -d "$pkgdir/usr/share/doc/$_pkgbase"
+ cp -r samples "$pkgdir/usr/share/doc/$_pkgbase"
}
diff --git a/engauge.desktop b/engauge.desktop
index 900bdb17db4..659a8b817f3 100644
--- a/engauge.desktop
+++ b/engauge.desktop
@@ -1,8 +1,8 @@
[Desktop Entry]
Name=Engauge
Comment=A Digitizer for curves and scanned plots.
-Exec=engauge -manual /usr/share/doc/engauge/usermanual
-Icon=engauge
+Exec=engauge
+Icon=engauge-digitizer
Terminal=0
Type=Application
-Categories=Science;Math; \ No newline at end of file
+Categories=Education;Science;Math;
diff --git a/engauge.install b/engauge.install
index b8906aff7a3..7117e312b9d 100644
--- a/engauge.install
+++ b/engauge.install
@@ -1,6 +1,6 @@
post_install() {
- echo "To read the manual from within engauge, "
- echo "run engauge the following way:"
- echo "engauge -manual /usr/share/engauge/doc/usermanual/"
- echo "Or set the variable ENGAUGE_USERMANUL accordingly."
+ echo "If you want several sample image files that may be imported into Engauge Digitizer, "
+ echo "please install engauge-samples:"
+ echo "sudo pacman -S engauge-samples"
+ echo "The files are in directory /usr/share/doc/engauge-digitizer/samples/"
}
diff --git a/engauge.sh b/engauge.sh
new file mode 100644
index 00000000000..71a59879947
--- /dev/null
+++ b/engauge.sh
@@ -0,0 +1,3 @@
+#!/usr/bin/env bash
+cd /usr/share/engauge-digitizer
+./engauge "$@"