summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorprofessorkaos642016-11-18 13:48:14 -0500
committerprofessorkaos642016-11-18 13:48:14 -0500
commitcc83985fe40d6c04bbf7ee2b3d74bd8cf338404d (patch)
treee0dbec17a8016da15e7d24221d4ed685542664bc
parent01d776ad8dcd3a02ecf7a9363fca167a1214650e (diff)
downloadaur-cc83985fe40d6c04bbf7ee2b3d74bd8cf338404d.tar.gz
rework launch script
-rw-r--r--.SRCINFO4
-rw-r--r--PKGBUILD21
-rwxr-xr-xPlayOnLinux.sh11
3 files changed, 27 insertions, 9 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 714bf81434d..a6580110f2a 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = playonlinux5-git
pkgdesc = GUI for managing Windows programs under linux (development version based on Java)
pkgver = r1262.6404de4
- pkgrel = 4
+ pkgrel = 5
epoch = 2
url = http://www.playonlinux.com/
arch = any
@@ -14,8 +14,10 @@ pkgbase = playonlinux5-git
options = !strip
source = playonlinux5::git://github.com/PlayOnLinux/POL-POM-5.git
source = PlayOnLinux5.desktop
+ source = PlayOnLinux.sh
md5sums = SKIP
md5sums = 7fe925810fc7ec6d8745817b1c541e7b
+ md5sums = aaddf3cb2070b9329c01eb8b5f9d8438
pkgname = playonlinux5-git
diff --git a/PKGBUILD b/PKGBUILD
index f42fc3fd41c..3671e858d7c 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -11,7 +11,7 @@
_pkgname=playonlinux5
pkgname=$_pkgname-git
pkgver=r1262.6404de4
-pkgrel=4
+pkgrel=5
epoch=2
pkgdesc="GUI for managing Windows programs under linux (development version based on Java)"
arch=('any')
@@ -20,10 +20,16 @@ license=('GPL')
makedepends=('gradle' 'maven' 'java-openjfx' 'jdk8-openjdk')
depends=('wine')
options=(!strip)
-source=("$_pkgname::git://github.com/PlayOnLinux/POL-POM-5.git"
- 'PlayOnLinux5.desktop')
-md5sums=('SKIP'
- '7fe925810fc7ec6d8745817b1c541e7b')
+source=(
+ "$_pkgname::git://github.com/PlayOnLinux/POL-POM-5.git"
+ 'PlayOnLinux5.desktop'
+ 'PlayOnLinux.sh'
+ )
+md5sums=(
+ 'SKIP'
+ '7fe925810fc7ec6d8745817b1c541e7b'
+ 'aaddf3cb2070b9329c01eb8b5f9d8438'
+ )
pkgver() {
cd "$_pkgname"
@@ -37,6 +43,7 @@ build() {
cd "$_pkgname"
# Set environment
+ # Use path to Java 8 for users nkt defaulted to Java 8 yet
export JAVA_HOME="/usr/lib/jvm/java-8-openjdk"
# Clean up
@@ -53,9 +60,7 @@ package() {
cp -r phoenicis-dist/ "$pkgdir/opt/$_pkgname/"
# Launcher
- install -d "$pkgdir/usr/bin/"
- ln -s "/opt/$_pkgname/PlayOnLinux.sh" "$pkgdir/usr/bin/$_pkgname"
- sed -i 's|$(dirname $0)|/opt/playonlinux5|' "$pkgdir/opt/$_pkgname/PlayOnLinux.sh"
+ install -Dm755 "PlayOnLinux.sh" "$pkgdir/usr/bin/PlayOnLinux.sh"
# Icon + Desktop
install -Dm644 "$srcdir/$_pkgname/phoenicis-javafx/target/classes/com/playonlinux/javafx/common/playonlinux.png" \
diff --git a/PlayOnLinux.sh b/PlayOnLinux.sh
new file mode 100755
index 00000000000..9cbc1091bb0
--- /dev/null
+++ b/PlayOnLinux.sh
@@ -0,0 +1,11 @@
+POL_HOME=/opt/playonlinux5
+CLASSPATH=${CLASSPATH}:$POL_HOME/lib/*
+
+# Ensure we are using the right java env
+# Don't necessarily force default Java 8, as it is not the default for Arch Linux right now
+# This handles users with Java 7 and 8
+export PATH=/usr/lib/jvm/java-8-openjdk/jre/bin/:$PATH
+
+java -classpath "$CLASSPATH" com.playonlinux.app.PlayOnLinuxApp "$@"
+
+# Unset