summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--PKGBUILD20
-rw-r--r--epub2pdf.sh2
2 files changed, 20 insertions, 2 deletions
diff --git a/PKGBUILD b/PKGBUILD
index c2f1d8028c3..34ca440afb3 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -5,5 +5,21 @@ pkgdesc="epub2pdf is a command-line tool that quickly generates PDF files from E
arch=('any')
url="http://epub2pdf.com"
license=('GPL3')
-depends=('java-runtime')
-source=("$url/files/epub2pdf-0.5.zip")
+depends=('java-runtime>=6')
+source=("$url/files/epub2pdf-0.5.zip"
+"epub2pdf.sh")
+md5sums=('7189ee61628a72dfdb89120aa9e86a89'
+'SKIP')
+
+package() {
+ mkdir -p ${pkgdir}/usr/share/java/epub2pdf/
+ cd ${srcdir}/${pkgname}/
+ rm -f ./epub2pdf.bat
+ rm -f ./epub2pdf.sh
+ cp -R * ${pkgdir}/usr/share/java/epub2pdf/
+ find ${pkgdir}/usr/share/java/epub2pdf/* -type f -exec chmod 644 {} \;
+ find ${pkgdir}/usr/share/java/epub2pdf/* -type d -exec chmod 755 {} \;
+ mkdir -p ${pkgdir}/usr/bin/
+ install -Dm755 ${srcdir}/epub2pdf.sh \
+ ${pkgdir}/usr/bin/epub2pdf || return 1
+}
diff --git a/epub2pdf.sh b/epub2pdf.sh
new file mode 100644
index 00000000000..91cd5497dfb
--- /dev/null
+++ b/epub2pdf.sh
@@ -0,0 +1,2 @@
+#!/bin/bash
+/usr/sbin/java -jar /usr/share/java/epub2pdf/epub2pdf.jar $@