Gentoo Archives: gentoo-commits

From: "Vlastimil Babka (caster)" <caster@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-java/icedtea: ChangeLog icedtea-6.1.9.3.ebuild
Date: Thu, 02 Dec 2010 17:16:52
Message-Id: 20101202171634.3C67220054@flycatcher.gentoo.org
1 caster 10/12/02 17:16:34
2
3 Modified: ChangeLog
4 Added: icedtea-6.1.9.3.ebuild
5 Log:
6 Version bump.
7
8 (Portage version: 2.2.0_alpha6/cvs/Linux x86_64)
9
10 Revision Changes Path
11 1.15 dev-java/icedtea/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-java/icedtea/ChangeLog?rev=1.15&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-java/icedtea/ChangeLog?rev=1.15&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-java/icedtea/ChangeLog?r1=1.14&r2=1.15
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/dev-java/icedtea/ChangeLog,v
20 retrieving revision 1.14
21 retrieving revision 1.15
22 diff -u -r1.14 -r1.15
23 --- ChangeLog 26 Nov 2010 22:07:44 -0000 1.14
24 +++ ChangeLog 2 Dec 2010 17:16:32 -0000 1.15
25 @@ -1,6 +1,11 @@
26 # ChangeLog for dev-java/icedtea
27 # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/dev-java/icedtea/ChangeLog,v 1.14 2010/11/26 22:07:44 caster Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/dev-java/icedtea/ChangeLog,v 1.15 2010/12/02 17:16:32 caster Exp $
30 +
31 +*icedtea-6.1.9.3 (02 Dec 2010)
32 +
33 + 02 Dec 2010; Vlastimil Babka <caster@g.o> +icedtea-6.1.9.3.ebuild:
34 + Version bump.
35
36 26 Nov 2010; Vlastimil Babka <caster@g.o> icedtea-6.1.9.1.ebuild,
37 icedtea-6.1.9.2.ebuild:
38
39
40
41 1.1 dev-java/icedtea/icedtea-6.1.9.3.ebuild
42
43 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-java/icedtea/icedtea-6.1.9.3.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-java/icedtea/icedtea-6.1.9.3.ebuild?rev=1.1&content-type=text/plain
45
46 Index: icedtea-6.1.9.3.ebuild
47 ===================================================================
48 # Copyright 1999-2010 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/dev-java/icedtea/icedtea-6.1.9.3.ebuild,v 1.1 2010/12/02 17:16:34 caster Exp $
51 # Build written by Andrew John Hughes (gnu_andrew@××××××××××.org)
52
53 # *********************************************************
54 # * IF YOU CHANGE THIS EBUILD, CHANGE ICEDTEA-7.* AS WELL *
55 # *********************************************************
56
57 EAPI="2"
58
59 inherit pax-utils java-pkg-2 java-vm-2 versionator
60
61 LICENSE="Apache-1.1 Apache-2.0 GPL-1 GPL-2 GPL-2-with-linking-exception LGPL-2 MPL-1.0 MPL-1.1 public-domain W3C"
62 SLOT="6"
63 KEYWORDS="~amd64 ~x86"
64
65 DESCRIPTION="A harness to build the OpenJDK using Free Software build tools and dependencies"
66 ICEDTEA_VER="$(get_version_component_range 2-4)"
67 ICEDTEA_PKG=icedtea${SLOT}-${ICEDTEA_VER}
68 OPENJDK_BUILD="20"
69 OPENJDK_DATE="21_jun_2010"
70 OPENJDK_TARBALL="openjdk-6-src-b${OPENJDK_BUILD}-${OPENJDK_DATE}.tar.gz"
71 JAXP_TARBALL="jdk6-jaxp-b20.zip"
72 JAXWS_TARBALL="jdk6-jaxws-b20.zip"
73 JAF_TARBALL="jdk6-jaf-b20.zip"
74 HOTSPOT_TARBALL="13edc857b967.tar.gz"
75 CACAO_TARBALL="e321b101a9ee.tar.bz2"
76 SRC_URI="http://icedtea.classpath.org/download/source/${ICEDTEA_PKG}.tar.gz
77 http://download.java.net/openjdk/jdk6/promoted/b${OPENJDK_BUILD}/${OPENJDK_TARBALL}
78 http://icedtea.classpath.org/download/drops/${JAXWS_TARBALL}
79 http://icedtea.classpath.org/download/drops/${JAF_TARBALL}
80 http://icedtea.classpath.org/download/drops/${JAXP_TARBALL}
81 http://hg.openjdk.java.net/hsx/hsx19/master/archive/${HOTSPOT_TARBALL}
82 cacao? ( http://mips.complang.tuwien.ac.at/hg/cacao/archive/${CACAO_TARBALL} )"
83 HOMEPAGE="http://icedtea.classpath.org"
84 S=${WORKDIR}/${ICEDTEA_PKG}
85
86 # Missing options:
87 # shark - needs adding
88 IUSE="cacao debug doc examples +hs19 javascript nio2 +nsplugin +nss pulseaudio systemtap +webstart +xrender zero"
89
90 # JTReg doesn't pass at present
91 RESTRICT="test"
92
93 RDEPEND=">=net-print/cups-1.2.12
94 >=x11-libs/libX11-1.1.3
95 >=media-libs/freetype-2.3.5
96 >=media-libs/alsa-lib-1.0
97 >=x11-libs/gtk+-2.8
98 >=x11-libs/libXinerama-1.0.2
99 >=x11-libs/libXp-1.0.0
100 >=x11-libs/libXi-1.1.3
101 >=x11-libs/libXau-1.0.3
102 >=x11-libs/libXdmcp-1.0.2
103 >=x11-libs/libXtst-1.0.3
104 >=media-libs/jpeg-6b
105 >=media-libs/libpng-1.2
106 >=media-libs/giflib-4.1.6
107 >=sys-libs/zlib-1.2.3
108 x11-proto/inputproto
109 x11-proto/xineramaproto
110 nsplugin? ( >=net-libs/xulrunner-1.9.1 )
111 pulseaudio? ( >=media-sound/pulseaudio-0.9.11 )
112 javascript? ( dev-java/rhino:1.6 )
113 zero? ( virtual/libffi )
114 xrender? ( >=x11-libs/libXrender-0.9.4 )
115 systemtap? ( >=dev-util/systemtap-1 )
116 !dev-java/icedtea6
117 nss? ( >=dev-libs/nss-3.12.5-r1 )"
118
119 # Additional dependencies for building:
120 # zip: extract OpenJDK tarball, and needed by configure
121 # xalan/xerces: automatic code generation (also needed for Ant 1.8.0 to work properly)
122 # ant, ecj, jdk: required to build Java code
123 # Only ant-core-1.7.1-r2 and later contain a version of Ant that
124 # properly respects environment variables, if the build
125 # sets some environment variables.
126 # ca-certificates, perl and openssl are used for the cacerts keystore generation
127 # xext headers have two variants depending on version - bug #288855
128 DEPEND="${RDEPEND}
129 || (
130 ( >=dev-java/gcj-jdk-4.3 >=app-admin/eselect-ecj-0.5-r1 )
131 ( >=dev-java/cacao-0.99.2 >=app-admin/eselect-ecj-0.5-r1 )
132 dev-java/icedtea6-bin
133 dev-java/icedtea:${SLOT}
134 )
135 app-arch/zip
136 >=dev-java/xalan-2.7.0:0
137 >=dev-java/xerces-2.9.1:2
138 >=dev-java/ant-core-1.7.1-r2
139 dev-java/ant-nodeps
140 app-misc/ca-certificates
141 dev-lang/perl
142 dev-libs/openssl
143 || (
144 (
145 >=x11-libs/libXext-1.1.1
146 >=x11-proto/xextproto-7.1.1
147 x11-proto/xproto
148 )
149 <x11-libs/libXext-1.1.1
150 )
151 sys-apps/lsb-release"
152
153 # a bit of hack so the VM switching is triggered without causing dependency troubles
154 JAVA_PKG_NV_DEPEND=">=virtual/jdk-1.5"
155 JAVA_PKG_WANT_SOURCE="1.5"
156 JAVA_PKG_WANT_TARGET="1.5"
157
158 pkg_setup() {
159 # Shark support disabled for now - still experimental and needs sys-devel/llvm
160 # if use shark ; then
161 # if ( ! use x86 && ! use sparc && ! use ppc ) ; then
162 # eerror "The Shark JIT has known issues on 64-bit platforms. Please rebuild"
163 # errror "without the shark USE flag turned on."
164 # die "Rebuild without the shark USE flag on."
165 # fi
166 # if ( ! use zero ) ; then
167 # eerror "The use of the Shark JIT is only applicable when used with the zero assembler port.";
168 # die "Rebuild without the shark USE flag on or with the zero USE flag turned on."
169 # fi
170 # fi
171
172 # quite a hack since java-config does not provide a way for a package
173 # to limit supported VM's for building and their preferred order
174 if [[ -n "${JAVA_PKG_FORCE_VM}" ]]; then
175 einfo "Honoring user-set JAVA_PKG_FORCE_VM"
176 elif has_version "dev-java/icedtea:${SLOT}"; then
177 JAVA_PKG_FORCE_VM="icedtea6"
178 elif has_version dev-java/icedtea6; then
179 JAVA_PKG_FORCE_VM="icedtea6"
180 elif has_version dev-java/icedtea6-bin; then
181 JAVA_PKG_FORCE_VM="icedtea6-bin"
182 elif has_version dev-java/gcj-jdk; then
183 JAVA_PKG_FORCE_VM="gcj-jdk"
184 elif has_version dev-java/cacao; then
185 JAVA_PKG_FORCE_VM="cacao"
186 else
187 JAVA_PKG_FORCE_VM=""
188 # don't die just yet if merging a binpkg - bug #258423
189 DIE_IF_NOT_BINPKG=true
190 fi
191
192 # if the previous failed, don't even run java eclasses pkg_setup
193 # as it might also die when no VM is present
194 if [[ -n "${JAVA_PKG_FORCE_VM}" ]]; then
195 einfo "Forced vm ${JAVA_PKG_FORCE_VM}"
196 java-vm-2_pkg_setup
197 java-pkg-2_pkg_setup
198 fi
199
200 VMHANDLE="icedtea${SLOT}"
201 }
202
203 src_unpack() {
204 if [[ -n ${DIE_IF_NOT_BINPKG} ]]; then
205 die "Unable to find a supported VM for building"
206 fi
207 unpack ${ICEDTEA_PKG}.tar.gz
208 }
209
210 unset_vars() {
211 unset JAVA_HOME JDK_HOME CLASSPATH JAVAC JAVACFLAGS
212 }
213
214 src_configure() {
215 local config procs rhino_jar
216 local vm=$(java-pkg_get-current-vm)
217 local vmhome="/usr/lib/jvm/${vm}"
218
219 # IcedTea6 can't be built using IcedTea7; its class files are too new
220 if [[ "${vm}" == "icedtea6" ]] || [[ "${vm}" == "icedtea6-bin" ]] ; then
221 # If we are upgrading icedtea, then we don't need to bootstrap.
222 config="${config} --with-openjdk=$(java-config -O)"
223 elif [[ "${vm}" == "gcj-jdk" || "${vm}" == "cacao" ]] ; then
224 # For other 1.5 JDKs e.g. GCJ, CACAO.
225 config="${config} --with-ecj-jar=/usr/share/eclipse-ecj/ecj.jar" \
226 config="${config} --with-gcj-home=${vmhome}"
227 else
228 eerror "IcedTea${SLOT} must be built with either a JDK based on GNU Classpath or an existing build of IcedTea${SLOT}."
229 die "Install a GNU Classpath JDK (gcj-jdk, cacao)"
230 fi
231
232 # OpenJDK-specific parallelism support.
233 procs=$(echo ${MAKEOPTS} | sed -r 's/.*-j\W*([0-9]+).*/\1/')
234 if [[ -n ${procs} ]] ; then
235 config="${config} --with-parallel-jobs=${procs}";
236 einfo "Configuring using --with-parallel-jobs=${procs}"
237 fi
238
239 if use_zero ; then
240 config="${config} --enable-zero"
241 else
242 config="${config} --disable-zero"
243 fi
244
245 if use javascript ; then
246 rhino_jar=$(java-pkg_getjar rhino:1.6 js.jar);
247 fi
248
249 if use hs19 ; then
250 config="${config} --with-hotspot-build=hs19"
251 fi
252
253 unset_vars
254
255 econf ${config} \
256 --with-openjdk-src-zip="${DISTDIR}/${OPENJDK_TARBALL}" \
257 --with-hotspot-src-zip="${DISTDIR}/${HOTSPOT_TARBALL}" \
258 --with-jaxp-drop-zip="${DISTDIR}/${JAXP_TARBALL}" \
259 --with-jaxws-drop-zip="${DISTDIR}/${JAXWS_TARBALL}" \
260 --with-jaf-drop-zip="${DISTDIR}/${JAF_TARBALL}" \
261 --with-cacao-src-zip="${DISTDIR}/${CACAO_TARBALL}" \
262 --with-java="${vmhome}/bin/java" \
263 --with-javac="${vmhome}/bin/javac" \
264 --with-javah="${vmhome}/bin/javah" \
265 --with-abs-install-dir=/usr/$(get_libdir)/icedtea${SLOT} \
266 $(use_enable !debug optimizations) \
267 $(use_enable doc docs) \
268 $(use_enable nsplugin plugin) \
269 $(use_with javascript rhino ${rhino_jar}) \
270 $(use_enable cacao) \
271 $(use_enable pulseaudio pulse-java) \
272 $(use_enable xrender) \
273 $(use_enable systemtap) \
274 $(use_enable nio2) \
275 $(use_enable nss) \
276 $(use_enable webstart) \
277 || die "configure failed"
278 }
279
280 src_compile() {
281 # Newer versions of Gentoo's ant add
282 # an environment variable so it works properly...
283 export ANT_RESPECT_JAVA_HOME=TRUE
284 # ant -diagnostics in Ant 1.8.0 fails without these
285 # otherwise we try to load the least that's needed to avoid possible classpath collisions
286 export ANT_TASKS="xerces-2 xalan ant-nodeps"
287
288 # Paludis does not respect unset from src_configure
289 unset_vars
290 emake -j 1 || die "make failed"
291 }
292
293 src_install() {
294 local dest="${ROOT}usr/$(get_libdir)/icedtea${SLOT}"
295 local ddest="${D}/${dest}"
296 dodir "${dest}" || die
297
298 dodoc README NEWS AUTHORS THANKYOU || die
299 dosym "${ROOT}usr/share/doc/${PF}" "${ROOT}usr/share/doc/${PN}${SLOT}"
300
301 cd "${S}/openjdk.build/j2sdk-image" || die
302
303 if use doc ; then
304 # java-pkg_dohtml needed for package-list #302654
305 java-pkg_dohtml -r ../docs/* || die "Failed to install documentation"
306 fi
307
308 # doins can't handle symlinks.
309 cp -vRP bin include jre lib man "${ddest}" || die "failed to copy"
310
311 # Set PaX markings on all JDK/JRE executables to allow code-generation on
312 # the heap by the JIT compiler.
313 pax-mark m $(list-paxables "${ddest}"{,/jre}/bin/*)
314
315 dodoc ASSEMBLY_EXCEPTION THIRD_PARTY_README || die
316
317 if use examples; then
318 dodir "${dest}/share";
319 cp -vRP demo sample "${ddest}/share/" || die
320 fi
321
322 cp src.zip "${ddest}" || die
323
324 # Fix the permissions.
325 find "${ddest}" \! -type l \( -perm /111 -exec chmod 755 {} \; -o -exec chmod 644 {} \; \) || die
326
327 if use nsplugin; then
328 local arch=${ARCH};
329 use x86 && arch=i386;
330 install_mozilla_plugin "${dest}/jre/lib/${arch}/IcedTeaPlugin.so";
331 fi
332
333 # We need to generate keystore - bug #273306
334 einfo "Generating cacerts file from certificates in /usr/share/ca-certificates/"
335 mkdir "${T}/certgen" && cd "${T}/certgen" || die
336 cp "${FILESDIR}/generate-cacerts.pl" . && chmod +x generate-cacerts.pl || die
337 for c in /usr/share/ca-certificates/*/*.crt; do
338 openssl x509 -text -in "${c}" >> all.crt || die
339 done
340 ./generate-cacerts.pl "${ddest}/bin/keytool" all.crt || die
341 cp -vRP cacerts "${ddest}/jre/lib/security/" || die
342 chmod 644 "${ddest}/jre/lib/security/cacerts" || die
343
344 sed -e "s/@SLOT@/${SLOT}/g" \
345 -e "s/@PV@/${ICEDTEA_VER}/g" \
346 < "${FILESDIR}/icedtea.env" > "${T}/icedtea.env"
347 set_java_env "${T}/icedtea.env"
348 }
349
350 use_zero() {
351 use zero || ( ! use amd64 && ! use x86 && ! use sparc )
352 }
353
354 pkg_postinst() {
355 # Set as default VM if none exists
356 java-vm-2_pkg_postinst
357
358 if use nsplugin; then
359 elog "The icedtea${SLOT} browser plugin (NPPlugin) can be enabled using eselect java-nsplugin"
360 elog "Note that the plugin works only in browsers based on xulrunner-1.9.1 or later"
361 elog "such as Firefox 3.5+, Chromium and perhaps some others too."
362 fi
363 }