summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD204
1 files changed, 103 insertions, 101 deletions
diff --git a/PKGBUILD b/PKGBUILD
index c4b6d1cce53..0e1fb49640c 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,12 +1,13 @@
-# Maintainer: Det
+# Maintainer: Mohammadreza Abdollahzadeh <morealaz at gmail dot com>
+# Contributors: Det
# Contributors: Damian Nowak
_pkgname=jdk
pkgname=bin32-jdk
_major=8
-_minor=192
-_build=b12
-_hash=750e1c8617c5452694857ad95c3ee230
+_minor=202
+_build=b08
+_hash=1961070e4c9b4e26a04e7f5a083f551e
pkgver=${_major}u${_minor}
pkgrel=1
pkgdesc="Oracle Java $_major Development Kit (32-bit)"
@@ -50,7 +51,7 @@ source=("http://download.oracle.com/otn-pub/java/jdk/$pkgver-$_build/$_hash/$_pk
"jmc32-$_jname.desktop"
"jvisualvm32-$_jname.desktop"
"policytool32-$_jname.desktop")
-md5sums=('21a498e710233dcd40b089566a726751'
+md5sums=('ddae517017646fc180d5241260d515e8'
'b3c7031bc65c28c2340302065e7d00d3'
'30d35416b403c621fb02d0dc0b115c05'
'9dfed511010a54eb377b692638d17585'
@@ -58,100 +59,101 @@ md5sums=('21a498e710233dcd40b089566a726751'
'65d3a4147634b7cf0923caafed7edda4')
package() {
- cd ${_pkgname}1.${_major}.0_${_minor}
-
- msg2 "Creating directory structure..."
- install -d "$pkgdir"/etc/.java/.systemPrefs
- install -d "$pkgdir"/usr/lib32/jvm/java32-$_major-$_pkgname/bin
- install -d "$pkgdir"/usr/lib32/mozilla/plugins
- install -d "$pkgdir"/usr/share/licenses/java${_major}-${_pkgname}32
-
- msg2 "Removing redundancies..."
- rm -r jre/lib/desktop/icons/HighContrast/
- rm -r jre/lib/desktop/icons/HighContrastInverse/
- rm -r jre/lib/desktop/icons/LowContrast/
- rm jre/lib/fontconfig.*.bfc
- rm jre/lib/fontconfig.*.properties.src
- rm -r jre/plugin/
- rm jre/*.txt
- rm jre/COPYRIGHT
- rm jre/LICENSE
- rm jre/README
- rm man/ja
-
- msg2 "Moving contents..."
- mv * "$pkgdir"/$_jvmdir
-
- # Cd to the new playground
- cd "$pkgdir"/$_jvmdir
-
- msg2 "Fixing directory structure..."
- # Replace duplicate binaries in bin/ with links to jre/bin/
- for i in $(ls jre/bin/); do
- ln -sf "$_jvmdir/jre/bin/$i" "bin/$i"
- done
-
- # Suffix .desktops + icons (sun-java.png -> sun-java32-$_jname.png)
- for i in $(find jre/lib/desktop/ -type f); do
- rename -- "." "32-$_jname." $i
- done
-
- # Fix .desktop paths
- sed -e "s|Exec=|Exec=$_jvmdir/jre/bin/|" \
- -e "s|.png|32-$_jname.png|" \
- -i jre/lib/desktop/applications/*
-
- # Move .desktops + icons to /usr/share
- mv jre/lib/desktop/* "$pkgdir"/usr/share/
- install -m644 "$srcdir"/*.desktop "$pkgdir"/usr/share/applications/
-
- # Move confs to /etc and link back to /usr: /usr/lib32/jvm/java32-$_jname/jre/lib -> /etc
- for new_etc_path in ${backup[@]}; do
- # Old location
- old_usr_path="jre/lib/${new_etc_path#*$_jname/}"
-
- # Move
- install -Dm644 "$old_usr_path" "$pkgdir/$new_etc_path"
- ln -sf "/$new_etc_path" "$old_usr_path"
- done
-
- # Link NPAPI plugin
- ln -sf $_jvmdir/jre/lib/i386/libnpjp2.so "$pkgdir"/usr/lib32/mozilla/plugins/libnpjp2-$_jname.so
-
- # Replace JKS keystore with 'ca-certificates-java'
- ln -sf /etc/ssl/certs/java/cacerts jre/lib/security/cacerts
-
- # Suffix man pages
- for i in $(find man/ -type f); do
- mv "$i" "${i/.1}32-$_jname.1"
- done
-
- # Move man pages
- mv man/ja_JP.UTF-8/ man/ja
- mv man/ "$pkgdir"/usr/share
-
- # Move/link licenses
- mv COPYRIGHT LICENSE *.txt "$pkgdir"/usr/share/licenses/java${_major}-${_pkgname}32/
- ln -sf /usr/share/licenses/java${_major}-${_pkgname}32/ "$pkgdir"/usr/share/licenses/$pkgname
-
- msg2 "Installing Java Cryptography Extension (JCE) Unlimited Strength Jurisdiction Policy Files..."
- # Replace default "strong", but limited, cryptography to get an "unlimited strength" one for
- # things like 256-bit AES. Enabled by default in OpenJDK:
- # - http://suhothayan.blogspot.com/2012/05/how-to-install-java-cryptography.html
- # - http://www.eyrie.org/~eagle/notes/debian/jce-policy.html
- install -m644 "$srcdir"/UnlimitedJCEPolicyJDK$_major/*.jar jre/lib/security/
- install -Dm644 "$srcdir"/UnlimitedJCEPolicyJDK$_major/README.txt \
- "$pkgdir"/usr/share/doc/$pkgname/README_-_Java_JCE_Unlimited_Strength.txt
-
- msg2 "Enabling copy+paste in unsigned applets..."
- # Copy/paste from system clipboard to unsigned Java applets has been disabled since 6u24:
- # - https://blogs.oracle.com/kyle/entry/copy_and_paste_in_java
- # - http://slightlyrandombrokenthoughts.blogspot.com/2011/03/oracle-java-applet-clipboard-injection.html
- _line=$(awk '/permission/{a=NR}; END{print a}' "$pkgdir"/etc/java32-$_jname/security/java.policy)
- sed "$_line a\\\\n \
- // (AUR) Allow unsigned applets to read system clipboard, see:\n \
- // - https://blogs.oracle.com/kyle/entry/copy_and_paste_in_java\n \
- // - http://slightlyrandombrokenthoughts.blogspot.com/2011/03/oracle-java-applet-clipboard-injection.html\n \
- permission java.awt.AWTPermission \"accessClipboard\";" \
- -i "$pkgdir"/etc/java32-$_jname/security/java.policy
+ cd ${_pkgname}1.${_major}.0_${_minor}
+
+ msg2 "Creating directory structure..."
+ install -d "$pkgdir"/etc/.java/.systemPrefs
+ install -d "$pkgdir"/usr/lib32/jvm/java32-$_major-$_pkgname/bin
+ install -d "$pkgdir"/usr/lib32/mozilla/plugins
+ install -d "$pkgdir"/usr/share/licenses/java${_major}-${_pkgname}32
+
+ msg2 "Removing redundancies..."
+ rm -r jre/lib/desktop/icons/HighContrast/
+ rm -r jre/lib/desktop/icons/HighContrastInverse/
+ rm -r jre/lib/desktop/icons/LowContrast/
+ rm jre/lib/fontconfig.*.bfc
+ rm jre/lib/fontconfig.*.properties.src
+ rm -r jre/plugin/
+ rm jre/*.txt
+ rm jre/COPYRIGHT
+ rm jre/LICENSE
+ rm jre/README
+ rm man/ja
+
+ msg2 "Moving contents..."
+ mv * "$pkgdir"/$_jvmdir
+
+ # Cd to the new playground
+ cd "$pkgdir"/$_jvmdir
+
+ msg2 "Fixing directory structure..."
+ # Replace duplicate binaries in bin/ with links to jre/bin/
+ for i in $(ls jre/bin/); do
+ ln -sf "$_jvmdir/jre/bin/$i" "bin/$i"
+ done
+
+ # Suffix .desktops + icons (sun-java.png -> sun-java32-$_jname.png)
+ for i in $(find jre/lib/desktop/ -type f); do
+ rename -- "." "32-$_jname." $i
+ done
+
+ # Fix .desktop paths
+ sed -e "s|Exec=|Exec=$_jvmdir/jre/bin/|" \
+ -e "s|.png|32-$_jname.png|" \
+ -i jre/lib/desktop/applications/*
+
+ # Move .desktops + icons to /usr/share
+ mv jre/lib/desktop/* "$pkgdir"/usr/share/
+ install -m644 "$srcdir"/*.desktop "$pkgdir"/usr/share/applications/
+
+ # Move confs to /etc and link back to /usr: /usr/lib32/jvm/java32-$_jname/jre/lib -> /etc
+ for new_etc_path in ${backup[@]}; do
+ # Old location
+ old_usr_path="jre/lib/${new_etc_path#*$_jname/}"
+
+ # Move
+ install -Dm644 "$old_usr_path" "$pkgdir/$new_etc_path"
+ ln -sf "/$new_etc_path" "$old_usr_path"
+ done
+
+ # Link NPAPI plugin
+ ln -sf $_jvmdir/jre/lib/i386/libnpjp2.so "$pkgdir"/usr/lib32/mozilla/plugins/libnpjp2-$_jname.so
+
+ # Replace JKS keystore with 'ca-certificates-java'
+ ln -sf /etc/ssl/certs/java/cacerts jre/lib/security/cacerts
+
+ # Suffix man pages
+ for i in $(find man/ -type f); do
+ mv "$i" "${i/.1}32-$_jname.1"
+ done
+
+ # Move man pages
+ mv man/ja_JP.UTF-8/ man/ja
+ mv man/ "$pkgdir"/usr/share
+
+ # Move/link licenses
+ mv COPYRIGHT LICENSE *.txt "$pkgdir"/usr/share/licenses/java${_major}-${_pkgname}32/
+ ln -sf /usr/share/licenses/java${_major}-${_pkgname}32/ "$pkgdir"/usr/share/licenses/$pkgname
+
+ msg2 "Installing Java Cryptography Extension (JCE) Unlimited Strength Jurisdiction Policy Files..."
+ # Replace default "strong", but limited, cryptography to get an "unlimited strength" one for
+ # things like 256-bit AES. Enabled by default in OpenJDK:
+ # - http://suhothayan.blogspot.com/2012/05/how-to-install-java-cryptography.html
+ # - http://www.eyrie.org/~eagle/notes/debian/jce-policy.html
+ install -m644 "$srcdir"/UnlimitedJCEPolicyJDK$_major/*.jar jre/lib/security/
+ install -Dm644 "$srcdir"/UnlimitedJCEPolicyJDK$_major/README.txt \
+ "$pkgdir"/usr/share/doc/$pkgname/README_-_Java_JCE_Unlimited_Strength.txt
+
+ msg2 "Enabling copy+paste in unsigned applets..."
+ # Copy/paste from system clipboard to unsigned Java applets has been disabled since 6u24:
+ # - https://blogs.oracle.com/kyle/entry/copy_and_paste_in_java
+ # - http://slightlyrandombrokenthoughts.blogspot.com/2011/03/oracle-java-applet-clipboard-injection.html
+ _line=$(awk '/permission/{a=NR}; END{print a}' "$pkgdir"/etc/java32-$_jname/security/java.policy)
+ sed "$_line a\\\\n \
+ // (AUR) Allow unsigned applets to read system clipboard, see:\n \
+ // - https://blogs.oracle.com/kyle/entry/copy_and_paste_in_java\n \
+ // - http://slightlyrandombrokenthoughts.blogspot.com/2011/03/oracle-java-applet-clipboard-injection.html\n \
+ permission java.awt.AWTPermission \"accessClipboard\";" \
+ -i "$pkgdir"/etc/java32-$_jname/security/java.policy
}
+# vim:set ts=2 sw=2 et: