Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 22395
Collapse All | Expand All

(-)dev-java/blackdown-jdk/blackdown-jdk-1.3.1-r10.ebuild (-9 / +5 lines)
Lines 2-8 Link Here
2
# Distributed under the terms of the GNU General Public License v2
2
# Distributed under the terms of the GNU General Public License v2
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/blackdown-jdk/blackdown-jdk-1.3.1-r10.ebuild,v 1.12 2004/07/14 01:44:43 agriffis Exp $
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/blackdown-jdk/blackdown-jdk-1.3.1-r10.ebuild,v 1.12 2004/07/14 01:44:43 agriffis Exp $
4
4
5
inherit java nsplugins gcc
5
inherit java gcc
6
6
7
S=${WORKDIR}/j2sdk1.3.1
7
S=${WORKDIR}/j2sdk1.3.1
8
DESCRIPTION="Blackdown Java Development Kit 1.3.1"
8
DESCRIPTION="Blackdown Java Development Kit 1.3.1"
Lines 12-18 Link Here
12
LICENSE="sun-bcla-java-vm"
12
LICENSE="sun-bcla-java-vm"
13
SLOT="1.3"
13
SLOT="1.3"
14
KEYWORDS="ppc"
14
KEYWORDS="ppc"
15
IUSE="doc"
15
IUSE="doc mozilla"
16
16
17
DEPEND="virtual/libc
17
DEPEND="virtual/libc
18
	>=dev-java/java-config-0.2.5
18
	>=dev-java/java-config-0.2.5
Lines 52-57 Link Here
52
	dohtml README.html
52
	dohtml README.html
53
53
54
	# Install ns plugin
54
	# Install ns plugin
55
	if use mozilla; then
55
	if [ "${ARCH}" == "x86" ] ; then
56
	if [ "${ARCH}" == "x86" ] ; then
56
		PLATFORM="i386"
57
		PLATFORM="i386"
57
	elif [ "${ARCH}" == "ppc" ] ; then
58
	elif [ "${ARCH}" == "ppc" ] ; then
Lines 59-66 Link Here
59
	elif [ "${ARCH}" == "sparc" ] ; then
60
	elif [ "${ARCH}" == "sparc" ] ; then
60
		PLATFORM="sparc"
61
		PLATFORM="sparc"
61
	fi
62
	fi
62
63
		install_mozilla_pluing /opt/${P}/jre/plugin/${PLATFORM}/mozilla/libjavaplugin_oji.so
63
	inst_plugin /opt/${P}/jre/plugin/${PLATFORM}/mozilla/javaplugin_oji.so
64
	fi
64
65
65
	find ${D}/opt/${P} -type f -name "*.so" -exec chmod +x \{\} \;
66
	find ${D}/opt/${P} -type f -name "*.so" -exec chmod +x \{\} \;
66
67
Lines 76-83 Link Here
76
	# install env into /etc/env.d
77
	# install env into /etc/env.d
77
	set_java_env ${FILESDIR}/${VMHANDLE} || die
78
	set_java_env ${FILESDIR}/${VMHANDLE} || die
78
}
79
}
79
80
pkg_postinst () {
81
	# Set as default system VM if none exists
82
	java_pkg_postinst
83
}
(-)dev-java/blackdown-jdk/blackdown-jdk-1.3.1-r8.ebuild (-6 / +12 lines)
Lines 2-8 Link Here
2
# Distributed under the terms of the GNU General Public License v2
2
# Distributed under the terms of the GNU General Public License v2
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/blackdown-jdk/blackdown-jdk-1.3.1-r8.ebuild,v 1.16 2004/09/21 13:58:18 axxo Exp $
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/blackdown-jdk/blackdown-jdk-1.3.1-r8.ebuild,v 1.16 2004/09/21 13:58:18 axxo Exp $
4
4
5
inherit java nsplugins
5
inherit java
6
6
7
S=${WORKDIR}/j2sdk1.3.1
7
S=${WORKDIR}/j2sdk1.3.1
8
DESCRIPTION="Blackdown Java Development Kit 1.3.1"
8
DESCRIPTION="Blackdown Java Development Kit 1.3.1"
Lines 14-20 Link Here
14
LICENSE="sun-bcla-java-vm"
14
LICENSE="sun-bcla-java-vm"
15
SLOT="1.3"
15
SLOT="1.3"
16
KEYWORDS="x86 ~ppc sparc"
16
KEYWORDS="x86 ~ppc sparc"
17
IUSE="doc"
17
IUSE="doc mozilla"
18
18
19
DEPEND="virtual/libc
19
DEPEND="virtual/libc
20
	>=dev-java/java-config-0.2.5
20
	>=dev-java/java-config-0.2.5
Lines 23-29 Link Here
23
	virtual/jre-1.3.1
23
	virtual/jre-1.3.1
24
	virtual/java-scheme-2"
24
	virtual/java-scheme-2"
25
25
26
src_unpack () {
26
src_unpack() {
27
	if use ppc || use sparc ; then
27
	if use ppc || use sparc ; then
28
		tail -n +400 ${DISTDIR}/${A} | tar jxpf -
28
		tail -n +400 ${DISTDIR}/${A} | tar jxpf -
29
	else
29
	else
Lines 37-43 Link Here
37
}
37
}
38
38
39
39
40
src_install () {
40
src_install() {
41
41
42
	dodir /opt/${P}
42
	dodir /opt/${P}
43
43
Lines 58-64 Link Here
58
		PLATFORM="sparc"
58
		PLATFORM="sparc"
59
	fi
59
	fi
60
60
61
	inst_plugin /opt/${P}/jre/plugin/${PLATFORM}/mozilla/javaplugin_oji.so
61
	use mozilla && install_mozilla_plugin /opt/${P}/jre/plugin/${PLATFORM}/mozilla/javaplugin_oji.so
62
62
63
	find ${D}/opt/${P} -type f -name "*.so" -exec chmod +x \{\} \;
63
	find ${D}/opt/${P} -type f -name "*.so" -exec chmod +x \{\} \;
64
64
Lines 72-78 Link Here
72
	set_java_env ${FILESDIR}/${VMHANDLE} || die
72
	set_java_env ${FILESDIR}/${VMHANDLE} || die
73
}
73
}
74
74
75
pkg_postinst () {
75
pkg_postinst() {
76
	# Set as default system VM if none exists
76
	# Set as default system VM if none exists
77
	java_pkg_postinst
77
	java_pkg_postinst
78
79
	if use mozilla; then
80
		einfo "The java mozilla plugin supplied by this package does not"
81
		einfo "work with newer of mozilla/firefox versions."
82
		einfo "You will need >=${PN}-1.4 from them."
83
	fi
78
}
84
}
(-)dev-java/blackdown-jdk/blackdown-jdk-1.4.1.ebuild (-6 / +7 lines)
Lines 3-9 Link Here
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/blackdown-jdk/blackdown-jdk-1.4.1.ebuild,v 1.20 2004/09/21 08:14:39 axxo Exp $
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/blackdown-jdk/blackdown-jdk-1.4.1.ebuild,v 1.20 2004/09/21 08:14:39 axxo Exp $
4
4
5
5
6
inherit java nsplugins
6
inherit java
7
7
8
JREV="01"
8
JREV="01"
9
9
Lines 21-27 Link Here
21
LICENSE="sun-bcla-java-vm"
21
LICENSE="sun-bcla-java-vm"
22
SLOT="1.4.1"
22
SLOT="1.4.1"
23
KEYWORDS="x86 -ppc sparc amd64"
23
KEYWORDS="x86 -ppc sparc amd64"
24
IUSE="doc"
24
IUSE="doc mozilla"
25
25
26
DEPEND="virtual/libc
26
DEPEND="virtual/libc
27
	>=dev-java/java-config-0.2.6
27
	>=dev-java/java-config-0.2.6
Lines 48-54 Link Here
48
	eval echo $offset
48
	eval echo $offset
49
}
49
}
50
50
51
src_unpack () {
51
src_unpack() {
52
	local offset="`get_offset ${DISTDIR}/${A}`"
52
	local offset="`get_offset ${DISTDIR}/${A}`"
53
53
54
	if [ -z "${offset}" ] ; then
54
	if [ -z "${offset}" ] ; then
Lines 61-67 Link Here
61
}
61
}
62
62
63
63
64
src_install () {
64
src_install() {
65
	local PLATFORM=
65
	local PLATFORM=
66
66
67
	dodir /opt/${P}
67
	dodir /opt/${P}
Lines 87-93 Link Here
87
		PLATFORM="sparc"
87
		PLATFORM="sparc"
88
	fi
88
	fi
89
89
90
	inst_plugin /opt/${P}/jre/plugin/${PLATFORM}/mozilla/javaplugin_oji.so
90
	use mozilla && install_mozilla_plugin /opt/${P}/jre/plugin/${PLATFORM}/mozilla/javaplugin_oji.so
91
91
92
	find ${D}/opt/${P} -type f -name "*.so" -exec chmod +x \{\} \;
92
	find ${D}/opt/${P} -type f -name "*.so" -exec chmod +x \{\} \;
93
93
Lines 104-110 Link Here
104
	fi
104
	fi
105
}
105
}
106
106
107
pkg_postinst () {
107
pkg_postinst() {
108
	# Set as default system VM if none exists
108
	# Set as default system VM if none exists
109
	java_pkg_postinst
109
	java_pkg_postinst
110
110
Lines 113-118 Link Here
113
	# but may confuse things like AV scanners and automatic tripwire
113
	# but may confuse things like AV scanners and automatic tripwire
114
	if has_version "sys-apps/chpax"
114
	if has_version "sys-apps/chpax"
115
	then
115
	then
116
		echo
116
		einfo "setting up conservative PaX flags for jar and javac"
117
		einfo "setting up conservative PaX flags for jar and javac"
117
118
118
		for paxkills in "jar" "javac" "java"
119
		for paxkills in "jar" "javac" "java"
(-)dev-java/blackdown-jdk/blackdown-jdk-1.4.2_rc1-r1.ebuild (-5 / +6 lines)
Lines 4-10 Link Here
4
4
5
IUSE="doc mozilla"
5
IUSE="doc mozilla"
6
6
7
inherit java nsplugins
7
inherit java
8
8
9
JREV=${PV#*_}
9
JREV=${PV#*_}
10
JV=${PV%_*}
10
JV=${PV%_*}
Lines 44-50 Link Here
44
	echo $offset
44
	echo $offset
45
}
45
}
46
46
47
src_unpack () {
47
src_unpack() {
48
	local offset=$(get_offset ${DISTDIR}/${A})
48
	local offset=$(get_offset ${DISTDIR}/${A})
49
49
50
	if [ -z "${offset}" ] ; then
50
	if [ -z "${offset}" ] ; then
Lines 81-87 Link Here
81
	rm -f "$UNPACK_CMD"
81
	rm -f "$UNPACK_CMD"
82
}
82
}
83
83
84
src_install () {
84
src_install() {
85
	typeset platform
85
	typeset platform
86
86
87
	dodir /opt/${P}
87
	dodir /opt/${P}
Lines 102-108 Link Here
102
			sparc*) platform="sparc" ;;
102
			sparc*) platform="sparc" ;;
103
			x86) platform="i386" ;;
103
			x86) platform="i386" ;;
104
		esac
104
		esac
105
		inst_plugin /opt/${P}/jre/plugin/${platform}/mozilla/libjavaplugin_oji.so
105
		install_mozilla_plugin /opt/${P}/jre/plugin/${platform}/mozilla/libjavaplugin_oji.so
106
	fi
106
	fi
107
107
108
	find ${D}/opt/${P} -type f -name "*.so" -exec chmod +x \{\} \;
108
	find ${D}/opt/${P} -type f -name "*.so" -exec chmod +x \{\} \;
Lines 120-126 Link Here
120
	unpack_jars
120
	unpack_jars
121
}
121
}
122
122
123
pkg_postinst () {
123
pkg_postinst() {
124
	# Set as default system VM if none exists
124
	# Set as default system VM if none exists
125
	java_pkg_postinst
125
	java_pkg_postinst
126
126
Lines 129-134 Link Here
129
	# but may confuse things like AV scanners and automatic tripwire
129
	# but may confuse things like AV scanners and automatic tripwire
130
	if has_version "sys-apps/chpax"
130
	if has_version "sys-apps/chpax"
131
	then
131
	then
132
		echo
132
		einfo "setting up conservative PaX flags for jar and javac"
133
		einfo "setting up conservative PaX flags for jar and javac"
133
134
134
		for paxkills in "jar" "javac" "java"
135
		for paxkills in "jar" "javac" "java"
(-)dev-java/blackdown-jdk/blackdown-jdk-1.4.2_rc1.ebuild (-5 / +8 lines)
Lines 4-10 Link Here
4
4
5
IUSE="doc"
5
IUSE="doc"
6
6
7
inherit java nsplugins
7
inherit java
8
8
9
JREV=${PV#*_}
9
JREV=${PV#*_}
10
JV=${PV%_*}
10
JV=${PV%_*}
Lines 44-50 Link Here
44
	echo $offset
44
	echo $offset
45
}
45
}
46
46
47
src_unpack () {
47
src_unpack() {
48
	local offset=$(get_offset ${DISTDIR}/${A})
48
	local offset=$(get_offset ${DISTDIR}/${A})
49
49
50
	if [ -z "${offset}" ] ; then
50
	if [ -z "${offset}" ] ; then
Lines 81-87 Link Here
81
	rm -f "$UNPACK_CMD"
81
	rm -f "$UNPACK_CMD"
82
}
82
}
83
83
84
src_install () {
84
src_install() {
85
	typeset platform
85
	typeset platform
86
86
87
	dodir /opt/${P}
87
	dodir /opt/${P}
Lines 95-106 Link Here
95
	dohtml README.html
95
	dohtml README.html
96
96
97
	# Install mozilla plugin
97
	# Install mozilla plugin
98
	if use mozilla; then
98
	case ${ARCH} in
99
	case ${ARCH} in
99
		amd64|x86) platform="i386" ;;
100
		amd64|x86) platform="i386" ;;
100
		ppc) platform="ppc" ;;
101
		ppc) platform="ppc" ;;
101
		sparc*) platform="sparc" ;;
102
		sparc*) platform="sparc" ;;
102
	esac
103
	esac
103
	inst_plugin /opt/${P}/jre/plugin/${platform}/mozilla/javaplugin_oji.so
104
		install_mozilla_plugin /opt/${P}/jre/plugin/${platform}/mozilla/libjavaplugin_oji.so
105
	fi
104
106
105
	find ${D}/opt/${P} -type f -name "*.so" -exec chmod +x \{\} \;
107
	find ${D}/opt/${P} -type f -name "*.so" -exec chmod +x \{\} \;
106
108
Lines 118-124 Link Here
118
	unpack_jars
120
	unpack_jars
119
}
121
}
120
122
121
pkg_postinst () {
123
pkg_postinst() {
122
	# Set as default system VM if none exists
124
	# Set as default system VM if none exists
123
	java_pkg_postinst
125
	java_pkg_postinst
124
126
Lines 127-132 Link Here
127
	# but may confuse things like AV scanners and automatic tripwire
129
	# but may confuse things like AV scanners and automatic tripwire
128
	if has_version "sys-apps/chpax"
130
	if has_version "sys-apps/chpax"
129
	then
131
	then
132
		echo
130
		einfo "setting up conservative PaX flags for jar and javac"
133
		einfo "setting up conservative PaX flags for jar and javac"
131
134
132
		for paxkills in "jar" "javac" "java"
135
		for paxkills in "jar" "javac" "java"
(-)dev-java/blackdown-jre/blackdown-jre-1.3.1-r9.ebuild (-22 / +7 lines)
Lines 2-8 Link Here
2
# Distributed under the terms of the GNU General Public License v2
2
# Distributed under the terms of the GNU General Public License v2
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/blackdown-jre/blackdown-jre-1.3.1-r9.ebuild,v 1.17 2004/07/14 12:22:27 axxo Exp $
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/blackdown-jre/blackdown-jre-1.3.1-r9.ebuild,v 1.17 2004/07/14 12:22:27 axxo Exp $
4
4
5
inherit java nsplugins gcc
5
inherit java gcc
6
6
7
S=${WORKDIR}/j2re1.3.1
7
S=${WORKDIR}/j2re1.3.1
8
DESCRIPTION="Blackdown Java Runtime Environment 1.3.1"
8
DESCRIPTION="Blackdown Java Runtime Environment 1.3.1"
Lines 12-18 Link Here
12
LICENSE="sun-bcla-java-vm"
12
LICENSE="sun-bcla-java-vm"
13
SLOT="0"
13
SLOT="0"
14
KEYWORDS="ppc"
14
KEYWORDS="ppc"
15
IUSE=""
15
IUSE="mozilla"
16
16
17
DEPEND="virtual/libc
17
DEPEND="virtual/libc
18
	>=dev-java/java-config-0.2.5
18
	>=dev-java/java-config-0.2.5
Lines 21-27 Link Here
21
PROVIDE="virtual/jre-1.3.1
21
PROVIDE="virtual/jre-1.3.1
22
	virtual/java-scheme-2"
22
	virtual/java-scheme-2"
23
23
24
src_unpack () {
24
src_unpack() {
25
	for a in ${A}; do
25
	for a in ${A}; do
26
		if [[ ${a} == *.bin ]]; then
26
		if [[ ${a} == *.bin ]]; then
27
			echo ">>> Unpacking ${a}..."
27
			echo ">>> Unpacking ${a}..."
Lines 40-46 Link Here
40
	fi
40
	fi
41
}
41
}
42
42
43
src_install () {
43
src_install() {
44
	typeset platform
44
	typeset platform
45
45
46
	dodir /opt/${P}
46
	dodir /opt/${P}
Lines 52-82 Link Here
52
	dohtml README.html
52
	dohtml README.html
53
53
54
	# Install mozilla plugin
54
	# Install mozilla plugin
55
	if use mozilla; then
55
	case ${ARCH} in
56
	case ${ARCH} in
56
		amd64|x86) platform="i386" ;;
57
		amd64|x86) platform="i386" ;;
57
		ppc) platform="ppc" ;;
58
		ppc) platform="ppc" ;;
