summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorDet2015-06-14 04:13:27 +0300
committerDet2015-06-14 04:14:15 +0300
commit8713652ded67113dd41ad33fe148c1cd0ddf66bf (patch)
tree6aa3cf2e681c0c6d047e7316af6f83d1a99f6908
downloadaur-8713652ded67113dd41ad33fe148c1cd0ddf66bf.tar.gz
Initial import: 6u45-3
-rw-r--r--.SRCINFO65
-rw-r--r--PKGBUILD157
-rw-r--r--bin32-jdk6.install71
-rw-r--r--javaws-launcher7
-rw-r--r--jconsole32-jdk6.desktop8
-rw-r--r--jmc32-jdk6.desktop8
-rw-r--r--jvisualvm32-jdk6.desktop9
-rw-r--r--policytool32-jdk6.desktop8
8 files changed, 333 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..9dc1f9b370c
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,65 @@
+pkgbase = bin32-jdk6
+ pkgdesc = Oracle Java 6 Development Kit (32-bit) (public release - end of support)
+ pkgver = 6u45
+ pkgrel = 3
+ url = https://www.java.com/en/download/faq/java_6.xml
+ install = bin32-jdk6.install
+ arch = x86_64
+ license = custom
+ provides = java32-runtime=6
+ provides = java32-runtime-headless=6
+ provides = java32-web-start=6
+ provides = java32-environment=6
+ provides = java32-runtime-jre=6
+ provides = java32-runtime-headless-jre=6
+ provides = java32-web-start-jre=6
+ provides = java32-environment-jdk=6
+ options = !strip
+ backup = etc/java32-jdk6/i386/jvm.cfg
+ backup = etc/java32-jdk6/images/cursors/cursors.properties
+ backup = etc/java32-jdk6/management/jmxremote.access
+ backup = etc/java32-jdk6/management/management.properties
+ backup = etc/java32-jdk6/security/java.policy
+ backup = etc/java32-jdk6/security/java.security
+ backup = etc/java32-jdk6/security/javaws.policy
+ backup = etc/java32-jdk6/content-types.properties
+ backup = etc/java32-jdk6/flavormap.properties
+ backup = etc/java32-jdk6/fontconfig.properties.src
+ backup = etc/java32-jdk6/logging.properties
+ backup = etc/java32-jdk6/net.properties
+ backup = etc/java32-jdk6/psfont.properties.ja
+ backup = etc/java32-jdk6/psfontj2d.properties
+ backup = etc/java32-jdk6/sound.properties
+ source = javaws-launcher
+ source = jconsole32-jdk6.desktop
+ source = jmc32-jdk6.desktop
+ source = jvisualvm32-jdk6.desktop
+ source = policytool32-jdk6.desktop
+ md5sums = 45c15a6b4767288f2f745598455ea2bf
+ md5sums = 8e3fb5f39a1c24945fdb9315f9743263
+ md5sums = be4ebc20e7acd60e195231c36db4a8cf
+ md5sums = eaaf5c10579336af3474ccb23dce2911
+ md5sums = 3adcb5783ffaa18c3480ddfa0569dce2
+ source_x86_64 = http://download.oracle.com/otn-pub/java/jdk/6u45-b06/jdk-6u45-linux-i586.bin
+ depends_x86_64 = ca-certificates-java
+ depends_x86_64 = desktop-file-utils
+ depends_x86_64 = hicolor-icon-theme
+ depends_x86_64 = java32-environment-common
+ depends_x86_64 = java32-runtime-common
+ depends_x86_64 = lib32-glibc
+ depends_x86_64 = lib32-libjpeg-turbo
+ depends_x86_64 = lib32-lcms2
+ depends_x86_64 = lib32-libxrender
+ depends_x86_64 = lib32-libxtst
+ depends_x86_64 = lib32-nss
+ depends_x86_64 = shared-mime-info
+ depends_x86_64 = xdg-utils
+ optdepends_x86_64 = eclipse: "Oracle Java Mission Control" plugins for Eclipse
+ optdepends_x86_64 = lib32-alsa-lib: for basic sound support
+ optdepends_x86_64 = lib32-gtk2: for Gtk+ look and feel (desktop)
+ optdepends_x86_64 = ttf-font: fonts
+ makedepends_x86_64 = pacman>=4.2.0
+ md5sums_x86_64 = 3269370b7c34e6cbfed8785d3d0c5cbd
+
+pkgname = bin32-jdk6
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..ae73188a0bd
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,157 @@
+# Maintainer: -
+# Contributors: Det, Damian Nowak
+
+_pkgname=jdk
+pkgname=bin32-jdk6
+_major=6
+_minor=45
+_build=b06
+pkgver=${_major}u${_minor}
+pkgrel=3
+pkgdesc="Oracle Java $_major Development Kit (32-bit) (public release - end of support)"
+arch=('x86_64')
+url=https://www.java.com/en/download/faq/java_6.xml
+license=('custom')
+depends_x86_64=('ca-certificates-java' 'desktop-file-utils' 'hicolor-icon-theme' 'java32-environment-common'
+ 'java32-runtime-common' 'lib32-glibc' 'lib32-libjpeg-turbo' 'lib32-lcms2' 'lib32-libxrender'
+ 'lib32-libxtst' 'lib32-nss' 'shared-mime-info' 'xdg-utils')
+optdepends_x86_64=('eclipse: "Oracle Java Mission Control" plugins for Eclipse'
+ 'lib32-alsa-lib: for basic sound support'
+ 'lib32-gtk2: for Gtk+ look and feel (desktop)'
+ 'ttf-font: fonts')
+makedepends_x86_64=('pacman>=4.2.0')
+provides=("java32-runtime=$_major" "java32-runtime-headless=$_major" "java32-web-start=$_major" "java32-environment=$_major"
+ "java32-runtime-jre=$_major" "java32-runtime-headless-jre=$_major" "java32-web-start-jre=$_major" "java32-environment-jdk=$_major")
+
+# Variables
+DLAGENTS=('http::/usr/bin/curl -LC - -b oraclelicense=a -O')
+_jname=${_pkgname}${_major}
+_jvmdir=/usr/lib32/jvm/java32-$_major-$_pkgname
+
+backup=("etc/java32-$_jname/i386/jvm.cfg"
+ "etc/java32-$_jname/images/cursors/cursors.properties"
+ "etc/java32-$_jname/management/jmxremote.access"
+ "etc/java32-$_jname/management/management.properties"
+ "etc/java32-$_jname/security/java.policy"
+ "etc/java32-$_jname/security/java.security"
+ "etc/java32-$_jname/security/javaws.policy"
+ "etc/java32-$_jname/content-types.properties"
+ "etc/java32-$_jname/flavormap.properties"
+ "etc/java32-$_jname/fontconfig.properties.src"
+ "etc/java32-$_jname/logging.properties"
+ "etc/java32-$_jname/net.properties"
+ "etc/java32-$_jname/psfont.properties.ja"
+ "etc/java32-$_jname/psfontj2d.properties"
+ "etc/java32-$_jname/sound.properties")
+options=('!strip') # JDK debug-symbols
+install=$pkgname.install
+source=('javaws-launcher'
+ "jconsole32-$_jname.desktop"
+ "jmc32-$_jname.desktop"
+ "jvisualvm32-$_jname.desktop"
+ "policytool32-$_jname.desktop")
+source_x86_64=("http://download.oracle.com/otn-pub/java/jdk/$pkgver-$_build/$_pkgname-$pkgver-linux-i586.bin")
+md5sums=('45c15a6b4767288f2f745598455ea2bf'
+ '8e3fb5f39a1c24945fdb9315f9743263'
+ 'be4ebc20e7acd60e195231c36db4a8cf'
+ 'eaaf5c10579336af3474ccb23dce2911'
+ '3adcb5783ffaa18c3480ddfa0569dce2')
+md5sums_x86_64=('3269370b7c34e6cbfed8785d3d0c5cbd')
+
+package() {
+ msg2 "Extracting the .bin"
+ rm -rf ${_pkgname}1.${_major}.0_${_minor}
+ sh $_pkgname-$pkgver-linux-i586.bin &>/dev/null
+
+ 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 db/bin/*.bat
+ 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
+
+ # javaws-launcher
+ install -m644 "$srcdir"/javaws-launcher bin/
+
+ 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=|&$_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.eucJP/ 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 "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
+} \ No newline at end of file
diff --git a/bin32-jdk6.install b/bin32-jdk6.install
new file mode 100644
index 00000000000..3d623c376b9
--- /dev/null
+++ b/bin32-jdk6.install
@@ -0,0 +1,71 @@
+THIS_JAVA='java32-6-jdk'
+NAME='32-bit JDK 6'
+
+all_off="$(tput sgr0)"
+bold="${all_off}$(tput bold)"
+blue="${bold}$(tput setaf 4)"
+yellow="${bold}$(tput setaf 3)"
+
+note() {
+ printf "${blue}::${yellow} archlinux-java32:${bold} $1${all_off}\n"
+}
+
+update_desktop() {
+ update-desktop-database -q
+ update-mime-database /usr/share/mime >/dev/null
+ xdg-icon-resource forceupdate &>/dev/null
+}
+
+post_install() {
+ default=$(archlinux-java32 get)
+ case ${default} in
+ "")
+ archlinux-java32 set ${THIS_JAVA}
+ note "${NAME} ('${THIS_JAVA}') set as default Java environment."
+ ;;
+ ${THIS_JAVA})
+ note "${NAME} ('${THIS_JAVA}') set as default Java environment."
+ ;;
+ *)
+ note "Default Java environment already set to '${default}'.
+ To use ${NAME} ('${THIS_JAVA}'), run:
+ # archlinux-java32 set ${THIS_JAVA}
+ For status, use:
+ $ archlinux-java32 status"
+ ;;
+ esac
+
+ if [[ ! -f /etc/ssl/certs/java/cacerts ]]; then
+ update-ca-trust
+ fi
+
+ update_desktop
+}
+
+post_upgrade() {
+ post_install
+}
+
+pre_remove() {
+ default=$(archlinux-java32 get)
+ if [[ ${default} = ${THIS_JAVA} ]]; then
+ archlinux-java32 unset
+ fi
+}
+
+post_remove() {
+ default=$(archlinux-java32 get) # reassign
+ if [[ ${default} ]]; then
+ note "Default Java environment is '${default}'."
+ else
+ archlinux-java32 fix
+ default=$(archlinux-java32 get) # re-reassign
+ if [[ ${default} ]]; then
+ note "Default Java environment left as '${default}'."
+ else
+ note "Java environment unset."
+ fi
+ fi
+
+ update_desktop
+}
diff --git a/javaws-launcher b/javaws-launcher
new file mode 100644
index 00000000000..2831dfcbbd7
--- /dev/null
+++ b/javaws-launcher
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+if [ -z "$@" ]; then
+ exec javaws -viewer
+else
+ exec javaws "$@"
+fi
diff --git a/jconsole32-jdk6.desktop b/jconsole32-jdk6.desktop
new file mode 100644
index 00000000000..07969d50e36
--- /dev/null
+++ b/jconsole32-jdk6.desktop
@@ -0,0 +1,8 @@
+[Desktop Entry]
+Exec=/usr/lib32/jvm/java32-6-jdk/bin/jconsole
+Icon=sun-java32-jdk6
+Name=Java 6 Monitoring and Management Console (32-bit)
+StartupNotify=true
+Terminal=false
+Type=Application
+Categories=Development;Java;
diff --git a/jmc32-jdk6.desktop b/jmc32-jdk6.desktop
new file mode 100644
index 00000000000..9eb18b463be
--- /dev/null
+++ b/jmc32-jdk6.desktop
@@ -0,0 +1,8 @@
+[Desktop Entry]
+Exec=/usr/lib32/jvm/java32-6-jdk/bin/jmc
+Icon=sun-java32-jdk6
+Name=Java 6 Mission Control (32-bit)
+StartupNotify=true
+Terminal=false
+Type=Application
+Categories=Development;Java;
diff --git a/jvisualvm32-jdk6.desktop b/jvisualvm32-jdk6.desktop
new file mode 100644
index 00000000000..3c1f6a32778
--- /dev/null
+++ b/jvisualvm32-jdk6.desktop
@@ -0,0 +1,9 @@
+[Desktop Entry]
+Exec=/usr/lib32/jvm/java32-6-jdk/bin/jvisualvm
+GenericName=Java 6 Monitoring and Performance Monitoring Tool (32-bit)
+Icon=sun-java32-jdk6
+Name=Java 6 VisualVM (32-bit)
+StartupNotify=true
+Terminal=false
+Type=Application
+Categories=Development;Java;
diff --git a/policytool32-jdk6.desktop b/policytool32-jdk6.desktop
new file mode 100644
index 00000000000..7b1295ef6e2
--- /dev/null
+++ b/policytool32-jdk6.desktop
@@ -0,0 +1,8 @@
+[Desktop Entry]
+Exec=/usr/lib32/jvm/java32-6-jdk/jre/bin/policytool
+Icon=sun-java32-jdk6
+Name=Java 6 Policy Settings (32-bit)
+StartupNotify=true
+Terminal=false
+Type=Application
+Categories=Settings;Java;