58
		sparc*) platform="sparc" ;;
59
		sparc*) platform="sparc" ;;
59
	esac
60
	esac
60
	inst_plugin /opt/${P}/plugin/${platform}/mozilla/javaplugin_oji.so
61
		install_mozilla_plugin /opt/${P}/plugin/${platform}/mozilla/javaplugin_oji.so
62
	fi
61
63
62
	sed -i "s/standard symbols l/symbol/g" ${D}/opt/${P}/lib/font.properties
64
	sed -i "s/standard symbols l/symbol/g" ${D}/opt/${P}/lib/font.properties
63
65
64
	set_java_env ${FILESDIR}/${VMHANDLE}
66
	set_java_env ${FILESDIR}/${VMHANDLE}
65
}
67
}
66
67
pkg_postinst () {
68
	# Only install the JRE as the system default if there's no JDK 
69
	# installed. Installing a JRE over an existing JDK will result
70
	# in major breakage, see #9289.
71
	if [ ! -f "${JAVAC}" ] ; then
72
		ewarn "Found no JDK, setting ${P} as default system VM"
73
		java_pkg_postinst
74
	fi
75
}
76
77
pkg_prerm() {
78
	if java-config -J | grep -q ${P} ; then
79
		ewarn "It appears you are removing your default system VM!"
80
		ewarn "Please run java-config -L then java-config -S to set a new system VM!"
81
	fi
82
}
(-)dev-java/blackdown-jre/blackdown-jre-1.4.1.ebuild (-19 / +4 lines)
Lines 2-8 Link Here
2
# Distributed under the terms of the GNU General Public License v2
2
# Distributed under the terms of the GNU General Public License v2
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/blackdown-jre/blackdown-jre-1.4.1.ebuild,v 1.15 2004/07/30 23:36:52 dragonheart Exp $
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/blackdown-jre/blackdown-jre-1.4.1.ebuild,v 1.15 2004/07/30 23:36:52 dragonheart Exp $
4
4
5
inherit java nsplugins gcc
5
inherit java gcc
6
6
7
S=${WORKDIR}/j2re1.4.1
7
S=${WORKDIR}/j2re1.4.1
8
DESCRIPTION="Blackdown Java Runtime Environment 1.4.1"
8
DESCRIPTION="Blackdown Java Runtime Environment 1.4.1"
Lines 69-80 Link Here
69
	dohtml README.html
69
	dohtml README.html
70
70
71
	# Install mozilla plugin
71
	# Install mozilla plugin
72
	if use mozilla; then
72
	case ${ARCH} in
73
	case ${ARCH} in
73
		amd64|x86) platform="i386" ;;
74
		amd64|x86) platform="i386" ;;
74
		ppc) platform="ppc" ;;
75
		ppc) platform="ppc" ;;
75
		sparc*) platform="sparc" ;;
76
		sparc*) platform="sparc" ;;
76
	esac
77
	esac
77
	inst_plugin /opt/${P}/plugin/${platform}/mozilla/javaplugin_oji.so
78
		install_mozilla_plugin /opt/${P}/plugin/${platform}/mozilla/javaplugin_oji.so
79
	fi
78
80
79
	sed -i "s/standard symbols l/symbol/g" ${D}/opt/${P}/lib/font.properties
81
	sed -i "s/standard symbols l/symbol/g" ${D}/opt/${P}/lib/font.properties
80
82
Lines 87-106 Link Here
87
			${D}/etc/env.d/java/20blackdown-jre-1.4.1
89
			${D}/etc/env.d/java/20blackdown-jre-1.4.1
88
	fi
90
	fi
89
}
91
}
90
91
pkg_postinst () {
92
	# Only install the JRE as the system default if there's no JDK 
93
	# installed. Installing a JRE over an existing JDK will result
94
	# in major breakage, see #9289.
95
	if [ ! -f "${JAVAC}" ] ; then
96
		ewarn "Found no JDK, setting ${P} as default system VM"
97
		java_pkg_postinst
98
	fi
99
}
100
101
pkg_postrm() {
102
	if java-config -J | grep -q ${P} ; then
103
		ewarn "It appears you are removing your default system VM!"
104
		ewarn "Please run java-config -L then java-config-S to set a new system VM!"
105
	fi
106
}
(-)dev-java/blackdown-jre/blackdown-jre-1.4.2_rc1-r1.ebuild (-22 / +5 lines)
Lines 2-10 Link Here
2
# Distributed under the terms of the GNU General Public License v2
2
# Distributed under the terms of the GNU General Public License v2
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/blackdown-jre/blackdown-jre-1.4.2_rc1-r1.ebuild,v 1.4 2004/07/14 01:45:28 agriffis Exp $
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/blackdown-jre/blackdown-jre-1.4.2_rc1-r1.ebuild,v 1.4 2004/07/14 01:45:28 agriffis Exp $
4
4
5
IUSE=""
5
inherit java
6
7
inherit java nsplugins
8
6
9
JREV="rc1"
7
JREV="rc1"
10
8
Lines 24-30 Link Here
24
SLOT="1.4.2"
22
SLOT="1.4.2"
25
LICENSE="sun-bcla-java-vm"
23
LICENSE="sun-bcla-java-vm"
26
KEYWORDS="-* amd64"
24
KEYWORDS="-* amd64"
27
25
IUSE=""
28
DEPEND="virtual/libc
26
DEPEND="virtual/libc
29
	>=dev-java/java-config-0.2.6
27
	>=dev-java/java-config-0.2.6
30
	>=sys-apps/sed-4
28
	>=sys-apps/sed-4
Lines 99-110 Link Here
99
	dohtml README.html
97
	dohtml README.html
100
98
101
	# Install mozilla plugin
99
	# Install mozilla plugin
100
	if use mozilla; then
102
	case ${ARCH} in
101
	case ${ARCH} in
103
		amd64|x86) platform="i386" ;;
102
		amd64|x86) platform="i386" ;;
104
		ppc) platform="ppc" ;;
103
		ppc) platform="ppc" ;;
105
		sparc*) platform="sparc" ;;
104
		sparc*) platform="sparc" ;;
106
	esac
105
	esac
107
	inst_plugin /opt/${P}/jre/plugin/${platform}/mozilla/libjavaplugin_oji.so
106
		install_mozilla_plugins /opt/${P}/jre/plugin/${platform}/mozilla/libjavaplugin_oji.so
107
	fi
108
108
109
	sed -i "s/standard symbols l/symbol/g" ${D}/opt/${P}/jre/lib/font.properties
109
	sed -i "s/standard symbols l/symbol/g" ${D}/opt/${P}/jre/lib/font.properties
110
110
Lines 121-140 Link Here
121
121
122
	unpack_jars
122
	unpack_jars
123
}
123
}
124
125
pkg_postinst () {
126
	# Only install the JRE as the system default if there's no JDK 
127
	# installed. Installing a JRE over an existing JDK will result
128
	# in major breakage, see #9289.
129
	if [ ! -f "${JAVAC}" ] ; then
130
		ewarn "Found no JDK, setting ${P} as default system VM"
131
		java_pkg_postinst
132
	fi
133
}
134
135
pkg_prerm() {
136
	if java-config -J | grep -q ${P} ; then
137
		ewarn "It appears you are removing your default system VM!"
138
		ewarn "Please run java-config -L then java-config-S to set a new system VM!"
139
	fi
140
}
(-)dev-java/compaq-jdk/compaq-jdk-1.3.1-r1.ebuild (-5 lines)
Lines 44-51 Link Here
44
44
45
	set_java_env ${FILESDIR}/${VMHANDLE} || die
45
	set_java_env ${FILESDIR}/${VMHANDLE} || die
46
}
46
}
47
48
pkg_postinst () {
49
	# Set as default VM if none exists
50
	java_pkg_postinst
51
}
(-)dev-java/compaq-jdk/compaq-jdk-1.3.1-r2.ebuild (-5 lines)
Lines 45-52 Link Here
45
45
46
	set_java_env ${FILESDIR}/${VMHANDLE} || die
46
	set_java_env ${FILESDIR}/${VMHANDLE} || die
47
}
47
}
48
49
pkg_postinst () {
50
	# Set as default VM if none exists
51
	java_pkg_postinst
52
}
(-)dev-java/compaq-jdk/compaq-jdk-1.3.1-r3.ebuild (-5 lines)
Lines 45-52 Link Here
45
45
46
	set_java_env ${FILESDIR}/${VMHANDLE} || die
46
	set_java_env ${FILESDIR}/${VMHANDLE} || die
47
}
47
}
48
49
pkg_postinst () {
50
	# Set as default VM if none exists
51
	java_pkg_postinst
52
}
(-)dev-java/compaq-jre/compaq-jre-1.3.1-r3.ebuild (-13 lines)
Lines 41-56 Link Here
41
41
42
	set_java_env ${FILESDIR}/${VMHANDLE} || die
42
	set_java_env ${FILESDIR}/${VMHANDLE} || die
43
}
43
}
44
45
pkg_postinst () {
46
	if [ ! -e "${JAVAC}" ] ; then
47
		java_pkg_postinst
48
	fi
49
}
50
51
pkg_postrm() {
52
	if [ ! -z "$(java-config -J) | grep ${P}" ] ; then
53
		ewarn "It appears you are removing your default system VM!"
54
		ewarn "Please run java-config -L then java-config-S to set a new system VM!"
55
	fi
56
}
(-)dev-java/ibm-jdk-bin/ibm-jdk-bin-1.4.1-r2.ebuild (-16 / +11 lines)
Lines 4-10 Link Here
4
4
5
IUSE="X doc javacomm"
5
IUSE="X doc javacomm"
6
6
7
inherit java nsplugins eutils
7
inherit java eutils
8
8
9
if use ppc; then
9
if use ppc; then
10
	S="${WORKDIR}/IBMJava2-ppc-141"
10
	S="${WORKDIR}/IBMJava2-ppc-141"
Lines 50-60 Link Here
50
	if use ppc; then
50
	if use ppc; then
51
		dosed s:/proc/cpuinfo:/etc//cpuinfo:g /opt/${P}/jre/bin/libjitc.so
51
		dosed s:/proc/cpuinfo:/etc//cpuinfo:g /opt/${P}/jre/bin/libjitc.so
52
		dosed s:/proc/cpuinfo:/etc//cpuinfo:g /opt/${P}/jre/bin/libjitc_g.so
52
		dosed s:/proc/cpuinfo:/etc//cpuinfo:g /opt/${P}/jre/bin/libjitc_g.so
53
		insinto ${D}/etc
53
		insinto /etc
54
		doins ${FILESDIR}/cpuinfo
54
		doins ${FILESDIR}/cpuinfo
55
	else
55
	fi
56
		# No java-plugin on ppc
56
57
		inst_plugin /opt/${P}/jre/bin/libjavaplugin_oji.so
57
	if use mozilla && ! use ppc; then
58
		local plugin="libjavaplugin_oji.so"
59
		if has_version '>=gcc-3*' ; then
60
			plugin="libjavaplugin_ojigcc3.so"
61
		fi
62
		install_mozilla_plugin /opt/${P}/jre/bin/${plugin}
58
	fi
63
	fi
59
64
60
	dohtml -a html,htm,HTML -r docs
65
	dohtml -a html,htm,HTML -r docs
Lines 67-89 Link Here
67
pkg_postinst() {
72
pkg_postinst() {
68
	java_pkg_postinst
73
	java_pkg_postinst
69
	if ! use X; then
74
	if ! use X; then
70
		einfo "********************************************************"
75
		echo
71
		eerror "You're not using X so its possible that you dont have"
76
		eerror "You're not using X so its possible that you dont have"
72
		eerror "a X server installed, please read the following warning: "
77
		eerror "a X server installed, please read the following warning: "
73
		eerror "Some parts of IBM JDK require XFree86 to be installed."
78
		eerror "Some parts of IBM JDK require XFree86 to be installed."
74
		eerror "Be careful which Java libraries you attempt to use."
79
		eerror "Be careful which Java libraries you attempt to use."
75
		einfo "********************************************************"
76
		echo
77
	fi
80
	fi
78
81
79
	einfo " After installing ${P} this"
80
	einfo " was set as the default JVM to run."
81
	einfo " When finished please run the following so your"
82
	einfo " enviroment gets updated."
83
	eerror "    /usr/sbin/env-update && source /etc/profile"
84
	einfo " Or use java-config program to set your preferred VM"
85
	einfo "******************************************************"
86
87
	ebeep 5
82
	ebeep 5
88
	epause 8
83
	epause 8
89
}
84
}
(-)dev-java/ibm-jdk-bin/ibm-jdk-bin-1.4.2.ebuild (-15 / +10 lines)
Lines 4-10 Link Here
4
4
5
IUSE="X doc javacomm"
5
IUSE="X doc javacomm"
6
6
7
inherit java nsplugins eutils
7
inherit java eutils
8
8
9
if use ppc; then
9
if use ppc; then
10
	S="${WORKDIR}/IBMJava2-ppc-142"
10
	S="${WORKDIR}/IBMJava2-ppc-142"
Lines 52-60 Link Here
52
		dosed s:/proc/cpuinfo:/etc//cpuinfo:g /opt/${P}/jre/bin/libjitc_g.so
52
		dosed s:/proc/cpuinfo:/etc//cpuinfo:g /opt/${P}/jre/bin/libjitc_g.so
53
		insinto /etc
53
		insinto /etc
54
		doins ${FILESDIR}/cpuinfo
54
		doins ${FILESDIR}/cpuinfo
55
	else
55
	fi
56
		# No java-plugin on ppc
56
57
		inst_plugin /opt/${P}/jre/bin/libjavaplugin_oji.so
57
	if use mozilla && ! use ppc; then
58
		local plugin="libjavaplugin_oji.so"
59
		if has_version '>=gcc-3*' ; then
60
			plugin="libjavaplugin_ojigcc3.so"
61
		fi
62
		install_mozilla_plugin /opt/${P}/jre/bin/${plugin}
58
	fi
63
	fi
59
64
60
	dohtml -a html,htm,HTML -r docs
65
	dohtml -a html,htm,HTML -r docs
Lines 67-89 Link Here
67
pkg_postinst() {
72
pkg_postinst() {
68
	java_pkg_postinst
73
	java_pkg_postinst
69
	if ! use X; then
74
	if ! use X; then
70
		einfo "********************************************************"
75
		echo
71
		eerror "You're not using X so its possible that you dont have"
76
		eerror "You're not using X so its possible that you dont have"
72
		eerror "a X server installed, please read the following warning: "
77
		eerror "a X server installed, please read the following warning: "
73
		eerror "Some parts of IBM JDK require XFree86 to be installed."
78
		eerror "Some parts of IBM JDK require XFree86 to be installed."
74
		eerror "Be careful which Java libraries you attempt to use."
79
		eerror "Be careful which Java libraries you attempt to use."
75
		einfo "********************************************************"
76
		echo
77
	fi
80
	fi
78
81
79
	einfo " After installing ${P} this"
80
	einfo " was set as the default JVM to run."
81
	einfo " When finished please run the following so your"
82
	einfo " enviroment gets updated."
83
	eerror "    /usr/sbin/env-update && source /etc/profile"
84
	einfo " Or use java-config program to set your preferred VM"
85
	einfo "******************************************************"
86
87
	ebeep 5
82
	ebeep 5
88
	epause 8
83
	epause 8
89
}
84
}
(-)dev-java/ibm-jre-bin/ibm-jre-bin-1.4.1-r1.ebuild (-11 / +8 lines)
Lines 2-8 Link Here
2
# Distributed under the terms of the GNU General Public License v2
2
# Distributed under the terms of the GNU General Public License v2
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/ibm-jre-bin/ibm-jre-bin-1.4.1-r1.ebuild,v 1.10 2004/08/04 12:52:54 axxo Exp $
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/ibm-jre-bin/ibm-jre-bin-1.4.1-r1.ebuild,v 1.10 2004/08/04 12:52:54 axxo Exp $
4
4
5
inherit java nsplugins
5
inherit java
6
6
7
S="${WORKDIR}/j2sdk${PV}"
7
S="${WORKDIR}/j2sdk${PV}"
8
DESCRIPTION="IBM Java Development Kit ${PV}"
8
DESCRIPTION="IBM Java Development Kit ${PV}"
Lines 48-63 Link Here
48
		< ${FILESDIR}/${P} \
48
		< ${FILESDIR}/${P} \
49
		> ${D}/etc/env.d/java/20${P} \
49
		> ${D}/etc/env.d/java/20${P} \
50
		|| die "unable to install environment file"
50
		|| die "unable to install environment file"
51
}
52
53
pkg_postinst(){
54
	inst_plugin /opt/${P}/bin/javaplugin.so
55
	true
56
}
57
51
58
pkg_prerm() {
52
	if use mozilla; then
59
	if [ ! -z "$(java-config -J | grep ${P})" ] ; then
53
		local plugin="libjavaplugin_oji.so"
60
		ewarn "It appears you are removing your default system VM!"
54
		if has_version '>=gcc-3*' ; then
61
		ewarn "Please run java-config -L then java-config-S to set a new system VM!"
55
			plugin="libjavaplugin_ojigcc3.so"
62
	fi
56
	fi
57
		install_mozilla_plugin /opt/${P}/bin/${plugin}
58
	fi
59
63
}
60
}
(-)dev-java/ibm-jre-bin/ibm-jre-bin-1.4.2.ebuild (-11 / +8 lines)
Lines 2-8 Link Here
2
# Distributed under the terms of the GNU General Public License v2
2
# Distributed under the terms of the GNU General Public License v2
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/ibm-jre-bin/ibm-jre-bin-1.4.2.ebuild,v 1.2 2004/08/04 15:25:57 sejo Exp $
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/ibm-jre-bin/ibm-jre-bin-1.4.2.ebuild,v 1.2 2004/08/04 15:25:57 sejo Exp $
4
4
5
inherit java nsplugins
5
inherit java
6
6
7
S="${WORKDIR}/j2sdk${PV}"
7
S="${WORKDIR}/j2sdk${PV}"
8
DESCRIPTION="IBM Java Development Kit ${PV}"
8
DESCRIPTION="IBM Java Development Kit ${PV}"
Lines 48-63 Link Here
48
		< ${FILESDIR}/${P} \
48
		< ${FILESDIR}/${P} \
49
		> ${D}/etc/env.d/java/20${P} \
49
		> ${D}/etc/env.d/java/20${P} \
50
		|| die "unable to install environment file"
50
		|| die "unable to install environment file"
51
}
52
53
pkg_postinst(){
54
	inst_plugin /opt/${P}/bin/javaplugin.so
55
	true
56
}
57
51
58
pkg_prerm() {
52
	if use mozilla; then
59
	if [ ! -z "$(java-config -J | grep ${P})" ] ; then
53
		local plugin="libjavaplugin_oji.so"
60
		ewarn "It appears you are removing your default system VM!"
54
		if has_version '>=gcc-3*' ; then
61
		ewarn "Please run java-config -L then java-config-S to set a new system VM!"
55
			plugin="libjavaplugin_ojigcc3.so"
62
	fi
56
	fi
57
		install_mozilla_plugin /opt/${P}/jre/bin/${plugin}
58
	fi
59
63
}
60
}
(-)dev-java/sun-j2sdk/sun-j2sdk-1.4.1-r1.ebuild (-3 / +4 lines)
Lines 8-16 Link Here
8
# Based on http://www.linuxfromscratch.org/~tushar/hints/javafromscratch.txt (LFS)
8
# Based on http://www.linuxfromscratch.org/~tushar/hints/javafromscratch.txt (LFS)
9
# By Tushar Teredesai <Tush@Yahoo.Com>
9
# By Tushar Teredesai <Tush@Yahoo.Com>
10
10
11
IUSE="nptl doc"
12
11
13
inherit java nsplugins
12
inherit java
14
13
15
JAVA_PATCHES="disable-sanity-check
14
JAVA_PATCHES="disable-sanity-check
16
	fix-intl-files
15
	fix-intl-files
Lines 51-56 Link Here
51
	virtual/jdk-1.4.1
50
	virtual/jdk-1.4.1
52
	virtual/java-scheme-2"
51
	virtual/java-scheme-2"
53
52
53
IUSE="nptl doc"
54
54
pkg_nofetch() {
55
pkg_nofetch() {
55
	einfo "Please download"
56
	einfo "Please download"
56
	einfo "  - ${SRC_MOZHEADERS}"
57
	einfo "  - ${SRC_MOZHEADERS}"
Lines 152-158 Link Here
152
153
153
	chown -R root:root ${D}/opt/${P}
154
	chown -R root:root ${D}/opt/${P}
154
155
155
	inst_plugin /opt/${P}/jre/plugin/i386/ns610/libjavaplugin_oji.so
156
	install_mozilla_plugin /opt/${P}/jre/plugin/i386/ns610/libjavaplugin_oji.so
156
	set_java_env ${FILESDIR}/${VMHANDLE}
157
	set_java_env ${FILESDIR}/${VMHANDLE}
157
}
158
}
158
159
(-)dev-java/sun-j2sdk/sun-j2sdk-1.4.2.ebuild (-4 / +3 lines)
Lines 2-10 Link Here
2
# Distributed under the terms of the GNU General Public License v2
2
# Distributed under the terms of the GNU General Public License v2
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/sun-j2sdk/sun-j2sdk-1.4.2.ebuild,v 1.12 2004/09/21 14:08:30 axxo Exp $
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/sun-j2sdk/sun-j2sdk-1.4.2.ebuild,v 1.12 2004/09/21 14:08:30 axxo Exp $
4
4
5
IUSE="nptl doc"
5
inherit java
6
7
inherit java nsplugins
8
6
9
JAVA_PATCHES="
7
JAVA_PATCHES="
10
	remove-fixed-paths
8
	remove-fixed-paths
Lines 27-32 Link Here
27
SLOT="0"
25
SLOT="0"
28
KEYWORDS="x86 -ppc -alpha -sparc"
26
KEYWORDS="x86 -ppc -alpha -sparc"
29
LICENSE="sun-csl"
27
LICENSE="sun-csl"
28
IUSE="nptl doc"
30
29
31
RDEPEND="virtual/libc
30
RDEPEND="virtual/libc
32
	virtual/x11
31
	virtual/x11
Lines 149-155 Link Here
149
148
150
	chown -R root:root ${D}/opt/${P}
149
	chown -R root:root ${D}/opt/${P}
151
150
152
	inst_plugin /opt/${P}/jre/plugin/i386/ns610/libjavaplugin_oji.so
151
	install_mozilla_plugin /opt/${P}/jre/plugin/i386/ns610/libjavaplugin_oji.so
153
	set_java_env ${FILESDIR}/${VMHANDLE}
152
	set_java_env ${FILESDIR}/${VMHANDLE}
154
}
153
}
155
154
(-)dev-java/sun-jdk/sun-jdk-1.2.2.017.ebuild (-4 / +4 lines)
Lines 50-56 Link Here
50
	echo
50
	echo
51
}
51
}
52
52
53
src_install () {
53
src_install() {
54
	# Make the root directory for the installation.
54
	# Make the root directory for the installation.
55
	dodir /opt/${P}
55
	dodir /opt/${P}
56
56
Lines 80-100 Link Here
80
	set_java_env ${FILESDIR}/${VMHANDLE} || die
80
	set_java_env ${FILESDIR}/${VMHANDLE} || die
81
}
81
}
82
82
83
pkg_postinst () {
83
pkg_postinst() {
84
	# Set as default VM if none exists
84
	# Set as default VM if none exists
85
	java_pkg_postinst
85
	java_pkg_postinst
86
86
87
	# Again, this will not work as a Mozilla plugin.
87
	# Again, this will not work as a Mozilla plugin.
88
	if use mozilla ; then
88
	if use mozilla ; then
89
		echo
89
		einfo "JDK 1.2.2 does not work with Mozilla.  A more recent JDK is"
90
		einfo "JDK 1.2.2 does not work with Mozilla.  A more recent JDK is"
90
		einfo "required."
91
		einfo "required."
91
		echo
92
	fi
92
	fi
93
93
94
	# Warn the user if they don't appear to have XFree86 installed.
94
	# Warn the user if they don't appear to have XFree86 installed.
95
	if ! use X ; then
95
	if ! use X ; then
96
		echo
96
		ewarn "Some parts of Sun's JDK require XFree86 to be installed."
97
		ewarn "Some parts of Sun's JDK require XFree86 to be installed."
97
		ewarn "Be careful which Java libraries you attempt to use."
98
		ewarn "Be careful which Java libraries you attempt to use."
98
		echo
99
	fi
99
	fi
100
}
100
}
(-)dev-java/sun-jdk/sun-jdk-1.4.2.05.ebuild (-28 / +11 lines)
Lines 2-10 Link Here
2
# Distributed under the terms of the GNU General Public License v2
2
# Distributed under the terms of the GNU General Public License v2
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/sun-jdk/sun-jdk-1.4.2.05.ebuild,v 1.3 2004/09/06 18:44:20 ciaranm Exp $
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/sun-jdk/sun-jdk-1.4.2.05.ebuild,v 1.3 2004/09/06 18:44:20 ciaranm Exp $
4
4
5
IUSE="doc gnome kde mozilla jce"
6
5
7
inherit java nsplugins eutils
6
inherit java eutils
8
7
9
MY_PV=${PV%.*}_${PV##*.}
8
MY_PV=${PV%.*}_${PV##*.}
10
MY_P=j2sdk${MY_PV}
9
MY_P=j2sdk${MY_PV}
Lines 22-27 Link Here
22
LICENSE="sun-bcla-java-vm"
21
LICENSE="sun-bcla-java-vm"
23
KEYWORDS="x86 -ppc -sparc -alpha -mips -hppa"
22
KEYWORDS="x86 -ppc -sparc -alpha -mips -hppa"
24
RESTRICT="fetch"
23
RESTRICT="fetch"
24
IUSE="doc gnome kde mozilla jce"
25
25
26
DEPEND=">=dev-java/java-config-1.1.5
26
DEPEND=">=dev-java/java-config-1.1.5
27
	sys-apps/sed
27
	sys-apps/sed
Lines 59-71 Link Here
59
59
60
src_unpack() {
60
src_unpack() {
61
	if [ ! -r ${DISTDIR}/${At} ]; then
61
	if [ ! -r ${DISTDIR}/${At} ]; then
62
		eerror "cannot read ${MY_PV}.bin. Please check the permission and try again."
62
		die "cannot read ${MY_PV}.bin. Please check the permission and try again."
63
		die
64
	fi
63
	fi
65
	if use jce; then
64
	if use jce; then
66
		if [ ! -r ${DISTDIR}/${jce_policy} ]; then
65
		if [ ! -r ${DISTDIR}/${jce_policy} ]; then
67
			eerror "cannot read ${jce_policy}. Please check the permission and try again."
66
			die "cannot read ${jce_policy}. Please check the permission and try again."
68
			die
69
		fi
67
		fi
70
	fi
68
	fi
71
	#Search for the ELF Header
69
	#Search for the ELF Header
Lines 90-96 Link Here
90
	fi
88
	fi
91
}
89
}
92
90
93
src_install () {
91
src_install() {
94
	local dirs="bin include jre lib man"
92
	local dirs="bin include jre lib man"
95
	dodir /opt/${P}
93
	dodir /opt/${P}
96
94
Lines 117-130 Link Here
117
		dosym /opt/${P}/jre/lib/security/unlimited-jce/local_policy.jar /opt/${P}/jre/lib/security/
115
		dosym /opt/${P}/jre/lib/security/unlimited-jce/local_policy.jar /opt/${P}/jre/lib/security/
118
	fi
116
	fi
119
117
118
	if use mozilla; then
120
	local plugin_dir="ns610"
119
	local plugin_dir="ns610"
121
	if has_version '>=gcc-3.2*' ; then
120
	if has_version '>=gcc-3.2*' ; then
122
		plugin_dir="ns610-gcc32"
121
		plugin_dir="ns610-gcc32"
123
	fi
122
	fi
124
	if use mozilla ; then
123
		install_mozilla_plugin /opt/${P}/jre/plugin/i386/${plugin_dir}/libjavaplugin_oji.so
125
		install_mozilla_plugin /opt/${P}/jre/plugin/i386/$plugin_dir/libjavaplugin_oji.so
126
	fi
124
	fi
127
	inst_plugin /opt/${P}/jre/plugin/i386/$plugin_dir/libjavaplugin_oji.so
128
125
129
	# create dir for system preferences
126
	# create dir for system preferences
130
	dodir /opt/${P}/.systemPrefs
127
	dodir /opt/${P}/.systemPrefs
Lines 154-160 Link Here
154
	#      is a directory and will not be gzipped ;)
151
	#      is a directory and will not be gzipped ;)
155
}
152
}
156
153
157
pkg_postinst () {
154
pkg_postinst() {
158
	# Create files used as storage for system preferences.
155
	# Create files used as storage for system preferences.
159
	touch /opt/${P}/.systemPrefs/.system.lock
156
	touch /opt/${P}/.systemPrefs/.system.lock
160
	chmod 644 /opt/${P}/.systemPrefs/.system.lock
157
	chmod 644 /opt/${P}/.systemPrefs/.system.lock
Lines 166-178 Link Here
166
163
167
	#Show info about netscape
164
	#Show info about netscape
168
	if has_version '>=netscape-navigator-4.79-r1' || has_version '>=netscape-communicator-4.79-r1' ; then
165
	if has_version '>=netscape-navigator-4.79-r1' || has_version '>=netscape-communicator-4.79-r1' ; then
169
		einfo "********************************************************"
166
		echo
170
		einfo "If you want to install the plugin for Netscape 4.x, type"
167
		einfo "If you want to install the plugin for Netscape 4.x, type"
171
		einfo
168
		einfo
172
		einfo "   cd /usr/lib/nsbrowser/plugins/"
169
		einfo "   cd /usr/lib/nsbrowser/plugins/"
173
		einfo "   ln -sf /opt/${P}/jre/plugin/i386/ns4/libjavaplugin.so"
170
		einfo "   ln -sf /opt/${P}/jre/plugin/i386/ns4/libjavaplugin.so"
174
		einfo "********************************************************"
175
		echo
176
	fi
171
	fi
177
172
178
	# if chpax is on the target system, set the appropriate PaX flags
173
	# if chpax is on the target system, set the appropriate PaX flags
Lines 180-185 Link Here
180
	# but may confuse things like AV scanners and automatic tripwire
175
	# but may confuse things like AV scanners and automatic tripwire
181
	if has_version "sys-apps/chpax"
176
	if has_version "sys-apps/chpax"
182
	then
177
	then
178
		echo
183
		einfo "setting up conservative PaX flags for jar, javac and java"
179
		einfo "setting up conservative PaX flags for jar, javac and java"
184
180
185
		for paxkills in "jar" "javac" "java"
181
		for paxkills in "jar" "javac" "java"
Lines 197-218 Link Here
197
		ewarn "can be given by #gentoo-hardened + pappy@gentoo.org"
193
		ewarn "can be given by #gentoo-hardened + pappy@gentoo.org"
198
	fi
194
	fi
199
195
200
	#Thanks to Douglas Pollock <douglas.pollock@magma.ca> for this
196
	echo
201
	#comment found on the sun-jdk 1.2.2 ebuild that he sent.
202
	einfo "*********************************************************"
203
	eerror "Some parts of Sun's JDK require XFree86 to be installed."
197
	eerror "Some parts of Sun's JDK require XFree86 to be installed."
204
	eerror "Be careful which Java libraries you attempt to use."
198
	eerror "Be careful which Java libraries you attempt to use."
205
	einfo "*********************************************************"
206
	echo
207
208
	einfo "******************************************************"
209
	einfo " After installing ${P} this"
210
	einfo " was set as the default JVM to run."
211
	einfo " When finished please run the following so your"
212
	einfo " enviroment gets updated."
213
	eerror "    /usr/sbin/env-update && source /etc/profile"
214
	einfo " Or use java-config program to set your preferred VM"
215
	einfo "******************************************************"
216
199
217
	ebeep 5
200
	ebeep 5
218
	epause 8
201
	epause 8
(-)dev-java/sun-jdk/sun-jdk-1.5.0_rc1.ebuild (-30 / +10 lines)
Lines 2-9 Link Here
2
# Distributed under the terms of the GNU General Public License v2
2
# Distributed under the terms of the GNU General Public License v2
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/sun-jdk/sun-jdk-1.5.0_rc1.ebuild,v 1.3 2004/09/06 18:44:20 ciaranm Exp $
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/sun-jdk/sun-jdk-1.5.0_rc1.ebuild,v 1.3 2004/09/06 18:44:20 ciaranm Exp $
4
4
5
IUSE="doc gnome kde mozilla jce"
6
7
inherit java eutils
5
inherit java eutils
8
6
9
amd64file="jdk-1_5_0-rc-linux-amd64.bin"
7
amd64file="jdk-1_5_0-rc-linux-amd64.bin"
Lines 26-31 Link Here
26
LICENSE="sun-bcla-java-vm"
24
LICENSE="sun-bcla-java-vm"
27
KEYWORDS="~x86 ~amd64"
25
KEYWORDS="~x86 ~amd64"
28
RESTRICT="fetch"
26
RESTRICT="fetch"
27
IUSE="doc gnome kde mozilla jce"
29
28
30
#
29
#
31
DEPEND=">=dev-java/java-config-1.2
30
DEPEND=">=dev-java/java-config-1.2
Lines 66-78 Link Here
66
65
67
src_unpack() {
66
src_unpack() {
68
	if [ ! -r ${DISTDIR}/${At} ]; then
67
	if [ ! -r ${DISTDIR}/${At} ]; then
69
		eerror "cannot read ${At}. Please check the permission and try again."
68
		die "cannot read ${At}. Please check the permission and try again."
70
		die
71
	fi
69
	fi
72
	if use jce; then
70
	if use jce; then
73
		if [ ! -r ${DISTDIR}/${jcefile} ]; then
71
		if [ ! -r ${DISTDIR}/${jcefile} ]; then
74
			eerror "cannot read ${jcefile}. Please check the permission and try again."
72
			die "cannot read ${jcefile}. Please check the permission and try again."
75
			die
76
		fi
73
		fi
77
	fi
74
	fi
78
75
Lines 102-108 Link Here
102
	${S}/bin/java -client -Xshare:dump
99
	${S}/bin/java -client -Xshare:dump
103
}
100
}
104
101
105
src_install () {
102
src_install() {
106
	local dirs="bin include jre lib man"
103
	local dirs="bin include jre lib man"
107
	dodir /opt/${P}
104
	dodir /opt/${P}
108
105
Lines 128-140 Link Here
128
		dosym /opt/${P}/jre/lib/security/unlimited-jce/local_policy.jar /opt/${P}/jre/lib/security/
125
		dosym /opt/${P}/jre/lib/security/unlimited-jce/local_policy.jar /opt/${P}/jre/lib/security/
129
	fi
126
	fi
130
127
131
128
	if use mozilla; then
132
	local plugin_dir="ns7-gcc29"
129
	local plugin_dir="ns7-gcc29"
133
	if has_version '>=gcc-3*' ; then
130
	if has_version '>=gcc-3*' ; then
134
		plugin_dir="ns7"
131
		plugin_dir="ns7"
135
	fi
132
	fi
136
133
137
	if use mozilla ; then
138
		if use x86 ; then
134
		if use x86 ; then
139
			install_mozilla_plugin /opt/${P}/jre/plugin/i386/$plugin_dir/libjavaplugin_oji.so
135
			install_mozilla_plugin /opt/${P}/jre/plugin/i386/$plugin_dir/libjavaplugin_oji.so
140
		else
136
		else
Lines 175-181 Link Here
175
	#      is a directory and will not be gzipped ;)
171
	#      is a directory and will not be gzipped ;)
176
}
172
}
177
173
178
pkg_postinst () {
174
pkg_postinst() {
179
	# Create files used as storage for system preferences.
175
	# Create files used as storage for system preferences.
180
	PREFS_LOCATION=/opt/${P}/jre
176
	PREFS_LOCATION=/opt/${P}/jre
181
	mkdir -p ${PREFS_LOCATION}/.systemPrefs
177
	mkdir -p ${PREFS_LOCATION}/.systemPrefs
Lines 193-205 Link Here
193
189
194
	#Show info about netscape
190
	#Show info about netscape
195
	if has_version '>=netscape-navigator-4.79-r1' || has_version '>=netscape-communicator-4.79-r1' ; then
191
	if has_version '>=netscape-navigator-4.79-r1' || has_version '>=netscape-communicator-4.79-r1' ; then
196
		einfo "********************************************************"
192
		echo
197
		einfo "If you want to install the plugin for Netscape 4.x, type"
193
		einfo "If you want to install the plugin for Netscape 4.x, type"
198
		einfo
194
		einfo
199
		einfo "   cd /usr/lib/nsbrowser/plugins/"
195
		einfo "   cd /usr/lib/nsbrowser/plugins/"
200
		einfo "   ln -sf /opt/${P}/jre/plugin/i386/ns4/libjavaplugin.so"
196
		einfo "   ln -sf /opt/${P}/jre/plugin/i386/ns4/libjavaplugin.so"
201
		einfo "********************************************************"
202
		echo
203
	fi
197
	fi
204
198
205
	# if chpax is on the target system, set the appropriate PaX flags
199
	# if chpax is on the target system, set the appropriate PaX flags
Lines 207-212 Link Here
207
	# but may confuse things like AV scanners and automatic tripwire
201
	# but may confuse things like AV scanners and automatic tripwire
208
	if has_version "sys-apps/chpax"
202
	if has_version "sys-apps/chpax"
209
	then
203
	then
204
		echo
210
		einfo "setting up conservative PaX flags for jar, javac and java"
205
		einfo "setting up conservative PaX flags for jar, javac and java"
211
206
212
		for paxkills in "jar" "javac" "java"
207
		for paxkills in "jar" "javac" "java"
Lines 224-253 Link Here
224
		ewarn "can be given by #gentoo-hardened + pappy@gentoo.org"
219
		ewarn "can be given by #gentoo-hardened + pappy@gentoo.org"
225
	fi
220
	fi
226
221
227
	#Thanks to Douglas Pollock <douglas.pollock@magma.ca> for this
222
	echo
228
	#comment found on the sun-jdk 1.2.2 ebuild that he sent.
229
	einfo "*********************************************************"
230
	eerror "Some parts of Sun's JDK require XFree86 to be installed."
223
	eerror "Some parts of Sun's JDK require XFree86 to be installed."
231
	eerror "Be careful which Java libraries you attempt to use."
224
	eerror "Be careful which Java libraries you attempt to use."
232
	einfo "*********************************************************"
233
	echo
234
225
235
	einfo "*********************************************************"
226
	echo
236
	einfo " After installing ${P} this"
237
	einfo " was set as the default JVM to run."
238
	einfo " When finished please run the following so your"
239
	einfo " enviroment gets updated."
240
	eerror "    /usr/sbin/env-update && source /etc/profile"
241
	einfo " Or use java-config program to set your preferred VM"
242
	einfo "*********************************************************"
243
244
	# warn about a default setting in Java 1.5.0 rc
245
	einfo "*********************************************************"
246
	einfo " Be careful: ${P}'s Java compiler uses"
227
	einfo " Be careful: ${P}'s Java compiler uses"
247
	einfo " '-source 1.5' as default. Some keywords such as 'enum'"
228
	einfo " '-source 1.5' as default. Some keywords such as 'enum'"
248
	einfo " are not valid identifiers any more in that mode,"
229
	einfo " are not valid identifiers any more in that mode,"
249
	einfo " which can cause incompatibility with certain sources."
230
	einfo " which can cause incompatibility with certain sources."
250
	einfo "*********************************************************"
251
231
252
	ebeep 5
232
	ebeep 5
253
	epause 8
233
	epause 8
(-)dev-java/sun-jre-bin/sun-jre-bin-1.4.2.05-r1.ebuild (-34 / +8 lines)
Lines 2-10 Link Here
2
# Distributed under the terms of the GNU General Public License v2
2
# Distributed under the terms of the GNU General Public License v2
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/sun-jre-bin/sun-jre-bin-1.4.2.05-r1.ebuild,v 1.1 2004/09/10 21:43:17 axxo Exp $
3
# $Header: /var/cvsroot/gentoo-x86/dev-java/sun-jre-bin/sun-jre-bin-1.4.2.05-r1.ebuild,v 1.1 2004/09/10 21:43:17 axxo Exp $
4
4
5
IUSE="gnome kde mozilla"
6
5
7
inherit java nsplugins eutils
6
inherit java eutils
8
7
9
At="j2re-1_4_2_05-linux-i586.bin"
8
At="j2re-1_4_2_05-linux-i586.bin"
10
S="${WORKDIR}/j2re1.4.2_05"
9
S="${WORKDIR}/j2re1.4.2_05"
Lines 15-20 Link Here
15
LICENSE="sun-bcla-java-vm"
14
LICENSE="sun-bcla-java-vm"
16
KEYWORDS="~x86 -ppc -sparc -alpha -mips -hppa"
15
KEYWORDS="~x86 -ppc -sparc -alpha -mips -hppa"
17
RESTRICT="fetch"
16
RESTRICT="fetch"
17
IUSE="gnome kde mozilla"
18
18
19
DEPEND=">=dev-java/java-config-1.1.5
19
DEPEND=">=dev-java/java-config-1.1.5
20
	sys-apps/sed"
20
	sys-apps/sed"
Lines 77-90 Link Here
77
	dodoc CHANGES COPYRIGHT README LICENSE THIRDPARTYLICENSEREADME.txt
77
	dodoc CHANGES COPYRIGHT README LICENSE THIRDPARTYLICENSEREADME.txt
78
	dohtml Welcome.html ControlPanel.html
78
	dohtml Welcome.html ControlPanel.html
79
79
80
	if use mozilla ; then
80
	local plugin_dir="ns610"
81
	local plugin_dir="ns610"
81
	if has_version '>=gcc-3.2*' ; then
82
	if has_version '>=gcc-3.2*' ; then
82
		plugin_dir="ns610-gcc32"
83
		plugin_dir="ns610-gcc32"
83
	fi
84
	fi
84
	if use mozilla ; then
85
		install_mozilla_plugin /opt/${P}/plugin/i386/$plugin_dir/libjavaplugin_oji.so
85
		install_mozilla_plugin /opt/${P}/plugin/i386/$plugin_dir/libjavaplugin_oji.so
86
	fi
86
	fi
87
	inst_plugin /opt/${P}/plugin/i386/$plugin_dir/libjavaplugin_oji.so
88
87
89
	# create dir for system preferences
88
	# create dir for system preferences
90
	dodir /opt/${P}/.systemPrefs
89
	dodir /opt/${P}/.systemPrefs
Lines 121-135 Link Here
121
	touch /opt/${P}/.systemPrefs/.systemRootModFile
120
	touch /opt/${P}/.systemPrefs/.systemRootModFile
122
	chmod 644 /opt/${P}/.systemPrefs/.systemRootModFile
121
	chmod 644 /opt/${P}/.systemPrefs/.systemRootModFile
123
122
123
	java_pkg_postinst
124
124
	#Show info about netscape
125
	#Show info about netscape
125
	if has_version '>=netscape-navigator-4.79-r1' || has_version '>=netscape-communicator-4.79-r1' ; then
126
	if has_version '>=netscape-navigator-4.79-r1' || has_version '>=netscape-communicator-4.79-r1' ; then
126
		einfo "********************************************************"
127
		echo
127
		einfo "If you want to install the plugin for Netscape 4.x, type"
128
		einfo "If you want to install the plugin for Netscape 4.x, type"
128
		einfo
129
		einfo
129
		einfo "   cd /usr/lib/nsbrowser/plugins/"
130
		einfo "   cd /usr/lib/nsbrowser/plugins/"
130
		einfo "   ln -sf /opt/${P}/jre/plugin/i386/ns4/libjavaplugin.so"
131
		einfo "   ln -sf /opt/${P}/jre/plugin/i386/ns4/libjavaplugin.so"
131
		einfo "********************************************************"
132
		echo
133
	fi
132
	fi
134
133
135
	# if chpax is on the target system, set the appropriate PaX flags
134
	# if chpax is on the target system, set the appropriate PaX flags
Lines 137-142 Link Here
137
	# but may confuse things like AV scanners and automatic tripwire
136
	# but may confuse things like AV scanners and automatic tripwire
138
	if has_version "sys-apps/chpax"
137
	if has_version "sys-apps/chpax"
139
	then
138
	then
139
		echo
140
		einfo "setting up conservative PaX flags for jar, javac and java"
140
		einfo "setting up conservative PaX flags for jar, javac and java"
141
141
142
		for paxkills in "java"
142
		for paxkills in "java"
Lines 154-189 Link Here
154
		ewarn "can be given by #gentoo-hardened + pappy@gentoo.org"
154
		ewarn "can be given by #gentoo-hardened + pappy@gentoo.org"
155
	fi
155
	fi
156
156
157
	#Thanks to Douglas Pollock <douglas.pollock@magma.ca> for this
157
	echo
158
	#comment found on the sun-jre 1.2.2 ebuild that he sent.
159
	einfo "*********************************************************"
160
	eerror "Some parts of Sun's JDK require XFree86 to be installed."
158
	eerror "Some parts of Sun's JDK require XFree86 to be installed."
161
	eerror "Be careful which Java libraries you attempt to use."
159
	eerror "Be careful which Java libraries you attempt to use."
162
	einfo "*********************************************************"
163
	echo
164
165
	# Set as default VM if none exists
166
	if [ ! -f "${JAVAC}" ] ; then
167
		java_pkg_postinst
168
169
		einfo "******************************************************"
170
		einfo " After installing ${P} this"
171
		einfo " was set as the default JVM to run."
172
		einfo " When finished please run the following so your"
173
		einfo " enviroment gets updated."
174
		eerror "    /usr/sbin/env-update && source /etc/profile"
175
		einfo " Or use java-config program to set your preferred VM"
176
		einfo "******************************************************"
177
	fi
178
160
179
	ebeep 5
161
	ebeep 5
180
	epause 8
162
	epause 8
181
}
163
}
182
183
pkg_prerm() {
184
	if [ ! -z "$(java-config -J | grep ${P})" ] ; then
185
		java-config -J
186
		ewarn "It appears you are removing your default system VM!"
187
		ewarn "Please run java-config -L then java-config-S to set a new system VM!"
188
	fi
189
}
(-)eclass/java.eclass (-41 / +53 lines)
Lines 12-61 Link Here
12
12
13
VMHANDLE=${PN}-${PV}
13
VMHANDLE=${PN}-${PV}
14
14
15
function sed2() {
15
EXPORT_FUNCTIONS pkg_postinst pkg_prerm
16
	unset filename
17
	unset arglist
18
	local filename=""
19
	local arglist
20
	declare -a arglist
21
	while test $# -gt 0 ; do
22
		case $1 in
23
			-e)
24
				shift
25
				arglist[${#arglist[@]}]="-e"
26
				arglist[${#arglist[@]}]="$1"
27
			;;
28
			*)
29
				if [ -e "$1" ] ; then
30
					filename=$1
31
				fi
32
			;;
33
		esac
34
		shift
35
	done
36
16
37
	if [ ! -z $filename ] ; then
17
java_pkg_postinst() {
38
		mv "${filename}" "${filename}.orig"
18
	local jdk=${PN#*-}
39
		sed "${arglist[@]}" < ${filename}.orig > ${filename}
19
	if [ ${jdk:0:3} == "jdk" ]; then
40
		return 0
20
		java_set_default_vm_
41
	else
21
	else
42
		return 1
22
		# Only install the JRE as the system default if there's no JDK
23
		# installed. Installing a JRE over an existing JDK will result
24
		# in major breakage, see #9289.
25
		if [ ! -f "${JAVAC}" ]; then
26
			 ewarn "Found no JDK, setting ${VMHANDLE} as default system VM"
27
			java_set_default_vm_
43
	fi
28
	fi
29
	fi
30
	java_mozilla_clean_
44
}
31
}
45
32
46
java_pkg_postinst() {
33
java_pkg_prerm() {
47
#	if [ -z `java-config --java 2> /dev/null` ] ; then
34
	if java-config -J | grep -q ${P} ; then
48
#		einfo "No default VM found, setting ${VMHANDLE} as default"
35
		ewarn "It appears you are removing your default system VM!"
49
		einfo "Setting ${VMHANDLE} as default"
36
		ewarn "Please run java-config -L then java-config-S to set a new system VM!"
50
		einfo "Use java-config to reassign your VM."
37
	fi
38
}
39
40
java_set_default_vm_() {
51
		java-config --set-system-vm=${VMHANDLE}
41
		java-config --set-system-vm=${VMHANDLE}
52
		/usr/sbin/env-update
42
		/usr/sbin/env-update
53
		source /etc/profile
43
		source /etc/profile
54
#	fi
55
}
56
44
57
pkg_postinst() {
45
	echo
58
	java_pkg_postinst
46
	einfo " After installing ${P} this"
47
	einfo " was set as the default JVM to run."
48
	einfo " When finished please run the following so your"
49
	einfo " enviroment gets updated."
50
	eerror "	/usr/sbin/env-update && source /etc/profile"
51
	einfo " Or use java-config program to set your preferred VM"
59
}
52
}
60
53
61
system_arch() {
54
system_arch() {
Lines 82-93 Link Here
82
		> ${D}/etc/env.d/java/20`basename $1` || die
75
		> ${D}/etc/env.d/java/20`basename $1` || die
83
}
76
}
84
77
85
install_mozilla_plugin() {
86
	local bn
87
	bn=`basename $1`
88
78
89
	if use mozilla ; then
79
java_get_plugin_dir_() {
90
		dodir /usr/$(get_libdir)/mozilla/plugins
80
	echo /usr/$(get_libdir)/nsbrowser/plugins
91
		dosym $1 /usr/$(get_libdir)/mozilla/plugins/${bn}
81
}
82
83
install_mozilla_plugin() {
84
	if [ ! -f ${D}/$1 ] ; then
85
		die "Cannot find ${1}"
92
	fi
86
	fi
87
88
	local plugin_dir=$(java_get_plugin_dir_)
89
	dodir ${plugin_dir}
90
	dosym ${1} ${plugin_dir}/javaplugin.so
93
}
91
}
92
93
java_mozilla_clean_() {
94
	#Because previously some ebuilds installed symlinks outside of pkg_install
95
	#and are left behind, which forces you to manualy remove them to select the
96
	#jdk/jre you want to use for java
97
	local plugin_dir=$(java_get_plugin_dir_)
98
	for file in ${plugin_dir}/javaplugin_*; do
99
		rm -f ${file}
100
	done
101
	for file in ${plugin_dir}/libjavaplugin*; do
102
		rm -f ${file}
103
	done
104
}
105

Return to bug 22395