From ptisnovs at redhat.com Mon Jan 3 07:58:31 2011 From: ptisnovs at redhat.com (Pavel Tisnovsky) Date: Mon, 03 Jan 2011 16:58:31 +0100 Subject: Backport to fix iTXt chunk handling for pngs In-Reply-To: <20101224211821.GA26390@redhat.com> References: <20101223203830.GA13424@redhat.com> <20101223221754.GA2994@redhat.com> <20101223223006.GA11447@redhat.com> <20101224150841.GA16863@rivendell.middle-earth.co.uk> <20101224211821.GA26390@redhat.com> Message-ID: <4D21F227.9050505@redhat.com> Deepak Bhole wrote: > > Here is the updated patchset for HEAD, 1.7, 1.8 and 1.9. It contains the > OOM patch + ChangeLog and NEWS entries. > > I've tested all 4 builds and they fix the issue. > > Cheers, > Deepak > Hi Deepak, it looks good from my perspective. I've run reproducer attached to https://bugzilla.redhat.com/show_bug.cgi?id=665355 against patched IcedTea6 HEAD and your changes really fix this issue ;-) FYI: I'm going to use this reproducer to create regression test (not using URL-connection and not using /probably/ copyrighted PNG images, of course) Cheers, Pavel From bugzilla-daemon at icedtea.classpath.org Mon Jan 3 12:04:55 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 03 Jan 2011 20:04:55 +0000 Subject: [Bug 609] New: Changing the Look and feel crashes the jvm Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=609 Summary: Changing the Look and feel crashes the jvm Product: IcedTea Version: 6-1.9.2 Platform: 64-bit URL: http://www.pastedump.com/paste/1173 OS/Version: Linux Status: NEW Severity: normal Priority: P2 Component: IcedTea6 AssignedTo: unassigned at icedtea.classpath.org ReportedBy: xander at badeend.org Executing the following piece of code gives me always an error: //Set Look & Feel try { LookAndFeelInfo[] lafs = javax.swing.UIManager.getInstalledLookAndFeels(); String s = lafs[3].getClassName(); System.out.println(s); javax.swing.UIManager.setLookAndFeel(s); } catch(Exception e) { e.printStackTrace(); } s = com.sun.java.swing.plaf.gtk.GTKLookAndFeel The error log is stored in the given url. One final note: switching to the other look and feels 0-2 works. -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Mon Jan 3 12:05:38 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 03 Jan 2011 20:05:38 +0000 Subject: [Bug 609] Changing the Look and feel crashes the jvm Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=609 xander at badeend.org changed: What |Removed |Added ---------------------------------------------------------------------------- Platform|64-bit |x86_64 -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From dbhole at icedtea.classpath.org Tue Jan 4 06:52:13 2011 From: dbhole at icedtea.classpath.org (dbhole at icedtea.classpath.org) Date: Tue, 04 Jan 2011 14:52:13 +0000 Subject: /hg/icedtea6: Backport S6687968, S6541476, S6782079 Message-ID: changeset 1121be5e4dbd in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=1121be5e4dbd author: Deepak Bhole date: Tue Jan 04 08:50:11 2011 -0500 Backport S6687968, S6541476, S6782079 iTXt chunk handling for png now works correctly. diffstat: 6 files changed, 4817 insertions(+), 1 deletion(-) ChangeLog | 13 Makefile.am | 5 NEWS | 3 patches/openjdk/6541476-png-iTXt-chunk.patch | 549 ++ patches/openjdk/6687968-pngimagereader_mem_leak.patch | 126 patches/openjdk/6782079-png_metadata_oom.patch | 4122 +++++++++++++++++ diffs (truncated from 4857 to 500 lines): diff -r 6ded99cd18d4 -r 1121be5e4dbd ChangeLog --- a/ChangeLog Fri Dec 31 21:03:38 2010 +0100 +++ b/ChangeLog Tue Jan 04 08:50:11 2011 -0500 @@ -1,3 +1,16 @@ 2010-12-31 Mark Wielaard + + Backport S6687968, S6541476, S6782079 + * Makefile.am: Add missing "\" to the patch list, update to include + new patches. + * NEWS: Updated. + * patches/openjdk/6687968-pngimagereader_mem_leak.patch: Backport to allow + S6541476 fix to apply cleanly. + * patches/openjdk/6541476-png-iTXt-chunk.patch: Backport to fix iTXt chunk + handling for png images. Also addresses RH665355. + * patches/openjdk/6782079-png_metadata_oom.patch: Backport to fix + potential OOM error when reading metadata on truncated pngs. + 2010-12-31 Mark Wielaard * Makefile.am (ICEDTEA_PATCHES): Add missing backslash. diff -r 6ded99cd18d4 -r 1121be5e4dbd Makefile.am --- a/Makefile.am Fri Dec 31 21:03:38 2010 +0100 +++ b/Makefile.am Tue Jan 04 08:50:11 2011 -0500 @@ -313,7 +313,10 @@ ICEDTEA_PATCHES = \ patches/openjdk/6795356-proxylazyvalue-leak.patch \ patches/rendering-engine-tests.patch \ patches/jtreg-TestXEmbedServer-fix.patch \ - patches/openjdk/6800846-printing-quality.patch + patches/openjdk/6800846-printing-quality.patch \ + patches/openjdk/6687968-pngimagereader_mem_leak.patch \ + patches/openjdk/6541476-png-iTXt-chunk.patch \ + patches/openjdk/6782079-png_metadata_oom.patch if WITH_ALT_HSBUILD ICEDTEA_PATCHES += \ diff -r 6ded99cd18d4 -r 1121be5e4dbd NEWS --- a/NEWS Fri Dec 31 21:03:38 2010 +0100 +++ b/NEWS Tue Jan 04 08:50:11 2011 -0500 @@ -51,6 +51,9 @@ New in release 1.10 (2010-XX-XX): - S6979979, RH508185: Rounding error in font sizes selected by the GTK Look and Feel - S6795356: Leak caused by javax.swing.UIDefaults.ProxyLazyValue.acc - S6800846, RH662230: Printing quality degraded with Java 6 compared to 5.0, index out of bounds exception. + - S6687968: PNGImageReader leaks native memory through an Inflater + - S6541476, RH665355: PNG imageio plugin incorrectly handles iTXt chunk + - S6782079: PNG: reading metadata may cause OOM on truncated images * Bug fixes - S7003777, RH647674: JTextPane produces incorrect content after parsing the html text diff -r 6ded99cd18d4 -r 1121be5e4dbd patches/openjdk/6541476-png-iTXt-chunk.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/openjdk/6541476-png-iTXt-chunk.patch Tue Jan 04 08:50:11 2011 -0500 @@ -0,0 +1,549 @@ +diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java +--- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java 2010-12-23 17:11:16.193446425 -0500 ++++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java 2010-12-23 17:11:29.399447037 -0500 +@@ -44,7 +44,6 @@ + import java.util.Arrays; + import java.util.Enumeration; + import java.util.Iterator; +-import java.util.List; + import java.util.zip.Inflater; + import java.util.zip.InflaterInputStream; + import javax.imageio.IIOException; +@@ -57,6 +56,7 @@ + import com.sun.imageio.plugins.common.InputStreamAdapter; + import com.sun.imageio.plugins.common.ReaderUtil; + import com.sun.imageio.plugins.common.SubImageInputStream; ++import java.io.ByteArrayOutputStream; + import sun.awt.image.ByteInterleavedRaster; + + class PNGImageDataEnumeration implements Enumeration { +@@ -209,6 +209,15 @@ + resetStreamSettings(); + } + ++ private String readNullTerminatedString(String charset) throws IOException { ++ ByteArrayOutputStream baos = new ByteArrayOutputStream(); ++ int b; ++ while ((b = stream.read()) != 0) { ++ baos.write(b); ++ } ++ return new String(baos.toByteArray(), charset); ++ } ++ + private String readNullTerminatedString() throws IOException { + StringBuilder b = new StringBuilder(); + int c; +@@ -447,26 +456,27 @@ + metadata.iTXt_keyword.add(keyword); + + int compressionFlag = stream.readUnsignedByte(); +- metadata.iTXt_compressionFlag.add(new Integer(compressionFlag)); ++ metadata.iTXt_compressionFlag.add(Boolean.valueOf(compressionFlag == 1)); + + int compressionMethod = stream.readUnsignedByte(); +- metadata.iTXt_compressionMethod.add(new Integer(compressionMethod)); ++ metadata.iTXt_compressionMethod.add(Integer.valueOf(compressionMethod)); + +- String languageTag = readNullTerminatedString(); ++ String languageTag = readNullTerminatedString("UTF8"); + metadata.iTXt_languageTag.add(languageTag); + +- String translatedKeyword = stream.readUTF(); ++ String translatedKeyword = ++ readNullTerminatedString("UTF8"); + metadata.iTXt_translatedKeyword.add(translatedKeyword); +- stream.skipBytes(1); // Null separator + + String text; ++ long pos = stream.getStreamPosition(); ++ byte[] b = new byte[(int)(chunkStart + chunkLength - pos)]; ++ stream.readFully(b); ++ + if (compressionFlag == 1) { // Decompress the text +- long pos = stream.getStreamPosition(); +- byte[] b = new byte[(int)(chunkStart + chunkLength - pos)]; +- stream.readFully(b); +- text = inflate(b); ++ text = new String(inflate(b), "UTF8"); + } else { +- text = stream.readUTF(); ++ text = new String(b, "UTF8"); + } + metadata.iTXt_text.add(text); + } +@@ -615,20 +625,20 @@ + metadata.tRNS_present = true; + } + +- private static String inflate(byte[] b) throws IOException { ++ private static byte[] inflate(byte[] b) throws IOException { + InputStream bais = new ByteArrayInputStream(b); + InputStream iis = new InflaterInputStream(bais); ++ ByteArrayOutputStream baos = new ByteArrayOutputStream(); + +- StringBuilder sb = new StringBuilder(80); + int c; + try { + while ((c = iis.read()) != -1) { +- sb.append((char)c); ++ baos.write(c); + } + } finally { + iis.close(); + } +- return sb.toString(); ++ return baos.toByteArray(); + } + + private void parse_zTXt_chunk(int chunkLength) throws IOException { +@@ -640,7 +650,7 @@ + + byte[] b = new byte[chunkLength - keyword.length() - 2]; + stream.readFully(b); +- metadata.zTXt_text.add(inflate(b)); ++ metadata.zTXt_text.add(new String(inflate(b))); + } + + private void readMetadata() throws IIOException { +diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java +--- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java 2010-12-23 17:11:16.193446425 -0500 ++++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java 2010-12-23 17:11:29.400446993 -0500 +@@ -671,13 +671,13 @@ + } + } + +- private byte[] deflate(String s) throws IOException { ++ private byte[] deflate(byte[] b) throws IOException { + ByteArrayOutputStream baos = new ByteArrayOutputStream(); + DeflaterOutputStream dos = new DeflaterOutputStream(baos); + +- int len = s.length(); ++ int len = b.length; + for (int i = 0; i < len; i++) { +- dos.write((int)s.charAt(i)); ++ dos.write((int)(0xff & b[i])); + } + dos.close(); + +@@ -685,38 +685,37 @@ + } + + private void write_iTXt() throws IOException { +- Iterator keywordIter = metadata.iTXt_keyword.iterator(); +- Iterator flagIter = metadata.iTXt_compressionFlag.iterator(); +- Iterator methodIter = metadata.iTXt_compressionMethod.iterator(); +- Iterator languageIter = metadata.iTXt_languageTag.iterator(); +- Iterator translatedKeywordIter = ++ Iterator keywordIter = metadata.iTXt_keyword.iterator(); ++ Iterator flagIter = metadata.iTXt_compressionFlag.iterator(); ++ Iterator methodIter = metadata.iTXt_compressionMethod.iterator(); ++ Iterator languageIter = metadata.iTXt_languageTag.iterator(); ++ Iterator translatedKeywordIter = + metadata.iTXt_translatedKeyword.iterator(); +- Iterator textIter = metadata.iTXt_text.iterator(); ++ Iterator textIter = metadata.iTXt_text.iterator(); + + while (keywordIter.hasNext()) { + ChunkStream cs = new ChunkStream(PNGImageReader.iTXt_TYPE, stream); +- String keyword = (String)keywordIter.next(); +- cs.writeBytes(keyword); ++ ++ cs.writeBytes(keywordIter.next()); + cs.writeByte(0); + +- int flag = ((Integer)flagIter.next()).intValue(); +- cs.writeByte(flag); +- int method = ((Integer)methodIter.next()).intValue(); +- cs.writeByte(method); ++ Boolean compressed = flagIter.next(); ++ cs.writeByte(compressed ? 1 : 0); + +- String languageTag = (String)languageIter.next(); +- cs.writeBytes(languageTag); ++ cs.writeByte(methodIter.next().intValue()); ++ ++ cs.writeBytes(languageIter.next()); + cs.writeByte(0); + +- String translatedKeyword = (String)translatedKeywordIter.next(); +- cs.writeBytes(translatedKeyword); ++ ++ cs.write(translatedKeywordIter.next().getBytes("UTF8")); + cs.writeByte(0); + +- String text = (String)textIter.next(); +- if (flag == 1) { +- cs.write(deflate(text)); ++ String text = textIter.next(); ++ if (compressed) { ++ cs.write(deflate(text.getBytes("UTF8"))); + } else { +- cs.writeUTF(text); ++ cs.write(text.getBytes("UTF8")); + } + cs.finish(); + } +@@ -737,7 +736,7 @@ + cs.writeByte(compressionMethod); + + String text = (String)textIter.next(); +- cs.write(deflate(text)); ++ cs.write(deflate(text.getBytes())); + cs.finish(); + } + } +diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java +--- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java 2010-06-21 17:15:11.000000000 -0400 ++++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java 2010-12-23 17:11:29.401446953 -0500 +@@ -176,12 +176,12 @@ + public byte[] iCCP_compressedProfile; + + // iTXt chunk +- public ArrayList iTXt_keyword = new ArrayList(); // Strings +- public ArrayList iTXt_compressionFlag = new ArrayList(); // Integers +- public ArrayList iTXt_compressionMethod = new ArrayList(); // Integers +- public ArrayList iTXt_languageTag = new ArrayList(); // Strings +- public ArrayList iTXt_translatedKeyword = new ArrayList(); // Strings +- public ArrayList iTXt_text = new ArrayList(); // Strings ++ public ArrayList iTXt_keyword = new ArrayList(); ++ public ArrayList iTXt_compressionFlag = new ArrayList(); ++ public ArrayList iTXt_compressionMethod = new ArrayList(); ++ public ArrayList iTXt_languageTag = new ArrayList(); ++ public ArrayList iTXt_translatedKeyword = new ArrayList(); ++ public ArrayList iTXt_text = new ArrayList(); + + // pHYs chunk + public boolean pHYs_present; +@@ -599,19 +599,17 @@ + if (iTXt_keyword.size() > 0) { + IIOMetadataNode iTXt_parent = new IIOMetadataNode("iTXt"); + for (int i = 0; i < iTXt_keyword.size(); i++) { +- Integer val; +- + IIOMetadataNode iTXt_node = new IIOMetadataNode("iTXtEntry"); +- iTXt_node.setAttribute("keyword", (String)iTXt_keyword.get(i)); +- val = (Integer)iTXt_compressionFlag.get(i); +- iTXt_node.setAttribute("compressionFlag", val.toString()); +- val = (Integer)iTXt_compressionMethod.get(i); +- iTXt_node.setAttribute("compressionMethod", val.toString()); ++ iTXt_node.setAttribute("keyword", iTXt_keyword.get(i)); ++ iTXt_node.setAttribute("compressionFlag", ++ iTXt_compressionFlag.get(i) ? "1" : "0"); ++ iTXt_node.setAttribute("compressionMethod", ++ iTXt_compressionMethod.get(i).toString()); + iTXt_node.setAttribute("languageTag", +- (String)iTXt_languageTag.get(i)); ++ iTXt_languageTag.get(i)); + iTXt_node.setAttribute("translatedKeyword", +- (String)iTXt_translatedKeyword.get(i)); +- iTXt_node.setAttribute("text", (String)iTXt_text.get(i)); ++ iTXt_translatedKeyword.get(i)); ++ iTXt_node.setAttribute("text", iTXt_text.get(i)); + + iTXt_parent.appendChild(iTXt_node); + } +@@ -1039,11 +1037,11 @@ + + for (int i = 0; i < iTXt_keyword.size(); i++) { + node = new IIOMetadataNode("TextEntry"); +- node.setAttribute("keyword", (String)iTXt_keyword.get(i)); +- node.setAttribute("value", (String)iTXt_text.get(i)); ++ node.setAttribute("keyword", iTXt_keyword.get(i)); ++ node.setAttribute("value", iTXt_text.get(i)); + node.setAttribute("language", +- (String)iTXt_languageTag.get(i)); +- if (((Integer)iTXt_compressionFlag.get(i)).intValue() == 1) { ++ iTXt_languageTag.get(i)); ++ if (iTXt_compressionFlag.get(i)) { + node.setAttribute("compression", "deflate"); + } else { + node.setAttribute("compression", "none"); +@@ -1429,11 +1427,11 @@ + + boolean compressionFlag = + getBooleanAttribute(iTXt_node, "compressionFlag"); +- iTXt_compressionFlag.add(new Boolean(compressionFlag)); ++ iTXt_compressionFlag.add(Boolean.valueOf(compressionFlag)); + + String compressionMethod = + getAttribute(iTXt_node, "compressionMethod"); +- iTXt_compressionMethod.add(compressionMethod); ++ iTXt_compressionMethod.add(Integer.valueOf(compressionMethod)); + + String languageTag = + getAttribute(iTXt_node, "languageTag"); +@@ -1952,13 +1950,10 @@ + tEXt_text.add(value); + } + } else { +- int flag = compression.equals("zip") ? +- 1 : 0; +- + // Use an iTXt node + iTXt_keyword.add(keyword); +- iTXt_compressionFlag.add(new Integer(flag)); +- iTXt_compressionMethod.add(new Integer(0)); ++ iTXt_compressionFlag.add(Boolean.valueOf(compression.equals("zip"))); ++ iTXt_compressionMethod.add(Integer.valueOf(0)); + iTXt_languageTag.add(language); + iTXt_translatedKeyword.add(keyword); // fake it + iTXt_text.add(value); +@@ -1995,12 +1990,12 @@ + gAMA_present = false; + hIST_present = false; + iCCP_present = false; +- iTXt_keyword = new ArrayList(); +- iTXt_compressionFlag = new ArrayList(); +- iTXt_compressionMethod = new ArrayList(); +- iTXt_languageTag = new ArrayList(); +- iTXt_translatedKeyword = new ArrayList(); +- iTXt_text = new ArrayList(); ++ iTXt_keyword = new ArrayList(); ++ iTXt_compressionFlag = new ArrayList(); ++ iTXt_compressionMethod = new ArrayList(); ++ iTXt_languageTag = new ArrayList(); ++ iTXt_translatedKeyword = new ArrayList(); ++ iTXt_text = new ArrayList(); + pHYs_present = false; + sBIT_present = false; + sPLT_present = false; +diff -urN openjdk.orig/jdk/test/javax/imageio/plugins/png/ITXtTest.java openjdk/jdk/test/javax/imageio/plugins/png/ITXtTest.java +--- openjdk.orig/jdk/test/javax/imageio/plugins/png/ITXtTest.java 1969-12-31 19:00:00.000000000 -0500 ++++ openjdk/jdk/test/javax/imageio/plugins/png/ITXtTest.java 2010-12-23 17:12:58.538446639 -0500 +@@ -0,0 +1,236 @@ ++/* ++ * Copyright (c) 2008, Oracle and/or its affiliates. All rights reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA ++ * or visit www.oracle.com if you need additional information or have any ++ * questions. ++ */ ++ ++/** ++ * @test ++ * @bug 6541476 ++ * @summary Test verifies that ImageIO PNG plugin correcly handles the ++ * iTxt chunk (International textual data). ++ * ++ * @run main ITXtTest ++ */ ++ ++ ++import java.awt.Color; ++import java.awt.Graphics2D; ++import java.awt.image.BufferedImage; ++import java.io.File; ++ ++import javax.imageio.ImageIO; ++import javax.imageio.ImageReader; ++import javax.imageio.IIOImage; ++import javax.imageio.ImageTypeSpecifier; ++import javax.imageio.ImageWriter; ++import javax.imageio.metadata.IIOMetadata; ++import javax.imageio.metadata.IIOMetadataNode; ++import javax.imageio.stream.ImageOutputStream; ++import javax.imageio.stream.ImageInputStream; ++ ++import org.w3c.dom.Node; ++ ++public class ITXtTest { ++ static public void main(String args[]) { ++ ITXtTest t_en = new ITXtTest(); ++ t_en.description = "xml - en"; ++ t_en.keyword = "XML:com.adobe.xmp"; ++ t_en.isCompressed = false; ++ t_en.compression = 0; ++ t_en.language = "en"; ++ t_en.trasKeyword = "XML:com.adobe.xmp"; ++ t_en.text = "Something"; ++ ++ doTest(t_en); ++ ++ // check compression case ++ t_en.isCompressed = true; ++ t_en.description = "xml - en - compressed"; ++ ++ doTest(t_en); ++ ++ ITXtTest t_ru = new ITXtTest(); ++ t_ru.description = "xml - ru"; ++ t_ru.keyword = "XML:com.adobe.xmp"; ++ t_ru.isCompressed = false; ++ t_ru.compression = 0; ++ t_ru.language = "ru"; ++ t_ru.trasKeyword = "\u0410\u0410\u0410\u0410\u0410 XML"; ++ t_ru.text = "\u042A\u042F\u042F\u042F\u042F\u042F\u042F"; ++ ++ doTest(t_ru); ++ ++ t_ru.isCompressed = true; ++ t_ru.description = "xml - ru - compressed"; ++ ++ doTest(t_ru); ++ } ++ ++ ++ String description; ++ ++ String keyword; ++ boolean isCompressed; ++ int compression; ++ String language; ++ String trasKeyword; ++ String text; ++ ++ ++ public IIOMetadataNode getNode() { ++ IIOMetadataNode iTXt = new IIOMetadataNode("iTXt"); ++ IIOMetadataNode iTXtEntry = new IIOMetadataNode("iTXtEntry"); ++ iTXtEntry.setAttribute("keyword", keyword); ++ iTXtEntry.setAttribute("compressionFlag", ++ isCompressed ? "true" : "false"); ++ iTXtEntry.setAttribute("compressionMethod", ++ Integer.toString(compression)); ++ iTXtEntry.setAttribute("languageTag", language); ++ iTXtEntry.setAttribute("translatedKeyword", ++ trasKeyword); ++ iTXtEntry.setAttribute("text", text); ++ iTXt.appendChild(iTXtEntry); ++ return iTXt; ++ } ++ ++ public static ITXtTest getFromNode(IIOMetadataNode n) { ++ ITXtTest t = new ITXtTest(); ++ ++ if (!"iTXt".equals(n.getNodeName())) { ++ throw new RuntimeException("Invalid node"); ++ } ++ IIOMetadataNode e = (IIOMetadataNode)n.getFirstChild(); ++ if (!"iTXtEntry".equals(e.getNodeName())) { ++ throw new RuntimeException("Invalid entry node"); ++ } ++ t.keyword = e.getAttribute("keyword"); ++ t.isCompressed = ++ (Integer.valueOf(e.getAttribute("compressionFlag")).intValue() == 1); ++ t.compression = ++ Integer.valueOf(e.getAttribute("compressionMethod")).intValue(); ++ t.language = e.getAttribute("languageTag"); ++ t.trasKeyword = e.getAttribute("translatedKeyword"); ++ t.text = e.getAttribute("text"); ++ ++ return t; ++ } ++ From dbhole at icedtea.classpath.org Tue Jan 4 06:52:51 2011 From: dbhole at icedtea.classpath.org (dbhole at icedtea.classpath.org) Date: Tue, 04 Jan 2011 14:52:51 +0000 Subject: /hg/release/icedtea6-1.7: Backport S6687968, S6541476, S6782079 Message-ID: changeset 3eec8b65af65 in /hg/release/icedtea6-1.7 details: http://icedtea.classpath.org/hg/release/icedtea6-1.7?cmd=changeset;node=3eec8b65af65 author: Deepak Bhole date: Tue Jan 04 08:50:49 2011 -0500 Backport S6687968, S6541476, S6782079 iTXt chunk handling for png now works correctly. diffstat: 6 files changed, 4818 insertions(+), 1 deletion(-) ChangeLog | 14 Makefile.am | 5 NEWS | 3 patches/openjdk/6541476-png-iTXt-chunk.patch | 549 ++ patches/openjdk/6687968-pngimagereader_mem_leak.patch | 126 patches/openjdk/6782079-png_metadata_oom.patch | 4122 +++++++++++++++++ diffs (truncated from 4859 to 500 lines): diff -r c39dead41c57 -r 3eec8b65af65 ChangeLog --- a/ChangeLog Thu Dec 23 15:52:54 2010 +0100 +++ b/ChangeLog Tue Jan 04 08:50:49 2011 -0500 @@ -1,4 +1,18 @@ 2010-12-23 Jiri Vanek + + Backport S6687968, S6541476, S6782079 + * Makefile.am: Add missing "\" to the patch list, update to include + new patches. + * NEWS: Updated. + * patches/openjdk/6687968-pngimagereader_mem_leak.patch: Backport to allow + S6541476 fix to apply cleanly. + * patches/openjdk/6541476-png-iTXt-chunk.patch: Backport to fix iTXt chunk + handling for png images. Also addresses RH665355. + * patches/openjdk/6782079-png_metadata_oom.patch: Backport to fix + potential OOM error when reading metadata on truncated pngs. + 2010-12-23 Jiri Vanek + * NEWS: Updated with rh.bugzilas. * patches/fonts-rhel.patch:repaired rhel 6 fonts configuration. diff -r c39dead41c57 -r 3eec8b65af65 Makefile.am --- a/Makefile.am Thu Dec 23 15:52:54 2010 +0100 +++ b/Makefile.am Tue Jan 04 08:50:49 2011 -0500 @@ -380,7 +380,10 @@ ICEDTEA_PATCHES = \ patches/openjdk/6438179-systray_check.patch \ patches/openjdk/4356282-opentype.patch \ patches/openjdk/6954424-opentype_javadoc.patch \ - patches/openjdk/6795356-proxylazyvalue-leak.patch + patches/openjdk/6795356-proxylazyvalue-leak.patch \ + patches/openjdk/6687968-pngimagereader_mem_leak.patch \ + patches/openjdk/6541476-png-iTXt-chunk.patch \ + patches/openjdk/6782079-png_metadata_oom.patch if WITH_ALT_HSBUILD ICEDTEA_PATCHES += patches/hotspot/$(HSBUILD)/openjdk-6886353-ignore_deoptimizealot.patch \ diff -r c39dead41c57 -r 3eec8b65af65 NEWS --- a/NEWS Thu Dec 23 15:52:54 2010 +0100 +++ b/NEWS Tue Jan 04 08:50:49 2011 -0500 @@ -18,6 +18,9 @@ New in release 1.7.7 (201X-XX-XX): - S6967433: dashed lines broken when using scaling transforms. - S6976265: No STROKE_CONTROL - S6967434, PR450, RH530642: Round joins/caps of scaled up lines have poor quality. + - S6687968: PNGImageReader leaks native memory through an Inflater + - S6541476, RH665355: PNG imageio plugin incorrectly handles iTXt chunk + - S6782079: PNG: reading metadata may cause OOM on truncated images * Fixes: - S7003777, RH647674: JTextPane produces incorrect content after parsing the html text - RH647157,RH582455: Update fontconfig files for rhel 6 diff -r c39dead41c57 -r 3eec8b65af65 patches/openjdk/6541476-png-iTXt-chunk.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/openjdk/6541476-png-iTXt-chunk.patch Tue Jan 04 08:50:49 2011 -0500 @@ -0,0 +1,549 @@ +diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java +--- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java 2010-12-23 17:11:16.193446425 -0500 ++++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java 2010-12-23 17:11:29.399447037 -0500 +@@ -44,7 +44,6 @@ + import java.util.Arrays; + import java.util.Enumeration; + import java.util.Iterator; +-import java.util.List; + import java.util.zip.Inflater; + import java.util.zip.InflaterInputStream; + import javax.imageio.IIOException; +@@ -57,6 +56,7 @@ + import com.sun.imageio.plugins.common.InputStreamAdapter; + import com.sun.imageio.plugins.common.ReaderUtil; + import com.sun.imageio.plugins.common.SubImageInputStream; ++import java.io.ByteArrayOutputStream; + import sun.awt.image.ByteInterleavedRaster; + + class PNGImageDataEnumeration implements Enumeration { +@@ -209,6 +209,15 @@ + resetStreamSettings(); + } + ++ private String readNullTerminatedString(String charset) throws IOException { ++ ByteArrayOutputStream baos = new ByteArrayOutputStream(); ++ int b; ++ while ((b = stream.read()) != 0) { ++ baos.write(b); ++ } ++ return new String(baos.toByteArray(), charset); ++ } ++ + private String readNullTerminatedString() throws IOException { + StringBuilder b = new StringBuilder(); + int c; +@@ -447,26 +456,27 @@ + metadata.iTXt_keyword.add(keyword); + + int compressionFlag = stream.readUnsignedByte(); +- metadata.iTXt_compressionFlag.add(new Integer(compressionFlag)); ++ metadata.iTXt_compressionFlag.add(Boolean.valueOf(compressionFlag == 1)); + + int compressionMethod = stream.readUnsignedByte(); +- metadata.iTXt_compressionMethod.add(new Integer(compressionMethod)); ++ metadata.iTXt_compressionMethod.add(Integer.valueOf(compressionMethod)); + +- String languageTag = readNullTerminatedString(); ++ String languageTag = readNullTerminatedString("UTF8"); + metadata.iTXt_languageTag.add(languageTag); + +- String translatedKeyword = stream.readUTF(); ++ String translatedKeyword = ++ readNullTerminatedString("UTF8"); + metadata.iTXt_translatedKeyword.add(translatedKeyword); +- stream.skipBytes(1); // Null separator + + String text; ++ long pos = stream.getStreamPosition(); ++ byte[] b = new byte[(int)(chunkStart + chunkLength - pos)]; ++ stream.readFully(b); ++ + if (compressionFlag == 1) { // Decompress the text +- long pos = stream.getStreamPosition(); +- byte[] b = new byte[(int)(chunkStart + chunkLength - pos)]; +- stream.readFully(b); +- text = inflate(b); ++ text = new String(inflate(b), "UTF8"); + } else { +- text = stream.readUTF(); ++ text = new String(b, "UTF8"); + } + metadata.iTXt_text.add(text); + } +@@ -615,20 +625,20 @@ + metadata.tRNS_present = true; + } + +- private static String inflate(byte[] b) throws IOException { ++ private static byte[] inflate(byte[] b) throws IOException { + InputStream bais = new ByteArrayInputStream(b); + InputStream iis = new InflaterInputStream(bais); ++ ByteArrayOutputStream baos = new ByteArrayOutputStream(); + +- StringBuilder sb = new StringBuilder(80); + int c; + try { + while ((c = iis.read()) != -1) { +- sb.append((char)c); ++ baos.write(c); + } + } finally { + iis.close(); + } +- return sb.toString(); ++ return baos.toByteArray(); + } + + private void parse_zTXt_chunk(int chunkLength) throws IOException { +@@ -640,7 +650,7 @@ + + byte[] b = new byte[chunkLength - keyword.length() - 2]; + stream.readFully(b); +- metadata.zTXt_text.add(inflate(b)); ++ metadata.zTXt_text.add(new String(inflate(b))); + } + + private void readMetadata() throws IIOException { +diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java +--- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java 2010-12-23 17:11:16.193446425 -0500 ++++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java 2010-12-23 17:11:29.400446993 -0500 +@@ -671,13 +671,13 @@ + } + } + +- private byte[] deflate(String s) throws IOException { ++ private byte[] deflate(byte[] b) throws IOException { + ByteArrayOutputStream baos = new ByteArrayOutputStream(); + DeflaterOutputStream dos = new DeflaterOutputStream(baos); + +- int len = s.length(); ++ int len = b.length; + for (int i = 0; i < len; i++) { +- dos.write((int)s.charAt(i)); ++ dos.write((int)(0xff & b[i])); + } + dos.close(); + +@@ -685,38 +685,37 @@ + } + + private void write_iTXt() throws IOException { +- Iterator keywordIter = metadata.iTXt_keyword.iterator(); +- Iterator flagIter = metadata.iTXt_compressionFlag.iterator(); +- Iterator methodIter = metadata.iTXt_compressionMethod.iterator(); +- Iterator languageIter = metadata.iTXt_languageTag.iterator(); +- Iterator translatedKeywordIter = ++ Iterator keywordIter = metadata.iTXt_keyword.iterator(); ++ Iterator flagIter = metadata.iTXt_compressionFlag.iterator(); ++ Iterator methodIter = metadata.iTXt_compressionMethod.iterator(); ++ Iterator languageIter = metadata.iTXt_languageTag.iterator(); ++ Iterator translatedKeywordIter = + metadata.iTXt_translatedKeyword.iterator(); +- Iterator textIter = metadata.iTXt_text.iterator(); ++ Iterator textIter = metadata.iTXt_text.iterator(); + + while (keywordIter.hasNext()) { + ChunkStream cs = new ChunkStream(PNGImageReader.iTXt_TYPE, stream); +- String keyword = (String)keywordIter.next(); +- cs.writeBytes(keyword); ++ ++ cs.writeBytes(keywordIter.next()); + cs.writeByte(0); + +- int flag = ((Integer)flagIter.next()).intValue(); +- cs.writeByte(flag); +- int method = ((Integer)methodIter.next()).intValue(); +- cs.writeByte(method); ++ Boolean compressed = flagIter.next(); ++ cs.writeByte(compressed ? 1 : 0); + +- String languageTag = (String)languageIter.next(); +- cs.writeBytes(languageTag); ++ cs.writeByte(methodIter.next().intValue()); ++ ++ cs.writeBytes(languageIter.next()); + cs.writeByte(0); + +- String translatedKeyword = (String)translatedKeywordIter.next(); +- cs.writeBytes(translatedKeyword); ++ ++ cs.write(translatedKeywordIter.next().getBytes("UTF8")); + cs.writeByte(0); + +- String text = (String)textIter.next(); +- if (flag == 1) { +- cs.write(deflate(text)); ++ String text = textIter.next(); ++ if (compressed) { ++ cs.write(deflate(text.getBytes("UTF8"))); + } else { +- cs.writeUTF(text); ++ cs.write(text.getBytes("UTF8")); + } + cs.finish(); + } +@@ -737,7 +736,7 @@ + cs.writeByte(compressionMethod); + + String text = (String)textIter.next(); +- cs.write(deflate(text)); ++ cs.write(deflate(text.getBytes())); + cs.finish(); + } + } +diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java +--- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java 2010-06-21 17:15:11.000000000 -0400 ++++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java 2010-12-23 17:11:29.401446953 -0500 +@@ -176,12 +176,12 @@ + public byte[] iCCP_compressedProfile; + + // iTXt chunk +- public ArrayList iTXt_keyword = new ArrayList(); // Strings +- public ArrayList iTXt_compressionFlag = new ArrayList(); // Integers +- public ArrayList iTXt_compressionMethod = new ArrayList(); // Integers +- public ArrayList iTXt_languageTag = new ArrayList(); // Strings +- public ArrayList iTXt_translatedKeyword = new ArrayList(); // Strings +- public ArrayList iTXt_text = new ArrayList(); // Strings ++ public ArrayList iTXt_keyword = new ArrayList(); ++ public ArrayList iTXt_compressionFlag = new ArrayList(); ++ public ArrayList iTXt_compressionMethod = new ArrayList(); ++ public ArrayList iTXt_languageTag = new ArrayList(); ++ public ArrayList iTXt_translatedKeyword = new ArrayList(); ++ public ArrayList iTXt_text = new ArrayList(); + + // pHYs chunk + public boolean pHYs_present; +@@ -599,19 +599,17 @@ + if (iTXt_keyword.size() > 0) { + IIOMetadataNode iTXt_parent = new IIOMetadataNode("iTXt"); + for (int i = 0; i < iTXt_keyword.size(); i++) { +- Integer val; +- + IIOMetadataNode iTXt_node = new IIOMetadataNode("iTXtEntry"); +- iTXt_node.setAttribute("keyword", (String)iTXt_keyword.get(i)); +- val = (Integer)iTXt_compressionFlag.get(i); +- iTXt_node.setAttribute("compressionFlag", val.toString()); +- val = (Integer)iTXt_compressionMethod.get(i); +- iTXt_node.setAttribute("compressionMethod", val.toString()); ++ iTXt_node.setAttribute("keyword", iTXt_keyword.get(i)); ++ iTXt_node.setAttribute("compressionFlag", ++ iTXt_compressionFlag.get(i) ? "1" : "0"); ++ iTXt_node.setAttribute("compressionMethod", ++ iTXt_compressionMethod.get(i).toString()); + iTXt_node.setAttribute("languageTag", +- (String)iTXt_languageTag.get(i)); ++ iTXt_languageTag.get(i)); + iTXt_node.setAttribute("translatedKeyword", +- (String)iTXt_translatedKeyword.get(i)); +- iTXt_node.setAttribute("text", (String)iTXt_text.get(i)); ++ iTXt_translatedKeyword.get(i)); ++ iTXt_node.setAttribute("text", iTXt_text.get(i)); + + iTXt_parent.appendChild(iTXt_node); + } +@@ -1039,11 +1037,11 @@ + + for (int i = 0; i < iTXt_keyword.size(); i++) { + node = new IIOMetadataNode("TextEntry"); +- node.setAttribute("keyword", (String)iTXt_keyword.get(i)); +- node.setAttribute("value", (String)iTXt_text.get(i)); ++ node.setAttribute("keyword", iTXt_keyword.get(i)); ++ node.setAttribute("value", iTXt_text.get(i)); + node.setAttribute("language", +- (String)iTXt_languageTag.get(i)); +- if (((Integer)iTXt_compressionFlag.get(i)).intValue() == 1) { ++ iTXt_languageTag.get(i)); ++ if (iTXt_compressionFlag.get(i)) { + node.setAttribute("compression", "deflate"); + } else { + node.setAttribute("compression", "none"); +@@ -1429,11 +1427,11 @@ + + boolean compressionFlag = + getBooleanAttribute(iTXt_node, "compressionFlag"); +- iTXt_compressionFlag.add(new Boolean(compressionFlag)); ++ iTXt_compressionFlag.add(Boolean.valueOf(compressionFlag)); + + String compressionMethod = + getAttribute(iTXt_node, "compressionMethod"); +- iTXt_compressionMethod.add(compressionMethod); ++ iTXt_compressionMethod.add(Integer.valueOf(compressionMethod)); + + String languageTag = + getAttribute(iTXt_node, "languageTag"); +@@ -1952,13 +1950,10 @@ + tEXt_text.add(value); + } + } else { +- int flag = compression.equals("zip") ? +- 1 : 0; +- + // Use an iTXt node + iTXt_keyword.add(keyword); +- iTXt_compressionFlag.add(new Integer(flag)); +- iTXt_compressionMethod.add(new Integer(0)); ++ iTXt_compressionFlag.add(Boolean.valueOf(compression.equals("zip"))); ++ iTXt_compressionMethod.add(Integer.valueOf(0)); + iTXt_languageTag.add(language); + iTXt_translatedKeyword.add(keyword); // fake it + iTXt_text.add(value); +@@ -1995,12 +1990,12 @@ + gAMA_present = false; + hIST_present = false; + iCCP_present = false; +- iTXt_keyword = new ArrayList(); +- iTXt_compressionFlag = new ArrayList(); +- iTXt_compressionMethod = new ArrayList(); +- iTXt_languageTag = new ArrayList(); +- iTXt_translatedKeyword = new ArrayList(); +- iTXt_text = new ArrayList(); ++ iTXt_keyword = new ArrayList(); ++ iTXt_compressionFlag = new ArrayList(); ++ iTXt_compressionMethod = new ArrayList(); ++ iTXt_languageTag = new ArrayList(); ++ iTXt_translatedKeyword = new ArrayList(); ++ iTXt_text = new ArrayList(); + pHYs_present = false; + sBIT_present = false; + sPLT_present = false; +diff -urN openjdk.orig/jdk/test/javax/imageio/plugins/png/ITXtTest.java openjdk/jdk/test/javax/imageio/plugins/png/ITXtTest.java +--- openjdk.orig/jdk/test/javax/imageio/plugins/png/ITXtTest.java 1969-12-31 19:00:00.000000000 -0500 ++++ openjdk/jdk/test/javax/imageio/plugins/png/ITXtTest.java 2010-12-23 17:12:58.538446639 -0500 +@@ -0,0 +1,236 @@ ++/* ++ * Copyright (c) 2008, Oracle and/or its affiliates. All rights reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA ++ * or visit www.oracle.com if you need additional information or have any ++ * questions. ++ */ ++ ++/** ++ * @test ++ * @bug 6541476 ++ * @summary Test verifies that ImageIO PNG plugin correcly handles the ++ * iTxt chunk (International textual data). ++ * ++ * @run main ITXtTest ++ */ ++ ++ ++import java.awt.Color; ++import java.awt.Graphics2D; ++import java.awt.image.BufferedImage; ++import java.io.File; ++ ++import javax.imageio.ImageIO; ++import javax.imageio.ImageReader; ++import javax.imageio.IIOImage; ++import javax.imageio.ImageTypeSpecifier; ++import javax.imageio.ImageWriter; ++import javax.imageio.metadata.IIOMetadata; ++import javax.imageio.metadata.IIOMetadataNode; ++import javax.imageio.stream.ImageOutputStream; ++import javax.imageio.stream.ImageInputStream; ++ ++import org.w3c.dom.Node; ++ ++public class ITXtTest { ++ static public void main(String args[]) { ++ ITXtTest t_en = new ITXtTest(); ++ t_en.description = "xml - en"; ++ t_en.keyword = "XML:com.adobe.xmp"; ++ t_en.isCompressed = false; ++ t_en.compression = 0; ++ t_en.language = "en"; ++ t_en.trasKeyword = "XML:com.adobe.xmp"; ++ t_en.text = "Something"; ++ ++ doTest(t_en); ++ ++ // check compression case ++ t_en.isCompressed = true; ++ t_en.description = "xml - en - compressed"; ++ ++ doTest(t_en); ++ ++ ITXtTest t_ru = new ITXtTest(); ++ t_ru.description = "xml - ru"; ++ t_ru.keyword = "XML:com.adobe.xmp"; ++ t_ru.isCompressed = false; ++ t_ru.compression = 0; ++ t_ru.language = "ru"; ++ t_ru.trasKeyword = "\u0410\u0410\u0410\u0410\u0410 XML"; ++ t_ru.text = "\u042A\u042F\u042F\u042F\u042F\u042F\u042F"; ++ ++ doTest(t_ru); ++ ++ t_ru.isCompressed = true; ++ t_ru.description = "xml - ru - compressed"; ++ ++ doTest(t_ru); ++ } ++ ++ ++ String description; ++ ++ String keyword; ++ boolean isCompressed; ++ int compression; ++ String language; ++ String trasKeyword; ++ String text; ++ ++ ++ public IIOMetadataNode getNode() { ++ IIOMetadataNode iTXt = new IIOMetadataNode("iTXt"); ++ IIOMetadataNode iTXtEntry = new IIOMetadataNode("iTXtEntry"); ++ iTXtEntry.setAttribute("keyword", keyword); ++ iTXtEntry.setAttribute("compressionFlag", ++ isCompressed ? "true" : "false"); ++ iTXtEntry.setAttribute("compressionMethod", ++ Integer.toString(compression)); ++ iTXtEntry.setAttribute("languageTag", language); ++ iTXtEntry.setAttribute("translatedKeyword", ++ trasKeyword); ++ iTXtEntry.setAttribute("text", text); ++ iTXt.appendChild(iTXtEntry); ++ return iTXt; ++ } ++ ++ public static ITXtTest getFromNode(IIOMetadataNode n) { ++ ITXtTest t = new ITXtTest(); ++ ++ if (!"iTXt".equals(n.getNodeName())) { ++ throw new RuntimeException("Invalid node"); ++ } ++ IIOMetadataNode e = (IIOMetadataNode)n.getFirstChild(); ++ if (!"iTXtEntry".equals(e.getNodeName())) { ++ throw new RuntimeException("Invalid entry node"); ++ } ++ t.keyword = e.getAttribute("keyword"); ++ t.isCompressed = ++ (Integer.valueOf(e.getAttribute("compressionFlag")).intValue() == 1); ++ t.compression = ++ Integer.valueOf(e.getAttribute("compressionMethod")).intValue(); ++ t.language = e.getAttribute("languageTag"); ++ t.trasKeyword = e.getAttribute("translatedKeyword"); ++ t.text = e.getAttribute("text"); ++ ++ return t; From dbhole at icedtea.classpath.org Tue Jan 4 06:53:34 2011 From: dbhole at icedtea.classpath.org (dbhole at icedtea.classpath.org) Date: Tue, 04 Jan 2011 14:53:34 +0000 Subject: /hg/release/icedtea6-1.8: Backport S6687968, S6541476, S6782079 Message-ID: changeset 4fefe62bdab3 in /hg/release/icedtea6-1.8 details: http://icedtea.classpath.org/hg/release/icedtea6-1.8?cmd=changeset;node=4fefe62bdab3 author: Deepak Bhole date: Tue Jan 04 08:51:33 2011 -0500 Backport S6687968, S6541476, S6782079 iTXt chunk handling for png now works correctly. diffstat: 6 files changed, 4818 insertions(+), 1 deletion(-) ChangeLog | 14 Makefile.am | 5 NEWS | 3 patches/openjdk/6541476-png-iTXt-chunk.patch | 549 ++ patches/openjdk/6687968-pngimagereader_mem_leak.patch | 126 patches/openjdk/6782079-png_metadata_oom.patch | 4122 +++++++++++++++++ diffs (truncated from 4859 to 500 lines): diff -r 78572b9f697c -r 4fefe62bdab3 ChangeLog --- a/ChangeLog Thu Dec 23 15:57:49 2010 +0100 +++ b/ChangeLog Tue Jan 04 08:51:33 2011 -0500 @@ -1,4 +1,18 @@ 2010-12-23 Jiri Vanek + + Backport S6687968, S6541476, S6782079 + * Makefile.am: Add missing "\" to the patch list, update to include + new patches. + * NEWS: Updated. + * patches/openjdk/6687968-pngimagereader_mem_leak.patch: Backport to allow + S6541476 fix to apply cleanly. + * patches/openjdk/6541476-png-iTXt-chunk.patch: Backport to fix iTXt chunk + handling for png images. Also addresses RH665355. + * patches/openjdk/6782079-png_metadata_oom.patch: Backport to fix + potential OOM error when reading metadata on truncated pngs. + 2010-12-23 Jiri Vanek + * NEWS: Updated with rh.bugzilas. * patches/fonts-rhel.patch:repaired rhel 6 fonts configuration. diff -r 78572b9f697c -r 4fefe62bdab3 Makefile.am --- a/Makefile.am Thu Dec 23 15:57:49 2010 +0100 +++ b/Makefile.am Tue Jan 04 08:51:33 2011 -0500 @@ -360,7 +360,10 @@ ICEDTEA_PATCHES = \ patches/openjdk/6438179-systray_check.patch \ patches/openjdk/4356282-opentype.patch \ patches/openjdk/6954424-opentype_javadoc.patch \ - patches/openjdk/6795356-proxylazyvalue-leak.patch + patches/openjdk/6795356-proxylazyvalue-leak.patch \ + patches/openjdk/6687968-pngimagereader_mem_leak.patch \ + patches/openjdk/6541476-png-iTXt-chunk.patch \ + patches/openjdk/6782079-png_metadata_oom.patch if WITH_ALT_HSBUILD ICEDTEA_PATCHES += patches/hotspot/$(HSBUILD)/openjdk-6886353-ignore_deoptimizealot.patch \ diff -r 78572b9f697c -r 4fefe62bdab3 NEWS --- a/NEWS Thu Dec 23 15:57:49 2010 +0100 +++ b/NEWS Tue Jan 04 08:51:33 2011 -0500 @@ -18,6 +18,9 @@ New in release 1.8.4 (201X-XX-XX): - S6967433: dashed lines broken when using scaling transforms. - S6976265: No STROKE_CONTROL - S6967434, PR450, RH530642: Round joins/caps of scaled up lines have poor quality. + - S6687968: PNGImageReader leaks native memory through an Inflater + - S6541476, RH665355: PNG imageio plugin incorrectly handles iTXt chunk + - S6782079: PNG: reading metadata may cause OOM on truncated images * Fixes: - S7003777, RH647674: JTextPane produces incorrect content after parsing the html text - RH647157,RH582455: Update fontconfig files for rhel 6 diff -r 78572b9f697c -r 4fefe62bdab3 patches/openjdk/6541476-png-iTXt-chunk.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/openjdk/6541476-png-iTXt-chunk.patch Tue Jan 04 08:51:33 2011 -0500 @@ -0,0 +1,549 @@ +diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java +--- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java 2010-12-23 17:11:16.193446425 -0500 ++++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java 2010-12-23 17:11:29.399447037 -0500 +@@ -44,7 +44,6 @@ + import java.util.Arrays; + import java.util.Enumeration; + import java.util.Iterator; +-import java.util.List; + import java.util.zip.Inflater; + import java.util.zip.InflaterInputStream; + import javax.imageio.IIOException; +@@ -57,6 +56,7 @@ + import com.sun.imageio.plugins.common.InputStreamAdapter; + import com.sun.imageio.plugins.common.ReaderUtil; + import com.sun.imageio.plugins.common.SubImageInputStream; ++import java.io.ByteArrayOutputStream; + import sun.awt.image.ByteInterleavedRaster; + + class PNGImageDataEnumeration implements Enumeration { +@@ -209,6 +209,15 @@ + resetStreamSettings(); + } + ++ private String readNullTerminatedString(String charset) throws IOException { ++ ByteArrayOutputStream baos = new ByteArrayOutputStream(); ++ int b; ++ while ((b = stream.read()) != 0) { ++ baos.write(b); ++ } ++ return new String(baos.toByteArray(), charset); ++ } ++ + private String readNullTerminatedString() throws IOException { + StringBuilder b = new StringBuilder(); + int c; +@@ -447,26 +456,27 @@ + metadata.iTXt_keyword.add(keyword); + + int compressionFlag = stream.readUnsignedByte(); +- metadata.iTXt_compressionFlag.add(new Integer(compressionFlag)); ++ metadata.iTXt_compressionFlag.add(Boolean.valueOf(compressionFlag == 1)); + + int compressionMethod = stream.readUnsignedByte(); +- metadata.iTXt_compressionMethod.add(new Integer(compressionMethod)); ++ metadata.iTXt_compressionMethod.add(Integer.valueOf(compressionMethod)); + +- String languageTag = readNullTerminatedString(); ++ String languageTag = readNullTerminatedString("UTF8"); + metadata.iTXt_languageTag.add(languageTag); + +- String translatedKeyword = stream.readUTF(); ++ String translatedKeyword = ++ readNullTerminatedString("UTF8"); + metadata.iTXt_translatedKeyword.add(translatedKeyword); +- stream.skipBytes(1); // Null separator + + String text; ++ long pos = stream.getStreamPosition(); ++ byte[] b = new byte[(int)(chunkStart + chunkLength - pos)]; ++ stream.readFully(b); ++ + if (compressionFlag == 1) { // Decompress the text +- long pos = stream.getStreamPosition(); +- byte[] b = new byte[(int)(chunkStart + chunkLength - pos)]; +- stream.readFully(b); +- text = inflate(b); ++ text = new String(inflate(b), "UTF8"); + } else { +- text = stream.readUTF(); ++ text = new String(b, "UTF8"); + } + metadata.iTXt_text.add(text); + } +@@ -615,20 +625,20 @@ + metadata.tRNS_present = true; + } + +- private static String inflate(byte[] b) throws IOException { ++ private static byte[] inflate(byte[] b) throws IOException { + InputStream bais = new ByteArrayInputStream(b); + InputStream iis = new InflaterInputStream(bais); ++ ByteArrayOutputStream baos = new ByteArrayOutputStream(); + +- StringBuilder sb = new StringBuilder(80); + int c; + try { + while ((c = iis.read()) != -1) { +- sb.append((char)c); ++ baos.write(c); + } + } finally { + iis.close(); + } +- return sb.toString(); ++ return baos.toByteArray(); + } + + private void parse_zTXt_chunk(int chunkLength) throws IOException { +@@ -640,7 +650,7 @@ + + byte[] b = new byte[chunkLength - keyword.length() - 2]; + stream.readFully(b); +- metadata.zTXt_text.add(inflate(b)); ++ metadata.zTXt_text.add(new String(inflate(b))); + } + + private void readMetadata() throws IIOException { +diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java +--- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java 2010-12-23 17:11:16.193446425 -0500 ++++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java 2010-12-23 17:11:29.400446993 -0500 +@@ -671,13 +671,13 @@ + } + } + +- private byte[] deflate(String s) throws IOException { ++ private byte[] deflate(byte[] b) throws IOException { + ByteArrayOutputStream baos = new ByteArrayOutputStream(); + DeflaterOutputStream dos = new DeflaterOutputStream(baos); + +- int len = s.length(); ++ int len = b.length; + for (int i = 0; i < len; i++) { +- dos.write((int)s.charAt(i)); ++ dos.write((int)(0xff & b[i])); + } + dos.close(); + +@@ -685,38 +685,37 @@ + } + + private void write_iTXt() throws IOException { +- Iterator keywordIter = metadata.iTXt_keyword.iterator(); +- Iterator flagIter = metadata.iTXt_compressionFlag.iterator(); +- Iterator methodIter = metadata.iTXt_compressionMethod.iterator(); +- Iterator languageIter = metadata.iTXt_languageTag.iterator(); +- Iterator translatedKeywordIter = ++ Iterator keywordIter = metadata.iTXt_keyword.iterator(); ++ Iterator flagIter = metadata.iTXt_compressionFlag.iterator(); ++ Iterator methodIter = metadata.iTXt_compressionMethod.iterator(); ++ Iterator languageIter = metadata.iTXt_languageTag.iterator(); ++ Iterator translatedKeywordIter = + metadata.iTXt_translatedKeyword.iterator(); +- Iterator textIter = metadata.iTXt_text.iterator(); ++ Iterator textIter = metadata.iTXt_text.iterator(); + + while (keywordIter.hasNext()) { + ChunkStream cs = new ChunkStream(PNGImageReader.iTXt_TYPE, stream); +- String keyword = (String)keywordIter.next(); +- cs.writeBytes(keyword); ++ ++ cs.writeBytes(keywordIter.next()); + cs.writeByte(0); + +- int flag = ((Integer)flagIter.next()).intValue(); +- cs.writeByte(flag); +- int method = ((Integer)methodIter.next()).intValue(); +- cs.writeByte(method); ++ Boolean compressed = flagIter.next(); ++ cs.writeByte(compressed ? 1 : 0); + +- String languageTag = (String)languageIter.next(); +- cs.writeBytes(languageTag); ++ cs.writeByte(methodIter.next().intValue()); ++ ++ cs.writeBytes(languageIter.next()); + cs.writeByte(0); + +- String translatedKeyword = (String)translatedKeywordIter.next(); +- cs.writeBytes(translatedKeyword); ++ ++ cs.write(translatedKeywordIter.next().getBytes("UTF8")); + cs.writeByte(0); + +- String text = (String)textIter.next(); +- if (flag == 1) { +- cs.write(deflate(text)); ++ String text = textIter.next(); ++ if (compressed) { ++ cs.write(deflate(text.getBytes("UTF8"))); + } else { +- cs.writeUTF(text); ++ cs.write(text.getBytes("UTF8")); + } + cs.finish(); + } +@@ -737,7 +736,7 @@ + cs.writeByte(compressionMethod); + + String text = (String)textIter.next(); +- cs.write(deflate(text)); ++ cs.write(deflate(text.getBytes())); + cs.finish(); + } + } +diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java +--- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java 2010-06-21 17:15:11.000000000 -0400 ++++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java 2010-12-23 17:11:29.401446953 -0500 +@@ -176,12 +176,12 @@ + public byte[] iCCP_compressedProfile; + + // iTXt chunk +- public ArrayList iTXt_keyword = new ArrayList(); // Strings +- public ArrayList iTXt_compressionFlag = new ArrayList(); // Integers +- public ArrayList iTXt_compressionMethod = new ArrayList(); // Integers +- public ArrayList iTXt_languageTag = new ArrayList(); // Strings +- public ArrayList iTXt_translatedKeyword = new ArrayList(); // Strings +- public ArrayList iTXt_text = new ArrayList(); // Strings ++ public ArrayList iTXt_keyword = new ArrayList(); ++ public ArrayList iTXt_compressionFlag = new ArrayList(); ++ public ArrayList iTXt_compressionMethod = new ArrayList(); ++ public ArrayList iTXt_languageTag = new ArrayList(); ++ public ArrayList iTXt_translatedKeyword = new ArrayList(); ++ public ArrayList iTXt_text = new ArrayList(); + + // pHYs chunk + public boolean pHYs_present; +@@ -599,19 +599,17 @@ + if (iTXt_keyword.size() > 0) { + IIOMetadataNode iTXt_parent = new IIOMetadataNode("iTXt"); + for (int i = 0; i < iTXt_keyword.size(); i++) { +- Integer val; +- + IIOMetadataNode iTXt_node = new IIOMetadataNode("iTXtEntry"); +- iTXt_node.setAttribute("keyword", (String)iTXt_keyword.get(i)); +- val = (Integer)iTXt_compressionFlag.get(i); +- iTXt_node.setAttribute("compressionFlag", val.toString()); +- val = (Integer)iTXt_compressionMethod.get(i); +- iTXt_node.setAttribute("compressionMethod", val.toString()); ++ iTXt_node.setAttribute("keyword", iTXt_keyword.get(i)); ++ iTXt_node.setAttribute("compressionFlag", ++ iTXt_compressionFlag.get(i) ? "1" : "0"); ++ iTXt_node.setAttribute("compressionMethod", ++ iTXt_compressionMethod.get(i).toString()); + iTXt_node.setAttribute("languageTag", +- (String)iTXt_languageTag.get(i)); ++ iTXt_languageTag.get(i)); + iTXt_node.setAttribute("translatedKeyword", +- (String)iTXt_translatedKeyword.get(i)); +- iTXt_node.setAttribute("text", (String)iTXt_text.get(i)); ++ iTXt_translatedKeyword.get(i)); ++ iTXt_node.setAttribute("text", iTXt_text.get(i)); + + iTXt_parent.appendChild(iTXt_node); + } +@@ -1039,11 +1037,11 @@ + + for (int i = 0; i < iTXt_keyword.size(); i++) { + node = new IIOMetadataNode("TextEntry"); +- node.setAttribute("keyword", (String)iTXt_keyword.get(i)); +- node.setAttribute("value", (String)iTXt_text.get(i)); ++ node.setAttribute("keyword", iTXt_keyword.get(i)); ++ node.setAttribute("value", iTXt_text.get(i)); + node.setAttribute("language", +- (String)iTXt_languageTag.get(i)); +- if (((Integer)iTXt_compressionFlag.get(i)).intValue() == 1) { ++ iTXt_languageTag.get(i)); ++ if (iTXt_compressionFlag.get(i)) { + node.setAttribute("compression", "deflate"); + } else { + node.setAttribute("compression", "none"); +@@ -1429,11 +1427,11 @@ + + boolean compressionFlag = + getBooleanAttribute(iTXt_node, "compressionFlag"); +- iTXt_compressionFlag.add(new Boolean(compressionFlag)); ++ iTXt_compressionFlag.add(Boolean.valueOf(compressionFlag)); + + String compressionMethod = + getAttribute(iTXt_node, "compressionMethod"); +- iTXt_compressionMethod.add(compressionMethod); ++ iTXt_compressionMethod.add(Integer.valueOf(compressionMethod)); + + String languageTag = + getAttribute(iTXt_node, "languageTag"); +@@ -1952,13 +1950,10 @@ + tEXt_text.add(value); + } + } else { +- int flag = compression.equals("zip") ? +- 1 : 0; +- + // Use an iTXt node + iTXt_keyword.add(keyword); +- iTXt_compressionFlag.add(new Integer(flag)); +- iTXt_compressionMethod.add(new Integer(0)); ++ iTXt_compressionFlag.add(Boolean.valueOf(compression.equals("zip"))); ++ iTXt_compressionMethod.add(Integer.valueOf(0)); + iTXt_languageTag.add(language); + iTXt_translatedKeyword.add(keyword); // fake it + iTXt_text.add(value); +@@ -1995,12 +1990,12 @@ + gAMA_present = false; + hIST_present = false; + iCCP_present = false; +- iTXt_keyword = new ArrayList(); +- iTXt_compressionFlag = new ArrayList(); +- iTXt_compressionMethod = new ArrayList(); +- iTXt_languageTag = new ArrayList(); +- iTXt_translatedKeyword = new ArrayList(); +- iTXt_text = new ArrayList(); ++ iTXt_keyword = new ArrayList(); ++ iTXt_compressionFlag = new ArrayList(); ++ iTXt_compressionMethod = new ArrayList(); ++ iTXt_languageTag = new ArrayList(); ++ iTXt_translatedKeyword = new ArrayList(); ++ iTXt_text = new ArrayList(); + pHYs_present = false; + sBIT_present = false; + sPLT_present = false; +diff -urN openjdk.orig/jdk/test/javax/imageio/plugins/png/ITXtTest.java openjdk/jdk/test/javax/imageio/plugins/png/ITXtTest.java +--- openjdk.orig/jdk/test/javax/imageio/plugins/png/ITXtTest.java 1969-12-31 19:00:00.000000000 -0500 ++++ openjdk/jdk/test/javax/imageio/plugins/png/ITXtTest.java 2010-12-23 17:12:58.538446639 -0500 +@@ -0,0 +1,236 @@ ++/* ++ * Copyright (c) 2008, Oracle and/or its affiliates. All rights reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA ++ * or visit www.oracle.com if you need additional information or have any ++ * questions. ++ */ ++ ++/** ++ * @test ++ * @bug 6541476 ++ * @summary Test verifies that ImageIO PNG plugin correcly handles the ++ * iTxt chunk (International textual data). ++ * ++ * @run main ITXtTest ++ */ ++ ++ ++import java.awt.Color; ++import java.awt.Graphics2D; ++import java.awt.image.BufferedImage; ++import java.io.File; ++ ++import javax.imageio.ImageIO; ++import javax.imageio.ImageReader; ++import javax.imageio.IIOImage; ++import javax.imageio.ImageTypeSpecifier; ++import javax.imageio.ImageWriter; ++import javax.imageio.metadata.IIOMetadata; ++import javax.imageio.metadata.IIOMetadataNode; ++import javax.imageio.stream.ImageOutputStream; ++import javax.imageio.stream.ImageInputStream; ++ ++import org.w3c.dom.Node; ++ ++public class ITXtTest { ++ static public void main(String args[]) { ++ ITXtTest t_en = new ITXtTest(); ++ t_en.description = "xml - en"; ++ t_en.keyword = "XML:com.adobe.xmp"; ++ t_en.isCompressed = false; ++ t_en.compression = 0; ++ t_en.language = "en"; ++ t_en.trasKeyword = "XML:com.adobe.xmp"; ++ t_en.text = "Something"; ++ ++ doTest(t_en); ++ ++ // check compression case ++ t_en.isCompressed = true; ++ t_en.description = "xml - en - compressed"; ++ ++ doTest(t_en); ++ ++ ITXtTest t_ru = new ITXtTest(); ++ t_ru.description = "xml - ru"; ++ t_ru.keyword = "XML:com.adobe.xmp"; ++ t_ru.isCompressed = false; ++ t_ru.compression = 0; ++ t_ru.language = "ru"; ++ t_ru.trasKeyword = "\u0410\u0410\u0410\u0410\u0410 XML"; ++ t_ru.text = "\u042A\u042F\u042F\u042F\u042F\u042F\u042F"; ++ ++ doTest(t_ru); ++ ++ t_ru.isCompressed = true; ++ t_ru.description = "xml - ru - compressed"; ++ ++ doTest(t_ru); ++ } ++ ++ ++ String description; ++ ++ String keyword; ++ boolean isCompressed; ++ int compression; ++ String language; ++ String trasKeyword; ++ String text; ++ ++ ++ public IIOMetadataNode getNode() { ++ IIOMetadataNode iTXt = new IIOMetadataNode("iTXt"); ++ IIOMetadataNode iTXtEntry = new IIOMetadataNode("iTXtEntry"); ++ iTXtEntry.setAttribute("keyword", keyword); ++ iTXtEntry.setAttribute("compressionFlag", ++ isCompressed ? "true" : "false"); ++ iTXtEntry.setAttribute("compressionMethod", ++ Integer.toString(compression)); ++ iTXtEntry.setAttribute("languageTag", language); ++ iTXtEntry.setAttribute("translatedKeyword", ++ trasKeyword); ++ iTXtEntry.setAttribute("text", text); ++ iTXt.appendChild(iTXtEntry); ++ return iTXt; ++ } ++ ++ public static ITXtTest getFromNode(IIOMetadataNode n) { ++ ITXtTest t = new ITXtTest(); ++ ++ if (!"iTXt".equals(n.getNodeName())) { ++ throw new RuntimeException("Invalid node"); ++ } ++ IIOMetadataNode e = (IIOMetadataNode)n.getFirstChild(); ++ if (!"iTXtEntry".equals(e.getNodeName())) { ++ throw new RuntimeException("Invalid entry node"); ++ } ++ t.keyword = e.getAttribute("keyword"); ++ t.isCompressed = ++ (Integer.valueOf(e.getAttribute("compressionFlag")).intValue() == 1); ++ t.compression = ++ Integer.valueOf(e.getAttribute("compressionMethod")).intValue(); ++ t.language = e.getAttribute("languageTag"); ++ t.trasKeyword = e.getAttribute("translatedKeyword"); ++ t.text = e.getAttribute("text"); ++ ++ return t; From dbhole at icedtea.classpath.org Tue Jan 4 06:57:54 2011 From: dbhole at icedtea.classpath.org (dbhole at icedtea.classpath.org) Date: Tue, 04 Jan 2011 14:57:54 +0000 Subject: /hg/release/icedtea6-1.9: Backport S6687968, S6541476, S6782079 Message-ID: changeset 7919aac747ab in /hg/release/icedtea6-1.9 details: http://icedtea.classpath.org/hg/release/icedtea6-1.9?cmd=changeset;node=7919aac747ab author: Deepak Bhole date: Tue Jan 04 08:55:53 2011 -0500 Backport S6687968, S6541476, S6782079 iTXt chunk handling for png now works correctly. diffstat: 6 files changed, 4818 insertions(+), 1 deletion(-) ChangeLog | 14 Makefile.am | 5 NEWS | 3 patches/openjdk/6541476-png-iTXt-chunk.patch | 549 ++ patches/openjdk/6687968-pngimagereader_mem_leak.patch | 126 patches/openjdk/6782079-png_metadata_oom.patch | 4122 +++++++++++++++++ diffs (truncated from 4859 to 500 lines): diff -r f06befaad21b -r 7919aac747ab ChangeLog --- a/ChangeLog Thu Dec 23 15:52:22 2010 +0100 +++ b/ChangeLog Tue Jan 04 08:55:53 2011 -0500 @@ -1,4 +1,18 @@ 2010-12-23 Jiri Vanek + + Backport S6687968, S6541476, S6782079 + * Makefile.am: Add missing "\" to the patch list, update to include + new patches. + * NEWS: Updated. + * patches/openjdk/6687968-pngimagereader_mem_leak.patch: Backport to allow + S6541476 fix to apply cleanly. + * patches/openjdk/6541476-png-iTXt-chunk.patch: Backport to fix iTXt chunk + handling for png images. Also addresses RH665355. + * patches/openjdk/6782079-png_metadata_oom.patch: Backport to fix + potential OOM error when reading metadata on truncated pngs. + 2010-12-23 Jiri Vanek + * NEWS: Updated with rh.bugzilas. * patches/fonts-rhel.patch:repaired rhel 6 fonts configuration. diff -r f06befaad21b -r 7919aac747ab Makefile.am --- a/Makefile.am Thu Dec 23 15:52:22 2010 +0100 +++ b/Makefile.am Tue Jan 04 08:55:53 2011 -0500 @@ -323,7 +323,10 @@ ICEDTEA_PATCHES = \ patches/openjdk/6438179-systray_check.patch \ patches/openjdk/4356282-opentype.patch \ patches/openjdk/6954424-opentype_javadoc.patch \ - patches/openjdk/6795356-proxylazyvalue-leak.patch + patches/openjdk/6795356-proxylazyvalue-leak.patch \ + patches/openjdk/6687968-pngimagereader_mem_leak.patch \ + patches/openjdk/6541476-png-iTXt-chunk.patch \ + patches/openjdk/6782079-png_metadata_oom.patch if WITH_ALT_HSBUILD ICEDTEA_PATCHES += \ diff -r f06befaad21b -r 7919aac747ab NEWS --- a/NEWS Thu Dec 23 15:52:22 2010 +0100 +++ b/NEWS Tue Jan 04 08:55:53 2011 -0500 @@ -19,6 +19,9 @@ New in release 1.9.4 (2011-XX-XX): - S6976265: No STROKE_CONTROL - S6967434, PR450, RH530642: Round joins/caps of scaled up lines have poor quality. - S6438179, RH569121: XToolkit.isTraySupported() result has nothing to do with the system tray + - S6687968: PNGImageReader leaks native memory through an Inflater + - S6541476, RH665355: PNG imageio plugin incorrectly handles iTXt chunk + - S6782079: PNG: reading metadata may cause OOM on truncated images * Fixes - S7003777, RH647674: JTextPane produces incorrect content after parsing the html text - RH647157,RH582455: Update fontconfig files for rhel 6 diff -r f06befaad21b -r 7919aac747ab patches/openjdk/6541476-png-iTXt-chunk.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/openjdk/6541476-png-iTXt-chunk.patch Tue Jan 04 08:55:53 2011 -0500 @@ -0,0 +1,549 @@ +diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java +--- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java 2010-12-23 17:11:16.193446425 -0500 ++++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java 2010-12-23 17:11:29.399447037 -0500 +@@ -44,7 +44,6 @@ + import java.util.Arrays; + import java.util.Enumeration; + import java.util.Iterator; +-import java.util.List; + import java.util.zip.Inflater; + import java.util.zip.InflaterInputStream; + import javax.imageio.IIOException; +@@ -57,6 +56,7 @@ + import com.sun.imageio.plugins.common.InputStreamAdapter; + import com.sun.imageio.plugins.common.ReaderUtil; + import com.sun.imageio.plugins.common.SubImageInputStream; ++import java.io.ByteArrayOutputStream; + import sun.awt.image.ByteInterleavedRaster; + + class PNGImageDataEnumeration implements Enumeration { +@@ -209,6 +209,15 @@ + resetStreamSettings(); + } + ++ private String readNullTerminatedString(String charset) throws IOException { ++ ByteArrayOutputStream baos = new ByteArrayOutputStream(); ++ int b; ++ while ((b = stream.read()) != 0) { ++ baos.write(b); ++ } ++ return new String(baos.toByteArray(), charset); ++ } ++ + private String readNullTerminatedString() throws IOException { + StringBuilder b = new StringBuilder(); + int c; +@@ -447,26 +456,27 @@ + metadata.iTXt_keyword.add(keyword); + + int compressionFlag = stream.readUnsignedByte(); +- metadata.iTXt_compressionFlag.add(new Integer(compressionFlag)); ++ metadata.iTXt_compressionFlag.add(Boolean.valueOf(compressionFlag == 1)); + + int compressionMethod = stream.readUnsignedByte(); +- metadata.iTXt_compressionMethod.add(new Integer(compressionMethod)); ++ metadata.iTXt_compressionMethod.add(Integer.valueOf(compressionMethod)); + +- String languageTag = readNullTerminatedString(); ++ String languageTag = readNullTerminatedString("UTF8"); + metadata.iTXt_languageTag.add(languageTag); + +- String translatedKeyword = stream.readUTF(); ++ String translatedKeyword = ++ readNullTerminatedString("UTF8"); + metadata.iTXt_translatedKeyword.add(translatedKeyword); +- stream.skipBytes(1); // Null separator + + String text; ++ long pos = stream.getStreamPosition(); ++ byte[] b = new byte[(int)(chunkStart + chunkLength - pos)]; ++ stream.readFully(b); ++ + if (compressionFlag == 1) { // Decompress the text +- long pos = stream.getStreamPosition(); +- byte[] b = new byte[(int)(chunkStart + chunkLength - pos)]; +- stream.readFully(b); +- text = inflate(b); ++ text = new String(inflate(b), "UTF8"); + } else { +- text = stream.readUTF(); ++ text = new String(b, "UTF8"); + } + metadata.iTXt_text.add(text); + } +@@ -615,20 +625,20 @@ + metadata.tRNS_present = true; + } + +- private static String inflate(byte[] b) throws IOException { ++ private static byte[] inflate(byte[] b) throws IOException { + InputStream bais = new ByteArrayInputStream(b); + InputStream iis = new InflaterInputStream(bais); ++ ByteArrayOutputStream baos = new ByteArrayOutputStream(); + +- StringBuilder sb = new StringBuilder(80); + int c; + try { + while ((c = iis.read()) != -1) { +- sb.append((char)c); ++ baos.write(c); + } + } finally { + iis.close(); + } +- return sb.toString(); ++ return baos.toByteArray(); + } + + private void parse_zTXt_chunk(int chunkLength) throws IOException { +@@ -640,7 +650,7 @@ + + byte[] b = new byte[chunkLength - keyword.length() - 2]; + stream.readFully(b); +- metadata.zTXt_text.add(inflate(b)); ++ metadata.zTXt_text.add(new String(inflate(b))); + } + + private void readMetadata() throws IIOException { +diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java +--- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java 2010-12-23 17:11:16.193446425 -0500 ++++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java 2010-12-23 17:11:29.400446993 -0500 +@@ -671,13 +671,13 @@ + } + } + +- private byte[] deflate(String s) throws IOException { ++ private byte[] deflate(byte[] b) throws IOException { + ByteArrayOutputStream baos = new ByteArrayOutputStream(); + DeflaterOutputStream dos = new DeflaterOutputStream(baos); + +- int len = s.length(); ++ int len = b.length; + for (int i = 0; i < len; i++) { +- dos.write((int)s.charAt(i)); ++ dos.write((int)(0xff & b[i])); + } + dos.close(); + +@@ -685,38 +685,37 @@ + } + + private void write_iTXt() throws IOException { +- Iterator keywordIter = metadata.iTXt_keyword.iterator(); +- Iterator flagIter = metadata.iTXt_compressionFlag.iterator(); +- Iterator methodIter = metadata.iTXt_compressionMethod.iterator(); +- Iterator languageIter = metadata.iTXt_languageTag.iterator(); +- Iterator translatedKeywordIter = ++ Iterator keywordIter = metadata.iTXt_keyword.iterator(); ++ Iterator flagIter = metadata.iTXt_compressionFlag.iterator(); ++ Iterator methodIter = metadata.iTXt_compressionMethod.iterator(); ++ Iterator languageIter = metadata.iTXt_languageTag.iterator(); ++ Iterator translatedKeywordIter = + metadata.iTXt_translatedKeyword.iterator(); +- Iterator textIter = metadata.iTXt_text.iterator(); ++ Iterator textIter = metadata.iTXt_text.iterator(); + + while (keywordIter.hasNext()) { + ChunkStream cs = new ChunkStream(PNGImageReader.iTXt_TYPE, stream); +- String keyword = (String)keywordIter.next(); +- cs.writeBytes(keyword); ++ ++ cs.writeBytes(keywordIter.next()); + cs.writeByte(0); + +- int flag = ((Integer)flagIter.next()).intValue(); +- cs.writeByte(flag); +- int method = ((Integer)methodIter.next()).intValue(); +- cs.writeByte(method); ++ Boolean compressed = flagIter.next(); ++ cs.writeByte(compressed ? 1 : 0); + +- String languageTag = (String)languageIter.next(); +- cs.writeBytes(languageTag); ++ cs.writeByte(methodIter.next().intValue()); ++ ++ cs.writeBytes(languageIter.next()); + cs.writeByte(0); + +- String translatedKeyword = (String)translatedKeywordIter.next(); +- cs.writeBytes(translatedKeyword); ++ ++ cs.write(translatedKeywordIter.next().getBytes("UTF8")); + cs.writeByte(0); + +- String text = (String)textIter.next(); +- if (flag == 1) { +- cs.write(deflate(text)); ++ String text = textIter.next(); ++ if (compressed) { ++ cs.write(deflate(text.getBytes("UTF8"))); + } else { +- cs.writeUTF(text); ++ cs.write(text.getBytes("UTF8")); + } + cs.finish(); + } +@@ -737,7 +736,7 @@ + cs.writeByte(compressionMethod); + + String text = (String)textIter.next(); +- cs.write(deflate(text)); ++ cs.write(deflate(text.getBytes())); + cs.finish(); + } + } +diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java +--- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java 2010-06-21 17:15:11.000000000 -0400 ++++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java 2010-12-23 17:11:29.401446953 -0500 +@@ -176,12 +176,12 @@ + public byte[] iCCP_compressedProfile; + + // iTXt chunk +- public ArrayList iTXt_keyword = new ArrayList(); // Strings +- public ArrayList iTXt_compressionFlag = new ArrayList(); // Integers +- public ArrayList iTXt_compressionMethod = new ArrayList(); // Integers +- public ArrayList iTXt_languageTag = new ArrayList(); // Strings +- public ArrayList iTXt_translatedKeyword = new ArrayList(); // Strings +- public ArrayList iTXt_text = new ArrayList(); // Strings ++ public ArrayList iTXt_keyword = new ArrayList(); ++ public ArrayList iTXt_compressionFlag = new ArrayList(); ++ public ArrayList iTXt_compressionMethod = new ArrayList(); ++ public ArrayList iTXt_languageTag = new ArrayList(); ++ public ArrayList iTXt_translatedKeyword = new ArrayList(); ++ public ArrayList iTXt_text = new ArrayList(); + + // pHYs chunk + public boolean pHYs_present; +@@ -599,19 +599,17 @@ + if (iTXt_keyword.size() > 0) { + IIOMetadataNode iTXt_parent = new IIOMetadataNode("iTXt"); + for (int i = 0; i < iTXt_keyword.size(); i++) { +- Integer val; +- + IIOMetadataNode iTXt_node = new IIOMetadataNode("iTXtEntry"); +- iTXt_node.setAttribute("keyword", (String)iTXt_keyword.get(i)); +- val = (Integer)iTXt_compressionFlag.get(i); +- iTXt_node.setAttribute("compressionFlag", val.toString()); +- val = (Integer)iTXt_compressionMethod.get(i); +- iTXt_node.setAttribute("compressionMethod", val.toString()); ++ iTXt_node.setAttribute("keyword", iTXt_keyword.get(i)); ++ iTXt_node.setAttribute("compressionFlag", ++ iTXt_compressionFlag.get(i) ? "1" : "0"); ++ iTXt_node.setAttribute("compressionMethod", ++ iTXt_compressionMethod.get(i).toString()); + iTXt_node.setAttribute("languageTag", +- (String)iTXt_languageTag.get(i)); ++ iTXt_languageTag.get(i)); + iTXt_node.setAttribute("translatedKeyword", +- (String)iTXt_translatedKeyword.get(i)); +- iTXt_node.setAttribute("text", (String)iTXt_text.get(i)); ++ iTXt_translatedKeyword.get(i)); ++ iTXt_node.setAttribute("text", iTXt_text.get(i)); + + iTXt_parent.appendChild(iTXt_node); + } +@@ -1039,11 +1037,11 @@ + + for (int i = 0; i < iTXt_keyword.size(); i++) { + node = new IIOMetadataNode("TextEntry"); +- node.setAttribute("keyword", (String)iTXt_keyword.get(i)); +- node.setAttribute("value", (String)iTXt_text.get(i)); ++ node.setAttribute("keyword", iTXt_keyword.get(i)); ++ node.setAttribute("value", iTXt_text.get(i)); + node.setAttribute("language", +- (String)iTXt_languageTag.get(i)); +- if (((Integer)iTXt_compressionFlag.get(i)).intValue() == 1) { ++ iTXt_languageTag.get(i)); ++ if (iTXt_compressionFlag.get(i)) { + node.setAttribute("compression", "deflate"); + } else { + node.setAttribute("compression", "none"); +@@ -1429,11 +1427,11 @@ + + boolean compressionFlag = + getBooleanAttribute(iTXt_node, "compressionFlag"); +- iTXt_compressionFlag.add(new Boolean(compressionFlag)); ++ iTXt_compressionFlag.add(Boolean.valueOf(compressionFlag)); + + String compressionMethod = + getAttribute(iTXt_node, "compressionMethod"); +- iTXt_compressionMethod.add(compressionMethod); ++ iTXt_compressionMethod.add(Integer.valueOf(compressionMethod)); + + String languageTag = + getAttribute(iTXt_node, "languageTag"); +@@ -1952,13 +1950,10 @@ + tEXt_text.add(value); + } + } else { +- int flag = compression.equals("zip") ? +- 1 : 0; +- + // Use an iTXt node + iTXt_keyword.add(keyword); +- iTXt_compressionFlag.add(new Integer(flag)); +- iTXt_compressionMethod.add(new Integer(0)); ++ iTXt_compressionFlag.add(Boolean.valueOf(compression.equals("zip"))); ++ iTXt_compressionMethod.add(Integer.valueOf(0)); + iTXt_languageTag.add(language); + iTXt_translatedKeyword.add(keyword); // fake it + iTXt_text.add(value); +@@ -1995,12 +1990,12 @@ + gAMA_present = false; + hIST_present = false; + iCCP_present = false; +- iTXt_keyword = new ArrayList(); +- iTXt_compressionFlag = new ArrayList(); +- iTXt_compressionMethod = new ArrayList(); +- iTXt_languageTag = new ArrayList(); +- iTXt_translatedKeyword = new ArrayList(); +- iTXt_text = new ArrayList(); ++ iTXt_keyword = new ArrayList(); ++ iTXt_compressionFlag = new ArrayList(); ++ iTXt_compressionMethod = new ArrayList(); ++ iTXt_languageTag = new ArrayList(); ++ iTXt_translatedKeyword = new ArrayList(); ++ iTXt_text = new ArrayList(); + pHYs_present = false; + sBIT_present = false; + sPLT_present = false; +diff -urN openjdk.orig/jdk/test/javax/imageio/plugins/png/ITXtTest.java openjdk/jdk/test/javax/imageio/plugins/png/ITXtTest.java +--- openjdk.orig/jdk/test/javax/imageio/plugins/png/ITXtTest.java 1969-12-31 19:00:00.000000000 -0500 ++++ openjdk/jdk/test/javax/imageio/plugins/png/ITXtTest.java 2010-12-23 17:12:58.538446639 -0500 +@@ -0,0 +1,236 @@ ++/* ++ * Copyright (c) 2008, Oracle and/or its affiliates. All rights reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA ++ * or visit www.oracle.com if you need additional information or have any ++ * questions. ++ */ ++ ++/** ++ * @test ++ * @bug 6541476 ++ * @summary Test verifies that ImageIO PNG plugin correcly handles the ++ * iTxt chunk (International textual data). ++ * ++ * @run main ITXtTest ++ */ ++ ++ ++import java.awt.Color; ++import java.awt.Graphics2D; ++import java.awt.image.BufferedImage; ++import java.io.File; ++ ++import javax.imageio.ImageIO; ++import javax.imageio.ImageReader; ++import javax.imageio.IIOImage; ++import javax.imageio.ImageTypeSpecifier; ++import javax.imageio.ImageWriter; ++import javax.imageio.metadata.IIOMetadata; ++import javax.imageio.metadata.IIOMetadataNode; ++import javax.imageio.stream.ImageOutputStream; ++import javax.imageio.stream.ImageInputStream; ++ ++import org.w3c.dom.Node; ++ ++public class ITXtTest { ++ static public void main(String args[]) { ++ ITXtTest t_en = new ITXtTest(); ++ t_en.description = "xml - en"; ++ t_en.keyword = "XML:com.adobe.xmp"; ++ t_en.isCompressed = false; ++ t_en.compression = 0; ++ t_en.language = "en"; ++ t_en.trasKeyword = "XML:com.adobe.xmp"; ++ t_en.text = "Something"; ++ ++ doTest(t_en); ++ ++ // check compression case ++ t_en.isCompressed = true; ++ t_en.description = "xml - en - compressed"; ++ ++ doTest(t_en); ++ ++ ITXtTest t_ru = new ITXtTest(); ++ t_ru.description = "xml - ru"; ++ t_ru.keyword = "XML:com.adobe.xmp"; ++ t_ru.isCompressed = false; ++ t_ru.compression = 0; ++ t_ru.language = "ru"; ++ t_ru.trasKeyword = "\u0410\u0410\u0410\u0410\u0410 XML"; ++ t_ru.text = "\u042A\u042F\u042F\u042F\u042F\u042F\u042F"; ++ ++ doTest(t_ru); ++ ++ t_ru.isCompressed = true; ++ t_ru.description = "xml - ru - compressed"; ++ ++ doTest(t_ru); ++ } ++ ++ ++ String description; ++ ++ String keyword; ++ boolean isCompressed; ++ int compression; ++ String language; ++ String trasKeyword; ++ String text; ++ ++ ++ public IIOMetadataNode getNode() { ++ IIOMetadataNode iTXt = new IIOMetadataNode("iTXt"); ++ IIOMetadataNode iTXtEntry = new IIOMetadataNode("iTXtEntry"); ++ iTXtEntry.setAttribute("keyword", keyword); ++ iTXtEntry.setAttribute("compressionFlag", ++ isCompressed ? "true" : "false"); ++ iTXtEntry.setAttribute("compressionMethod", ++ Integer.toString(compression)); ++ iTXtEntry.setAttribute("languageTag", language); ++ iTXtEntry.setAttribute("translatedKeyword", ++ trasKeyword); ++ iTXtEntry.setAttribute("text", text); ++ iTXt.appendChild(iTXtEntry); ++ return iTXt; ++ } ++ ++ public static ITXtTest getFromNode(IIOMetadataNode n) { ++ ITXtTest t = new ITXtTest(); ++ ++ if (!"iTXt".equals(n.getNodeName())) { ++ throw new RuntimeException("Invalid node"); ++ } ++ IIOMetadataNode e = (IIOMetadataNode)n.getFirstChild(); ++ if (!"iTXtEntry".equals(e.getNodeName())) { ++ throw new RuntimeException("Invalid entry node"); ++ } ++ t.keyword = e.getAttribute("keyword"); ++ t.isCompressed = ++ (Integer.valueOf(e.getAttribute("compressionFlag")).intValue() == 1); ++ t.compression = ++ Integer.valueOf(e.getAttribute("compressionMethod")).intValue(); ++ t.language = e.getAttribute("languageTag"); ++ t.trasKeyword = e.getAttribute("translatedKeyword"); ++ t.text = e.getAttribute("text"); ++ ++ return t; From asu at redhat.com Tue Jan 4 07:50:05 2011 From: asu at redhat.com (Andrew Su) Date: Tue, 4 Jan 2011 10:50:05 -0500 (EST) Subject: [rfc][icedtea-web]: Hide unsupported security options in itw-settings In-Reply-To: <1558059459.143773.1294154013075.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Message-ID: <2034839543.144946.1294156205052.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Hello, This is a simple patch for hiding the values. getProperty() in DeploymentConfigurations.java was changed such that null is returned instead of a NullPointerException being thrown in the case that the value is not set. This patch adds a check to see if the value is null and proceed to next item. Comments? --Andrew -------------- next part -------------- A non-text attachment was scrubbed... Name: 20110104_hide_unsupported_security_options_v4.patch Type: text/x-patch Size: 1453 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110104/754c3f76/20110104_hide_unsupported_security_options_v4.patch From dbhole at redhat.com Tue Jan 4 02:31:50 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Tue, 4 Jan 2011 05:31:50 -0500 Subject: [rfc][icedtea-web]: Hide unsupported security options in itw-settings In-Reply-To: <2034839543.144946.1294156205052.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> References: <1558059459.143773.1294154013075.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <2034839543.144946.1294156205052.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Message-ID: <20110104103150.GA29062@redhat.com> * Andrew Su [2011-01-04 10:51]: > Hello, > > This is a simple patch for hiding the values. getProperty() in DeploymentConfigurations.java was changed such that null is returned instead of a NullPointerException being thrown in the case that the value is not set. This patch adds a check to see if the value is null and proceed to next item. > If getProperty returns null, s will be null and Boolean.parseBoolean(s) will throw an exception, so existing code will still work. Is this patch to do it the 'right way' or to fix some sort of error you are encountering? Cheers, Deepak > Comments? > > --Andrew > diff -r c7922247b6d2 netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java > --- a/netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java Thu Dec 23 16:55:17 2010 -0500 > +++ b/netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java Tue Jan 04 10:47:54 2011 -0500 > @@ -114,16 +114,16 @@ > > // Only display the ones with properties that are valid or existent. > for (int i = 0; i < properties.length; i++) { > - try { > - String s = config.getProperty(properties[i]); > - securityGeneralOptions[i].setSelected(Boolean.parseBoolean(s)); > - securityGeneralOptions[i].setActionCommand(properties[i]); > - securityGeneralOptions[i].addActionListener(this); > - c.gridy = i + 1; > - topPanel.add(securityGeneralOptions[i], c); > - } catch (Exception e) { > + String s = config.getProperty(properties[i]); > + if (s == null) { > securityGeneralOptions[i] = null; > + continue; > } > + securityGeneralOptions[i].setSelected(Boolean.parseBoolean(s)); > + securityGeneralOptions[i].setActionCommand(properties[i]); > + securityGeneralOptions[i].addActionListener(this); > + c.gridy = i + 1; > + topPanel.add(securityGeneralOptions[i], c); > } > > Component filler = Box.createRigidArea(new Dimension(1, 1)); From asu at redhat.com Tue Jan 4 08:07:35 2011 From: asu at redhat.com (Andrew Su) Date: Tue, 04 Jan 2011 11:07:35 -0500 Subject: [rfc][icedtea-web]: Hide unsupported security options in itw-settings In-Reply-To: <20110104103150.GA29062@redhat.com> References: <1558059459.143773.1294154013075.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <2034839543.144946.1294156205052.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <20110104103150.GA29062@redhat.com> Message-ID: <4D2345C7.4050801@redhat.com> On 01/04/2011 05:31 AM, Deepak Bhole wrote: > * Andrew Su [2011-01-04 10:51]: >> Hello, >> >> This is a simple patch for hiding the values. getProperty() in DeploymentConfigurations.java was changed such that null is returned instead of a NullPointerException being thrown in the case that the value is not set. This patch adds a check to see if the value is null and proceed to next item. >> > > If getProperty returns null, s will be null and Boolean.parseBoolean(s) > will throw an exception, so existing code will still work. > > Is this patch to do it the 'right way' or to fix some sort of error you > are encountering? Hi Deepak, Boolean.parseBoolean(s) will return false for any string that isn't "true". looking at the Boolean class it says: return ((name != null) && name.equalsIgnoreCase("true")); Thus no exception will be thrown. Regards, Andrew > Cheers, > Deepak > >> Comments? >> >> --Andrew >> diff -r c7922247b6d2 netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java >> --- a/netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java Thu Dec 23 16:55:17 2010 -0500 >> +++ b/netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java Tue Jan 04 10:47:54 2011 -0500 >> @@ -114,16 +114,16 @@ >> >> // Only display the ones with properties that are valid or existent. >> for (int i = 0; i< properties.length; i++) { >> - try { >> - String s = config.getProperty(properties[i]); >> - securityGeneralOptions[i].setSelected(Boolean.parseBoolean(s)); >> - securityGeneralOptions[i].setActionCommand(properties[i]); >> - securityGeneralOptions[i].addActionListener(this); >> - c.gridy = i + 1; >> - topPanel.add(securityGeneralOptions[i], c); >> - } catch (Exception e) { >> + String s = config.getProperty(properties[i]); >> + if (s == null) { >> securityGeneralOptions[i] = null; >> + continue; >> } >> + securityGeneralOptions[i].setSelected(Boolean.parseBoolean(s)); >> + securityGeneralOptions[i].setActionCommand(properties[i]); >> + securityGeneralOptions[i].addActionListener(this); >> + c.gridy = i + 1; >> + topPanel.add(securityGeneralOptions[i], c); >> } >> >> Component filler = Box.createRigidArea(new Dimension(1, 1)); From dbhole at redhat.com Tue Jan 4 02:35:58 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Tue, 4 Jan 2011 05:35:58 -0500 Subject: [rfc][icedtea-web]: Hide unsupported security options in itw-settings In-Reply-To: <20110104103150.GA29062@redhat.com> References: <1558059459.143773.1294154013075.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <2034839543.144946.1294156205052.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <20110104103150.GA29062@redhat.com> Message-ID: <20110104103558.GB29062@redhat.com> * Deepak Bhole [2011-01-04 11:04]: > * Andrew Su [2011-01-04 10:51]: > > Hello, > > > > This is a simple patch for hiding the values. getProperty() in DeploymentConfigurations.java was changed such that null is returned instead of a NullPointerException being thrown in the case that the value is not set. This patch adds a check to see if the value is null and proceed to next item. > > > > > If getProperty returns null, s will be null and Boolean.parseBoolean(s) > will throw an exception, so existing code will still work. > > Is this patch to do it the 'right way' or to fix some sort of error you > are encountering? > Sorry, ignore that. parseBoolean returns false if string is null. Patch looks fine to me in that case. OK for head (and 1.0 if it is affected). Deepak > Cheers, > Deepak > > > Comments? > > > > --Andrew > > > diff -r c7922247b6d2 netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java > > --- a/netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java Thu Dec 23 16:55:17 2010 -0500 > > +++ b/netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java Tue Jan 04 10:47:54 2011 -0500 > > @@ -114,16 +114,16 @@ > > > > // Only display the ones with properties that are valid or existent. > > for (int i = 0; i < properties.length; i++) { > > - try { > > - String s = config.getProperty(properties[i]); > > - securityGeneralOptions[i].setSelected(Boolean.parseBoolean(s)); > > - securityGeneralOptions[i].setActionCommand(properties[i]); > > - securityGeneralOptions[i].addActionListener(this); > > - c.gridy = i + 1; > > - topPanel.add(securityGeneralOptions[i], c); > > - } catch (Exception e) { > > + String s = config.getProperty(properties[i]); > > + if (s == null) { > > securityGeneralOptions[i] = null; > > + continue; > > } > > + securityGeneralOptions[i].setSelected(Boolean.parseBoolean(s)); > > + securityGeneralOptions[i].setActionCommand(properties[i]); > > + securityGeneralOptions[i].addActionListener(this); > > + c.gridy = i + 1; > > + topPanel.add(securityGeneralOptions[i], c); > > } > > > > Component filler = Box.createRigidArea(new Dimension(1, 1)); > From asu at icedtea.classpath.org Tue Jan 4 08:24:22 2011 From: asu at icedtea.classpath.org (asu at icedtea.classpath.org) Date: Tue, 04 Jan 2011 16:24:22 +0000 Subject: /hg/icedtea-web: Hide unsupported options in itw-settings' secur... Message-ID: changeset 5c8851b13c04 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=5c8851b13c04 author: Andrew Su date: Tue Jan 04 11:23:15 2011 -0500 Hide unsupported options in itw-settings' security options. diffstat: 2 files changed, 13 insertions(+), 8 deletions(-) ChangeLog | 5 +++ netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java | 16 +++++----- diffs (40 lines): diff -r c7922247b6d2 -r 5c8851b13c04 ChangeLog --- a/ChangeLog Thu Dec 23 16:55:17 2010 -0500 +++ b/ChangeLog Tue Jan 04 11:23:15 2011 -0500 @@ -1,3 +1,8 @@ 2010-12-23 Andrew Su +2011-01-04 Andrew Su + + * netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java: + (addComponents): Hide unsupported options. + 2010-12-23 Andrew Su * netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java: diff -r c7922247b6d2 -r 5c8851b13c04 netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java --- a/netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java Thu Dec 23 16:55:17 2010 -0500 +++ b/netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java Tue Jan 04 11:23:15 2011 -0500 @@ -114,16 +114,16 @@ public class SecuritySettingsPanel exten // Only display the ones with properties that are valid or existent. for (int i = 0; i < properties.length; i++) { - try { - String s = config.getProperty(properties[i]); - securityGeneralOptions[i].setSelected(Boolean.parseBoolean(s)); - securityGeneralOptions[i].setActionCommand(properties[i]); - securityGeneralOptions[i].addActionListener(this); - c.gridy = i + 1; - topPanel.add(securityGeneralOptions[i], c); - } catch (Exception e) { + String s = config.getProperty(properties[i]); + if (s == null) { securityGeneralOptions[i] = null; + continue; } + securityGeneralOptions[i].setSelected(Boolean.parseBoolean(s)); + securityGeneralOptions[i].setActionCommand(properties[i]); + securityGeneralOptions[i].addActionListener(this); + c.gridy = i + 1; + topPanel.add(securityGeneralOptions[i], c); } Component filler = Box.createRigidArea(new Dimension(1, 1)); From asu at redhat.com Tue Jan 4 08:26:50 2011 From: asu at redhat.com (Andrew Su) Date: Tue, 04 Jan 2011 11:26:50 -0500 Subject: [rfc][icedtea-web]: Hide unsupported security options in itw-settings In-Reply-To: <20110104103558.GB29062@redhat.com> References: <1558059459.143773.1294154013075.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <2034839543.144946.1294156205052.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <20110104103150.GA29062@redhat.com> <20110104103558.GB29062@redhat.com> Message-ID: <4D234A4A.5030906@redhat.com> On 01/04/2011 05:35 AM, Deepak Bhole wrote: > * Deepak Bhole [2011-01-04 11:04]: >> * Andrew Su [2011-01-04 10:51]: >>> Hello, >>> >>> This is a simple patch for hiding the values. getProperty() in DeploymentConfigurations.java was changed such that null is returned instead of a NullPointerException being thrown in the case that the value is not set. This patch adds a check to see if the value is null and proceed to next item. >>> >> >> If getProperty returns null, s will be null and Boolean.parseBoolean(s) >> will throw an exception, so existing code will still work. >> >> Is this patch to do it the 'right way' or to fix some sort of error you >> are encountering? >> > Sorry, ignore that. parseBoolean returns false if string is null. > > Patch looks fine to me in that case. OK for head (and 1.0 if it is > affected). Thanks for looking it over, pushed to HEAD. 1.0 doesn't have the change to DeploymentConfiguration.java yet. Cheers, Andrew >>> diff -r c7922247b6d2 netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java >>> --- a/netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java Thu Dec 23 16:55:17 2010 -0500 >>> +++ b/netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java Tue Jan 04 10:47:54 2011 -0500 >>> @@ -114,16 +114,16 @@ >>> >>> // Only display the ones with properties that are valid or existent. >>> for (int i = 0; i< properties.length; i++) { >>> - try { >>> - String s = config.getProperty(properties[i]); >>> - securityGeneralOptions[i].setSelected(Boolean.parseBoolean(s)); >>> - securityGeneralOptions[i].setActionCommand(properties[i]); >>> - securityGeneralOptions[i].addActionListener(this); >>> - c.gridy = i + 1; >>> - topPanel.add(securityGeneralOptions[i], c); >>> - } catch (Exception e) { >>> + String s = config.getProperty(properties[i]); >>> + if (s == null) { >>> securityGeneralOptions[i] = null; >>> + continue; >>> } >>> + securityGeneralOptions[i].setSelected(Boolean.parseBoolean(s)); >>> + securityGeneralOptions[i].setActionCommand(properties[i]); >>> + securityGeneralOptions[i].addActionListener(this); >>> + c.gridy = i + 1; >>> + topPanel.add(securityGeneralOptions[i], c); >>> } >>> >>> Component filler = Box.createRigidArea(new Dimension(1, 1)); From omajid at redhat.com Tue Jan 4 09:54:44 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 04 Jan 2011 12:54:44 -0500 Subject: [icedtea-web] RFC: allow alternate means of finding browsers In-Reply-To: <20101222232940.GK17229@rivendell.middle-earth.co.uk> References: <4D12605D.3080501@redhat.com> <20101222204258.GE17229@rivendell.middle-earth.co.uk> <4D127864.3010302@redhat.com> <20101222232940.GK17229@rivendell.middle-earth.co.uk> Message-ID: <4D235EE4.4040608@redhat.com> On 12/22/2010 06:29 PM, Dr Andrew John Hughes wrote: > On 17:15 Wed 22 Dec , Omair Majid wrote: >> On 12/22/2010 03:42 PM, Dr Andrew John Hughes wrote: >>> On 15:32 Wed 22 Dec , Omair Majid wrote: >>>> Hi, >>>> >>>> The attached patch allows netx to use a browser based on the BROWSER env >>>> variable or using xdg-open, as opposed to relying on user-supplied >>>> browser command. >>>> >>>> A new configuration option deployment.browser.source is used to >>>> determine where to find the browser. If it is set to "PATH" (the >>>> default), the configuration option deployment.browser.path is used. If >>>> deployment.browser.source is set to "ENV" then the $BROWSER environment >>>> variable is used. If deployment.browser.source is set to "XDG" then the >>>> program xdg-open is used to launch the browser. >>>> >>> >>> I would make XDG the default so it works like other applications on the system >>> (which I presume use either this or $BROWSER) if deployment.browser.path is not set. >>> Then NetX automatically picks up the system browser rather than prompting. >>> >> >> Ah, great idea! Should I keep support for using $BROWSER or remove that >> too in favour of xdg-open? >> > > Please keep it. I don't see how it does any harm. > > You might also want to consider the scenario that xdg-open is not available > and fall back to $BROWSER then prompting if that is also empty. > Done. >>> Shouldn't we do some basic sanity checks on the contents of getEnv? (And path too >>> if we don't already) >>> >> >> We should, and we dont do it for path either. Actually netx refers to >> path as 'command' and that's how it deals with it too - it simply execs >> "command url" to open the url. This allows a user to use a program name >> (like firefox) instead of the entire path to it. So checking for >> file/path existence makes this common case fail: >> BROWSER=chromium-browser javaws foo.jnlp >> (and similar for path). I dont see any simple way to check if the >> command is valid - short of actually running the command. Do you have >> any other sanity checks in mind? > > On *ix systems, you could run 'which command' and then execute the result of that > instead. How well that works depends if we want to allow options to be specified > to the binary. > I am using the 'type' builtin to check if command is valid rather than 'which' since the behaviour of 'type' is a POSIX standard, while 'which' may or may not return an error code on failure. > I would at least check for things like \r and \n which would suggest something fishy to me. > It doesn't immediately seem a huge issue as the netx binary is not privileged. > Also done. Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: configure-browser-03.patch Type: text/x-patch Size: 4325 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110104/d400b3b9/configure-browser-03.patch From omajid at icedtea.classpath.org Tue Jan 4 10:09:15 2011 From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org) Date: Tue, 04 Jan 2011 18:09:15 +0000 Subject: /hg/icedtea-web: only print debug output when not null Message-ID: changeset 8e1b7bb5f2fc in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=8e1b7bb5f2fc author: Omair Majid date: Tue Jan 04 13:08:25 2011 -0500 only print debug output when not null 2011-01-04 Omair Majid * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java (installShutdownHooks): Only print when not null. diffstat: 2 files changed, 8 insertions(+), 4 deletions(-) ChangeLog | 5 +++++ netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java | 7 +++---- diffs (35 lines): diff -r 5c8851b13c04 -r 8e1b7bb5f2fc ChangeLog --- a/ChangeLog Tue Jan 04 11:23:15 2011 -0500 +++ b/ChangeLog Tue Jan 04 13:08:25 2011 -0500 @@ -1,3 +1,8 @@ 2011-01-04 Andrew Su +2011-01-04 Omair Majid + + * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java + (installShutdownHooks): Only print when not null. + 2011-01-04 Andrew Su * netx/net/sourceforge/jnlp/controlpanel/SecuritySettingsPanel.java: diff -r 5c8851b13c04 -r 8e1b7bb5f2fc netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java --- a/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Tue Jan 04 11:23:15 2011 -0500 +++ b/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Tue Jan 04 13:08:25 2011 -0500 @@ -182,16 +182,15 @@ public class JNLPClassLoader extends URL Runtime.getRuntime().addShutdownHook(new Thread() { @Override public void run() { - if (JNLPRuntime.isDebug()) { - System.out.println("Cleaning up native directory" + nativeDir.getAbsolutePath()); - } - /* * Delete only the native dir created by this classloader (if * there is one). Other classloaders (parent, peers) will all * cleanup things they created */ if (nativeDir != null) { + if (JNLPRuntime.isDebug()) { + System.out.println("Cleaning up native directory" + nativeDir.getAbsolutePath()); + } try { FileUtils.recursiveDelete(nativeDir, new File(System.getProperty("java.io.tmpdir"))); From omajid at redhat.com Tue Jan 4 10:13:43 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 04 Jan 2011 13:13:43 -0500 Subject: [icedtea-web] RFC: fix exception in debug output from JNLPClassLoader In-Reply-To: <20101225000122.GH16863@rivendell.middle-earth.co.uk> References: <4D1508BC.5030200@redhat.com> <20101225000122.GH16863@rivendell.middle-earth.co.uk> Message-ID: <4D236357.40806@redhat.com> On 12/24/2010 07:01 PM, Dr Andrew John Hughes wrote: > On 15:55 Fri 24 Dec , Omair Majid wrote: >> The attached patch fixes an exception that happens when printing debug >> output. >> >> The exception only happens when javaws is run in verbose mode and the >> JVM is shutting down - so it does not affect the behaviour of the JNLP >> application. >> >> Any objections? >> >> ChangeLog >> 2010-12-24 Omair Majid >> >> * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java >> (installShutdownHooks): Only print when not null. >> >> Cheers, >> Omair > > Good spot. Approved. > > If this is present in 1.0 too, it should probably be backported. Fix pushed to HEAD. Deepak, may I add this to 1.0 too? Cheers, Omair From omajid at redhat.com Tue Jan 4 10:35:28 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 04 Jan 2011 13:35:28 -0500 Subject: [icedtea-web] RFC: small cleanup in ControlPanel In-Reply-To: <4D0BDAD8.6070702@redhat.com> References: <4D0BDAD8.6070702@redhat.com> Message-ID: <4D236870.9080707@redhat.com> On 12/17/2010 04:49 PM, Omair Majid wrote: > Hi, > > The attached patch cleans up some code in the ControlPanel, and in the > process removes dependencies on JNLPRuntime. > > ChangeLog: > 2010-12-17 Omair Majid > > * netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java: Remove > JNLPRuntime import. Remove configBrowserCommand. > (SettingsPanel.toString): Add Override annotation. > (createMainSettingsPanel): Remove call to loadConfiguration. > (loadConfiguration): Remove method. Setting the browser command > should be handled by the appropriate panel. > (main): Remove call to JNLPRuntime.initialize and just create a new > DeploymentConfiguration object. Clarify TODO comment. > Any comments? Ok to commit? Cheers, Omair From omajid at redhat.com Tue Jan 4 10:45:08 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 04 Jan 2011 13:45:08 -0500 Subject: [icedtea-web] RFC: custom policy for trusted applications In-Reply-To: <4D1132FA.40306@redhat.com> References: <4D1132FA.40306@redhat.com> Message-ID: <4D236AB4.8070700@redhat.com> On 12/21/2010 06:06 PM, Omair Majid wrote: > Hi, > > The attached patch adds support for using a custom policy file to grant > permissions to trusted applications. > > ChangeLog: > 2010-12-21 Omair Majid > > * netx/net/sourceforge/jnlp/SecurityDesc.java: Add > customTrustedPolicy. > (SecurityDesc): Initialize customTrustedPolicy. > (getCustomTrustedPolicy): New method. Get custom policy file from > configuration and use it to initialize a custom configuration. > (getPermissions): If trusted application and customTrustedPolicy is > not null, delegate to otherwise return AllPermissions. > * netx/net/sourceforge/jnlp/config/Defaults.java > (getDefaults): Use constant for property. > * netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java: > Add new constant KEY_SECURITY_TRUSTED_POLICY. > * netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java > (installEnvironment): Pass cs as a parameter to > SecurityDesc.getPermissions. > * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java > (getPermissions): Likewise. > > Any comments or concerns? > > Cheers, > Omair Ok to commit? Cheers, Omair From omajid at redhat.com Tue Jan 4 10:48:15 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 04 Jan 2011 13:48:15 -0500 Subject: [icedtea-web] RFC: use deployment-specific system- and user-level policy files to grant permissions In-Reply-To: <4D0BEC5A.2070701@redhat.com> References: <4D0BEC5A.2070701@redhat.com> Message-ID: <4D236B6F.4090008@redhat.com> On 12/17/2010 06:03 PM, Omair Majid wrote: > Hi, > > The following patch makes these two properties from > deployment.properties have effect: > deployment.user.security.policy > deployment.system.security.policy > > The patch makes the JNLPPolicy class look for permissions for the given > code source in the files defined by these two properties as well. > > Thoughts? > > ChangeLog: > 2010-12-17 Omair Majid > > * netx/net/sourceforge/jnlp/runtime/JNLPPolicy.java: Add > systemJnlpPolicy and userJnlpPolicy. > (JNLPPolicy): Initialize the new policies. > (getPermissions): Consult the extra policies as well to determine the > resulting permissions to be granted. > (getPolicyFromConfig): New method. Create a new Policy instance to > delegate to for system- and user-level policies. > > Cheers, > Omair Ok to commit? Cheers, Omair From dbhole at redhat.com Tue Jan 4 11:11:18 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Tue, 4 Jan 2011 14:11:18 -0500 Subject: [icedtea-web] RFC: custom policy for trusted applications In-Reply-To: <4D236AB4.8070700@redhat.com> References: <4D1132FA.40306@redhat.com> <4D236AB4.8070700@redhat.com> Message-ID: <20110104191118.GA31828@redhat.com> * Omair Majid [2011-01-04 13:46]: > On 12/21/2010 06:06 PM, Omair Majid wrote: > >Hi, > > > >The attached patch adds support for using a custom policy file to grant > >permissions to trusted applications. > > > >ChangeLog: > >2010-12-21 Omair Majid > > > >* netx/net/sourceforge/jnlp/SecurityDesc.java: Add > >customTrustedPolicy. > >(SecurityDesc): Initialize customTrustedPolicy. > >(getCustomTrustedPolicy): New method. Get custom policy file from > >configuration and use it to initialize a custom configuration. > >(getPermissions): If trusted application and customTrustedPolicy is > >not null, delegate to otherwise return AllPermissions. > >* netx/net/sourceforge/jnlp/config/Defaults.java > >(getDefaults): Use constant for property. > >* netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java: > >Add new constant KEY_SECURITY_TRUSTED_POLICY. > >* netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java > >(installEnvironment): Pass cs as a parameter to > >SecurityDesc.getPermissions. > >* netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java > >(getPermissions): Likewise. > > > >Any comments or concerns? > > > >Cheers, > >Omair > > Ok to commit? > Looks fine to me. OK for HEAD. Deepak > Cheers, > Omair From dbhole at redhat.com Tue Jan 4 11:13:58 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Tue, 4 Jan 2011 14:13:58 -0500 Subject: [icedtea-web] RFC: use deployment-specific system- and user-level policy files to grant permissions In-Reply-To: <4D0BEC5A.2070701@redhat.com> References: <4D0BEC5A.2070701@redhat.com> Message-ID: <20110104191358.GB31828@redhat.com> * Omair Majid [2010-12-17 18:05]: > Hi, > > The following patch makes these two properties from > deployment.properties have effect: > deployment.user.security.policy > deployment.system.security.policy > > The patch makes the JNLPPolicy class look for permissions for the > given code source in the files defined by these two properties as > well. > > Thoughts? > Looks good! OK for HEAD. Cheers, Deepak > ChangeLog: > 2010-12-17 Omair Majid > > * netx/net/sourceforge/jnlp/runtime/JNLPPolicy.java: Add > systemJnlpPolicy and userJnlpPolicy. > (JNLPPolicy): Initialize the new policies. > (getPermissions): Consult the extra policies as well to determine the > resulting permissions to be granted. > (getPolicyFromConfig): New method. Create a new Policy instance to > delegate to for system- and user-level policies. > > Cheers, > Omair > diff -r adef5d4159ee netx/net/sourceforge/jnlp/runtime/JNLPPolicy.java > --- a/netx/net/sourceforge/jnlp/runtime/JNLPPolicy.java Mon Dec 13 17:28:01 2010 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/JNLPPolicy.java Wed Dec 15 14:44:27 2010 -0500 > @@ -16,9 +16,13 @@ > > package net.sourceforge.jnlp.runtime; > > +import java.net.URI; > +import java.net.URISyntaxException; > import java.security.*; > import java.util.Enumeration; > > +import net.sourceforge.jnlp.config.DeploymentConfiguration; > + > /** > * Policy for JNLP environment. This class delegates to the > * system policy but always grants permissions to the JNLP code > @@ -40,10 +44,19 @@ > /** the previous policy */ > private static Policy systemPolicy; > > + /** the system level policy for jnlps */ > + private Policy systemJnlpPolicy = null; > + > + /** the user-level policy for jnlps */ > + private Policy userJnlpPolicy = null; > + > protected JNLPPolicy() { > shellSource = JNLPPolicy.class.getProtectionDomain().getCodeSource(); > systemSource = Policy.class.getProtectionDomain().getCodeSource(); > systemPolicy = Policy.getPolicy(); > + > + systemJnlpPolicy = getPolicyFromConfig(DeploymentConfiguration.KEY_SYSTEM_SECURITY_POLICY); > + userJnlpPolicy = getPolicyFromConfig(DeploymentConfiguration.KEY_USER_SECURITY_POLICY); > } > > /** > @@ -62,11 +75,27 @@ > > PermissionCollection clPermissions = cl.getPermissions(source); > > + Enumeration e; > + CodeSource appletCS = new CodeSource(JNLPRuntime.getApplication().getJNLPFile().getSourceLocation(), (java.security.cert.Certificate[]) null); > + > // systempolicy permissions need to be accounted for as well > - CodeSource appletCS = new CodeSource(JNLPRuntime.getApplication().getJNLPFile().getSourceLocation(), (java.security.cert.Certificate[]) null); > - Enumeration e = systemPolicy.getPermissions(appletCS).elements(); > + e = systemPolicy.getPermissions(appletCS).elements(); > while (e.hasMoreElements()) > - clPermissions.add((Permission) e.nextElement()); > + clPermissions.add(e.nextElement()); > + > + // and so do permissions from the jnlp-specific system policy > + if (systemJnlpPolicy != null) { > + e = systemJnlpPolicy.getPermissions(appletCS).elements(); > + while (e.hasMoreElements()) > + clPermissions.add(e.nextElement()); > + } > + > + // and permissiosn from jnlp-specific user policy too > + if (userJnlpPolicy != null) { > + e = userJnlpPolicy.getPermissions(appletCS).elements(); > + while (e.hasMoreElements()) > + clPermissions.add(e.nextElement()); > + } > > return clPermissions; > } > @@ -93,6 +124,31 @@ > return result; > } > > + /** > + * Constructs a delegate policy based on a config setting > + * @param key a KEY_* in DeploymentConfiguration > + * @return a policy based on the configuration set by the user > + */ > + private Policy getPolicyFromConfig(String key) { > + Policy policy = null; > + String policyLocation = null; > + DeploymentConfiguration config = JNLPRuntime.getConfiguration(); > + policyLocation = config.getProperty(key); > + if (policyLocation != null) { > + try { > + URI policyUri = new URI(policyLocation); > + policy = getInstance("JavaPolicy", new URIParameter(policyUri)); > + } catch (IllegalArgumentException e) { > + e.printStackTrace(); > + } catch (NoSuchAlgorithmException e) { > + e.printStackTrace(); > + } catch (URISyntaxException e) { > + e.printStackTrace(); > + } > + } > + return policy; > + } > + > public boolean implies(ProtectionDomain domain, Permission permission) { > //Include the permissions that may be added during runtime. > PermissionCollection pc = getPermissions(domain.getCodeSource()); From dbhole at redhat.com Tue Jan 4 11:16:54 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Tue, 4 Jan 2011 14:16:54 -0500 Subject: [icedtea-web] RFC: small cleanup in ControlPanel In-Reply-To: <4D236870.9080707@redhat.com> References: <4D0BDAD8.6070702@redhat.com> <4D236870.9080707@redhat.com> Message-ID: <20110104191653.GC31828@redhat.com> * Omair Majid [2011-01-04 13:36]: > On 12/17/2010 04:49 PM, Omair Majid wrote: > >Hi, > > > >The attached patch cleans up some code in the ControlPanel, and in the > >process removes dependencies on JNLPRuntime. > > > >ChangeLog: > >2010-12-17 Omair Majid > > > >* netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java: Remove > >JNLPRuntime import. Remove configBrowserCommand. > >(SettingsPanel.toString): Add Override annotation. > >(createMainSettingsPanel): Remove call to loadConfiguration. > >(loadConfiguration): Remove method. Setting the browser command > >should be handled by the appropriate panel. > >(main): Remove call to JNLPRuntime.initialize and just create a new > >DeploymentConfiguration object. Clarify TODO comment. > > > > Any comments? Ok to commit? > Looks good to me. OK for head. Cheers, Deepak > Cheers, > Omair From dbhole at redhat.com Tue Jan 4 11:32:05 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Tue, 4 Jan 2011 14:32:05 -0500 Subject: [icedtea-web] RFC: fix exception in debug output from JNLPClassLoader In-Reply-To: <4D236357.40806@redhat.com> References: <4D1508BC.5030200@redhat.com> <20101225000122.GH16863@rivendell.middle-earth.co.uk> <4D236357.40806@redhat.com> Message-ID: <20110104193204.GE31828@redhat.com> * Omair Majid [2011-01-04 13:13]: > On 12/24/2010 07:01 PM, Dr Andrew John Hughes wrote: > >On 15:55 Fri 24 Dec , Omair Majid wrote: > >>The attached patch fixes an exception that happens when printing debug > >>output. > >> > >>The exception only happens when javaws is run in verbose mode and the > >>JVM is shutting down - so it does not affect the behaviour of the JNLP > >>application. > >> > >>Any objections? > >> > >>ChangeLog > >>2010-12-24 Omair Majid > >> > >> * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java > >> (installShutdownHooks): Only print when not null. > >> > >>Cheers, > >>Omair > > > >Good spot. Approved. > > > >If this is present in 1.0 too, it should probably be backported. > > Fix pushed to HEAD. > > Deepak, may I add this to 1.0 too? > Yes, please do. Thanks, Deepak > Cheers, > Omair From omajid at icedtea.classpath.org Tue Jan 4 11:45:25 2011 From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org) Date: Tue, 04 Jan 2011 19:45:25 +0000 Subject: /hg/icedtea-web: remove control panel's dependency on JNLPRuntim... Message-ID: changeset c938ea901f2f in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=c938ea901f2f author: Omair Majid date: Tue Jan 04 14:45:10 2011 -0500 remove control panel's dependency on JNLPRuntime and other minor cleanup 2011-01-04 Omair Majid * netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java: Remove JNLPRuntime import. Remove configBrowserCommand. (createMainSettingsPanel): Remove call to loadConfiguration. (loadConfiguration): Remove method. Setting the browser command should be handled by the appropriate panel. (main): Remove call to JNLPRuntime.initialize and just create a new DeploymentConfiguration object. Clarify TODO comment. diffstat: 2 files changed, 19 insertions(+), 22 deletions(-) ChangeLog | 10 ++++ netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java | 31 ++++---------- diffs (96 lines): diff -r 8e1b7bb5f2fc -r c938ea901f2f ChangeLog --- a/ChangeLog Tue Jan 04 13:08:25 2011 -0500 +++ b/ChangeLog Tue Jan 04 14:45:10 2011 -0500 @@ -1,3 +1,13 @@ 2011-01-04 Omair Majid + + * netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java: Remove + JNLPRuntime import. Remove configBrowserCommand. + (createMainSettingsPanel): Remove call to loadConfiguration. + (loadConfiguration): Remove method. Setting the browser command + should be handled by the appropriate panel. + (main): Remove call to JNLPRuntime.initialize and just create a new + DeploymentConfiguration object. Clarify TODO comment. + 2011-01-04 Omair Majid * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java diff -r 8e1b7bb5f2fc -r c938ea901f2f netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java --- a/netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java Tue Jan 04 13:08:25 2011 -0500 +++ b/netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java Tue Jan 04 14:45:10 2011 -0500 @@ -1,5 +1,5 @@ /* ControlPanel.java -- Display the control panel for modifying deployment settings. -Copyright (C) 2010 Red Hat +Copyright (C) 2011 Red Hat This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -52,7 +52,6 @@ import javax.swing.event.ListSelectionLi import javax.swing.event.ListSelectionListener; import net.sourceforge.jnlp.config.DeploymentConfiguration; -import net.sourceforge.jnlp.runtime.JNLPRuntime; import net.sourceforge.jnlp.runtime.Translator; import net.sourceforge.jnlp.security.viewer.CertificatePane; @@ -91,11 +90,6 @@ public class ControlPanel extends JFrame } private DeploymentConfiguration config = null; - - /* - * actual configuration options - */ - private String configBrowserCommand = null; /** * Creates a new instance of the ControlPanel. @@ -223,8 +217,6 @@ public class ControlPanel extends JFrame */ private JPanel createMainSettingsPanel() { - loadConfiguration(); - SettingsPanel[] panels = new SettingsPanel[] { new SettingsPanel(Translator.R("CPTabAbout"), createAboutPanel()), new SettingsPanel(Translator.R("CPTabCache"), createCacheSettingsPanel()), new SettingsPanel(Translator.R("CPTabCertificate"), createCertificatesSettingsPanel()), @@ -338,16 +330,6 @@ public class ControlPanel extends JFrame } /** - * Get the location of the browser. - */ - private void loadConfiguration() { - configBrowserCommand = config.getProperty("deployment.browser.path"); - if (configBrowserCommand == null) { - configBrowserCommand = ""; - } - } - - /** * Save the configuration changes. */ private void saveConfiguration() { @@ -359,14 +341,19 @@ public class ControlPanel extends JFrame } public static void main(String[] args) throws Exception { - JNLPRuntime.initialize(true); - final DeploymentConfiguration config = JNLPRuntime.getConfiguration(); + final DeploymentConfiguration config = new DeploymentConfiguration(); try { config.load(); } catch (ConfigurationException e) { - // TODO Auto-generated catch block + // FIXME inform user about this and exit properly + // the only known condition under which this can happen is when a + // required system configuration file is not found + + // if configuration is not loaded, we will get NullPointerExceptions + // everywhere e.printStackTrace(); } + SwingUtilities.invokeLater(new Runnable() { @Override public void run() { From omajid at redhat.com Tue Jan 4 11:46:00 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 04 Jan 2011 14:46:00 -0500 Subject: [icedtea-web] RFC: small cleanup in ControlPanel In-Reply-To: <20110104191653.GC31828@redhat.com> References: <4D0BDAD8.6070702@redhat.com> <4D236870.9080707@redhat.com> <20110104191653.GC31828@redhat.com> Message-ID: <4D2378F8.2090006@redhat.com> On 01/04/2011 02:16 PM, Deepak Bhole wrote: > * Omair Majid [2011-01-04 13:36]: >> On 12/17/2010 04:49 PM, Omair Majid wrote: >>> Hi, >>> >>> The attached patch cleans up some code in the ControlPanel, and in the >>> process removes dependencies on JNLPRuntime. >>> >>> ChangeLog: >>> 2010-12-17 Omair Majid >>> >>> * netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java: Remove >>> JNLPRuntime import. Remove configBrowserCommand. >>> (SettingsPanel.toString): Add Override annotation. >>> (createMainSettingsPanel): Remove call to loadConfiguration. >>> (loadConfiguration): Remove method. Setting the browser command >>> should be handled by the appropriate panel. >>> (main): Remove call to JNLPRuntime.initialize and just create a new >>> DeploymentConfiguration object. Clarify TODO comment. >>> >> >> Any comments? Ok to commit? >> > > Looks good to me. OK for head. > Thanks. Pushed to head. Cheers, Omair From omajid at icedtea.classpath.org Tue Jan 4 12:12:51 2011 From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org) Date: Tue, 04 Jan 2011 20:12:51 +0000 Subject: /hg/icedtea-web: allow custom permissions instead of all permiss... Message-ID: changeset e65820401742 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=e65820401742 author: Omair Majid date: Tue Jan 04 15:12:40 2011 -0500 allow custom permissions instead of all permissions for trusted code 2011-01-04 Omair Majid * netx/net/sourceforge/jnlp/SecurityDesc.java: Add customTrustedPolicy. (SecurityDesc): Initialize customTrustedPolicy. (getCustomTrustedPolicy): New method. Get custom policy file from configuration and use it to initialize a custom configuration. (getPermissions): If trusted application and customTrustedPolicy is not null, delegate to otherwise return AllPermissions. * netx/net/sourceforge/jnlp/config/Defaults.java (getDefaults): Use constant for property. * netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java: Add new constant KEY_SECURITY_TRUSTED_POLICY. * netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java (installEnvironment): Pass cs as a parameter to SecurityDesc.getPermissions. * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java (getPermissions): Likewise. diffstat: 6 files changed, 62 insertions(+), 6 deletions(-) ChangeLog | 19 ++++ netx/net/sourceforge/jnlp/SecurityDesc.java | 41 +++++++++- netx/net/sourceforge/jnlp/config/Defaults.java | 2 netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java | 2 netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java | 2 netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java | 2 diffs (145 lines): diff -r c938ea901f2f -r e65820401742 ChangeLog --- a/ChangeLog Tue Jan 04 14:45:10 2011 -0500 +++ b/ChangeLog Tue Jan 04 15:12:40 2011 -0500 @@ -1,3 +1,22 @@ 2011-01-04 Omair Majid + + * netx/net/sourceforge/jnlp/SecurityDesc.java: Add + customTrustedPolicy. + (SecurityDesc): Initialize customTrustedPolicy. + (getCustomTrustedPolicy): New method. Get custom policy file from + configuration and use it to initialize a custom configuration. + (getPermissions): If trusted application and customTrustedPolicy is + not null, delegate to otherwise return AllPermissions. + * netx/net/sourceforge/jnlp/config/Defaults.java + (getDefaults): Use constant for property. + * netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java: + Add new constant KEY_SECURITY_TRUSTED_POLICY. + * netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java + (installEnvironment): Pass cs as a parameter to + SecurityDesc.getPermissions. + * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java + (getPermissions): Likewise. + 2011-01-04 Omair Majid * netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java: Remove diff -r c938ea901f2f -r e65820401742 netx/net/sourceforge/jnlp/SecurityDesc.java --- a/netx/net/sourceforge/jnlp/SecurityDesc.java Tue Jan 04 14:45:10 2011 -0500 +++ b/netx/net/sourceforge/jnlp/SecurityDesc.java Tue Jan 04 15:12:40 2011 -0500 @@ -57,6 +57,8 @@ public class SecurityDesc { /** the JNLP file */ private JNLPFile file; + + private final Policy customTrustedPolicy; // We go by the rules here: // http://java.sun.com/docs/books/tutorial/deployment/doingMoreWithRIA/properties.html @@ -151,6 +153,33 @@ public class SecurityDesc { String key = DeploymentConfiguration.KEY_SECURITY_ALLOW_HIDE_WINDOW_WARNING; grantAwtPermissions = Boolean.valueOf(JNLPRuntime.getConfiguration().getProperty(key)); + + customTrustedPolicy = getCustomTrustedPolicy(); + } + + /** + * Returns a Policy object that represents a custom policy to use instead + * of granting {@link AllPermission} to a {@link CodeSource} + * + * @return a {@link Policy} object to delegate to. May be null, which + * indicates that no policy exists and AllPermissions should be granted + * instead. + */ + private Policy getCustomTrustedPolicy() { + String key = DeploymentConfiguration.KEY_SECURITY_TRUSTED_POLICY; + String policyLocation = JNLPRuntime.getConfiguration().getProperty(key); + + Policy policy = null; + if (policyLocation != null) { + try { + URI policyUri = new URI("file://" + policyLocation); + policy = Policy.getInstance("JavaPolicy", new URIParameter(policyUri)); + } catch (Exception e) { + e.printStackTrace(); + } + } + // return the appropriate policy, or null + return policy; } /** @@ -164,15 +193,21 @@ public class SecurityDesc { /** * Returns a PermissionCollection containing the basic * permissions granted depending on the security type. + * + * @param cs the CodeSource to get permissions for */ - public PermissionCollection getPermissions() { + public PermissionCollection getPermissions(CodeSource cs) { PermissionCollection permissions = getSandBoxPermissions(); // discard sandbox, give all if (type == ALL_PERMISSIONS) { permissions = new Permissions(); - permissions.add(new AllPermission()); - return permissions; + if (customTrustedPolicy == null) { + permissions.add(new AllPermission()); + return permissions; + } else { + return customTrustedPolicy.getPermissions(cs); + } } // add j2ee to sandbox if needed diff -r c938ea901f2f -r e65820401742 netx/net/sourceforge/jnlp/config/Defaults.java --- a/netx/net/sourceforge/jnlp/config/Defaults.java Tue Jan 04 14:45:10 2011 -0500 +++ b/netx/net/sourceforge/jnlp/config/Defaults.java Tue Jan 04 15:12:40 2011 -0500 @@ -209,7 +209,7 @@ public class Defaults { String.valueOf(true) }, { - "deployment.security.trusted.policy", + DeploymentConfiguration.KEY_SECURITY_TRUSTED_POLICY, BasicValueValidators.getFilePathValidator(), null }, diff -r c938ea901f2f -r e65820401742 netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java --- a/netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java Tue Jan 04 14:45:10 2011 -0500 +++ b/netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java Tue Jan 04 15:12:40 2011 -0500 @@ -103,6 +103,8 @@ public final class DeploymentConfigurati /** Boolean. Only show security prompts to user if true */ public static final String KEY_SECURITY_PROMPT_USER = "deployment.security.askgrantdialog.show"; + + public static final String KEY_SECURITY_TRUSTED_POLICY = "deployment.security.trusted.policy"; /** Boolean. Only give AWTPermission("showWindowWithoutWarningBanner") if true */ public static final String KEY_SECURITY_ALLOW_HIDE_WINDOW_WARNING = "deployment.security.sandbox.awtwarningwindow"; diff -r c938ea901f2f -r e65820401742 netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java --- a/netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java Tue Jan 04 14:45:10 2011 -0500 +++ b/netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java Tue Jan 04 15:12:40 2011 -0500 @@ -225,7 +225,7 @@ public class ApplicationInstance { JNLPClassLoader loader = (JNLPClassLoader) this.loader; SecurityDesc s = loader.getSecurity(); - ProtectionDomain pd = new ProtectionDomain(cs, s.getPermissions(), null, null); + ProtectionDomain pd = new ProtectionDomain(cs, s.getPermissions(cs), null, null); // Add to hashmap AccessControlContext acc = new AccessControlContext(new ProtectionDomain[] { pd }); diff -r c938ea901f2f -r e65820401742 netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java --- a/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Tue Jan 04 14:45:10 2011 -0500 +++ b/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Tue Jan 04 15:12:40 2011 -0500 @@ -578,7 +578,7 @@ public class JNLPClassLoader extends URL (getCodeSourceSecurity(cs.getLocation()).getSecurityType().equals(SecurityDesc.ALL_PERMISSIONS) || getCodeSourceSecurity(cs.getLocation()).getSecurityType().equals(SecurityDesc.J2EE_PERMISSIONS))) { - permissions = getCodeSourceSecurity(cs.getLocation()).getPermissions(); + permissions = getCodeSourceSecurity(cs.getLocation()).getPermissions(cs); } Enumeration e = permissions.elements(); From omajid at redhat.com Tue Jan 4 12:13:12 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 04 Jan 2011 15:13:12 -0500 Subject: [icedtea-web] RFC: custom policy for trusted applications In-Reply-To: <20110104191118.GA31828@redhat.com> References: <4D1132FA.40306@redhat.com> <4D236AB4.8070700@redhat.com> <20110104191118.GA31828@redhat.com> Message-ID: <4D237F58.7060705@redhat.com> On 01/04/2011 02:11 PM, Deepak Bhole wrote: > * Omair Majid [2011-01-04 13:46]: >> On 12/21/2010 06:06 PM, Omair Majid wrote: >>> Hi, >>> >>> The attached patch adds support for using a custom policy file to grant >>> permissions to trusted applications. >>> >>> ChangeLog: >>> 2010-12-21 Omair Majid >>> >>> * netx/net/sourceforge/jnlp/SecurityDesc.java: Add >>> customTrustedPolicy. >>> (SecurityDesc): Initialize customTrustedPolicy. >>> (getCustomTrustedPolicy): New method. Get custom policy file from >>> configuration and use it to initialize a custom configuration. >>> (getPermissions): If trusted application and customTrustedPolicy is >>> not null, delegate to otherwise return AllPermissions. >>> * netx/net/sourceforge/jnlp/config/Defaults.java >>> (getDefaults): Use constant for property. >>> * netx/net/sourceforge/jnlp/config/DeploymentConfiguration.java: >>> Add new constant KEY_SECURITY_TRUSTED_POLICY. >>> * netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java >>> (installEnvironment): Pass cs as a parameter to >>> SecurityDesc.getPermissions. >>> * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java >>> (getPermissions): Likewise. >>> >>> Any comments or concerns? >>> >>> Cheers, >>> Omair >> >> Ok to commit? >> > > Looks fine to me. OK for HEAD. > Thanks. Pushed to HEAD. Cheers, Omair From bugzilla-daemon at icedtea.classpath.org Tue Jan 4 12:17:43 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 04 Jan 2011 20:17:43 +0000 Subject: [Bug 609] Changing the Look and feel crashes the jvm Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=609 ------- Comment #1 from asu at redhat.com 2011-01-04 20:17 ------- Hello Xander, I have just finished testing this with the latest version on the release branch [1] and did not experience any crashes. I also tried using an older revision tagged as 1.9.2 which also runs without issues. Is this 100% reproducible for you? [asu at Tsuruya:~/src/LAF_Test]$ /jdk/build/icedtea6-1.9/openjdk.build/j2sdk-image/bin/javac -version javac 1.6.0_20 [asu at Tsuruya:~/src/LAF_Test]$ /jdk/build/icedtea6-1.9/openjdk.build/j2sdk-image/bin/java -version java version "1.6.0_20" OpenJDK Runtime Environment (IcedTea6 1.9.4pre+r7919aac747ab) (linux-gnu build 1.6.0_20-b20) OpenJDK 64-Bit Server VM (build 17.0-b16, mixed mode) [asu at Tsuruya:~/src/LAF_Test]$ rm *.class [asu at Tsuruya:~/src/LAF_Test]$ /jdk/build/icedtea6-1.9/openjdk.build/j2sdk-image/bin/javac test.java [asu at Tsuruya:~/src/LAF_Test]$ /jdk/build/icedtea6-1.9/openjdk.build/j2sdk-image/bin/java test com.sun.java.swing.plaf.gtk.GTKLookAndFeel [asu at Tsuruya:~/src/LAF_Test]$ cat test.java import javax.swing.UIManager.LookAndFeelInfo; public class test { public static void main(String[] args) throws Exception { //Set Look & Feel try { LookAndFeelInfo[] lafs = javax.swing.UIManager.getInstalledLookAndFeels(); String s = lafs[3].getClassName(); System.out.println(s); javax.swing.UIManager.setLookAndFeel(s); } catch (Exception e) { e.printStackTrace(); } } } [asu at Tsuruya:~/src/LAF_Test]$ uname -r 2.6.34.7-66.fc13.x86_64 [1] http://icedtea.classpath.org/hg/release/icedtea6-1.9 -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From omajid at icedtea.classpath.org Tue Jan 4 12:22:50 2011 From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org) Date: Tue, 04 Jan 2011 20:22:50 +0000 Subject: /hg/icedtea-web: use deployment-specific user and system level p... Message-ID: changeset 94ec09d9d634 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=94ec09d9d634 author: Omair Majid date: Tue Jan 04 15:22:41 2011 -0500 use deployment-specific user and system level policy files to grant additional permissions 2011-01-04 Omair Majid * netx/net/sourceforge/jnlp/runtime/JNLPPolicy.java: Add systemJnlpPolicy and userJnlpPolicy. (JNLPPolicy): Initialize the new policies. (getPermissions): Consult the extra policies as well to determine the resulting permissions to be granted. (getPolicyFromConfig): New method. Create a new Policy instance to delegate to for system- and user-level policies. diffstat: 2 files changed, 67 insertions(+), 3 deletions(-) ChangeLog | 10 +++ netx/net/sourceforge/jnlp/runtime/JNLPPolicy.java | 60 +++++++++++++++++++-- diffs (116 lines): diff -r e65820401742 -r 94ec09d9d634 ChangeLog --- a/ChangeLog Tue Jan 04 15:12:40 2011 -0500 +++ b/ChangeLog Tue Jan 04 15:22:41 2011 -0500 @@ -1,3 +1,13 @@ 2011-01-04 Omair Majid + + * netx/net/sourceforge/jnlp/runtime/JNLPPolicy.java: Add + systemJnlpPolicy and userJnlpPolicy. + (JNLPPolicy): Initialize the new policies. + (getPermissions): Consult the extra policies as well to determine the + resulting permissions to be granted. + (getPolicyFromConfig): New method. Create a new Policy instance to + delegate to for system- and user-level policies. + 2011-01-04 Omair Majid * netx/net/sourceforge/jnlp/SecurityDesc.java: Add diff -r e65820401742 -r 94ec09d9d634 netx/net/sourceforge/jnlp/runtime/JNLPPolicy.java --- a/netx/net/sourceforge/jnlp/runtime/JNLPPolicy.java Tue Jan 04 15:12:40 2011 -0500 +++ b/netx/net/sourceforge/jnlp/runtime/JNLPPolicy.java Tue Jan 04 15:22:41 2011 -0500 @@ -16,8 +16,12 @@ package net.sourceforge.jnlp.runtime; +import java.net.URI; +import java.net.URISyntaxException; import java.security.*; import java.util.Enumeration; + +import net.sourceforge.jnlp.config.DeploymentConfiguration; /** * Policy for JNLP environment. This class delegates to the @@ -40,10 +44,19 @@ public class JNLPPolicy extends Policy { /** the previous policy */ private static Policy systemPolicy; + /** the system level policy for jnlps */ + private Policy systemJnlpPolicy = null; + + /** the user-level policy for jnlps */ + private Policy userJnlpPolicy = null; + protected JNLPPolicy() { shellSource = JNLPPolicy.class.getProtectionDomain().getCodeSource(); systemSource = Policy.class.getProtectionDomain().getCodeSource(); systemPolicy = Policy.getPolicy(); + + systemJnlpPolicy = getPolicyFromConfig(DeploymentConfiguration.KEY_SYSTEM_SECURITY_POLICY); + userJnlpPolicy = getPolicyFromConfig(DeploymentConfiguration.KEY_USER_SECURITY_POLICY); } /** @@ -62,11 +75,27 @@ public class JNLPPolicy extends Policy { PermissionCollection clPermissions = cl.getPermissions(source); + Enumeration e; + CodeSource appletCS = new CodeSource(JNLPRuntime.getApplication().getJNLPFile().getSourceLocation(), (java.security.cert.Certificate[]) null); + // systempolicy permissions need to be accounted for as well - CodeSource appletCS = new CodeSource(JNLPRuntime.getApplication().getJNLPFile().getSourceLocation(), (java.security.cert.Certificate[]) null); - Enumeration e = systemPolicy.getPermissions(appletCS).elements(); + e = systemPolicy.getPermissions(appletCS).elements(); while (e.hasMoreElements()) - clPermissions.add((Permission) e.nextElement()); + clPermissions.add(e.nextElement()); + + // and so do permissions from the jnlp-specific system policy + if (systemJnlpPolicy != null) { + e = systemJnlpPolicy.getPermissions(appletCS).elements(); + while (e.hasMoreElements()) + clPermissions.add(e.nextElement()); + } + + // and permissiosn from jnlp-specific user policy too + if (userJnlpPolicy != null) { + e = userJnlpPolicy.getPermissions(appletCS).elements(); + while (e.hasMoreElements()) + clPermissions.add(e.nextElement()); + } return clPermissions; } @@ -93,6 +122,31 @@ public class JNLPPolicy extends Policy { return result; } + /** + * Constructs a delegate policy based on a config setting + * @param key a KEY_* in DeploymentConfiguration + * @return a policy based on the configuration set by the user + */ + private Policy getPolicyFromConfig(String key) { + Policy policy = null; + String policyLocation = null; + DeploymentConfiguration config = JNLPRuntime.getConfiguration(); + policyLocation = config.getProperty(key); + if (policyLocation != null) { + try { + URI policyUri = new URI(policyLocation); + policy = getInstance("JavaPolicy", new URIParameter(policyUri)); + } catch (IllegalArgumentException e) { + e.printStackTrace(); + } catch (NoSuchAlgorithmException e) { + e.printStackTrace(); + } catch (URISyntaxException e) { + e.printStackTrace(); + } + } + return policy; + } + public boolean implies(ProtectionDomain domain, Permission permission) { //Include the permissions that may be added during runtime. PermissionCollection pc = getPermissions(domain.getCodeSource()); From omajid at icedtea.classpath.org Tue Jan 4 12:26:28 2011 From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org) Date: Tue, 04 Jan 2011 20:26:28 +0000 Subject: /hg/release/icedtea-web-1.0: fix NullPointerException in debug o... Message-ID: changeset 8f4d653aeb0e in /hg/release/icedtea-web-1.0 details: http://icedtea.classpath.org/hg/release/icedtea-web-1.0?cmd=changeset;node=8f4d653aeb0e author: Omair Majid date: Tue Jan 04 15:26:11 2011 -0500 fix NullPointerException in debug output 2011-01-04 Omair Majid * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java (installShutdownHooks): Only print when not null. diffstat: 2 files changed, 8 insertions(+), 4 deletions(-) ChangeLog | 5 +++++ netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java | 7 +++---- diffs (35 lines): diff -r 4afa92b88e74 -r 8f4d653aeb0e ChangeLog --- a/ChangeLog Fri Dec 24 15:17:35 2010 -0500 +++ b/ChangeLog Tue Jan 04 15:26:11 2011 -0500 @@ -1,3 +1,8 @@ 2010-12-24 Omair Majid + + * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java + (installShutdownHooks): Only print when not null. + 2010-12-24 Omair Majid * netx/net/sourceforge/jnlp/security/SecurityWarning.java diff -r 4afa92b88e74 -r 8f4d653aeb0e netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java --- a/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Fri Dec 24 15:17:35 2010 -0500 +++ b/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Tue Jan 04 15:26:11 2011 -0500 @@ -182,16 +182,15 @@ public class JNLPClassLoader extends URL Runtime.getRuntime().addShutdownHook(new Thread() { @Override public void run() { - if (JNLPRuntime.isDebug()) { - System.out.println("Cleaning up native directory" + nativeDir.getAbsolutePath()); - } - /* * Delete only the native dir created by this classloader (if * there is one). Other classloaders (parent, peers) will all * cleanup things they created */ if (nativeDir != null) { + if (JNLPRuntime.isDebug()) { + System.out.println("Cleaning up native directory" + nativeDir.getAbsolutePath()); + } try { FileUtils.recursiveDelete(nativeDir, new File(System.getProperty("java.io.tmpdir"))); From omajid at redhat.com Tue Jan 4 12:26:47 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 04 Jan 2011 15:26:47 -0500 Subject: [icedtea-web] RFC: fix exception in debug output from JNLPClassLoader In-Reply-To: <20110104193204.GE31828@redhat.com> References: <4D1508BC.5030200@redhat.com> <20101225000122.GH16863@rivendell.middle-earth.co.uk> <4D236357.40806@redhat.com> <20110104193204.GE31828@redhat.com> Message-ID: <4D238287.9000508@redhat.com> On 01/04/2011 02:32 PM, Deepak Bhole wrote: > * Omair Majid [2011-01-04 13:13]: >> On 12/24/2010 07:01 PM, Dr Andrew John Hughes wrote: >>> On 15:55 Fri 24 Dec , Omair Majid wrote: >>>> The attached patch fixes an exception that happens when printing debug >>>> output. >>>> >>>> The exception only happens when javaws is run in verbose mode and the >>>> JVM is shutting down - so it does not affect the behaviour of the JNLP >>>> application. >>>> >>>> Any objections? >>>> >>>> ChangeLog >>>> 2010-12-24 Omair Majid >>>> >>>> * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java >>>> (installShutdownHooks): Only print when not null. >>>> >>>> Cheers, >>>> Omair >>> >>> Good spot. Approved. >>> >>> If this is present in 1.0 too, it should probably be backported. >> >> Fix pushed to HEAD. >> >> Deepak, may I add this to 1.0 too? >> > > Yes, please do. > Done. Cheers, Omair From omajid at redhat.com Tue Jan 4 12:28:06 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 04 Jan 2011 15:28:06 -0500 Subject: [icedtea-web] RFC: use deployment-specific system- and user-level policy files to grant permissions In-Reply-To: <20110104191358.GB31828@redhat.com> References: <4D0BEC5A.2070701@redhat.com> <20110104191358.GB31828@redhat.com> Message-ID: <4D2382D6.8050903@redhat.com> On 01/04/2011 02:13 PM, Deepak Bhole wrote: > * Omair Majid [2010-12-17 18:05]: >> Hi, >> >> The following patch makes these two properties from >> deployment.properties have effect: >> deployment.user.security.policy >> deployment.system.security.policy >> >> The patch makes the JNLPPolicy class look for permissions for the >> given code source in the files defined by these two properties as >> well. >> >> Thoughts? >> > > Looks good! OK for HEAD. > Thanks for looking over the change. I have pushed it to HEAD. Cheers, Omair From bugzilla-daemon at icedtea.classpath.org Tue Jan 4 12:31:00 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 04 Jan 2011 20:31:00 +0000 Subject: [Bug 609] Changing the Look and feel crashes the jvm Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=609 ------- Comment #2 from xander at badeend.org 2011-01-04 20:30 ------- Hello Andrew, I did the same as you and it always crashes... See the results below: cheers Xander xander at veronica ~/test $ javac -version javac 1.6.0_20 xander at veronica ~/test $ java -version java version "1.6.0_20" OpenJDK Runtime Environment (IcedTea6 1.9.2) (Gentoo build 1.6.0_20-b20) OpenJDK 64-Bit Server VM (build 19.0-b09, mixed mode) xander at veronica ~/test $ rm *.class xander at veronica ~/test $ javac Test.java xander at veronica ~/test $ ls Test.class Test.java xander at veronica ~/test $ java Test com.sun.java.swing.plaf.gtk.GTKLookAndFeel # # A fatal error has been detected by the Java Runtime Environment: # # SIGSEGV (0xb) at pc=0x00007f0a0d95ccc9, pid=4316, tid=139681168054032 # # JRE version: 6.0_20-b20 # Java VM: OpenJDK 64-Bit Server VM (19.0-b09 mixed mode linux-amd64 ) # Derivative: IcedTea6 1.9.2 # Distribution: Built on Gentoo Base System release 1.12.14 (Thu Nov 25 23:05:49 CET 2010) # Problematic frame: # C [libc.so.6+0x77cc9] cfree+0x19 # # An error report file with more information is saved as: # /home/xander/test/hs_err_pid4316.log # # If you would like to submit a bug report, please include # instructions how to reproduce the bug and visit: # http://icedtea.classpath.org/bugzilla # The crash happened outside the Java Virtual Machine in native code. # See problematic frame for where to report the bug. # Aborted xander at veronica ~/test $ cat Test.java import javax.swing.UIManager.LookAndFeelInfo; public class Test { public static void main(String[] args) throws Exception { //Set Look & Feel try { LookAndFeelInfo[] lafs = javax.swing.UIManager.getInstalledLookAndFeels(); String s = lafs[3].getClassName(); System.out.println(s); javax.swing.UIManager.setLookAndFeel(s); } catch (Exception e) { e.printStackTrace(); } } } xander at veronica ~/test $ uname -a Linux veronica 2.6.37-rc2 #5 SMP Wed Dec 29 21:49:10 CET 2010 x86_64 Intel(R) Core(TM)2 Duo CPU T6400 @ 2.00GHz GenuineIntel GNU/Linux xander at veronica ~/test $ -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From dbhole at redhat.com Tue Jan 4 13:05:21 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Tue, 4 Jan 2011 16:05:21 -0500 Subject: Not using signers in JNLPPolicy.getPermissions() In-Reply-To: <4D0BED49.5070108@redhat.com> References: <4D0BED49.5070108@redhat.com> Message-ID: <20110104210520.GA2891@redhat.com> * Omair Majid [2010-12-17 18:07]: > Hi, > > I noticed this line in JNLPPolicy.getPermissions(CodeSource source): > > CodeSource appletCS = new CodeSource(JNLPRuntime.getApplication().getJNLPFile().getSourceLocation(), > (java.security.cert.Certificate[]) null); > > I understand that we need a URL to the actual source of the code > (instead of a url to the on-disk cache), but why use null as the > certificate array? Is there a reason we are not using the actual > signers associated with the CodeSource? > appletCS is used only in the getPermissions call below, whose return is merged with the permissions that the jar code signer has (clPermissions). clPermissions already accounts for code-signer specific permissions, so providing signers to the CodeSource constructor would make no difference, and was probably done to avoid redundant merging. Cheers, Deepak > Thanks, > Omair From omajid at redhat.com Tue Jan 4 13:33:18 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 04 Jan 2011 16:33:18 -0500 Subject: Not using signers in JNLPPolicy.getPermissions() In-Reply-To: <20110104210520.GA2891@redhat.com> References: <4D0BED49.5070108@redhat.com> <20110104210520.GA2891@redhat.com> Message-ID: <4D23921E.1000707@redhat.com> On 01/04/2011 04:05 PM, Deepak Bhole wrote: > * Omair Majid [2010-12-17 18:07]: >> Hi, >> >> I noticed this line in JNLPPolicy.getPermissions(CodeSource source): >> >> CodeSource appletCS = new CodeSource(JNLPRuntime.getApplication().getJNLPFile().getSourceLocation(), >> (java.security.cert.Certificate[]) null); >> >> I understand that we need a URL to the actual source of the code >> (instead of a url to the on-disk cache), but why use null as the >> certificate array? Is there a reason we are not using the actual >> signers associated with the CodeSource? >> > > appletCS is used only in the getPermissions call below, whose return is > merged with the permissions that the jar code signer has > (clPermissions). > > clPermissions already accounts for code-signer specific permissions, so > providing signers to the CodeSource constructor would make no > difference, and was probably done to avoid redundant merging. > Thanks for the explanation. However, I still dont think this code is entirely correct. clPermissions (as far as I can tell) does not account for system policy. If the system's policy file contains something like: grant signedBy "Duke" { permission java.io.FilePermission "/tmp/*", "read,write"; }; And the applet is signed by Duke, the code wont be granted these permissions (but like other signed code, it will be granted AllPermissions - unless a policy file is used to grant it a subset of permissions rather than all permissions). Cheers, Omair From dbhole at redhat.com Tue Jan 4 13:42:10 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Tue, 4 Jan 2011 16:42:10 -0500 Subject: Not using signers in JNLPPolicy.getPermissions() In-Reply-To: <4D23921E.1000707@redhat.com> References: <4D0BED49.5070108@redhat.com> <20110104210520.GA2891@redhat.com> <4D23921E.1000707@redhat.com> Message-ID: <20110104214209.GB2891@redhat.com> * Omair Majid [2011-01-04 16:33]: > On 01/04/2011 04:05 PM, Deepak Bhole wrote: > >* Omair Majid [2010-12-17 18:07]: > >>Hi, > >> > >>I noticed this line in JNLPPolicy.getPermissions(CodeSource source): > >> > >>CodeSource appletCS = new CodeSource(JNLPRuntime.getApplication().getJNLPFile().getSourceLocation(), > >>(java.security.cert.Certificate[]) null); > >> > >>I understand that we need a URL to the actual source of the code > >>(instead of a url to the on-disk cache), but why use null as the > >>certificate array? Is there a reason we are not using the actual > >>signers associated with the CodeSource? > >> > > > >appletCS is used only in the getPermissions call below, whose return is > >merged with the permissions that the jar code signer has > >(clPermissions). > > > >clPermissions already accounts for code-signer specific permissions, so > >providing signers to the CodeSource constructor would make no > >difference, and was probably done to avoid redundant merging. > > > > Thanks for the explanation. However, I still dont think this code is > entirely correct. clPermissions (as far as I can tell) does not > account for system policy. If the system's policy file contains > something like: > > grant signedBy "Duke" { > permission java.io.FilePermission "/tmp/*", "read,write"; > }; > > And the applet is signed by Duke, the code wont be granted these > permissions (but like other signed code, it will be granted > AllPermissions - unless a policy file is used to grant it a subset > of permissions rather than all permissions). > Ah, sorry, you are correct. I thought there was another getPermissions call based on signer in JNLPClassLoader, but that is not that case. That said however, AllPermission trumps per-cert permissions anyway, and that is the expected behaviour. The docs state: "With this (deployment.security.trusted.policy) property unset (default), trusted code will be granted the AllPermission permission." I am trying to understand what would be gained by providing code signers to the CodeSource constructor.. or am I missing something? Cheers, Deepak > Cheers, > Omair From omajid at redhat.com Tue Jan 4 13:56:38 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 04 Jan 2011 16:56:38 -0500 Subject: Not using signers in JNLPPolicy.getPermissions() In-Reply-To: <20110104214209.GB2891@redhat.com> References: <4D0BED49.5070108@redhat.com> <20110104210520.GA2891@redhat.com> <4D23921E.1000707@redhat.com> <20110104214209.GB2891@redhat.com> Message-ID: <4D239796.5040906@redhat.com> On 01/04/2011 04:42 PM, Deepak Bhole wrote: > * Omair Majid [2011-01-04 16:33]: >> On 01/04/2011 04:05 PM, Deepak Bhole wrote: >>> * Omair Majid [2010-12-17 18:07]: >>>> Hi, >>>> >>>> I noticed this line in JNLPPolicy.getPermissions(CodeSource source): >>>> >>>> CodeSource appletCS = new CodeSource(JNLPRuntime.getApplication().getJNLPFile().getSourceLocation(), >>>> (java.security.cert.Certificate[]) null); >>>> >>>> I understand that we need a URL to the actual source of the code >>>> (instead of a url to the on-disk cache), but why use null as the >>>> certificate array? Is there a reason we are not using the actual >>>> signers associated with the CodeSource? >>>> >>> >>> appletCS is used only in the getPermissions call below, whose return is >>> merged with the permissions that the jar code signer has >>> (clPermissions). >>> >>> clPermissions already accounts for code-signer specific permissions, so >>> providing signers to the CodeSource constructor would make no >>> difference, and was probably done to avoid redundant merging. >>> >> >> Thanks for the explanation. However, I still dont think this code is >> entirely correct. clPermissions (as far as I can tell) does not >> account for system policy. If the system's policy file contains >> something like: >> >> grant signedBy "Duke" { >> permission java.io.FilePermission "/tmp/*", "read,write"; >> }; >> >> And the applet is signed by Duke, the code wont be granted these >> permissions (but like other signed code, it will be granted >> AllPermissions - unless a policy file is used to grant it a subset >> of permissions rather than all permissions). >> > > Ah, sorry, you are correct. I thought there was another getPermissions > call based on signer in JNLPClassLoader, but that is not that case. > That said however, AllPermission trumps per-cert permissions anyway, and > that is the expected behaviour. The docs state: > > "With this (deployment.security.trusted.policy) property unset > (default), trusted code will be granted the AllPermission permission." > Oh, yes. I agree that this should not be a problem in the default configuration. > I am trying to understand what would be gained by providing code signers > to the CodeSource constructor.. or am I missing something? > Well, as the documentation says, AllPermissions are not granted if deployment.security.trusted.policy points to a policy file. So suppose an advanced user sets up a policy file to grant no permissions to trusted code. The user then adds a custom policy rule (in the system policy file or the deployment-specific policy file) to grant AllPermissions to code signed by a signer "Foo". Now an applet signed by "Bar" will (or should!) run in a sandbox. However, an applet signed by "Foo" should run with all permissions, but because the code signer is null, it will be granted no permissions and it will run in a sandbox. Thanks, Omair From dlila at icedtea.classpath.org Tue Jan 4 13:57:44 2011 From: dlila at icedtea.classpath.org (dlila at icedtea.classpath.org) Date: Tue, 04 Jan 2011 21:57:44 +0000 Subject: /hg/icedtea6: Fixed RH661505 - JPEGs decoder color space recogni... Message-ID: changeset d2d762ec4dda in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=d2d762ec4dda author: Denis Lila date: Tue Jan 04 16:56:06 2011 -0500 Fixed RH661505 - JPEGs decoder color space recognition problem. diffstat: 4 files changed, 26 insertions(+), 1 deletion(-) ChangeLog | 7 +++++++ Makefile.am | 3 ++- NEWS | 1 + patches/661505-jpeg.patch | 16 ++++++++++++++++ diffs (58 lines): diff -r 1121be5e4dbd -r d2d762ec4dda ChangeLog --- a/ChangeLog Tue Jan 04 08:50:11 2011 -0500 +++ b/ChangeLog Tue Jan 04 16:56:06 2011 -0500 @@ -1,3 +1,10 @@ 2011-01-04 Deepak Bhole + + Fixed RH661505. + * NEWS: Updated with fix. + * Makefile.am: Apply patch. + * patches/661506-jpeg.patch: New file. Bug fix. + 2011-01-04 Deepak Bhole Backport S6687968, S6541476, S6782079 diff -r 1121be5e4dbd -r d2d762ec4dda Makefile.am --- a/Makefile.am Tue Jan 04 08:50:11 2011 -0500 +++ b/Makefile.am Tue Jan 04 16:56:06 2011 -0500 @@ -316,7 +316,8 @@ ICEDTEA_PATCHES = \ patches/openjdk/6800846-printing-quality.patch \ patches/openjdk/6687968-pngimagereader_mem_leak.patch \ patches/openjdk/6541476-png-iTXt-chunk.patch \ - patches/openjdk/6782079-png_metadata_oom.patch + patches/openjdk/6782079-png_metadata_oom.patch \ + patches/661505-jpeg.patch if WITH_ALT_HSBUILD ICEDTEA_PATCHES += \ diff -r 1121be5e4dbd -r d2d762ec4dda NEWS --- a/NEWS Tue Jan 04 08:50:11 2011 -0500 +++ b/NEWS Tue Jan 04 16:56:06 2011 -0500 @@ -54,6 +54,7 @@ New in release 1.10 (2010-XX-XX): - S6687968: PNGImageReader leaks native memory through an Inflater - S6541476, RH665355: PNG imageio plugin incorrectly handles iTXt chunk - S6782079: PNG: reading metadata may cause OOM on truncated images + - RH661505: JPEGs with sRGB IEC61966-2.1 color profiles have wrong colors * Bug fixes - S7003777, RH647674: JTextPane produces incorrect content after parsing the html text diff -r 1121be5e4dbd -r d2d762ec4dda patches/661505-jpeg.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/661505-jpeg.patch Tue Jan 04 16:56:06 2011 -0500 @@ -0,0 +1,16 @@ +--- openjdk/jdk/src/share/native/sun/awt/image/jpeg/imageioJPEG.c.old 2010-12-24 13:20:49.444589072 -0500 ++++ openjdk/jdk/src/share/native/sun/awt/image/jpeg/imageioJPEG.c 2010-12-24 13:21:58.059463767 -0500 +@@ -1488,2 +1488,4 @@ + ++#define JPEG_APP1 (JPEG_APP0 + 1) /* EXIF APP1 marker code */ ++ + JNIEXPORT jlong JNICALL +@@ -1541,2 +1543,3 @@ + jpegsavemarkers(cinfo, ICC_MARKER, 0xFFFF); ++ jpegsavemarkers(cinfo, JPEG_APP1, 0xFFFF); + +@@ -1601,4 +1604,2 @@ + +-#define JPEG_APP1 (JPEG_APP0 + 1) /* EXIF APP1 marker code */ +- + /* From ptisnovs at redhat.com Wed Jan 5 07:42:20 2011 From: ptisnovs at redhat.com (Pavel Tisnovsky) Date: Wed, 05 Jan 2011 16:42:20 +0100 Subject: Licence for PngSuite? Message-ID: <4D24915C.30706@redhat.com> Hi all, I'd like to create new regression test for checking image reader/writer behaviour and for this I need some useful PNG images. Below are my conversation with the author of PngSuite (http://www.schaik.com/pngsuite/pngsuite.html) with his permission to use his images in OpenJDK. Do you think that this permission allow as to add these images to OpenJDK OR at least to IcedTea? Cheers Pavel -------- Original Message -------- Subject: Re: Licence for PngSuite? Date: Wed, 05 Jan 2011 07:25:37 -0700 From: Willem van Schaik To: Pavel Tisnovsky References: <4D245D00.1010806 at redhat.com> Hi Pavel, Five or six years ago I had a very similar discussion with "your friends" ;-) from Novell/SuSE. They needed to be sure that legally they were OK with including PngSuite somewhere in their distro. The 'legal' status of PngSuite, if you can even call that, is that anybody may use it any way they like. You may include it in any piece of software, no matter if that's GPL, freeware or commercial. When I created PngSuite at the time, I created every single image from scratch. There was nothing used, borrowed, etc. from existing images. I did it that way because nothing out there was usable, but the advantage is that the end result has no depending copyright issues. Let me know if you need anything more official than this. See you, Willem PS. I've been and still am a "RedHat guy" since 1985, when I switched from Slackware :). PngSuite was generated on RedHat 3.0.3 and my current desktop is CentOS. Laptops are running Fedora and the PVR is MythDora. OpenJDK is also close to my heart, having been with Sun Microsystems the last 10 years. Mow with Cisco, selling Redhat on UCS. Pavel Tisnovsky wrote: > Hi Willem, > > I prepare regression tests for OpenJDK including tests which check > correct behaviour of image readers and writers. I was looking for some > PNG files containing various colour types and various not-so-often used > chunks and your PngSuite seems to be one of the best sources (well I > missed images containing iTXt chunk which is quite important due to some > issues we've found in UTF-8 related code in JDK ;-). > > Do you think it is possible to add some of these images to OpenJDK as > part of regression test package? I've found you have copyright to it > (PngSuite.README) but I am unable to find any licence text (GPLxx is > best suited for OpenJDK at this moment). > > Best regards, > Pavel Tisnovsky > OpenJDK Team > Red Hat, Inc. > > -- Willem van Schaik http://www.schaik.com/ From ahughes at redhat.com Wed Jan 5 07:55:13 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Wed, 5 Jan 2011 15:55:13 +0000 Subject: Licence for PngSuite? In-Reply-To: <4D24915C.30706@redhat.com> References: <4D24915C.30706@redhat.com> Message-ID: <20110105155513.GB18924@rivendell.middle-earth.co.uk> On 16:42 Wed 05 Jan , Pavel Tisnovsky wrote: > Hi all, > > I'd like to create new regression test for checking image reader/writer > behaviour and for this I need some useful PNG images. > > Below are my conversation with the author of PngSuite > (http://www.schaik.com/pngsuite/pngsuite.html) with his permission to > use his images in OpenJDK. > > Do you think that this permission allow as to add these images to > OpenJDK OR at least to IcedTea? > Sounds like there is no issue with including them in IcedTea. We can't make the decision for OpenJDK. > Cheers > Pavel > > -------- Original Message -------- > Subject: Re: Licence for PngSuite? > Date: Wed, 05 Jan 2011 07:25:37 -0700 > From: Willem van Schaik > To: Pavel Tisnovsky > References: <4D245D00.1010806 at redhat.com> > > Hi Pavel, > > Five or six years ago I had a very similar discussion with "your > friends" ;-) from Novell/SuSE. They needed to be sure that legally they > were OK with including PngSuite somewhere in their distro. > > The 'legal' status of PngSuite, if you can even call that, is that > anybody may use it any way they like. You may include it in any piece of > software, no matter if that's GPL, freeware or commercial. > > When I created PngSuite at the time, I created every single image from > scratch. There was nothing used, borrowed, etc. from existing images. I > did it that way because nothing out there was usable, but the advantage > is that the end result has no depending copyright issues. > > Let me know if you need anything more official than this. > > See you, > Willem > > > PS. I've been and still am a "RedHat guy" since 1985, when I switched > from Slackware :). PngSuite was generated on RedHat 3.0.3 and my current > desktop is CentOS. Laptops are running Fedora and the PVR is MythDora. > OpenJDK is also close to my heart, having been with Sun Microsystems the > last 10 years. Mow with Cisco, selling Redhat on UCS. > > > > > > > > Pavel Tisnovsky wrote: > > Hi Willem, > > > > I prepare regression tests for OpenJDK including tests which check > > correct behaviour of image readers and writers. I was looking for some > > PNG files containing various colour types and various not-so-often used > > chunks and your PngSuite seems to be one of the best sources (well I > > missed images containing iTXt chunk which is quite important due to some > > issues we've found in UTF-8 related code in JDK ;-). > > > > Do you think it is possible to add some of these images to OpenJDK as > > part of regression test package? I've found you have copyright to it > > (PngSuite.README) but I am unable to find any licence text (GPLxx is > > best suited for OpenJDK at this moment). > > > > Best regards, > > Pavel Tisnovsky > > OpenJDK Team > > Red Hat, Inc. > > > > > > > -- > > Willem van Schaik > > http://www.schaik.com/ > -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From bugzilla-daemon at icedtea.classpath.org Wed Jan 5 16:34:54 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 06 Jan 2011 00:34:54 +0000 Subject: [Bug 610] New: SIGSEGV (0xb) at pc=0xb70254c7, pid=7087, tid=2339584880 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=610 Summary: SIGSEGV (0xb) at pc=0xb70254c7, pid=7087, tid=2339584880 Product: IcedTea Version: 6-1.8.3 Platform: all OS/Version: Linux Status: NEW Severity: normal Priority: P2 Component: IcedTea6 AssignedTo: unassigned at icedtea.classpath.org ReportedBy: pyro_maniac at web.de # # A fatal error has been detected by the Java Runtime Environment: # # SIGSEGV (0xb) at pc=0xb70254c7, pid=7087, tid=2339584880 # # JRE version: 6.0_18-b18 # Java VM: OpenJDK Server VM (16.0-b13 mixed mode linux-x86 ) # Derivative: IcedTea6 1.8.3 # Distribution: Debian GNU/Linux unstable (sid), package 6b18-1.8.3-2 # Problematic frame: # V [libjvm.so+0x5104c7] --------------- T H R E A D --------------- Current thread (0x08b01000): GCTaskThread [stack: 0x8b6b3000,0x8b734000] [id=7089] siginfo:si_signo=SIGSEGV: si_errno=0, si_code=1 (SEGV_MAPERR), si_addr=0x0000000c Registers: EAX=0x00000008, EBX=0xb71ba01c, ECX=0x00000000, EDX=0xa8f36cb0 ESP=0x8b732e80, EBP=0x8b732ed8, ESI=0x00000000, EDI=0x94e07ed4 EIP=0xb70254c7, CR2=0x0000000c, EFLAGS=0x00210293 Top of Stack: (sp=0x8b732e80) 0x8b732e80: 08b4dbd0 a90a67c0 00000001 00000001 0x8b732e90: 01010e20 a8ec0000 00000000 08b4dc2c 0x8b732ea0: 08b00e20 08b01000 4fcd3a81 4fcd3a80 0x8b732eb0: 8b732f00 4f8a39bc 4f8b39bc ab7441ec 0x8b732ec0: 08b00e20 8acbbfc0 8b732ee8 b71ba01c 0x8b732ed0: 00000000 94e07ed4 8b732f28 b702a508 0x8b732ee0: 08b4dbd0 a8f36cb0 00000001 00000000 0x8b732ef0: 08b4dbd0 00000000 8b732f0c 8b732f08 -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From mark at klomp.org Thu Jan 6 03:12:46 2011 From: mark at klomp.org (Mark Wielaard) Date: Thu, 06 Jan 2011 12:12:46 +0100 Subject: Build failed in Hudson: IcedTea6hgTargetTesting #108 In-Reply-To: <2011632679.1741294298443575.JavaMail.nighttester@toadeater> References: <919265566.1731294212046280.JavaMail.nighttester@toadeater> <2011632679.1741294298443575.JavaMail.nighttester@toadeater> Message-ID: <1294312366.4438.15.camel@springer.wildebeest.org> Hi Andrew, On Thu, 2011-01-06 at 02:20 -0500, Hudson Admin wrote: > [...] > patching file openjdk/jdk/src/share/classes/com/sun/script/javascript/RhinoCompiledScript.java > Checking patches/openjdk/6725214-direct3d-01.patch > 1 out of 2 hunks FAILED -- saving rejects to file openjdk/jdk/make/common/shared/Platform.gmk.rej > 1 out of 2 hunks FAILED -- saving rejects to file openjdk/jdk/make/sun/xawt/mapfile-vers.rej > 1 out of 3 hunks FAILED -- saving rejects to file openjdk/jdk/src/share/classes/sun/java2d/SunGraphicsEnvironment.java.rej > ERROR patch patches/openjdk/6725214-direct3d-01.patch FAILED! > WARNING make clean-patch before retrying a fix > make: *** [stamps/patch.stamp] Error 2 > + exit 1 Could you take a look at why this is failing? It seems to have failed in exactly the same way for a couple of days now, but I haven't seen this failure on other setups. Thanks, Mark From bugzilla-daemon at icedtea.classpath.org Thu Jan 6 04:42:44 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 06 Jan 2011 12:42:44 +0000 Subject: [Bug 611] New: Minecr Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=611 Summary: Minecr Product: VisualVM Harness Version: unspecified Platform: all OS/Version: Linux Status: NEW Severity: blocker Priority: P2 Component: VisualVM AssignedTo: unassigned at icedtea.classpath.org ReportedBy: losderio at freenet.de # # A fatal error has been detected by the Java Runtime Environment: # # SIGSEGV (0xb) at pc=0xb342529c, pid=22616, tid=3011271536 # # JRE version: 6.0_18-b18 # Java VM: OpenJDK Client VM (16.0-b13 mixed mode, sharing linux-x86 ) # Derivative: IcedTea6 1.8.3 # Distribution: Debian GNU/Linux unstable (sid), package 6b18-1.8.3-2 # Problematic frame: # C [libGL.so.1+0x6d29c] XF86DRIQueryExtension+0x8e # # If you would like to submit a bug report, please include # instructions how to reproduce the bug and visit: # http://icedtea.classpath.org/bugzilla # The crash happened outside the Java Virtual Machine in native code. # See problematic frame for where to report the bug. # --------------- T H R E A D --------------- Current thread (0x096d3c00): JavaThread "Minecraft main thread" daemon [_thread_in_native, id=22658, stack(0xb3775000,0xb37c6000)] siginfo:si_signo=SIGSEGV: si_errno=0, si_code=1 (SEGV_MAPERR), si_addr=0x00000004 Registers: EAX=0x00000041, EBX=0x097fc5a8, ECX=0x09809ff0, EDX=0xb3479100 ESP=0xb37c2ae0, EBP=0x097fafb0, ESI=0x00000000, EDI=0x00000001 EIP=0xb342529c, CR2=0x00000004, EFLAGS=0x00010202 Top of Stack: (sp=0xb37c2ae0) 0xb37c2ae0: 00000000 b780a3a0 b7808ff4 b780a3a0 0xb37c2af0: 0000000f 00000074 b7736bbd b780a3d8 0xb37c2b00: b41063e8 00000001 097fafb0 097fc254 0xb37c2b10: b37c4b7c b342303c 097fafb0 b37c2b50 0xb37c2b20: b37c2b54 b7808ff4 b780a3a0 b37c4b7c 0xb37c2b30: 097fc238 b773662c 097fc238 b76f59cf 0xb37c2b40: b3453e0c b37c4b7c b780a3a0 b3453e0e 0xb37c2b50: 00000013 494c2000 097fafb0 097fc1d8 Instructions: (pc=0xb342529c) 0xb342528c: 00 66 89 79 02 83 45 6c 04 83 45 60 01 8b 76 08 0xb342529c: 0f b6 56 04 88 11 88 41 01 33 c9 8d 04 24 51 51 Stack: [0xb3775000,0xb37c6000], sp=0xb37c2ae0, free space=136b37c2484k Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code) C [libGL.so.1+0x6d29c] XF86DRIQueryExtension+0x8e Java frames: (J=compiled Java code, j=interpreted, Vv=VM code) j org.lwjgl.opengl.LinuxDisplayPeerInfo.initDefaultPeerInfo(JILjava/nio/ByteBuffer;Lorg/lwjgl/opengl/PixelFormat;)V+0 j org.lwjgl.opengl.LinuxDisplayPeerInfo.(Lorg/lwjgl/opengl/PixelFormat;)V+24 j org.lwjgl.opengl.LinuxDisplay.createPeerInfo(Lorg/lwjgl/opengl/PixelFormat;)Lorg/lwjgl/opengl/PeerInfo;+6 j org.lwjgl.opengl.Display.create(Lorg/lwjgl/opengl/PixelFormat;Lorg/lwjgl/opengl/Drawable;Lorg/lwjgl/opengl/ContextAttribs;)V+55 j org.lwjgl.opengl.Display.create(Lorg/lwjgl/opengl/PixelFormat;)V+9 j org.lwjgl.opengl.Display.create()V+13 j net.minecraft.client.Minecraft.a()V+135 j net.minecraft.client.Minecraft.run()V+6 j java.lang.Thread.run()V+11 v ~StubRoutines::call_stub --------------- P R O C E S S --------------- Java Threads: ( => current thread ) =>0x096d3c00 JavaThread "Minecraft main thread" daemon [_thread_in_native, id=22658, stack(0xb3775000,0xb37c6000)] 0x09703000 JavaThread "Timer hack thread" daemon [_thread_blocked, id=22657, stack(0xb3966000,0xb39b7000)] 0x09716c00 JavaThread "Keep-Alive-Timer" daemon [_thread_blocked, id=22654, stack(0xb3915000,0xb3966000)] 0x097a6c00 JavaThread "TimerQueue" daemon [_thread_blocked, id=22634, stack(0xb38b9000,0xb390a000)] 0xb3b0b800 JavaThread "DestroyJavaVM" [_thread_blocked, id=22617, stack(0xb6dfd000,0xb6e4e000)] 0x0974d800 JavaThread "AWT-EventQueue-0" [_thread_blocked, id=22632, stack(0xb3ca4000,0xb3cf5000)] 0xb4296000 JavaThread "AWT-Shutdown" [_thread_blocked, id=22631, stack(0xb3c53000,0xb3ca4000)] 0xb4260c00 JavaThread "AWT-XAWT" daemon [_thread_in_native, id=22626, stack(0xb3cf5000,0xb3d46000)] 0xb4226c00 JavaThread "Java2D Disposer" daemon [_thread_blocked, id=22625, stack(0xb3e9d000,0xb3eee000)] 0x096be400 JavaThread "Low Memory Detector" daemon [_thread_blocked, id=22623, stack(0xb43d7000,0xb4428000)] 0x096bc400 JavaThread "CompilerThread0" daemon [_thread_blocked, id=22622, stack(0xb4428000,0xb44a9000)] 0x096ba800 JavaThread "Signal Dispatcher" daemon [_thread_blocked, id=22621, stack(0xb44a9000,0xb44fa000)] 0x096b2400 JavaThread "Finalizer" daemon [_thread_blocked, id=22620, stack(0xb466f000,0xb46c0000)] 0x096b0c00 JavaThread "Reference Handler" daemon [_thread_blocked, id=22619, stack(0xb46c0000,0xb4711000)] Other Threads: 0x096af400 VMThread [stack: 0xb4711000,0xb4792000] [id=22618] 0x096c1c00 WatcherThread [stack: 0xb4356000,0xb43d7000] [id=22624] VM state:not at safepoint (normal execution) VM Mutex/Monitor currently owned by a thread: None Heap def new generation total 157248K, used 75301K [0x4ef70000, 0x59a10000, 0x644c0000) eden space 139776K, 53% used [0x4ef70000, 0x538f97c0, 0x577f0000) from space 17472K, 0% used [0x577f0000, 0x577f0000, 0x58900000) to space 17472K, 0% used [0x58900000, 0x58900000, 0x59a10000) tenured generation total 349568K, used 0K [0x644c0000, 0x79a20000, 0x8ef70000) the space 349568K, 0% used [0x644c0000, 0x644c0000, 0x644c0200, 0x79a20000) compacting perm gen total 12288K, used 3401K [0x8ef70000, 0x8fb70000, 0x92f70000) the space 12288K, 27% used [0x8ef70000, 0x8f2c2560, 0x8f2c2600, 0x8fb70000) ro space 10240K, 72% used [0x92f70000, 0x936ba9e0, 0x936baa00, 0x93970000) rw space 12288K, 60% used [0x93970000, 0x940ab0d0, 0x940ab200, 0x94570000) Dynamic libraries: 08048000-08050000 r-xp 00000000 08:01 2990573 /usr/lib/jvm/java-6-openjdk/jre/bin/java 08050000-08051000 rw-p 00008000 08:01 2990573 /usr/lib/jvm/java-6-openjdk/jre/bin/java 0967e000-09926000 rw-p 00000000 00:00 0 [heap] 4ef70000-59a10000 rw-p 00000000 00:00 0 59a10000-644c0000 rw-p 00000000 00:00 0 644c0000-79a20000 rw-p 00000000 00:00 0 79a20000-8ef70000 rw-p 00000000 00:00 0 8ef70000-8fb70000 rw-p 00000000 00:00 0 8fb70000-92f70000 rw-p 00000000 00:00 0 92f70000-936bb000 r--s 00001000 08:01 2990589 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/client/classes.jsa 936bb000-93970000 rw-p 00000000 00:00 0 93970000-940ac000 rw-p 0074c000 08:01 2990589 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/client/classes.jsa 940ac000-94570000 rw-p 00000000 00:00 0 94570000-9466a000 rw-p 00e88000 08:01 2990589 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/client/classes.jsa 9466a000-94970000 rw-p 00000000 00:00 0 94970000-94978000 r-xs 00f82000 08:01 2990589 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/client/classes.jsa 94978000-94d70000 rw-p 00000000 00:00 0 b33b8000-b346c000 r-xp 00000000 08:01 2642820 /usr/lib/libGL.so.1.2 b346c000-b3477000 rwxp 000b3000 08:01 2642820 /usr/lib/libGL.so.1.2 b3477000-b347c000 rwxp 00000000 00:00 0 b347c000-b3676000 rw-s 00000000 00:04 10977316 /SYSV00000000 (deleted) b371c000-b3773000 r-xp 00000000 08:01 3918721 /home/dominik/.minecraft/bin/natives/liblwjgl.so b3773000-b3774000 r--p 00056000 08:01 3918721 /home/dominik/.minecraft/bin/natives/liblwjgl.so b3774000-b3775000 rw-p 00057000 08:01 3918721 /home/dominik/.minecraft/bin/natives/liblwjgl.so b3775000-b3778000 ---p 00000000 00:00 0 b3778000-b37c6000 rw-p 00000000 00:00 0 b37c6000-b3845000 rw-s 00000000 00:04 11042853 /SYSV00000000 (deleted) b3845000-b38b9000 rw-s 00000000 00:04 10879005 /SYSV00000000 (deleted) b38b9000-b38bc000 ---p 00000000 00:00 0 b38bc000-b390a000 rw-p 00000000 00:00 0 b390d000-b3914000 r-xp 00000000 08:01 2642796 /usr/lib/libatiuki.so.1.0 b3914000-b3915000 rw-p 00006000 08:01 2642796 /usr/lib/libatiuki.so.1.0 b3915000-b3918000 ---p 00000000 00:00 0 b3918000-b3966000 rw-p 00000000 00:00 0 b3966000-b3969000 ---p 00000000 00:00 0 b3969000-b39b7000 rw-p 00000000 00:00 0 b39b7000-b39ba000 ---p 00000000 00:00 0 b39ba000-b3a08000 rw-p 00000000 00:00 0 b3a08000-b3a18000 r-xp 00000000 08:01 2138522 /lib/i686/cmov/libresolv-2.11.2.so b3a18000-b3a19000 r--p 00010000 08:01 2138522 /lib/i686/cmov/libresolv-2.11.2.so b3a19000-b3a1a000 rw-p 00011000 08:01 2138522 /lib/i686/cmov/libresolv-2.11.2.so b3a1a000-b3a1c000 rw-p 00000000 00:00 0 b3a1c000-b3a9b000 rw-s 00000000 00:04 10944538 /SYSV00000000 (deleted) b3a9b000-b3b00000 rw-s 00000000 00:04 10813465 /SYSV00000000 (deleted) b3b00000-b3b26000 rw-p 00000000 00:00 0 b3b26000-b3c00000 ---p 00000000 00:00 0 b3c05000-b3c09000 r-xp 00000000 08:01 2138528 /lib/i686/cmov/libnss_dns-2.11.2.so b3c09000-b3c0a000 r--p 00004000 08:01 2138528 /lib/i686/cmov/libnss_dns-2.11.2.so b3c0a000-b3c0b000 rw-p 00005000 08:01 2138528 /lib/i686/cmov/libnss_dns-2.11.2.so b3c0b000-b3c11000 r-xp 00000000 08:01 2643224 /usr/lib/libXrandr.so.2.2.0 b3c11000-b3c12000 rw-p 00005000 08:01 2643224 /usr/lib/libXrandr.so.2.2.0 b3c12000-b3c1b000 r--s 0010b000 08:01 3918716 /home/dominik/.minecraft/bin/minecraft.jar b3c1b000-b3c1e000 r--s 0001f000 08:01 3918715 /home/dominik/.minecraft/bin/lwjgl_util.jar b3c1e000-b3c23000 r--s 00033000 08:01 3918714 /home/dominik/.minecraft/bin/jinput.jar b3c23000-b3c50000 r-xp 00000000 08:01 2982481 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/liblcms.so b3c50000-b3c51000 rw-p 0002d000 08:01 2982481 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/liblcms.so b3c51000-b3c53000 rw-p 00000000 00:00 0 b3c53000-b3c56000 ---p 00000000 00:00 0 b3c56000-b3ca4000 rw-p 00000000 00:00 0 b3ca4000-b3ca7000 ---p 00000000 00:00 0 b3ca7000-b3cf5000 rw-p 00000000 00:00 0 b3cf5000-b3cf8000 ---p 00000000 00:00 0 b3cf8000-b3d46000 rw-p 00000000 00:00 0 b3d46000-b3d47000 r--s 00000000 08:01 4237615 /var/cache/fontconfig/c05880de57d1f5e948fdfacc138775d9-le32d4.cache-3 b3d47000-b3d53000 r--s 00000000 08:01 4237685 /var/cache/fontconfig/99323171c53ab78df6914f910138fdd6-le32d4.cache-3 b3d53000-b3d59000 r--s 00000000 08:01 4237601 /var/cache/fontconfig/945677eb7aeaf62f1d50efc3fb3ec7d8-le32d4.cache-3 b3d59000-b3d5b000 r--s 00000000 08:01 4237613 /var/cache/fontconfig/ea47318ec9849e1a71e80a5d69d13859-le32d4.cache-3 b3d5b000-b3d5c000 r--s 00000000 08:01 4237612 /var/cache/fontconfig/e3fa16a14183b06aa45b3e009278fd14-le32d4.cache-3 b3d5c000-b3d5e000 r--s 00000000 08:01 4237611 /var/cache/fontconfig/b5ea634b0fb353b8ea17632d1f9ef766-le32d4.cache-3 b3d5e000-b3d62000 r--s 00000000 08:01 4237719 /var/cache/fontconfig/926e794c3d5e5dffcaf2fa83ef8d36c2-le32d4.cache-3 b3d62000-b3d65000 r--s 00000000 08:01 4237610 /var/cache/fontconfig/6eb3985aa4124903f6ff08ba781cd364-le32d4.cache-3 b3d65000-b3d6c000 r--s 00000000 08:01 4237609 /var/cache/fontconfig/6d41288fd70b0be22e8c3a91e032eec0-le32d4.cache-3 b3d6c000-b3d6d000 r--s 00000000 08:01 4235966 /var/cache/fontconfig/4794a0821666d79190d59a36cb4f44b5-le32d4.cache-3 b3d6d000-b3d8f000 r--s 00000000 08:01 4237710 /var/cache/fontconfig/365b55f210c0a22e9a19e35191240f32-le32d4.cache-3 b3d8f000-b3d97000 r--s 00000000 08:01 4237682 /var/cache/fontconfig/e302478682accd753874ffa0d37e8e3c-le32d4.cache-3 b3d97000-b3d9f000 r--s 00000000 08:01 4237600 /var/cache/fontconfig/d52a8644073d54c13679302ca1180695-le32d4.cache-3 b3d9f000-b3dad000 r--s 00000000 08:01 4237707 /var/cache/fontconfig/e13b20fdb08344e0e664864cc2ede53d-le32d4.cache-3 b3daf000-b3db8000 r--s 000ac000 08:01 3918713 /home/dominik/.minecraft/bin/lwjgl.jar b3db8000-b3dbe000 rw-s 00000000 00:04 11010081 /SYSV00000000 (deleted) b3dbe000-b3dd2000 r-xp 00000000 08:01 2982457 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libnet.so b3dd2000-b3dd3000 rw-p 00013000 08:01 2982457 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libnet.so b3dd3000-b3dd4000 r--s 00000000 08:01 4237615 /var/cache/fontconfig/c05880de57d1f5e948fdfacc138775d9-le32d4.cache-3 b3dd4000-b3de0000 r--s 00000000 08:01 4237685 /var/cache/fontconfig/99323171c53ab78df6914f910138fdd6-le32d4.cache-3 b3de0000-b3de6000 r--s 00000000 08:01 4237601 /var/cache/fontconfig/945677eb7aeaf62f1d50efc3fb3ec7d8-le32d4.cache-3 b3de6000-b3de8000 r--s 00000000 08:01 4237613 /var/cache/fontconfig/ea47318ec9849e1a71e80a5d69d13859-le32d4.cache-3 b3de8000-b3de9000 r--s 00000000 08:01 4237612 /var/cache/fontconfig/e3fa16a14183b06aa45b3e009278fd14-le32d4.cache-3 b3de9000-b3deb000 r--s 00000000 08:01 4237611 /var/cache/fontconfig/b5ea634b0fb353b8ea17632d1f9ef766-le32d4.cache-3 b3deb000-b3def000 r--s 00000000 08:01 4237719 /var/cache/fontconfig/926e794c3d5e5dffcaf2fa83ef8d36c2-le32d4.cache-3 b3def000-b3df2000 r--s 00000000 08:01 4237610 /var/cache/fontconfig/6eb3985aa4124903f6ff08ba781cd364-le32d4.cache-3 b3df2000-b3df9000 r--s 00000000 08:01 4237609 /var/cache/fontconfig/6d41288fd70b0be22e8c3a91e032eec0-le32d4.cache-3 b3df9000-b3dfa000 r--s 00000000 08:01 4235966 /var/cache/fontconfig/4794a0821666d79190d59a36cb4f44b5-le32d4.cache-3 b3dfa000-b3e1c000 r--s 00000000 08:01 4237710 /var/cache/fontconfig/365b55f210c0a22e9a19e35191240f32-le32d4.cache-3 b3e1c000-b3e24000 r--s 00000000 08:01 4237682 /var/cache/fontconfig/e302478682accd753874ffa0d37e8e3c-le32d4.cache-3 b3e24000-b3e2c000 r--s 00000000 08:01 4237600 /var/cache/fontconfig/d52a8644073d54c13679302ca1180695-le32d4.cache-3 b3e2c000-b3e3a000 r--s 00000000 08:01 4237707 /var/cache/fontconfig/e13b20fdb08344e0e664864cc2ede53d-le32d4.cache-3 b3e3a000-b3e48000 r--s 00000000 08:01 4237706 /var/cache/fontconfig/865f88548240fee46819705c6468c165-le32d4.cache-3 b3e48000-b3e56000 r--s 00000000 08:01 4237706 /var/cache/fontconfig/865f88548240fee46819705c6468c165-le32d4.cache-3 b3e57000-b3e5e000 r-xp 00000000 08:01 2982278 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libnio.so b3e5e000-b3e5f000 rw-p 00006000 08:01 2982278 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libnio.so b3e5f000-b3e63000 r-xp 00000000 08:01 2643212 /usr/lib/libXfixes.so.3.1.0 b3e63000-b3e64000 rw-p 00003000 08:01 2643212 /usr/lib/libXfixes.so.3.1.0 b3e64000-b3e6c000 r-xp 00000000 08:01 2643216 /usr/lib/libXcursor.so.1.0.2 b3e6c000-b3e6d000 rw-p 00007000 08:01 2643216 /usr/lib/libXcursor.so.1.0.2 b3e6d000-b3e6e000 r-xp 00000000 08:01 2982455 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libjawt.so b3e6e000-b3e6f000 rw-p 00000000 08:01 2982455 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libjawt.so b3e6f000-b3e71000 r-xp 00000000 08:01 2121826 /lib/libnss_mdns4_minimal.so.2 b3e71000-b3e72000 rw-p 00001000 08:01 2121826 /lib/libnss_mdns4_minimal.so.2 b3e72000-b3e75000 r--s 00031000 08:01 2973937 /usr/lib/jvm/java-6-openjdk/jre/lib/ext/sunjce_provider.jar b3e75000-b3e79000 r--s 0007c000 08:01 2973942 /usr/lib/jvm/java-6-openjdk/jre/lib/jsse.jar b3e79000-b3e82000 r-xp 00000000 08:01 2982478 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libjpeg.so b3e82000-b3e83000 rw-p 00008000 08:01 2982478 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libjpeg.so b3e83000-b3e85000 r--s 00013000 08:01 2973925 /usr/lib/jvm/java-6-openjdk/jre/lib/jce.jar b3e85000-b3e9d000 r--s 00000000 08:01 1007626 /home/dominik/.fontconfig/da5476bf6924ef9fc543d03ebbce3132-le32d4.cache-3 b3e9d000-b3ea0000 ---p 00000000 00:00 0 b3ea0000-b3eee000 rw-p 00000000 00:00 0 b3eee000-b3f0b000 r-xp 00000000 08:01 2121812 /lib/libgcc_s.so.1 b3f0b000-b3f0c000 rw-p 0001c000 08:01 2121812 /lib/libgcc_s.so.1 b3f0c000-b3f7f000 r-xp 00000000 08:01 2645572 /usr/lib/libfreetype.so.6.6.0 b3f7f000-b3f83000 rw-p 00073000 08:01 2645572 /usr/lib/libfreetype.so.6.6.0 b3f83000-b3fc7000 r-xp 00000000 08:01 2982274 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libfontmanager.so b3fc7000-b3fc9000 rw-p 00043000 08:01 2982274 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libfontmanager.so b3fc9000-b3fce000 rw-p 00000000 00:00 0 b3fce000-b3fd2000 r-xp 00000000 08:01 2640409 /usr/lib/libXdmcp.so.6.0.0 b3fd2000-b3fd3000 rw-p 00003000 08:01 2640409 /usr/lib/libXdmcp.so.6.0.0 b3fd3000-b3feb000 r-xp 00000000 08:01 2640411 /usr/lib/libxcb.so.1.1.0 b3feb000-b3fec000 rw-p 00017000 08:01 2640411 /usr/lib/libxcb.so.1.1.0 b3fec000-b4105000 r-xp 00000000 08:01 2640413 /usr/lib/libX11.so.6.3.0 b4105000-b4109000 rw-p 00118000 08:01 2640413 /usr/lib/libX11.so.6.3.0 b4109000-b414e000 r-xp 00000000 08:01 3014787 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/xawt/libmawt.so b414e000-b4150000 rw-p 00044000 08:01 3014787 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/xawt/libmawt.so b4150000-b4151000 rw-p 00000000 00:00 0 b4151000-b41d5000 r-xp 00000000 08:01 2982277 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libawt.so b41d5000-b41dc000 rw-p 00084000 08:01 2982277 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libawt.so b41dc000-b4200000 rw-p 00000000 00:00 0 b4200000-b4300000 rw-p 00000000 00:00 0 b4301000-b4302000 r--p 00000000 00:00 0 b4302000-b4304000 r-xp 00000000 08:01 2640407 /usr/lib/libXau.so.6.0.0 b4304000-b4305000 rw-p 00001000 08:01 2640407 /usr/lib/libXau.so.6.0.0 b4305000-b4311000 r-xp 00000000 08:01 696563 /usr/lib/libXi.so.6.1.0 b4311000-b4312000 rw-p 0000c000 08:01 696563 /usr/lib/libXi.so.6.1.0 b4312000-b4316000 r-xp 00000000 08:01 2643553 /usr/lib/libXtst.so.6.1.0 b4316000-b4317000 rw-p 00004000 08:01 2643553 /usr/lib/libXtst.so.6.1.0 b4317000-b431f000 r-xp 00000000 08:01 2640420 /usr/lib/libXrender.so.1.3.0 b431f000-b4320000 rw-p 00007000 08:01 2640420 /usr/lib/libXrender.so.1.3.0 b4320000-b432e000 r-xp 00000000 08:01 2643210 /usr/lib/libXext.so.6.4.0 b432e000-b432f000 rw-p 0000d000 08:01 2643210 /usr/lib/libXext.so.6.4.0 b432f000-b4347000 r--s 00000000 08:01 1007626 /home/dominik/.fontconfig/da5476bf6924ef9fc543d03ebbce3132-le32d4.cache-3 b4347000-b434e000 r--s 00102000 08:01 2973952 /usr/lib/jvm/java-6-openjdk/jre/lib/resources.jar b434e000-b4356000 r--s 00066000 08:01 2681843 /usr/share/java/gnome-java-bridge.jar b4356000-b4357000 ---p 00000000 00:00 0 b4357000-b43d7000 rw-p 00000000 00:00 0 b43d7000-b43da000 ---p 00000000 00:00 0 b43da000-b4428000 rw-p 00000000 00:00 0 b4428000-b442b000 ---p 00000000 00:00 0 b442b000-b44a9000 rw-p 00000000 00:00 0 b44a9000-b44ac000 ---p 00000000 00:00 0 b44ac000-b44fa000 rw-p 00000000 00:00 0 b44fa000-b466f000 r--p 00000000 08:01 2654563 /usr/lib/locale/locale-archive b466f000-b4672000 ---p 00000000 00:00 0 b4672000-b46c0000 rw-p 00000000 00:00 0 b46c0000-b46c3000 ---p 00000000 00:00 0 b46c3000-b4711000 rw-p 00000000 00:00 0 b4711000-b4712000 ---p 00000000 00:00 0 b4712000-b47c5000 rw-p 00000000 00:00 0 b47c5000-b4958000 r--s 03916000 08:01 2973956 /usr/lib/jvm/java-6-openjdk/jre/lib/rt.jar b4958000-b4966000 rw-p 00000000 00:00 0 b4966000-b4980000 rw-p 00000000 00:00 0 b4980000-b4a2b000 rw-p 00000000 00:00 0 b4a2b000-b4ad6000 rw-p 00000000 00:00 0 b4ad6000-b4b2c000 rw-p 00000000 00:00 0 b4b2c000-b4b80000 rw-p 00000000 00:00 0 b4b80000-b4c2c000 rw-p 00000000 00:00 0 b4c2c000-b4cd6000 rw-p 00000000 00:00 0 b4cd6000-b4cdc000 rw-p 00000000 00:00 0 b4cdc000-b4cf6000 rw-p 00000000 00:00 0 b4cf6000-b4d08000 rw-p 00000000 00:00 0 b4d08000-b4d82000 rw-p 00000000 00:00 0 b4d82000-b4eea000 rwxp 00000000 00:00 0 b4eea000-b6d82000 rw-p 00000000 00:00 0 b6d82000-b6d8c000 r-xp 00000000 08:01 2138535 /lib/i686/cmov/libnss_files-2.11.2.so b6d8c000-b6d8d000 r--p 00009000 08:01 2138535 /lib/i686/cmov/libnss_files-2.11.2.so b6d8d000-b6d8e000 rw-p 0000a000 08:01 2138535 /lib/i686/cmov/libnss_files-2.11.2.so b6d8e000-b6d96000 r-xp 00000000 08:01 2138524 /lib/i686/cmov/libnss_nis-2.11.2.so b6d96000-b6d97000 r--p 00008000 08:01 2138524 /lib/i686/cmov/libnss_nis-2.11.2.so b6d97000-b6d98000 rw-p 00009000 08:01 2138524 /lib/i686/cmov/libnss_nis-2.11.2.so b6d98000-b6d9e000 r-xp 00000000 08:01 2138520 /lib/i686/cmov/libnss_compat-2.11.2.so b6d9e000-b6d9f000 r--p 00006000 08:01 2138520 /lib/i686/cmov/libnss_compat-2.11.2.so b6d9f000-b6da0000 rw-p 00007000 08:01 2138520 /lib/i686/cmov/libnss_compat-2.11.2.so b6da0000-b6db3000 r-xp 00000000 08:01 2138536 /lib/i686/cmov/libnsl-2.11.2.so b6db3000-b6db4000 r--p 00012000 08:01 2138536 /lib/i686/cmov/libnsl-2.11.2.so b6db4000-b6db5000 rw-p 00013000 08:01 2138536 /lib/i686/cmov/libnsl-2.11.2.so b6db5000-b6db7000 rw-p 00000000 00:00 0 b6db7000-b6dba000 r--s 0000f000 08:01 2973939 /usr/lib/jvm/java-6-openjdk/jre/lib/ext/pulse-java.jar b6dba000-b6dc0000 rw-p 00000000 00:00 0 b6dc0000-b6dc6000 r-xp 00000000 08:01 2982276 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libzip.so b6dc6000-b6dc7000 rw-p 00006000 08:01 2982276 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libzip.so b6dc7000-b6dcf000 rw-s 00000000 08:01 1876226 /tmp/hsperfdata_dominik/22616 b6dcf000-b6df2000 r-xp 00000000 08:01 2982272 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libjava.so b6df2000-b6df4000 rw-p 00023000 08:01 2982272 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libjava.so b6df4000-b6dfb000 r-xp 00000000 08:01 2138527 /lib/i686/cmov/librt-2.11.2.so b6dfb000-b6dfc000 r--p 00006000 08:01 2138527 /lib/i686/cmov/librt-2.11.2.so b6dfc000-b6dfd000 rw-p 00007000 08:01 2138527 /lib/i686/cmov/librt-2.11.2.so b6dfd000-b6e00000 ---p 00000000 00:00 0 b6e00000-b6e4e000 rw-p 00000000 00:00 0 b6e4e000-b6e72000 r-xp 00000000 08:01 2138521 /lib/i686/cmov/libm-2.11.2.so b6e72000-b6e73000 r--p 00023000 08:01 2138521 /lib/i686/cmov/libm-2.11.2.so b6e73000-b6e74000 rw-p 00024000 08:01 2138521 /lib/i686/cmov/libm-2.11.2.so b6e74000-b7286000 r-xp 00000000 08:01 2990549 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/client/libjvm.so b7286000-b72a9000 rw-p 00411000 08:01 2990549 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/client/libjvm.so b72a9000-b76c7000 rw-p 00000000 00:00 0 b76c7000-b7807000 r-xp 00000000 08:01 2138537 /lib/i686/cmov/libc-2.11.2.so b7807000-b7809000 r--p 0013f000 08:01 2138537 /lib/i686/cmov/libc-2.11.2.so b7809000-b780a000 rw-p 00141000 08:01 2138537 /lib/i686/cmov/libc-2.11.2.so b780a000-b780d000 rw-p 00000000 00:00 0 b780d000-b780f000 r-xp 00000000 08:01 2138529 /lib/i686/cmov/libdl-2.11.2.so b780f000-b7810000 r--p 00001000 08:01 2138529 /lib/i686/cmov/libdl-2.11.2.so b7810000-b7811000 rw-p 00002000 08:01 2138529 /lib/i686/cmov/libdl-2.11.2.so b7811000-b7814000 r-xp 00000000 08:01 2990550 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/jli/libjli.so b7814000-b7815000 rw-p 00002000 08:01 2990550 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/jli/libjli.so b7815000-b782a000 r-xp 00000000 08:01 2138526 /lib/i686/cmov/libpthread-2.11.2.so b782a000-b782b000 r--p 00014000 08:01 2138526 /lib/i686/cmov/libpthread-2.11.2.so b782b000-b782c000 rw-p 00015000 08:01 2138526 /lib/i686/cmov/libpthread-2.11.2.so b782c000-b782f000 rw-p 00000000 00:00 0 b782f000-b7842000 r-xp 00000000 08:01 2640022 /usr/lib/libz.so.1.2.3.4 b7842000-b7843000 rw-p 00013000 08:01 2640022 /usr/lib/libz.so.1.2.3.4 b7843000-b7845000 r--s 0000b000 08:01 4368058 /home/dominik/Downloads/Minecraft.jar b7845000-b784c000 r-xp 00000000 08:01 2990551 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/native_threads/libhpi.so b784c000-b784d000 rw-p 00006000 08:01 2990551 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/native_threads/libhpi.so b784d000-b784e000 rw-p 00000000 00:00 0 b784e000-b784f000 r--p 00000000 00:00 0 b784f000-b785a000 r-xp 00000000 08:01 2982452 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libverify.so b785a000-b785b000 rw-p 0000b000 08:01 2982452 /usr/lib/jvm/java-6-openjdk/jre/lib/i386/libverify.so b785b000-b785d000 rw-p 00000000 00:00 0 b785d000-b785e000 r-xp 00000000 00:00 0 [vdso] b785e000-b7879000 r-xp 00000000 08:01 2123342 /lib/ld-2.11.2.so b7879000-b787a000 r--p 0001a000 08:01 2123342 /lib/ld-2.11.2.so b787a000-b787b000 rw-p 0001b000 08:01 2123342 /lib/ld-2.11.2.so bfbf3000-bfc08000 rw-p 00000000 00:00 0 [stack] VM Arguments: jvm_args: -Xmx1024M -Xms512M java_command: net.minecraft.LauncherFrame Launcher Type: SUN_STANDARD Environment Variables: PATH=/usr/local/bin:/usr/bin:/bin:/usr/games USERNAME=dominik LD_LIBRARY_PATH=/usr/lib/jvm/java-6-openjdk/jre/lib/i386/client:/usr/lib/jvm/java-6-openjdk/jre/lib/i386:/usr/lib/jvm/java-6-openjdk/jre/../lib/i386 SHELL=/bin/bash DISPLAY=:0.0 Signal Handlers: SIGSEGV: [libjvm.so+0x3ad310], sa_mask[0]=0x7ffbfeff, sa_flags=0x10000004 SIGBUS: [libjvm.so+0x3ad310], sa_mask[0]=0x7ffbfeff, sa_flags=0x10000004 SIGFPE: [libjvm.so+0x2d7940], sa_mask[0]=0x7ffbfeff, sa_flags=0x10000004 SIGPIPE: [libjvm.so+0x2d7940], sa_mask[0]=0x7ffbfeff, sa_flags=0x10000004 SIGXFSZ: [libjvm.so+0x2d7940], sa_mask[0]=0x7ffbfeff, sa_flags=0x10000004 SIGILL: [libjvm.so+0x2d7940], sa_mask[0]=0x7ffbfeff, sa_flags=0x10000004 SIGUSR1: SIG_DFL, sa_mask[0]=0x00000000, sa_flags=0x00000000 SIGUSR2: [libjvm.so+0x2d7090], sa_mask[0]=0x00000000, sa_flags=0x10000004 SIGHUP: [libjvm.so+0x2d9640], sa_mask[0]=0x7ffbfeff, sa_flags=0x10000004 SIGINT: [libjvm.so+0x2d9640], sa_mask[0]=0x7ffbfeff, sa_flags=0x10000004 SIGTERM: [libjvm.so+0x2d9640], sa_mask[0]=0x7ffbfeff, sa_flags=0x10000004 SIGQUIT: [libjvm.so+0x2d9640], sa_mask[0]=0x7ffbfeff, sa_flags=0x10000004 --------------- S Y S T E M --------------- OS:squeeze/sid uname:Linux 2.6.32-5-686 #1 SMP Fri Dec 10 16:12:40 UTC 2010 i686 libc:glibc 2.11.2 NPTL 2.11.2 rlimit: STACK 8192k, CORE 0k, NPROC infinity, NOFILE 1024, AS infinity load average:0.96 0.63 0.58 CPU:total 1 (1 cores per cpu, 1 threads per core) family 15 model 6 stepping 4, cmov, cx8, fxsr, mmx, sse, sse2, sse3 Memory: 4k page, physical 1814332k(54480k free), swap 3229024k(3221848k free) vm_info: OpenJDK Client VM (16.0-b13) for linux-x86 JRE (1.6.0_18-b18), built on Nov 30 2010 13:22:29 by "doko" with gcc 4.4.5 time: Thu Jan 6 13:38:57 2011 elapsed time: 46 seconds -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Thu Jan 6 04:44:05 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 06 Jan 2011 12:44:05 +0000 Subject: [Bug 611] Minecraft Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=611 losderio at freenet.de changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Minecr |Minecraft -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From jvanek at redhat.com Thu Jan 6 05:16:46 2011 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 06 Jan 2011 14:16:46 +0100 Subject: Review request: Version tag was cause of failed rpm build of visualvm 1.3.2 Message-ID: <4D25C0BE.7000905@redhat.com> # HG changeset patch # User Jiri Vanek # Date 1294319582 -3600 # Node ID df40da40c697d8d5cb3513bf9f9559d02279f346 # Parent ba2ccec163d04ec94ac31ee75cad10d1b7d8f6ee f14 refused Version 1.1pre for 1.3.1 rpm build. Removed Version tag from dektop file diff -r ba2ccec163d0 -r df40da40c697 visualvm.desktop.in --- a/visualvm.desktop.in Thu Oct 14 22:40:23 2010 +0100 +++ b/visualvm.desktop.in Thu Jan 06 14:13:02 2011 +0100 @@ -6,4 +6,3 @@ Terminal=false Type=Application Categories=Development;Java; -Version=@PACKAGE_VERSION@ From jvanek at redhat.com Thu Jan 6 05:18:41 2011 From: jvanek at redhat.com (Jiri Vanek) Date: Thu, 06 Jan 2011 14:18:41 +0100 Subject: Fwd: Review request: Version tag was cause of failed rpm build of visualvm 1.3.2 Message-ID: <4D25C131.4040708@redhat.com> sorry for typo. For visualvm 1.3.1 From ptisnovs at redhat.com Thu Jan 6 05:54:54 2011 From: ptisnovs at redhat.com (Pavel Tisnovsky) Date: Thu, 06 Jan 2011 14:54:54 +0100 Subject: Review request: Version tag was cause of failed rpm build of visualvm 1.3.2 In-Reply-To: <4D25C0BE.7000905@redhat.com> References: <4D25C0BE.7000905@redhat.com> Message-ID: <4D25C9AE.7070909@redhat.com> Jiri Vanek wrote: > # HG changeset patch > # User Jiri Vanek > # Date 1294319582 -3600 > # Node ID df40da40c697d8d5cb3513bf9f9559d02279f346 > # Parent ba2ccec163d04ec94ac31ee75cad10d1b7d8f6ee > f14 refused Version 1.1pre for 1.3.1 rpm build. Removed Version tag from > dektop file > > diff -r ba2ccec163d0 -r df40da40c697 visualvm.desktop.in > --- a/visualvm.desktop.in Thu Oct 14 22:40:23 2010 +0100 > +++ b/visualvm.desktop.in Thu Jan 06 14:13:02 2011 +0100 > @@ -6,4 +6,3 @@ > Terminal=false > Type=Application > Categories=Development;Java; > -Version=@PACKAGE_VERSION@ Hi Jiri, looks ok for me. Pavel From jvanek at icedtea.classpath.org Thu Jan 6 05:56:28 2011 From: jvanek at icedtea.classpath.org (jvanek at icedtea.classpath.org) Date: Thu, 06 Jan 2011 13:56:28 +0000 Subject: /hg/visualvm: f14 refused Version 1.1pre for 1.3.1 rpm build. Re... Message-ID: changeset df40da40c697 in /hg/visualvm details: http://icedtea.classpath.org/hg/visualvm?cmd=changeset;node=df40da40c697 author: Jiri Vanek date: Thu Jan 06 14:13:02 2011 +0100 f14 refused Version 1.1pre for 1.3.1 rpm build. Removed Version tag from dektop file diffstat: 1 file changed, 1 deletion(-) visualvm.desktop.in | 1 - diffs (8 lines): diff -r ba2ccec163d0 -r df40da40c697 visualvm.desktop.in --- a/visualvm.desktop.in Thu Oct 14 22:40:23 2010 +0100 +++ b/visualvm.desktop.in Thu Jan 06 14:13:02 2011 +0100 @@ -6,4 +6,3 @@ Terminal=false Terminal=false Type=Application Categories=Development;Java; -Version=@PACKAGE_VERSION@ From bugzilla-daemon at icedtea.classpath.org Thu Jan 6 08:43:39 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 06 Jan 2011 16:43:39 +0000 Subject: [Bug 610] SIGSEGV (0xb) at pc=0xb70254c7, pid=7087, tid=2339584880 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=610 dlila at redhat.com changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |dlila at redhat.com ------- Comment #1 from dlila at redhat.com 2011-01-06 16:43 ------- Hello. Could you please give us more information on how to reproduce this problem (such as what application was being run)? Thank you, Denis. -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Thu Jan 6 09:12:49 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 06 Jan 2011 17:12:49 +0000 Subject: [Bug 610] SIGSEGV (0xb) at pc=0xb70254c7, pid=7087, tid=2339584880 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=610 ------- Comment #2 from pyro_maniac at web.de 2011-01-06 17:12 ------- @ Dennis Lila Sorry i missed to add that. I was using JDownloader and i get that error every time i use it. -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Thu Jan 6 09:57:02 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 06 Jan 2011 17:57:02 +0000 Subject: [Bug 610] SIGSEGV (0xb) at pc=0xb70254c7, pid=7087, tid=2339584880 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=610 ------- Comment #3 from dlila at redhat.com 2011-01-06 17:57 ------- Hi Jens Could you tell us the steps you take to make it crash? Just starting up JDownloader doesn't do it (obviously). -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Thu Jan 6 10:10:22 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 06 Jan 2011 18:10:22 +0000 Subject: [Bug 610] SIGSEGV (0xb) at pc=0xb70254c7, pid=7087, tid=2339584880 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=610 ------- Comment #4 from pyro_maniac at web.de 2011-01-06 18:10 ------- I can not describe the inner actions. My way to reproduce it is to just start jdownloader with a list of download tasks in and start it. I didn't yet found a specific link or hoster which crashes it. -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Thu Jan 6 10:34:06 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 06 Jan 2011 18:34:06 +0000 Subject: [Bug 610] SIGSEGV (0xb) at pc=0xb70254c7, pid=7087, tid=2339584880 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=610 ------- Comment #5 from dlila at redhat.com 2011-01-06 18:34 ------- Has JDownloader ever worked for you, or did this problem start occurring after you tried downloading some particular file? I ask because if it's the latter I might be able to reproduce it if I had the list of files you're trying to download. It would also be nice if you could somehow send me your ~/.jd directory. If the crash is happening because of some saved state, that should let me reproduce it. -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Thu Jan 6 11:24:04 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 06 Jan 2011 19:24:04 +0000 Subject: [Bug 610] SIGSEGV (0xb) at pc=0xb70254c7, pid=7087, tid=2339584880 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=610 ------- Comment #6 from pyro_maniac at web.de 2011-01-06 19:24 ------- JDownloader worked before but i dont know if i used the same version of icedtea. I will try to get a reproducable link. -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From omajid at redhat.com Thu Jan 6 15:24:28 2011 From: omajid at redhat.com (Omair Majid) Date: Thu, 06 Jan 2011 18:24:28 -0500 Subject: RFC: Fix incorrect selection of user-level trusted client certificate store Message-ID: <4D264F2C.8010503@redhat.com> Hi, The attached patch fixes a typo which causes the system-level keystore to be selected instead of the user-level keystore. Ok for HEAD and 1.0? Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: fix-client-type-typo.patch Type: text/x-patch Size: 683 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110106/e64b8836/fix-client-type-typo.patch From dbhole at redhat.com Thu Jan 6 15:25:32 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Thu, 6 Jan 2011 18:25:32 -0500 Subject: RFC: Fix incorrect selection of user-level trusted client certificate store In-Reply-To: <4D264F2C.8010503@redhat.com> References: <4D264F2C.8010503@redhat.com> Message-ID: <20110106232531.GE31325@redhat.com> * Omair Majid [2011-01-06 18:24]: > Hi, > > The attached patch fixes a typo which causes the system-level > keystore to be selected instead of the user-level keystore. > > Ok for HEAD and 1.0? > Looks fine to me. Okay for both 1.0 and HEAD. Cheers, Deepak > Cheers, > Omair > diff -r 94ec09d9d634 netx/net/sourceforge/jnlp/security/KeyStores.java > --- a/netx/net/sourceforge/jnlp/security/KeyStores.java Tue Jan 04 15:22:41 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/security/KeyStores.java Thu Jan 06 18:18:42 2011 -0500 > @@ -262,7 +262,7 @@ > configKey = DeploymentConfiguration.KEY_USER_TRUSTED_CERTS; > break; > case CLIENT_CERTS: > - configKey = DeploymentConfiguration.KEY_SYSTEM_TRUSTED_CLIENT_CERTS; > + configKey = DeploymentConfiguration.KEY_USER_TRUSTED_CLIENT_CERTS; > break; > } > break; From ahughes at redhat.com Thu Jan 6 16:59:35 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 7 Jan 2011 00:59:35 +0000 Subject: Build failed in Hudson: IcedTea6hgTargetTesting #108 In-Reply-To: <1294312366.4438.15.camel@springer.wildebeest.org> References: <919265566.1731294212046280.JavaMail.nighttester@toadeater> <2011632679.1741294298443575.JavaMail.nighttester@toadeater> <1294312366.4438.15.camel@springer.wildebeest.org> Message-ID: <20110107005935.GE7065@rivendell.middle-earth.co.uk> On 12:12 Thu 06 Jan , Mark Wielaard wrote: > Hi Andrew, > > On Thu, 2011-01-06 at 02:20 -0500, Hudson Admin wrote: > > [...] > > patching file openjdk/jdk/src/share/classes/com/sun/script/javascript/RhinoCompiledScript.java > > Checking patches/openjdk/6725214-direct3d-01.patch > > 1 out of 2 hunks FAILED -- saving rejects to file openjdk/jdk/make/common/shared/Platform.gmk.rej > > 1 out of 2 hunks FAILED -- saving rejects to file openjdk/jdk/make/sun/xawt/mapfile-vers.rej > > 1 out of 3 hunks FAILED -- saving rejects to file openjdk/jdk/src/share/classes/sun/java2d/SunGraphicsEnvironment.java.rej > > ERROR patch patches/openjdk/6725214-direct3d-01.patch FAILED! > > WARNING make clean-patch before retrying a fix > > make: *** [stamps/patch.stamp] Error 2 > > + exit 1 > > Could you take a look at why this is failing? It seems to have failed in > exactly the same way for a couple of days now, but I haven't seen this > failure on other setups. > Do you have other setups that build the icedtea6-hg tree? I'm aware of this. It needs syncing with OpenJDK6 upstream again. I'll look when I have a clean OpenJDK6 tree to test with. > Thanks, > > Mark > -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Thu Jan 6 16:59:58 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 7 Jan 2011 00:59:58 +0000 Subject: Build failed in Hudson: IcedTea6hgTargetTesting #108 In-Reply-To: <20110107005935.GE7065@rivendell.middle-earth.co.uk> References: <919265566.1731294212046280.JavaMail.nighttester@toadeater> <2011632679.1741294298443575.JavaMail.nighttester@toadeater> <1294312366.4438.15.camel@springer.wildebeest.org> <20110107005935.GE7065@rivendell.middle-earth.co.uk> Message-ID: <20110107005958.GF7065@rivendell.middle-earth.co.uk> On 00:59 Fri 07 Jan , Dr Andrew John Hughes wrote: > On 12:12 Thu 06 Jan , Mark Wielaard wrote: > > Hi Andrew, > > > > On Thu, 2011-01-06 at 02:20 -0500, Hudson Admin wrote: > > > [...] > > > patching file openjdk/jdk/src/share/classes/com/sun/script/javascript/RhinoCompiledScript.java > > > Checking patches/openjdk/6725214-direct3d-01.patch > > > 1 out of 2 hunks FAILED -- saving rejects to file openjdk/jdk/make/common/shared/Platform.gmk.rej > > > 1 out of 2 hunks FAILED -- saving rejects to file openjdk/jdk/make/sun/xawt/mapfile-vers.rej > > > 1 out of 3 hunks FAILED -- saving rejects to file openjdk/jdk/src/share/classes/sun/java2d/SunGraphicsEnvironment.java.rej > > > ERROR patch patches/openjdk/6725214-direct3d-01.patch FAILED! > > > WARNING make clean-patch before retrying a fix > > > make: *** [stamps/patch.stamp] Error 2 > > > + exit 1 > > > > Could you take a look at why this is failing? It seems to have failed in > > exactly the same way for a couple of days now, but I haven't seen this > > failure on other setups. > > > > Do you have other setups that build the icedtea6-hg tree? > > I'm aware of this. It needs syncing with OpenJDK6 upstream again. > I'll look when I have a clean OpenJDK6 tree to test with. > Of course, someone else is welcome to do it first... ;-) > > Thanks, > > > > Mark > > > > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Thu Jan 6 17:02:55 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 7 Jan 2011 01:02:55 +0000 Subject: Review request: Version tag was cause of failed rpm build of visualvm 1.3.2 In-Reply-To: <4D25C0BE.7000905@redhat.com> References: <4D25C0BE.7000905@redhat.com> Message-ID: <20110107010255.GH7065@rivendell.middle-earth.co.uk> On 14:16 Thu 06 Jan , Jiri Vanek wrote: > # HG changeset patch > # User Jiri Vanek > # Date 1294319582 -3600 > # Node ID df40da40c697d8d5cb3513bf9f9559d02279f346 > # Parent ba2ccec163d04ec94ac31ee75cad10d1b7d8f6ee > f14 refused Version 1.1pre for 1.3.1 rpm build. Removed Version tag from > dektop file > > diff -r ba2ccec163d0 -r df40da40c697 visualvm.desktop.in > --- a/visualvm.desktop.in Thu Oct 14 22:40:23 2010 +0100 > +++ b/visualvm.desktop.in Thu Jan 06 14:13:02 2011 +0100 > @@ -6,4 +6,3 @@ > Terminal=false > Type=Application > Categories=Development;Java; > -Version=@PACKAGE_VERSION@ What exactly is this patch for? -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Thu Jan 6 18:03:14 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 7 Jan 2011 02:03:14 +0000 Subject: Review request: Version tag was cause of failed rpm build of visualvm 1.3.2 In-Reply-To: <20110107010255.GH7065@rivendell.middle-earth.co.uk> References: <4D25C0BE.7000905@redhat.com> <20110107010255.GH7065@rivendell.middle-earth.co.uk> Message-ID: <20110107020314.GK7065@rivendell.middle-earth.co.uk> On 01:02 Fri 07 Jan , Dr Andrew John Hughes wrote: > On 14:16 Thu 06 Jan , Jiri Vanek wrote: > > # HG changeset patch > > # User Jiri Vanek > > # Date 1294319582 -3600 > > # Node ID df40da40c697d8d5cb3513bf9f9559d02279f346 > > # Parent ba2ccec163d04ec94ac31ee75cad10d1b7d8f6ee > > f14 refused Version 1.1pre for 1.3.1 rpm build. Removed Version tag from > > dektop file > > > > diff -r ba2ccec163d0 -r df40da40c697 visualvm.desktop.in > > --- a/visualvm.desktop.in Thu Oct 14 22:40:23 2010 +0100 > > +++ b/visualvm.desktop.in Thu Jan 06 14:13:02 2011 +0100 > > @@ -6,4 +6,3 @@ > > Terminal=false > > Type=Application > > Categories=Development;Java; > > -Version=@PACKAGE_VERSION@ > > What exactly is this patch for? > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 It seems right that 1.1pre should be rejected as pre-releases shouldn't be shipped. Please revert this patch. -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From mark at klomp.org Fri Jan 7 00:15:07 2011 From: mark at klomp.org (mark at klomp.org) Date: Fri, 7 Jan 2011 09:15:07 +0100 (CET) Subject: Build failed in Hudson: IcedTea6hgTargetTesting #108 In-Reply-To: <20110107005935.GE7065@rivendell.middle-earth.co.uk> References: <919265566.1731294212046280.JavaMail.nighttester@toadeater> <2011632679.1741294298443575.JavaMail.nighttester@toadeater> <1294312366.4438.15.camel@springer.wildebeest.org> <20110107005935.GE7065@rivendell.middle-earth.co.uk> Message-ID: <61043.80.101.103.228.1294388107.squirrel@gnu.wildebeest.org> > On 12:12 Thu 06 Jan , Mark Wielaard wrote: >> Could you take a look at why this is failing? It seems to have failed in >> exactly the same way for a couple of days now, but I haven't seen this >> failure on other setups. >> > Do you have other setups that build the icedtea6-hg tree? Aha, OK I missed that this is the icedtea6-hg variant. It would be good to have other autobuilders for it, but I haven't set one up yet. > I'm aware of this. It needs syncing with OpenJDK6 upstream again. > I'll look when I have a clean OpenJDK6 tree to test with. In how far is it diverged from the main icedtea6 tree? Would it be possible to make it a configure option of the main tree? In general I would assume the changes between the tree would normally be minimal. Or am I missing something? Thanks, Mark From omajid at redhat.com Fri Jan 7 04:31:31 2011 From: omajid at redhat.com (Omair Majid) Date: Fri, 07 Jan 2011 07:31:31 -0500 Subject: Review request: Version tag was cause of failed rpm build of visualvm 1.3.2 In-Reply-To: <4D25C0BE.7000905@redhat.com> References: <4D25C0BE.7000905@redhat.com> Message-ID: <4D2707A3.2070006@redhat.com> Hi Jiri, On 01/06/2011 08:16 AM, Jiri Vanek wrote: > # HG changeset patch > # User Jiri Vanek > # Date 1294319582 -3600 > # Node ID df40da40c697d8d5cb3513bf9f9559d02279f346 > # Parent ba2ccec163d04ec94ac31ee75cad10d1b7d8f6ee > f14 refused Version 1.1pre for 1.3.1 rpm build. Removed Version tag from > dektop file > That's because the Version key refers to the version of the Desktop Entry Specification that this file follows, not the version of the program itself. The only supported value, as far as I know, is 1.0. Please see the specification for more information: http://standards.freedesktop.org/desktop-entry-spec/latest/ar01s05.html > diff -r ba2ccec163d0 -r df40da40c697 visualvm.desktop.in > --- a/visualvm.desktop.in Thu Oct 14 22:40:23 2010 +0100 > +++ b/visualvm.desktop.in Thu Jan 06 14:13:02 2011 +0100 > @@ -6,4 +6,3 @@ > Terminal=false > Type=Application > Categories=Development;Java; > -Version=@PACKAGE_VERSION@ Cheers, Omair From ahughes at redhat.com Fri Jan 7 04:33:22 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 7 Jan 2011 12:33:22 +0000 Subject: Build failed in Hudson: IcedTea6hgTargetTesting #108 In-Reply-To: <61043.80.101.103.228.1294388107.squirrel@gnu.wildebeest.org> References: <919265566.1731294212046280.JavaMail.nighttester@toadeater> <2011632679.1741294298443575.JavaMail.nighttester@toadeater> <1294312366.4438.15.camel@springer.wildebeest.org> <20110107005935.GE7065@rivendell.middle-earth.co.uk> <61043.80.101.103.228.1294388107.squirrel@gnu.wildebeest.org> Message-ID: <20110107123322.GA17639@rivendell.middle-earth.co.uk> On 09:15 Fri 07 Jan , mark at klomp.org wrote: > > On 12:12 Thu 06 Jan , Mark Wielaard wrote: > >> Could you take a look at why this is failing? It seems to have failed in > >> exactly the same way for a couple of days now, but I haven't seen this > >> failure on other setups. > >> > > Do you have other setups that build the icedtea6-hg tree? > > Aha, OK I missed that this is the icedtea6-hg variant. It would be good to > have other autobuilders for it, but I haven't set one up yet. > > > I'm aware of this. It needs syncing with OpenJDK6 upstream again. > > I'll look when I have a clean OpenJDK6 tree to test with. > > In how far is it diverged from the main icedtea6 tree? Would it be > possible to make it a configure option of the main tree? In general I > would assume the changes between the tree would normally be minimal. Or am > I missing something? > Think of it as icedtea6 next generation. It contains the changes needed for the next OpenJDK6 tarball when eventually released and is merged to icedtea6 when this happens. So no, it shouldn't be a configure option as that would just bloat the main IcedTea with a lot of conditionals that become invalid over time as the OpenJDK6 Mercurial tree changes. It would date as soon as released. As I said, patches have gone into OpenJDK6 which break those in icedtea6. Someone just needs to build it against current OpenJDK6 hg and fix the issues. I presume it's because someone upstreamed a patch, but also might be due to the binary plug removal from Kelly. > Thanks, > > Mark > -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Fri Jan 7 04:37:49 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 7 Jan 2011 12:37:49 +0000 Subject: Review request: Version tag was cause of failed rpm build of visualvm 1.3.2 In-Reply-To: <4D25C9AE.7070909@redhat.com> References: <4D25C0BE.7000905@redhat.com> <4D25C9AE.7070909@redhat.com> Message-ID: <20110107123749.GB17639@rivendell.middle-earth.co.uk> On 14:54 Thu 06 Jan , Pavel Tisnovsky wrote: > Jiri Vanek wrote: > > # HG changeset patch > > # User Jiri Vanek > > # Date 1294319582 -3600 > > # Node ID df40da40c697d8d5cb3513bf9f9559d02279f346 > > # Parent ba2ccec163d04ec94ac31ee75cad10d1b7d8f6ee > > f14 refused Version 1.1pre for 1.3.1 rpm build. Removed Version tag from > > dektop file > > > > diff -r ba2ccec163d0 -r df40da40c697 visualvm.desktop.in > > --- a/visualvm.desktop.in Thu Oct 14 22:40:23 2010 +0100 > > +++ b/visualvm.desktop.in Thu Jan 06 14:13:02 2011 +0100 > > @@ -6,4 +6,3 @@ > > Terminal=false > > Type=Application > > Categories=Development;Java; > > -Version=@PACKAGE_VERSION@ > > Hi Jiri, > > looks ok for me. > > Pavel Why have you approved this? A ChangeLog wasn't even given, let alone an explanation of what this patch is meant to do. -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at icedtea.classpath.org Fri Jan 7 05:01:14 2011 From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org) Date: Fri, 07 Jan 2011 13:01:14 +0000 Subject: /hg/icedtea-web: fix typo in locating the user-level trusted cli... Message-ID: changeset dc02a605f905 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=dc02a605f905 author: Omair Majid date: Fri Jan 07 08:00:08 2011 -0500 fix typo in locating the user-level trusted client certficate store 2011-01-04 Omair Majid * netx/net/sourceforge/jnlp/security/KeyStores.java (getKeyStoreLocation): Fix typo. Return the user-level certificate store correctly. diffstat: 2 files changed, 7 insertions(+), 1 deletion(-) ChangeLog | 6 ++++++ netx/net/sourceforge/jnlp/security/KeyStores.java | 2 +- diffs (25 lines): diff -r 94ec09d9d634 -r dc02a605f905 ChangeLog --- a/ChangeLog Tue Jan 04 15:22:41 2011 -0500 +++ b/ChangeLog Fri Jan 07 08:00:08 2011 -0500 @@ -1,3 +1,9 @@ 2011-01-04 Omair Majid + + * netx/net/sourceforge/jnlp/security/KeyStores.java + (getKeyStoreLocation): Fix typo. Return the user-level certificate + store correctly. + 2011-01-04 Omair Majid * netx/net/sourceforge/jnlp/runtime/JNLPPolicy.java: Add diff -r 94ec09d9d634 -r dc02a605f905 netx/net/sourceforge/jnlp/security/KeyStores.java --- a/netx/net/sourceforge/jnlp/security/KeyStores.java Tue Jan 04 15:22:41 2011 -0500 +++ b/netx/net/sourceforge/jnlp/security/KeyStores.java Fri Jan 07 08:00:08 2011 -0500 @@ -262,7 +262,7 @@ public final class KeyStores { configKey = DeploymentConfiguration.KEY_USER_TRUSTED_CERTS; break; case CLIENT_CERTS: - configKey = DeploymentConfiguration.KEY_SYSTEM_TRUSTED_CLIENT_CERTS; + configKey = DeploymentConfiguration.KEY_USER_TRUSTED_CLIENT_CERTS; break; } break; From omajid at icedtea.classpath.org Fri Jan 7 05:13:08 2011 From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org) Date: Fri, 07 Jan 2011 13:13:08 +0000 Subject: /hg/release/icedtea-web-1.0: fix typo in locating the user-level... Message-ID: changeset b3647620fa41 in /hg/release/icedtea-web-1.0 details: http://icedtea.classpath.org/hg/release/icedtea-web-1.0?cmd=changeset;node=b3647620fa41 author: Omair Majid date: Fri Jan 07 08:08:41 2011 -0500 fix typo in locating the user-level trusted client certificate store 2011-01-07 Omair Majid * netx/net/sourceforge/jnlp/security/KeyStores.java (getKeyStoreLocation): Fix typo. Return the user-level certificate store correctly. diffstat: 2 files changed, 7 insertions(+), 1 deletion(-) ChangeLog | 6 ++++++ netx/net/sourceforge/jnlp/security/KeyStores.java | 2 +- diffs (28 lines): diff -r 8f4d653aeb0e -r b3647620fa41 ChangeLog --- a/ChangeLog Tue Jan 04 15:26:11 2011 -0500 +++ b/ChangeLog Fri Jan 07 08:08:41 2011 -0500 @@ -2,6 +2,12 @@ 2011-01-04 Omair Majid + + * netx/net/sourceforge/jnlp/security/KeyStores.java + (getKeyStoreLocation): Fix typo. Return the user-level certificate + store correctly. 2010-12-24 Omair Majid diff -r 8f4d653aeb0e -r b3647620fa41 netx/net/sourceforge/jnlp/security/KeyStores.java --- a/netx/net/sourceforge/jnlp/security/KeyStores.java Tue Jan 04 15:26:11 2011 -0500 +++ b/netx/net/sourceforge/jnlp/security/KeyStores.java Fri Jan 07 08:08:41 2011 -0500 @@ -262,7 +262,7 @@ public final class KeyStores { configKey = DeploymentConfiguration.KEY_USER_TRUSTED_CERTS; break; case CLIENT_CERTS: - configKey = DeploymentConfiguration.KEY_SYSTEM_TRUSTED_CLIENT_CERTS; + configKey = DeploymentConfiguration.KEY_USER_TRUSTED_CLIENT_CERTS; break; } break; From ptisnovs at redhat.com Fri Jan 7 06:28:27 2011 From: ptisnovs at redhat.com (Pavel Tisnovsky) Date: Fri, 07 Jan 2011 15:28:27 +0100 Subject: Review request: Version tag was cause of failed rpm build of visualvm 1.3.2 In-Reply-To: <20110107123749.GB17639@rivendell.middle-earth.co.uk> References: <4D25C0BE.7000905@redhat.com> <4D25C9AE.7070909@redhat.com> <20110107123749.GB17639@rivendell.middle-earth.co.uk> Message-ID: <4D27230B.5000203@redhat.com> Dr Andrew John Hughes wrote: > On 14:54 Thu 06 Jan , Pavel Tisnovsky wrote: >> Jiri Vanek wrote: >>> # HG changeset patch >>> # User Jiri Vanek >>> # Date 1294319582 -3600 >>> # Node ID df40da40c697d8d5cb3513bf9f9559d02279f346 >>> # Parent ba2ccec163d04ec94ac31ee75cad10d1b7d8f6ee >>> f14 refused Version 1.1pre for 1.3.1 rpm build. Removed Version tag from >>> dektop file >>> >>> diff -r ba2ccec163d0 -r df40da40c697 visualvm.desktop.in >>> --- a/visualvm.desktop.in Thu Oct 14 22:40:23 2010 +0100 >>> +++ b/visualvm.desktop.in Thu Jan 06 14:13:02 2011 +0100 >>> @@ -6,4 +6,3 @@ >>> Terminal=false >>> Type=Application >>> Categories=Development;Java; >>> -Version=@PACKAGE_VERSION@ >> Hi Jiri, >> >> looks ok for me. >> >> Pavel > > Why have you approved this? A ChangeLog wasn't even given, let alone an explanation of what this patch is meant to do. Hi Andrew, well, I discussed about this issue with Jiri, so I knew why he did this change before he post this mail. Pavel From andrew at icedtea.classpath.org Fri Jan 7 08:24:45 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Fri, 07 Jan 2011 16:24:45 +0000 Subject: /hg/visualvm: Add ChangeLog entry for Jiri. Message-ID: changeset 97e73715aa7e in /hg/visualvm details: http://icedtea.classpath.org/hg/visualvm?cmd=changeset;node=97e73715aa7e author: Andrew John Hughes date: Fri Jan 07 16:24:38 2011 +0000 Add ChangeLog entry for Jiri. 2011-01-07 Jiri Vanek * visualvm.desktop.in: Remove setting of Version which should refer to the desktop file format, and not the package itself. diffstat: 1 file changed, 7 insertions(+) ChangeLog | 7 +++++++ diffs (14 lines): diff -r df40da40c697 -r 97e73715aa7e ChangeLog --- a/ChangeLog Thu Jan 06 14:13:02 2011 +0100 +++ b/ChangeLog Fri Jan 07 16:24:38 2011 +0000 @@ -1,3 +1,10 @@ 2010-10-14 Tomas Hurka + + * visualvm.desktop.in: + Remove setting of Version which should + refer to the desktop file format, and not + the package itself. + 2010-10-14 Tomas Hurka > Support VisualVM 1.3.1. From ahughes at redhat.com Fri Jan 7 13:26:56 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 7 Jan 2011 21:26:56 +0000 Subject: [jvanek@redhat.com: visual vm 1.3.1] Message-ID: <20110107212656.GD17639@rivendell.middle-earth.co.uk> [Forwarding to distro-pkg-dev as public items such as releases should be discussed there] ----- Forwarded message from Jiri Vanek ----- Date: Thu, 06 Jan 2011 15:08:49 +0100 From: Jiri Vanek Subject: visual vm 1.3.1 User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.9) Gecko/20100907 Fedora/3.1.3-1.fc13 Thunderbird/3.1.3 Hi! I had prepared visualvm harness 1.1. and uploaded to download/sources as 1.0 was used to be. I have also updated our package to visualvm to 1.3.1, harness 1.1, profiler 6.9-1. It is awaiting in testrepo, and will be here, untill way "how with" visualvm will be set. Regards J. ----- End forwarded message ----- I don't believe we have even properly discussed a 1.1 release of the VisualVM harness yet, let alone made such a release. Such releases need to be discussed on the public list (distro-pkg-dev) so that everyone has a chance to give their input. I have asked, both by e-mail and on IRC, for you to post any patches you want for such a release but have only seen one so far (http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011643.html). The discussion on https://bugzilla.redhat.com/show_bug.cgi?id=640205 suggests that more changes are needed before we make a new release and a quick look at the spec file in Fedora confirmed this to me. I tried to make some of the necessary changes but found that my work was being ignored by the Fedora build as it was downloading a 1.1 tarball. This seems to have been published to the IcedTea server without any discussion. I'm afraid I've had to remove this in order to proceed with work on VisualVM. Apologies to anyone who may have been depending on it, but it doesn't seem to have been announced anywhere. We provide the VisualVM harness as an upstream project so that all distributions can benefit. Thus, where possible, we expect changes to be pushed to the harness rather than being kept locally in the distribution packages so that more people can benefit. At present, the Fedora spec file for VisualVM seems to have several modifications (patches and the movement of installed files) which can be upstreamed for the benefit of all, and I would like to see these in the repository before any further releases are made. Additionally, when submitting patches for review, please attach them to an e-mail describing fully the motivation for it with a ChangeLog entry. It is very hard to review a patch if we don't know why it is being submitted in the first place or what it does. Thanks, -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Fri Jan 7 13:31:42 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 7 Jan 2011 21:31:42 +0000 Subject: Review request: Version tag was cause of failed rpm build of visualvm 1.3.2 In-Reply-To: <4D2707A3.2070006@redhat.com> References: <4D25C0BE.7000905@redhat.com> <4D2707A3.2070006@redhat.com> Message-ID: <20110107213142.GE17639@rivendell.middle-earth.co.uk> On 07:31 Fri 07 Jan , Omair Majid wrote: > Hi Jiri, > > On 01/06/2011 08:16 AM, Jiri Vanek wrote: > > # HG changeset patch > > # User Jiri Vanek > > # Date 1294319582 -3600 > > # Node ID df40da40c697d8d5cb3513bf9f9559d02279f346 > > # Parent ba2ccec163d04ec94ac31ee75cad10d1b7d8f6ee > > f14 refused Version 1.1pre for 1.3.1 rpm build. Removed Version tag from > > dektop file > > > > That's because the Version key refers to the version of the Desktop > Entry Specification that this file follows, not the version of the > program itself. The only supported value, as far as I know, is 1.0. > Please see the specification for more information: > http://standards.freedesktop.org/desktop-entry-spec/latest/ar01s05.html > Thanks for explaining, Omair. I guess this has been broken for a long time and no-one noticed :-( > > diff -r ba2ccec163d0 -r df40da40c697 visualvm.desktop.in > > --- a/visualvm.desktop.in Thu Oct 14 22:40:23 2010 +0100 > > +++ b/visualvm.desktop.in Thu Jan 06 14:13:02 2011 +0100 > > @@ -6,4 +6,3 @@ > > Terminal=false > > Type=Application > > Categories=Development;Java; > > -Version=@PACKAGE_VERSION@ > > Cheers, > Omair -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Fri Jan 7 13:32:31 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 7 Jan 2011 21:32:31 +0000 Subject: Review request: Version tag was cause of failed rpm build of visualvm 1.3.2 In-Reply-To: <4D27230B.5000203@redhat.com> References: <4D25C0BE.7000905@redhat.com> <4D25C9AE.7070909@redhat.com> <20110107123749.GB17639@rivendell.middle-earth.co.uk> <4D27230B.5000203@redhat.com> Message-ID: <20110107213231.GF17639@rivendell.middle-earth.co.uk> On 15:28 Fri 07 Jan , Pavel Tisnovsky wrote: > Dr Andrew John Hughes wrote: > > On 14:54 Thu 06 Jan , Pavel Tisnovsky wrote: > >> Jiri Vanek wrote: > >>> # HG changeset patch > >>> # User Jiri Vanek > >>> # Date 1294319582 -3600 > >>> # Node ID df40da40c697d8d5cb3513bf9f9559d02279f346 > >>> # Parent ba2ccec163d04ec94ac31ee75cad10d1b7d8f6ee > >>> f14 refused Version 1.1pre for 1.3.1 rpm build. Removed Version tag from > >>> dektop file > >>> > >>> diff -r ba2ccec163d0 -r df40da40c697 visualvm.desktop.in > >>> --- a/visualvm.desktop.in Thu Oct 14 22:40:23 2010 +0100 > >>> +++ b/visualvm.desktop.in Thu Jan 06 14:13:02 2011 +0100 > >>> @@ -6,4 +6,3 @@ > >>> Terminal=false > >>> Type=Application > >>> Categories=Development;Java; > >>> -Version=@PACKAGE_VERSION@ > >> Hi Jiri, > >> > >> looks ok for me. > >> > >> Pavel > > > > Why have you approved this? A ChangeLog wasn't even given, let alone an explanation of what this patch is meant to do. > > Hi Andrew, > > well, I discussed about this issue with Jiri, so I knew why he did this > change before he post this mail. > Yeah, that just doesn't help the rest of us :-D And no change should be committed without a ChangeLog. > Pavel -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From andrew at icedtea.classpath.org Fri Jan 7 18:39:43 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Sat, 08 Jan 2011 02:39:43 +0000 Subject: /hg/icedtea6-hg: 36 new changesets Message-ID: changeset 31705b7b612c in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=31705b7b612c author: ptisnovs date: Tue Nov 16 16:02:46 2010 +0100 Correction of testcase java/awt/FontClass/CreateFont/DeleteFont. The test now ignores directory created by HS. changeset 8ab7d435a672 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=8ab7d435a672 author: Andrew John Hughes date: Fri Nov 19 13:35:01 2010 +0000 Use IcedTea server for CACAO drops. 2010-11-19 Andrew John Hughes * Makefile.am: Add download-cacao alias. (CACAO_BASE_URL): Switch to using IcedTea server for CACAO drops too. (CACAO_URL): Likewise. changeset c3803fc3edac in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=c3803fc3edac author: Andrew John Hughes date: Fri Nov 19 22:23:15 2010 +0000 Fix a memory leak in the XRender pipeline. 2010-11-19 Andrew John Hughes * Makefile.am: Add new patch. * patches/xrender-gc-cleanup.patch: Fix memory leak in XRender pipeline. changeset 789ec2d452bd in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=789ec2d452bd author: doko at ubuntu.com date: Mon Nov 22 04:51:01 2010 +0100 Add shark alias when building zero with shark support on hotspot archs. Without the alias, -shark just gets ignored and defaults to the hotspot vm, which is unexpected. 2010-11-22 Matthias Klose * Makefile.am (stamps/add-zero.stamp): Add shark alias when building zero with shark support on hotspot archs. changeset 4aef376b7123 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=4aef376b7123 author: ptisnovs date: Tue Nov 23 11:39:48 2010 +0100 Corrected JTreg harness - this tool now accepts "process" flag for "compile" tag and also correctly sets properties during the "compile" phase. changeset c80d9c5bbe27 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=c80d9c5bbe27 author: Andrew John Hughes date: Wed Nov 24 16:53:20 2010 +0000 Add new releases (1.7.6, 1.8.3, 1.9.2) to NEWS. 2010-11-24 Andrew John Hughes * NEWS: Add 1.7.6, 1.8.3 and 1.9.2 releases. changeset 0aab3837f513 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=0aab3837f513 author: Andrew John Hughes date: Wed Nov 24 22:44:32 2010 +0000 Final plugin and NetX cleanup. 2010-11-24 Andrew John Hughes Final plugin & NetX cleanup. * patches/extensions/netx-umask.patch: Dropped. NetX is no longer in IcedTea6 and IcedTea-Web uses java to do the same thing. * patches/extensions/netx.patch: Remove javaws binary and javax.jnlp documentation production; the requisite classes no longer exist. Move rest to applet_hole.patch. * Makefile.am: (ICEDTEA_PATCHES): Updated. * NEWS: Move NetX and plugin sections for 1.10 to IcedTea-Web. * patches/applet_hole.patch: Remainder of netx.patch which makes AppletViewerPanel accessible. changeset c3150835fe12 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=c3150835fe12 author: doko at ubuntu.com date: Mon Nov 29 08:50:36 2010 +0100 Update params-cast-size_t.patch for hs19 2010-11-29 Matthias Klose * patches/hotspot/hs19/params-cast-size_t.patch: Update for hs19. changeset 19c298cbf34e in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=19c298cbf34e author: doko at ubuntu.com date: Mon Nov 29 14:00:48 2010 +0100 Reapply ia64 build fix from patches/zero/6896043.patch 2010-11-29 Matthias Klose * patches/hotspot/hs19/ia64-fix.patch: Reapply chunk from patches/zero/6896043.patch. changeset 7940436316db in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=7940436316db author: doko at ubuntu.com date: Mon Nov 29 15:54:26 2010 +0100 Add `build' to .hgignore changeset d66a310d5c94 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=d66a310d5c94 author: ptisnovs date: Mon Nov 29 17:15:17 2010 +0100 Regression test fix - setup of SecurityManager to run this test as regular applet but with AWT robot enabled. changeset 0481c6a6d7ed in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=0481c6a6d7ed author: ptisnovs date: Tue Nov 30 18:16:07 2010 +0100 Regression test fix - compilation results are checked against correct .out files. changeset 4dbf4fd42544 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=4dbf4fd42544 author: doko at ubuntu.com date: Wed Dec 01 00:54:22 2010 +0100 Remove obsolete chunk from sparc64 patch 2010-12-01 Matthias Klose * patches/icedtea-sparc64-linux.patch: Remove obsolete chunk. changeset 9f9f4d8947e1 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=9f9f4d8947e1 author: Andrew John Hughes date: Wed Dec 01 15:57:49 2010 +0000 7002666: Eclipse CDT projects crash with compressed oops 2010-12-01 Andrew John Hughes * patches/disable-default-compoops.patch: Removed. * Makefile.am: Replace disable compressed oops workaround with proper fix for 7002666. * patches/openjdk/7002666-eclipse_cdt_oops_crash.patch: Backport of 7002666: Eclipse CDT projects crash with compressed oops * NEWS: Updated. changeset 6bc8c41e508f in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=6bc8c41e508f author: Andrew John Hughes date: Wed Dec 01 17:53:39 2010 +0000 Apply 7002666 to both hs17 and hs19. 2010-12-01 Andrew John Hughes * Makefile.am: Apply 7002666 to both hs17 and hs19. changeset b45cfed4da75 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=b45cfed4da75 author: ptisnovs date: Thu Dec 02 18:14:55 2010 +0100 Removed printing of unnecessary messages from JTreg harness. changeset d6930de9aba6 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=d6930de9aba6 author: Andrew John Hughes date: Fri Dec 03 13:27:58 2010 +0000 Add generic types to Hashtable in PluginAppletViewer to stop warnings in icedtea-web. 2010-12-01 Andrew John Hughes * patches/applet_hole.patch: Add generic types to Hashtable to stop warnings when building icedtea-web. changeset 531713add335 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=531713add335 author: ptisnovs date: Mon Dec 06 11:53:07 2010 +0100 Regression test fix - corrected .out file used for check messages generated by java compiler. changeset aceb60a00782 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=aceb60a00782 author: Denis Lila date: Mon Dec 06 12:37:25 2010 -0500 user: Denis Lila added patches/openjdk/647674 -bad-html-entity-parse.patch changed ChangeLog changed Makefile.am changed NEWS changeset ccb45c2618bd in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=ccb45c2618bd author: Denis Lila date: Mon Dec 06 17:04:54 2010 -0500 user: Denis Lila Fixed bug ids from previous commit. added patches/openjdk/7003777-bad-html-entity-parse.patch changed ChangeLog changed Makefile.am changed NEWS removed patches/openjdk/647674-bad-html-entity-parse.patch changeset 814f715ce323 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=814f715ce323 author: ptisnovs date: Tue Dec 07 12:11:55 2010 +0100 Backport of regression tests fix (sun/security/ssl/sun/net/www/proto col/https/HttpsURLConnection/*entities.java). changeset 589610636e32 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=589610636e32 author: ptisnovs date: Wed Dec 08 17:41:44 2010 +0100 Testcase correction - now the test runtime/6929067/Test6929067.sh works correctly also on x86_64 and other platforms. changeset 8c26dcba8a27 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=8c26dcba8a27 author: Omair Majid date: Fri Dec 10 17:30:05 2010 -0500 Backport S6979979: Rounding error in font sizes selected by the GTK Look and Feel 2010-12-10 Omair Majid Backport S6979979. * NEWS: Updated with fix. * Makefile.am: Apply patch. * patches/openjdk/6979979-gtk_font_size_rounding.patch: New file. Backport of S6979979. changeset b9b77d7c92a7 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=b9b77d7c92a7 author: Denis Lila date: Mon Dec 13 17:45:35 2010 -0500 Backport of 6795356 changeset b27bf2cfbdd7 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=b27bf2cfbdd7 author: ptisnovs date: Tue Dec 14 12:52:52 2010 +0100 Added new regression test used to check rendering engine behaviour. changeset 2a1bf7104cc8 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=2a1bf7104cc8 author: ptisnovs date: Thu Dec 16 18:34:51 2010 +0100 Testcase correction - the test should also work on Gnome with upper panel displayed. changeset 12df222ab029 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=12df222ab029 author: Denis Lila date: Fri Dec 17 09:30:47 2010 -0500 Improved rendering engine test. changeset ae5814009b4e in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=ae5814009b4e author: Denis Lila date: Tue Dec 21 09:22:22 2010 -0500 Backport of 6800846: indexed image printing quality; OOB exception. changeset 1177891197a7 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=1177891197a7 author: Jiri Vanek date: Wed Dec 22 15:56:32 2010 +0100 fixed fonts configuration for rhel 6 changeset ed90513aa469 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=ed90513aa469 author: Jiri Vanek date: Thu Dec 23 12:51:25 2010 +0100 added bugzilas numbers to NEWS changeset 7219bd74962a in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=7219bd74962a author: Jiri Vanek date: Thu Dec 23 14:56:09 2010 +0100 fixed position of bugfixes for rhel fonts patch's bugs numbers. changeset 6ded99cd18d4 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=6ded99cd18d4 author: Mark Wielaard date: Fri Dec 31 21:03:38 2010 +0100 * Makefile.am (ICEDTEA_PATCHES): Add missing backslash. changeset 1121be5e4dbd in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=1121be5e4dbd author: Deepak Bhole date: Tue Jan 04 08:50:11 2011 -0500 Backport S6687968, S6541476, S6782079 iTXt chunk handling for png now works correctly. changeset d2d762ec4dda in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=d2d762ec4dda author: Denis Lila date: Tue Jan 04 16:56:06 2011 -0500 Fixed RH661505 - JPEGs decoder color space recognition problem. changeset a25c22543a4c in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=a25c22543a4c author: Andrew John Hughes date: Fri Jan 07 21:43:31 2011 +0000 Merge changeset f7bd517ec204 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=f7bd517ec204 author: Andrew John Hughes date: Sat Jan 08 02:38:52 2011 +0000 Drop upstreamed patches and fix Direct3D patch broken by Oracle copyright updates. 2011-01-07 Andrew John Hughes * patches/jtreg-TestXEmbedServer-fix.patch, * patches/openjdk/6668231-ssl_cert.patch, * patches/openjdk/6687968-pngimagereader_mem_leak.patch, * patches/openjdk/6795356-proxylazyvalue-leak.patch, * patches/openjdk/6941936-broken-pipe.patch, * patches/openjdk/6943219-failure-in-linux.patch, * patches/openjdk/6951319-sparc_build_fixes.patch, * patches/openjdk/6963870-swing_npe.patch, * patches/openjdk/6979979-gtk_font_size_rounding.patch, * patches/openjdk/6994130-ppc_fix.patch: Drop upstreamed patches. * Makefile.am: Updated with above. * patches/openjdk/6725214-direct3d-01.patch: Recreated due to copyright header changes by Oracle. diffstat: 132 files changed, 7375 insertions(+), 26542 deletions(-) .hgignore | 1 ChangeLog | 417 Makefile.am | 130 NEWS | 67 acinclude.m4 | 4 hotspot.map | 2 patches/661505-jpeg.patch | 16 patches/alpha-fixes.patch | 21 patches/applet_hole.patch | 117 patches/disable-default-compoops.patch | 12 patches/extensions/netx-umask.patch | 164 patches/extensions/netx.patch | 137 patches/fonts-rhel.patch | 148 patches/gcc-suffix.patch | 31 patches/hotspot/hs19/alpha-fixes.patch | 21 patches/hotspot/hs19/gcc-suffix.patch | 31 patches/hotspot/hs19/params-cast-size_t.patch | 284 patches/hotspot/hs19/print_lsb_release.patch | 49 patches/hotspot/hs19/update-bootclasspath.patch | 13 patches/hotspot/original/alpha-fixes.patch | 31 patches/hotspot/original/gcc-suffix.patch | 25 patches/hotspot/original/params-cast-size_t.patch | 274 patches/hotspot/original/print_lsb_release.patch | 48 patches/hotspot/original/update-bootclasspath.patch | 13 patches/ia64-fix.patch | 30 patches/icedtea-jtreg-jrunscript.patch | 12 patches/icedtea-lcms.patch | 25 patches/icedtea-shark-build.patch | 16 patches/icedtea-sparc64-linux.patch | 18 patches/jtreg-6929067-fix.patch | 51 patches/jtreg-DeleteFont.patch | 20 patches/jtreg-T6638712-fix.patch | 30 patches/jtreg-T6650759m-fix.patch | 6 patches/jtreg-WindowWithWarningTest.patch | 50 patches/openjdk/4356282-opentype.patch | 227 patches/openjdk/6438179-systray_check.patch | 92 patches/openjdk/6541476-png-iTXt-chunk.patch | 549 + patches/openjdk/6622432-bigdecimal_performance.patch | 4211 ---------- patches/openjdk/6668231-ssl_cert.patch | 306 patches/openjdk/6678385-window_movement_crasher.patch | 1241 -- patches/openjdk/6721088-awt_window_size.patch | 67 patches/openjdk/6725214-direct3d-01.patch | 667 - patches/openjdk/6782079-png_metadata_oom.patch | 4122 +++++++++ patches/openjdk/6795060-icu_crash.patch | 95 patches/openjdk/6800846-printing-quality.patch | 144 patches/openjdk/6850606-bigdecimal_regression.patch | 144 patches/openjdk/6853592-badwindow-warning-fix.patch | 16 patches/openjdk/6876282-bigdecimal_divide.patch | 89 patches/openjdk/6951319-sparc_build_fixes.patch | 642 - patches/openjdk/6954424-opentype_javadoc.patch | 23 patches/openjdk/6961732-negative_leading.patch | 45 patches/openjdk/6963870-swing_npe.patch | 99 patches/openjdk/6969395-net_bugs.patch | 461 - patches/openjdk/6985992-test_6933784.patch | 43 patches/openjdk/6994130-ppc_fix.patch | 11 patches/openjdk/7002666-eclipse_cdt_oops_crash.patch | 79 patches/openjdk/7003777-bad-html-entity-parse.patch | 80 patches/params-cast-size_t.patch | 295 patches/print_lsb_release.patch | 49 patches/rendering-engine-tests.patch | 375 patches/security/20101012/6559775.patch | 317 patches/security/20101012/6622002.patch | 64 patches/security/20101012/6623943.patch | 138 patches/security/20101012/6891766.patch | 1147 -- patches/security/20101012/6914943.patch | 2129 ----- patches/security/20101012/6925710.patch | 198 patches/security/20101012/6938813.patch | 196 patches/security/20101012/6952017.patch | 50 patches/security/20101012/6952603.patch | 38 patches/security/20101012/6957564.patch | 77 patches/security/20101012/6958060.patch | 15 patches/security/20101012/6961084.patch | 325 patches/security/20101012/6963023.patch | 95 patches/security/20101012/6963285.patch | 20 patches/security/20101012/6963489.patch | 31 patches/security/20101012/6966692.patch | 91 patches/security/20101012/6981426.patch | 24 patches/security/20101012/6990437.patch | 116 patches/update-bootclasspath.patch | 13 patches/xrender-gc-cleanup.patch | 12 shark/hotspot/make/linux/makefiles/shark.make | 32 shark/hotspot/src/cpu/zero/vm/shark_globals_zero.hpp | 62 shark/hotspot/src/share/vm/includeDB_shark | 369 shark/hotspot/src/share/vm/shark/llvmHeaders.hpp | 82 shark/hotspot/src/share/vm/shark/llvmValue.hpp | 62 shark/hotspot/src/share/vm/shark/sharkBlock.cpp | 1260 -- shark/hotspot/src/share/vm/shark/sharkBlock.hpp | 281 shark/hotspot/src/share/vm/shark/sharkBuilder.cpp | 591 - shark/hotspot/src/share/vm/shark/sharkBuilder.hpp | 209 shark/hotspot/src/share/vm/shark/sharkCacheDecache.cpp | 259 shark/hotspot/src/share/vm/shark/sharkCacheDecache.hpp | 417 shark/hotspot/src/share/vm/shark/sharkCodeBuffer.hpp | 87 shark/hotspot/src/share/vm/shark/sharkCompiler.cpp | 340 shark/hotspot/src/share/vm/shark/sharkCompiler.hpp | 119 shark/hotspot/src/share/vm/shark/sharkConstant.cpp | 128 shark/hotspot/src/share/vm/shark/sharkConstant.hpp | 64 shark/hotspot/src/share/vm/shark/sharkContext.cpp | 180 shark/hotspot/src/share/vm/shark/sharkContext.hpp | 187 shark/hotspot/src/share/vm/shark/sharkEntry.hpp | 58 shark/hotspot/src/share/vm/shark/sharkFunction.cpp | 188 shark/hotspot/src/share/vm/shark/sharkFunction.hpp | 111 shark/hotspot/src/share/vm/shark/sharkInliner.cpp | 749 - shark/hotspot/src/share/vm/shark/sharkInliner.hpp | 32 shark/hotspot/src/share/vm/shark/sharkIntrinsics.cpp | 277 shark/hotspot/src/share/vm/shark/sharkIntrinsics.hpp | 54 shark/hotspot/src/share/vm/shark/sharkInvariants.cpp | 37 shark/hotspot/src/share/vm/shark/sharkInvariants.hpp | 167 shark/hotspot/src/share/vm/shark/sharkMemoryManager.cpp | 116 shark/hotspot/src/share/vm/shark/sharkMemoryManager.hpp | 88 shark/hotspot/src/share/vm/shark/sharkNativeWrapper.cpp | 352 shark/hotspot/src/share/vm/shark/sharkNativeWrapper.hpp | 182 shark/hotspot/src/share/vm/shark/sharkRuntime.cpp | 251 shark/hotspot/src/share/vm/shark/sharkRuntime.hpp | 83 shark/hotspot/src/share/vm/shark/sharkStack.cpp | 263 shark/hotspot/src/share/vm/shark/sharkStack.hpp | 290 shark/hotspot/src/share/vm/shark/sharkState.cpp | 389 shark/hotspot/src/share/vm/shark/sharkState.hpp | 188 shark/hotspot/src/share/vm/shark/sharkStateScanner.cpp | 99 shark/hotspot/src/share/vm/shark/sharkStateScanner.hpp | 75 shark/hotspot/src/share/vm/shark/sharkTopLevelBlock.cpp | 1991 ---- shark/hotspot/src/share/vm/shark/sharkTopLevelBlock.hpp | 430 - shark/hotspot/src/share/vm/shark/sharkType.hpp | 112 shark/hotspot/src/share/vm/shark/sharkValue.cpp | 260 shark/hotspot/src/share/vm/shark/sharkValue.hpp | 332 shark/hotspot/src/share/vm/shark/shark_globals.cpp | 29 shark/hotspot/src/share/vm/shark/shark_globals.hpp | 54 test/jtreg/README | 6 test/jtreg/com/sun/javatest/regtest/Action.java | 20 test/jtreg/com/sun/javatest/regtest/CompileAction.java | 142 test/jtreg/com/sun/javatest/regtest/Path.java | 164 test/jtreg/com/sun/javatest/regtest/RegressionScript.java | 15 test/jtreg/com/sun/javatest/regtest/RegressionSecurityManager.java | 2 diffs (truncated from 36542 to 500 lines): diff -r ad1c77031a41 -r f7bd517ec204 .hgignore --- a/.hgignore Fri Nov 12 18:17:22 2010 +0000 +++ b/.hgignore Sat Jan 08 02:38:52 2011 +0000 @@ -8,6 +8,7 @@ netbeans netbeans visualvm bootstrap +build debian lib tools diff -r ad1c77031a41 -r f7bd517ec204 ChangeLog --- a/ChangeLog Fri Nov 12 18:17:22 2010 +0000 +++ b/ChangeLog Sat Jan 08 02:38:52 2011 +0000 @@ -1,3 +1,246 @@ 2010-11-12 Andrew John Hughes + + * patches/jtreg-TestXEmbedServer-fix.patch, + * patches/openjdk/6668231-ssl_cert.patch, + * patches/openjdk/6687968-pngimagereader_mem_leak.patch, + * patches/openjdk/6795356-proxylazyvalue-leak.patch, + * patches/openjdk/6941936-broken-pipe.patch, + * patches/openjdk/6943219-failure-in-linux.patch, + * patches/openjdk/6951319-sparc_build_fixes.patch, + * patches/openjdk/6963870-swing_npe.patch, + * patches/openjdk/6979979-gtk_font_size_rounding.patch, + * patches/openjdk/6994130-ppc_fix.patch: + Drop upstreamed patches. + * Makefile.am: Updated with above. + * patches/openjdk/6725214-direct3d-01.patch: + Recreated due to copyright header changes by Oracle. + +2011-01-04 Denis Lila + + Fixed RH661505. + * NEWS: Updated with fix. + * Makefile.am: Apply patch. + * patches/661506-jpeg.patch: New file. Bug fix. + +2011-01-04 Deepak Bhole + + Backport S6687968, S6541476, S6782079 + * Makefile.am: Add missing "\" to the patch list, update to include + new patches. + * NEWS: Updated. + * patches/openjdk/6687968-pngimagereader_mem_leak.patch: Backport to allow + S6541476 fix to apply cleanly. + * patches/openjdk/6541476-png-iTXt-chunk.patch: Backport to fix iTXt chunk + handling for png images. Also addresses RH665355. + * patches/openjdk/6782079-png_metadata_oom.patch: Backport to fix + potential OOM error when reading metadata on truncated pngs. + +2010-12-31 Mark Wielaard + + * Makefile.am (ICEDTEA_PATCHES): Add missing backslash. + +2010-12-22 Jiri Vanek + + * NEWS: Updated with rh.bugzilas. + * patches/fonts-rhel.patch:repaired rhel 6 fonts configuration. + +2010-12-21 Denis Lila + + Backport S6800846. + * NEWS: Updated with fixes. + * Makefile.am: Apply patch. + * patches/openjdk/6800846-printing-quality.patch: New file. Backport + of S6795356, and fix for RH662230. + +2010-12-17 Denis Lila + Pavel Tisnovsky + + * patches/rendering-engine-tests.patch: + Improved the tests by using the rendering engine explicitly. + +2010-12-16 Pavel Tisnovsky + + * Makefile.am: Add new patch. + * patches/jtreg-TestXEmbedServer-fix.patch: + Testcase correction - the test should also work on Gnome with upper + panel displayed. + +2010-12-14 Denis Lila , Pavel Tisnovsky + + * Makefile.am: Add new patch. + * patches/rendering-engine-tests.patch: + Added new regression test used to check rendering engine behaviour. + +2010-12-13 Denis Lila + + Backport S6795356. + * NEWS: Updated with fixes. + * Makefile.am: Apply patch. + * patches/openjdk/6795356-proxylazyvalue-leak.patch: New file. Backport + of S6795356, and fix for S7004655 and PR590. + +2010-12-10 Omair Majid + + Backport S6979979. + * NEWS: Updated with fix. + * Makefile.am: Apply patch. + * patches/openjdk/6979979-gtk_font_size_rounding.patch: New file. Backport + of S6979979. + +2010-12-08 Pavel Tisnovsky + + * Makefile.am: Add new patch. + * patches/jtreg-6929067-fix.patch: + Testcase correction - now the test works correctly also on x86_64 and + other platforms. + +2010-12-07 Pavel Tisnovsky + + * Makefile.am: + (ICEDTEA_PATCHES): Updated. + * patches/openjdk/6941936-broken-pipe.patch: + * patches/openjdk/6943219-failure-in-linux.patch: + Backport of regression test fix. + +2010-12-06 Denis Lila + + * Makefile.am: + Changed patch name. + * patches/openjdk/647674-bad-html-entity-parse.patch: Removed. + * patches/openjdk/7003777-bad-html-entity-parse.patch: A rename + of the removed patch. + * NEWS: updated with the correct patch names. + +2010-12-06 Denis Lila + + * Makefile.am: + Added patch. + * patches/openjdk/647674-bad-html-entity-parse.patch: + Fixed issue where the parsing of tokens such as "&xyz" in html + documents would insert "&xyz;" in the document. + +2010-12-06 Pavel Tisnovsky + + * Makefile.am: + (ICEDTEA_PATCHES): Updated. + * patches/jtreg-T6650759m-fix.patch: + Regression test fix - corrected .out file used for + check messages generated by java compiler. + +2010-12-01 Andrew John Hughes + + * patches/applet_hole.patch: + Add generic types to Hashtable to stop warnings + when building icedtea-web. + +2010-12-02 Pavel Tisnovsky + + * test/jtreg/com/sun/javatest/regtest/CompileAction.java: + Removed printing of unnecessary messages from JTreg harness. + +2010-12-01 Andrew John Hughes + + * Makefile.am: Apply 7002666 to both hs17 + and hs19. + +2010-12-01 Andrew John Hughes + + * patches/disable-default-compoops.patch: Removed. + * Makefile.am: Replace disable compressed oops workaround + with proper fix for 7002666. + * patches/openjdk/7002666-eclipse_cdt_oops_crash.patch: + Backport of 7002666: Eclipse CDT projects crash with + compressed oops + * NEWS: Updated. + +2010-12-01 Matthias Klose + + * patches/icedtea-sparc64-linux.patch: Remove obsolete chunk. + +2010-11-30 Pavel Tisnovsky + + * Makefile.am: + (ICEDTEA_PATCHES): Updated. + * patches/jtreg-T6638712-fix.patch: + Regression test fix - compilation results are checked against + correct .out files. + +2010-11-29 Pavel Tisnovsky + + * Makefile.am: + (ICEDTEA_PATCHES): Updated. + * patches/jtreg-WindowWithWarningTest.patch: + Regression test fix - setup of SecurityManager to + run this test as regular applet but with AWT robot enabled. + +2010-11-29 Matthias Klose + + * patches/hotspot/hs19/ia64-fix.patch: Reapply chunk from + patches/zero/6896043.patch. + +2010-11-29 Matthias Klose + + * patches/hotspot/hs19/params-cast-size_t.patch: Update for hs19. + +2010-11-24 Andrew John Hughes + + Final plugin & NetX cleanup. + * patches/extensions/netx-umask.patch: + Dropped. NetX is no longer in IcedTea6 + and IcedTea-Web uses java to do the same thing. + * patches/extensions/netx.patch: + Remove javaws binary and javax.jnlp documentation + production; the requisite classes no longer exist. + Move rest to applet_hole.patch. + * Makefile.am: + (ICEDTEA_PATCHES): Updated. + * NEWS: Move NetX and plugin sections for 1.10 + to IcedTea-Web. + * patches/applet_hole.patch: Remainder of netx.patch + which makes AppletViewerPanel accessible. + +2010-11-24 Andrew John Hughes + + * NEWS: Add 1.7.6, 1.8.3 and 1.9.2 releases. + +2010-11-23 Pavel Tisnovsky + + * test/jtreg/README: + Updated. + * test/jtreg/com/sun/javatest/regtest/Path.java: + * test/jtreg/com/sun/javatest/regtest/Action.java: + * test/jtreg/com/sun/javatest/regtest/CompileAction.java: + * test/jtreg/com/sun/javatest/regtest/RegressionScript.java: + * test/jtreg/com/sun/javatest/regtest/RegressionSecurityManager.java: + Corrected JTreg harness - this tool now accepts "process" flag for + "compile" tag and also correctly sets properties during "compile" + phase. + +2010-11-22 Matthias Klose + + * Makefile.am (stamps/add-zero.stamp): Add shark alias when building + zero with shark support on hotspot archs. + +2010-11-19 Andrew John Hughes + + * Makefile.am: Add new patch. + * patches/xrender-gc-cleanup.patch: + Fix memory leak in XRender pipeline. + +2010-11-19 Andrew John Hughes + + * Makefile.am: + Add download-cacao alias. + (CACAO_BASE_URL): Switch to using IcedTea + server for CACAO drops too. + (CACAO_URL): Likewise. + +2010-11-15 Pavel Tisnovsky + + * Makefile.am: Add patch. + * patches/jtreg-DeleteFont.patch: + Testcase correction - the test now ignores directory created by HS. + 2010-11-12 Andrew John Hughes * Makefile.am: @@ -5,9 +248,27 @@ 2010-11-12 Andrew John Hughes + + * patches/openjdk/6622432-bigdecimal_performance.patch, + * patches/openjdk/6850606-bigdecimal_regression.patch, + * patches/openjdk/6876282-bigdecimal_divide.patch: + Removed, upstream. + * Makefile.am: Add patch below. + * patches/6703377-freetypescaler.patch: + Added back, not upstream (this is NOT 6703377, but + an addendum to it). + 2010-11-11 Stefan Ring * Makefile.am: Upgrade CACAO version, use .tar.gz archive + +2010-11-09 Andrew John Hughes + + * patches/6703377-freetypescaler.patch, + * patches/openjdk/6853592-badwindow-warning-fix.patch: + Drop patches applied upstream. + * Makefile.am: Drop above patches. 2010-11-11 Stefan Ring @@ -136,6 +397,110 @@ 2010-10-20 Andrew John Hughes + + * patches/security/20101012/6559775.patch, + * patches/security/20101012/6622002.patch, + * patches/security/20101012/6891766.patch, + * patches/security/20101012/6914943.patch, + * patches/security/20101012/6925710.patch, + * patches/security/20101012/6938813.patch, + * patches/security/20101012/6952017.patch, + * patches/security/20101012/6952603.patch, + * patches/security/20101012/6957564.patch, + * patches/security/20101012/6958060.patch, + * patches/security/20101012/6961084.patch, + * patches/security/20101012/6963023.patch, + * patches/security/20101012/6963285.patch, + * patches/security/20101012/6963489.patch, + * patches/security/20101012/6966692.patch, + * patches/security/20101012/6981426.patch, + * patches/security/20101012/6990437.patch: + Dropped; available upstream. + * Makefile.am: Drop above patches. + * patches/icedtea-lcms.patch: Rejigged against + upstream security patch. + +2010-10-18 Andrew John Hughes + + * patches/hotspot/hs19/alpha-fixes.patch, + * patches/hotspot/hs19/gcc-suffix.patch, + * patches/hotspot/hs19/params-cast-size_t.patch, + * patches/hotspot/hs19/print_lsb_release.patch, + * patches/hotspot/hs19/update-bootclasspath.patch: + Move to patches. hs19 is now the only option. + * patches/hotspot/original/alpha-fixes.patch, + * patches/hotspot/original/gcc-suffix.patch, + * patches/hotspot/original/params-cast-size_t.patch, + * patches/hotspot/original/print_lsb_release.patch, + * patches/hotspot/original/update-bootclasspath.patch: + Dropped; upstream moved from hs17 to hs19. + * patches/icedtea-shark-build.patch: + Applied upstream by Gary Benson. + * patches/security/20101012/6623943.patch: + Applied upstream by Omair Majid. + * shark/hotspot/make/linux/makefiles/shark.make, + * shark/hotspot/src/cpu/zero/vm/shark_globals_zero.hpp, + * shark/hotspot/src/share/vm/includeDB_shark, + * shark/hotspot/src/share/vm/shark/llvmHeaders.hpp, + * shark/hotspot/src/share/vm/shark/llvmValue.hpp, + * shark/hotspot/src/share/vm/shark/sharkBlock.cpp, + * shark/hotspot/src/share/vm/shark/sharkBlock.hpp, + * shark/hotspot/src/share/vm/shark/sharkBuilder.cpp, + * shark/hotspot/src/share/vm/shark/sharkBuilder.hpp, + * shark/hotspot/src/share/vm/shark/sharkCacheDecache.cpp, + * shark/hotspot/src/share/vm/shark/sharkCacheDecache.hpp, + * shark/hotspot/src/share/vm/shark/sharkCodeBuffer.hpp, + * shark/hotspot/src/share/vm/shark/sharkCompiler.cpp, + * shark/hotspot/src/share/vm/shark/sharkCompiler.hpp, + * shark/hotspot/src/share/vm/shark/sharkConstant.cpp, + * shark/hotspot/src/share/vm/shark/sharkConstant.hpp, + * shark/hotspot/src/share/vm/shark/sharkContext.cpp, + * shark/hotspot/src/share/vm/shark/sharkContext.hpp, + * shark/hotspot/src/share/vm/shark/sharkEntry.hpp, + * shark/hotspot/src/share/vm/shark/sharkFunction.cpp, + * shark/hotspot/src/share/vm/shark/sharkFunction.hpp, + * shark/hotspot/src/share/vm/shark/sharkInliner.cpp, + * shark/hotspot/src/share/vm/shark/sharkInliner.hpp, + * shark/hotspot/src/share/vm/shark/sharkIntrinsics.cpp, + * shark/hotspot/src/share/vm/shark/sharkIntrinsics.hpp, + * shark/hotspot/src/share/vm/shark/sharkInvariants.cpp, + * shark/hotspot/src/share/vm/shark/sharkInvariants.hpp, + * shark/hotspot/src/share/vm/shark/sharkMemoryManager.cpp, + * shark/hotspot/src/share/vm/shark/sharkMemoryManager.hpp, + * shark/hotspot/src/share/vm/shark/sharkNativeWrapper.cpp, + * shark/hotspot/src/share/vm/shark/sharkNativeWrapper.hpp, + * shark/hotspot/src/share/vm/shark/sharkRuntime.cpp, + * shark/hotspot/src/share/vm/shark/sharkRuntime.hpp, + * shark/hotspot/src/share/vm/shark/sharkStack.cpp, + * shark/hotspot/src/share/vm/shark/sharkStack.hpp, + * shark/hotspot/src/share/vm/shark/sharkState.cpp, + * shark/hotspot/src/share/vm/shark/sharkState.hpp, + * shark/hotspot/src/share/vm/shark/sharkStateScanner.cpp, + * shark/hotspot/src/share/vm/shark/sharkStateScanner.hpp, + * shark/hotspot/src/share/vm/shark/sharkTopLevelBlock.cpp, + * shark/hotspot/src/share/vm/shark/sharkTopLevelBlock.hpp, + * shark/hotspot/src/share/vm/shark/sharkType.hpp, + * shark/hotspot/src/share/vm/shark/sharkValue.cpp, + * shark/hotspot/src/share/vm/shark/sharkValue.hpp, + * shark/hotspot/src/share/vm/shark/shark_globals.cpp, + * shark/hotspot/src/share/vm/shark/shark_globals.hpp: + Shark is in HotSpot 19. + * Makefile.am: + (ICEDTEA_PATCHES): Remove $(HSBUILD) special casing. + Remove conditional !WITH_ALT_HSBUILD patches. + (ports): Drop !WITH_ALT_HSBUILD block. + (clean-ports): Likewise. + * hotspot.map: Remove hs19. + * patches/alpha-fixes.patch, + * patches/gcc-suffix.patch, + * patches/params-cast-size_t.patch, + * patches/print_lsb_release.patch, + * patches/update-bootclasspath.patch: + The hs19 patches moved above. + * acinclude.m4: + (AC_CHECK_WITH_HOTSPOT_BUILD): Default to original. 2010-10-19 Andrew John Hughes @@ -421,7 +786,6 @@ 2010-10-19 Andrew John Hughes + + * patches/icedtea-awt-window-size.patch, + * patches/openjdk/6969395-net_bugs.patch, + * patches/openjdk/6985992-test_6933784.patch: + Dropped; upstreamed. + * Makefile.am: Remove above patches. 2010-09-23 Andrew John Hughes @@ -1023,6 +1395,15 @@ 2010-09-07 Andrew John Hughes + + * patches/openjdk/6438179-systray_check.patch: + Dropped, applied upstream. + * Makefile.am: Drop above patch and those brought + back by merge. Update JAXP tarball. + * patches/openjdk/6951319-sparc_build_fixes.patch: + Remove upstreamed parts. + 2010-09-03 Pavel Tisnovsky * Makefile.am: Fixed indentation, changes spaces to tab. @@ -1072,7 +1453,7 @@ 2010-08-27 Deepak Bhole - * Makefile.am: + * Makefile.am: Add patch. * patches/opengl-jni-fix.patch: Fixed missing JNI link to native function OGLContext.getOGLIdString() which causes @@ -1159,6 +1540,22 @@ 2010-08-13 Andrew John Hughes + + * patches/openjdk/4356282-opentype.patch, + * patches/openjdk/6795060-icu_crash.patch, + * patches/openjdk/6954424-opentype_javadoc.patch: + Dropped, applied upstream. + * Makefile.am: + Remove above patches. + +2010-08-12 Andrew John Hughes + + * patches/openjdk/6678385-window_movement_crasher.patch: + Dropped, applied upstream. + * Makefile.am: + Remove above patch. 2010-08-09 Omair Majid @@ -1200,7 +1597,7 @@ 2010-08-09 Deepak Bhole @@ -1512,6 +1909,12 @@ 2010-07-28 Matthias Klose * NEWS: Add 1.8.1 entry. + +2010-07-26 Andrew John Hughes + + * patches/icedtea-jtreg-jrunscript.patch: + Regenerate after 50002bfcff96 from dcubed being + added to OpenJDK6. 2010-07-26 Andrew John Hughes @@ -1961,6 +2364,12 @@ 2010-07-08 Andrew John Hughes + From andrew at icedtea.classpath.org Fri Jan 7 19:48:25 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Sat, 08 Jan 2011 03:48:25 +0000 Subject: /hg/visualvm: 3 new changesets Message-ID: changeset afb288d37834 in /hg/visualvm details: http://icedtea.classpath.org/hg/visualvm?cmd=changeset;node=afb288d37834 author: Andrew John Hughes date: Sat Jan 08 01:02:33 2011 +0000 Make VisualVM work regardless of where it is installed. 2011-01-07 Andrew John Hughes Make VisualVM work regardless of where it is installed. * Makefile.am: (NBPLATFORM_DIR_COPY): Removed. (install-exec-local): Install configuration to $(sysconfdir) rather than $(libdir)/visualvm/etc. Patch launcher with $(sysconfdir), platform directory, and $(libdir)/visualvm. Patch visualvm.conf with jdkhome. Don't bother copying the platform symlink, just use the original location directly in the configuration file. changeset 307d1a64ee76 in /hg/visualvm details: http://icedtea.classpath.org/hg/visualvm?cmd=changeset;node=307d1a64ee76 author: Andrew John Hughes date: Sat Jan 08 01:12:46 2011 +0000 Install visualvm.desktop into $(datadir)/applications. 2011-01-08 Andrew John Hughes * Makefile.am: (install-exec-local): Install the desktop file into the applications subdirectory. changeset d0293407ac9c in /hg/visualvm details: http://icedtea.classpath.org/hg/visualvm?cmd=changeset;node=d0293407ac9c author: Andrew John Hughes date: Sat Jan 08 02:00:50 2011 +0000 Turn on debugging information for native code. 2011-01-08 Andrew John Hughes * Makefile.am: (nbplatform): Turn on debugging information for native code. diffstat: 2 files changed, 39 insertions(+), 13 deletions(-) ChangeLog | 25 +++++++++++++++++++++++++ Makefile.am | 27 ++++++++++++++------------- diffs (102 lines): diff -r 97e73715aa7e -r d0293407ac9c ChangeLog --- a/ChangeLog Fri Jan 07 16:24:38 2011 +0000 +++ b/ChangeLog Sat Jan 08 02:00:50 2011 +0000 @@ -1,3 +1,28 @@ 2011-01-07 Jiri Vanek + + * Makefile.am: + (nbplatform): Turn on debugging information + for native code. + +2011-01-08 Andrew John Hughes + + * Makefile.am: + (install-exec-local): Install the desktop file + into the applications subdirectory. + +2011-01-07 Andrew John Hughes + + Make VisualVM work regardless of where it is + installed. + * Makefile.am: + (NBPLATFORM_DIR_COPY): Removed. + (install-exec-local): Install configuration + to $(sysconfdir) rather than $(libdir)/visualvm/etc. + Patch launcher with $(sysconfdir), platform directory, + and $(libdir)/visualvm. Patch visualvm.conf with jdkhome. + Don't bother copying the platform symlink, just use the + original location directly in the configuration file. + 2011-01-07 Jiri Vanek * visualvm.desktop.in: diff -r 97e73715aa7e -r d0293407ac9c Makefile.am --- a/Makefile.am Fri Jan 07 16:24:38 2011 +0000 +++ b/Makefile.am Sat Jan 08 02:00:50 2011 +0000 @@ -30,7 +30,6 @@ if VVVERSION_131 VISUALVM_SRC_ZIP=$(VISUALVM_131_SRC_ZIP) VISUALVM_SHA256SUM=$(VISUALVM_131_SHA256SUM) NBPLATFORM_DIR=netbeans/nbbuild/netbeans_visualvm/platform - NBPLATFORM_DIR_COPY=$(NBPLATFORM_DIR) ADDITIONAL_DIRS=profiler.oql PROFILER=profiler else @@ -42,7 +41,6 @@ if VVVERSION_13 VISUALVM_SRC_ZIP=$(VISUALVM_13_SRC_ZIP) VISUALVM_SHA256SUM=$(VISUALVM_13_SHA256SUM) NBPLATFORM_DIR=netbeans/nbbuild/netbeans_visualvm/platform - NBPLATFORM_DIR_COPY=$(NBPLATFORM_DIR) ADDITIONAL_DIRS=profiler.oql PROFILER=profiler else @@ -53,7 +51,6 @@ else VISUALVM_SRC_ZIP=$(VISUALVM_122_SRC_ZIP) VISUALVM_SHA256SUM=$(VISUALVM_122_SHA256SUM) NBPLATFORM_DIR=netbeans/nbbuild/netbeans_visualvm - NBPLATFORM_DIR_COPY=$(NBPLATFORM_DIR)/$(NB_PLATFORM) NBBUILD_PROPERTIES=-Dpermit.jdk6.builds=true -Dbuildnumber=091221-4fc006d17cb1 PROFILER=profiler3 endif @@ -171,7 +168,7 @@ stamps/nbplatform.stamp: stamps/extract- ln -s linux-amd64 netbeans/lib.profiler/release/lib/deployed/jdk15/linux ln -s linux-amd64 netbeans/lib.profiler/release/lib/deployed/jdk16/linux cd netbeans/lib.profiler/native/build && \ - sed -i -e 's#gcc32#$(CC)#' -e 's#-m64#$(ARCHFLAG)#' buildnative-linux64.sh && \ + sed -i -e 's#gcc32#$(CC)#' -e 's#-m64#$(ARCHFLAG)#' -e 's#Wall#Wall -g#' buildnative-linux64.sh && \ JAVA_HOME_15=$(SYSTEM_JDK_DIR) JAVA_HOME_16=$(SYSTEM_JDK_DIR) ./buildnative-linux64.sh JAVA_HOME=$(SYSTEM_JDK_DIR) $(ANT) $(NBBUILD_PROPERTIES) -f netbeans/nbbuild/build.xml bootstrap for dir in lib.profiler lib.profiler.charts lib.profiler.ui lib.profiler.common profiler $(ADDITIONAL_DIRS); do \ @@ -198,20 +195,24 @@ clean-visualvm: install-exec-local: mkdir -p $(DESTDIR)$(bindir) - mkdir -p $(DESTDIR)$(libdir)/visualvm/etc + mkdir -p $(DESTDIR)$(sysconfdir) mkdir -p $(DESTDIR)$(libdir)/visualvm/visualvm - mkdir -p $(DESTDIR)$(datadir) - sed "s/APPNAME=\`basename.*\`/APPNAME=visualvm/" \ - visualvm/launcher/visualvm >> \ + mkdir -p $(DESTDIR)$(datadir)/applications + cat visualvm/launcher/visualvm | \ + sed "s:APPNAME=\`basename.*\`:APPNAME=visualvm:" | \ + sed "s:\$$BASEDIR/etc:$(sysconfdir):" | \ + sed "s:\$$BASEDIR/\$$X:$(libdir)/visualvm/\$$X:" | \ + sed "s:^nbexec=.*:nbexec=$(SYSTEM_NETBEANS_DIR)/$(NB_PLATFORM)/lib/nbexec:" > \ $(DESTDIR)$(bindir)/jvisualvm chmod a+x $(DESTDIR)$(bindir)/jvisualvm - cp visualvm/launcher/visualvm.conf $(DESTDIR)$(libdir)/visualvm/etc - echo visualvm >> $(DESTDIR)$(libdir)/visualvm/etc/visualvm.clusters - echo $(PROFILER) >> $(DESTDIR)$(libdir)/visualvm/etc/visualvm.clusters + sed -e "s:^#jdkhome=.*:jdkhome=\"$(SYSTEM_JDK_DIR)\"":g \ + visualvm/launcher/visualvm.conf > \ + $(DESTDIR)$(sysconfdir)/visualvm.conf + echo visualvm >> $(DESTDIR)$(sysconfdir)/visualvm.clusters + echo $(PROFILER) >> $(DESTDIR)$(sysconfdir)/visualvm.clusters cp -r visualvm/build/cluster/* $(DESTDIR)$(libdir)/visualvm/visualvm - cp -r $(NBPLATFORM_DIR_COPY) $(DESTDIR)$(libdir)/visualvm cp -r netbeans/nbbuild/netbeans_visualvm/$(PROFILER) $(DESTDIR)$(libdir)/visualvm - cp visualvm.desktop $(DESTDIR)$(datadir) + cp visualvm.desktop $(DESTDIR)$(datadir)/applications download-netbeans-profiler: stamps/download-netbeans-profiler.stamp From akurtakov at gmail.com Sat Jan 8 00:17:56 2011 From: akurtakov at gmail.com (akurtakov) Date: Sat, 8 Jan 2011 10:17:56 +0200 Subject: [jvanek@redhat.com: visual vm 1.3.1] In-Reply-To: <20110107212656.GD17639@rivendell.middle-earth.co.uk> References: <20110107212656.GD17639@rivendell.middle-earth.co.uk> Message-ID: On Fri, Jan 7, 2011 at 11:26 PM, Dr Andrew John Hughes wrote: > [Forwarding to distro-pkg-dev as public items such as releases should be discussed there] > > ----- Forwarded message from Jiri Vanek ----- > > Date: Thu, 06 Jan 2011 15:08:49 +0100 > From: Jiri Vanek > Subject: visual vm 1.3.1 > User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.9) Gecko/20100907 Fedora/3.1.3-1.fc13 Thunderbird/3.1.3 > > Hi! > I had prepared visualvm harness 1.1. and uploaded to download/sources > as 1.0 was used to be. > I have also updated our package to visualvm to 1.3.1, harness 1.1, > profiler 6.9-1. > It is awaiting in testrepo, and will be here, untill way "how with" > visualvm ?will be set. > > Regards J. > > ----- End forwarded message ----- > > I don't believe we have even properly discussed a 1.1 release of the > VisualVM harness yet, let alone made such a release. ?Such releases > need to be discussed on the public list (distro-pkg-dev) so that everyone > has a chance to give their input. > > I have asked, both by e-mail and on IRC, for you to post any patches > you want for such a release but have only seen one so far > (http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011643.html). The > discussion on https://bugzilla.redhat.com/show_bug.cgi?id=640205 > suggests that more changes are needed before we make a new release and > a quick look at the spec file in Fedora confirmed this to me. > > I tried to make some of the necessary changes but found that my work > was being ignored by the Fedora build as it was downloading a 1.1 > tarball. ?This seems to have been published to the IcedTea server > without any discussion. ?I'm afraid I've had to remove this in order > to proceed with work on VisualVM. ?Apologies to anyone who may have > been depending on it, but it doesn't seem to have been announced > anywhere. > > We provide the VisualVM harness as an upstream project so that all > distributions can benefit. ?Thus, where possible, we expect changes > to be pushed to the harness rather than being kept locally in the > distribution packages so that more people can benefit. ?At present, > the Fedora spec file for VisualVM seems to have several modifications > (patches and the movement of installed files) which can be upstreamed > for the benefit of all, and I would like to see these in the repository > before any further releases are made. I just want to note that Fedora as a project requires each packager to propose his patches upstream. See http://fedoraproject.org/wiki/PackageMaintainers/WhyUpstream. But we can not guarantee that every packager is doing that nor we can track every patch's path in different tracking systems, mails and so on. This mail is sent to simply disambiguate what does Fedora mean in this mail - upstream first is one of our biggest virtues and I'm not happy seeing it questioned in any way by a single package maintainer actions. Regards, Alexander Kurtakov > > Additionally, when submitting patches for review, please attach them > to an e-mail describing fully the motivation for it with a ChangeLog > entry. ?It is very hard to review a patch if we don't know why it is > being submitted in the first place or what it does. > > Thanks, > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA ?7927 142C 2591 94EF D9D8 > From andrew at icedtea.classpath.org Sat Jan 8 16:43:18 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Sun, 09 Jan 2011 00:43:18 +0000 Subject: /hg/icedtea6: Move OpenJDK patch to correct place with bug ID. ... Message-ID: changeset fd09f4a3b767 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=fd09f4a3b767 author: Andrew John Hughes date: Sun Jan 09 00:43:01 2011 +0000 Move OpenJDK patch to correct place with bug ID. Only apply jtreg-6929067-fix.patch on hs19. 2011-01-07 Andrew John Hughes * patches/jtreg-TestXEmbedServer-fix.patch: Moved to... * Makefile.am: Fix path to above patch. Only apply jtreg-6929067-fix.patch when building hs19. * patches/openjdk/6560348-jtreg-TestXEmbedServer-fix.patch: ... OpenJDK patch with appropriate bug ID. diffstat: 4 files changed, 38 insertions(+), 28 deletions(-) ChangeLog | 10 +++++ Makefile.am | 6 +-- patches/jtreg-TestXEmbedServer-fix.patch | 25 -------------- patches/openjdk/6560348-jtreg-TestXEmbedServer-fix.patch | 25 ++++++++++++++ diffs (101 lines): diff -r d2d762ec4dda -r fd09f4a3b767 ChangeLog --- a/ChangeLog Tue Jan 04 16:56:06 2011 -0500 +++ b/ChangeLog Sun Jan 09 00:43:01 2011 +0000 @@ -1,3 +1,13 @@ 2011-01-04 Denis Lila + + * patches/jtreg-TestXEmbedServer-fix.patch: + Moved to... + * Makefile.am: + Fix path to above patch. Only apply jtreg-6929067-fix.patch + when building hs19. + * patches/openjdk/6560348-jtreg-TestXEmbedServer-fix.patch: + ... OpenJDK patch with appropriate bug ID. + 2011-01-04 Denis Lila Fixed RH661505. diff -r d2d762ec4dda -r fd09f4a3b767 Makefile.am --- a/Makefile.am Tue Jan 04 16:56:06 2011 -0500 +++ b/Makefile.am Sun Jan 09 00:43:01 2011 +0000 @@ -308,11 +308,10 @@ ICEDTEA_PATCHES = \ patches/openjdk/7003777-bad-html-entity-parse.patch \ patches/openjdk/6941936-broken-pipe.patch \ patches/openjdk/6943219-failure-in-linux.patch \ - patches/jtreg-6929067-fix.patch \ patches/openjdk/6979979-gtk_font_size_rounding.patch \ patches/openjdk/6795356-proxylazyvalue-leak.patch \ patches/rendering-engine-tests.patch \ - patches/jtreg-TestXEmbedServer-fix.patch \ + patches/openjdk/6560348-jtreg-TestXEmbedServer-fix.patch \ patches/openjdk/6800846-printing-quality.patch \ patches/openjdk/6687968-pngimagereader_mem_leak.patch \ patches/openjdk/6541476-png-iTXt-chunk.patch \ @@ -323,7 +322,8 @@ ICEDTEA_PATCHES += \ ICEDTEA_PATCHES += \ patches/openjdk/6994130-ppc_fix.patch \ patches/openjdk/6980392-fix_test6581734.patch \ - patches/hotspot/hs19/ia64-fix.patch + patches/hotspot/hs19/ia64-fix.patch \ + patches/jtreg-6929067-fix.patch else ICEDTEA_PATCHES += \ patches/shark_do_nothing_on_stub_frame.patch \ diff -r d2d762ec4dda -r fd09f4a3b767 patches/jtreg-TestXEmbedServer-fix.patch --- a/patches/jtreg-TestXEmbedServer-fix.patch Tue Jan 04 16:56:06 2011 -0500 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,25 +0,0 @@ ---- openjdk-old/jdk/test/java/awt/xembed/server/TestXEmbedServer.java 2010-06-21 23:15:49.000000000 +0200 -+++ openjdk/jdk/test/java/awt/xembed/server/TestXEmbedServer.java 2010-06-21 23:15:49.000000000 +0200 -@@ -31,6 +31,9 @@ - import java.awt.datatransfer.*; - - public abstract class TestXEmbedServer { -+ // vertical position of server AND client windows -+ private static final int VERTICAL_POSITION = 200; -+ - private static final Logger log = Logger.getLogger("test.xembed"); - Frame f; - Canvas client; -@@ -161,10 +164,10 @@ - dummy = new JFrame("Dummy"); - dummy.getContentPane().add(new JButton("Button")); - dummy.setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE); -- dummy.setBounds(0, 0, 100, 100); -+ dummy.setBounds(0, VERTICAL_POSITION, 100, 100); - dummy.setVisible(true); - -- f.setBounds(300, 0, 800, 300); -+ f.setBounds(300, VERTICAL_POSITION, 800, 300); - f.setVisible(true); - } - diff -r d2d762ec4dda -r fd09f4a3b767 patches/openjdk/6560348-jtreg-TestXEmbedServer-fix.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/openjdk/6560348-jtreg-TestXEmbedServer-fix.patch Sun Jan 09 00:43:01 2011 +0000 @@ -0,0 +1,25 @@ +--- openjdk-old/jdk/test/java/awt/xembed/server/TestXEmbedServer.java 2010-06-21 23:15:49.000000000 +0200 ++++ openjdk/jdk/test/java/awt/xembed/server/TestXEmbedServer.java 2010-06-21 23:15:49.000000000 +0200 +@@ -31,6 +31,9 @@ + import java.awt.datatransfer.*; + + public abstract class TestXEmbedServer { ++ // vertical position of server AND client windows ++ private static final int VERTICAL_POSITION = 200; ++ + private static final Logger log = Logger.getLogger("test.xembed"); + Frame f; + Canvas client; +@@ -161,10 +164,10 @@ + dummy = new JFrame("Dummy"); + dummy.getContentPane().add(new JButton("Button")); + dummy.setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE); +- dummy.setBounds(0, 0, 100, 100); ++ dummy.setBounds(0, VERTICAL_POSITION, 100, 100); + dummy.setVisible(true); + +- f.setBounds(300, 0, 800, 300); ++ f.setBounds(300, VERTICAL_POSITION, 800, 300); + f.setVisible(true); + } + From andrew at icedtea.classpath.org Sat Jan 8 16:47:00 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Sun, 09 Jan 2011 00:47:00 +0000 Subject: /hg/icedtea6-hg: 2 new changesets Message-ID: changeset fd09f4a3b767 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=fd09f4a3b767 author: Andrew John Hughes date: Sun Jan 09 00:43:01 2011 +0000 Move OpenJDK patch to correct place with bug ID. Only apply jtreg-6929067-fix.patch on hs19. 2011-01-07 Andrew John Hughes * patches/jtreg-TestXEmbedServer-fix.patch: Moved to... * Makefile.am: Fix path to above patch. Only apply jtreg-6929067-fix.patch when building hs19. * patches/openjdk/6560348-jtreg-TestXEmbedServer-fix.patch: ... OpenJDK patch with appropriate bug ID. changeset 3c63d5967d08 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=3c63d5967d08 author: Andrew John Hughes date: Sun Jan 09 00:46:45 2011 +0000 Merge diffstat: 112 files changed, 990 insertions(+), 27219 deletions(-) ChangeLog | 201 Makefile.am | 105 acinclude.m4 | 4 hotspot.map | 2 patches/alpha-fixes.patch | 21 patches/gcc-suffix.patch | 31 patches/hotspot/hs19/alpha-fixes.patch | 21 patches/hotspot/hs19/gcc-suffix.patch | 31 patches/hotspot/hs19/ia64-fix.patch | 30 patches/hotspot/hs19/params-cast-size_t.patch | 295 - patches/hotspot/hs19/print_lsb_release.patch | 49 patches/hotspot/hs19/update-bootclasspath.patch | 13 patches/hotspot/original/alpha-fixes.patch | 31 patches/hotspot/original/gcc-suffix.patch | 25 patches/hotspot/original/params-cast-size_t.patch | 274 patches/hotspot/original/print_lsb_release.patch | 48 patches/hotspot/original/update-bootclasspath.patch | 13 patches/ia64-fix.patch | 30 patches/icedtea-jtreg-jrunscript.patch | 12 patches/icedtea-lcms.patch | 25 patches/icedtea-shark-build.patch | 16 patches/jtreg-TestXEmbedServer-fix.patch | 25 patches/openjdk/4356282-opentype.patch | 227 patches/openjdk/6438179-systray_check.patch | 92 patches/openjdk/6622432-bigdecimal_performance.patch | 4211 --------------- patches/openjdk/6668231-ssl_cert.patch | 306 - patches/openjdk/6678385-window_movement_crasher.patch | 1241 ---- patches/openjdk/6687968-pngimagereader_mem_leak.patch | 126 patches/openjdk/6721088-awt_window_size.patch | 67 patches/openjdk/6725214-direct3d-01.patch | 667 +- patches/openjdk/6795060-icu_crash.patch | 95 patches/openjdk/6795356-proxylazyvalue-leak.patch | 320 - patches/openjdk/6850606-bigdecimal_regression.patch | 144 patches/openjdk/6853592-badwindow-warning-fix.patch | 16 patches/openjdk/6876282-bigdecimal_divide.patch | 89 patches/openjdk/6941936-broken-pipe.patch | 438 - patches/openjdk/6943219-failure-in-linux.patch | 73 patches/openjdk/6951319-sparc_build_fixes.patch | 642 -- patches/openjdk/6954424-opentype_javadoc.patch | 23 patches/openjdk/6961732-negative_leading.patch | 45 patches/openjdk/6963870-swing_npe.patch | 99 patches/openjdk/6969395-net_bugs.patch | 461 - patches/openjdk/6979979-gtk_font_size_rounding.patch | 57 patches/openjdk/6985992-test_6933784.patch | 43 patches/openjdk/6994130-ppc_fix.patch | 11 patches/params-cast-size_t.patch | 295 + patches/print_lsb_release.patch | 49 patches/security/20101012/6559775.patch | 317 - patches/security/20101012/6622002.patch | 64 patches/security/20101012/6623943.patch | 138 patches/security/20101012/6891766.patch | 1147 ---- patches/security/20101012/6914943.patch | 2129 ------- patches/security/20101012/6925710.patch | 198 patches/security/20101012/6938813.patch | 196 patches/security/20101012/6952017.patch | 50 patches/security/20101012/6952603.patch | 38 patches/security/20101012/6957564.patch | 77 patches/security/20101012/6958060.patch | 15 patches/security/20101012/6961084.patch | 325 - patches/security/20101012/6963023.patch | 95 patches/security/20101012/6963285.patch | 20 patches/security/20101012/6963489.patch | 31 patches/security/20101012/6966692.patch | 91 patches/security/20101012/6981426.patch | 24 patches/security/20101012/6990437.patch | 116 patches/update-bootclasspath.patch | 13 shark/hotspot/make/linux/makefiles/shark.make | 32 shark/hotspot/src/cpu/zero/vm/shark_globals_zero.hpp | 62 shark/hotspot/src/share/vm/includeDB_shark | 369 - shark/hotspot/src/share/vm/shark/llvmHeaders.hpp | 82 shark/hotspot/src/share/vm/shark/llvmValue.hpp | 62 shark/hotspot/src/share/vm/shark/sharkBlock.cpp | 1260 ---- shark/hotspot/src/share/vm/shark/sharkBlock.hpp | 281 - shark/hotspot/src/share/vm/shark/sharkBuilder.cpp | 591 -- shark/hotspot/src/share/vm/shark/sharkBuilder.hpp | 209 shark/hotspot/src/share/vm/shark/sharkCacheDecache.cpp | 259 shark/hotspot/src/share/vm/shark/sharkCacheDecache.hpp | 417 - shark/hotspot/src/share/vm/shark/sharkCodeBuffer.hpp | 87 shark/hotspot/src/share/vm/shark/sharkCompiler.cpp | 340 - shark/hotspot/src/share/vm/shark/sharkCompiler.hpp | 119 shark/hotspot/src/share/vm/shark/sharkConstant.cpp | 128 shark/hotspot/src/share/vm/shark/sharkConstant.hpp | 64 shark/hotspot/src/share/vm/shark/sharkContext.cpp | 180 shark/hotspot/src/share/vm/shark/sharkContext.hpp | 187 shark/hotspot/src/share/vm/shark/sharkEntry.hpp | 58 shark/hotspot/src/share/vm/shark/sharkFunction.cpp | 188 shark/hotspot/src/share/vm/shark/sharkFunction.hpp | 111 shark/hotspot/src/share/vm/shark/sharkInliner.cpp | 749 -- shark/hotspot/src/share/vm/shark/sharkInliner.hpp | 32 shark/hotspot/src/share/vm/shark/sharkIntrinsics.cpp | 277 shark/hotspot/src/share/vm/shark/sharkIntrinsics.hpp | 54 shark/hotspot/src/share/vm/shark/sharkInvariants.cpp | 37 shark/hotspot/src/share/vm/shark/sharkInvariants.hpp | 167 shark/hotspot/src/share/vm/shark/sharkMemoryManager.cpp | 116 shark/hotspot/src/share/vm/shark/sharkMemoryManager.hpp | 88 shark/hotspot/src/share/vm/shark/sharkNativeWrapper.cpp | 352 - shark/hotspot/src/share/vm/shark/sharkNativeWrapper.hpp | 182 shark/hotspot/src/share/vm/shark/sharkRuntime.cpp | 251 shark/hotspot/src/share/vm/shark/sharkRuntime.hpp | 83 shark/hotspot/src/share/vm/shark/sharkStack.cpp | 263 shark/hotspot/src/share/vm/shark/sharkStack.hpp | 290 - shark/hotspot/src/share/vm/shark/sharkState.cpp | 389 - shark/hotspot/src/share/vm/shark/sharkState.hpp | 188 shark/hotspot/src/share/vm/shark/sharkStateScanner.cpp | 99 shark/hotspot/src/share/vm/shark/sharkStateScanner.hpp | 75 shark/hotspot/src/share/vm/shark/sharkTopLevelBlock.cpp | 1991 ------- shark/hotspot/src/share/vm/shark/sharkTopLevelBlock.hpp | 430 - shark/hotspot/src/share/vm/shark/sharkType.hpp | 112 shark/hotspot/src/share/vm/shark/sharkValue.cpp | 260 shark/hotspot/src/share/vm/shark/sharkValue.hpp | 332 - shark/hotspot/src/share/vm/shark/shark_globals.cpp | 29 shark/hotspot/src/share/vm/shark/shark_globals.hpp | 54 diffs (truncated from 30339 to 500 lines): diff -r d2d762ec4dda -r 3c63d5967d08 ChangeLog --- a/ChangeLog Tue Jan 04 16:56:06 2011 -0500 +++ b/ChangeLog Sun Jan 09 00:46:45 2011 +0000 @@ -1,3 +1,30 @@ 2011-01-04 Denis Lila + + * patches/jtreg-TestXEmbedServer-fix.patch: + Moved to... + * Makefile.am: + Fix path to above patch. Only apply jtreg-6929067-fix.patch + when building hs19. + * patches/openjdk/6560348-jtreg-TestXEmbedServer-fix.patch: + ... OpenJDK patch with appropriate bug ID. + +2011-01-07 Andrew John Hughes + + * patches/jtreg-TestXEmbedServer-fix.patch, + * patches/openjdk/6668231-ssl_cert.patch, + * patches/openjdk/6687968-pngimagereader_mem_leak.patch, + * patches/openjdk/6795356-proxylazyvalue-leak.patch, + * patches/openjdk/6941936-broken-pipe.patch, + * patches/openjdk/6943219-failure-in-linux.patch, + * patches/openjdk/6951319-sparc_build_fixes.patch, + * patches/openjdk/6963870-swing_npe.patch, + * patches/openjdk/6979979-gtk_font_size_rounding.patch, + * patches/openjdk/6994130-ppc_fix.patch: + Drop upstreamed patches. + * Makefile.am: Updated with above. + * patches/openjdk/6725214-direct3d-01.patch: + Recreated due to copyright header changes by Oracle. + 2011-01-04 Denis Lila Fixed RH661505. @@ -231,9 +258,27 @@ 2010-11-12 Andrew John Hughes + + * patches/openjdk/6622432-bigdecimal_performance.patch, + * patches/openjdk/6850606-bigdecimal_regression.patch, + * patches/openjdk/6876282-bigdecimal_divide.patch: + Removed, upstream. + * Makefile.am: Add patch below. + * patches/6703377-freetypescaler.patch: + Added back, not upstream (this is NOT 6703377, but + an addendum to it). + 2010-11-11 Stefan Ring * Makefile.am: Upgrade CACAO version, use .tar.gz archive + +2010-11-09 Andrew John Hughes + + * patches/6703377-freetypescaler.patch, + * patches/openjdk/6853592-badwindow-warning-fix.patch: + Drop patches applied upstream. + * Makefile.am: Drop above patches. 2010-11-11 Stefan Ring @@ -362,6 +407,110 @@ 2010-10-20 Andrew John Hughes + + * patches/security/20101012/6559775.patch, + * patches/security/20101012/6622002.patch, + * patches/security/20101012/6891766.patch, + * patches/security/20101012/6914943.patch, + * patches/security/20101012/6925710.patch, + * patches/security/20101012/6938813.patch, + * patches/security/20101012/6952017.patch, + * patches/security/20101012/6952603.patch, + * patches/security/20101012/6957564.patch, + * patches/security/20101012/6958060.patch, + * patches/security/20101012/6961084.patch, + * patches/security/20101012/6963023.patch, + * patches/security/20101012/6963285.patch, + * patches/security/20101012/6963489.patch, + * patches/security/20101012/6966692.patch, + * patches/security/20101012/6981426.patch, + * patches/security/20101012/6990437.patch: + Dropped; available upstream. + * Makefile.am: Drop above patches. + * patches/icedtea-lcms.patch: Rejigged against + upstream security patch. + +2010-10-18 Andrew John Hughes + + * patches/hotspot/hs19/alpha-fixes.patch, + * patches/hotspot/hs19/gcc-suffix.patch, + * patches/hotspot/hs19/params-cast-size_t.patch, + * patches/hotspot/hs19/print_lsb_release.patch, + * patches/hotspot/hs19/update-bootclasspath.patch: + Move to patches. hs19 is now the only option. + * patches/hotspot/original/alpha-fixes.patch, + * patches/hotspot/original/gcc-suffix.patch, + * patches/hotspot/original/params-cast-size_t.patch, + * patches/hotspot/original/print_lsb_release.patch, + * patches/hotspot/original/update-bootclasspath.patch: + Dropped; upstream moved from hs17 to hs19. + * patches/icedtea-shark-build.patch: + Applied upstream by Gary Benson. + * patches/security/20101012/6623943.patch: + Applied upstream by Omair Majid. + * shark/hotspot/make/linux/makefiles/shark.make, + * shark/hotspot/src/cpu/zero/vm/shark_globals_zero.hpp, + * shark/hotspot/src/share/vm/includeDB_shark, + * shark/hotspot/src/share/vm/shark/llvmHeaders.hpp, + * shark/hotspot/src/share/vm/shark/llvmValue.hpp, + * shark/hotspot/src/share/vm/shark/sharkBlock.cpp, + * shark/hotspot/src/share/vm/shark/sharkBlock.hpp, + * shark/hotspot/src/share/vm/shark/sharkBuilder.cpp, + * shark/hotspot/src/share/vm/shark/sharkBuilder.hpp, + * shark/hotspot/src/share/vm/shark/sharkCacheDecache.cpp, + * shark/hotspot/src/share/vm/shark/sharkCacheDecache.hpp, + * shark/hotspot/src/share/vm/shark/sharkCodeBuffer.hpp, + * shark/hotspot/src/share/vm/shark/sharkCompiler.cpp, + * shark/hotspot/src/share/vm/shark/sharkCompiler.hpp, + * shark/hotspot/src/share/vm/shark/sharkConstant.cpp, + * shark/hotspot/src/share/vm/shark/sharkConstant.hpp, + * shark/hotspot/src/share/vm/shark/sharkContext.cpp, + * shark/hotspot/src/share/vm/shark/sharkContext.hpp, + * shark/hotspot/src/share/vm/shark/sharkEntry.hpp, + * shark/hotspot/src/share/vm/shark/sharkFunction.cpp, + * shark/hotspot/src/share/vm/shark/sharkFunction.hpp, + * shark/hotspot/src/share/vm/shark/sharkInliner.cpp, + * shark/hotspot/src/share/vm/shark/sharkInliner.hpp, + * shark/hotspot/src/share/vm/shark/sharkIntrinsics.cpp, + * shark/hotspot/src/share/vm/shark/sharkIntrinsics.hpp, + * shark/hotspot/src/share/vm/shark/sharkInvariants.cpp, + * shark/hotspot/src/share/vm/shark/sharkInvariants.hpp, + * shark/hotspot/src/share/vm/shark/sharkMemoryManager.cpp, + * shark/hotspot/src/share/vm/shark/sharkMemoryManager.hpp, + * shark/hotspot/src/share/vm/shark/sharkNativeWrapper.cpp, + * shark/hotspot/src/share/vm/shark/sharkNativeWrapper.hpp, + * shark/hotspot/src/share/vm/shark/sharkRuntime.cpp, + * shark/hotspot/src/share/vm/shark/sharkRuntime.hpp, + * shark/hotspot/src/share/vm/shark/sharkStack.cpp, + * shark/hotspot/src/share/vm/shark/sharkStack.hpp, + * shark/hotspot/src/share/vm/shark/sharkState.cpp, + * shark/hotspot/src/share/vm/shark/sharkState.hpp, + * shark/hotspot/src/share/vm/shark/sharkStateScanner.cpp, + * shark/hotspot/src/share/vm/shark/sharkStateScanner.hpp, + * shark/hotspot/src/share/vm/shark/sharkTopLevelBlock.cpp, + * shark/hotspot/src/share/vm/shark/sharkTopLevelBlock.hpp, + * shark/hotspot/src/share/vm/shark/sharkType.hpp, + * shark/hotspot/src/share/vm/shark/sharkValue.cpp, + * shark/hotspot/src/share/vm/shark/sharkValue.hpp, + * shark/hotspot/src/share/vm/shark/shark_globals.cpp, + * shark/hotspot/src/share/vm/shark/shark_globals.hpp: + Shark is in HotSpot 19. + * Makefile.am: + (ICEDTEA_PATCHES): Remove $(HSBUILD) special casing. + Remove conditional !WITH_ALT_HSBUILD patches. + (ports): Drop !WITH_ALT_HSBUILD block. + (clean-ports): Likewise. + * hotspot.map: Remove hs19. + * patches/alpha-fixes.patch, + * patches/gcc-suffix.patch, + * patches/params-cast-size_t.patch, + * patches/print_lsb_release.patch, + * patches/update-bootclasspath.patch: + The hs19 patches moved above. + * acinclude.m4: + (AC_CHECK_WITH_HOTSPOT_BUILD): Default to original. 2010-10-19 Andrew John Hughes @@ -647,7 +796,6 @@ 2010-10-19 Andrew John Hughes + + * patches/icedtea-awt-window-size.patch, + * patches/openjdk/6969395-net_bugs.patch, + * patches/openjdk/6985992-test_6933784.patch: + Dropped; upstreamed. + * Makefile.am: Remove above patches. 2010-09-23 Andrew John Hughes @@ -1249,6 +1405,15 @@ 2010-09-07 Andrew John Hughes + + * patches/openjdk/6438179-systray_check.patch: + Dropped, applied upstream. + * Makefile.am: Drop above patch and those brought + back by merge. Update JAXP tarball. + * patches/openjdk/6951319-sparc_build_fixes.patch: + Remove upstreamed parts. + 2010-09-03 Pavel Tisnovsky * Makefile.am: Fixed indentation, changes spaces to tab. @@ -1298,7 +1463,7 @@ 2010-08-27 Deepak Bhole - * Makefile.am: + * Makefile.am: Add patch. * patches/opengl-jni-fix.patch: Fixed missing JNI link to native function OGLContext.getOGLIdString() which causes @@ -1385,6 +1550,22 @@ 2010-08-13 Andrew John Hughes + + * patches/openjdk/4356282-opentype.patch, + * patches/openjdk/6795060-icu_crash.patch, + * patches/openjdk/6954424-opentype_javadoc.patch: + Dropped, applied upstream. + * Makefile.am: + Remove above patches. + +2010-08-12 Andrew John Hughes + + * patches/openjdk/6678385-window_movement_crasher.patch: + Dropped, applied upstream. + * Makefile.am: + Remove above patch. 2010-08-09 Omair Majid @@ -1426,7 +1607,7 @@ 2010-08-09 Deepak Bhole @@ -1738,6 +1919,12 @@ 2010-07-28 Matthias Klose * NEWS: Add 1.8.1 entry. + +2010-07-26 Andrew John Hughes + + * patches/icedtea-jtreg-jrunscript.patch: + Regenerate after 50002bfcff96 from dcubed being + added to OpenJDK6. 2010-07-26 Andrew John Hughes @@ -2187,6 +2374,12 @@ 2010-07-08 Andrew John Hughes + + * patches/openjdk/6961732.patch: + Dropped, applied upstream. + * Makefile.am: Remove above patch. 2010-07-06 Andrew John Hughes @@ -10480,7 +10673,7 @@ 2009-04-07 Omair Majid - * patches/icedtea-jtreg-jrunscript.patch: New patch. Replaces + * patches/icedtea-jtreg-jrunscript.patch: New patch. Replaces jrunscriptTest.sh with a java version that isnt picky about int vs double changes. * Makefile.am (ICEDTEA_PATCHES): Apply the above. diff -r d2d762ec4dda -r 3c63d5967d08 Makefile.am --- a/Makefile.am Tue Jan 04 16:56:06 2011 -0500 +++ b/Makefile.am Sun Jan 09 00:46:45 2011 +0000 @@ -18,8 +18,8 @@ JAF_DROP_ZIP = jdk6-jaf-b20.zip JAF_DROP_ZIP = jdk6-jaf-b20.zip JAF_DROP_SHA256SUM = 78c7b5c9d6271e88ee46abadd018a61f1e9645f8936cc8df1617e5f4f5074012 JAXP_DROP_URL = http://icedtea.classpath.org/download/drops -JAXP_DROP_ZIP = jdk6-jaxp-b20.zip -JAXP_DROP_SHA256SUM = d097627d4059d488c5a09d4e33cec275a193d4d8bc0fea8ef4f1337170904156 +JAXP_DROP_ZIP = jaxp-1_4_4.zip +JAXP_DROP_SHA256SUM = 10b203bec5b7d3dd8f515a9e098f80abc316faf977bcc220b56efe3dc6e9e5e9 OPENJDK_HG_URL = http://hg.openjdk.java.net/jdk6/jdk6 @@ -174,27 +174,7 @@ REWRITER_SRCS = $(abs_top_srcdir)/rewrit ICEDTEA_FSG_PATCHES = -BROKEN = - -SECURITY_PATCHES = \ - patches/security/20101012/6891766.patch \ - patches/security/20101012/6925710.patch \ - patches/security/20101012/6938813.patch \ - patches/security/20101012/6957564.patch \ - patches/security/20101012/6958060.patch \ - patches/security/20101012/6963023.patch \ - patches/security/20101012/6963489.patch \ - patches/security/20101012/6966692.patch \ - patches/security/20101012/6914943.patch \ - patches/security/20101012/6559775.patch \ - patches/security/20101012/6622002.patch \ - patches/security/20101012/6623943.patch \ - patches/security/20101012/6952017.patch \ - patches/security/20101012/6952603.patch \ - patches/security/20101012/6961084.patch \ - patches/security/20101012/6963285.patch \ - patches/security/20101012/6981426.patch \ - patches/security/20101012/6990437.patch +SECURITY_PATCHES = ICEDTEA_PATCHES = \ $(SECURITY_PATCHES) \ @@ -211,7 +191,7 @@ ICEDTEA_PATCHES = \ patches/icedtea-headers.patch \ patches/icedtea-headers-hotspot.patch \ patches/icedtea-gcc-suffix.patch \ - patches/hotspot/$(HSBUILD)/gcc-suffix.patch \ + patches/gcc-suffix.patch \ patches/icedtea-bytebuffer-compact.patch \ patches/memory-limits.patch \ patches/icedtea-sunsrc.patch \ @@ -219,18 +199,18 @@ ICEDTEA_PATCHES = \ patches/icedtea-javafiles.patch \ patches/icedtea-jvmtiEnv.patch \ patches/icedtea-lcms.patch \ - patches/hotspot/$(HSBUILD)/print_lsb_release.patch \ + patches/print_lsb_release.patch \ patches/icedtea-jpegclasses.patch \ patches/icedtea-uname.patch \ patches/icedtea-freetypeversion.patch \ patches/icedtea-nomotif-6706121.patch \ patches/icedtea-nomotif.patch \ patches/icedtea-nomotif-mtoolkit.patch \ - patches/hotspot/$(HSBUILD)/alpha-fixes.patch \ + patches/alpha-fixes.patch \ patches/icedtea-alt-jar.patch \ patches/icedtea-jdk-use-ssize_t.patch \ patches/icedtea-use-idx_t.patch \ - patches/hotspot/$(HSBUILD)/params-cast-size_t.patch \ + patches/params-cast-size_t.patch \ patches/icedtea-clean-crypto.patch \ patches/icedtea-arch.patch \ patches/icedtea-lc_ctype.patch \ @@ -246,7 +226,6 @@ ICEDTEA_PATCHES = \ patches/icedtea-sparc-ptracefix.patch \ patches/icedtea-sparc-trapsfix.patch \ patches/icedtea-demo-swingapplet.patch \ - patches/openjdk/6721088-awt_window_size.patch \ patches/icedtea-jtreg-6592792.patch \ patches/icedtea-s390-noinline.patch \ patches/icedtea-jtreg-dnd.patch \ @@ -262,43 +241,27 @@ ICEDTEA_PATCHES = \ patches/icedtea-parisc.patch \ patches/icedtea-sh4-support.patch \ patches/icedtea-policy-evaluation.patch \ - patches/hotspot/$(HSBUILD)/update-bootclasspath.patch \ + patches/update-bootclasspath.patch \ patches/libpng.patch \ patches/applet_hole.patch \ patches/icedtea-jtreg-httpTest.patch \ patches/arm.patch \ - patches/openjdk/6678385-window_movement_crasher.patch \ - patches/openjdk/6961732-negative_leading.patch \ patches/debug-dir.patch \ patches/no-sync.patch \ patches/icedtea-override-redirect-metacity.patch \ - patches/openjdk/6963870-swing_npe.patch \ - patches/openjdk/6668231-ssl_cert.patch \ patches/openjdk/6967533-pre_epoch.patch \ patches/fonts-rhel.patch \ patches/fonts-gentoo.patch \ patches/ipv4-mapped-ipv6-addresses.patch \ - patches/openjdk/6795060-icu_crash.patch \ - patches/openjdk/4356282-opentype.patch \ - patches/openjdk/6954424-opentype_javadoc.patch \ - patches/openjdk/6438179-systray_check.patch \ patches/icedtea-too-many-args.patch \ patches/icedtea-jtreg-OpenGLContextInit.patch \ - patches/openjdk/6969395-net_bugs.patch \ patches/openjdk/6510892-httpserver_test.patch \ patches/openjdk/6638712-wildcard_types.patch \ patches/openjdk/6650759-missing_inference.patch \ patches/numa_on_early_glibc.patch \ - patches/icedtea-shark-build.patch \ - patches/openjdk/6985992-test_6933784.patch \ - patches/openjdk/6853592-badwindow-warning-fix.patch \ - patches/6703377-freetypescaler.patch \ patches/icedtea-jtreg-international-fonts.patch \ patches/openjdk/6967436-6976265-6967434-pisces.patch \ patches/openjdk/6997495-test_correction_6857159.patch \ - patches/openjdk/6622432-bigdecimal_performance.patch \ - patches/openjdk/6850606-bigdecimal_regression.patch \ - patches/openjdk/6876282-bigdecimal_divide.patch \ patches/f14-fonts.patch \ patches/jtreg-DeleteFont.patch \ patches/jtreg-WindowWithWarningTest.patch \ @@ -306,34 +269,15 @@ ICEDTEA_PATCHES = \ patches/openjdk/7002666-eclipse_cdt_oops_crash.patch \ patches/jtreg-T6650759m-fix.patch \ patches/openjdk/7003777-bad-html-entity-parse.patch \ - patches/openjdk/6941936-broken-pipe.patch \ - patches/openjdk/6943219-failure-in-linux.patch \ patches/jtreg-6929067-fix.patch \ - patches/openjdk/6979979-gtk_font_size_rounding.patch \ - patches/openjdk/6795356-proxylazyvalue-leak.patch \ patches/rendering-engine-tests.patch \ - patches/jtreg-TestXEmbedServer-fix.patch \ patches/openjdk/6800846-printing-quality.patch \ - patches/openjdk/6687968-pngimagereader_mem_leak.patch \ patches/openjdk/6541476-png-iTXt-chunk.patch \ patches/openjdk/6782079-png_metadata_oom.patch \ - patches/661505-jpeg.patch - -if WITH_ALT_HSBUILD -ICEDTEA_PATCHES += \ - patches/openjdk/6994130-ppc_fix.patch \ + patches/661505-jpeg.patch \ patches/openjdk/6980392-fix_test6581734.patch \ - patches/hotspot/hs19/ia64-fix.patch -else -ICEDTEA_PATCHES += \ - patches/shark_do_nothing_on_stub_frame.patch \ - patches/icedtea-shark-build-hotspot.patch \ - patches/shark.patch \ - patches/shark-debug-option.patch \ - patches/icedtea-shark.patch \ - patches/icedtea-linux-separate-debuginfo.patch \ - patches/openjdk/6951319-sparc_build_fixes.patch -endif + patches/6703377-freetypescaler.patch \ + patches/ia64-fix.patch if WITH_RHINO ICEDTEA_PATCHES += \ @@ -916,23 +860,6 @@ clean-replace-hotspot: # Copy ports sources into tree stamps/ports.stamp: stamps/replace-hotspot.stamp -if !WITH_ALT_HSBUILD - for target in $(abs_top_srcdir)/shark/hotspot/make/*/makefiles/* \ - $(abs_top_srcdir)/shark/hotspot/src/*cpu/* \ - $(abs_top_srcdir)/shark/hotspot/src/share/vm/*; do \ - link=$$(dirname $$target | sed 's/^.*shark/openjdk/'); \ - cp -rv $$target $$link; \ - done - if ! test "x$(WITH_CACAO)" = "xno" ; then \ - mkdir -p openjdk/jdk/src/solaris/bin/$(BUILD_ARCH_DIR) ; \ - ln -sf $(abs_top_builddir)/jvm.cfg \ - openjdk/jdk/src/solaris/bin/$(BUILD_ARCH_DIR)/jvm.cfg ; \ - fi - if ! test "x$(WITH_CACAO)" = "xno"; then \ - ln -sf $(abs_top_builddir)/ergo.c \ - openjdk/jdk/src/solaris/bin/ergo_$(BUILD_ARCH_DIR).c; \ - fi -endif for target in $(abs_top_srcdir)/arm_port/hotspot/tools \ $(abs_top_srcdir)/arm_port/hotspot/src/*cpu/* ; do \ link=$$(dirname $$target | sed 's/^.*arm_port/openjdk/'); \ @@ -942,16 +869,6 @@ endif touch stamps/ports.stamp clean-ports: -if !WITH_ALT_HSBUILD - for target in $(abs_top_srcdir)/shark/hotspot/make/*/makefiles/* \ - $(abs_top_srcdir)/shark/hotspot/src/*cpu/* \ - $(abs_top_srcdir)/shark/hotspot/src/share/vm/*; do \ - link=$$(dirname $$target | sed 's/^.*shark/openjdk/'); \ - rm -rf $$link; \ - done - rm -f openjdk/jdk/src/solaris/bin/$(BUILD_ARCH_DIR)/jvm.cfg - rm -f openjdk/jdk/src/solaris/bin/ergo_$(BUILD_ARCH_DIR).c -endif for target in $(abs_top_srcdir)/arm_port/hotspot/tools \ $(abs_top_srcdir)/arm_port/hotspot/src/*cpu/* ; do \ link=$$(dirname $$target | sed 's/^.*arm_port/openjdk/'); \ diff -r d2d762ec4dda -r 3c63d5967d08 acinclude.m4 --- a/acinclude.m4 Tue Jan 04 16:56:06 2011 -0500 +++ b/acinclude.m4 Sun Jan 09 00:46:45 2011 +0000 @@ -917,8 +917,8 @@ AC_DEFUN([AC_CHECK_WITH_HOTSPOT_BUILD], AC_DEFUN([AC_CHECK_WITH_HOTSPOT_BUILD], [ From jvanek at redhat.com Sun Jan 9 12:56:28 2011 From: jvanek at redhat.com (Jiri Vanek) Date: Sun, 09 Jan 2011 21:56:28 +0100 Subject: [jvanek@redhat.com: visual vm 1.3.1] In-Reply-To: <20110107212656.GD17639@rivendell.middle-earth.co.uk> References: <20110107212656.GD17639@rivendell.middle-earth.co.uk> Message-ID: <4D2A20FC.7070708@redhat.com> On 01/07/2011 10:26 PM, Dr Andrew John Hughes wrote: > [Forwarding to distro-pkg-dev as public items such as releases should be discussed there] > > ----- Forwarded message from Jiri Vanek ----- > > Date: Thu, 06 Jan 2011 15:08:49 +0100 > From: Jiri Vanek > Subject: visual vm 1.3.1 > User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.9) Gecko/20100907 Fedora/3.1.3-1.fc13 Thunderbird/3.1.3 > > Hi! > I had prepared visualvm harness 1.1. and uploaded to download/sources > as 1.0 was used to be. > I have also updated our package to visualvm to 1.3.1, harness 1.1, > profiler 6.9-1. > It is awaiting in testrepo, and will be here, untill way "how with" > visualvm will be set. > > Regards J. > > ----- End forwarded message ----- > > I don't believe we have even properly discussed a 1.1 release of the > VisualVM harness yet, let alone made such a release. Such releases > need to be discussed on the public list (distro-pkg-dev) so that everyone > has a chance to give their input. > > I have asked, both by e-mail and on IRC, for you to post any patches > you want for such a release but have only seen one so far > (http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011643.html). The > discussion on https://bugzilla.redhat.com/show_bug.cgi?id=640205 > suggests that more changes are needed before we make a new release and > a quick look at the spec file in Fedora confirmed this to me. > > I tried to make some of the necessary changes but found that my work > was being ignored by the Fedora build as it was downloading a 1.1 > tarball. This seems to have been published to the IcedTea server > without any discussion. I'm afraid I've had to remove this in order > to proceed with work on VisualVM. Apologies to anyone who may have > been depending on it, but it doesn't seem to have been announced > anywhere. > > We provide the VisualVM harness as an upstream project so that all > distributions can benefit. Thus, where possible, we expect changes > to be pushed to the harness rather than being kept locally in the > distribution packages so that more people can benefit. At present, > the Fedora spec file for VisualVM seems to have several modifications > (patches and the movement of installed files) which can be upstreamed > for the benefit of all, and I would like to see these in the repository > before any further releases are made. > > Additionally, when submitting patches for review, please attach them > to an e-mail describing fully the motivation for it with a ChangeLog > entry. It is very hard to review a patch if we don't know why it is > being submitted in the first place or what it does. > > Thanks, > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 This is little bit unfair. When vm 1.3 was "released", we agreed that You will do the changes in harness according to specfile, because you wrote the harness. Also was sugested to dont release 1.3 until 1.3.1 will be build - probably with new harness. 1.3.1 Is available more then 2months. So why to wait when everything is prepared? I have asked you several times if things are moving. They didn't:(. At least my rash action moved them. My apologise for uploading 1.1 to download/sources. I underestimate its full purpose as distribution channel. I should at least name it pre or work off-line at all. Also I'm sorry for not to notice distro-pkg. I informed only java-team as I'm used to. Although I consider most of things as misscommuncation, I apologise..."road to hell is paved with good intentions." Regards J. From ahughes at redhat.com Sun Jan 9 15:00:15 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Sun, 9 Jan 2011 23:00:15 +0000 Subject: [jvanek@redhat.com: visual vm 1.3.1] In-Reply-To: References: <20110107212656.GD17639@rivendell.middle-earth.co.uk> Message-ID: <20110109230015.GA5350@rivendell.middle-earth.co.uk> On 10:17 Sat 08 Jan , akurtakov wrote: > On Fri, Jan 7, 2011 at 11:26 PM, Dr Andrew John Hughes > wrote: > > [Forwarding to distro-pkg-dev as public items such as releases should be discussed there] > > > > ----- Forwarded message from Jiri Vanek ----- > > > > Date: Thu, 06 Jan 2011 15:08:49 +0100 > > From: Jiri Vanek > > Subject: visual vm 1.3.1 > > User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.9) Gecko/20100907 Fedora/3.1.3-1.fc13 Thunderbird/3.1.3 > > > > Hi! > > I had prepared visualvm harness 1.1. and uploaded to download/sources > > as 1.0 was used to be. > > I have also updated our package to visualvm to 1.3.1, harness 1.1, > > profiler 6.9-1. > > It is awaiting in testrepo, and will be here, untill way "how with" > > visualvm ?will be set. > > > > Regards J. > > > > ----- End forwarded message ----- > > > > I don't believe we have even properly discussed a 1.1 release of the > > VisualVM harness yet, let alone made such a release. ?Such releases > > need to be discussed on the public list (distro-pkg-dev) so that everyone > > has a chance to give their input. > > > > I have asked, both by e-mail and on IRC, for you to post any patches > > you want for such a release but have only seen one so far > > (http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011643.html). The > > discussion on https://bugzilla.redhat.com/show_bug.cgi?id=640205 > > suggests that more changes are needed before we make a new release and > > a quick look at the spec file in Fedora confirmed this to me. > > > > I tried to make some of the necessary changes but found that my work > > was being ignored by the Fedora build as it was downloading a 1.1 > > tarball. ?This seems to have been published to the IcedTea server > > without any discussion. ?I'm afraid I've had to remove this in order > > to proceed with work on VisualVM. ?Apologies to anyone who may have > > been depending on it, but it doesn't seem to have been announced > > anywhere. > > > > We provide the VisualVM harness as an upstream project so that all > > distributions can benefit. ?Thus, where possible, we expect changes > > to be pushed to the harness rather than being kept locally in the > > distribution packages so that more people can benefit. ?At present, > > the Fedora spec file for VisualVM seems to have several modifications > > (patches and the movement of installed files) which can be upstreamed > > for the benefit of all, and I would like to see these in the repository > > before any further releases are made. > > I just want to note that Fedora as a project requires each packager to > propose his patches upstream. See > http://fedoraproject.org/wiki/PackageMaintainers/WhyUpstream. But we > can not guarantee that every packager is doing that nor we can track > every patch's path in different tracking systems, mails and so on. > This mail is sent to simply disambiguate what does Fedora mean in this > mail - upstream first is one of our biggest virtues and I'm not happy > seeing it questioned in any way by a single package maintainer > actions. > Thanks for the link, Alexander. This does a better job of explaining the very point I was trying to make about upstreaming patches, and this requirement is one of the things I like about Fedora :-) On Friday, I upstreamed the changes in the Fedora spec file myself and sent the updated spec file to Jiri, who maintains the VisualVM package in Fedora. We should now be able to press on with a release and a new Fedora RPM can be created which uses the new 1.1 version of the VisualVM harness. In the future, I hope Jiri will work closer with upstream and submit such changes himself. > Regards, > Alexander Kurtakov > > > > > Additionally, when submitting patches for review, please attach them > > to an e-mail describing fully the motivation for it with a ChangeLog > > entry. ?It is very hard to review a patch if we don't know why it is > > being submitted in the first place or what it does. > > > > Thanks, > > -- > > Andrew :) > > > > Free Java Software Engineer > > Red Hat, Inc. (http://www.redhat.com) > > > > Support Free Java! > > Contribute to GNU Classpath and IcedTea > > http://www.gnu.org/software/classpath > > http://icedtea.classpath.org > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > Fingerprint = F8EF F1EA 401E 2E60 15FA ?7927 142C 2591 94EF D9D8 > > Thanks, -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Sun Jan 9 16:19:14 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Mon, 10 Jan 2011 00:19:14 +0000 Subject: [jvanek@redhat.com: visual vm 1.3.1] In-Reply-To: <4D2A20FC.7070708@redhat.com> References: <20110107212656.GD17639@rivendell.middle-earth.co.uk> <4D2A20FC.7070708@redhat.com> Message-ID: <20110110001914.GB5350@rivendell.middle-earth.co.uk> On 21:56 Sun 09 Jan , Jiri Vanek wrote: > On 01/07/2011 10:26 PM, Dr Andrew John Hughes wrote: > > [Forwarding to distro-pkg-dev as public items such as releases should be discussed there] > > > > ----- Forwarded message from Jiri Vanek ----- > > > > Date: Thu, 06 Jan 2011 15:08:49 +0100 > > From: Jiri Vanek > > Subject: visual vm 1.3.1 > > User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.9) Gecko/20100907 Fedora/3.1.3-1.fc13 Thunderbird/3.1.3 > > > > Hi! > > I had prepared visualvm harness 1.1. and uploaded to download/sources > > as 1.0 was used to be. > > I have also updated our package to visualvm to 1.3.1, harness 1.1, > > profiler 6.9-1. > > It is awaiting in testrepo, and will be here, untill way "how with" > > visualvm will be set. > > > > Regards J. > > > > ----- End forwarded message ----- > > > > I don't believe we have even properly discussed a 1.1 release of the > > VisualVM harness yet, let alone made such a release. Such releases > > need to be discussed on the public list (distro-pkg-dev) so that everyone > > has a chance to give their input. > > > > I have asked, both by e-mail and on IRC, for you to post any patches > > you want for such a release but have only seen one so far > > (http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011643.html). The > > discussion on https://bugzilla.redhat.com/show_bug.cgi?id=640205 > > suggests that more changes are needed before we make a new release and > > a quick look at the spec file in Fedora confirmed this to me. > > > > I tried to make some of the necessary changes but found that my work > > was being ignored by the Fedora build as it was downloading a 1.1 > > tarball. This seems to have been published to the IcedTea server > > without any discussion. I'm afraid I've had to remove this in order > > to proceed with work on VisualVM. Apologies to anyone who may have > > been depending on it, but it doesn't seem to have been announced > > anywhere. > > > > We provide the VisualVM harness as an upstream project so that all > > distributions can benefit. Thus, where possible, we expect changes > > to be pushed to the harness rather than being kept locally in the > > distribution packages so that more people can benefit. At present, > > the Fedora spec file for VisualVM seems to have several modifications > > (patches and the movement of installed files) which can be upstreamed > > for the benefit of all, and I would like to see these in the repository > > before any further releases are made. > > > > Additionally, when submitting patches for review, please attach them > > to an e-mail describing fully the motivation for it with a ChangeLog > > entry. It is very hard to review a patch if we don't know why it is > > being submitted in the first place or what it does. > > > > Thanks, > > -- > > Andrew :) > > > > Free Java Software Engineer > > Red Hat, Inc. (http://www.redhat.com) > > > > Support Free Java! > > Contribute to GNU Classpath and IcedTea > > http://www.gnu.org/software/classpath > > http://icedtea.classpath.org > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 > > This is little bit unfair. When vm 1.3 was "released", we agreed that > You will do the changes in harness according to specfile, because you > wrote the harness. I agreed to help, yes. You're new to the harness still, so I would have been happy to show you where to make the needed changes to the build or even make such changes. But for your side, you've never even provided a list of the issues you've encountered or how you fixed them (see https://bugzilla.redhat.com/show_bug.cgi?id=640205#c30) It simply doesn't scale for upstream to go looking into every distro's repository for local patches and doing the work of incorporating those changes. That's part of your role as the package maintainer (or at least filing bugs). > Also was sugested to dont release 1.3 until 1.3.1 > will be build - probably with new harness. 1.3.1 Is available more then > 2months. I don't follow this. I said that the Mercurial repository had support for VisualVM 1.3.1, provided by Tomas Hurka, and so it would make sense to have a new VisualVM harness release (1.1) to get 1.3.1 into the Fedora packages. Given we were moving to a new release anyway, it makes sense to incorporate your changes (again see comment #30 on the bug report). > So why to wait when everything is prepared? I have asked you > several times if things are moving. They didn't:(. At least my rash > action moved them. > Provoking people is not a way to get what you want. It just inspires bad feeling and doesn't help the community work together. You may not believe it, but I do have other tasks to do other than incorporating your changes, including security updates for IcedTea (e.g. http://blog.fuseyism.com/index.php/2010/11/24/icedtea6-176-183-and-192-released/) which take a higher priority. Please have more patience. > My apologise for uploading 1.1 to download/sources. I underestimate its > full purpose as distribution channel. I should at least name it pre or > work off-line at all. I don't see why there's any reason to put such a tarball on a public server other than to try and subvert the release process. I'd have a little more sympathy if this seemed like a genuine mistake, but you were told, when you asked to upload the file, to contact the mailing list and you ignored this. There's obviously no problem with doing test builds against your own locally created tarballs (as I did on Friday to do the required work). You shouldn't publish these tarballs publicly or make released RPMs out of them e.g. https://admin.fedoraproject.org/updates/visualvm-1.3.1-1.fc14 (BTW, the versioning there should indicate the version of VisualVM harness used; please incorporate this). A release needs to first be discussed on the public mailing list (distro-pkg-dev) to give everyone chance to contribute or at least make them aware of it. You then need to do basic administration work like updating the version, tagging the tree and rolling a tarball against that tag with the correct version. The reason the tree carries a 'pre' suffix through most of its life is explicitly to distinguish test/pre-release tarballs from the real releases we make and you shouldn't just rename them to '1.1' or whatever. The full release process is described on the wiki: http://icedtea.classpath.org/wiki/ReleasingIcedTea (this is for IcedTea but most of the same applies to VisualVM & IcedTea-Web). That handles the technical side, but the most important side to a release is handling it socially with the participation of the community and not just making random releases as you feel like it. > Also I'm sorry for not to notice distro-pkg. I > informed only java-team as I'm used to. Ok, now you know. You've posted to the list before, so it's not completely alien. > Although I consider most of > things as misscommuncation, I apologise..."road to hell is paved with > good intentions." > The best way to apologise is by learning from such mistakes and doing the right thing in future :-) > Regards J. > > > > > -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From schumi.han at gmail.com Mon Jan 10 08:09:06 2011 From: schumi.han at gmail.com (Zhu Han) Date: Tue, 11 Jan 2011 00:09:06 +0800 Subject: "-client" option Message-ID: Hi, Does "-client" options work for IcedTea JDK? Or, is there any way to limit the address space consumed by a single JVM instance? The target box does not have swap space, so I'd like to limit the anonymous space consumed by the JVM as little as possible. Even if I set "-Xmx96M", the jvm consumes 640MB memory space. By the way, the JVM is 64bit. Thank you so much!! best regards, hanzhu -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110111/6fc194e0/attachment.html From aph at redhat.com Mon Jan 10 08:18:15 2011 From: aph at redhat.com (Andrew Haley) Date: Mon, 10 Jan 2011 16:18:15 +0000 Subject: "-client" option In-Reply-To: References: Message-ID: <4D2B3147.20100@redhat.com> On 01/10/2011 04:09 PM, Zhu Han wrote: > Does "-client" options work for IcedTea JDK? It depends on the target. 32-bit x86 yes, 64-bit x86, no. > Or, is there any way to limit the address space consumed by a single JVM > instance? The target box does not have swap space, so I'd like to limit the > anonymous space consumed by the JVM as little as possible. Even if I set > "-Xmx96M", the jvm consumes 640MB memory space. Does it really consume that space, or does it merely pre-allocate that much address space? I think it's probably the latter. But 640M really is a lot. Is your -Xms setting 96M too? When I tried running x86 Java with no options, I got a RSS of 12m, not 640M. What are you measuing? Andrew. By the way, the JVM is > 64bit. > > Thank you so much!! > > best regards, > hanzhu > From ahughes at redhat.com Mon Jan 10 08:49:47 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Mon, 10 Jan 2011 16:49:47 +0000 Subject: RFC: VisualVM Harness 1.1 Release Message-ID: <20110110164947.GA13053@rivendell.middle-earth.co.uk> I'd like to release an updated version of the VisualVM Harness, 1.1. There have been a number of changes in the repository since the 1.0 release: * Support for VisualVM 1.3.1 http://icedtea.classpath.org/hg/visualvm/rev/ba2ccec163d0 * Make VisualVM work outside the JVM directory structure so builds work with configuration files in /etc and libraries in /usr/lib. http://icedtea.classpath.org/hg/visualvm/rev/afb288d37834 * Remove the invalid Version field from visualvm.desktop and install it in the correct location under $(datadir)/applications. http://icedtea.classpath.org/hg/visualvm/rev/df40da40c697 http://icedtea.classpath.org/hg/visualvm/rev/307d1a64ee76 * Add debugging information to the native shared libraries http://icedtea.classpath.org/hg/visualvm/rev/d0293407ac9c Does anyone have any further patches they'd like to see in 1.1? If there are no further comments, I'll make the release tomorrow evening (Tuesday, 11th of January) at around 18:00 UTC. Thanks, -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at redhat.com Mon Jan 10 13:39:38 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 10 Jan 2011 16:39:38 -0500 Subject: [icedtea-web] RFC: use tagsoup to try and parse malformed JNLP files Message-ID: <4D2B7C9A.1070104@redhat.com> Hi, I have come across a number of JNLP files that are not valid xml. Netx can not parse these files using a xml parser, and fails to run them. I spent some time looking for a solution and came across TagSoup[1]. The TagSoup library parses a malformed HTML document into a well-formed xml-like HTML document, but it works almost perfectly for our purposes too. The attached patch makes use of TagSoup for parsing input jnlp files. Parsing is currently implemented in two passes. In the first pass, TagSoup reads the "xml" (which can be malformed and hence not really xml), and outputs valid XML. Netx then uses this valid XML and uses it's own XML parser to parse the file. The patch requires TagSoup as an optional dependency. To use TagSoup, run configure (--with-tagsoup can be used to point to a TagSoup jar). To not use TagSoup (even if it installed), use --with-tagsoup=no The patch also adds an additional command line option, -xml ,to the javaws binary. This option can be used to force Netx to use the normal xml parser instead of TagSoup to parse the jnlp file. Any thoughts or comments? ChangeLog: 2011-01-10 Omair Majid * Makefile.am: Add NETX_EXCLUDE_SRCS, NETX_DUMMY_CLASSPATH (netx-source-files.txt): Selectively exclude some sources from compilation. (stamps/netx.stamp): Depend on netx-dummy.jar (netx-dummy.jar): New target. Empty jar. Used so there is always at least one class on the classpath. ($(NETX_DIR)/launcher/%.o): Add classpath. * NEWS: Update with fix. * acinclude.m4: Add IT_CHECK_FOR_TAGSOUP. * configure.ac: Call IT_CHECK_FOR_TAGSOUP. * netx/net/sourceforge/jnlp/JNLPFile.java: Add new member parserSettings. (JNLPFile(URL)): Pass a ParserSettings object. (JNLPFile(URL,boolean)): Refactored into... (JNLPFile(URL,ParserSettings)): New method. (JNLPFile(URL,Version,boolean)): Refactored into... (JNLPFile(URL,Version,ParserSettings)): New method. (JNLPFile(URL,Version,boolean,UpdatePolicy)): Refactored into... (JNLPFile(URL,Version,ParserSettings,UpdatePolicy)): New method. (JNLPFile(URL,String,Version,boolean,UpdatePolicy)): Refactored into... (JNLPFile(URL,String,Version,ParserSettings,UpdatePolicy)): New method. (JNLPFile(InputStream,boolean)): Refactored into... (JNLPFile(InputStream,ParserSettings)): New method. (getParserSettings): New method. (parse(Node,boolean,URL)): Refactored into... (parse(InputStream,URL)): New method. Invoke parser to get the root node and then parse it. * netx/net/sourceforge/jnlp/Launcher.java (toFile): Use new ParserSettings object. * netx/net/sourceforge/jnlp/Parser.java (Parser(JNLPFile,URL,Node,boolean,boolean)): Refactored into... (Parser(JNLPFile,URL,Node,ParserSettings)): New method. (getRootNode): Implementation moved into XMLParser.getRootNode. Selects the right subclass of XMLParser to use. (getEncoding): Moved to XMLParser. * netx/net/sourceforge/jnlp/ParserSettings.java: New file. (ParserSettings): New method. (ParserSettings(boolean,boolean,boolean)): New method. (isExtensionAllowed): New method. (isMalfromedXmlAllowed): New method. (isStrict): New method. * netx/net/sourceforge/jnlp/XMLParser.java (getRootNode): New method. Contains implementation from Parser.getRootNode. (getEncoding): New method. Moved from Parser. * netx/net/sourceforge/jnlp/MalformedXMLParser.java: New file. (getRootNode): New method. Transform input into valid xml and delegate to parent to parse it. (xmlizeInputStream): New method. Read contents from an input stream and transform it into valid xml. * netx/net/sourceforge/jnlp/resources/Messages.properties: Add BOXml. * netx/net/sourceforge/jnlp/runtime/Boot.java: Add -xml option. (getFile): Parse -xml option and create a new ParserSettings object based on it. * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java (getInstance(URL,String,Version,UpdatePolicy)): Refactored into... (getInstance(URL,String,Version,ParserSettings,UpdatePolicy): New method. (initializeExtensions): Use the same parser settings to parse the extension as used in the original file. Cheers, Omair [1] http://home.ccil.org/~cowan/XML/tagsoup/ -------------- next part -------------- A non-text attachment was scrubbed... Name: tagsoup-01.patch Type: text/x-patch Size: 35688 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110110/274c590b/tagsoup-01.patch From ahughes at redhat.com Mon Jan 10 14:33:23 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Mon, 10 Jan 2011 22:33:23 +0000 Subject: [icedtea-web] RFC: use tagsoup to try and parse malformed JNLP files In-Reply-To: <4D2B7C9A.1070104@redhat.com> References: <4D2B7C9A.1070104@redhat.com> Message-ID: <20110110223323.GK13053@rivendell.middle-earth.co.uk> On 16:39 Mon 10 Jan , Omair Majid wrote: > Hi, > > I have come across a number of JNLP files that are not valid xml. Netx > can not parse these files using a xml parser, and fails to run them. I > spent some time looking for a solution and came across TagSoup[1]. The > TagSoup library parses a malformed HTML document into a well-formed > xml-like HTML document, but it works almost perfectly for our purposes too. > > The attached patch makes use of TagSoup for parsing input jnlp files. > > Parsing is currently implemented in two passes. In the first pass, > TagSoup reads the "xml" (which can be malformed and hence not really > xml), and outputs valid XML. Netx then uses this valid XML and uses it's > own XML parser to parse the file. > > The patch requires TagSoup as an optional dependency. To use TagSoup, > run configure (--with-tagsoup can be used to point to a TagSoup jar). To > not use TagSoup (even if it installed), use --with-tagsoup=no > > The patch also adds an additional command line option, -xml ,to the > javaws binary. This option can be used to force Netx to use the normal > xml parser instead of TagSoup to parse the jnlp file. > > Any thoughts or comments? > > ChangeLog: > 2011-01-10 Omair Majid > > * Makefile.am: Add NETX_EXCLUDE_SRCS, NETX_DUMMY_CLASSPATH > (netx-source-files.txt): Selectively exclude some sources from > compilation. > (stamps/netx.stamp): Depend on netx-dummy.jar > (netx-dummy.jar): New target. Empty jar. Used so there is always at > least one class on the classpath. > ($(NETX_DIR)/launcher/%.o): Add classpath. > * NEWS: Update with fix. > * acinclude.m4: Add IT_CHECK_FOR_TAGSOUP. > * configure.ac: Call IT_CHECK_FOR_TAGSOUP. > * netx/net/sourceforge/jnlp/JNLPFile.java: Add new member > parserSettings. > (JNLPFile(URL)): Pass a ParserSettings object. > (JNLPFile(URL,boolean)): Refactored into... > (JNLPFile(URL,ParserSettings)): New method. > (JNLPFile(URL,Version,boolean)): Refactored into... > (JNLPFile(URL,Version,ParserSettings)): New method. > (JNLPFile(URL,Version,boolean,UpdatePolicy)): Refactored into... > (JNLPFile(URL,Version,ParserSettings,UpdatePolicy)): New method. > (JNLPFile(URL,String,Version,boolean,UpdatePolicy)): Refactored > into... > (JNLPFile(URL,String,Version,ParserSettings,UpdatePolicy)): New > method. > (JNLPFile(InputStream,boolean)): Refactored into... > (JNLPFile(InputStream,ParserSettings)): New method. > (getParserSettings): New method. > (parse(Node,boolean,URL)): Refactored into... > (parse(InputStream,URL)): New method. Invoke parser to get the root > node and then parse it. > * netx/net/sourceforge/jnlp/Launcher.java > (toFile): Use new ParserSettings object. > * netx/net/sourceforge/jnlp/Parser.java > (Parser(JNLPFile,URL,Node,boolean,boolean)): Refactored into... > (Parser(JNLPFile,URL,Node,ParserSettings)): New method. > (getRootNode): Implementation moved into XMLParser.getRootNode. > Selects the right subclass of XMLParser to use. > (getEncoding): Moved to XMLParser. > * netx/net/sourceforge/jnlp/ParserSettings.java: New file. > (ParserSettings): New method. > (ParserSettings(boolean,boolean,boolean)): New method. > (isExtensionAllowed): New method. > (isMalfromedXmlAllowed): New method. > (isStrict): New method. > * netx/net/sourceforge/jnlp/XMLParser.java > (getRootNode): New method. Contains implementation from > Parser.getRootNode. > (getEncoding): New method. Moved from Parser. > * netx/net/sourceforge/jnlp/MalformedXMLParser.java: New file. > (getRootNode): New method. Transform input into valid xml and > delegate to parent to parse it. > (xmlizeInputStream): New method. Read contents from an input stream > and transform it into valid xml. > * netx/net/sourceforge/jnlp/resources/Messages.properties: Add > BOXml. > * netx/net/sourceforge/jnlp/runtime/Boot.java: Add -xml option. > (getFile): Parse -xml option and create a new ParserSettings object > based on it. > * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java > (getInstance(URL,String,Version,UpdatePolicy)): Refactored into... > (getInstance(URL,String,Version,ParserSettings,UpdatePolicy): New > method. > (initializeExtensions): Use the same parser settings to parse the > extension as used in the original file. > > Cheers, > Omair > > [1] http://home.ccil.org/~cowan/XML/tagsoup/ I've just looked at the build changes. I'll leave someone with better knowledge of the source code to look at those changes. With Makefile.am, I don't see why NETX_DUMMY_CLASSPATH is needed or the additional rule that creates a JAR file. Neither do you need to set NETX_EXCLUDE_SRCS to empty; this is the default. if HAVE_TAGSOUP NETX_CLASSPATH_ARG=-classpath $(TAGSOUP_JAR) NETX_LAUNCHER_ARG="-Xbootclasspath/a:$(TAGSOUP_JAR)" else NETX_EXCLUDE_SRCS+=net.sourceforge.jnlp.MalformedXMLParser.java endif would work fine and you can drop the netx-dummy.jar rule. Should we really be putting tagsoup on the bootclasspath? What's wrong with the classpath? As to excluding the file, have you tested this? Are you sure no other Java files pull that class in? For configure, the argument should be the path to the jar file. Otherwise, the JAR file always has to be 'tagsoup.jar' which may not be the case. You should also check /usr/share/tagsoup/lib/tagsoup.jar which is the Gentoo installation path. Debian uses /usr/share/java/tagsoup.jar as already checked. > diff -r dc02a605f905 Makefile.am > --- a/Makefile.am Fri Jan 07 08:00:08 2011 -0500 > +++ b/Makefile.am Mon Jan 10 16:36:44 2011 -0500 > @@ -31,6 +31,10 @@ > net.sourceforge.jnlp.services net.sourceforge.jnlp.tools \ > net.sourceforge.jnlp.util net.sourceforge.jnlp.controlpanel > > +NETX_EXCLUDE_SRCS= > + > +NETX_DUMMY_CLASSPATH:=netx-dummy.jar > + > # Conditional defintions > if ENABLE_PLUGIN > ICEDTEAPLUGIN_CLEAN = clean-IcedTeaPlugin > @@ -68,6 +72,13 @@ > endif > endif > > +if HAVE_TAGSOUP > +NETX_CLASSPATH=$(NETX_DUMMY_CLASSPATH):$(TAGSOUP_JAR) > +else > +NETX_CLASSPATH=$(NETX_DUMMY_CLASSPATH) > +NETX_EXCLUDE_SRCS+=net.sourceforge.jnlp.MalformedXMLParser.java > +endif > + > # Launcher > > LAUNCHER_SRCDIR = $(abs_top_srcdir)/launcher > @@ -279,14 +290,19 @@ > # a patch applied to sun.plugin.AppletViewerPanel and generated sources > > netx-source-files.txt: > - find $(NETX_SRCDIR) -name '*.java' | sort > $@ > + find $(NETX_SRCDIR) -name '*.java' | sort > $@ ; \ > + for src in $(NETX_EXCLUDE_SRCS) ; \ > + do \ > + sed -i "/$${src}/ d" $@ ; \ > + done > > -stamps/netx.stamp: netx-source-files.txt stamps/bootstrap-directory.stamp > +stamps/netx.stamp: netx-source-files.txt stamps/bootstrap-directory.stamp netx-dummy.jar > mkdir -p $(NETX_DIR) > $(BOOT_DIR)/bin/javac $(IT_JAVACFLAGS) \ > -d $(NETX_DIR) \ > -sourcepath $(NETX_SRCDIR) \ > -bootclasspath $(RUNTIME) \ > + -classpath $(NETX_CLASSPATH) \ > @netx-source-files.txt > (cd $(NETX_RESOURCE_DIR); \ > for files in $$(find . -type f); \ > @@ -297,6 +313,10 @@ > mkdir -p stamps > touch $@ > > +netx-dummy.jar: > + echo "Manifest-Version: 1.0" > netx-dummy-manifest.mf > + jar cfm $@ netx-dummy-manifest.mf > + > stamps/netx-dist.stamp: stamps/netx.stamp > (cd $(NETX_DIR) ; \ > mkdir -p lib ; \ > @@ -312,6 +332,7 @@ > > clean-netx: > rm -rf $(NETX_DIR) > + rm -f netx-dummy.jar > rm -f stamps/netx-dist.stamp > rm -f netx-source-files.txt > rm -f stamps/netx.stamp > @@ -349,7 +370,7 @@ > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > mkdir -p $(NETX_DIR)/launcher && \ > $(CC) $(LAUNCHER_FLAGS) \ > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > + -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "-Xbootclasspath/a:$(NETX_CLASSPATH)", "net.sourceforge.jnlp.runtime.Boot", }' \ > -DPROGNAME='"javaws"' -c -o $@ $< > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > diff -r dc02a605f905 NEWS > --- a/NEWS Fri Jan 07 08:00:08 2011 -0500 > +++ b/NEWS Mon Jan 10 16:36:44 2011 -0500 > @@ -8,7 +8,12 @@ > > CVE-XXXX-YYYY: http://www.cve.mitre.org/cgi-bin/cvename.cgi?name=XXXX-YYYY > > -New in release 1.0 (2010-XX-XX): > +New in release 1.1 (2011-XX-XX): > + > +* NetX > + - Netx can now parse malformed jnlp files using tagsoup > + > +New in release 1.0 (2011-XX-XX): > > * Initial release of IcedTea-Web > * Security updates > diff -r dc02a605f905 acinclude.m4 > --- a/acinclude.m4 Fri Jan 07 08:00:08 2011 -0500 > +++ b/acinclude.m4 Mon Jan 10 16:36:44 2011 -0500 > @@ -297,6 +297,33 @@ > fi > ]) > > + > +AC_DEFUN_ONCE([IT_CHECK_FOR_TAGSOUP], > +[ > + AC_MSG_CHECKING([for tagsoup]) > + AC_ARG_WITH([tagsoup], > + [AS_HELP_STRING([--with-tagsoup], > + [tagsoup.jar])], > + [ > + TAGSOUP_JAR=${withval} > + ], > + [ > + TAGSOUP_JAR= > + ]) > + if test -z "${TAGSOUP_JAR}"; then > + for dir in /usr/share/java /usr/local/share/java ; do > + if test -f $dir/tagsoup.jar; then > + TAGSOUP_JAR=$dir/tagsoup.jar > + break > + fi > + done > + fi > + AC_MSG_RESULT(${TAGSOUP_JAR}) > + AC_SUBST(TAGSOUP_JAR) > + AM_CONDITIONAL([HAVE_TAGSOUP], [test x$TAGSOUP_JAR != xno]) > +]) > + > + > dnl Generic macro to check for a Java class > dnl Takes the name of the class as an argument. The macro name > dnl is usually the name of the class with '.' > diff -r dc02a605f905 configure.ac > --- a/configure.ac Fri Jan 07 08:00:08 2011 -0500 > +++ b/configure.ac Mon Jan 10 16:36:44 2011 -0500 > @@ -80,4 +80,6 @@ > IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) > IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE > > +IT_CHECK_FOR_TAGSOUP > + > AC_OUTPUT > diff -r dc02a605f905 netx/net/sourceforge/jnlp/JNLPFile.java > --- a/netx/net/sourceforge/jnlp/JNLPFile.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/JNLPFile.java Mon Jan 10 16:36:44 2011 -0500 > @@ -67,6 +67,9 @@ > /** the network location of this JNLP file */ > protected URL fileLocation; > > + /** the ParserSettings which were used to parse this file */ > + protected ParserSettings parserSettings = null; > + > /** A key that uniquely identifies connected instances (main jnlp+ext) */ > protected String uniqueKey = null; > > @@ -132,7 +135,7 @@ > * @throws ParseException if the JNLP file was invalid > */ > public JNLPFile(URL location) throws IOException, ParseException { > - this(location, false); // not strict > + this(location, new ParserSettings()); > } > > /** > @@ -140,12 +143,12 @@ > * default policy. > * > * @param location the location of the JNLP file > - * @param strict whether to enforce the spec when > + * @param settings the parser settings to use while parsing the file > * @throws IOException if an IO exception occurred > * @throws ParseException if the JNLP file was invalid > */ > - public JNLPFile(URL location, boolean strict) throws IOException, ParseException { > - this(location, (Version) null, strict); > + public JNLPFile(URL location, ParserSettings settings) throws IOException, ParseException { > + this(location, (Version) null, settings); > } > > /** > @@ -154,12 +157,12 @@ > * > * @param location the location of the JNLP file > * @param version the version of the JNLP file > - * @param strict whether to enforce the spec when > + * @param settings the parser settings to use while parsing the file > * @throws IOException if an IO exception occurred > * @throws ParseException if the JNLP file was invalid > */ > - public JNLPFile(URL location, Version version, boolean strict) throws IOException, ParseException { > - this(location, version, strict, JNLPRuntime.getDefaultUpdatePolicy()); > + public JNLPFile(URL location, Version version, ParserSettings settings) throws IOException, ParseException { > + this(location, version, settings, JNLPRuntime.getDefaultUpdatePolicy()); > } > > /** > @@ -168,14 +171,15 @@ > * > * @param location the location of the JNLP file > * @param version the version of the JNLP file > - * @param strict whether to enforce the spec when > + * @param settings the parser settings to use while parsing the file > * @param policy the update policy > * @throws IOException if an IO exception occurred > * @throws ParseException if the JNLP file was invalid > */ > - public JNLPFile(URL location, Version version, boolean strict, UpdatePolicy policy) throws IOException, ParseException { > - Node root = Parser.getRootNode(openURL(location, version, policy)); > - parse(root, strict, location); > + public JNLPFile(URL location, Version version, ParserSettings settings, UpdatePolicy policy) throws IOException, ParseException { > + this.parserSettings = settings; > + > + parse(openURL(location, version, policy), location); > > //Downloads the original jnlp file into the cache if possible > //(i.e. If the jnlp file being launched exist locally, but it > @@ -202,13 +206,13 @@ > * @param location the location of the JNLP file > * @param uniqueKey A string that uniquely identifies connected instances > * @param version the version of the JNLP file > - * @param strict whether to enforce the spec when > + * @param settings the parser settings to use while parsing the file > * @param policy the update policy > * @throws IOException if an IO exception occurred > * @throws ParseException if the JNLP file was invalid > */ > - public JNLPFile(URL location, String uniqueKey, Version version, boolean strict, UpdatePolicy policy) throws IOException, ParseException { > - this(location, version, strict, policy); > + public JNLPFile(URL location, String uniqueKey, Version version, ParserSettings settings, UpdatePolicy policy) throws IOException, ParseException { > + this(location, version, settings, policy); > this.uniqueKey = uniqueKey; > > if (JNLPRuntime.isDebug()) > @@ -218,11 +222,14 @@ > /** > * Create a JNLPFile from an input stream. > * > + * @param input input stream to read the JNLP file from > + * @param settings the parser settings to use while parsing the file > * @throws IOException if an IO exception occurred > * @throws ParseException if the JNLP file was invalid > */ > - public JNLPFile(InputStream input, boolean strict) throws ParseException { > - parse(Parser.getRootNode(input), strict, null); > + public JNLPFile(InputStream input, ParserSettings settings) throws ParseException { > + this.parserSettings = settings; > + parse(input, null); > } > > /** > @@ -288,6 +295,13 @@ > } > > /** > + * Returns the ParserSettings that was used to parse this file > + */ > + public ParserSettings getParserSettings() { > + return parserSettings; > + } > + > + /** > * Returns the JNLP file's version. > */ > public Version getFileVersion() { > @@ -548,12 +562,13 @@ > * @param strict whether to enforce the spec when > * @param location the file location or null > */ > - private void parse(Node root, boolean strict, URL location) throws ParseException { > + private void parse(InputStream input, URL location) throws ParseException { > try { > //if (location != null) > // location = new URL(location, "."); // remove filename > > - Parser parser = new Parser(this, location, root, strict, true); // true == allow extensions > + Node root = Parser.getRootNode(input, parserSettings); > + Parser parser = new Parser(this, location, root, parserSettings); > > // JNLP tag information > specVersion = parser.getSpecVersion(); > diff -r dc02a605f905 netx/net/sourceforge/jnlp/Launcher.java > --- a/netx/net/sourceforge/jnlp/Launcher.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/Launcher.java Mon Jan 10 16:36:44 2011 -0500 > @@ -360,9 +360,11 @@ > JNLPFile file = null; > > try { > - file = new JNLPFile(location, (Version) null, true, updatePolicy); // strict > + ParserSettings settings = new ParserSettings(true, true, false); > + file = new JNLPFile(location, (Version) null, settings, updatePolicy); // strict > } catch (ParseException ex) { > - file = new JNLPFile(location, (Version) null, false, updatePolicy); > + ParserSettings settings = new ParserSettings(false, true, true); > + file = new JNLPFile(location, (Version) null, settings, updatePolicy); > > // only here if strict failed but lax did not fail > LaunchException lex = > diff -r dc02a605f905 netx/net/sourceforge/jnlp/MalformedXMLParser.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/MalformedXMLParser.java Mon Jan 10 16:36:44 2011 -0500 > @@ -0,0 +1,101 @@ > +// Copyright (C) 2011 Red Hat, Inc. > +// > +// This library is free software; you can redistribute it and/or > +// modify it under the terms of the GNU Lesser General Public > +// License as published by the Free Software Foundation; either > +// version 2.1 of the License, or (at your option) any later version. > +// > +// This library is distributed in the hope that it will be useful, > +// but WITHOUT ANY WARRANTY; without even the implied warranty of > +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > +// Lesser General Public License for more details. > +// > +// You should have received a copy of the GNU Lesser General Public > +// License along with this library; if not, write to the Free Software > +// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. > + > +package net.sourceforge.jnlp; > + > +import static net.sourceforge.jnlp.runtime.Translator.R; > + > +import java.io.ByteArrayInputStream; > +import java.io.ByteArrayOutputStream; > +import java.io.IOException; > +import java.io.InputStream; > +import java.io.OutputStreamWriter; > +import java.io.Writer; > + > +import net.sourceforge.jnlp.runtime.JNLPRuntime; > + > +import org.ccil.cowan.tagsoup.HTMLSchema; > +import org.ccil.cowan.tagsoup.Parser; > +import org.ccil.cowan.tagsoup.XMLWriter; > +import org.xml.sax.InputSource; > +import org.xml.sax.SAXException; > +import org.xml.sax.XMLReader; > + > +/** > + * An specialized {@link XMLParser} that uses TagSoup[1] to parse > + * malformed XML > + * > + * Used by net.sourceforge.jnlp.Parser > + * > + * [1] http://home.ccil.org/~cowan/XML/tagsoup/ > + */ > +public class MalformedXMLParser extends XMLParser { > + > + /** > + * Parses the data from an {@link InputStream} to create a XML tree. > + * Returns a {@link Node} representing the root of the tree. > + * > + * @param input the {@link InputStream} to read data from > + * @throws ParseException if an exception occurs while parsing the input > + */ > + @Override > + public Node getRootNode(InputStream input) throws ParseException { > + if (JNLPRuntime.isDebug()) { > + System.out.println("Using MalformedXMLParser"); > + } > + InputStream xmlInput = xmlizeInputStream(input); > + return super.getRootNode(xmlInput); > + } > + > + /** > + * Reads malformed XML from the InputStream original and returns a new > + * InputStream which can be used to read a well-formed version of the input > + * > + * @param original > + * @return an {@link InputStream} which can be used to read a well-formed > + * version of the input XML > + * @throws ParseException > + */ > + private InputStream xmlizeInputStream(InputStream original) throws ParseException { > + try { > + ByteArrayOutputStream out = new ByteArrayOutputStream(); > + > + HTMLSchema schema = new HTMLSchema(); > + XMLReader reader = new Parser(); > + > + reader.setProperty(Parser.schemaProperty, schema); > + reader.setFeature(Parser.bogonsEmptyFeature, false); > + reader.setFeature(Parser.ignorableWhitespaceFeature, true); > + reader.setFeature(Parser.ignoreBogonsFeature, false); > + > + Writer writeger = new OutputStreamWriter(out); > + XMLWriter x = new XMLWriter(writeger); > + > + reader.setContentHandler(x); > + > + InputSource s = new InputSource(original); > + > + reader.parse(s); > + return new ByteArrayInputStream(out.toByteArray()); > + } catch (SAXException e) { > + throw new ParseException(R("PBadXML"), e); > + } catch (IOException e) { > + throw new ParseException(R("PBadXML"), e); > + } > + > + } > + > +} > diff -r dc02a605f905 netx/net/sourceforge/jnlp/Parser.java > --- a/netx/net/sourceforge/jnlp/Parser.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/Parser.java Mon Jan 10 16:36:44 2011 -0500 > @@ -1,5 +1,5 @@ > // Copyright (C) 2001-2003 Jon A. Maxwell (JAM) > -// Copyright (C) 2009 Red Hat, Inc. > +// Copyright (C) 2011 Red Hat, Inc. > // > // This library is free software; you can redistribute it and/or > // modify it under the terms of the GNU Lesser General Public > @@ -20,15 +20,13 @@ > import static net.sourceforge.jnlp.runtime.Translator.R; > > import java.io.*; > +import java.lang.reflect.InvocationTargetException; > +import java.lang.reflect.Method; > import java.net.*; > import java.util.*; > -//import javax.xml.parsers.*; // commented to use right Node > -//import org.w3c.dom.*; // class for using Tiny XML | NanoXML > -//import org.xml.sax.*; > -//import gd.xml.tiny.*; > + > import net.sourceforge.jnlp.UpdateDesc.Check; > import net.sourceforge.jnlp.UpdateDesc.Policy; > -import net.sourceforge.nanoxml.*; > > /** > * Contains methods to parse an XML document into a JNLPFile. > @@ -105,15 +103,14 @@ > * @param file the (uninitialized) file reference > * @param base if codebase is not specified, a default base for relative URLs > * @param root the root node > - * @param strict whether to enforce strict compliance with the JNLP spec > - * @param allowExtensions whether to allow extensions to the JNLP spec > + * @param settings the parser settings to use when parsing the JNLP file > * @throws ParseException if the JNLP file is invalid > */ > - public Parser(JNLPFile file, URL base, Node root, boolean strict, boolean allowExtensions) throws ParseException { > + public Parser(JNLPFile file, URL base, Node root, ParserSettings settings) throws ParseException { > this.file = file; > this.root = root; > - this.strict = strict; > - this.allowExtensions = allowExtensions; > + this.strict = settings.isStrict(); > + this.allowExtensions = settings.isExtensionAllowed(); > > // ensure it's a JNLP node > if (root == null || !root.getNodeName().equals("jnlp")) > @@ -1205,116 +1202,33 @@ > * > * @throws ParseException if the JNLP file is invalid > */ > - public static Node getRootNode(InputStream input) throws ParseException { > + public static Node getRootNode(InputStream input, ParserSettings settings) throws ParseException { > + String className = null; > + if (settings.isMalfromedXmlAllowed()) { > + className = "net.sourceforge.jnlp.MalformedXMLParser"; > + } else { > + className = "net.sourceforge.jnlp.XMLParser"; > + } > + > try { > - /* SAX > - DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); > - factory.setValidating(false); > - factory.setNamespaceAware(true); > - DocumentBuilder builder = factory.newDocumentBuilder(); > - builder.setErrorHandler(errorHandler); > + Class klass = null; > + try { > + klass = Class.forName(className); > + } catch (ClassNotFoundException e) { > + klass = Class.forName("net.sourceforge.jnlp.XMLParser"); > + } > + Object instance = klass.newInstance(); > + Method m = klass.getMethod("getRootNode", InputStream.class); > > - Document doc = builder.parse(input); > - return doc.getDocumentElement(); > - */ > - > - /* TINY > - Node document = new Node(TinyParser.parseXML(input)); > - Node jnlpNode = getChildNode(document, "jnlp"); // skip comments > - */ > - > - //A BufferedInputStream is used to allow marking and reseting > - //of a stream. > - BufferedInputStream bs = new BufferedInputStream(input); > - > - /* NANO */ > - final XMLElement xml = new XMLElement(); > - final PipedInputStream pin = new PipedInputStream(); > - final PipedOutputStream pout = new PipedOutputStream(pin); > - final InputStreamReader isr = new InputStreamReader(bs, getEncoding(bs)); > - // Clean the jnlp xml file of all comments before passing > - // it to the parser. > - new Thread( > - new Runnable() { > - public void run() { > - (new XMLElement()).sanitizeInput(isr, pout); > - try { > - pout.close(); > - } catch (IOException ioe) { > - ioe.printStackTrace(); > - } > - } > - }).start(); > - xml.parseFromReader(new InputStreamReader(pin)); > - Node jnlpNode = new Node(xml); > - return jnlpNode; > - } catch (Exception ex) { > - throw new ParseException(R("PBadXML"), ex); > + return (Node) m.invoke(instance, input); > + } catch (InvocationTargetException e) { > + if (e.getCause() instanceof ParseException) { > + throw (ParseException)(e.getCause()); > + } > + throw new ParseException(R("PBadXML"), e); > + } catch (Exception e) { > + throw new ParseException(R("PBadXML"), e); > } > } > > - /** > - * Returns the name of the encoding used in this InputStream. > - * > - * @param input the InputStream > - * @return a String representation of encoding > - */ > - private static String getEncoding(InputStream input) throws IOException { > - //Fixme: This only recognizes UTF-8, UTF-16, and > - //UTF-32, which is enough to parse the prolog portion of xml to > - //find out the exact encoding (if it exists). The reason being > - //there could be other encodings, such as ISO 8859 which is 8-bits > - //but it supports latin characters. > - //So what needs to be done is to parse the prolog and retrieve > - //the exact encoding from it. > - > - int[] s = new int[4]; > - String encoding = "UTF-8"; > - > - //Determine what the first four bytes are and store > - //them into an int array. > - input.mark(4); > - for (int i = 0; i < 4; i++) { > - s[i] = input.read(); > - } > - input.reset(); > - > - //Set the encoding base on what the first four bytes of the > - //inputstream turn out to be (following the information from > - //www.w3.org/TR/REC-xml/#sec-guessing). > - if (s[0] == 255) { > - if (s[1] == 254) { > - if (s[2] != 0 || s[3] != 0) { > - encoding = "UnicodeLittle"; > - } else { > - encoding = "X-UTF-32LE-BOM"; > - } > - } > - } else if (s[0] == 254 && s[1] == 255 && (s[2] != 0 || > - s[3] != 0)) { > - encoding = "UTF-16"; > - > - } else if (s[0] == 0 && s[1] == 0 && s[2] == 254 && > - s[3] == 255) { > - encoding = "X-UTF-32BE-BOM"; > - > - } else if (s[0] == 0 && s[1] == 0 && s[2] == 0 && > - s[3] == 60) { > - encoding = "UTF-32BE"; > - > - } else if (s[0] == 60 && s[1] == 0 && s[2] == 0 && > - s[3] == 0) { > - encoding = "UTF-32LE"; > - > - } else if (s[0] == 0 && s[1] == 60 && s[2] == 0 && > - s[3] == 63) { > - encoding = "UTF-16BE"; > - } else if (s[0] == 60 && s[1] == 0 && s[2] == 63 && > - s[3] == 0) { > - encoding = "UTF-16LE"; > - } > - > - return encoding; > - } > - > } > diff -r dc02a605f905 netx/net/sourceforge/jnlp/ParserSettings.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/ParserSettings.java Mon Jan 10 16:36:44 2011 -0500 > @@ -0,0 +1,55 @@ > +// Copyright (C) 2011 Red Hat, Inc. > +// > +// This library is free software; you can redistribute it and/or > +// modify it under the terms of the GNU Lesser General Public > +// License as published by the Free Software Foundation; either > +// version 2.1 of the License, or (at your option) any later version. > +// > +// This library is distributed in the hope that it will be useful, > +// but WITHOUT ANY WARRANTY; without even the implied warranty of > +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > +// Lesser General Public License for more details. > +// > +// You should have received a copy of the GNU Lesser General Public > +// License along with this library; if not, write to the Free Software > +// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. > + > +package net.sourceforge.jnlp; > + > +/** > + * Encapsulates settings to use with the JNLP Parser > + */ > +public class ParserSettings { > + > + private final boolean strict; > + private final boolean extensionAllowed; > + private final boolean malformedXmlAllowed; > + > + /** Create a new ParserSettings with the defautl parser settings */ > + public ParserSettings() { > + this(false, true, true); > + } > + > + /** Create a new ParserSettings object */ > + public ParserSettings(boolean strict, boolean extensionAllowed, boolean malformedXmlAllowed) { > + this.strict = strict; > + this.extensionAllowed = extensionAllowed; > + this.malformedXmlAllowed = malformedXmlAllowed; > + } > + > + /** @return true if extensions to the spec are allowed */ > + public boolean isExtensionAllowed() { > + return extensionAllowed; > + } > + > + /** @return true if parsing malformed xml is allowed */ > + public boolean isMalfromedXmlAllowed() { > + return malformedXmlAllowed; > + } > + > + /** @return true if strict parsing mode is to be used */ > + public boolean isStrict() { > + return strict; > + } > + > +} > diff -r dc02a605f905 netx/net/sourceforge/jnlp/XMLParser.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/XMLParser.java Mon Jan 10 16:36:44 2011 -0500 > @@ -0,0 +1,163 @@ > +// Copyright (C) 2001-2003 Jon A. Maxwell (JAM) > +// Copyright (C) 2011 Red Hat, Inc. > +// > +// This library is free software; you can redistribute it and/or > +// modify it under the terms of the GNU Lesser General Public > +// License as published by the Free Software Foundation; either > +// version 2.1 of the License, or (at your option) any later version. > +// > +// This library is distributed in the hope that it will be useful, > +// but WITHOUT ANY WARRANTY; without even the implied warranty of > +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > +// Lesser General Public License for more details. > +// > +// You should have received a copy of the GNU Lesser General Public > +// License along with this library; if not, write to the Free Software > +// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. > + > +package net.sourceforge.jnlp; > + > +import static net.sourceforge.jnlp.runtime.Translator.R; > + > +import java.io.BufferedInputStream; > +import java.io.IOException; > +import java.io.InputStream; > +import java.io.InputStreamReader; > +import java.io.PipedInputStream; > +import java.io.PipedOutputStream; > + > +import net.sourceforge.nanoxml.XMLElement; > + > +//import javax.xml.parsers.*; // commented to use right Node > +//import org.w3c.dom.*; // class for using Tiny XML | NanoXML > +//import org.xml.sax.*; > +//import gd.xml.tiny.*; > + > +/** > + * A gateway to the actual implementation of the parsers. > + * > + * Used by net.sourceforge.jnlp.Parser > + */ > +class XMLParser { > + > + /** > + * Parses input from an InputStream and returns a Node representing the > + * root of the parse tree. > + * > + * @param input the {@link InputStream} containing the XML > + * @return a {@link Node} representing the root of the parsed XML > + * @throws ParseException > + */ > + public Node getRootNode(InputStream input) throws ParseException { > + > + try { > + /* SAX > + DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); > + factory.setValidating(false); > + factory.setNamespaceAware(true); > + DocumentBuilder builder = factory.newDocumentBuilder(); > + builder.setErrorHandler(errorHandler); > + > + Document doc = builder.parse(input); > + return doc.getDocumentElement(); > + */ > + > + /* TINY > + Node document = new Node(TinyParser.parseXML(input)); > + Node jnlpNode = getChildNode(document, "jnlp"); // skip comments > + */ > + > + //A BufferedInputStream is used to allow marking and reseting > + //of a stream. > + BufferedInputStream bs = new BufferedInputStream(input); > + > + /* NANO */ > + final XMLElement xml = new XMLElement(); > + final PipedInputStream pin = new PipedInputStream(); > + final PipedOutputStream pout = new PipedOutputStream(pin); > + final InputStreamReader isr = new InputStreamReader(bs, getEncoding(bs)); > + // Clean the jnlp xml file of all comments before passing > + // it to the parser. > + new Thread( > + new Runnable() { > + public void run() { > + (new XMLElement()).sanitizeInput(isr, pout); > + try { > + pout.close(); > + } catch (IOException ioe) { > + ioe.printStackTrace(); > + } > + } > + }).start(); > + xml.parseFromReader(new InputStreamReader(pin)); > + Node jnlpNode = new Node(xml); > + return jnlpNode; > + } catch (Exception ex) { > + throw new ParseException(R("PBadXML"), ex); > + } > + } > + > + /** > + * Returns the name of the encoding used in this InputStream. > + * > + * @param input the InputStream > + * @return a String representation of encoding > + */ > + private static String getEncoding(InputStream input) throws IOException { > + //Fixme: This only recognizes UTF-8, UTF-16, and > + //UTF-32, which is enough to parse the prolog portion of xml to > + //find out the exact encoding (if it exists). The reason being > + //there could be other encodings, such as ISO 8859 which is 8-bits > + //but it supports latin characters. > + //So what needs to be done is to parse the prolog and retrieve > + //the exact encoding from it. > + > + int[] s = new int[4]; > + String encoding = "UTF-8"; > + > + //Determine what the first four bytes are and store > + //them into an int array. > + input.mark(4); > + for (int i = 0; i < 4; i++) { > + s[i] = input.read(); > + } > + input.reset(); > + > + //Set the encoding base on what the first four bytes of the > + //inputstream turn out to be (following the information from > + //www.w3.org/TR/REC-xml/#sec-guessing). > + if (s[0] == 255) { > + if (s[1] == 254) { > + if (s[2] != 0 || s[3] != 0) { > + encoding = "UnicodeLittle"; > + } else { > + encoding = "X-UTF-32LE-BOM"; > + } > + } > + } else if (s[0] == 254 && s[1] == 255 && (s[2] != 0 || > + s[3] != 0)) { > + encoding = "UTF-16"; > + > + } else if (s[0] == 0 && s[1] == 0 && s[2] == 254 && > + s[3] == 255) { > + encoding = "X-UTF-32BE-BOM"; > + > + } else if (s[0] == 0 && s[1] == 0 && s[2] == 0 && > + s[3] == 60) { > + encoding = "UTF-32BE"; > + > + } else if (s[0] == 60 && s[1] == 0 && s[2] == 0 && > + s[3] == 0) { > + encoding = "UTF-32LE"; > + > + } else if (s[0] == 0 && s[1] == 60 && s[2] == 0 && > + s[3] == 63) { > + encoding = "UTF-16BE"; > + } else if (s[0] == 60 && s[1] == 0 && s[2] == 63 && > + s[3] == 0) { > + encoding = "UTF-16LE"; > + } > + > + return encoding; > + } > +} > diff -r dc02a605f905 netx/net/sourceforge/jnlp/resources/Messages.properties > --- a/netx/net/sourceforge/jnlp/resources/Messages.properties Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/resources/Messages.properties Mon Jan 10 16:36:44 2011 -0500 > @@ -158,6 +158,7 @@ > BOHeadless = Disables download window, other UIs. > BOStrict = Enables strict checking of JNLP file format. > BOViewer = Shows the trusted certificate viewer. > +BOXml = Uses an XML parser to parse the JNLP file. > BXnofork = Do not create another JVM. > BXclearcache= Clean the JNLP application cache. > BOHelp = Print this message and exit. > diff -r dc02a605f905 netx/net/sourceforge/jnlp/runtime/Boot.java > --- a/netx/net/sourceforge/jnlp/runtime/Boot.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/Boot.java Mon Jan 10 16:36:44 2011 -0500 > @@ -34,6 +34,7 @@ > import net.sourceforge.jnlp.LaunchException; > import net.sourceforge.jnlp.Launcher; > import net.sourceforge.jnlp.ParseException; > +import net.sourceforge.jnlp.ParserSettings; > import net.sourceforge.jnlp.PropertyDesc; > import net.sourceforge.jnlp.ResourcesDesc; > import net.sourceforge.jnlp.cache.CacheUtil; > @@ -104,6 +105,7 @@ > + " -noupdate " + R("BONoupdate") + "\n" > + " -headless " + R("BOHeadless") + "\n" > + " -strict " + R("BOStrict") + "\n" > + + " -xml " + R("BOXml") + "\n" > + " -Xnofork " + R("BXnofork") + "\n" > + " -Xclearcache " + R("BXclearcache") + "\n" > + " -help " + R("BOHelp") + "\n"; > @@ -262,13 +264,22 @@ > e.printStackTrace(); > } > > - boolean strict = (null != getOption("-strict")); > + boolean strict = false; > + boolean malformedXmlAllowed = true; > > - JNLPFile file = new JNLPFile(url, strict); > + if (null != getOption("-strict")) { > + strict = true; > + } > + if (null != getOption("-xml")) { > + malformedXmlAllowed = false; > + } > + ParserSettings settings = new ParserSettings(strict, true, malformedXmlAllowed); > + > + JNLPFile file = new JNLPFile(url, settings); > > // Launches the jnlp file where this file originated. > if (file.getSourceLocation() != null) { > - file = new JNLPFile(file.getSourceLocation(), strict); > + file = new JNLPFile(file.getSourceLocation(), settings); > } > > // add in extra params from command line > diff -r dc02a605f905 netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java > --- a/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Mon Jan 10 16:36:44 2011 -0500 > @@ -50,6 +50,7 @@ > import net.sourceforge.jnlp.JNLPFile; > import net.sourceforge.jnlp.LaunchException; > import net.sourceforge.jnlp.ParseException; > +import net.sourceforge.jnlp.ParserSettings; > import net.sourceforge.jnlp.PluginBridge; > import net.sourceforge.jnlp.ResourcesDesc; > import net.sourceforge.jnlp.SecurityDesc; > @@ -324,12 +325,12 @@ > * @param version the file's version > * @param policy the update policy to use when downloading resources > */ > - public static JNLPClassLoader getInstance(URL location, String uniqueKey, Version version, UpdatePolicy policy) > + public static JNLPClassLoader getInstance(URL location, String uniqueKey, Version version, ParserSettings settings, UpdatePolicy policy) > throws IOException, ParseException, LaunchException { > JNLPClassLoader loader = urlToLoader.get(uniqueKey); > > if (loader == null || !location.equals(loader.getJNLPFile().getFileLocation())) > - loader = getInstance(new JNLPFile(location, uniqueKey, version, false, policy), policy); > + loader = getInstance(new JNLPFile(location, uniqueKey, version, settings, policy), policy); > > return loader; > } > @@ -348,7 +349,7 @@ > for (int i = 0; i < ext.length; i++) { > try { > String uniqueKey = this.getJNLPFile().getUniqueKey(); > - JNLPClassLoader loader = getInstance(ext[i].getLocation(), uniqueKey, ext[i].getVersion(), updatePolicy); > + JNLPClassLoader loader = getInstance(ext[i].getLocation(), uniqueKey, ext[i].getVersion(), file.getParserSettings(), updatePolicy); > loaderList.add(loader); > } catch (Exception ex) { > ex.printStackTrace(); -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From andrew at icedtea.classpath.org Mon Jan 10 15:47:21 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Mon, 10 Jan 2011 23:47:21 +0000 Subject: /hg/icedtea6-hg: 2 new changesets Message-ID: changeset 52c2b4ff95ed in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=52c2b4ff95ed author: Andrew John Hughes date: Mon Jan 10 21:26:50 2011 +0000 Remove upstreamed patches: 6541476, 6782079 and 7002666. 2011-01-10 Andrew John Hughes * patches/openjdk/6541476-png-iTXt-chunk.patch, * patches/openjdk/6782079-png_metadata_oom.patch, * patches/openjdk/7002666-eclipse_cdt_oops_crash.patch: Drop upstreamed patches. * Makefile.am: Remove above patches. changeset b645d7e86c18 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=b645d7e86c18 author: Andrew John Hughes date: Mon Jan 10 23:47:02 2011 +0000 Bump to b21. 2011-01-10 Andrew John Hughes * Makefile.am: (OPENJDK_VERSION): Bump to b21. diffstat: 5 files changed, 15 insertions(+), 4754 deletions(-) ChangeLog | 14 Makefile.am | 5 patches/openjdk/6541476-png-iTXt-chunk.patch | 549 -- patches/openjdk/6782079-png_metadata_oom.patch | 4122 ------------------ patches/openjdk/7002666-eclipse_cdt_oops_crash.patch | 79 diffs (truncated from 4810 to 500 lines): diff -r 3c63d5967d08 -r b645d7e86c18 ChangeLog --- a/ChangeLog Sun Jan 09 00:46:45 2011 +0000 +++ b/ChangeLog Mon Jan 10 23:47:02 2011 +0000 @@ -1,3 +1,17 @@ 2011-01-07 Andrew John Hughes + + * Makefile.am: + (OPENJDK_VERSION): Bump to b21. + +2011-01-10 Andrew John Hughes + + * patches/openjdk/6541476-png-iTXt-chunk.patch, + * patches/openjdk/6782079-png_metadata_oom.patch, + * patches/openjdk/7002666-eclipse_cdt_oops_crash.patch: + Drop upstreamed patches. + * Makefile.am: + Remove above patches. + 2011-01-07 Andrew John Hughes * patches/jtreg-TestXEmbedServer-fix.patch: diff -r 3c63d5967d08 -r b645d7e86c18 Makefile.am --- a/Makefile.am Sun Jan 09 00:46:45 2011 +0000 +++ b/Makefile.am Mon Jan 10 23:47:02 2011 +0000 @@ -2,7 +2,7 @@ OPENJDK_DATE = 21_jun_2010 OPENJDK_MD5SUM = 0b36adbf67e4f261e1b827ed4be4f447 -OPENJDK_VERSION = b20 +OPENJDK_VERSION = b21 OPENJDK_URL = http://download.java.net/openjdk/jdk6/promoted/$(OPENJDK_VERSION)/ CACAO_VERSION = 6a5eda011e49 @@ -266,14 +266,11 @@ ICEDTEA_PATCHES = \ patches/jtreg-DeleteFont.patch \ patches/jtreg-WindowWithWarningTest.patch \ patches/jtreg-T6638712-fix.patch \ - patches/openjdk/7002666-eclipse_cdt_oops_crash.patch \ patches/jtreg-T6650759m-fix.patch \ patches/openjdk/7003777-bad-html-entity-parse.patch \ patches/jtreg-6929067-fix.patch \ patches/rendering-engine-tests.patch \ patches/openjdk/6800846-printing-quality.patch \ - patches/openjdk/6541476-png-iTXt-chunk.patch \ - patches/openjdk/6782079-png_metadata_oom.patch \ patches/661505-jpeg.patch \ patches/openjdk/6980392-fix_test6581734.patch \ patches/6703377-freetypescaler.patch \ diff -r 3c63d5967d08 -r b645d7e86c18 patches/openjdk/6541476-png-iTXt-chunk.patch --- a/patches/openjdk/6541476-png-iTXt-chunk.patch Sun Jan 09 00:46:45 2011 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,549 +0,0 @@ -diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java ---- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java 2010-12-23 17:11:16.193446425 -0500 -+++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java 2010-12-23 17:11:29.399447037 -0500 -@@ -44,7 +44,6 @@ - import java.util.Arrays; - import java.util.Enumeration; - import java.util.Iterator; --import java.util.List; - import java.util.zip.Inflater; - import java.util.zip.InflaterInputStream; - import javax.imageio.IIOException; -@@ -57,6 +56,7 @@ - import com.sun.imageio.plugins.common.InputStreamAdapter; - import com.sun.imageio.plugins.common.ReaderUtil; - import com.sun.imageio.plugins.common.SubImageInputStream; -+import java.io.ByteArrayOutputStream; - import sun.awt.image.ByteInterleavedRaster; - - class PNGImageDataEnumeration implements Enumeration { -@@ -209,6 +209,15 @@ - resetStreamSettings(); - } - -+ private String readNullTerminatedString(String charset) throws IOException { -+ ByteArrayOutputStream baos = new ByteArrayOutputStream(); -+ int b; -+ while ((b = stream.read()) != 0) { -+ baos.write(b); -+ } -+ return new String(baos.toByteArray(), charset); -+ } -+ - private String readNullTerminatedString() throws IOException { - StringBuilder b = new StringBuilder(); - int c; -@@ -447,26 +456,27 @@ - metadata.iTXt_keyword.add(keyword); - - int compressionFlag = stream.readUnsignedByte(); -- metadata.iTXt_compressionFlag.add(new Integer(compressionFlag)); -+ metadata.iTXt_compressionFlag.add(Boolean.valueOf(compressionFlag == 1)); - - int compressionMethod = stream.readUnsignedByte(); -- metadata.iTXt_compressionMethod.add(new Integer(compressionMethod)); -+ metadata.iTXt_compressionMethod.add(Integer.valueOf(compressionMethod)); - -- String languageTag = readNullTerminatedString(); -+ String languageTag = readNullTerminatedString("UTF8"); - metadata.iTXt_languageTag.add(languageTag); - -- String translatedKeyword = stream.readUTF(); -+ String translatedKeyword = -+ readNullTerminatedString("UTF8"); - metadata.iTXt_translatedKeyword.add(translatedKeyword); -- stream.skipBytes(1); // Null separator - - String text; -+ long pos = stream.getStreamPosition(); -+ byte[] b = new byte[(int)(chunkStart + chunkLength - pos)]; -+ stream.readFully(b); -+ - if (compressionFlag == 1) { // Decompress the text -- long pos = stream.getStreamPosition(); -- byte[] b = new byte[(int)(chunkStart + chunkLength - pos)]; -- stream.readFully(b); -- text = inflate(b); -+ text = new String(inflate(b), "UTF8"); - } else { -- text = stream.readUTF(); -+ text = new String(b, "UTF8"); - } - metadata.iTXt_text.add(text); - } -@@ -615,20 +625,20 @@ - metadata.tRNS_present = true; - } - -- private static String inflate(byte[] b) throws IOException { -+ private static byte[] inflate(byte[] b) throws IOException { - InputStream bais = new ByteArrayInputStream(b); - InputStream iis = new InflaterInputStream(bais); -+ ByteArrayOutputStream baos = new ByteArrayOutputStream(); - -- StringBuilder sb = new StringBuilder(80); - int c; - try { - while ((c = iis.read()) != -1) { -- sb.append((char)c); -+ baos.write(c); - } - } finally { - iis.close(); - } -- return sb.toString(); -+ return baos.toByteArray(); - } - - private void parse_zTXt_chunk(int chunkLength) throws IOException { -@@ -640,7 +650,7 @@ - - byte[] b = new byte[chunkLength - keyword.length() - 2]; - stream.readFully(b); -- metadata.zTXt_text.add(inflate(b)); -+ metadata.zTXt_text.add(new String(inflate(b))); - } - - private void readMetadata() throws IIOException { -diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java ---- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java 2010-12-23 17:11:16.193446425 -0500 -+++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageWriter.java 2010-12-23 17:11:29.400446993 -0500 -@@ -671,13 +671,13 @@ - } - } - -- private byte[] deflate(String s) throws IOException { -+ private byte[] deflate(byte[] b) throws IOException { - ByteArrayOutputStream baos = new ByteArrayOutputStream(); - DeflaterOutputStream dos = new DeflaterOutputStream(baos); - -- int len = s.length(); -+ int len = b.length; - for (int i = 0; i < len; i++) { -- dos.write((int)s.charAt(i)); -+ dos.write((int)(0xff & b[i])); - } - dos.close(); - -@@ -685,38 +685,37 @@ - } - - private void write_iTXt() throws IOException { -- Iterator keywordIter = metadata.iTXt_keyword.iterator(); -- Iterator flagIter = metadata.iTXt_compressionFlag.iterator(); -- Iterator methodIter = metadata.iTXt_compressionMethod.iterator(); -- Iterator languageIter = metadata.iTXt_languageTag.iterator(); -- Iterator translatedKeywordIter = -+ Iterator keywordIter = metadata.iTXt_keyword.iterator(); -+ Iterator flagIter = metadata.iTXt_compressionFlag.iterator(); -+ Iterator methodIter = metadata.iTXt_compressionMethod.iterator(); -+ Iterator languageIter = metadata.iTXt_languageTag.iterator(); -+ Iterator translatedKeywordIter = - metadata.iTXt_translatedKeyword.iterator(); -- Iterator textIter = metadata.iTXt_text.iterator(); -+ Iterator textIter = metadata.iTXt_text.iterator(); - - while (keywordIter.hasNext()) { - ChunkStream cs = new ChunkStream(PNGImageReader.iTXt_TYPE, stream); -- String keyword = (String)keywordIter.next(); -- cs.writeBytes(keyword); -+ -+ cs.writeBytes(keywordIter.next()); - cs.writeByte(0); - -- int flag = ((Integer)flagIter.next()).intValue(); -- cs.writeByte(flag); -- int method = ((Integer)methodIter.next()).intValue(); -- cs.writeByte(method); -+ Boolean compressed = flagIter.next(); -+ cs.writeByte(compressed ? 1 : 0); - -- String languageTag = (String)languageIter.next(); -- cs.writeBytes(languageTag); -+ cs.writeByte(methodIter.next().intValue()); -+ -+ cs.writeBytes(languageIter.next()); - cs.writeByte(0); - -- String translatedKeyword = (String)translatedKeywordIter.next(); -- cs.writeBytes(translatedKeyword); -+ -+ cs.write(translatedKeywordIter.next().getBytes("UTF8")); - cs.writeByte(0); - -- String text = (String)textIter.next(); -- if (flag == 1) { -- cs.write(deflate(text)); -+ String text = textIter.next(); -+ if (compressed) { -+ cs.write(deflate(text.getBytes("UTF8"))); - } else { -- cs.writeUTF(text); -+ cs.write(text.getBytes("UTF8")); - } - cs.finish(); - } -@@ -737,7 +736,7 @@ - cs.writeByte(compressionMethod); - - String text = (String)textIter.next(); -- cs.write(deflate(text)); -+ cs.write(deflate(text.getBytes())); - cs.finish(); - } - } -diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java ---- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java 2010-06-21 17:15:11.000000000 -0400 -+++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGMetadata.java 2010-12-23 17:11:29.401446953 -0500 -@@ -176,12 +176,12 @@ - public byte[] iCCP_compressedProfile; - - // iTXt chunk -- public ArrayList iTXt_keyword = new ArrayList(); // Strings -- public ArrayList iTXt_compressionFlag = new ArrayList(); // Integers -- public ArrayList iTXt_compressionMethod = new ArrayList(); // Integers -- public ArrayList iTXt_languageTag = new ArrayList(); // Strings -- public ArrayList iTXt_translatedKeyword = new ArrayList(); // Strings -- public ArrayList iTXt_text = new ArrayList(); // Strings -+ public ArrayList iTXt_keyword = new ArrayList(); -+ public ArrayList iTXt_compressionFlag = new ArrayList(); -+ public ArrayList iTXt_compressionMethod = new ArrayList(); -+ public ArrayList iTXt_languageTag = new ArrayList(); -+ public ArrayList iTXt_translatedKeyword = new ArrayList(); -+ public ArrayList iTXt_text = new ArrayList(); - - // pHYs chunk - public boolean pHYs_present; -@@ -599,19 +599,17 @@ - if (iTXt_keyword.size() > 0) { - IIOMetadataNode iTXt_parent = new IIOMetadataNode("iTXt"); - for (int i = 0; i < iTXt_keyword.size(); i++) { -- Integer val; -- - IIOMetadataNode iTXt_node = new IIOMetadataNode("iTXtEntry"); -- iTXt_node.setAttribute("keyword", (String)iTXt_keyword.get(i)); -- val = (Integer)iTXt_compressionFlag.get(i); -- iTXt_node.setAttribute("compressionFlag", val.toString()); -- val = (Integer)iTXt_compressionMethod.get(i); -- iTXt_node.setAttribute("compressionMethod", val.toString()); -+ iTXt_node.setAttribute("keyword", iTXt_keyword.get(i)); -+ iTXt_node.setAttribute("compressionFlag", -+ iTXt_compressionFlag.get(i) ? "1" : "0"); -+ iTXt_node.setAttribute("compressionMethod", -+ iTXt_compressionMethod.get(i).toString()); - iTXt_node.setAttribute("languageTag", -- (String)iTXt_languageTag.get(i)); -+ iTXt_languageTag.get(i)); - iTXt_node.setAttribute("translatedKeyword", -- (String)iTXt_translatedKeyword.get(i)); -- iTXt_node.setAttribute("text", (String)iTXt_text.get(i)); -+ iTXt_translatedKeyword.get(i)); -+ iTXt_node.setAttribute("text", iTXt_text.get(i)); - - iTXt_parent.appendChild(iTXt_node); - } -@@ -1039,11 +1037,11 @@ - - for (int i = 0; i < iTXt_keyword.size(); i++) { - node = new IIOMetadataNode("TextEntry"); -- node.setAttribute("keyword", (String)iTXt_keyword.get(i)); -- node.setAttribute("value", (String)iTXt_text.get(i)); -+ node.setAttribute("keyword", iTXt_keyword.get(i)); -+ node.setAttribute("value", iTXt_text.get(i)); - node.setAttribute("language", -- (String)iTXt_languageTag.get(i)); -- if (((Integer)iTXt_compressionFlag.get(i)).intValue() == 1) { -+ iTXt_languageTag.get(i)); -+ if (iTXt_compressionFlag.get(i)) { - node.setAttribute("compression", "deflate"); - } else { - node.setAttribute("compression", "none"); -@@ -1429,11 +1427,11 @@ - - boolean compressionFlag = - getBooleanAttribute(iTXt_node, "compressionFlag"); -- iTXt_compressionFlag.add(new Boolean(compressionFlag)); -+ iTXt_compressionFlag.add(Boolean.valueOf(compressionFlag)); - - String compressionMethod = - getAttribute(iTXt_node, "compressionMethod"); -- iTXt_compressionMethod.add(compressionMethod); -+ iTXt_compressionMethod.add(Integer.valueOf(compressionMethod)); - - String languageTag = - getAttribute(iTXt_node, "languageTag"); -@@ -1952,13 +1950,10 @@ - tEXt_text.add(value); - } - } else { -- int flag = compression.equals("zip") ? -- 1 : 0; -- - // Use an iTXt node - iTXt_keyword.add(keyword); -- iTXt_compressionFlag.add(new Integer(flag)); -- iTXt_compressionMethod.add(new Integer(0)); -+ iTXt_compressionFlag.add(Boolean.valueOf(compression.equals("zip"))); -+ iTXt_compressionMethod.add(Integer.valueOf(0)); - iTXt_languageTag.add(language); - iTXt_translatedKeyword.add(keyword); // fake it - iTXt_text.add(value); -@@ -1995,12 +1990,12 @@ - gAMA_present = false; - hIST_present = false; - iCCP_present = false; -- iTXt_keyword = new ArrayList(); -- iTXt_compressionFlag = new ArrayList(); -- iTXt_compressionMethod = new ArrayList(); -- iTXt_languageTag = new ArrayList(); -- iTXt_translatedKeyword = new ArrayList(); -- iTXt_text = new ArrayList(); -+ iTXt_keyword = new ArrayList(); -+ iTXt_compressionFlag = new ArrayList(); -+ iTXt_compressionMethod = new ArrayList(); -+ iTXt_languageTag = new ArrayList(); -+ iTXt_translatedKeyword = new ArrayList(); -+ iTXt_text = new ArrayList(); - pHYs_present = false; - sBIT_present = false; - sPLT_present = false; -diff -urN openjdk.orig/jdk/test/javax/imageio/plugins/png/ITXtTest.java openjdk/jdk/test/javax/imageio/plugins/png/ITXtTest.java ---- openjdk.orig/jdk/test/javax/imageio/plugins/png/ITXtTest.java 1969-12-31 19:00:00.000000000 -0500 -+++ openjdk/jdk/test/javax/imageio/plugins/png/ITXtTest.java 2010-12-23 17:12:58.538446639 -0500 -@@ -0,0 +1,236 @@ -+/* -+ * Copyright (c) 2008, Oracle and/or its affiliates. All rights reserved. -+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -+ * -+ * This code is free software; you can redistribute it and/or modify it -+ * under the terms of the GNU General Public License version 2 only, as -+ * published by the Free Software Foundation. -+ * -+ * This code is distributed in the hope that it will be useful, but WITHOUT -+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -+ * version 2 for more details (a copy is included in the LICENSE file that -+ * accompanied this code). -+ * -+ * You should have received a copy of the GNU General Public License version -+ * 2 along with this work; if not, write to the Free Software Foundation, -+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. -+ * -+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA -+ * or visit www.oracle.com if you need additional information or have any -+ * questions. -+ */ -+ -+/** -+ * @test -+ * @bug 6541476 -+ * @summary Test verifies that ImageIO PNG plugin correcly handles the -+ * iTxt chunk (International textual data). -+ * -+ * @run main ITXtTest -+ */ -+ -+ -+import java.awt.Color; -+import java.awt.Graphics2D; -+import java.awt.image.BufferedImage; -+import java.io.File; -+ -+import javax.imageio.ImageIO; -+import javax.imageio.ImageReader; -+import javax.imageio.IIOImage; -+import javax.imageio.ImageTypeSpecifier; -+import javax.imageio.ImageWriter; -+import javax.imageio.metadata.IIOMetadata; -+import javax.imageio.metadata.IIOMetadataNode; -+import javax.imageio.stream.ImageOutputStream; -+import javax.imageio.stream.ImageInputStream; -+ -+import org.w3c.dom.Node; -+ -+public class ITXtTest { -+ static public void main(String args[]) { -+ ITXtTest t_en = new ITXtTest(); -+ t_en.description = "xml - en"; -+ t_en.keyword = "XML:com.adobe.xmp"; -+ t_en.isCompressed = false; -+ t_en.compression = 0; -+ t_en.language = "en"; -+ t_en.trasKeyword = "XML:com.adobe.xmp"; -+ t_en.text = "Something"; -+ -+ doTest(t_en); -+ -+ // check compression case -+ t_en.isCompressed = true; -+ t_en.description = "xml - en - compressed"; -+ -+ doTest(t_en); -+ -+ ITXtTest t_ru = new ITXtTest(); -+ t_ru.description = "xml - ru"; -+ t_ru.keyword = "XML:com.adobe.xmp"; -+ t_ru.isCompressed = false; -+ t_ru.compression = 0; -+ t_ru.language = "ru"; -+ t_ru.trasKeyword = "\u0410\u0410\u0410\u0410\u0410 XML"; -+ t_ru.text = "\u042A\u042F\u042F\u042F\u042F\u042F\u042F"; -+ -+ doTest(t_ru); -+ -+ t_ru.isCompressed = true; -+ t_ru.description = "xml - ru - compressed"; -+ -+ doTest(t_ru); -+ } -+ -+ -+ String description; -+ -+ String keyword; -+ boolean isCompressed; -+ int compression; -+ String language; -+ String trasKeyword; -+ String text; -+ -+ -+ public IIOMetadataNode getNode() { -+ IIOMetadataNode iTXt = new IIOMetadataNode("iTXt"); -+ IIOMetadataNode iTXtEntry = new IIOMetadataNode("iTXtEntry"); -+ iTXtEntry.setAttribute("keyword", keyword); -+ iTXtEntry.setAttribute("compressionFlag", -+ isCompressed ? "true" : "false"); -+ iTXtEntry.setAttribute("compressionMethod", -+ Integer.toString(compression)); -+ iTXtEntry.setAttribute("languageTag", language); -+ iTXtEntry.setAttribute("translatedKeyword", -+ trasKeyword); -+ iTXtEntry.setAttribute("text", text); -+ iTXt.appendChild(iTXtEntry); -+ return iTXt; -+ } -+ -+ public static ITXtTest getFromNode(IIOMetadataNode n) { -+ ITXtTest t = new ITXtTest(); -+ -+ if (!"iTXt".equals(n.getNodeName())) { -+ throw new RuntimeException("Invalid node"); -+ } -+ IIOMetadataNode e = (IIOMetadataNode)n.getFirstChild(); -+ if (!"iTXtEntry".equals(e.getNodeName())) { -+ throw new RuntimeException("Invalid entry node"); -+ } -+ t.keyword = e.getAttribute("keyword"); -+ t.isCompressed = -+ (Integer.valueOf(e.getAttribute("compressionFlag")).intValue() == 1); -+ t.compression = -+ Integer.valueOf(e.getAttribute("compressionMethod")).intValue(); -+ t.language = e.getAttribute("languageTag"); -+ t.trasKeyword = e.getAttribute("translatedKeyword"); -+ t.text = e.getAttribute("text"); -+ -+ return t; -+ } -+ From omajid at redhat.com Mon Jan 10 16:10:16 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 10 Jan 2011 19:10:16 -0500 Subject: [icedtea-web] RFC: use tagsoup to try and parse malformed JNLP files In-Reply-To: <20110110223323.GK13053@rivendell.middle-earth.co.uk> References: <4D2B7C9A.1070104@redhat.com> <20110110223323.GK13053@rivendell.middle-earth.co.uk> Message-ID: <4D2B9FE8.608@redhat.com> On 01/10/2011 05:33 PM, Dr Andrew John Hughes wrote: > On 16:39 Mon 10 Jan , Omair Majid wrote: >> Hi, >> >> I have come across a number of JNLP files that are not valid xml. Netx >> can not parse these files using a xml parser, and fails to run them. I >> spent some time looking for a solution and came across TagSoup[1]. The >> TagSoup library parses a malformed HTML document into a well-formed >> xml-like HTML document, but it works almost perfectly for our purposes too. >> >> The attached patch makes use of TagSoup for parsing input jnlp files. >> >> Parsing is currently implemented in two passes. In the first pass, >> TagSoup reads the "xml" (which can be malformed and hence not really >> xml), and outputs valid XML. Netx then uses this valid XML and uses it's >> own XML parser to parse the file. >> >> The patch requires TagSoup as an optional dependency. To use TagSoup, >> run configure (--with-tagsoup can be used to point to a TagSoup jar). To >> not use TagSoup (even if it installed), use --with-tagsoup=no >> >> The patch also adds an additional command line option, -xml ,to the >> javaws binary. This option can be used to force Netx to use the normal >> xml parser instead of TagSoup to parse the jnlp file. >> >> Any thoughts or comments? >> >> ChangeLog: >> 2011-01-10 Omair Majid >> >> * Makefile.am: Add NETX_EXCLUDE_SRCS, NETX_DUMMY_CLASSPATH >> (netx-source-files.txt): Selectively exclude some sources from >> compilation. >> (stamps/netx.stamp): Depend on netx-dummy.jar >> (netx-dummy.jar): New target. Empty jar. Used so there is always at >> least one class on the classpath. >> ($(NETX_DIR)/launcher/%.o): Add classpath. >> * NEWS: Update with fix. >> * acinclude.m4: Add IT_CHECK_FOR_TAGSOUP. >> * configure.ac: Call IT_CHECK_FOR_TAGSOUP. >> * netx/net/sourceforge/jnlp/JNLPFile.java: Add new member >> parserSettings. >> (JNLPFile(URL)): Pass a ParserSettings object. >> (JNLPFile(URL,boolean)): Refactored into... >> (JNLPFile(URL,ParserSettings)): New method. >> (JNLPFile(URL,Version,boolean)): Refactored into... >> (JNLPFile(URL,Version,ParserSettings)): New method. >> (JNLPFile(URL,Version,boolean,UpdatePolicy)): Refactored into... >> (JNLPFile(URL,Version,ParserSettings,UpdatePolicy)): New method. >> (JNLPFile(URL,String,Version,boolean,UpdatePolicy)): Refactored >> into... >> (JNLPFile(URL,String,Version,ParserSettings,UpdatePolicy)): New >> method. >> (JNLPFile(InputStream,boolean)): Refactored into... >> (JNLPFile(InputStream,ParserSettings)): New method. >> (getParserSettings): New method. >> (parse(Node,boolean,URL)): Refactored into... >> (parse(InputStream,URL)): New method. Invoke parser to get the root >> node and then parse it. >> * netx/net/sourceforge/jnlp/Launcher.java >> (toFile): Use new ParserSettings object. >> * netx/net/sourceforge/jnlp/Parser.java >> (Parser(JNLPFile,URL,Node,boolean,boolean)): Refactored into... >> (Parser(JNLPFile,URL,Node,ParserSettings)): New method. >> (getRootNode): Implementation moved into XMLParser.getRootNode. >> Selects the right subclass of XMLParser to use. >> (getEncoding): Moved to XMLParser. >> * netx/net/sourceforge/jnlp/ParserSettings.java: New file. >> (ParserSettings): New method. >> (ParserSettings(boolean,boolean,boolean)): New method. >> (isExtensionAllowed): New method. >> (isMalfromedXmlAllowed): New method. >> (isStrict): New method. >> * netx/net/sourceforge/jnlp/XMLParser.java >> (getRootNode): New method. Contains implementation from >> Parser.getRootNode. >> (getEncoding): New method. Moved from Parser. >> * netx/net/sourceforge/jnlp/MalformedXMLParser.java: New file. >> (getRootNode): New method. Transform input into valid xml and >> delegate to parent to parse it. >> (xmlizeInputStream): New method. Read contents from an input stream >> and transform it into valid xml. >> * netx/net/sourceforge/jnlp/resources/Messages.properties: Add >> BOXml. >> * netx/net/sourceforge/jnlp/runtime/Boot.java: Add -xml option. >> (getFile): Parse -xml option and create a new ParserSettings object >> based on it. >> * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java >> (getInstance(URL,String,Version,UpdatePolicy)): Refactored into... >> (getInstance(URL,String,Version,ParserSettings,UpdatePolicy): New >> method. >> (initializeExtensions): Use the same parser settings to parse the >> extension as used in the original file. >> >> Cheers, >> Omair >> >> [1] http://home.ccil.org/~cowan/XML/tagsoup/ > > I've just looked at the build changes. I'll leave someone with better knowledge > of the source code to look at those changes. > Thanks for looking over the changes so quickly! > With Makefile.am, I don't see why NETX_DUMMY_CLASSPATH is needed or the additional > rule that creates a JAR file. Neither do you need to set NETX_EXCLUDE_SRCS to empty; > this is the default. > Automake complains if a variable is not set before using += : NETX_EXCLUDE_SRCS must be set with `=' before using `+=' > if HAVE_TAGSOUP > NETX_CLASSPATH_ARG=-classpath $(TAGSOUP_JAR) > NETX_LAUNCHER_ARG="-Xbootclasspath/a:$(TAGSOUP_JAR)" > else > NETX_EXCLUDE_SRCS+=net.sourceforge.jnlp.MalformedXMLParser.java > endif > > would work fine and you can drop the netx-dummy.jar rule. > Thanks for the idea. What I wanted to do (a little prematurely, I suppose) was to make sure that more dependencies could be added in the future (with their own configure flags, if necessary) without changing the code too much. I also wanted all build code-paths to be as close as possible. Which is why I wanted to always have a classpath for netx-building (even if it was effectively blank using netx-dummy.jar) But my approach just makes the Makefile look like a mess. > Should we really be putting tagsoup on the bootclasspath? What's wrong with the classpath? > I have tested it out now with classpath and it looks like the javaws launcher does not like it: $ javaws XEtchedButtonDemo.jnlp Unrecognized option: -classpath /usr/share/java/tagsoup.jar Could not create the Java virtual machine. There is probably a way around this, I will see if I can find it. > As to excluding the file, have you tested this? Are you sure no other Java files pull > that class in? > Yup. This is one code path I made sure to test. MalformedXMLParser is a new file I added in this patch. The class is never used directly. Only net.sourceforge.jnlp.Parser uses it, and that too through reflection. Building (and running) without tagsoup works just fine. > For configure, the argument should be the path to the jar file. Otherwise, the JAR file > always has to be 'tagsoup.jar' which may not be the case. > Isnt this already the case? Perhaps I missed something, but the code does this: if --with-tagsoup=no then HAVE_TAGSOUP is set to false. if --with-tagsoup=somevar then somevar is used as the location of the tagsoup.jar. If --with-tagsoup is not used, then /usr/share/java (and other locations) are searched for a tagsoup.jar. > You should also check /usr/share/tagsoup/lib/tagsoup.jar which is the Gentoo installation path. > Debian uses /usr/share/java/tagsoup.jar as already checked. > Ah, thanks. Updated patch attached. Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: tagsoup-02.patch Type: text/x-patch Size: 35339 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110110/87bbd05a/tagsoup-02.patch From schumi.han at gmail.com Mon Jan 10 18:42:56 2011 From: schumi.han at gmail.com (Zhu Han) Date: Tue, 11 Jan 2011 10:42:56 +0800 Subject: "-client" option In-Reply-To: <4D2B3147.20100@redhat.com> References: <4D2B3147.20100@redhat.com> Message-ID: Thank you for your response. My testing platform is 64 bit X86. The things on X86 platform may be better. 640MB is just the pre-allocated address space size, half of them are anonymous mmap region. RSS is just around 48MB. I want to control the total size of address space because the JVM process spawns several sub-process to execute some scripts provided by OS occasionally. I know this is not portable, but seems like there is no better way to open a URL in standalone browser from a java application. This may be failed because of lack of swap space to backup address space. This is desktop oriented java application. Do you have any suggestion on it? Or is there any way for me to limit the address space of process forked by ProcessBuilder? best regards, hanzhu On Tue, Jan 11, 2011 at 12:18 AM, Andrew Haley wrote: > On 01/10/2011 04:09 PM, Zhu Han wrote: > > Does "-client" options work for IcedTea JDK? >> > > It depends on the target. 32-bit x86 yes, 64-bit x86, no. > > > Or, is there any way to limit the address space consumed by a single JVM >> instance? The target box does not have swap space, so I'd like to limit >> the >> anonymous space consumed by the JVM as little as possible. Even if I set >> "-Xmx96M", the jvm consumes 640MB memory space. >> > > Does it really consume that space, or does it merely pre-allocate that > much address space? I think it's probably the latter. > > But 640M really is a lot. Is your -Xms setting 96M too? > When I tried running x86 Java with no options, I got a RSS of > 12m, not 640M. What are you measuing? > > Andrew. > > > > > > By the way, the JVM is > >> 64bit. >> >> Thank you so much!! >> >> best regards, >> hanzhu >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110111/36a1229a/attachment.html From aph at redhat.com Tue Jan 11 02:57:11 2011 From: aph at redhat.com (Andrew Haley) Date: Tue, 11 Jan 2011 10:57:11 +0000 Subject: "-client" option In-Reply-To: References: <4D2B3147.20100@redhat.com> Message-ID: <4D2C3787.60702@redhat.com> Please don't top-post, it's very confusing. On 01/11/2011 02:42 AM, Zhu Han wrote: > Thank you for your response. > > My testing platform is 64 bit X86. The things on X86 platform may be better. Mine is 64-bit too. > 640MB is just the pre-allocated address space size, half of them are > anonymous mmap region. RSS is just around 48MB. I want to control the > total size of address space because the JVM process spawns several > sub-process to execute some scripts provided by OS occasionally. I know this > is not portable, but seems like there is no better way to open a URL in > standalone browser from a java application. But these regions are mapped as MAP_NORESERVE, so it shouldn't matter. > This may be failed because of lack of swap space to backup address space. OK, so now I understand what the real problem is. I'm assuming Linux. I don't understand why this is happening. I wonder if you have some odd setting. What is /proc/sys/vm/overcommit_memory? /proc/sys/vm/overcommit_ratio? /proc/meminfo ? Andrew. From ahughes at redhat.com Tue Jan 11 06:03:58 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Tue, 11 Jan 2011 14:03:58 +0000 Subject: [icedtea-web] RFC: use tagsoup to try and parse malformed JNLP files In-Reply-To: <4D2B9FE8.608@redhat.com> References: <4D2B7C9A.1070104@redhat.com> <20110110223323.GK13053@rivendell.middle-earth.co.uk> <4D2B9FE8.608@redhat.com> Message-ID: <20110111140358.GA28602@rivendell.middle-earth.co.uk> On 19:10 Mon 10 Jan , Omair Majid wrote: > On 01/10/2011 05:33 PM, Dr Andrew John Hughes wrote: > > On 16:39 Mon 10 Jan , Omair Majid wrote: > >> Hi, > >> > >> I have come across a number of JNLP files that are not valid xml. Netx > >> can not parse these files using a xml parser, and fails to run them. I > >> spent some time looking for a solution and came across TagSoup[1]. The > >> TagSoup library parses a malformed HTML document into a well-formed > >> xml-like HTML document, but it works almost perfectly for our purposes too. > >> > >> The attached patch makes use of TagSoup for parsing input jnlp files. > >> > >> Parsing is currently implemented in two passes. In the first pass, > >> TagSoup reads the "xml" (which can be malformed and hence not really > >> xml), and outputs valid XML. Netx then uses this valid XML and uses it's > >> own XML parser to parse the file. > >> > >> The patch requires TagSoup as an optional dependency. To use TagSoup, > >> run configure (--with-tagsoup can be used to point to a TagSoup jar). To > >> not use TagSoup (even if it installed), use --with-tagsoup=no > >> > >> The patch also adds an additional command line option, -xml ,to the > >> javaws binary. This option can be used to force Netx to use the normal > >> xml parser instead of TagSoup to parse the jnlp file. > >> > >> Any thoughts or comments? > >> > >> ChangeLog: > >> 2011-01-10 Omair Majid > >> > >> * Makefile.am: Add NETX_EXCLUDE_SRCS, NETX_DUMMY_CLASSPATH > >> (netx-source-files.txt): Selectively exclude some sources from > >> compilation. > >> (stamps/netx.stamp): Depend on netx-dummy.jar > >> (netx-dummy.jar): New target. Empty jar. Used so there is always at > >> least one class on the classpath. > >> ($(NETX_DIR)/launcher/%.o): Add classpath. > >> * NEWS: Update with fix. > >> * acinclude.m4: Add IT_CHECK_FOR_TAGSOUP. > >> * configure.ac: Call IT_CHECK_FOR_TAGSOUP. > >> * netx/net/sourceforge/jnlp/JNLPFile.java: Add new member > >> parserSettings. > >> (JNLPFile(URL)): Pass a ParserSettings object. > >> (JNLPFile(URL,boolean)): Refactored into... > >> (JNLPFile(URL,ParserSettings)): New method. > >> (JNLPFile(URL,Version,boolean)): Refactored into... > >> (JNLPFile(URL,Version,ParserSettings)): New method. > >> (JNLPFile(URL,Version,boolean,UpdatePolicy)): Refactored into... > >> (JNLPFile(URL,Version,ParserSettings,UpdatePolicy)): New method. > >> (JNLPFile(URL,String,Version,boolean,UpdatePolicy)): Refactored > >> into... > >> (JNLPFile(URL,String,Version,ParserSettings,UpdatePolicy)): New > >> method. > >> (JNLPFile(InputStream,boolean)): Refactored into... > >> (JNLPFile(InputStream,ParserSettings)): New method. > >> (getParserSettings): New method. > >> (parse(Node,boolean,URL)): Refactored into... > >> (parse(InputStream,URL)): New method. Invoke parser to get the root > >> node and then parse it. > >> * netx/net/sourceforge/jnlp/Launcher.java > >> (toFile): Use new ParserSettings object. > >> * netx/net/sourceforge/jnlp/Parser.java > >> (Parser(JNLPFile,URL,Node,boolean,boolean)): Refactored into... > >> (Parser(JNLPFile,URL,Node,ParserSettings)): New method. > >> (getRootNode): Implementation moved into XMLParser.getRootNode. > >> Selects the right subclass of XMLParser to use. > >> (getEncoding): Moved to XMLParser. > >> * netx/net/sourceforge/jnlp/ParserSettings.java: New file. > >> (ParserSettings): New method. > >> (ParserSettings(boolean,boolean,boolean)): New method. > >> (isExtensionAllowed): New method. > >> (isMalfromedXmlAllowed): New method. > >> (isStrict): New method. > >> * netx/net/sourceforge/jnlp/XMLParser.java > >> (getRootNode): New method. Contains implementation from > >> Parser.getRootNode. > >> (getEncoding): New method. Moved from Parser. > >> * netx/net/sourceforge/jnlp/MalformedXMLParser.java: New file. > >> (getRootNode): New method. Transform input into valid xml and > >> delegate to parent to parse it. > >> (xmlizeInputStream): New method. Read contents from an input stream > >> and transform it into valid xml. > >> * netx/net/sourceforge/jnlp/resources/Messages.properties: Add > >> BOXml. > >> * netx/net/sourceforge/jnlp/runtime/Boot.java: Add -xml option. > >> (getFile): Parse -xml option and create a new ParserSettings object > >> based on it. > >> * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java > >> (getInstance(URL,String,Version,UpdatePolicy)): Refactored into... > >> (getInstance(URL,String,Version,ParserSettings,UpdatePolicy): New > >> method. > >> (initializeExtensions): Use the same parser settings to parse the > >> extension as used in the original file. > >> > >> Cheers, > >> Omair > >> > >> [1] http://home.ccil.org/~cowan/XML/tagsoup/ > > > > I've just looked at the build changes. I'll leave someone with better knowledge > > of the source code to look at those changes. > > > > Thanks for looking over the changes so quickly! > > > With Makefile.am, I don't see why NETX_DUMMY_CLASSPATH is needed or the additional > > rule that creates a JAR file. Neither do you need to set NETX_EXCLUDE_SRCS to empty; > > this is the default. > > > > Automake complains if a variable is not set before using += : > > NETX_EXCLUDE_SRCS must be set with `=' before using `+=' > Yeah, so we just use '=' now :-) > > if HAVE_TAGSOUP > > NETX_CLASSPATH_ARG=-classpath $(TAGSOUP_JAR) > > NETX_LAUNCHER_ARG="-Xbootclasspath/a:$(TAGSOUP_JAR)" > > else > > NETX_EXCLUDE_SRCS+=net.sourceforge.jnlp.MalformedXMLParser.java > > endif > > > > would work fine and you can drop the netx-dummy.jar rule. > > > > Thanks for the idea. What I wanted to do (a little prematurely, I > suppose) was to make sure that more dependencies could be added in the > future (with their own configure flags, if necessary) without changing > the code too much. I also wanted all build code-paths to be as close as > possible. Which is why I wanted to always have a classpath for > netx-building (even if it was effectively blank using netx-dummy.jar) > But my approach just makes the Makefile look like a mess. > Yeah, I guessed your motivation. I'm just not sure it's worth bending over backwards to accomodate it. I guess we can scratch our heads over a good solution should we need a second dependency. > > Should we really be putting tagsoup on the bootclasspath? What's wrong with the classpath? > > > > I have tested it out now with classpath and it looks like the javaws > launcher does not like it: > $ javaws XEtchedButtonDemo.jnlp > Unrecognized option: -classpath /usr/share/java/tagsoup.jar > Could not create the Java virtual machine. > > There is probably a way around this, I will see if I can find it. > After writing the last reply, it also came to mind that setting this might cause issues with a classpath passed to javaws (if that's possible). So needs some testing. I'm just wary that tagsoup includes unknown code and it's a bit dangerous to put it on the privileged bootclasspath. Then again, I'm not sure any of javaws should be on the bootclasspath. > > As to excluding the file, have you tested this? Are you sure no other Java files pull > > that class in? > > > > Yup. This is one code path I made sure to test. MalformedXMLParser is a > new file I added in this patch. The class is never used directly. Only > net.sourceforge.jnlp.Parser uses it, and that too through reflection. > Building (and running) without tagsoup works just fine. > > > For configure, the argument should be the path to the jar file. Otherwise, the JAR file > > always has to be 'tagsoup.jar' which may not be the case. > > > > Isnt this already the case? Perhaps I missed something, but the code > does this: if --with-tagsoup=no then HAVE_TAGSOUP is set to false. if > --with-tagsoup=somevar then somevar is used as the location of the > tagsoup.jar. If --with-tagsoup is not used, then /usr/share/java (and > other locations) are searched for a tagsoup.jar. > Yes sorry, you're right. The block I was looking at is only used if no option is provided by the user, in which case we know the predefined paths. > > You should also check /usr/share/tagsoup/lib/tagsoup.jar which is the Gentoo installation path. > > Debian uses /usr/share/java/tagsoup.jar as already checked. > > > > Ah, thanks. Updated patch attached. > Thanks. Don't know why they don't use /usr/share/java. > Cheers, > Omair > diff -r dc02a605f905 Makefile.am > --- a/Makefile.am Fri Jan 07 08:00:08 2011 -0500 > +++ b/Makefile.am Mon Jan 10 19:09:30 2011 -0500 > @@ -31,6 +31,8 @@ > net.sourceforge.jnlp.services net.sourceforge.jnlp.tools \ > net.sourceforge.jnlp.util net.sourceforge.jnlp.controlpanel > > +NETX_EXCLUDE_SRCS= > + > # Conditional defintions > if ENABLE_PLUGIN > ICEDTEAPLUGIN_CLEAN = clean-IcedTeaPlugin > @@ -68,6 +70,13 @@ > endif > endif > > +if HAVE_TAGSOUP > +NETX_CLASSPATH_ARG=-classpath $(TAGSOUP_JAR) > +NETX_LAUNCHER_ARG="-Xbootclasspath/a:$(TAGSOUP_JAR)", > +else > +NETX_EXCLUDE_SRCS+=net.sourceforge.jnlp.MalformedXMLParser.java > +endif > + > # Launcher > > LAUNCHER_SRCDIR = $(abs_top_srcdir)/launcher > @@ -279,14 +288,19 @@ > # a patch applied to sun.plugin.AppletViewerPanel and generated sources > > netx-source-files.txt: > - find $(NETX_SRCDIR) -name '*.java' | sort > $@ > + find $(NETX_SRCDIR) -name '*.java' | sort > $@ ; \ > + for src in $(NETX_EXCLUDE_SRCS) ; \ > + do \ > + sed -i "/$${src}/ d" $@ ; \ > + done > > -stamps/netx.stamp: netx-source-files.txt stamps/bootstrap-directory.stamp > +stamps/netx.stamp: netx-source-files.txt stamps/bootstrap-directory.stamp netx-dummy.jar > mkdir -p $(NETX_DIR) > $(BOOT_DIR)/bin/javac $(IT_JAVACFLAGS) \ > -d $(NETX_DIR) \ > -sourcepath $(NETX_SRCDIR) \ > -bootclasspath $(RUNTIME) \ > + $(NETX_CLASSPATH_ARG) \ > @netx-source-files.txt > (cd $(NETX_RESOURCE_DIR); \ > for files in $$(find . -type f); \ > @@ -349,7 +363,7 @@ > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > mkdir -p $(NETX_DIR)/launcher && \ > $(CC) $(LAUNCHER_FLAGS) \ > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > + -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", $(NETX_LAUNCHER_ARG) "net.sourceforge.jnlp.runtime.Boot", }' \ > -DPROGNAME='"javaws"' -c -o $@ $< > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > diff -r dc02a605f905 NEWS > --- a/NEWS Fri Jan 07 08:00:08 2011 -0500 > +++ b/NEWS Mon Jan 10 19:09:30 2011 -0500 > @@ -8,7 +8,12 @@ > > CVE-XXXX-YYYY: http://www.cve.mitre.org/cgi-bin/cvename.cgi?name=XXXX-YYYY > > -New in release 1.0 (2010-XX-XX): > +New in release 1.1 (2011-XX-XX): > + > +* NetX > + - Netx can now parse malformed jnlp files using tagsoup > + > +New in release 1.0 (2011-XX-XX): > > * Initial release of IcedTea-Web > * Security updates > diff -r dc02a605f905 acinclude.m4 > --- a/acinclude.m4 Fri Jan 07 08:00:08 2011 -0500 > +++ b/acinclude.m4 Mon Jan 10 19:09:30 2011 -0500 > @@ -297,6 +297,36 @@ > fi > ]) > > + > +AC_DEFUN_ONCE([IT_CHECK_FOR_TAGSOUP], > +[ > + AC_MSG_CHECKING([for tagsoup]) > + AC_ARG_WITH([tagsoup], > + [AS_HELP_STRING([--with-tagsoup], > + [support malformed jnlp files])], > + [ TAGSOUP_JAR=${withval} ], > + [ TAGSOUP_JAR= ]) > + if test x"${TAGSOUP_JAR}" = xyes ; then > + TAGSOUP_JAR= > + fi > + if test -z "${TAGSOUP_JAR}" ; then > + for dir in /usr/share/java /usr/local/share/java \ > + /usr/share/tagsoup/lib/ ; do > + if test -f $dir/tagsoup.jar; then > + TAGSOUP_JAR=$dir/tagsoup.jar > + break > + fi > + done > + fi > + if test x"${TAGSOUP_JAR}" = x ; then > + TAGSOUP_JAR=no > + fi > + AC_MSG_RESULT(${TAGSOUP_JAR}) > + AC_SUBST(TAGSOUP_JAR) > + AM_CONDITIONAL([HAVE_TAGSOUP], [test x$TAGSOUP_JAR != xno]) > +]) > + > + > dnl Generic macro to check for a Java class > dnl Takes the name of the class as an argument. The macro name > dnl is usually the name of the class with '.' > diff -r dc02a605f905 configure.ac > --- a/configure.ac Fri Jan 07 08:00:08 2011 -0500 > +++ b/configure.ac Mon Jan 10 19:09:30 2011 -0500 > @@ -80,4 +80,6 @@ > IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) > IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE > > +IT_CHECK_FOR_TAGSOUP > + > AC_OUTPUT > diff -r dc02a605f905 netx/net/sourceforge/jnlp/JNLPFile.java > --- a/netx/net/sourceforge/jnlp/JNLPFile.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/JNLPFile.java Mon Jan 10 19:09:30 2011 -0500 > @@ -67,6 +67,9 @@ > /** the network location of this JNLP file */ > protected URL fileLocation; > > + /** the ParserSettings which were used to parse this file */ > + protected ParserSettings parserSettings = null; > + > /** A key that uniquely identifies connected instances (main jnlp+ext) */ > protected String uniqueKey = null; > > @@ -132,7 +135,7 @@ > * @throws ParseException if the JNLP file was invalid > */ > public JNLPFile(URL location) throws IOException, ParseException { > - this(location, false); // not strict > + this(location, new ParserSettings()); > } > > /** > @@ -140,12 +143,12 @@ > * default policy. > * > * @param location the location of the JNLP file > - * @param strict whether to enforce the spec when > + * @param settings the parser settings to use while parsing the file > * @throws IOException if an IO exception occurred > * @throws ParseException if the JNLP file was invalid > */ > - public JNLPFile(URL location, boolean strict) throws IOException, ParseException { > - this(location, (Version) null, strict); > + public JNLPFile(URL location, ParserSettings settings) throws IOException, ParseException { > + this(location, (Version) null, settings); > } > > /** > @@ -154,12 +157,12 @@ > * > * @param location the location of the JNLP file > * @param version the version of the JNLP file > - * @param strict whether to enforce the spec when > + * @param settings the parser settings to use while parsing the file > * @throws IOException if an IO exception occurred > * @throws ParseException if the JNLP file was invalid > */ > - public JNLPFile(URL location, Version version, boolean strict) throws IOException, ParseException { > - this(location, version, strict, JNLPRuntime.getDefaultUpdatePolicy()); > + public JNLPFile(URL location, Version version, ParserSettings settings) throws IOException, ParseException { > + this(location, version, settings, JNLPRuntime.getDefaultUpdatePolicy()); > } > > /** > @@ -168,14 +171,15 @@ > * > * @param location the location of the JNLP file > * @param version the version of the JNLP file > - * @param strict whether to enforce the spec when > + * @param settings the parser settings to use while parsing the file > * @param policy the update policy > * @throws IOException if an IO exception occurred > * @throws ParseException if the JNLP file was invalid > */ > - public JNLPFile(URL location, Version version, boolean strict, UpdatePolicy policy) throws IOException, ParseException { > - Node root = Parser.getRootNode(openURL(location, version, policy)); > - parse(root, strict, location); > + public JNLPFile(URL location, Version version, ParserSettings settings, UpdatePolicy policy) throws IOException, ParseException { > + this.parserSettings = settings; > + > + parse(openURL(location, version, policy), location); > > //Downloads the original jnlp file into the cache if possible > //(i.e. If the jnlp file being launched exist locally, but it > @@ -202,13 +206,13 @@ > * @param location the location of the JNLP file > * @param uniqueKey A string that uniquely identifies connected instances > * @param version the version of the JNLP file > - * @param strict whether to enforce the spec when > + * @param settings the parser settings to use while parsing the file > * @param policy the update policy > * @throws IOException if an IO exception occurred > * @throws ParseException if the JNLP file was invalid > */ > - public JNLPFile(URL location, String uniqueKey, Version version, boolean strict, UpdatePolicy policy) throws IOException, ParseException { > - this(location, version, strict, policy); > + public JNLPFile(URL location, String uniqueKey, Version version, ParserSettings settings, UpdatePolicy policy) throws IOException, ParseException { > + this(location, version, settings, policy); > this.uniqueKey = uniqueKey; > > if (JNLPRuntime.isDebug()) > @@ -218,11 +222,14 @@ > /** > * Create a JNLPFile from an input stream. > * > + * @param input input stream to read the JNLP file from > + * @param settings the parser settings to use while parsing the file > * @throws IOException if an IO exception occurred > * @throws ParseException if the JNLP file was invalid > */ > - public JNLPFile(InputStream input, boolean strict) throws ParseException { > - parse(Parser.getRootNode(input), strict, null); > + public JNLPFile(InputStream input, ParserSettings settings) throws ParseException { > + this.parserSettings = settings; > + parse(input, null); > } > > /** > @@ -288,6 +295,13 @@ > } > > /** > + * Returns the ParserSettings that was used to parse this file > + */ > + public ParserSettings getParserSettings() { > + return parserSettings; > + } > + > + /** > * Returns the JNLP file's version. > */ > public Version getFileVersion() { > @@ -548,12 +562,13 @@ > * @param strict whether to enforce the spec when > * @param location the file location or null > */ > - private void parse(Node root, boolean strict, URL location) throws ParseException { > + private void parse(InputStream input, URL location) throws ParseException { > try { > //if (location != null) > // location = new URL(location, "."); // remove filename > > - Parser parser = new Parser(this, location, root, strict, true); // true == allow extensions > + Node root = Parser.getRootNode(input, parserSettings); > + Parser parser = new Parser(this, location, root, parserSettings); > > // JNLP tag information > specVersion = parser.getSpecVersion(); > diff -r dc02a605f905 netx/net/sourceforge/jnlp/Launcher.java > --- a/netx/net/sourceforge/jnlp/Launcher.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/Launcher.java Mon Jan 10 19:09:30 2011 -0500 > @@ -360,9 +360,11 @@ > JNLPFile file = null; > > try { > - file = new JNLPFile(location, (Version) null, true, updatePolicy); // strict > + ParserSettings settings = new ParserSettings(true, true, false); > + file = new JNLPFile(location, (Version) null, settings, updatePolicy); // strict > } catch (ParseException ex) { > - file = new JNLPFile(location, (Version) null, false, updatePolicy); > + ParserSettings settings = new ParserSettings(false, true, true); > + file = new JNLPFile(location, (Version) null, settings, updatePolicy); > > // only here if strict failed but lax did not fail > LaunchException lex = > diff -r dc02a605f905 netx/net/sourceforge/jnlp/MalformedXMLParser.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/MalformedXMLParser.java Mon Jan 10 19:09:30 2011 -0500 > @@ -0,0 +1,101 @@ > +// Copyright (C) 2011 Red Hat, Inc. > +// > +// This library is free software; you can redistribute it and/or > +// modify it under the terms of the GNU Lesser General Public > +// License as published by the Free Software Foundation; either > +// version 2.1 of the License, or (at your option) any later version. > +// > +// This library is distributed in the hope that it will be useful, > +// but WITHOUT ANY WARRANTY; without even the implied warranty of > +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > +// Lesser General Public License for more details. > +// > +// You should have received a copy of the GNU Lesser General Public > +// License along with this library; if not, write to the Free Software > +// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. > + > +package net.sourceforge.jnlp; > + > +import static net.sourceforge.jnlp.runtime.Translator.R; > + > +import java.io.ByteArrayInputStream; > +import java.io.ByteArrayOutputStream; > +import java.io.IOException; > +import java.io.InputStream; > +import java.io.OutputStreamWriter; > +import java.io.Writer; > + > +import net.sourceforge.jnlp.runtime.JNLPRuntime; > + > +import org.ccil.cowan.tagsoup.HTMLSchema; > +import org.ccil.cowan.tagsoup.Parser; > +import org.ccil.cowan.tagsoup.XMLWriter; > +import org.xml.sax.InputSource; > +import org.xml.sax.SAXException; > +import org.xml.sax.XMLReader; > + > +/** > + * An specialized {@link XMLParser} that uses TagSoup[1] to parse > + * malformed XML > + * > + * Used by net.sourceforge.jnlp.Parser > + * > + * [1] http://home.ccil.org/~cowan/XML/tagsoup/ > + */ > +public class MalformedXMLParser extends XMLParser { > + > + /** > + * Parses the data from an {@link InputStream} to create a XML tree. > + * Returns a {@link Node} representing the root of the tree. > + * > + * @param input the {@link InputStream} to read data from > + * @throws ParseException if an exception occurs while parsing the input > + */ > + @Override > + public Node getRootNode(InputStream input) throws ParseException { > + if (JNLPRuntime.isDebug()) { > + System.out.println("Using MalformedXMLParser"); > + } > + InputStream xmlInput = xmlizeInputStream(input); > + return super.getRootNode(xmlInput); > + } > + > + /** > + * Reads malformed XML from the InputStream original and returns a new > + * InputStream which can be used to read a well-formed version of the input > + * > + * @param original > + * @return an {@link InputStream} which can be used to read a well-formed > + * version of the input XML > + * @throws ParseException > + */ > + private InputStream xmlizeInputStream(InputStream original) throws ParseException { > + try { > + ByteArrayOutputStream out = new ByteArrayOutputStream(); > + > + HTMLSchema schema = new HTMLSchema(); > + XMLReader reader = new Parser(); > + > + reader.setProperty(Parser.schemaProperty, schema); > + reader.setFeature(Parser.bogonsEmptyFeature, false); > + reader.setFeature(Parser.ignorableWhitespaceFeature, true); > + reader.setFeature(Parser.ignoreBogonsFeature, false); > + > + Writer writeger = new OutputStreamWriter(out); > + XMLWriter x = new XMLWriter(writeger); > + > + reader.setContentHandler(x); > + > + InputSource s = new InputSource(original); > + > + reader.parse(s); > + return new ByteArrayInputStream(out.toByteArray()); > + } catch (SAXException e) { > + throw new ParseException(R("PBadXML"), e); > + } catch (IOException e) { > + throw new ParseException(R("PBadXML"), e); > + } > + > + } > + > +} > diff -r dc02a605f905 netx/net/sourceforge/jnlp/Parser.java > --- a/netx/net/sourceforge/jnlp/Parser.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/Parser.java Mon Jan 10 19:09:30 2011 -0500 > @@ -1,5 +1,5 @@ > // Copyright (C) 2001-2003 Jon A. Maxwell (JAM) > -// Copyright (C) 2009 Red Hat, Inc. > +// Copyright (C) 2011 Red Hat, Inc. > // > // This library is free software; you can redistribute it and/or > // modify it under the terms of the GNU Lesser General Public > @@ -20,15 +20,13 @@ > import static net.sourceforge.jnlp.runtime.Translator.R; > > import java.io.*; > +import java.lang.reflect.InvocationTargetException; > +import java.lang.reflect.Method; > import java.net.*; > import java.util.*; > -//import javax.xml.parsers.*; // commented to use right Node > -//import org.w3c.dom.*; // class for using Tiny XML | NanoXML > -//import org.xml.sax.*; > -//import gd.xml.tiny.*; > + > import net.sourceforge.jnlp.UpdateDesc.Check; > import net.sourceforge.jnlp.UpdateDesc.Policy; > -import net.sourceforge.nanoxml.*; > > /** > * Contains methods to parse an XML document into a JNLPFile. > @@ -105,15 +103,14 @@ > * @param file the (uninitialized) file reference > * @param base if codebase is not specified, a default base for relative URLs > * @param root the root node > - * @param strict whether to enforce strict compliance with the JNLP spec > - * @param allowExtensions whether to allow extensions to the JNLP spec > + * @param settings the parser settings to use when parsing the JNLP file > * @throws ParseException if the JNLP file is invalid > */ > - public Parser(JNLPFile file, URL base, Node root, boolean strict, boolean allowExtensions) throws ParseException { > + public Parser(JNLPFile file, URL base, Node root, ParserSettings settings) throws ParseException { > this.file = file; > this.root = root; > - this.strict = strict; > - this.allowExtensions = allowExtensions; > + this.strict = settings.isStrict(); > + this.allowExtensions = settings.isExtensionAllowed(); > > // ensure it's a JNLP node > if (root == null || !root.getNodeName().equals("jnlp")) > @@ -1205,116 +1202,33 @@ > * > * @throws ParseException if the JNLP file is invalid > */ > - public static Node getRootNode(InputStream input) throws ParseException { > + public static Node getRootNode(InputStream input, ParserSettings settings) throws ParseException { > + String className = null; > + if (settings.isMalfromedXmlAllowed()) { > + className = "net.sourceforge.jnlp.MalformedXMLParser"; > + } else { > + className = "net.sourceforge.jnlp.XMLParser"; > + } > + > try { > - /* SAX > - DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); > - factory.setValidating(false); > - factory.setNamespaceAware(true); > - DocumentBuilder builder = factory.newDocumentBuilder(); > - builder.setErrorHandler(errorHandler); > + Class klass = null; > + try { > + klass = Class.forName(className); > + } catch (ClassNotFoundException e) { > + klass = Class.forName("net.sourceforge.jnlp.XMLParser"); > + } > + Object instance = klass.newInstance(); > + Method m = klass.getMethod("getRootNode", InputStream.class); > > - Document doc = builder.parse(input); > - return doc.getDocumentElement(); > - */ > - > - /* TINY > - Node document = new Node(TinyParser.parseXML(input)); > - Node jnlpNode = getChildNode(document, "jnlp"); // skip comments > - */ > - > - //A BufferedInputStream is used to allow marking and reseting > - //of a stream. > - BufferedInputStream bs = new BufferedInputStream(input); > - > - /* NANO */ > - final XMLElement xml = new XMLElement(); > - final PipedInputStream pin = new PipedInputStream(); > - final PipedOutputStream pout = new PipedOutputStream(pin); > - final InputStreamReader isr = new InputStreamReader(bs, getEncoding(bs)); > - // Clean the jnlp xml file of all comments before passing > - // it to the parser. > - new Thread( > - new Runnable() { > - public void run() { > - (new XMLElement()).sanitizeInput(isr, pout); > - try { > - pout.close(); > - } catch (IOException ioe) { > - ioe.printStackTrace(); > - } > - } > - }).start(); > - xml.parseFromReader(new InputStreamReader(pin)); > - Node jnlpNode = new Node(xml); > - return jnlpNode; > - } catch (Exception ex) { > - throw new ParseException(R("PBadXML"), ex); > + return (Node) m.invoke(instance, input); > + } catch (InvocationTargetException e) { > + if (e.getCause() instanceof ParseException) { > + throw (ParseException)(e.getCause()); > + } > + throw new ParseException(R("PBadXML"), e); > + } catch (Exception e) { > + throw new ParseException(R("PBadXML"), e); > } > } > > - /** > - * Returns the name of the encoding used in this InputStream. > - * > - * @param input the InputStream > - * @return a String representation of encoding > - */ > - private static String getEncoding(InputStream input) throws IOException { > - //Fixme: This only recognizes UTF-8, UTF-16, and > - //UTF-32, which is enough to parse the prolog portion of xml to > - //find out the exact encoding (if it exists). The reason being > - //there could be other encodings, such as ISO 8859 which is 8-bits > - //but it supports latin characters. > - //So what needs to be done is to parse the prolog and retrieve > - //the exact encoding from it. > - > - int[] s = new int[4]; > - String encoding = "UTF-8"; > - > - //Determine what the first four bytes are and store > - //them into an int array. > - input.mark(4); > - for (int i = 0; i < 4; i++) { > - s[i] = input.read(); > - } > - input.reset(); > - > - //Set the encoding base on what the first four bytes of the > - //inputstream turn out to be (following the information from > - //www.w3.org/TR/REC-xml/#sec-guessing). > - if (s[0] == 255) { > - if (s[1] == 254) { > - if (s[2] != 0 || s[3] != 0) { > - encoding = "UnicodeLittle"; > - } else { > - encoding = "X-UTF-32LE-BOM"; > - } > - } > - } else if (s[0] == 254 && s[1] == 255 && (s[2] != 0 || > - s[3] != 0)) { > - encoding = "UTF-16"; > - > - } else if (s[0] == 0 && s[1] == 0 && s[2] == 254 && > - s[3] == 255) { > - encoding = "X-UTF-32BE-BOM"; > - > - } else if (s[0] == 0 && s[1] == 0 && s[2] == 0 && > - s[3] == 60) { > - encoding = "UTF-32BE"; > - > - } else if (s[0] == 60 && s[1] == 0 && s[2] == 0 && > - s[3] == 0) { > - encoding = "UTF-32LE"; > - > - } else if (s[0] == 0 && s[1] == 60 && s[2] == 0 && > - s[3] == 63) { > - encoding = "UTF-16BE"; > - } else if (s[0] == 60 && s[1] == 0 && s[2] == 63 && > - s[3] == 0) { > - encoding = "UTF-16LE"; > - } > - > - return encoding; > - } > - > } > diff -r dc02a605f905 netx/net/sourceforge/jnlp/ParserSettings.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/ParserSettings.java Mon Jan 10 19:09:30 2011 -0500 > @@ -0,0 +1,55 @@ > +// Copyright (C) 2011 Red Hat, Inc. > +// > +// This library is free software; you can redistribute it and/or > +// modify it under the terms of the GNU Lesser General Public > +// License as published by the Free Software Foundation; either > +// version 2.1 of the License, or (at your option) any later version. > +// > +// This library is distributed in the hope that it will be useful, > +// but WITHOUT ANY WARRANTY; without even the implied warranty of > +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > +// Lesser General Public License for more details. > +// > +// You should have received a copy of the GNU Lesser General Public > +// License along with this library; if not, write to the Free Software > +// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. > + > +package net.sourceforge.jnlp; > + > +/** > + * Encapsulates settings to use with the JNLP Parser > + */ > +public class ParserSettings { > + > + private final boolean strict; > + private final boolean extensionAllowed; > + private final boolean malformedXmlAllowed; > + > + /** Create a new ParserSettings with the defautl parser settings */ > + public ParserSettings() { > + this(false, true, true); > + } > + > + /** Create a new ParserSettings object */ > + public ParserSettings(boolean strict, boolean extensionAllowed, boolean malformedXmlAllowed) { > + this.strict = strict; > + this.extensionAllowed = extensionAllowed; > + this.malformedXmlAllowed = malformedXmlAllowed; > + } > + > + /** @return true if extensions to the spec are allowed */ > + public boolean isExtensionAllowed() { > + return extensionAllowed; > + } > + > + /** @return true if parsing malformed xml is allowed */ > + public boolean isMalfromedXmlAllowed() { > + return malformedXmlAllowed; > + } > + > + /** @return true if strict parsing mode is to be used */ > + public boolean isStrict() { > + return strict; > + } > + > +} > diff -r dc02a605f905 netx/net/sourceforge/jnlp/XMLParser.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/XMLParser.java Mon Jan 10 19:09:30 2011 -0500 > @@ -0,0 +1,163 @@ > +// Copyright (C) 2001-2003 Jon A. Maxwell (JAM) > +// Copyright (C) 2011 Red Hat, Inc. > +// > +// This library is free software; you can redistribute it and/or > +// modify it under the terms of the GNU Lesser General Public > +// License as published by the Free Software Foundation; either > +// version 2.1 of the License, or (at your option) any later version. > +// > +// This library is distributed in the hope that it will be useful, > +// but WITHOUT ANY WARRANTY; without even the implied warranty of > +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > +// Lesser General Public License for more details. > +// > +// You should have received a copy of the GNU Lesser General Public > +// License along with this library; if not, write to the Free Software > +// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. > + > +package net.sourceforge.jnlp; > + > +import static net.sourceforge.jnlp.runtime.Translator.R; > + > +import java.io.BufferedInputStream; > +import java.io.IOException; > +import java.io.InputStream; > +import java.io.InputStreamReader; > +import java.io.PipedInputStream; > +import java.io.PipedOutputStream; > + > +import net.sourceforge.nanoxml.XMLElement; > + > +//import javax.xml.parsers.*; // commented to use right Node > +//import org.w3c.dom.*; // class for using Tiny XML | NanoXML > +//import org.xml.sax.*; > +//import gd.xml.tiny.*; > + > +/** > + * A gateway to the actual implementation of the parsers. > + * > + * Used by net.sourceforge.jnlp.Parser > + */ > +class XMLParser { > + > + /** > + * Parses input from an InputStream and returns a Node representing the > + * root of the parse tree. > + * > + * @param input the {@link InputStream} containing the XML > + * @return a {@link Node} representing the root of the parsed XML > + * @throws ParseException > + */ > + public Node getRootNode(InputStream input) throws ParseException { > + > + try { > + /* SAX > + DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); > + factory.setValidating(false); > + factory.setNamespaceAware(true); > + DocumentBuilder builder = factory.newDocumentBuilder(); > + builder.setErrorHandler(errorHandler); > + > + Document doc = builder.parse(input); > + return doc.getDocumentElement(); > + */ > + > + /* TINY > + Node document = new Node(TinyParser.parseXML(input)); > + Node jnlpNode = getChildNode(document, "jnlp"); // skip comments > + */ > + > + //A BufferedInputStream is used to allow marking and reseting > + //of a stream. > + BufferedInputStream bs = new BufferedInputStream(input); > + > + /* NANO */ > + final XMLElement xml = new XMLElement(); > + final PipedInputStream pin = new PipedInputStream(); > + final PipedOutputStream pout = new PipedOutputStream(pin); > + final InputStreamReader isr = new InputStreamReader(bs, getEncoding(bs)); > + // Clean the jnlp xml file of all comments before passing > + // it to the parser. > + new Thread( > + new Runnable() { > + public void run() { > + (new XMLElement()).sanitizeInput(isr, pout); > + try { > + pout.close(); > + } catch (IOException ioe) { > + ioe.printStackTrace(); > + } > + } > + }).start(); > + xml.parseFromReader(new InputStreamReader(pin)); > + Node jnlpNode = new Node(xml); > + return jnlpNode; > + } catch (Exception ex) { > + throw new ParseException(R("PBadXML"), ex); > + } > + } > + > + /** > + * Returns the name of the encoding used in this InputStream. > + * > + * @param input the InputStream > + * @return a String representation of encoding > + */ > + private static String getEncoding(InputStream input) throws IOException { > + //Fixme: This only recognizes UTF-8, UTF-16, and > + //UTF-32, which is enough to parse the prolog portion of xml to > + //find out the exact encoding (if it exists). The reason being > + //there could be other encodings, such as ISO 8859 which is 8-bits > + //but it supports latin characters. > + //So what needs to be done is to parse the prolog and retrieve > + //the exact encoding from it. > + > + int[] s = new int[4]; > + String encoding = "UTF-8"; > + > + //Determine what the first four bytes are and store > + //them into an int array. > + input.mark(4); > + for (int i = 0; i < 4; i++) { > + s[i] = input.read(); > + } > + input.reset(); > + > + //Set the encoding base on what the first four bytes of the > + //inputstream turn out to be (following the information from > + //www.w3.org/TR/REC-xml/#sec-guessing). > + if (s[0] == 255) { > + if (s[1] == 254) { > + if (s[2] != 0 || s[3] != 0) { > + encoding = "UnicodeLittle"; > + } else { > + encoding = "X-UTF-32LE-BOM"; > + } > + } > + } else if (s[0] == 254 && s[1] == 255 && (s[2] != 0 || > + s[3] != 0)) { > + encoding = "UTF-16"; > + > + } else if (s[0] == 0 && s[1] == 0 && s[2] == 254 && > + s[3] == 255) { > + encoding = "X-UTF-32BE-BOM"; > + > + } else if (s[0] == 0 && s[1] == 0 && s[2] == 0 && > + s[3] == 60) { > + encoding = "UTF-32BE"; > + > + } else if (s[0] == 60 && s[1] == 0 && s[2] == 0 && > + s[3] == 0) { > + encoding = "UTF-32LE"; > + > + } else if (s[0] == 0 && s[1] == 60 && s[2] == 0 && > + s[3] == 63) { > + encoding = "UTF-16BE"; > + } else if (s[0] == 60 && s[1] == 0 && s[2] == 63 && > + s[3] == 0) { > + encoding = "UTF-16LE"; > + } > + > + return encoding; > + } > +} > diff -r dc02a605f905 netx/net/sourceforge/jnlp/resources/Messages.properties > --- a/netx/net/sourceforge/jnlp/resources/Messages.properties Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/resources/Messages.properties Mon Jan 10 19:09:30 2011 -0500 > @@ -158,6 +158,7 @@ > BOHeadless = Disables download window, other UIs. > BOStrict = Enables strict checking of JNLP file format. > BOViewer = Shows the trusted certificate viewer. > +BOXml = Uses an XML parser to parse the JNLP file. > BXnofork = Do not create another JVM. > BXclearcache= Clean the JNLP application cache. > BOHelp = Print this message and exit. > diff -r dc02a605f905 netx/net/sourceforge/jnlp/runtime/Boot.java > --- a/netx/net/sourceforge/jnlp/runtime/Boot.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/Boot.java Mon Jan 10 19:09:30 2011 -0500 > @@ -34,6 +34,7 @@ > import net.sourceforge.jnlp.LaunchException; > import net.sourceforge.jnlp.Launcher; > import net.sourceforge.jnlp.ParseException; > +import net.sourceforge.jnlp.ParserSettings; > import net.sourceforge.jnlp.PropertyDesc; > import net.sourceforge.jnlp.ResourcesDesc; > import net.sourceforge.jnlp.cache.CacheUtil; > @@ -104,6 +105,7 @@ > + " -noupdate " + R("BONoupdate") + "\n" > + " -headless " + R("BOHeadless") + "\n" > + " -strict " + R("BOStrict") + "\n" > + + " -xml " + R("BOXml") + "\n" > + " -Xnofork " + R("BXnofork") + "\n" > + " -Xclearcache " + R("BXclearcache") + "\n" > + " -help " + R("BOHelp") + "\n"; > @@ -262,13 +264,22 @@ > e.printStackTrace(); > } > > - boolean strict = (null != getOption("-strict")); > + boolean strict = false; > + boolean malformedXmlAllowed = true; > > - JNLPFile file = new JNLPFile(url, strict); > + if (null != getOption("-strict")) { > + strict = true; > + } > + if (null != getOption("-xml")) { > + malformedXmlAllowed = false; > + } > + ParserSettings settings = new ParserSettings(strict, true, malformedXmlAllowed); > + > + JNLPFile file = new JNLPFile(url, settings); > > // Launches the jnlp file where this file originated. > if (file.getSourceLocation() != null) { > - file = new JNLPFile(file.getSourceLocation(), strict); > + file = new JNLPFile(file.getSourceLocation(), settings); > } > > // add in extra params from command line > diff -r dc02a605f905 netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java > --- a/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Mon Jan 10 19:09:30 2011 -0500 > @@ -50,6 +50,7 @@ > import net.sourceforge.jnlp.JNLPFile; > import net.sourceforge.jnlp.LaunchException; > import net.sourceforge.jnlp.ParseException; > +import net.sourceforge.jnlp.ParserSettings; > import net.sourceforge.jnlp.PluginBridge; > import net.sourceforge.jnlp.ResourcesDesc; > import net.sourceforge.jnlp.SecurityDesc; > @@ -324,12 +325,12 @@ > * @param version the file's version > * @param policy the update policy to use when downloading resources > */ > - public static JNLPClassLoader getInstance(URL location, String uniqueKey, Version version, UpdatePolicy policy) > + public static JNLPClassLoader getInstance(URL location, String uniqueKey, Version version, ParserSettings settings, UpdatePolicy policy) > throws IOException, ParseException, LaunchException { > JNLPClassLoader loader = urlToLoader.get(uniqueKey); > > if (loader == null || !location.equals(loader.getJNLPFile().getFileLocation())) > - loader = getInstance(new JNLPFile(location, uniqueKey, version, false, policy), policy); > + loader = getInstance(new JNLPFile(location, uniqueKey, version, settings, policy), policy); > > return loader; > } > @@ -348,7 +349,7 @@ > for (int i = 0; i < ext.length; i++) { > try { > String uniqueKey = this.getJNLPFile().getUniqueKey(); > - JNLPClassLoader loader = getInstance(ext[i].getLocation(), uniqueKey, ext[i].getVersion(), updatePolicy); > + JNLPClassLoader loader = getInstance(ext[i].getLocation(), uniqueKey, ext[i].getVersion(), file.getParserSettings(), updatePolicy); > loaderList.add(loader); > } catch (Exception ex) { > ex.printStackTrace(); -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at redhat.com Tue Jan 11 06:12:38 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 11 Jan 2011 09:12:38 -0500 Subject: [icedtea-web] RFC: remove unused imports in netx code Message-ID: <4D2C6556.9050103@redhat.com> Hi, The attached patch removes unused imports in Netx code. Ok to commit? ChangeLog 2011-01-11 Omair Majid * netx/javax/jnlp/UnavailableServiceException.java: Remove unused imports. * netx/net/sourceforge/jnlp/AppletDesc.java: Likewise. * netx/net/sourceforge/jnlp/ApplicationDesc.java: Likewise. * netx/net/sourceforge/jnlp/ComponentDesc.java: Likewise. * netx/net/sourceforge/jnlp/DefaultLaunchHandler.java: Likewise. * netx/net/sourceforge/jnlp/IconDesc.java: Likewise. * netx/net/sourceforge/jnlp/InformationDesc.java: Likewise. * netx/net/sourceforge/jnlp/InstallerDesc.java: Likewise. * netx/net/sourceforge/jnlp/JARDesc.java: Likewise. * netx/net/sourceforge/jnlp/JREDesc.java: Likewise. * netx/net/sourceforge/jnlp/Launcher.java: Likewise. * netx/net/sourceforge/jnlp/PackageDesc.java: Likewise. * netx/net/sourceforge/jnlp/ParseException.java: Likewise. * netx/net/sourceforge/jnlp/PluginBridge.java: Likewise. * netx/net/sourceforge/jnlp/PropertyDesc.java: Likewise. * netx/net/sourceforge/jnlp/ResourcesDesc.java: Likewise. * netx/net/sourceforge/jnlp/Version.java: Likewise. * netx/net/sourceforge/jnlp/cache/CacheEntry.java: Likewise. * netx/net/sourceforge/jnlp/cache/CacheUtil.java: Likewise. * netx/net/sourceforge/jnlp/cache/DefaultDownloadIndicator.java: Likewise. * netx/net/sourceforge/jnlp/cache/DownloadIndicator.java: Likewise. * netx/net/sourceforge/jnlp/cache/UpdatePolicy.java: Likewise. * netx/net/sourceforge/jnlp/controlpanel /AdvancedProxySettingsDialog.java: Likewise. * netx/net/sourceforge/jnlp/controlpanel /AdvancedProxySettingsPane.java: Likewise. * netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java: Likewise. * netx/net/sourceforge/jnlp/controlpanel /TemporaryInternetFilesPanel.java: Likewise. * netx/net/sourceforge/jnlp/event/ApplicationEvent.java: Likewise. * netx/net/sourceforge/jnlp/event/DownloadEvent.java: Likewise. * netx/net/sourceforge/jnlp/runtime/AppThreadGroup.java: Likewise. * netx/net/sourceforge/jnlp/runtime/AppletAudioClip.java: Likewise. * netx/net/sourceforge/jnlp/runtime/AppletInstance.java: Likewise. * netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java: Likewise. * netx/net/sourceforge/jnlp/runtime/Boot13.java: Likewise. * netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java: Likewise. * netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: Likewise. * netx/net/sourceforge/jnlp/security/CertsInfoPane.java: Likewise. * netx/net/sourceforge/jnlp/security/SecurityUtil.java: Likewise. * netx/net/sourceforge/jnlp/services/XBasicService.java: Likewise. * netx/net/sourceforge/jnlp/services/XDownloadService.java: Likewise. * netx/net/sourceforge/jnlp/services/XExtensionInstallerService.java: Likewise. * netx/net/sourceforge/jnlp/services/XFileContents.java: Likewise. * netx/net/sourceforge/jnlp/services/XFileOpenService.java: Likewise. * netx/net/sourceforge/jnlp/services/XFileSaveService.java: Likewise. * netx/net/sourceforge/jnlp/services/XPersistenceService.java: Likewise. * netx/net/sourceforge/jnlp/util/PropertiesFile.java: Likewise. * netx/net/sourceforge/jnlp/util/Reflect.java: Likewise. Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: remove-unused-imports-01.patch Type: text/x-patch Size: 22184 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110111/7a3a5e56/remove-unused-imports-01.patch From ahughes at redhat.com Tue Jan 11 06:42:31 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Tue, 11 Jan 2011 14:42:31 +0000 Subject: [icedtea-web] RFC: remove unused imports in netx code In-Reply-To: <4D2C6556.9050103@redhat.com> References: <4D2C6556.9050103@redhat.com> Message-ID: <20110111144230.GD28602@rivendell.middle-earth.co.uk> On 09:12 Tue 11 Jan , Omair Majid wrote: > Hi, > > The attached patch removes unused imports in Netx code. > > Ok to commit? > > ChangeLog > 2011-01-11 Omair Majid > * netx/javax/jnlp/UnavailableServiceException.java: Remove unused > imports. > * netx/net/sourceforge/jnlp/AppletDesc.java: Likewise. > * netx/net/sourceforge/jnlp/ApplicationDesc.java: Likewise. > * netx/net/sourceforge/jnlp/ComponentDesc.java: Likewise. > * netx/net/sourceforge/jnlp/DefaultLaunchHandler.java: Likewise. > * netx/net/sourceforge/jnlp/IconDesc.java: Likewise. > * netx/net/sourceforge/jnlp/InformationDesc.java: Likewise. > * netx/net/sourceforge/jnlp/InstallerDesc.java: Likewise. > * netx/net/sourceforge/jnlp/JARDesc.java: Likewise. > * netx/net/sourceforge/jnlp/JREDesc.java: Likewise. > * netx/net/sourceforge/jnlp/Launcher.java: Likewise. > * netx/net/sourceforge/jnlp/PackageDesc.java: Likewise. > * netx/net/sourceforge/jnlp/ParseException.java: Likewise. > * netx/net/sourceforge/jnlp/PluginBridge.java: Likewise. > * netx/net/sourceforge/jnlp/PropertyDesc.java: Likewise. > * netx/net/sourceforge/jnlp/ResourcesDesc.java: Likewise. > * netx/net/sourceforge/jnlp/Version.java: Likewise. > * netx/net/sourceforge/jnlp/cache/CacheEntry.java: Likewise. > * netx/net/sourceforge/jnlp/cache/CacheUtil.java: Likewise. > * netx/net/sourceforge/jnlp/cache/DefaultDownloadIndicator.java: > Likewise. > * netx/net/sourceforge/jnlp/cache/DownloadIndicator.java: Likewise. > * netx/net/sourceforge/jnlp/cache/UpdatePolicy.java: Likewise. > * netx/net/sourceforge/jnlp/controlpanel > /AdvancedProxySettingsDialog.java: Likewise. > * netx/net/sourceforge/jnlp/controlpanel > /AdvancedProxySettingsPane.java: Likewise. > * netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java: > Likewise. > * netx/net/sourceforge/jnlp/controlpanel > /TemporaryInternetFilesPanel.java: Likewise. > * netx/net/sourceforge/jnlp/event/ApplicationEvent.java: Likewise. > * netx/net/sourceforge/jnlp/event/DownloadEvent.java: Likewise. > * netx/net/sourceforge/jnlp/runtime/AppThreadGroup.java: Likewise. > * netx/net/sourceforge/jnlp/runtime/AppletAudioClip.java: Likewise. > * netx/net/sourceforge/jnlp/runtime/AppletInstance.java: Likewise. > * netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java: > Likewise. > * netx/net/sourceforge/jnlp/runtime/Boot13.java: Likewise. > * netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java: Likewise. > * netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: > Likewise. > * netx/net/sourceforge/jnlp/security/CertsInfoPane.java: Likewise. > * netx/net/sourceforge/jnlp/security/SecurityUtil.java: Likewise. > * netx/net/sourceforge/jnlp/services/XBasicService.java: Likewise. > * netx/net/sourceforge/jnlp/services/XDownloadService.java: Likewise. > * netx/net/sourceforge/jnlp/services/XExtensionInstallerService.java: > Likewise. > * netx/net/sourceforge/jnlp/services/XFileContents.java: Likewise. > * netx/net/sourceforge/jnlp/services/XFileOpenService.java: Likewise. > * netx/net/sourceforge/jnlp/services/XFileSaveService.java: Likewise. > * netx/net/sourceforge/jnlp/services/XPersistenceService.java: > Likewise. > * netx/net/sourceforge/jnlp/util/PropertiesFile.java: Likewise. > * netx/net/sourceforge/jnlp/util/Reflect.java: Likewise. > > Cheers, > Omair Fine by me, if it still builds. > diff -r dc02a605f905 netx/net/sourceforge/jnlp/AppletDesc.java > --- a/netx/net/sourceforge/jnlp/AppletDesc.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/AppletDesc.java Tue Jan 11 08:02:21 2011 -0500 > @@ -16,7 +16,6 @@ > > package net.sourceforge.jnlp; > > -import java.io.*; > import java.net.*; > import java.util.*; > > diff -r dc02a605f905 netx/net/sourceforge/jnlp/ApplicationDesc.java > --- a/netx/net/sourceforge/jnlp/ApplicationDesc.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/ApplicationDesc.java Tue Jan 11 08:02:21 2011 -0500 > @@ -16,8 +16,6 @@ > > package net.sourceforge.jnlp; > > -import java.io.*; > -import java.net.*; > import java.util.*; > > /** > diff -r dc02a605f905 netx/net/sourceforge/jnlp/ComponentDesc.java > --- a/netx/net/sourceforge/jnlp/ComponentDesc.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/ComponentDesc.java Tue Jan 11 08:02:21 2011 -0500 > @@ -16,10 +16,6 @@ > > package net.sourceforge.jnlp; > > -import java.io.*; > -import java.net.*; > -import java.util.*; > - > /** > * The component-desc element. > * > diff -r dc02a605f905 netx/net/sourceforge/jnlp/DefaultLaunchHandler.java > --- a/netx/net/sourceforge/jnlp/DefaultLaunchHandler.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/DefaultLaunchHandler.java Tue Jan 11 08:02:21 2011 -0500 > @@ -17,11 +17,6 @@ > package net.sourceforge.jnlp; > > import net.sourceforge.jnlp.runtime.*; > -import net.sourceforge.jnlp.util.*; > - > -import java.awt.*; > -import java.util.*; > -import javax.swing.*; > > /** > * This default implementation shows prints the exception to > diff -r dc02a605f905 netx/net/sourceforge/jnlp/IconDesc.java > --- a/netx/net/sourceforge/jnlp/IconDesc.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/IconDesc.java Tue Jan 11 08:02:21 2011 -0500 > @@ -16,9 +16,7 @@ > > package net.sourceforge.jnlp; > > -import java.io.*; > import java.net.*; > -import java.util.*; > > /** > * The icon element. > diff -r dc02a605f905 netx/net/sourceforge/jnlp/InformationDesc.java > --- a/netx/net/sourceforge/jnlp/InformationDesc.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/InformationDesc.java Tue Jan 11 08:02:21 2011 -0500 > @@ -17,8 +17,6 @@ > > package net.sourceforge.jnlp; > > -import java.io.*; > -import java.awt.Dimension; > import java.net.*; > import java.util.*; > > diff -r dc02a605f905 netx/net/sourceforge/jnlp/InstallerDesc.java > --- a/netx/net/sourceforge/jnlp/InstallerDesc.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/InstallerDesc.java Tue Jan 11 08:02:21 2011 -0500 > @@ -16,10 +16,6 @@ > > package net.sourceforge.jnlp; > > -import java.io.*; > -import java.net.*; > -import java.util.*; > - > /** > * The installer-desc element. > * > diff -r dc02a605f905 netx/net/sourceforge/jnlp/JARDesc.java > --- a/netx/net/sourceforge/jnlp/JARDesc.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/JARDesc.java Tue Jan 11 08:02:21 2011 -0500 > @@ -16,9 +16,7 @@ > > package net.sourceforge.jnlp; > > -import java.io.*; > -import java.net.*; > -import java.util.*; > +import java.net.URL; > > /** > * The JAR element. > diff -r dc02a605f905 netx/net/sourceforge/jnlp/JREDesc.java > --- a/netx/net/sourceforge/jnlp/JREDesc.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/JREDesc.java Tue Jan 11 08:02:21 2011 -0500 > @@ -18,7 +18,6 @@ > > import static net.sourceforge.jnlp.runtime.Translator.R; > > -import java.io.*; > import java.net.*; > import java.util.*; > > diff -r dc02a605f905 netx/net/sourceforge/jnlp/Launcher.java > --- a/netx/net/sourceforge/jnlp/Launcher.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/Launcher.java Tue Jan 11 08:02:21 2011 -0500 > @@ -24,8 +24,6 @@ > import java.io.FileInputStream; > import java.io.FileOutputStream; > import java.io.IOException; > -import java.lang.management.ManagementFactory; > -import java.lang.management.ThreadMXBean; > import java.lang.reflect.Method; > import java.net.InetAddress; > import java.net.URL; > @@ -48,7 +46,6 @@ > import net.sourceforge.jnlp.services.InstanceExistsException; > import net.sourceforge.jnlp.services.ServiceUtil; > import net.sourceforge.jnlp.util.FileUtils; > -import net.sourceforge.jnlp.util.Reflect; > > import javax.swing.SwingUtilities; > import javax.swing.text.html.parser.ParserDelegator; > diff -r dc02a605f905 netx/net/sourceforge/jnlp/PackageDesc.java > --- a/netx/net/sourceforge/jnlp/PackageDesc.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/PackageDesc.java Tue Jan 11 08:02:21 2011 -0500 > @@ -16,10 +16,6 @@ > > package net.sourceforge.jnlp; > > -import java.io.*; > -import java.net.*; > -import java.util.*; > - > /** > * The package element. > * > diff -r dc02a605f905 netx/net/sourceforge/jnlp/ParseException.java > --- a/netx/net/sourceforge/jnlp/ParseException.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/ParseException.java Tue Jan 11 08:02:21 2011 -0500 > @@ -17,8 +17,6 @@ > package net.sourceforge.jnlp; > > import java.io.*; > -import java.net.*; > -import java.util.*; > > /** > * Thrown to indicate that an error has occurred while parsing a > diff -r dc02a605f905 netx/net/sourceforge/jnlp/PluginBridge.java > --- a/netx/net/sourceforge/jnlp/PluginBridge.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/PluginBridge.java Tue Jan 11 08:02:21 2011 -0500 > @@ -26,7 +26,6 @@ > import java.net.MalformedURLException; > import java.util.Calendar; > import java.util.Hashtable; > -import java.util.Iterator; > import java.util.Locale; > import java.util.List; > import java.util.ArrayList; > diff -r dc02a605f905 netx/net/sourceforge/jnlp/PropertyDesc.java > --- a/netx/net/sourceforge/jnlp/PropertyDesc.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/PropertyDesc.java Tue Jan 11 08:02:21 2011 -0500 > @@ -16,10 +16,6 @@ > > package net.sourceforge.jnlp; > > -import java.io.*; > -import java.net.*; > -import java.util.*; > - > /** > * The property element. > * > diff -r dc02a605f905 netx/net/sourceforge/jnlp/ResourcesDesc.java > --- a/netx/net/sourceforge/jnlp/ResourcesDesc.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/ResourcesDesc.java Tue Jan 11 08:02:21 2011 -0500 > @@ -16,9 +16,6 @@ > > package net.sourceforge.jnlp; > > -import java.io.*; > -import java.awt.Dimension; > -import java.net.*; > import java.util.*; > > /** > diff -r dc02a605f905 netx/net/sourceforge/jnlp/Version.java > --- a/netx/net/sourceforge/jnlp/Version.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/Version.java Tue Jan 11 08:02:21 2011 -0500 > @@ -16,8 +16,6 @@ > > package net.sourceforge.jnlp; > > -import java.io.*; > -import java.net.*; > import java.util.*; > > /** > diff -r dc02a605f905 netx/net/sourceforge/jnlp/cache/CacheEntry.java > --- a/netx/net/sourceforge/jnlp/cache/CacheEntry.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/cache/CacheEntry.java Tue Jan 11 08:02:21 2011 -0500 > @@ -20,10 +20,6 @@ > > import java.io.*; > import java.net.*; > -import java.util.*; > -import java.lang.reflect.*; > -import java.security.*; > -import javax.jnlp.*; > > import net.sourceforge.jnlp.*; > import net.sourceforge.jnlp.runtime.*; > diff -r dc02a605f905 netx/net/sourceforge/jnlp/cache/CacheUtil.java > --- a/netx/net/sourceforge/jnlp/cache/CacheUtil.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/cache/CacheUtil.java Tue Jan 11 08:02:21 2011 -0500 > @@ -22,7 +22,6 @@ > import java.net.*; > import java.nio.channels.FileChannel; > import java.util.*; > -import java.lang.reflect.*; > import java.security.*; > import javax.jnlp.*; > > diff -r dc02a605f905 netx/net/sourceforge/jnlp/cache/DefaultDownloadIndicator.java > --- a/netx/net/sourceforge/jnlp/cache/DefaultDownloadIndicator.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/cache/DefaultDownloadIndicator.java Tue Jan 11 08:02:21 2011 -0500 > @@ -27,7 +27,6 @@ > import javax.swing.Timer; > import javax.jnlp.*; > > -import net.sourceforge.jnlp.*; > import net.sourceforge.jnlp.runtime.*; > > /** > diff -r dc02a605f905 netx/net/sourceforge/jnlp/cache/DownloadIndicator.java > --- a/netx/net/sourceforge/jnlp/cache/DownloadIndicator.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/cache/DownloadIndicator.java Tue Jan 11 08:02:21 2011 -0500 > @@ -16,16 +16,9 @@ > > package net.sourceforge.jnlp.cache; > > -import java.awt.*; > -import java.awt.event.*; > import java.net.*; > -import java.util.*; > -import java.util.List; > -import javax.swing.*; > -import javax.swing.Timer; > import javax.jnlp.*; > > -import net.sourceforge.jnlp.*; > import net.sourceforge.jnlp.runtime.*; > > /** > diff -r dc02a605f905 netx/net/sourceforge/jnlp/cache/UpdatePolicy.java > --- a/netx/net/sourceforge/jnlp/cache/UpdatePolicy.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/cache/UpdatePolicy.java Tue Jan 11 08:02:21 2011 -0500 > @@ -16,17 +16,6 @@ > > package net.sourceforge.jnlp.cache; > > -import java.io.*; > -import java.net.*; > -import java.util.*; > -import java.lang.reflect.*; > -import java.security.*; > -import javax.jnlp.*; > - > -import net.sourceforge.jnlp.*; > -import net.sourceforge.jnlp.runtime.*; > -import net.sourceforge.jnlp.util.*; > - > /** > * A policy that determines when a resource should be checked for > * an updated version.

> diff -r dc02a605f905 netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java > --- a/netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java Tue Jan 11 08:02:21 2011 -0500 > @@ -28,8 +28,6 @@ > import java.awt.event.WindowEvent; > > import javax.swing.JDialog; > -import javax.swing.SwingUtilities; > -import javax.swing.UIManager; > > import net.sourceforge.jnlp.config.DeploymentConfiguration; > import net.sourceforge.jnlp.runtime.Translator; > diff -r dc02a605f905 netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsPane.java > --- a/netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsPane.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsPane.java Tue Jan 11 08:02:21 2011 -0500 > @@ -27,8 +27,6 @@ > import java.awt.event.ActionListener; > import java.awt.event.ItemEvent; > import java.awt.event.ItemListener; > -import java.awt.event.KeyAdapter; > -import java.awt.event.KeyEvent; > import java.util.ArrayList; > import java.util.List; > > diff -r dc02a605f905 netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java > --- a/netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java Tue Jan 11 08:02:21 2011 -0500 > @@ -29,15 +29,12 @@ > import java.awt.event.ActionListener; > import java.awt.event.ItemEvent; > import java.awt.event.ItemListener; > -import java.awt.event.KeyAdapter; > -import java.awt.event.KeyEvent; > import java.util.ArrayList; > > import javax.swing.Box; > import javax.swing.ButtonGroup; > import javax.swing.JButton; > import javax.swing.JCheckBox; > -import javax.swing.JComponent; > import javax.swing.JLabel; > import javax.swing.JPanel; > import javax.swing.JRadioButton; > diff -r dc02a605f905 netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java > --- a/netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java Tue Jan 11 08:02:21 2011 -0500 > @@ -38,7 +38,6 @@ > import javax.swing.JSpinner; > import javax.swing.JTextField; > import javax.swing.SpinnerNumberModel; > -import javax.swing.SwingUtilities; > import javax.swing.event.ChangeEvent; > import javax.swing.event.ChangeListener; > > diff -r dc02a605f905 netx/net/sourceforge/jnlp/event/ApplicationEvent.java > --- a/netx/net/sourceforge/jnlp/event/ApplicationEvent.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/event/ApplicationEvent.java Tue Jan 11 08:02:21 2011 -0500 > @@ -18,7 +18,6 @@ > > import java.util.*; > > -import net.sourceforge.jnlp.*; > import net.sourceforge.jnlp.runtime.*; > > /** > diff -r dc02a605f905 netx/net/sourceforge/jnlp/event/DownloadEvent.java > --- a/netx/net/sourceforge/jnlp/event/DownloadEvent.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/event/DownloadEvent.java Tue Jan 11 08:02:21 2011 -0500 > @@ -19,9 +19,7 @@ > import java.net.*; > import java.util.*; > > -import net.sourceforge.jnlp.*; > import net.sourceforge.jnlp.cache.*; > -import net.sourceforge.jnlp.runtime.*; > > /** > * This event is sent during the launch of an > diff -r dc02a605f905 netx/net/sourceforge/jnlp/runtime/AppThreadGroup.java > --- a/netx/net/sourceforge/jnlp/runtime/AppThreadGroup.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/AppThreadGroup.java Tue Jan 11 08:02:21 2011 -0500 > @@ -16,8 +16,6 @@ > > package net.sourceforge.jnlp.runtime; > > -import java.awt.*; > - > /** > * Thread group for a JNLP application. > * > diff -r dc02a605f905 netx/net/sourceforge/jnlp/runtime/AppletAudioClip.java > --- a/netx/net/sourceforge/jnlp/runtime/AppletAudioClip.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/AppletAudioClip.java Tue Jan 11 08:02:21 2011 -0500 > @@ -17,7 +17,6 @@ > package net.sourceforge.jnlp.runtime; > > import java.net.*; > -import java.io.*; > import java.applet.*; > import javax.sound.sampled.*; > > diff -r dc02a605f905 netx/net/sourceforge/jnlp/runtime/AppletInstance.java > --- a/netx/net/sourceforge/jnlp/runtime/AppletInstance.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/AppletInstance.java Tue Jan 11 08:02:21 2011 -0500 > @@ -18,13 +18,6 @@ > > import java.applet.*; > import java.awt.*; > -import java.io.*; > -import java.net.*; > -import java.util.*; > -import java.util.List; > -import java.security.*; > -import java.lang.reflect.*; > -import java.lang.ref.*; > > import net.sourceforge.jnlp.*; > > diff -r dc02a605f905 netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java > --- a/netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java Tue Jan 11 08:02:21 2011 -0500 > @@ -37,7 +37,6 @@ > import net.sourceforge.jnlp.event.ApplicationListener; > import net.sourceforge.jnlp.security.SecurityWarning; > import net.sourceforge.jnlp.security.SecurityWarning.AccessType; > -import net.sourceforge.jnlp.services.ServiceUtil; > import net.sourceforge.jnlp.util.WeakList; > import net.sourceforge.jnlp.util.XDesktopEntry; > > diff -r dc02a605f905 netx/net/sourceforge/jnlp/runtime/Boot13.java > --- a/netx/net/sourceforge/jnlp/runtime/Boot13.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/Boot13.java Tue Jan 11 08:02:21 2011 -0500 > @@ -17,10 +17,8 @@ > package net.sourceforge.jnlp.runtime; > > import java.lang.reflect.*; > -import java.io.*; > import java.net.*; > import java.security.*; > -import javax.swing.*; > > /** > * Allows a Policy and SecurityManager to be set in JRE1.3 without > diff -r dc02a605f905 netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java > --- a/netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java Tue Jan 11 08:02:21 2011 -0500 > @@ -19,7 +19,6 @@ > import java.io.*; > import java.net.Authenticator; > import java.net.ProxySelector; > -import java.nio.channels.FileLock; > import java.awt.*; > import java.text.*; > import java.util.*; > diff -r dc02a605f905 netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java > --- a/netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java Tue Jan 11 08:02:21 2011 -0500 > @@ -20,17 +20,12 @@ > > import java.awt.Frame; > import java.awt.Window; > -import java.awt.event.WindowAdapter; > -import java.awt.event.WindowEvent; > import java.lang.ref.WeakReference; > import java.net.SocketPermission; > import java.security.AllPermission; > import java.security.AccessControlException; > -import java.security.AccessController; > import java.security.Permission; > -import java.security.PrivilegedAction; > import java.security.SecurityPermission; > -import java.util.PropertyPermission; > > import javax.swing.JWindow; > > diff -r dc02a605f905 netx/net/sourceforge/jnlp/security/CertsInfoPane.java > --- a/netx/net/sourceforge/jnlp/security/CertsInfoPane.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/security/CertsInfoPane.java Tue Jan 11 08:02:21 2011 -0500 > @@ -40,12 +40,9 @@ > import static net.sourceforge.jnlp.runtime.Translator.R; > > import java.util.ArrayList; > -import java.util.Date; > import java.security.cert.CertPath; > import java.security.cert.X509Certificate; > import java.security.MessageDigest; > -import java.math.BigInteger; > -import javax.security.auth.x500.X500Principal; > > import sun.misc.HexDumpEncoder; > import sun.security.x509.*; > diff -r dc02a605f905 netx/net/sourceforge/jnlp/security/SecurityUtil.java > --- a/netx/net/sourceforge/jnlp/security/SecurityUtil.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/security/SecurityUtil.java Tue Jan 11 08:02:21 2011 -0500 > @@ -42,7 +42,6 @@ > import java.io.FileOutputStream; > import java.security.KeyStore; > > -import net.sourceforge.jnlp.runtime.JNLPRuntime; > import net.sourceforge.jnlp.security.KeyStores.Level; > import net.sourceforge.jnlp.security.KeyStores.Type; > > diff -r dc02a605f905 netx/net/sourceforge/jnlp/services/XBasicService.java > --- a/netx/net/sourceforge/jnlp/services/XBasicService.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/services/XBasicService.java Tue Jan 11 08:02:21 2011 -0500 > @@ -31,7 +31,6 @@ > import net.sourceforge.jnlp.config.DeploymentConfiguration; > import net.sourceforge.jnlp.runtime.ApplicationInstance; > import net.sourceforge.jnlp.runtime.JNLPRuntime; > -import net.sourceforge.jnlp.util.PropertiesFile; > > /** > * The BasicService JNLP service. > diff -r dc02a605f905 netx/net/sourceforge/jnlp/services/XDownloadService.java > --- a/netx/net/sourceforge/jnlp/services/XDownloadService.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/services/XDownloadService.java Tue Jan 11 08:02:21 2011 -0500 > @@ -18,12 +18,8 @@ > > import java.io.*; > import java.net.*; > -import java.util.*; > -import java.lang.ref.*; > import javax.jnlp.*; > > -import net.sourceforge.jnlp.*; > - > /** > * The DownloadService JNLP service. > * > diff -r dc02a605f905 netx/net/sourceforge/jnlp/services/XExtensionInstallerService.java > --- a/netx/net/sourceforge/jnlp/services/XExtensionInstallerService.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/services/XExtensionInstallerService.java Tue Jan 11 08:02:21 2011 -0500 > @@ -16,13 +16,9 @@ > > package net.sourceforge.jnlp.services; > > -import java.io.*; > import java.net.*; > -import java.util.*; > -import java.lang.ref.*; > import javax.jnlp.*; > > -import net.sourceforge.jnlp.*; > > /** > * The ExtensionInstallerService JNLP service. > diff -r dc02a605f905 netx/net/sourceforge/jnlp/services/XFileContents.java > --- a/netx/net/sourceforge/jnlp/services/XFileContents.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/services/XFileContents.java Tue Jan 11 08:02:21 2011 -0500 > @@ -17,14 +17,8 @@ > package net.sourceforge.jnlp.services; > > import java.io.*; > -import java.net.*; > -import java.util.*; > -import java.lang.ref.*; > import javax.jnlp.*; > > -import net.sourceforge.jnlp.*; > -import net.sourceforge.jnlp.runtime.JNLPRuntime; > - > /** > * File contents. > * > diff -r dc02a605f905 netx/net/sourceforge/jnlp/services/XFileOpenService.java > --- a/netx/net/sourceforge/jnlp/services/XFileOpenService.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/services/XFileOpenService.java Tue Jan 11 08:02:21 2011 -0500 > @@ -38,18 +38,11 @@ > package net.sourceforge.jnlp.services; > > import java.io.*; > -import java.net.*; > -import java.util.*; > -import java.lang.ref.*; > import javax.jnlp.*; > > -import net.sourceforge.jnlp.*; > -import net.sourceforge.jnlp.runtime.*; > import net.sourceforge.jnlp.security.SecurityWarning.AccessType; > > import javax.swing.JFileChooser; > -import javax.swing.JOptionPane; > -import java.security.*; > > /** > * The FileOpenService JNLP service. > diff -r dc02a605f905 netx/net/sourceforge/jnlp/services/XFileSaveService.java > --- a/netx/net/sourceforge/jnlp/services/XFileSaveService.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/services/XFileSaveService.java Tue Jan 11 08:02:21 2011 -0500 > @@ -38,9 +38,6 @@ > package net.sourceforge.jnlp.services; > > import java.io.*; > -import java.net.*; > -import java.util.*; > -import java.lang.ref.*; > import javax.jnlp.*; > > import net.sourceforge.jnlp.security.SecurityWarning.AccessType; > @@ -48,7 +45,6 @@ > > import javax.swing.JFileChooser; > import javax.swing.JOptionPane; > -import java.security.*; > > /** > * The FileSaveService JNLP service. > diff -r dc02a605f905 netx/net/sourceforge/jnlp/services/XPersistenceService.java > --- a/netx/net/sourceforge/jnlp/services/XPersistenceService.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/services/XPersistenceService.java Tue Jan 11 08:02:21 2011 -0500 > @@ -19,10 +19,8 @@ > import java.io.*; > import java.net.*; > import java.util.*; > -import java.lang.ref.*; > import javax.jnlp.*; > > -import net.sourceforge.jnlp.*; > import net.sourceforge.jnlp.cache.*; > import net.sourceforge.jnlp.config.DeploymentConfiguration; > import net.sourceforge.jnlp.runtime.*; > diff -r dc02a605f905 netx/net/sourceforge/jnlp/util/PropertiesFile.java > --- a/netx/net/sourceforge/jnlp/util/PropertiesFile.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/util/PropertiesFile.java Tue Jan 11 08:02:21 2011 -0500 > @@ -17,11 +17,8 @@ > package net.sourceforge.jnlp.util; > > import java.io.*; > -import java.net.*; > import java.util.*; > > -import net.sourceforge.jnlp.*; > - > /** > * A properties object backed by a specified file without throwing > * exceptions. The properties are automatically loaded from the > diff -r dc02a605f905 netx/net/sourceforge/jnlp/util/Reflect.java > --- a/netx/net/sourceforge/jnlp/util/Reflect.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/util/Reflect.java Tue Jan 11 08:02:21 2011 -0500 > @@ -16,7 +16,6 @@ > > package net.sourceforge.jnlp.util; > > -import java.util.*; > import java.lang.reflect.*; > > /** -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at redhat.com Tue Jan 11 08:40:11 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 11 Jan 2011 11:40:11 -0500 Subject: [icedtea-web] RFC: add missing generic type in JNLPFile Message-ID: <4D2C87EB.1000107@redhat.com> Hi, The attached patch adds a generic type to 'info' in JNLPFile. Ok to commit? ChangeLog: 2011-01-11 Omair Majid * netx/net/sourceforge/jnlp/JNLPFile: Add missing generic type to info. (getInformation): Remove redundant cast. Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: fix-generic-in-jnlpfile.patch Type: text/x-patch Size: 831 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110111/ef7a0fa0/fix-generic-in-jnlpfile.patch From ahughes at redhat.com Tue Jan 11 09:07:25 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Tue, 11 Jan 2011 17:07:25 +0000 Subject: [icedtea-web] RFC: add missing generic type in JNLPFile In-Reply-To: <4D2C87EB.1000107@redhat.com> References: <4D2C87EB.1000107@redhat.com> Message-ID: <20110111170724.GH28602@rivendell.middle-earth.co.uk> On 11:40 Tue 11 Jan , Omair Majid wrote: > Hi, > > The attached patch adds a generic type to 'info' in JNLPFile. > > Ok to commit? > > ChangeLog: > 2011-01-11 Omair Majid > > * netx/net/sourceforge/jnlp/JNLPFile: Add missing generic type to > info. > (getInformation): Remove redundant cast. > > > Cheers, > Omair Looks good. javac clearly misses these; is this with ecj? > diff -r dc02a605f905 netx/net/sourceforge/jnlp/JNLPFile.java > --- a/netx/net/sourceforge/jnlp/JNLPFile.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/JNLPFile.java Tue Jan 11 11:31:28 2011 -0500 > @@ -80,7 +80,7 @@ > protected Version specVersion; > > /** information */ > - protected List info; > + protected List info; > > protected UpdateDesc update; > > @@ -326,7 +326,7 @@ > List result = new ArrayList(); > > for (int i = 0; i < info.size(); i++) { > - InformationDesc infoDesc = (InformationDesc) info.get(i); > + InformationDesc infoDesc = info.get(i); > > if (localMatches(locale, infoDesc.getLocales())) > if (localMatches(locale, infoDesc.getLocales())) -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at redhat.com Tue Jan 11 09:18:06 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 11 Jan 2011 12:18:06 -0500 Subject: [icedtea-web] RFC: add missing generic type in JNLPFile In-Reply-To: <20110111170724.GH28602@rivendell.middle-earth.co.uk> References: <4D2C87EB.1000107@redhat.com> <20110111170724.GH28602@rivendell.middle-earth.co.uk> Message-ID: <4D2C90CE.2060400@redhat.com> On 01/11/2011 12:07 PM, Dr Andrew John Hughes wrote: > On 11:40 Tue 11 Jan , Omair Majid wrote: >> Hi, >> >> The attached patch adds a generic type to 'info' in JNLPFile. >> > Looks good. javac clearly misses these; is this with ecj? Actually, I ran across this particular case while trying to use the variable. But yes, ecj points it out too. Cheers, Omair From ahughes at redhat.com Tue Jan 11 10:13:37 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Tue, 11 Jan 2011 18:13:37 +0000 Subject: [icedtea-web] RFC: add missing generic type in JNLPFile In-Reply-To: <4D2C90CE.2060400@redhat.com> References: <4D2C87EB.1000107@redhat.com> <20110111170724.GH28602@rivendell.middle-earth.co.uk> <4D2C90CE.2060400@redhat.com> Message-ID: <20110111181336.GJ28602@rivendell.middle-earth.co.uk> On 12:18 Tue 11 Jan , Omair Majid wrote: > On 01/11/2011 12:07 PM, Dr Andrew John Hughes wrote: > > On 11:40 Tue 11 Jan , Omair Majid wrote: > >> Hi, > >> > >> The attached patch adds a generic type to 'info' in JNLPFile. > >> > > Looks good. javac clearly misses these; is this with ecj? > > Actually, I ran across this particular case while trying to use the > variable. But yes, ecj points it out too. > Yeah, I was thinking of both this and the import warnings patch you posted. ecj is the only compiler I know that warns about unused imports with the default settings ;-) > Cheers, > Omair -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Tue Jan 11 10:37:26 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Tue, 11 Jan 2011 18:37:26 +0000 Subject: RFC: VisualVM Harness 1.1 Release In-Reply-To: <20110110164947.GA13053@rivendell.middle-earth.co.uk> References: <20110110164947.GA13053@rivendell.middle-earth.co.uk> Message-ID: <20110111183726.GM28602@rivendell.middle-earth.co.uk> On 16:49 Mon 10 Jan , Dr Andrew John Hughes wrote: > I'd like to release an updated version of the VisualVM Harness, 1.1. > There have been a number of changes in the repository since the 1.0 > release: > > * Support for VisualVM 1.3.1 > http://icedtea.classpath.org/hg/visualvm/rev/ba2ccec163d0 > > * Make VisualVM work outside the JVM directory structure > so builds work with configuration files in /etc and libraries in /usr/lib. > http://icedtea.classpath.org/hg/visualvm/rev/afb288d37834 > > * Remove the invalid Version field from visualvm.desktop and install > it in the correct location under $(datadir)/applications. > http://icedtea.classpath.org/hg/visualvm/rev/df40da40c697 > http://icedtea.classpath.org/hg/visualvm/rev/307d1a64ee76 > > * Add debugging information to the native shared libraries > http://icedtea.classpath.org/hg/visualvm/rev/d0293407ac9c > > Does anyone have any further patches they'd like to see in 1.1? > If there are no further comments, I'll make the release tomorrow evening > (Tuesday, 11th of January) at around 18:00 UTC. > As proposed, I'm going to go ahead with a release of VisualVM Harness 1.1 now. > Thanks, > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From asu at redhat.com Tue Jan 11 11:19:57 2011 From: asu at redhat.com (Andrew Su) Date: Tue, 11 Jan 2011 14:19:57 -0500 Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. Message-ID: <4D2CAD5D.10009@redhat.com> Hello, I have attached a patch which allows exceptions be logged to file if the option "Enable logging" is set in deployments.property file. Comments? Questions? Concerns? Cheers, Andrew -------------- next part -------------- A non-text attachment was scrubbed... Name: 20110111_add_logging.patch Type: text/x-patch Size: 4790 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110111/d79d1f48/20110111_add_logging.patch From andrew at icedtea.classpath.org Tue Jan 11 12:28:50 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Tue, 11 Jan 2011 20:28:50 +0000 Subject: /hg/visualvm: 3 new changesets Message-ID: changeset 162f041b396c in /hg/visualvm details: http://icedtea.classpath.org/hg/visualvm?cmd=changeset;node=162f041b396c author: Andrew John Hughes date: Tue Jan 11 20:18:33 2011 +0000 Provide uninstallation option. 2011-01-11 Andrew John Hughes * Makefile.am: (uninstall-local): Provide uninstallation option. changeset a9687562ffcc in /hg/visualvm details: http://icedtea.classpath.org/hg/visualvm?cmd=changeset;node=a9687562ffcc author: Andrew John Hughes date: Tue Jan 11 20:22:57 2011 +0000 Update NEWS and bump to 1.1. 2011-01-11 Andrew John Hughes * NEWS: Updated. * configure.ac: Bump to 1.1. changeset 749ac25272d8 in /hg/visualvm details: http://icedtea.classpath.org/hg/visualvm?cmd=changeset;node=749ac25272d8 author: Andrew John Hughes date: Tue Jan 11 20:27:52 2011 +0000 Added tag 1.1 for changeset a9687562ffcc diffstat: 5 files changed, 28 insertions(+), 1 deletion(-) .hgtags | 1 + ChangeLog | 10 ++++++++++ Makefile.am | 7 +++++++ NEWS | 9 +++++++++ configure.ac | 2 +- diffs (68 lines): diff -r d0293407ac9c -r 749ac25272d8 .hgtags --- a/.hgtags Sat Jan 08 02:00:50 2011 +0000 +++ b/.hgtags Tue Jan 11 20:27:52 2011 +0000 @@ -1,1 +1,2 @@ 8b1172973c70ab07f27468f719b6b34c96586779 8b1172973c70ab07f27468f719b6b34c96586779 1.0 +a9687562ffccc1dc97fd7dd0a8d3ad718f765ed3 1.1 diff -r d0293407ac9c -r 749ac25272d8 ChangeLog --- a/ChangeLog Sat Jan 08 02:00:50 2011 +0000 +++ b/ChangeLog Tue Jan 11 20:27:52 2011 +0000 @@ -1,3 +1,13 @@ 2011-01-08 Andrew John Hughes + + * NEWS: Updated. + * configure.ac: Bump to 1.1. + +2011-01-11 Andrew John Hughes + + * Makefile.am: + (uninstall-local): Provide uninstallation option. + 2011-01-08 Andrew John Hughes * Makefile.am: diff -r d0293407ac9c -r 749ac25272d8 Makefile.am --- a/Makefile.am Sat Jan 08 02:00:50 2011 +0000 +++ b/Makefile.am Tue Jan 11 20:27:52 2011 +0000 @@ -214,6 +214,13 @@ install-exec-local: cp -r netbeans/nbbuild/netbeans_visualvm/$(PROFILER) $(DESTDIR)$(libdir)/visualvm cp visualvm.desktop $(DESTDIR)$(datadir)/applications +uninstall-local: + rm -f $(DESTDIR)$(bindir)/jvisualvm + rm -f $(DESTDIR)$(sysconfdir)/visualvm.conf + rm -f $(DESTDIR)$(sysconfdir)/visualvm.clusters + rm -rf $(DESTDIR)$(libdir)/visualvm + rm -f $(DESTDIR)$(datadir)/applications/visualvm.desktop + download-netbeans-profiler: stamps/download-netbeans-profiler.stamp download-visualvm: stamps/download-visualvm.stamp diff -r d0293407ac9c -r 749ac25272d8 NEWS --- a/NEWS Sat Jan 08 02:00:50 2011 +0000 +++ b/NEWS Tue Jan 11 20:27:52 2011 +0000 @@ -8,6 +8,15 @@ GX - http://bugs.gentoo.org/show_bug.cg CVE-XXXX-YYYY: http://www.cve.mitre.org/cgi-bin/cvename.cgi?name=XXXX-YYYY +New in release 1.1 (2011-01-11): + +* Support for VisualVM 1.3.1. +* Make VisualVM work outside the JVM directory structure. +* Remove the invalid Version field from visualvm.desktop. +* Install visualvm.desktop in the correct location under $(datadir)/applications. +* Add debugging information to the native shared libraries. +* Provide uninstallation support. + New in release 1.0 (2010-09-08): * Separation of VisualVM build harness from IcedTea6. diff -r d0293407ac9c -r 749ac25272d8 configure.ac --- a/configure.ac Sat Jan 08 02:00:50 2011 +0000 +++ b/configure.ac Tue Jan 11 20:27:52 2011 +0000 @@ -1,4 +1,4 @@ AC_INIT([visualvm_harness], [1.1pre], [d -AC_INIT([visualvm_harness], [1.1pre], [distro-pkg-dev at openjdk.java.net]) +AC_INIT([visualvm_harness], [1.1], [distro-pkg-dev at openjdk.java.net]) AM_INIT_AUTOMAKE([1.9 tar-pax foreign]) AC_CONFIG_FILES([Makefile visualvm.desktop]) From ahughes at redhat.com Tue Jan 11 12:33:29 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Tue, 11 Jan 2011 20:33:29 +0000 Subject: VisualVM Harness 1.1 Released! Message-ID: <20110111203329.GO28602@rivendell.middle-earth.co.uk> We are pleased to announce the release of version 1.1 of the VisualVM harness! The main changes are the addition of support for VisualVM 1.3.1 and the ability to install VisualVM outside the JDK directory structure. What's New ========== * Support for VisualVM 1.3.1. * Make VisualVM work outside the JVM directory structure. * Remove the invalid Version field from visualvm.desktop. * Install visualvm.desktop in the correct location under $(datadir)/applications. * Add debugging information to the native shared libraries. * Provide uninstallation support. The tarball can be downloaded from: http://icedtea.classpath.org/download/source/visualvm_harness-1.1.tar.gz sha256sum: 69ed2ec8867052757ea2ee416a87a2f636553dbeaa36b452dc5036817672177a The following people helped with the 1.0 release: Andrew John Hughes, Tomas Hurka, Jiri Vanek We would also like to thank all the bug reporters and testers! To get started: $ tar xzf visualvm_harness-1.1.tar.gz $ ./configure $ make $ make install Full build requirements and instructions are in INSTALL. To build VisualVM 1.3, the option --with-visualvm-version=1.3 should be specified. To build VisualVM 1.3.1, the option --with-visualvm-version=1.3.1 should be specified. The default remains 1.2.2. -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and the OpenJDK http://www.gnu.org/software/classpath http://openjdk.java.net PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From asu at redhat.com Tue Jan 11 12:39:52 2011 From: asu at redhat.com (Andrew Su) Date: Tue, 11 Jan 2011 15:39:52 -0500 (EST) Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. In-Reply-To: <4D2CAD5D.10009@redhat.com> Message-ID: <1483225093.62137.1294778392529.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> ----- Original Message ----- > From: "Andrew Su" > To: "OpenJDK" > Sent: Tuesday, January 11, 2011 2:19:57 PM > Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. > Hello, > > I have attached a patch which allows exceptions be logged to file if > the > option "Enable logging" is set in deployments.property file. > > Comments? Questions? Concerns? Hi, I have updated the patch (removed unused import). Cheers, Andrew -------------- next part -------------- A non-text attachment was scrubbed... Name: 20110111_add_logging_v2.patch Type: text/x-patch Size: 5402 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110111/5ff3e0d6/20110111_add_logging_v2.patch From ahughes at redhat.com Tue Jan 11 13:00:09 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Tue, 11 Jan 2011 21:00:09 +0000 Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. In-Reply-To: <1483225093.62137.1294778392529.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> References: <4D2CAD5D.10009@redhat.com> <1483225093.62137.1294778392529.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Message-ID: <20110111210009.GQ28602@rivendell.middle-earth.co.uk> On 15:39 Tue 11 Jan , Andrew Su wrote: > > > ----- Original Message ----- > > From: "Andrew Su" > > To: "OpenJDK" > > Sent: Tuesday, January 11, 2011 2:19:57 PM > > Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. > > Hello, > > > > I have attached a patch which allows exceptions be logged to file if > > the > > option "Enable logging" is set in deployments.property file. > > > > Comments? Questions? Concerns? > > Hi, > > I have updated the patch (removed unused import). > > Cheers, > Andrew As Log and AppletLogger should never have instances (as far as I can tell), you should add a private no-argument constructor to prevent them being created. Also, it would be nice to break the long line in Log (the getName() one) onto two lines. Other than that, looks good. > diff -r dc02a605f905 ChangeLog > --- a/ChangeLog Fri Jan 07 08:00:08 2011 -0500 > +++ b/ChangeLog Tue Jan 11 15:37:29 2011 -0500 > @@ -1,3 +1,13 @@ > +2011-01-11 Andrew Su > + > + * makefile.am: Added net.sourceforge.jnlp.config to NETX_PKGS > + variable. > + * netx/net/sourceforge/jnlp/NetxPanel.java: > + (showAppletException): Override, adds logging to file. Then proceed > + with showAppletException in sun.applet.AppletPanel > + * netx/net/sourceforge/jnlp/debug/AppletLogger.java: New class. > + * netx/net/sourceforge/jnlp/debug/Log.java: New class. > + > 2011-01-04 Omair Majid > > * netx/net/sourceforge/jnlp/security/KeyStores.java > diff -r dc02a605f905 Makefile.am > --- a/Makefile.am Fri Jan 07 08:00:08 2011 -0500 > +++ b/Makefile.am Tue Jan 11 15:37:29 2011 -0500 > @@ -29,7 +29,8 @@ > net.sourceforge.jnlp.cache net.sourceforge.jnlp.event \ > net.sourceforge.jnlp.security net.sourceforge.jnlp.security.viewer \ > net.sourceforge.jnlp.services net.sourceforge.jnlp.tools \ > - net.sourceforge.jnlp.util net.sourceforge.jnlp.controlpanel > + net.sourceforge.jnlp.util net.sourceforge.jnlp.controlpanel \ > + net.sourceforge.jnlp.debug > > # Conditional defintions > if ENABLE_PLUGIN > diff -r dc02a605f905 netx/net/sourceforge/jnlp/NetxPanel.java > --- a/netx/net/sourceforge/jnlp/NetxPanel.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/NetxPanel.java Tue Jan 11 15:37:29 2011 -0500 > @@ -22,6 +22,7 @@ > > package net.sourceforge.jnlp; > > +import net.sourceforge.jnlp.debug.AppletLogger; > import net.sourceforge.jnlp.runtime.AppThreadGroup; > import net.sourceforge.jnlp.runtime.AppletInstance; > import net.sourceforge.jnlp.runtime.JNLPRuntime; > @@ -68,6 +69,12 @@ > super.run(); > } > > + @Override > + protected void showAppletException(Throwable t) { > + AppletLogger.log(t); // log the exception > + super.showAppletException(t); > + } > + > //Overriding to use Netx classloader. You might need to relax visibility > //in sun.applet.AppletPanel for runLoader(). > protected void runLoader() { > diff -r dc02a605f905 netx/net/sourceforge/jnlp/debug/AppletLogger.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/debug/AppletLogger.java Tue Jan 11 15:37:29 2011 -0500 > @@ -0,0 +1,42 @@ > +package net.sourceforge.jnlp.debug; > + > +import java.io.IOException; > +import java.util.logging.FileHandler; > +import java.util.logging.Level; > +import java.util.logging.Logger; > +import java.util.logging.XMLFormatter; > + > +/** > + * This class writes log information to file. > + * @author Andrew Su (asu at redhat.com, andrew.su at utoronto.ca) > + * > + */ > +public class AppletLogger extends Log { > + public static Logger logger; > + > + static { > + try { > + // If logging is enabled, we create logger. > + if (enableLogging) { > + String fn = icedteaLogDir + "Plugin" + java.lang.System.currentTimeMillis() + ".log"; > + boolean append = false; > + FileHandler fh = new FileHandler(fn, append); > + fh.setFormatter(new XMLFormatter()); > + logger = Logger.getLogger(AppletLogger.class.getPackage().getName() + "." + AppletLogger.class.getName()); > + logger.setLevel(Level.ALL); > + logger.addHandler(fh); > + } > + } catch (IOException e) { > + e.printStackTrace(); > + } > + } > + > + public synchronized static void log(Throwable e) { > + if (enableLogging) { > + String ex = e.toString(); > + for (StackTraceElement ste : e.getStackTrace()) > + ex = ex + "\n\tat " + ste; > + logger.log(Level.FINE, ex); > + } > + } > +} > diff -r dc02a605f905 netx/net/sourceforge/jnlp/debug/Log.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/debug/Log.java Tue Jan 11 15:37:29 2011 -0500 > @@ -0,0 +1,46 @@ > +package net.sourceforge.jnlp.debug; > + > +import java.io.File; > + > +import javax.naming.ConfigurationException; > + > +import net.sourceforge.jnlp.config.DeploymentConfiguration; > + > +/** > + * This file provides the information required to do logging. > + * @author Andrew Su (asu at redhat.com, andrew.su at utoronto.ca) > + * > + */ > +public class Log { > + > + // Directory where the logs are stored. > + public static String icedteaLogDir; > + > + public static boolean enableLogging = false; > + public static boolean enableTracing = false; > + > + // Prepare for logging. > + static { > + DeploymentConfiguration config = new DeploymentConfiguration(); > + try { > + config.load(); > + } catch (ConfigurationException e) { > + e.printStackTrace(); > + } > + > + // Check whether logging and tracing is enabled. > + enableLogging = Boolean.parseBoolean(config.getProperty(DeploymentConfiguration.KEY_ENABLE_LOGGING)); > + enableTracing = Boolean.parseBoolean(config.getProperty(DeploymentConfiguration.KEY_ENABLE_TRACING)); > + > + // Get log directory, create it if it doesn't exist. If unable to create and doesn't exist, don't log. > + icedteaLogDir = config.getProperty(DeploymentConfiguration.KEY_USER_LOG_DIR); > + if (icedteaLogDir != null) { > + File f = new File(icedteaLogDir); > + if (f.isDirectory() || f.mkdirs()) > + icedteaLogDir += File.separator; > + else > + enableLogging = false; > + } > + } > + > +} -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From asu at redhat.com Tue Jan 11 13:19:13 2011 From: asu at redhat.com (Andrew Su) Date: Tue, 11 Jan 2011 16:19:13 -0500 Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. In-Reply-To: <20110111210009.GQ28602@rivendell.middle-earth.co.uk> References: <4D2CAD5D.10009@redhat.com> <1483225093.62137.1294778392529.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <20110111210009.GQ28602@rivendell.middle-earth.co.uk> Message-ID: <4D2CC951.4030607@redhat.com> On 01/11/2011 04:00 PM, Dr Andrew John Hughes wrote: > On 15:39 Tue 11 Jan , Andrew Su wrote: >> >> ----- Original Message ----- >>> From: "Andrew Su" >>> To: "OpenJDK" >>> Sent: Tuesday, January 11, 2011 2:19:57 PM >>> Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. >>> Hello, >>> >>> I have attached a patch which allows exceptions be logged to file if >>> the >>> option "Enable logging" is set in deployments.property file. >>> >>> Comments? Questions? Concerns? >> Hi, >> >> I have updated the patch (removed unused import). >> >> Cheers, >> Andrew > As Log and AppletLogger should never have instances (as far as I can tell), you > should add a private no-argument constructor to prevent them being created. > Also, it would be nice to break the long line in Log (the getName() one) onto > two lines. > Other than that, looks good. Hi Andrew, I have made the above changes, but making constructor for Log private needs me to make a different constructor for AppletLogger so instead I used no modifier for the constructor which is only accessible from the same package. (However used private for AppletLogger's constructor.) Ok for head? Cheers, Andrew -------------- next part -------------- A non-text attachment was scrubbed... Name: 20110111_add_logging_v3.patch Type: text/x-patch Size: 5461 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110111/17f30895/20110111_add_logging_v3.patch From omajid at redhat.com Tue Jan 11 13:30:20 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 11 Jan 2011 16:30:20 -0500 Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. In-Reply-To: <1483225093.62137.1294778392529.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> References: <1483225093.62137.1294778392529.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Message-ID: <4D2CCBEC.9060009@redhat.com> On 01/11/2011 03:39 PM, Andrew Su wrote: > > ----- Original Message ----- >>> From: "Andrew Su" To: >>> "OpenJDK" Sent: Tuesday, January >>> 11, 2011 2:19:57 PM Subject: [RFC][IcedTea-Web]: Add Logging of >>> applet exceptions. Hello, >>> >>> I have attached a patch which allows exceptions be logged to file >>> if the option "Enable logging" is set in deployments.property >>> file. >>> >>> Comments? Questions? Concerns? > Hi, > > I have updated the patch (removed unused import). Am I correct in understanding that this only log exceptions from init()/start()/stop()/destroy() ? > > diff -r dc02a605f905 ChangeLog > --- a/ChangeLog Fri Jan 07 08:00:08 2011 -0500 > +++ b/ChangeLog Tue Jan 11 15:37:29 2011 -0500 > @@ -1,3 +1,13 @@ > +2011-01-11 Andrew Su > + > + * makefile.am: Added net.sourceforge.jnlp.config to NETX_PKGS > + variable. Looks like a typo here (should be net.sourceforge.jnlp.debug). On that note, net.sourceforge.jnlp.config is not in NETX_PKGS either. That must have been my mistake. > + * netx/net/sourceforge/jnlp/NetxPanel.java: > + (showAppletException): Override, adds logging to file. Then proceed > + with showAppletException in sun.applet.AppletPanel > + * netx/net/sourceforge/jnlp/debug/AppletLogger.java: New class. > + * netx/net/sourceforge/jnlp/debug/Log.java: New class. > + > 2011-01-04 Omair Majid > > * netx/net/sourceforge/jnlp/security/KeyStores.java > diff -r dc02a605f905 Makefile.am > --- a/Makefile.am Fri Jan 07 08:00:08 2011 -0500 > +++ b/Makefile.am Tue Jan 11 15:37:29 2011 -0500 > @@ -29,7 +29,8 @@ > net.sourceforge.jnlp.cache net.sourceforge.jnlp.event \ > net.sourceforge.jnlp.security net.sourceforge.jnlp.security.viewer \ > net.sourceforge.jnlp.services net.sourceforge.jnlp.tools \ > - net.sourceforge.jnlp.util net.sourceforge.jnlp.controlpanel > + net.sourceforge.jnlp.util net.sourceforge.jnlp.controlpanel \ > + net.sourceforge.jnlp.debug > > # Conditional defintions > if ENABLE_PLUGIN > diff -r dc02a605f905 netx/net/sourceforge/jnlp/NetxPanel.java > --- a/netx/net/sourceforge/jnlp/NetxPanel.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/NetxPanel.java Tue Jan 11 15:37:29 2011 -0500 > @@ -22,6 +22,7 @@ > > package net.sourceforge.jnlp; > > +import net.sourceforge.jnlp.debug.AppletLogger; > import net.sourceforge.jnlp.runtime.AppThreadGroup; > import net.sourceforge.jnlp.runtime.AppletInstance; > import net.sourceforge.jnlp.runtime.JNLPRuntime; > @@ -68,6 +69,12 @@ > super.run(); > } > > + @Override > + protected void showAppletException(Throwable t) { > + AppletLogger.log(t); // log the exception > + super.showAppletException(t); > + } > + Nicely done! > //Overriding to use Netx classloader. You might need to relax visibility > //in sun.applet.AppletPanel for runLoader(). > protected void runLoader() { > diff -r dc02a605f905 netx/net/sourceforge/jnlp/debug/AppletLogger.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/debug/AppletLogger.java Tue Jan 11 15:37:29 2011 -0500 > @@ -0,0 +1,42 @@ > +package net.sourceforge.jnlp.debug; > + > +import java.io.IOException; > +import java.util.logging.FileHandler; > +import java.util.logging.Level; > +import java.util.logging.Logger; > +import java.util.logging.XMLFormatter; > + > +/** > + * This class writes log information to file. > + * @author Andrew Su (asu at redhat.com,andrew.su at utoronto.ca) > + * > + */ > +public class AppletLogger extends Log { This may be just nitpicking, but I dont like the names. "AppletLogger extends Log" sounds a little strange. Maybe use "AppletLog extends Log" or "AppletLogger extends Logger"? > + public static Logger logger; > + > + static { > + try { > + // If logging is enabled, we create logger. > + if (enableLogging) { > + String fn = icedteaLogDir + "Plugin" + java.lang.System.currentTimeMillis() + ".log"; > + boolean append = false; > + FileHandler fh = new FileHandler(fn, append); > + fh.setFormatter(new XMLFormatter()); Hmm.. is this line saying that logs should be written in XML? > + logger = Logger.getLogger(AppletLogger.class.getPackage().getName() + "." + AppletLogger.class.getName()); > + logger.setLevel(Level.ALL); > + logger.addHandler(fh); > + } > + } catch (IOException e) { > + e.printStackTrace(); > + } > + } > + > + public synchronized static void log(Throwable e) { > + if (enableLogging) { > + String ex = e.toString(); > + for (StackTraceElement ste : e.getStackTrace()) > + ex = ex + "\n\tat " + ste; > + logger.log(Level.FINE, ex); > + } Perhaps using ex.printStackTrace(PrintStream) might be better? I dont know how well the simple for loop handles exceptions with causes. > + } > +} > diff -r dc02a605f905 netx/net/sourceforge/jnlp/debug/Log.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/debug/Log.java Tue Jan 11 15:37:29 2011 -0500 > @@ -0,0 +1,46 @@ > +package net.sourceforge.jnlp.debug; > + > +import java.io.File; > + > +import javax.naming.ConfigurationException; > + > +import net.sourceforge.jnlp.config.DeploymentConfiguration; > + > +/** > + * This file provides the information required to do logging. > + * @author Andrew Su (asu at redhat.com,andrew.su at utoronto.ca) > + * > + */ > +public class Log { > + > + // Directory where the logs are stored. > + public static String icedteaLogDir; > + > + public static boolean enableLogging = false; > + public static boolean enableTracing = false; > + > + // Prepare for logging. > + static { > + DeploymentConfiguration config = new DeploymentConfiguration(); > + try { > + config.load(); > + } catch (ConfigurationException e) { > + e.printStackTrace(); > + } > + This is done by JNLPRuntime.initialize() early in the plugin initialization phase. I dont think this is needed here at all. > + // Check whether logging and tracing is enabled. > + enableLogging = Boolean.parseBoolean(config.getProperty(DeploymentConfiguration.KEY_ENABLE_LOGGING)); > + enableTracing = Boolean.parseBoolean(config.getProperty(DeploymentConfiguration.KEY_ENABLE_TRACING)); > + > + // Get log directory, create it if it doesn't exist. If unable to create and doesn't exist, don't log. > + icedteaLogDir = config.getProperty(DeploymentConfiguration.KEY_USER_LOG_DIR); > + if (icedteaLogDir != null) { > + File f = new File(icedteaLogDir); > + if (f.isDirectory() || f.mkdirs()) > + icedteaLogDir += File.separator; > + else > + enableLogging = false; > + } > + } > + > +} Cheers, Omair From ahughes at redhat.com Tue Jan 11 14:41:57 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Tue, 11 Jan 2011 22:41:57 +0000 Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. In-Reply-To: <4D2CC951.4030607@redhat.com> References: <4D2CAD5D.10009@redhat.com> <1483225093.62137.1294778392529.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <20110111210009.GQ28602@rivendell.middle-earth.co.uk> <4D2CC951.4030607@redhat.com> Message-ID: <20110111224157.GS28602@rivendell.middle-earth.co.uk> On 16:19 Tue 11 Jan , Andrew Su wrote: > On 01/11/2011 04:00 PM, Dr Andrew John Hughes wrote: > > On 15:39 Tue 11 Jan , Andrew Su wrote: > >> > >> ----- Original Message ----- > >>> From: "Andrew Su" > >>> To: "OpenJDK" > >>> Sent: Tuesday, January 11, 2011 2:19:57 PM > >>> Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. > >>> Hello, > >>> > >>> I have attached a patch which allows exceptions be logged to file if > >>> the > >>> option "Enable logging" is set in deployments.property file. > >>> > >>> Comments? Questions? Concerns? > >> Hi, > >> > >> I have updated the patch (removed unused import). > >> > >> Cheers, > >> Andrew > > As Log and AppletLogger should never have instances (as far as I can tell), you > > should add a private no-argument constructor to prevent them being created. > > Also, it would be nice to break the long line in Log (the getName() one) onto > > two lines. > > Other than that, looks good. > Hi Andrew, > > I have made the above changes, but making constructor for Log private > needs me to make a different constructor for AppletLogger so instead I > used no modifier for the constructor which is only accessible from the > same package. (However used private for AppletLogger's constructor.) > Ah yes, that's because the subclass constructor will implicitly call super(). Looks fine. > Ok for head? > > Cheers, > Andrew > diff -r dc02a605f905 ChangeLog > --- a/ChangeLog Fri Jan 07 08:00:08 2011 -0500 > +++ b/ChangeLog Tue Jan 11 16:16:20 2011 -0500 > @@ -1,3 +1,13 @@ > +2011-01-11 Andrew Su > + > + * makefile.am: Added net.sourceforge.jnlp.config to NETX_PKGS > + variable. > + * netx/net/sourceforge/jnlp/NetxPanel.java: > + (showAppletException): Override, adds logging to file. Then proceed > + with showAppletException in sun.applet.AppletPanel > + * netx/net/sourceforge/jnlp/debug/AppletLogger.java: New class. > + * netx/net/sourceforge/jnlp/debug/Log.java: New class. > + > 2011-01-04 Omair Majid > > * netx/net/sourceforge/jnlp/security/KeyStores.java > diff -r dc02a605f905 Makefile.am > --- a/Makefile.am Fri Jan 07 08:00:08 2011 -0500 > +++ b/Makefile.am Tue Jan 11 16:16:20 2011 -0500 > @@ -29,7 +29,8 @@ > net.sourceforge.jnlp.cache net.sourceforge.jnlp.event \ > net.sourceforge.jnlp.security net.sourceforge.jnlp.security.viewer \ > net.sourceforge.jnlp.services net.sourceforge.jnlp.tools \ > - net.sourceforge.jnlp.util net.sourceforge.jnlp.controlpanel > + net.sourceforge.jnlp.util net.sourceforge.jnlp.controlpanel \ > + net.sourceforge.jnlp.debug > > # Conditional defintions > if ENABLE_PLUGIN > diff -r dc02a605f905 netx/net/sourceforge/jnlp/NetxPanel.java > --- a/netx/net/sourceforge/jnlp/NetxPanel.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/NetxPanel.java Tue Jan 11 16:16:20 2011 -0500 > @@ -22,6 +22,7 @@ > > package net.sourceforge.jnlp; > > +import net.sourceforge.jnlp.debug.AppletLogger; > import net.sourceforge.jnlp.runtime.AppThreadGroup; > import net.sourceforge.jnlp.runtime.AppletInstance; > import net.sourceforge.jnlp.runtime.JNLPRuntime; > @@ -68,6 +69,12 @@ > super.run(); > } > > + @Override > + protected void showAppletException(Throwable t) { > + AppletLogger.log(t); // log the exception > + super.showAppletException(t); > + } > + > //Overriding to use Netx classloader. You might need to relax visibility > //in sun.applet.AppletPanel for runLoader(). > protected void runLoader() { > diff -r dc02a605f905 netx/net/sourceforge/jnlp/debug/AppletLogger.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/debug/AppletLogger.java Tue Jan 11 16:16:20 2011 -0500 > @@ -0,0 +1,45 @@ > +package net.sourceforge.jnlp.debug; > + > +import java.io.IOException; > +import java.util.logging.FileHandler; > +import java.util.logging.Level; > +import java.util.logging.Logger; > +import java.util.logging.XMLFormatter; > + > +/** > + * This class writes log information to file. > + * @author Andrew Su (asu at redhat.com, andrew.su at utoronto.ca) > + * > + */ > +public class AppletLogger extends Log { > + public static Logger logger; > + > + static { > + try { > + // If logging is enabled, we create logger. > + if (enableLogging) { > + String fn = icedteaLogDir + "Plugin" + java.lang.System.currentTimeMillis() + ".log"; > + boolean append = false; > + FileHandler fh = new FileHandler(fn, append); > + fh.setFormatter(new XMLFormatter()); > + String logClassName = AppletLogger.class.getName(); > + logger = Logger.getLogger(logClassName); > + logger.setLevel(Level.ALL); > + logger.addHandler(fh); > + } > + } catch (IOException e) { > + e.printStackTrace(); > + } > + } > + > + private AppletLogger(){} > + > + public synchronized static void log(Throwable e) { > + if (enableLogging) { > + String ex = e.toString(); > + for (StackTraceElement ste : e.getStackTrace()) > + ex = ex + "\n\tat " + ste; > + logger.log(Level.FINE, ex); > + } > + } > +} > diff -r dc02a605f905 netx/net/sourceforge/jnlp/debug/Log.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/debug/Log.java Tue Jan 11 16:16:20 2011 -0500 > @@ -0,0 +1,48 @@ > +package net.sourceforge.jnlp.debug; > + > +import java.io.File; > + > +import javax.naming.ConfigurationException; > + > +import net.sourceforge.jnlp.config.DeploymentConfiguration; > + > +/** > + * This file provides the information required to do logging. > + * @author Andrew Su (asu at redhat.com, andrew.su at utoronto.ca) > + * > + */ > +public class Log { > + > + // Directory where the logs are stored. > + public static String icedteaLogDir; > + > + public static boolean enableLogging = false; > + public static boolean enableTracing = false; > + > + // Prepare for logging. > + static { > + DeploymentConfiguration config = new DeploymentConfiguration(); > + try { > + config.load(); > + } catch (ConfigurationException e) { > + e.printStackTrace(); > + } > + > + // Check whether logging and tracing is enabled. > + enableLogging = Boolean.parseBoolean(config.getProperty(DeploymentConfiguration.KEY_ENABLE_LOGGING)); > + enableTracing = Boolean.parseBoolean(config.getProperty(DeploymentConfiguration.KEY_ENABLE_TRACING)); > + > + // Get log directory, create it if it doesn't exist. If unable to create and doesn't exist, don't log. > + icedteaLogDir = config.getProperty(DeploymentConfiguration.KEY_USER_LOG_DIR); > + if (icedteaLogDir != null) { > + File f = new File(icedteaLogDir); > + if (f.isDirectory() || f.mkdirs()) > + icedteaLogDir += File.separator; > + else > + enableLogging = false; > + } > + } > + > + Log(){} > + > +} -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From asu at redhat.com Tue Jan 11 18:46:00 2011 From: asu at redhat.com (Andrew Su) Date: Tue, 11 Jan 2011 21:46:00 -0500 Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. In-Reply-To: <4D2CCBEC.9060009@redhat.com> References: <1483225093.62137.1294778392529.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <4D2CCBEC.9060009@redhat.com> Message-ID: <4D2D15E8.6040708@redhat.com> On 01/11/2011 04:30 PM, Omair Majid wrote: > On 01/11/2011 03:39 PM, Andrew Su wrote: >> >> ----- Original Message ----- >>>> From: "Andrew Su" To: >>>> "OpenJDK" Sent: Tuesday, January >>>> 11, 2011 2:19:57 PM Subject: [RFC][IcedTea-Web]: Add Logging of >>>> applet exceptions. Hello, >>>> >>>> I have attached a patch which allows exceptions be logged to file >>>> if the option "Enable logging" is set in deployments.property >>>> file. >>>> >>>> Comments? Questions? Concerns? >> Hi, >> >> I have updated the patch (removed unused import). > > Am I correct in understanding that this only log exceptions from > init()/start()/stop()/destroy() ? Yes. > >> >> diff -r dc02a605f905 ChangeLog >> --- a/ChangeLog Fri Jan 07 08:00:08 2011 -0500 >> +++ b/ChangeLog Tue Jan 11 15:37:29 2011 -0500 >> @@ -1,3 +1,13 @@ >> +2011-01-11 Andrew Su >> + >> + * makefile.am: Added net.sourceforge.jnlp.config to NETX_PKGS >> + variable. > > Looks like a typo here (should be net.sourceforge.jnlp.debug). On that > note, net.sourceforge.jnlp.config is not in NETX_PKGS either. That > must have been my mistake. Oops, I was going to put that in another patch, but accidentally typed it there.. > >> + * netx/net/sourceforge/jnlp/NetxPanel.java: >> + (showAppletException): Override, adds logging to file. Then proceed >> + with showAppletException in sun.applet.AppletPanel >> + * netx/net/sourceforge/jnlp/debug/AppletLogger.java: New class. >> + * netx/net/sourceforge/jnlp/debug/Log.java: New class. >> + >> 2011-01-04 Omair Majid >> >> * netx/net/sourceforge/jnlp/security/KeyStores.java >> diff -r dc02a605f905 Makefile.am >> --- a/Makefile.am Fri Jan 07 08:00:08 2011 -0500 >> +++ b/Makefile.am Tue Jan 11 15:37:29 2011 -0500 >> @@ -29,7 +29,8 @@ >> net.sourceforge.jnlp.cache net.sourceforge.jnlp.event \ >> net.sourceforge.jnlp.security >> net.sourceforge.jnlp.security.viewer \ >> net.sourceforge.jnlp.services net.sourceforge.jnlp.tools \ >> - net.sourceforge.jnlp.util net.sourceforge.jnlp.controlpanel >> + net.sourceforge.jnlp.util net.sourceforge.jnlp.controlpanel \ >> + net.sourceforge.jnlp.debug >> >> # Conditional defintions >> if ENABLE_PLUGIN >> diff -r dc02a605f905 netx/net/sourceforge/jnlp/NetxPanel.java >> --- a/netx/net/sourceforge/jnlp/NetxPanel.java Fri Jan 07 08:00:08 >> 2011 -0500 >> +++ b/netx/net/sourceforge/jnlp/NetxPanel.java Tue Jan 11 15:37:29 >> 2011 -0500 >> @@ -22,6 +22,7 @@ >> >> package net.sourceforge.jnlp; >> >> +import net.sourceforge.jnlp.debug.AppletLogger; >> import net.sourceforge.jnlp.runtime.AppThreadGroup; >> import net.sourceforge.jnlp.runtime.AppletInstance; >> import net.sourceforge.jnlp.runtime.JNLPRuntime; >> @@ -68,6 +69,12 @@ >> super.run(); >> } >> >> + @Override >> + protected void showAppletException(Throwable t) { >> + AppletLogger.log(t); // log the exception >> + super.showAppletException(t); >> + } >> + > > Nicely done! Thanks! > >> //Overriding to use Netx classloader. You might need to relax >> visibility >> //in sun.applet.AppletPanel for runLoader(). >> protected void runLoader() { >> diff -r dc02a605f905 netx/net/sourceforge/jnlp/debug/AppletLogger.java >> --- /dev/null Thu Jan 01 00:00:00 1970 +0000 >> +++ b/netx/net/sourceforge/jnlp/debug/AppletLogger.java Tue Jan 11 >> 15:37:29 2011 -0500 >> @@ -0,0 +1,42 @@ >> +package net.sourceforge.jnlp.debug; >> + >> +import java.io.IOException; >> +import java.util.logging.FileHandler; >> +import java.util.logging.Level; >> +import java.util.logging.Logger; >> +import java.util.logging.XMLFormatter; >> + >> +/** >> + * This class writes log information to file. >> + * @author Andrew Su (asu at redhat.com,andrew.su at utoronto.ca) >> + * >> + */ >> +public class AppletLogger extends Log { > > This may be just nitpicking, but I dont like the names. "AppletLogger > extends Log" sounds a little strange. Maybe use "AppletLog extends > Log" or "AppletLogger extends Logger"? Ah, you're not going to like the follow up patch for adding tracing, "AppletTracer" guess I'll make that "AppletTrace". ;) > >> + public static Logger logger; >> + >> + static { >> + try { >> + // If logging is enabled, we create logger. >> + if (enableLogging) { >> + String fn = icedteaLogDir + "Plugin" + >> java.lang.System.currentTimeMillis() + ".log"; >> + boolean append = false; >> + FileHandler fh = new FileHandler(fn, append); >> + fh.setFormatter(new XMLFormatter()); > > Hmm.. is this line saying that logs should be written in XML? Yes, this is to follow the format of how the proprietary plugin does logging. This will keep any tools being used with those logs to continue with our plugin's logs. > >> + logger = >> Logger.getLogger(AppletLogger.class.getPackage().getName() + "." + >> AppletLogger.class.getName()); >> + logger.setLevel(Level.ALL); >> + logger.addHandler(fh); >> + } >> + } catch (IOException e) { >> + e.printStackTrace(); >> + } >> + } >> + >> + public synchronized static void log(Throwable e) { >> + if (enableLogging) { >> + String ex = e.toString(); >> + for (StackTraceElement ste : e.getStackTrace()) >> + ex = ex + "\n\tat " + ste; >> + logger.log(Level.FINE, ex); >> + } > > Perhaps using ex.printStackTrace(PrintStream) might be better? I dont > know how well the simple for loop handles exceptions with causes. Ah, yes, changed. > >> + } >> +} >> diff -r dc02a605f905 netx/net/sourceforge/jnlp/debug/Log.java >> --- /dev/null Thu Jan 01 00:00:00 1970 +0000 >> +++ b/netx/net/sourceforge/jnlp/debug/Log.java Tue Jan 11 15:37:29 >> 2011 -0500 >> @@ -0,0 +1,46 @@ >> +package net.sourceforge.jnlp.debug; >> + >> +import java.io.File; >> + >> +import javax.naming.ConfigurationException; >> + >> +import net.sourceforge.jnlp.config.DeploymentConfiguration; >> + >> +/** >> + * This file provides the information required to do logging. >> + * @author Andrew Su (asu at redhat.com,andrew.su at utoronto.ca) >> + * >> + */ >> +public class Log { >> + >> + // Directory where the logs are stored. >> + public static String icedteaLogDir; >> + >> + public static boolean enableLogging = false; >> + public static boolean enableTracing = false; >> + >> + // Prepare for logging. >> + static { >> + DeploymentConfiguration config = new DeploymentConfiguration(); >> + try { >> + config.load(); >> + } catch (ConfigurationException e) { >> + e.printStackTrace(); >> + } >> + > > This is done by JNLPRuntime.initialize() early in the plugin > initialization phase. I dont think this is needed here at all. Changed to calling JNLPRuntime.getConfiguration(). Thanks for looking it over, here is the updated patch with the said changes. -------------- next part -------------- A non-text attachment was scrubbed... Name: 20110111_add_logging_v4.patch Type: text/x-patch Size: 5447 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110111/1d2a6b55/20110111_add_logging_v4.patch From schumi.han at gmail.com Wed Jan 12 02:08:32 2011 From: schumi.han at gmail.com (Zhu Han) Date: Wed, 12 Jan 2011 18:08:32 +0800 Subject: "-client" option In-Reply-To: <4D2C3787.60702@redhat.com> References: <4D2B3147.20100@redhat.com> <4D2C3787.60702@redhat.com> Message-ID: On Tue, Jan 11, 2011 at 6:57 PM, Andrew Haley wrote: > > 640MB is just the pre-allocated address space size, half of them are >> anonymous mmap region. RSS is just around 48MB. I want to control the >> total size of address space because the JVM process spawns several >> sub-process to execute some scripts provided by OS occasionally. I know >> this >> is not portable, but seems like there is no better way to open a URL in >> standalone browser from a java application. >> > > But these regions are mapped as MAP_NORESERVE, so it shouldn't matter. > > > This may be failed because of lack of swap space to backup address space. >> > > OK, so now I understand what the real problem is. > > I'm assuming Linux. > > I don't understand why this is happening. I wonder if you have some > odd setting. > > What is /proc/sys/vm/overcommit_memory? /proc/sys/vm/overcommit_ratio? > > /proc/meminfo ? > Because it will be deployed as a desktop application. So I have no control over settings of /proc/sys/vm/overcommit_memory. And some distributions set it as 0, at least it is 0 on my Ubuntu 10.04. The failure can be observed only on resource limited environment. I have written a small script and communicate with JVM through local loopback TCP connection. This is a possible workaround. But, it is quite ugly... Do you have any good suggestions? Thank you. > > Andrew. > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110112/290b1f85/attachment.html From aph at redhat.com Wed Jan 12 03:57:05 2011 From: aph at redhat.com (Andrew Haley) Date: Wed, 12 Jan 2011 11:57:05 +0000 Subject: "-client" option In-Reply-To: References: <4D2B3147.20100@redhat.com> <4D2C3787.60702@redhat.com> Message-ID: <4D2D9711.9050206@redhat.com> On 01/12/2011 10:08 AM, Zhu Han wrote: > On Tue, Jan 11, 2011 at 6:57 PM, Andrew Haley wrote: > >> 640MB is just the pre-allocated address space size, half of them are >>> anonymous mmap region. RSS is just around 48MB. I want to control the >>> total size of address space because the JVM process spawns several >>> sub-process to execute some scripts provided by OS occasionally. I know >>> this >>> is not portable, but seems like there is no better way to open a URL in >>> standalone browser from a java application. >>> >> >> But these regions are mapped as MAP_NORESERVE, so it shouldn't matter. >> >> >> This may be failed because of lack of swap space to backup address space. >>> >> >> OK, so now I understand what the real problem is. >> >> I'm assuming Linux. >> >> I don't understand why this is happening. I wonder if you have some >> odd setting. >> >> What is /proc/sys/vm/overcommit_memory? /proc/sys/vm/overcommit_ratio? >> >> /proc/meminfo ? >> > > Because it will be deployed as a desktop application. So I have no control > over settings of /proc/sys/vm/overcommit_memory. And some distributions set > it as 0, at least it is 0 on my Ubuntu 10.04. 0 should be fine. > The failure can be observed only on resource limited environment. > > I have written a small script and communicate with JVM through local > loopback TCP connection. This is a possible workaround. But, it is quite > ugly... I've had a look, and the big mappings seem to be MAP_PRIVATE|MAP_NORESERVE per-thread regions allocated for the malloc heap by glibc. Every thread has its own heap, and these are pre-allocated in 64M chunks. A bunch of special-purpose threads are started by the VM, so you have a multiple of these 64M mappings. So, I don't think there's much you can do about it. But in any case, MAP_NORESERVE doesn't reserve memory, so you shouldn't start getting an OOM condition until you really run out of memory, not just address space. Andrew. From asu at redhat.com Wed Jan 12 07:00:24 2011 From: asu at redhat.com (Andrew Su) Date: Wed, 12 Jan 2011 10:00:24 -0500 (EST) Subject: /hg/icedtea-web: remove control panel's dependency on JNLPRuntim... In-Reply-To: Message-ID: <365727830.74109.1294844424499.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Hello Omair, I was trying to use control panel to set some values, but noticed the look and feel was not how it should be and also I get a few exceptions from CertificatePane. java.lang.NullPointerException at java.io.File.(File.java:239) at net.sourceforge.jnlp.security.KeyStores.getKeyStore(KeyStores.java:124) at net.sourceforge.jnlp.security.KeyStores.getKeyStore(KeyStores.java:103) at net.sourceforge.jnlp.security.viewer.CertificatePane.initializeKeyStore(CertificatePane.java:148) at net.sourceforge.jnlp.security.viewer.CertificatePane.repopulateTables(CertificatePane.java:285) at net.sourceforge.jnlp.security.viewer.CertificatePane.(CertificatePane.java:140) at net.sourceforge.jnlp.controlpanel.ControlPanel.createCertificatesSettingsPanel(ControlPanel.java:276) at net.sourceforge.jnlp.controlpanel.ControlPanel.createMainSettingsPanel(ControlPanel.java:220) at net.sourceforge.jnlp.controlpanel.ControlPanel.(ControlPanel.java:108) at net.sourceforge.jnlp.controlpanel.ControlPanel$5.run(ControlPanel.java:360) at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:226) at java.awt.EventQueue.dispatchEvent(EventQueue.java:602) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:275) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:200) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:185) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:177) at java.awt.EventDispatchThread.run(EventDispatchThread.java:138) java.lang.NullPointerException at net.sourceforge.jnlp.security.viewer.CertificatePane.readKeyStore(CertificatePane.java:258) at net.sourceforge.jnlp.security.viewer.CertificatePane.repopulateTables(CertificatePane.java:286) at net.sourceforge.jnlp.security.viewer.CertificatePane.(CertificatePane.java:140) at net.sourceforge.jnlp.controlpanel.ControlPanel.createCertificatesSettingsPanel(ControlPanel.java:276) at net.sourceforge.jnlp.controlpanel.ControlPanel.createMainSettingsPanel(ControlPanel.java:220) at net.sourceforge.jnlp.controlpanel.ControlPanel.(ControlPanel.java:108) at net.sourceforge.jnlp.controlpanel.ControlPanel$5.run(ControlPanel.java:360) at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:226) at java.awt.EventQueue.dispatchEvent(EventQueue.java:602) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:275) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:200) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:185) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:177) at java.awt.EventDispatchThread.run(EventDispatchThread.java:138) The reason the use of JNLPRuntime was so that CertificatePane didn't do this + it also sets the look and feel. Regards, Andrew ----- Original Message ----- > From: omajid at icedtea.classpath.org > To: distro-pkg-dev at openjdk.java.net > Sent: Tuesday, January 4, 2011 2:45:25 PM > Subject: /hg/icedtea-web: remove control panel's dependency on JNLPRuntim... > changeset c938ea901f2f in /hg/icedtea-web > details: > http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=c938ea901f2f > author: Omair Majid > date: Tue Jan 04 14:45:10 2011 -0500 > > remove control panel's dependency on JNLPRuntime and other minor > cleanup > > 2011-01-04 Omair Majid > > * netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java: > Remove JNLPRuntime import. Remove configBrowserCommand. > (createMainSettingsPanel): Remove call to loadConfiguration. > (loadConfiguration): Remove method. Setting the browser command > should be handled by the appropriate panel. (main): Remove call > to JNLPRuntime.initialize and just create a new > DeploymentConfiguration object. Clarify TODO comment. > > > diffstat: > > 2 files changed, 19 insertions(+), 22 deletions(-) > ChangeLog | 10 ++++ > netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java | 31 > ++++---------- > > diffs (96 lines): > > diff -r 8e1b7bb5f2fc -r c938ea901f2f ChangeLog > --- a/ChangeLog Tue Jan 04 13:08:25 2011 -0500 > +++ b/ChangeLog Tue Jan 04 14:45:10 2011 -0500 > @@ -1,3 +1,13 @@ 2011-01-04 Omair Majid +2011-01-04 Omair Majid > + > + * netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java: Remove > + JNLPRuntime import. Remove configBrowserCommand. > + (createMainSettingsPanel): Remove call to loadConfiguration. > + (loadConfiguration): Remove method. Setting the browser command > + should be handled by the appropriate panel. > + (main): Remove call to JNLPRuntime.initialize and just create a new > + DeploymentConfiguration object. Clarify TODO comment. > + > 2011-01-04 Omair Majid > > * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java > diff -r 8e1b7bb5f2fc -r c938ea901f2f > netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java > --- a/netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java Tue Jan > 04 13:08:25 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java Tue Jan > 04 14:45:10 2011 -0500 > @@ -1,5 +1,5 @@ > /* ControlPanel.java -- Display the control panel for modifying > deployment settings. > -Copyright (C) 2010 Red Hat > +Copyright (C) 2011 Red Hat > > This program is free software; you can redistribute it and/or modify > it under the terms of the GNU General Public License as published by > @@ -52,7 +52,6 @@ import javax.swing.event.ListSelectionLi > import javax.swing.event.ListSelectionListener; > > import net.sourceforge.jnlp.config.DeploymentConfiguration; > -import net.sourceforge.jnlp.runtime.JNLPRuntime; > import net.sourceforge.jnlp.runtime.Translator; > import net.sourceforge.jnlp.security.viewer.CertificatePane; > > @@ -91,11 +90,6 @@ public class ControlPanel extends JFrame > } > > private DeploymentConfiguration config = null; > - > - /* > - * actual configuration options > - */ > - private String configBrowserCommand = null; > > /** > * Creates a new instance of the ControlPanel. > @@ -223,8 +217,6 @@ public class ControlPanel extends JFrame > */ > private JPanel createMainSettingsPanel() { > > - loadConfiguration(); > - > SettingsPanel[] panels = new SettingsPanel[] { new > SettingsPanel(Translator.R("CPTabAbout"), createAboutPanel()), > new SettingsPanel(Translator.R("CPTabCache"), > createCacheSettingsPanel()), > new SettingsPanel(Translator.R("CPTabCertificate"), > createCertificatesSettingsPanel()), > @@ -338,16 +330,6 @@ public class ControlPanel extends JFrame > } > > /** > - * Get the location of the browser. > - */ > - private void loadConfiguration() { > - configBrowserCommand = > config.getProperty("deployment.browser.path"); > - if (configBrowserCommand == null) { > - configBrowserCommand = ""; > - } > - } > - > - /** > * Save the configuration changes. > */ > private void saveConfiguration() { > @@ -359,14 +341,19 @@ public class ControlPanel extends JFrame > } > > public static void main(String[] args) throws Exception { > - JNLPRuntime.initialize(true); > - final DeploymentConfiguration config = > JNLPRuntime.getConfiguration(); > + final DeploymentConfiguration config = new > DeploymentConfiguration(); > try { > config.load(); > } catch (ConfigurationException e) { > - // TODO Auto-generated catch block > + // FIXME inform user about this and exit properly > + // the only known condition under which this can happen is when a > + // required system configuration file is not found > + > + // if configuration is not loaded, we will get NullPointerExceptions > + // everywhere > e.printStackTrace(); > } > + > SwingUtilities.invokeLater(new Runnable() { > @Override > public void run() { From ahughes at redhat.com Wed Jan 12 07:08:23 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Wed, 12 Jan 2011 15:08:23 +0000 Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. In-Reply-To: <4D2D15E8.6040708@redhat.com> References: <1483225093.62137.1294778392529.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <4D2CCBEC.9060009@redhat.com> <4D2D15E8.6040708@redhat.com> Message-ID: <20110112150823.GA15701@rivendell.middle-earth.co.uk> On 21:46 Tue 11 Jan , Andrew Su wrote: > On 01/11/2011 04:30 PM, Omair Majid wrote: > > On 01/11/2011 03:39 PM, Andrew Su wrote: > >> > >> ----- Original Message ----- > >>>> From: "Andrew Su" To: > >>>> "OpenJDK" Sent: Tuesday, January > >>>> 11, 2011 2:19:57 PM Subject: [RFC][IcedTea-Web]: Add Logging of > >>>> applet exceptions. Hello, > >>>> > >>>> I have attached a patch which allows exceptions be logged to file > >>>> if the option "Enable logging" is set in deployments.property > >>>> file. > >>>> > >>>> Comments? Questions? Concerns? > >> Hi, > >> > >> I have updated the patch (removed unused import). > > > > Am I correct in understanding that this only log exceptions from > > init()/start()/stop()/destroy() ? > Yes. > > > >> > >> diff -r dc02a605f905 ChangeLog > >> --- a/ChangeLog Fri Jan 07 08:00:08 2011 -0500 > >> +++ b/ChangeLog Tue Jan 11 15:37:29 2011 -0500 > >> @@ -1,3 +1,13 @@ > >> +2011-01-11 Andrew Su > >> + > >> + * makefile.am: Added net.sourceforge.jnlp.config to NETX_PKGS > >> + variable. > > > > Looks like a typo here (should be net.sourceforge.jnlp.debug). On that > > note, net.sourceforge.jnlp.config is not in NETX_PKGS either. That > > must have been my mistake. > Oops, I was going to put that in another patch, but accidentally typed > it there.. > > > >> + * netx/net/sourceforge/jnlp/NetxPanel.java: > >> + (showAppletException): Override, adds logging to file. Then proceed > >> + with showAppletException in sun.applet.AppletPanel > >> + * netx/net/sourceforge/jnlp/debug/AppletLogger.java: New class. > >> + * netx/net/sourceforge/jnlp/debug/Log.java: New class. > >> + > >> 2011-01-04 Omair Majid > >> > >> * netx/net/sourceforge/jnlp/security/KeyStores.java > >> diff -r dc02a605f905 Makefile.am > >> --- a/Makefile.am Fri Jan 07 08:00:08 2011 -0500 > >> +++ b/Makefile.am Tue Jan 11 15:37:29 2011 -0500 > >> @@ -29,7 +29,8 @@ > >> net.sourceforge.jnlp.cache net.sourceforge.jnlp.event \ > >> net.sourceforge.jnlp.security > >> net.sourceforge.jnlp.security.viewer \ > >> net.sourceforge.jnlp.services net.sourceforge.jnlp.tools \ > >> - net.sourceforge.jnlp.util net.sourceforge.jnlp.controlpanel > >> + net.sourceforge.jnlp.util net.sourceforge.jnlp.controlpanel \ > >> + net.sourceforge.jnlp.debug > >> > >> # Conditional defintions > >> if ENABLE_PLUGIN > >> diff -r dc02a605f905 netx/net/sourceforge/jnlp/NetxPanel.java > >> --- a/netx/net/sourceforge/jnlp/NetxPanel.java Fri Jan 07 08:00:08 > >> 2011 -0500 > >> +++ b/netx/net/sourceforge/jnlp/NetxPanel.java Tue Jan 11 15:37:29 > >> 2011 -0500 > >> @@ -22,6 +22,7 @@ > >> > >> package net.sourceforge.jnlp; > >> > >> +import net.sourceforge.jnlp.debug.AppletLogger; > >> import net.sourceforge.jnlp.runtime.AppThreadGroup; > >> import net.sourceforge.jnlp.runtime.AppletInstance; > >> import net.sourceforge.jnlp.runtime.JNLPRuntime; > >> @@ -68,6 +69,12 @@ > >> super.run(); > >> } > >> > >> + @Override > >> + protected void showAppletException(Throwable t) { > >> + AppletLogger.log(t); // log the exception > >> + super.showAppletException(t); > >> + } > >> + > > > > Nicely done! > Thanks! > > > >> //Overriding to use Netx classloader. You might need to relax > >> visibility > >> //in sun.applet.AppletPanel for runLoader(). > >> protected void runLoader() { > >> diff -r dc02a605f905 netx/net/sourceforge/jnlp/debug/AppletLogger.java > >> --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > >> +++ b/netx/net/sourceforge/jnlp/debug/AppletLogger.java Tue Jan 11 > >> 15:37:29 2011 -0500 > >> @@ -0,0 +1,42 @@ > >> +package net.sourceforge.jnlp.debug; > >> + > >> +import java.io.IOException; > >> +import java.util.logging.FileHandler; > >> +import java.util.logging.Level; > >> +import java.util.logging.Logger; > >> +import java.util.logging.XMLFormatter; > >> + > >> +/** > >> + * This class writes log information to file. > >> + * @author Andrew Su (asu at redhat.com,andrew.su at utoronto.ca) > >> + * > >> + */ > >> +public class AppletLogger extends Log { > > > > This may be just nitpicking, but I dont like the names. "AppletLogger > > extends Log" sounds a little strange. Maybe use "AppletLog extends > > Log" or "AppletLogger extends Logger"? > Ah, you're not going to like the follow up patch for adding tracing, > "AppletTracer" guess I'll make that "AppletTrace". ;) > > > > >> + public static Logger logger; > >> + > >> + static { > >> + try { > >> + // If logging is enabled, we create logger. > >> + if (enableLogging) { > >> + String fn = icedteaLogDir + "Plugin" + > >> java.lang.System.currentTimeMillis() + ".log"; > >> + boolean append = false; > >> + FileHandler fh = new FileHandler(fn, append); > >> + fh.setFormatter(new XMLFormatter()); > > > > Hmm.. is this line saying that logs should be written in XML? > Yes, this is to follow the format of how the proprietary plugin does > logging. This will keep any tools being used with those logs to continue > with our plugin's logs. Is there any real advantage to this? Do you have an example of the output to see how readable it is? I don't think we should do things just because some proprietary vendor's product does. > > > >> + logger = > >> Logger.getLogger(AppletLogger.class.getPackage().getName() + "." + > >> AppletLogger.class.getName()); > >> + logger.setLevel(Level.ALL); > >> + logger.addHandler(fh); > >> + } > >> + } catch (IOException e) { > >> + e.printStackTrace(); > >> + } > >> + } > >> + > >> + public synchronized static void log(Throwable e) { > >> + if (enableLogging) { > >> + String ex = e.toString(); > >> + for (StackTraceElement ste : e.getStackTrace()) > >> + ex = ex + "\n\tat " + ste; > >> + logger.log(Level.FINE, ex); > >> + } > > > > Perhaps using ex.printStackTrace(PrintStream) might be better? I dont > > know how well the simple for loop handles exceptions with causes. > Ah, yes, changed. > > > >> + } > >> +} > >> diff -r dc02a605f905 netx/net/sourceforge/jnlp/debug/Log.java > >> --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > >> +++ b/netx/net/sourceforge/jnlp/debug/Log.java Tue Jan 11 15:37:29 > >> 2011 -0500 > >> @@ -0,0 +1,46 @@ > >> +package net.sourceforge.jnlp.debug; > >> + > >> +import java.io.File; > >> + > >> +import javax.naming.ConfigurationException; > >> + > >> +import net.sourceforge.jnlp.config.DeploymentConfiguration; > >> + > >> +/** > >> + * This file provides the information required to do logging. > >> + * @author Andrew Su (asu at redhat.com,andrew.su at utoronto.ca) > >> + * > >> + */ > >> +public class Log { > >> + > >> + // Directory where the logs are stored. > >> + public static String icedteaLogDir; > >> + > >> + public static boolean enableLogging = false; > >> + public static boolean enableTracing = false; > >> + > >> + // Prepare for logging. > >> + static { > >> + DeploymentConfiguration config = new DeploymentConfiguration(); > >> + try { > >> + config.load(); > >> + } catch (ConfigurationException e) { > >> + e.printStackTrace(); > >> + } > >> + > > > > This is done by JNLPRuntime.initialize() early in the plugin > > initialization phase. I dont think this is needed here at all. > Changed to calling JNLPRuntime.getConfiguration(). > > Thanks for looking it over, here is the updated patch with the said changes. > > > > diff -r dc02a605f905 ChangeLog > --- a/ChangeLog Fri Jan 07 08:00:08 2011 -0500 > +++ b/ChangeLog Tue Jan 11 21:45:49 2011 -0500 > @@ -1,3 +1,13 @@ > +2011-01-11 Andrew Su > + > + * makefile.am: Added net.sourceforge.jnlp.debug to NETX_PKGS > + variable. > + * netx/net/sourceforge/jnlp/NetxPanel.java: > + (showAppletException): Override, adds logging to file. Then proceed > + with showAppletException in sun.applet.AppletPanel > + * netx/net/sourceforge/jnlp/debug/AppletLog.java: New class. > + * netx/net/sourceforge/jnlp/debug/Log.java: New class. > + > 2011-01-04 Omair Majid > > * netx/net/sourceforge/jnlp/security/KeyStores.java > diff -r dc02a605f905 Makefile.am > --- a/Makefile.am Fri Jan 07 08:00:08 2011 -0500 > +++ b/Makefile.am Tue Jan 11 21:45:49 2011 -0500 > @@ -29,7 +29,8 @@ > net.sourceforge.jnlp.cache net.sourceforge.jnlp.event \ > net.sourceforge.jnlp.security net.sourceforge.jnlp.security.viewer \ > net.sourceforge.jnlp.services net.sourceforge.jnlp.tools \ > - net.sourceforge.jnlp.util net.sourceforge.jnlp.controlpanel > + net.sourceforge.jnlp.util net.sourceforge.jnlp.controlpanel \ > + net.sourceforge.jnlp.debug > > # Conditional defintions > if ENABLE_PLUGIN > diff -r dc02a605f905 netx/net/sourceforge/jnlp/NetxPanel.java > --- a/netx/net/sourceforge/jnlp/NetxPanel.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/NetxPanel.java Tue Jan 11 21:45:49 2011 -0500 > @@ -22,6 +22,7 @@ > > package net.sourceforge.jnlp; > > +import net.sourceforge.jnlp.debug.AppletLog; > import net.sourceforge.jnlp.runtime.AppThreadGroup; > import net.sourceforge.jnlp.runtime.AppletInstance; > import net.sourceforge.jnlp.runtime.JNLPRuntime; > @@ -68,6 +69,12 @@ > super.run(); > } > > + @Override > + protected void showAppletException(Throwable t) { > + AppletLog.log(t); // log the exception > + super.showAppletException(t); > + } > + > //Overriding to use Netx classloader. You might need to relax visibility > //in sun.applet.AppletPanel for runLoader(). > protected void runLoader() { > diff -r dc02a605f905 netx/net/sourceforge/jnlp/debug/AppletLog.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/debug/AppletLog.java Tue Jan 11 21:45:49 2011 -0500 > @@ -0,0 +1,48 @@ > +package net.sourceforge.jnlp.debug; > + > +import java.io.ByteArrayOutputStream; > +import java.io.IOException; > +import java.io.PrintStream; > +import java.util.logging.FileHandler; > +import java.util.logging.Level; > +import java.util.logging.Logger; > +import java.util.logging.XMLFormatter; > + > +/** > + * This class writes log information to file. > + * @author Andrew Su (asu at redhat.com, andrew.su at utoronto.ca) > + * > + */ > +public class AppletLog extends Log { > + public static Logger logger; > + > + static { > + try { > + // If logging is enabled, we create logger. > + if (enableLogging) { > + String fn = icedteaLogDir + "Plugin" + java.lang.System.currentTimeMillis() + ".log"; > + boolean append = false; > + FileHandler fh = new FileHandler(fn, append); > + fh.setFormatter(new XMLFormatter()); > + String logClassName = AppletLog.class.getName(); > + logger = Logger.getLogger(logClassName); > + logger.setLevel(Level.ALL); > + logger.addHandler(fh); > + } > + } catch (IOException e) { > + e.printStackTrace(); > + } > + } > + > + private AppletLog() { > + } > + > + public synchronized static void log(Throwable e) { > + if (enableLogging) { > + ByteArrayOutputStream baos = new ByteArrayOutputStream(); > + PrintStream ps = new PrintStream(baos); > + e.printStackTrace(ps); > + logger.log(Level.FINE, baos.toString()); > + } > + } > +} > diff -r dc02a605f905 netx/net/sourceforge/jnlp/debug/Log.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/debug/Log.java Tue Jan 11 21:45:49 2011 -0500 > @@ -0,0 +1,43 @@ > +package net.sourceforge.jnlp.debug; > + > +import java.io.File; > + > +import net.sourceforge.jnlp.config.DeploymentConfiguration; > +import net.sourceforge.jnlp.runtime.JNLPRuntime; > + > +/** > + * This file provides the information required to do logging. > + * @author Andrew Su (asu at redhat.com, andrew.su at utoronto.ca) > + * > + */ > +public class Log { > + > + // Directory where the logs are stored. > + public static String icedteaLogDir; > + > + public static boolean enableLogging = false; > + public static boolean enableTracing = false; > + > + // Prepare for logging. > + static { > + DeploymentConfiguration config = JNLPRuntime.getConfiguration(); > + > + // Check whether logging and tracing is enabled. > + enableLogging = Boolean.parseBoolean(config.getProperty(DeploymentConfiguration.KEY_ENABLE_LOGGING)); > + enableTracing = Boolean.parseBoolean(config.getProperty(DeploymentConfiguration.KEY_ENABLE_TRACING)); > + > + // Get log directory, create it if it doesn't exist. If unable to create and doesn't exist, don't log. > + icedteaLogDir = config.getProperty(DeploymentConfiguration.KEY_USER_LOG_DIR); > + System.out.println(icedteaLogDir); > + if (icedteaLogDir != null) { > + File f = new File(icedteaLogDir); > + if (f.isDirectory() || f.mkdirs()) > + icedteaLogDir += File.separator; > + else > + enableLogging = false; > + } > + } > + > + Log() {} > + > +} -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From asu at redhat.com Wed Jan 12 07:15:33 2011 From: asu at redhat.com (Andrew Su) Date: Wed, 12 Jan 2011 10:15:33 -0500 (EST) Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. In-Reply-To: <20110112150823.GA15701@rivendell.middle-earth.co.uk> Message-ID: <1707366967.74652.1294845333531.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> --Snip-- > > > > > >> + public static Logger logger; > > >> + > > >> + static { > > >> + try { > > >> + // If logging is enabled, we create logger. > > >> + if (enableLogging) { > > >> + String fn = icedteaLogDir + "Plugin" + > > >> java.lang.System.currentTimeMillis() + ".log"; > > >> + boolean append = false; > > >> + FileHandler fh = new FileHandler(fn, append); > > >> + fh.setFormatter(new XMLFormatter()); > > > > > > Hmm.. is this line saying that logs should be written in XML? > > Yes, this is to follow the format of how the proprietary plugin does > > logging. This will keep any tools being used with those logs to > > continue > > with our plugin's logs. > > Is there any real advantage to this? Do you have an example of the > output > to see how readable it is? I don't think we should do things just > because > some proprietary vendor's product does. Here is an example of how it would look like. 2011-01-12T10:14:58 1294845298608 0 net.sourceforge.jnlp.debug.AppletLog FINE net.sourceforge.jnlp.debug.AppletLog log 10 java.lang.NullPointerException at Democritus.init(Democritus.java:25) at sun.applet.AppletPanel.run(AppletPanel.java:436) at net.sourceforge.jnlp.NetxPanel.run(NetxPanel.java:69) at java.lang.Thread.run(Thread.java:636) > > > > > > >> + logger = > > >> Logger.getLogger(AppletLogger.class.getPackage().getName() + "." > > >> + > > >> AppletLogger.class.getName()); > > >> + logger.setLevel(Level.ALL); > > >> + logger.addHandler(fh); > > >> + } > > >> + } catch (IOException e) { > > >> + e.printStackTrace(); > > >> + } > > >> + } --Snip-- Regards, Andrew From omajid at redhat.com Wed Jan 12 07:53:01 2011 From: omajid at redhat.com (Omair Majid) Date: Wed, 12 Jan 2011 10:53:01 -0500 Subject: /hg/icedtea-web: remove control panel's dependency on JNLPRuntim... In-Reply-To: <365727830.74109.1294844424499.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> References: <365727830.74109.1294844424499.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Message-ID: <4D2DCE5D.2010000@redhat.com> On 01/12/2011 10:00 AM, Andrew Su wrote: > Hello Omair, > > I was trying to use control panel to set some values, but noticed the look and feel was not how it should be and also I get a few exceptions from CertificatePane. > > java.lang.NullPointerException > at java.io.File.(File.java:239) > at net.sourceforge.jnlp.security.KeyStores.getKeyStore(KeyStores.java:124) > at net.sourceforge.jnlp.security.KeyStores.getKeyStore(KeyStores.java:103) > at net.sourceforge.jnlp.security.viewer.CertificatePane.initializeKeyStore(CertificatePane.java:148) > at net.sourceforge.jnlp.security.viewer.CertificatePane.repopulateTables(CertificatePane.java:285) > at net.sourceforge.jnlp.security.viewer.CertificatePane.(CertificatePane.java:140) > at net.sourceforge.jnlp.controlpanel.ControlPanel.createCertificatesSettingsPanel(ControlPanel.java:276) > at net.sourceforge.jnlp.controlpanel.ControlPanel.createMainSettingsPanel(ControlPanel.java:220) > at net.sourceforge.jnlp.controlpanel.ControlPanel.(ControlPanel.java:108) > at net.sourceforge.jnlp.controlpanel.ControlPanel$5.run(ControlPanel.java:360) > at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:226) > at java.awt.EventQueue.dispatchEvent(EventQueue.java:602) > at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:275) > at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:200) > at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190) > at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:185) > at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:177) > at java.awt.EventDispatchThread.run(EventDispatchThread.java:138) > java.lang.NullPointerException > at net.sourceforge.jnlp.security.viewer.CertificatePane.readKeyStore(CertificatePane.java:258) > at net.sourceforge.jnlp.security.viewer.CertificatePane.repopulateTables(CertificatePane.java:286) > at net.sourceforge.jnlp.security.viewer.CertificatePane.(CertificatePane.java:140) > at net.sourceforge.jnlp.controlpanel.ControlPanel.createCertificatesSettingsPanel(ControlPanel.java:276) > at net.sourceforge.jnlp.controlpanel.ControlPanel.createMainSettingsPanel(ControlPanel.java:220) > at net.sourceforge.jnlp.controlpanel.ControlPanel.(ControlPanel.java:108) > at net.sourceforge.jnlp.controlpanel.ControlPanel$5.run(ControlPanel.java:360) > at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:226) > at java.awt.EventQueue.dispatchEvent(EventQueue.java:602) > at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:275) > at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:200) > at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190) > at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:185) > at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:177) > at java.awt.EventDispatchThread.run(EventDispatchThread.java:138) > > > The reason the use of JNLPRuntime was so that CertificatePane didn't do this + it also sets the look and feel. > Thanks for catching the error. I noticed the look and feel problem myself this morning, but I didnt notice the exceptions. I would really like to avoid calling JNLPRuntime.initialize(), since that sets up a whole bunch of other stuff that the control panel really does not need - such as the security manager, security threads and so on. Ideally, there would be no dependencies to anything else in Netx either, but CertificatePane is intent on making things more interesting for us :/ The attached patch is my attempt at fixing things. Or do you think it would be better to revert the original patch (remove the dependency on JNLPRuntime) ? Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: fix-laf-keystore-exceptions-01.patch Type: text/x-patch Size: 3038 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110112/7452b32d/fix-laf-keystore-exceptions-01.patch From ahughes at redhat.com Wed Jan 12 08:00:40 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Wed, 12 Jan 2011 16:00:40 +0000 Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. In-Reply-To: <1707366967.74652.1294845333531.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> References: <20110112150823.GA15701@rivendell.middle-earth.co.uk> <1707366967.74652.1294845333531.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Message-ID: <20110112160039.GB15701@rivendell.middle-earth.co.uk> On 10:15 Wed 12 Jan , Andrew Su wrote: > > --Snip-- > > > > > > > >> + public static Logger logger; > > > >> + > > > >> + static { > > > >> + try { > > > >> + // If logging is enabled, we create logger. > > > >> + if (enableLogging) { > > > >> + String fn = icedteaLogDir + "Plugin" + > > > >> java.lang.System.currentTimeMillis() + ".log"; > > > >> + boolean append = false; > > > >> + FileHandler fh = new FileHandler(fn, append); > > > >> + fh.setFormatter(new XMLFormatter()); > > > > > > > > Hmm.. is this line saying that logs should be written in XML? > > > Yes, this is to follow the format of how the proprietary plugin does > > > logging. This will keep any tools being used with those logs to > > > continue > > > with our plugin's logs. > > > > Is there any real advantage to this? Do you have an example of the > > output > > to see how readable it is? I don't think we should do things just > > because > > some proprietary vendor's product does. > > Here is an example of how it would look like. > > > > > > 2011-01-12T10:14:58 > 1294845298608 > 0 > net.sourceforge.jnlp.debug.AppletLog > FINE > net.sourceforge.jnlp.debug.AppletLog > log > 10 > java.lang.NullPointerException > at Democritus.init(Democritus.java:25) > at sun.applet.AppletPanel.run(AppletPanel.java:436) > at net.sourceforge.jnlp.NetxPanel.run(NetxPanel.java:69) > at java.lang.Thread.run(Thread.java:636) > > > > I guess it is fairly readable, but it would be different to the proprietary logs anyway as the classes will be different. Ok, we'll go with that, unless anyone else objects. > > > > > > > > > > >> + logger = > > > >> Logger.getLogger(AppletLogger.class.getPackage().getName() + "." > > > >> + > > > >> AppletLogger.class.getName()); > > > >> + logger.setLevel(Level.ALL); > > > >> + logger.addHandler(fh); > > > >> + } > > > >> + } catch (IOException e) { > > > >> + e.printStackTrace(); > > > >> + } > > > >> + } > > --Snip-- > > Regards, > Andrew -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From asu at redhat.com Wed Jan 12 08:35:22 2011 From: asu at redhat.com (Andrew Su) Date: Wed, 12 Jan 2011 11:35:22 -0500 (EST) Subject: /hg/icedtea-web: remove control panel's dependency on JNLPRuntim... In-Reply-To: <4D2DCE5D.2010000@redhat.com> Message-ID: <415919376.76596.1294850122215.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> ----- Original Message ----- > From: "Omair Majid" > To: "Andrew Su" > Cc: distro-pkg-dev at openjdk.java.net > Sent: Wednesday, January 12, 2011 10:53:01 AM > Subject: Re: /hg/icedtea-web: remove control panel's dependency on JNLPRuntim... > On 01/12/2011 10:00 AM, Andrew Su wrote: > > Hello Omair, > > > > I was trying to use control panel to set some values, but noticed > > the look and feel was not how it should be and also I get a few > > exceptions from CertificatePane. > > > > java.lang.NullPointerException > > at java.io.File.(File.java:239) > > at > > net.sourceforge.jnlp.security.KeyStores.getKeyStore(KeyStores.java:124) > > at > > net.sourceforge.jnlp.security.KeyStores.getKeyStore(KeyStores.java:103) > > at > > net.sourceforge.jnlp.security.viewer.CertificatePane.initializeKeyStore(CertificatePane.java:148) > > at > > net.sourceforge.jnlp.security.viewer.CertificatePane.repopulateTables(CertificatePane.java:285) > > at > > net.sourceforge.jnlp.security.viewer.CertificatePane.(CertificatePane.java:140) > > at > > net.sourceforge.jnlp.controlpanel.ControlPanel.createCertificatesSettingsPanel(ControlPanel.java:276) > > at > > net.sourceforge.jnlp.controlpanel.ControlPanel.createMainSettingsPanel(ControlPanel.java:220) > > at > > net.sourceforge.jnlp.controlpanel.ControlPanel.(ControlPanel.java:108) > > at > > net.sourceforge.jnlp.controlpanel.ControlPanel$5.run(ControlPanel.java:360) > > at > > java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:226) > > at java.awt.EventQueue.dispatchEvent(EventQueue.java:602) > > at > > java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:275) > > at > > java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:200) > > at > > java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190) > > at > > java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:185) > > at > > java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:177) > > at java.awt.EventDispatchThread.run(EventDispatchThread.java:138) > > java.lang.NullPointerException > > at > > net.sourceforge.jnlp.security.viewer.CertificatePane.readKeyStore(CertificatePane.java:258) > > at > > net.sourceforge.jnlp.security.viewer.CertificatePane.repopulateTables(CertificatePane.java:286) > > at > > net.sourceforge.jnlp.security.viewer.CertificatePane.(CertificatePane.java:140) > > at > > net.sourceforge.jnlp.controlpanel.ControlPanel.createCertificatesSettingsPanel(ControlPanel.java:276) > > at > > net.sourceforge.jnlp.controlpanel.ControlPanel.createMainSettingsPanel(ControlPanel.java:220) > > at > > net.sourceforge.jnlp.controlpanel.ControlPanel.(ControlPanel.java:108) > > at > > net.sourceforge.jnlp.controlpanel.ControlPanel$5.run(ControlPanel.java:360) > > at > > java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:226) > > at java.awt.EventQueue.dispatchEvent(EventQueue.java:602) > > at > > java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:275) > > at > > java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:200) > > at > > java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190) > > at > > java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:185) > > at > > java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:177) > > at java.awt.EventDispatchThread.run(EventDispatchThread.java:138) > > > > > > The reason the use of JNLPRuntime was so that CertificatePane didn't > > do this + it also sets the look and feel. > > > > Thanks for catching the error. I noticed the look and feel problem > myself this morning, but I didnt notice the exceptions. > > I would really like to avoid calling JNLPRuntime.initialize(), since > that sets up a whole bunch of other stuff that the control panel > really > does not need - such as the security manager, security threads and so > on. Ideally, there would be no dependencies to anything else in Netx > either, but CertificatePane is intent on making things more > interesting > for us :/ > > The attached patch is my attempt at fixing things. > > Or do you think it would be better to revert the original patch > (remove > the dependency on JNLPRuntime) ? Hi Omair, This patch looks fine to me and also fixes the issues mentioned. I am for not using JNLPRuntime.initialize() as well. Thanks for the quick fix! Cheers, Andrew > > Cheers, > Omair From omajid at icedtea.classpath.org Wed Jan 12 09:51:08 2011 From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org) Date: Wed, 12 Jan 2011 17:51:08 +0000 Subject: /hg/icedtea-web: 3 new changesets Message-ID: changeset 9a9e757c21d7 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=9a9e757c21d7 author: Omair Majid date: Wed Jan 12 12:31:25 2011 -0500 remove ununsed imports in netx 2011-01-12 Omair Majid * netx/javax/jnlp/UnavailableServiceException.java: Remove unused imports. * netx/net/sourceforge/jnlp/AppletDesc.java: Likewise. * netx/net/sourceforge/jnlp/ApplicationDesc.java: Likewise. * netx/net/sourceforge/jnlp/ComponentDesc.java: Likewise. * netx/net/sourceforge/jnlp/DefaultLaunchHandler.java: Likewise. * netx/net/sourceforge/jnlp/IconDesc.java: Likewise. * netx/net/sourceforge/jnlp/InformationDesc.java: Likewise. * netx/net/sourceforge/jnlp/InstallerDesc.java: Likewise. * netx/net/sourceforge/jnlp/JARDesc.java: Likewise. * netx/net/sourceforge/jnlp/JREDesc.java: Likewise. * netx/net/sourceforge/jnlp/Launcher.java: Likewise. * netx/net/sourceforge/jnlp/PackageDesc.java: Likewise. * netx/net/sourceforge/jnlp/ParseException.java: Likewise. * netx/net/sourceforge/jnlp/PluginBridge.java: Likewise. * netx/net/sourceforge/jnlp/PropertyDesc.java: Likewise. * netx/net/sourceforge/jnlp/ResourcesDesc.java: Likewise. * netx/net/sourceforge/jnlp/Version.java: Likewise. * netx/net/sourceforge/jnlp/cache/CacheEntry.java: Likewise. * netx/net/sourceforge/jnlp/cache/CacheUtil.java: Likewise. * netx/net/sourceforge/jnlp/cache/DefaultDownloadIndicator.java: Likewise. * netx/net/sourceforge/jnlp/cache/DownloadIndicator.java: Likewise. * netx/net/sourceforge/jnlp/cache/UpdatePolicy.java: Likewise. * netx/net/sourceforge/jnlp/controlpanel /AdvancedProxySettingsDialog.java: Likewise. * netx/net/sourceforge/jnlp/controlpanel /AdvancedProxySettingsPane.java: Likewise. * netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java: Likewise. * netx/net/sourceforge/jnlp/controlpanel /TemporaryInternetFilesPanel.java: Likewise. * netx/net/sourceforge/jnlp/event/ApplicationEvent.java: Likewise. * netx/net/sourceforge/jnlp/event/DownloadEvent.java: Likewise. * netx/net/sourceforge/jnlp/runtime/AppThreadGroup.java: Likewise. * netx/net/sourceforge/jnlp/runtime/AppletAudioClip.java: Likewise. * netx/net/sourceforge/jnlp/runtime/AppletInstance.java: Likewise. * netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java: Likewise. * netx/net/sourceforge/jnlp/runtime/Boot13.java: Likewise. * netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java: Likewise. * netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: Likewise. * netx/net/sourceforge/jnlp/security/CertsInfoPane.java: Likewise. * netx/net/sourceforge/jnlp/security/SecurityUtil.java: Likewise. * netx/net/sourceforge/jnlp/services/XBasicService.java: Likewise. * netx/net/sourceforge/jnlp/services/XDownloadService.java: Likewise. * netx/net/sourceforge/jnlp/services/XExtensionInstallerService.java: Likewise. * netx/net/sourceforge/jnlp/services/XFileContents.java: Likewise. * netx/net/sourceforge/jnlp/services/XFileOpenService.java: Likewise. * netx/net/sourceforge/jnlp/services/XFileSaveService.java: Likewise. * netx/net/sourceforge/jnlp/services/XPersistenceService.java: Likewise. * netx/net/sourceforge/jnlp/util/PropertiesFile.java: Likewise. * netx/net/sourceforge/jnlp/util/Reflect.java: Likewise. changeset 47fafd13e0c4 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=47fafd13e0c4 author: Omair Majid date: Wed Jan 12 12:36:36 2011 -0500 add missing generic type in JNLPFile 2011-01-12 Omair Majid * netx/net/sourceforge/jnlp/JNLPFile: Add missing generic type to info. (getInformation): Remove redundant cast. changeset 4e84e06b54e9 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=4e84e06b54e9 author: Omair Majid date: Wed Jan 12 12:50:13 2011 -0500 fix problems in control panel caused by removing JNLPRuntime.initialize() 2011-01-12 Omair Majid * netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java (main): Set look and feel. Set config object to use with KeyStores. * netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java (initialize): Set config object to use with KeyStores. * netx/net/sourceforge/jnlp/security/KeyStores.java: Add new member config. (setConfiguration): New method. Sets the value of config after security check. (getKeyStoreLocation): Use config object instead of querying JNLPRuntime. diffstat: 49 files changed, 104 insertions(+), 137 deletions(-) ChangeLog | 76 ++++++++++ netx/net/sourceforge/jnlp/AppletDesc.java | 1 netx/net/sourceforge/jnlp/ApplicationDesc.java | 2 netx/net/sourceforge/jnlp/ComponentDesc.java | 4 netx/net/sourceforge/jnlp/DefaultLaunchHandler.java | 5 netx/net/sourceforge/jnlp/IconDesc.java | 2 netx/net/sourceforge/jnlp/InformationDesc.java | 2 netx/net/sourceforge/jnlp/InstallerDesc.java | 4 netx/net/sourceforge/jnlp/JARDesc.java | 4 netx/net/sourceforge/jnlp/JNLPFile.java | 4 netx/net/sourceforge/jnlp/JREDesc.java | 1 netx/net/sourceforge/jnlp/Launcher.java | 3 netx/net/sourceforge/jnlp/PackageDesc.java | 4 netx/net/sourceforge/jnlp/ParseException.java | 2 netx/net/sourceforge/jnlp/PluginBridge.java | 1 netx/net/sourceforge/jnlp/PropertyDesc.java | 4 netx/net/sourceforge/jnlp/ResourcesDesc.java | 3 netx/net/sourceforge/jnlp/Version.java | 2 netx/net/sourceforge/jnlp/cache/CacheEntry.java | 4 netx/net/sourceforge/jnlp/cache/CacheUtil.java | 1 netx/net/sourceforge/jnlp/cache/DefaultDownloadIndicator.java | 1 netx/net/sourceforge/jnlp/cache/DownloadIndicator.java | 7 netx/net/sourceforge/jnlp/cache/UpdatePolicy.java | 11 - netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java | 2 netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsPane.java | 2 netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java | 9 + netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java | 3 netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java | 1 netx/net/sourceforge/jnlp/event/ApplicationEvent.java | 1 netx/net/sourceforge/jnlp/event/DownloadEvent.java | 2 netx/net/sourceforge/jnlp/runtime/AppThreadGroup.java | 2 netx/net/sourceforge/jnlp/runtime/AppletAudioClip.java | 1 netx/net/sourceforge/jnlp/runtime/AppletInstance.java | 7 netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java | 1 netx/net/sourceforge/jnlp/runtime/Boot13.java | 2 netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java | 4 netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java | 5 netx/net/sourceforge/jnlp/security/CertsInfoPane.java | 3 netx/net/sourceforge/jnlp/security/KeyStores.java | 15 + netx/net/sourceforge/jnlp/security/SecurityUtil.java | 1 netx/net/sourceforge/jnlp/services/XBasicService.java | 1 netx/net/sourceforge/jnlp/services/XDownloadService.java | 4 netx/net/sourceforge/jnlp/services/XExtensionInstallerService.java | 4 netx/net/sourceforge/jnlp/services/XFileContents.java | 6 netx/net/sourceforge/jnlp/services/XFileOpenService.java | 7 netx/net/sourceforge/jnlp/services/XFileSaveService.java | 4 netx/net/sourceforge/jnlp/services/XPersistenceService.java | 2 netx/net/sourceforge/jnlp/util/PropertiesFile.java | 3 netx/net/sourceforge/jnlp/util/Reflect.java | 1 diffs (truncated from 825 to 500 lines): diff -r dc02a605f905 -r 4e84e06b54e9 ChangeLog --- a/ChangeLog Fri Jan 07 08:00:08 2011 -0500 +++ b/ChangeLog Wed Jan 12 12:50:13 2011 -0500 @@ -1,3 +1,79 @@ 2011-01-04 Omair Majid + + * netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java + (main): Set look and feel. Set config object to use with KeyStores. + * netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java + (initialize): Set config object to use with KeyStores. + * netx/net/sourceforge/jnlp/security/KeyStores.java: Add new member + config. + (setConfiguration): New method. Sets the value of config after security + check. + (getKeyStoreLocation): Use config object instead of querying JNLPRuntime. + +2011-01-12 Omair Majid + + * netx/net/sourceforge/jnlp/JNLPFile: Add missing generic type to info. + (getInformation): Remove redundant cast. + +2011-01-12 Omair Majid + + * netx/javax/jnlp/UnavailableServiceException.java: Remove unused + imports. + * netx/net/sourceforge/jnlp/AppletDesc.java: Likewise. + * netx/net/sourceforge/jnlp/ApplicationDesc.java: Likewise. + * netx/net/sourceforge/jnlp/ComponentDesc.java: Likewise. + * netx/net/sourceforge/jnlp/DefaultLaunchHandler.java: Likewise. + * netx/net/sourceforge/jnlp/IconDesc.java: Likewise. + * netx/net/sourceforge/jnlp/InformationDesc.java: Likewise. + * netx/net/sourceforge/jnlp/InstallerDesc.java: Likewise. + * netx/net/sourceforge/jnlp/JARDesc.java: Likewise. + * netx/net/sourceforge/jnlp/JREDesc.java: Likewise. + * netx/net/sourceforge/jnlp/Launcher.java: Likewise. + * netx/net/sourceforge/jnlp/PackageDesc.java: Likewise. + * netx/net/sourceforge/jnlp/ParseException.java: Likewise. + * netx/net/sourceforge/jnlp/PluginBridge.java: Likewise. + * netx/net/sourceforge/jnlp/PropertyDesc.java: Likewise. + * netx/net/sourceforge/jnlp/ResourcesDesc.java: Likewise. + * netx/net/sourceforge/jnlp/Version.java: Likewise. + * netx/net/sourceforge/jnlp/cache/CacheEntry.java: Likewise. + * netx/net/sourceforge/jnlp/cache/CacheUtil.java: Likewise. + * netx/net/sourceforge/jnlp/cache/DefaultDownloadIndicator.java: + Likewise. + * netx/net/sourceforge/jnlp/cache/DownloadIndicator.java: Likewise. + * netx/net/sourceforge/jnlp/cache/UpdatePolicy.java: Likewise. + * netx/net/sourceforge/jnlp/controlpanel + /AdvancedProxySettingsDialog.java: Likewise. + * netx/net/sourceforge/jnlp/controlpanel + /AdvancedProxySettingsPane.java: Likewise. + * netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java: + Likewise. + * netx/net/sourceforge/jnlp/controlpanel + /TemporaryInternetFilesPanel.java: Likewise. + * netx/net/sourceforge/jnlp/event/ApplicationEvent.java: Likewise. + * netx/net/sourceforge/jnlp/event/DownloadEvent.java: Likewise. + * netx/net/sourceforge/jnlp/runtime/AppThreadGroup.java: Likewise. + * netx/net/sourceforge/jnlp/runtime/AppletAudioClip.java: Likewise. + * netx/net/sourceforge/jnlp/runtime/AppletInstance.java: Likewise. + * netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java: + Likewise. + * netx/net/sourceforge/jnlp/runtime/Boot13.java: Likewise. + * netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java: Likewise. + * netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: + Likewise. + * netx/net/sourceforge/jnlp/security/CertsInfoPane.java: Likewise. + * netx/net/sourceforge/jnlp/security/SecurityUtil.java: Likewise. + * netx/net/sourceforge/jnlp/services/XBasicService.java: Likewise. + * netx/net/sourceforge/jnlp/services/XDownloadService.java: Likewise. + * netx/net/sourceforge/jnlp/services/XExtensionInstallerService.java: + Likewise. + * netx/net/sourceforge/jnlp/services/XFileContents.java: Likewise. + * netx/net/sourceforge/jnlp/services/XFileOpenService.java: Likewise. + * netx/net/sourceforge/jnlp/services/XFileSaveService.java: Likewise. + * netx/net/sourceforge/jnlp/services/XPersistenceService.java: + Likewise. + * netx/net/sourceforge/jnlp/util/PropertiesFile.java: Likewise. + * netx/net/sourceforge/jnlp/util/Reflect.java: Likewise. + 2011-01-04 Omair Majid * netx/net/sourceforge/jnlp/security/KeyStores.java diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/AppletDesc.java --- a/netx/net/sourceforge/jnlp/AppletDesc.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/AppletDesc.java Wed Jan 12 12:50:13 2011 -0500 @@ -16,7 +16,6 @@ package net.sourceforge.jnlp; -import java.io.*; import java.net.*; import java.util.*; diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/ApplicationDesc.java --- a/netx/net/sourceforge/jnlp/ApplicationDesc.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/ApplicationDesc.java Wed Jan 12 12:50:13 2011 -0500 @@ -16,8 +16,6 @@ package net.sourceforge.jnlp; -import java.io.*; -import java.net.*; import java.util.*; /** diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/ComponentDesc.java --- a/netx/net/sourceforge/jnlp/ComponentDesc.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/ComponentDesc.java Wed Jan 12 12:50:13 2011 -0500 @@ -16,10 +16,6 @@ package net.sourceforge.jnlp; -import java.io.*; -import java.net.*; -import java.util.*; - /** * The component-desc element. * diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/DefaultLaunchHandler.java --- a/netx/net/sourceforge/jnlp/DefaultLaunchHandler.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/DefaultLaunchHandler.java Wed Jan 12 12:50:13 2011 -0500 @@ -17,11 +17,6 @@ package net.sourceforge.jnlp; package net.sourceforge.jnlp; import net.sourceforge.jnlp.runtime.*; -import net.sourceforge.jnlp.util.*; - -import java.awt.*; -import java.util.*; -import javax.swing.*; /** * This default implementation shows prints the exception to diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/IconDesc.java --- a/netx/net/sourceforge/jnlp/IconDesc.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/IconDesc.java Wed Jan 12 12:50:13 2011 -0500 @@ -16,9 +16,7 @@ package net.sourceforge.jnlp; -import java.io.*; import java.net.*; -import java.util.*; /** * The icon element. diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/InformationDesc.java --- a/netx/net/sourceforge/jnlp/InformationDesc.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/InformationDesc.java Wed Jan 12 12:50:13 2011 -0500 @@ -17,8 +17,6 @@ package net.sourceforge.jnlp; -import java.io.*; -import java.awt.Dimension; import java.net.*; import java.util.*; diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/InstallerDesc.java --- a/netx/net/sourceforge/jnlp/InstallerDesc.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/InstallerDesc.java Wed Jan 12 12:50:13 2011 -0500 @@ -15,10 +15,6 @@ // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. package net.sourceforge.jnlp; - -import java.io.*; -import java.net.*; -import java.util.*; /** * The installer-desc element. diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/JARDesc.java --- a/netx/net/sourceforge/jnlp/JARDesc.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/JARDesc.java Wed Jan 12 12:50:13 2011 -0500 @@ -16,9 +16,7 @@ package net.sourceforge.jnlp; -import java.io.*; -import java.net.*; -import java.util.*; +import java.net.URL; /** * The JAR element. diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/JNLPFile.java --- a/netx/net/sourceforge/jnlp/JNLPFile.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/JNLPFile.java Wed Jan 12 12:50:13 2011 -0500 @@ -80,7 +80,7 @@ public class JNLPFile { protected Version specVersion; /** information */ - protected List info; + protected List info; protected UpdateDesc update; @@ -326,7 +326,7 @@ public class JNLPFile { List result = new ArrayList(); for (int i = 0; i < info.size(); i++) { - InformationDesc infoDesc = (InformationDesc) info.get(i); + InformationDesc infoDesc = info.get(i); if (localMatches(locale, infoDesc.getLocales())) if (localMatches(locale, infoDesc.getLocales())) diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/JREDesc.java --- a/netx/net/sourceforge/jnlp/JREDesc.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/JREDesc.java Wed Jan 12 12:50:13 2011 -0500 @@ -18,7 +18,6 @@ package net.sourceforge.jnlp; import static net.sourceforge.jnlp.runtime.Translator.R; -import java.io.*; import java.net.*; import java.util.*; diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/Launcher.java --- a/netx/net/sourceforge/jnlp/Launcher.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/Launcher.java Wed Jan 12 12:50:13 2011 -0500 @@ -24,8 +24,6 @@ import java.io.FileInputStream; import java.io.FileInputStream; import java.io.FileOutputStream; import java.io.IOException; -import java.lang.management.ManagementFactory; -import java.lang.management.ThreadMXBean; import java.lang.reflect.Method; import java.net.InetAddress; import java.net.URL; @@ -48,7 +46,6 @@ import net.sourceforge.jnlp.services.Ins import net.sourceforge.jnlp.services.InstanceExistsException; import net.sourceforge.jnlp.services.ServiceUtil; import net.sourceforge.jnlp.util.FileUtils; -import net.sourceforge.jnlp.util.Reflect; import javax.swing.SwingUtilities; import javax.swing.text.html.parser.ParserDelegator; diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/PackageDesc.java --- a/netx/net/sourceforge/jnlp/PackageDesc.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/PackageDesc.java Wed Jan 12 12:50:13 2011 -0500 @@ -15,10 +15,6 @@ // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. package net.sourceforge.jnlp; - -import java.io.*; -import java.net.*; -import java.util.*; /** * The package element. diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/ParseException.java --- a/netx/net/sourceforge/jnlp/ParseException.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/ParseException.java Wed Jan 12 12:50:13 2011 -0500 @@ -17,8 +17,6 @@ package net.sourceforge.jnlp; package net.sourceforge.jnlp; import java.io.*; -import java.net.*; -import java.util.*; /** * Thrown to indicate that an error has occurred while parsing a diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/PluginBridge.java --- a/netx/net/sourceforge/jnlp/PluginBridge.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/PluginBridge.java Wed Jan 12 12:50:13 2011 -0500 @@ -26,7 +26,6 @@ import java.net.MalformedURLException; import java.net.MalformedURLException; import java.util.Calendar; import java.util.Hashtable; -import java.util.Iterator; import java.util.Locale; import java.util.List; import java.util.ArrayList; diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/PropertyDesc.java --- a/netx/net/sourceforge/jnlp/PropertyDesc.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/PropertyDesc.java Wed Jan 12 12:50:13 2011 -0500 @@ -15,10 +15,6 @@ // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. package net.sourceforge.jnlp; - -import java.io.*; -import java.net.*; -import java.util.*; /** * The property element. diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/ResourcesDesc.java --- a/netx/net/sourceforge/jnlp/ResourcesDesc.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/ResourcesDesc.java Wed Jan 12 12:50:13 2011 -0500 @@ -16,9 +16,6 @@ package net.sourceforge.jnlp; -import java.io.*; -import java.awt.Dimension; -import java.net.*; import java.util.*; /** diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/Version.java --- a/netx/net/sourceforge/jnlp/Version.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/Version.java Wed Jan 12 12:50:13 2011 -0500 @@ -16,8 +16,6 @@ package net.sourceforge.jnlp; -import java.io.*; -import java.net.*; import java.util.*; /** diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/cache/CacheEntry.java --- a/netx/net/sourceforge/jnlp/cache/CacheEntry.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/cache/CacheEntry.java Wed Jan 12 12:50:13 2011 -0500 @@ -20,10 +20,6 @@ import static net.sourceforge.jnlp.runti import java.io.*; import java.net.*; -import java.util.*; -import java.lang.reflect.*; -import java.security.*; -import javax.jnlp.*; import net.sourceforge.jnlp.*; import net.sourceforge.jnlp.runtime.*; diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/cache/CacheUtil.java --- a/netx/net/sourceforge/jnlp/cache/CacheUtil.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/cache/CacheUtil.java Wed Jan 12 12:50:13 2011 -0500 @@ -22,7 +22,6 @@ import java.net.*; import java.net.*; import java.nio.channels.FileChannel; import java.util.*; -import java.lang.reflect.*; import java.security.*; import javax.jnlp.*; diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/cache/DefaultDownloadIndicator.java --- a/netx/net/sourceforge/jnlp/cache/DefaultDownloadIndicator.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/cache/DefaultDownloadIndicator.java Wed Jan 12 12:50:13 2011 -0500 @@ -27,7 +27,6 @@ import javax.swing.Timer; import javax.swing.Timer; import javax.jnlp.*; -import net.sourceforge.jnlp.*; import net.sourceforge.jnlp.runtime.*; /** diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/cache/DownloadIndicator.java --- a/netx/net/sourceforge/jnlp/cache/DownloadIndicator.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/cache/DownloadIndicator.java Wed Jan 12 12:50:13 2011 -0500 @@ -16,16 +16,9 @@ package net.sourceforge.jnlp.cache; -import java.awt.*; -import java.awt.event.*; import java.net.*; -import java.util.*; -import java.util.List; -import javax.swing.*; -import javax.swing.Timer; import javax.jnlp.*; -import net.sourceforge.jnlp.*; import net.sourceforge.jnlp.runtime.*; /** diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/cache/UpdatePolicy.java --- a/netx/net/sourceforge/jnlp/cache/UpdatePolicy.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/cache/UpdatePolicy.java Wed Jan 12 12:50:13 2011 -0500 @@ -15,17 +15,6 @@ // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. package net.sourceforge.jnlp.cache; - -import java.io.*; -import java.net.*; -import java.util.*; -import java.lang.reflect.*; -import java.security.*; -import javax.jnlp.*; - -import net.sourceforge.jnlp.*; -import net.sourceforge.jnlp.runtime.*; -import net.sourceforge.jnlp.util.*; /** * A policy that determines when a resource should be checked for diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java --- a/netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java Wed Jan 12 12:50:13 2011 -0500 @@ -28,8 +28,6 @@ import java.awt.event.WindowEvent; import java.awt.event.WindowEvent; import javax.swing.JDialog; -import javax.swing.SwingUtilities; -import javax.swing.UIManager; import net.sourceforge.jnlp.config.DeploymentConfiguration; import net.sourceforge.jnlp.runtime.Translator; diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsPane.java --- a/netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsPane.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsPane.java Wed Jan 12 12:50:13 2011 -0500 @@ -27,8 +27,6 @@ import java.awt.event.ActionListener; import java.awt.event.ActionListener; import java.awt.event.ItemEvent; import java.awt.event.ItemListener; -import java.awt.event.KeyAdapter; -import java.awt.event.KeyEvent; import java.util.ArrayList; import java.util.List; diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java --- a/netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java Wed Jan 12 12:50:13 2011 -0500 @@ -53,6 +53,7 @@ import javax.swing.event.ListSelectionLi import net.sourceforge.jnlp.config.DeploymentConfiguration; import net.sourceforge.jnlp.runtime.Translator; +import net.sourceforge.jnlp.security.KeyStores; import net.sourceforge.jnlp.security.viewer.CertificatePane; /** @@ -354,6 +355,14 @@ public class ControlPanel extends JFrame e.printStackTrace(); } + try { + UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName()); + } catch (Exception e) { + // ignore; not a big deal + } + + KeyStores.setConfiguration(config); + SwingUtilities.invokeLater(new Runnable() { @Override public void run() { diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java --- a/netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java Wed Jan 12 12:50:13 2011 -0500 @@ -29,15 +29,12 @@ import java.awt.event.ActionListener; import java.awt.event.ActionListener; import java.awt.event.ItemEvent; import java.awt.event.ItemListener; -import java.awt.event.KeyAdapter; -import java.awt.event.KeyEvent; import java.util.ArrayList; import javax.swing.Box; import javax.swing.ButtonGroup; import javax.swing.JButton; import javax.swing.JCheckBox; -import javax.swing.JComponent; import javax.swing.JLabel; import javax.swing.JPanel; import javax.swing.JRadioButton; diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java --- a/netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/controlpanel/TemporaryInternetFilesPanel.java Wed Jan 12 12:50:13 2011 -0500 @@ -38,7 +38,6 @@ import javax.swing.JSpinner; import javax.swing.JSpinner; import javax.swing.JTextField; import javax.swing.SpinnerNumberModel; -import javax.swing.SwingUtilities; import javax.swing.event.ChangeEvent; import javax.swing.event.ChangeListener; diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/event/ApplicationEvent.java --- a/netx/net/sourceforge/jnlp/event/ApplicationEvent.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/event/ApplicationEvent.java Wed Jan 12 12:50:13 2011 -0500 @@ -18,7 +18,6 @@ package net.sourceforge.jnlp.event; import java.util.*; -import net.sourceforge.jnlp.*; import net.sourceforge.jnlp.runtime.*; /** diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/event/DownloadEvent.java --- a/netx/net/sourceforge/jnlp/event/DownloadEvent.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/event/DownloadEvent.java Wed Jan 12 12:50:13 2011 -0500 @@ -19,9 +19,7 @@ import java.net.*; import java.net.*; import java.util.*; -import net.sourceforge.jnlp.*; import net.sourceforge.jnlp.cache.*; -import net.sourceforge.jnlp.runtime.*; /** * This event is sent during the launch of an diff -r dc02a605f905 -r 4e84e06b54e9 netx/net/sourceforge/jnlp/runtime/AppThreadGroup.java --- a/netx/net/sourceforge/jnlp/runtime/AppThreadGroup.java Fri Jan 07 08:00:08 2011 -0500 +++ b/netx/net/sourceforge/jnlp/runtime/AppThreadGroup.java Wed Jan 12 12:50:13 2011 -0500 From omajid at redhat.com Wed Jan 12 09:52:19 2011 From: omajid at redhat.com (Omair Majid) Date: Wed, 12 Jan 2011 12:52:19 -0500 Subject: /hg/icedtea-web: remove control panel's dependency on JNLPRuntim... In-Reply-To: <415919376.76596.1294850122215.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> References: <415919376.76596.1294850122215.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Message-ID: <4D2DEA53.3030206@redhat.com> On 01/12/2011 11:35 AM, Andrew Su wrote: > >>> I was trying to use control panel to set some values, but noticed >>> the look and feel was not how it should be and also I get a few >>> exceptions from CertificatePane. >>> > > This patch looks fine to me and also fixes the issues mentioned. > I am for not using JNLPRuntime.initialize() as well. > Thanks for the quick fix! > Thanks for looking over the patch. I have pushed it to HEAD. Cheers, Omair From omajid at redhat.com Wed Jan 12 09:53:38 2011 From: omajid at redhat.com (Omair Majid) Date: Wed, 12 Jan 2011 12:53:38 -0500 Subject: [icedtea-web] RFC: remove unused imports in netx code In-Reply-To: <20110111144230.GD28602@rivendell.middle-earth.co.uk> References: <4D2C6556.9050103@redhat.com> <20110111144230.GD28602@rivendell.middle-earth.co.uk> Message-ID: <4D2DEAA2.4080009@redhat.com> On 01/11/2011 09:42 AM, Dr Andrew John Hughes wrote: > On 09:12 Tue 11 Jan , Omair Majid wrote: >> The attached patch removes unused imports in Netx code. >> >> Ok to commit? >> >> ChangeLog >> 2011-01-11 Omair Majid >> * netx/javax/jnlp/UnavailableServiceException.java: Remove unused >> imports. >> * netx/net/sourceforge/jnlp/AppletDesc.java: Likewise. >> * netx/net/sourceforge/jnlp/ApplicationDesc.java: Likewise. >> * netx/net/sourceforge/jnlp/ComponentDesc.java: Likewise. >> * netx/net/sourceforge/jnlp/DefaultLaunchHandler.java: Likewise. >> * netx/net/sourceforge/jnlp/IconDesc.java: Likewise. >> * netx/net/sourceforge/jnlp/InformationDesc.java: Likewise. >> * netx/net/sourceforge/jnlp/InstallerDesc.java: Likewise. >> * netx/net/sourceforge/jnlp/JARDesc.java: Likewise. >> * netx/net/sourceforge/jnlp/JREDesc.java: Likewise. >> * netx/net/sourceforge/jnlp/Launcher.java: Likewise. >> * netx/net/sourceforge/jnlp/PackageDesc.java: Likewise. >> * netx/net/sourceforge/jnlp/ParseException.java: Likewise. >> * netx/net/sourceforge/jnlp/PluginBridge.java: Likewise. >> * netx/net/sourceforge/jnlp/PropertyDesc.java: Likewise. >> * netx/net/sourceforge/jnlp/ResourcesDesc.java: Likewise. >> * netx/net/sourceforge/jnlp/Version.java: Likewise. >> * netx/net/sourceforge/jnlp/cache/CacheEntry.java: Likewise. >> * netx/net/sourceforge/jnlp/cache/CacheUtil.java: Likewise. >> * netx/net/sourceforge/jnlp/cache/DefaultDownloadIndicator.java: >> Likewise. >> * netx/net/sourceforge/jnlp/cache/DownloadIndicator.java: Likewise. >> * netx/net/sourceforge/jnlp/cache/UpdatePolicy.java: Likewise. >> * netx/net/sourceforge/jnlp/controlpanel >> /AdvancedProxySettingsDialog.java: Likewise. >> * netx/net/sourceforge/jnlp/controlpanel >> /AdvancedProxySettingsPane.java: Likewise. >> * netx/net/sourceforge/jnlp/controlpanel/NetworkSettingsPanel.java: >> Likewise. >> * netx/net/sourceforge/jnlp/controlpanel >> /TemporaryInternetFilesPanel.java: Likewise. >> * netx/net/sourceforge/jnlp/event/ApplicationEvent.java: Likewise. >> * netx/net/sourceforge/jnlp/event/DownloadEvent.java: Likewise. >> * netx/net/sourceforge/jnlp/runtime/AppThreadGroup.java: Likewise. >> * netx/net/sourceforge/jnlp/runtime/AppletAudioClip.java: Likewise. >> * netx/net/sourceforge/jnlp/runtime/AppletInstance.java: Likewise. >> * netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java: >> Likewise. >> * netx/net/sourceforge/jnlp/runtime/Boot13.java: Likewise. >> * netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java: Likewise. >> * netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: >> Likewise. >> * netx/net/sourceforge/jnlp/security/CertsInfoPane.java: Likewise. >> * netx/net/sourceforge/jnlp/security/SecurityUtil.java: Likewise. >> * netx/net/sourceforge/jnlp/services/XBasicService.java: Likewise. >> * netx/net/sourceforge/jnlp/services/XDownloadService.java: Likewise. >> * netx/net/sourceforge/jnlp/services/XExtensionInstallerService.java: >> Likewise. >> * netx/net/sourceforge/jnlp/services/XFileContents.java: Likewise. >> * netx/net/sourceforge/jnlp/services/XFileOpenService.java: Likewise. >> * netx/net/sourceforge/jnlp/services/XFileSaveService.java: Likewise. >> * netx/net/sourceforge/jnlp/services/XPersistenceService.java: >> Likewise. >> * netx/net/sourceforge/jnlp/util/PropertiesFile.java: Likewise. >> * netx/net/sourceforge/jnlp/util/Reflect.java: Likewise. >> > Fine by me, if it still builds. > Thanks for looking over the patch. Pushed to HEAD. Cheers, Omair From omajid at redhat.com Wed Jan 12 09:56:05 2011 From: omajid at redhat.com (Omair Majid) Date: Wed, 12 Jan 2011 12:56:05 -0500 Subject: [icedtea-web] RFC: add missing generic type in JNLPFile In-Reply-To: <20110111170724.GH28602@rivendell.middle-earth.co.uk> References: <4D2C87EB.1000107@redhat.com> <20110111170724.GH28602@rivendell.middle-earth.co.uk> Message-ID: <4D2DEB35.2060302@redhat.com> On 01/11/2011 12:07 PM, Dr Andrew John Hughes wrote: > On 11:40 Tue 11 Jan , Omair Majid wrote: >> Hi, >> >> The attached patch adds a generic type to 'info' in JNLPFile. >> >> Ok to commit? >> >> ChangeLog: >> 2011-01-11 Omair Majid >> >> * netx/net/sourceforge/jnlp/JNLPFile: Add missing generic type to >> info. >> (getInformation): Remove redundant cast. >> >> >> Cheers, >> Omair > > Looks good. javac clearly misses these; is this with ecj? > Thanks for the review. I have pushed this to HEAD. Cheers, Omair From bugzilla-daemon at icedtea.classpath.org Wed Jan 12 12:31:33 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 12 Jan 2011 20:31:33 +0000 Subject: [Bug 615] New: Compiler exception while compiling netbeans 6.9.1 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=615 Summary: Compiler exception while compiling netbeans 6.9.1 Product: IcedTea Version: 6-1.9.2 Platform: all OS/Version: Linux Status: NEW Severity: normal Priority: P2 Component: IcedTea6 AssignedTo: unassigned at icedtea.classpath.org ReportedBy: fordfrog at gentoo.org i tried to compile netbeans using sources from http://download.netbeans.org/netbeans/6.9.1/final/zip/netbeans-6.9.1-201007282301-src.zip but i get this error: compile: [mkdir] Created dir: /var/tmp/portage/tmp/cnd.model.services/build/classes [nb-javac] Compiling 43 source files to /var/tmp/portage/tmp/cnd.model.services/build/classes [repeat] warning: [path] bad path element "/var/tmp/portage/tmp/nbbuild/netbeans/ide/modules/org-netbeans-modules-utilities.jar": no such file or directory [repeat] warning: [path] bad path element "/var/tmp/portage/tmp/nbbuild/netbeans/platform/lib/boot.jar": no such file or directory [repeat] warning: [path] bad path element "/var/tmp/portage/tmp/nbbuild/netbeans/platform/modules/org-openide-io.jar": no such file or directory [repeat] An exception has occurred in the compiler (1.6.0_20). Please file a bug at the Java Developer Connection (http://java.sun.com/webapps/bugreport) after checking the Bug Parade for duplicates. Include your program and the following diagnostic in your report. Thank you. [repeat] com.sun.tools.javac.code.Symbol$CompletionFailure: class file for org.netbeans.api.lexer.TokenId not found [nbmerge] Failed to build target: all-cnd.model.services BUILD FAILED /var/tmp/portage/tmp/nbbuild/build.xml:394: The following error occurred while executing this line: /var/tmp/portage/tmp/nbbuild/build.xml:389: The following error occurred while executing this line: /var/tmp/portage/tmp/nbbuild/build.xml:436: The following error occurred while executing this line: /var/tmp/portage/tmp/nbbuild/templates/common.xml:202: Compile failed; see the compiler error output for details. here is my icedtea version: $ java -version java version "1.6.0_20" OpenJDK Runtime Environment (IcedTea6 1.9.3) (Gentoo build 1.6.0_20-b20) OpenJDK 64-Bit Server VM (build 19.0-b09, mixed mode) this issue seems to be reproducable as i got reports from other people on gentoo that they cannot compile this version of netbeans. just a minor note for compilation of netbeans, you will most probably have to disable ruby cluster as there is some error with one file download. so the steps might be these: 1) download http://download.netbeans.org/netbeans/6.9.1/final/zip/netbeans-6.9.1-201007282301-src.zip 2) unzip it to new folder and cd to the folder 3) edit nbbuild/cluster.properties and remove from variable clusters.config.full.list line with nb.cluster.ruby 4) run: ant -f nbbuild/build.xml build-nozip alternatively, you can probably just try to build cnd cluster but i did not try that. -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Wed Jan 12 13:31:17 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 12 Jan 2011 21:31:17 +0000 Subject: [Bug 615] Compiler exception while compiling netbeans 6.9.1 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=615 gnu_andrew at member.fsf.org changed: What |Removed |Added ---------------------------------------------------------------------------- Platform|all |x86_64 -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Wed Jan 12 13:55:00 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 12 Jan 2011 21:55:00 +0000 Subject: [Bug 611] Minecraft Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=611 gnu_andrew at member.fsf.org changed: What |Removed |Added ---------------------------------------------------------------------------- Component|VisualVM |IcedTea6 Product|VisualVM Harness |IcedTea -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Wed Jan 12 13:55:35 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 12 Jan 2011 21:55:35 +0000 Subject: [Bug 611] Minecraft Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=611 gnu_andrew at member.fsf.org changed: What |Removed |Added ---------------------------------------------------------------------------- Severity|blocker |normal Platform|all |x86 Target Milestone|--- |6-1.8.3 -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Wed Jan 12 13:56:04 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 12 Jan 2011 21:56:04 +0000 Subject: [Bug 611] Minecraft Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=611 ------- Comment #1 from gnu_andrew at member.fsf.org 2011-01-12 21:56 ------- Could you try with 1.9.3? -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Wed Jan 12 16:53:08 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 13 Jan 2011 00:53:08 +0000 Subject: [Bug 615] Compiler exception while compiling netbeans 6.9.1 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=615 ------- Comment #1 from fordfrog at gentoo.org 2011-01-13 00:53 ------- just an additional info, it compiles fine with sun-jdk. also, netbeans-6.9 fails to compile to with icedtea. here is the gentoo bug about this issue: https://bugs.gentoo.org/show_bug.cgi?id=342647 -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From andrew at icedtea.classpath.org Thu Jan 13 01:57:50 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Thu, 13 Jan 2011 09:57:50 +0000 Subject: /hg/icedtea6-hg: Remove upstreamed patch 6980392 Message-ID: changeset 8fbbbe4af6bc in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=8fbbbe4af6bc author: Andrew John Hughes date: Thu Jan 13 09:57:38 2011 +0000 Remove upstreamed patch 6980392 2011-01-10 Andrew John Hughes * patches/openjdk/6980392-fix_test6581734.patch: Remove upstreamed patch. * Makefile.am: Drop above patch. diffstat: 3 files changed, 6 insertions(+), 22 deletions(-) ChangeLog | 6 ++++++ Makefile.am | 1 - patches/openjdk/6980392-fix_test6581734.patch | 21 --------------------- diffs (49 lines): diff -r b645d7e86c18 -r 8fbbbe4af6bc ChangeLog --- a/ChangeLog Mon Jan 10 23:47:02 2011 +0000 +++ b/ChangeLog Thu Jan 13 09:57:38 2011 +0000 @@ -1,3 +1,9 @@ 2011-01-10 Andrew John Hughes + + * patches/openjdk/6980392-fix_test6581734.patch: + Remove upstreamed patch. + * Makefile.am: Drop above patch. + 2011-01-10 Andrew John Hughes * Makefile.am: diff -r b645d7e86c18 -r 8fbbbe4af6bc Makefile.am --- a/Makefile.am Mon Jan 10 23:47:02 2011 +0000 +++ b/Makefile.am Thu Jan 13 09:57:38 2011 +0000 @@ -272,7 +272,6 @@ ICEDTEA_PATCHES = \ patches/rendering-engine-tests.patch \ patches/openjdk/6800846-printing-quality.patch \ patches/661505-jpeg.patch \ - patches/openjdk/6980392-fix_test6581734.patch \ patches/6703377-freetypescaler.patch \ patches/ia64-fix.patch diff -r b645d7e86c18 -r 8fbbbe4af6bc patches/openjdk/6980392-fix_test6581734.patch --- a/patches/openjdk/6980392-fix_test6581734.patch Mon Jan 10 23:47:02 2011 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,21 +0,0 @@ -# HG changeset patch -# User kevinw -# Date 1282924624 -3600 -# Node ID 21c29458b334f7b1f05a185442ab37ab8de1ea7b -# Parent 8e5955ddf8e491a54b7e9446424fdee02e6950c8 -6980392: TEST_BUG: gc/6581734/Test6581734.java has typo -Summary: simple correction in testcase -Reviewed-by: mchung - -diff -r 8e5955ddf8e4 -r 21c29458b334 test/gc/6581734/Test6581734.java ---- openjdk.old/hotspot/test/gc/6581734/Test6581734_.java 2010-10-08 22:29:24.000000000 +0200 -+++ openjdk/hotspot/test/gc/6581734/Test6581734.java 2010-11-11 15:47:15.000000000 +0100 -@@ -121,7 +121,7 @@ - } - - if (collectorsWithTime http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=615 ------- Comment #2 from aph at redhat.com 2011-01-13 10:06 ------- I can confirm that this is a regression. OK with java-1.6.0-openjdk-1.6.0.0-41.1.8.2.fc12.x86_64 Fail with java-1.6.0-openjdk-1.6.0.0-49.1.9.3.fc14.x86_64 -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Thu Jan 13 02:41:31 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 13 Jan 2011 10:41:31 +0000 Subject: [Bug 615] Compiler exception while compiling netbeans 6.9.1 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=615 ------- Comment #3 from mark at klomp.org 2011-01-13 10:41 ------- We probably should take a look at this giant patch: http://hg.openjdk.java.net/jdk6/jdk6/langtools/rev/5c2858bccb3f Sadly those patches were all bundled in one commit making it somewhat hard to see them independently. It is only a hunch though, I didn't actually try anything. This was added after jdk6-b20, so probably the easiest to check if this helps is to try against icedtea6-hg. -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Thu Jan 13 03:30:51 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 13 Jan 2011 11:30:51 +0000 Subject: [Bug 615] Compiler exception while compiling netbeans 6.9.1 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=615 aph at redhat.com changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Thu Jan 13 03:31:35 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Thu, 13 Jan 2011 11:31:35 +0000 Subject: [Bug 615] Compiler exception while compiling netbeans 6.9.1 Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=615 aph at redhat.com changed: What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|unassigned at icedtea.classpath|aph at redhat.com |.org | Status|ASSIGNED |NEW -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. You are the assignee for the bug, or are watching the assignee. From schumi.han at gmail.com Thu Jan 13 06:12:28 2011 From: schumi.han at gmail.com (Zhu Han) Date: Thu, 13 Jan 2011 22:12:28 +0800 Subject: "-client" option In-Reply-To: <4D2D9711.9050206@redhat.com> References: <4D2B3147.20100@redhat.com> <4D2C3787.60702@redhat.com> <4D2D9711.9050206@redhat.com> Message-ID: On Wed, Jan 12, 2011 at 7:57 PM, Andrew Haley wrote: > On 01/12/2011 10:08 AM, Zhu Han wrote: > >> On Tue, Jan 11, 2011 at 6:57 PM, Andrew Haley wrote: >> >> 640MB is just the pre-allocated address space size, half of them are >>> >>>> anonymous mmap region. RSS is just around 48MB. I want to control the >>>> total size of address space because the JVM process spawns several >>>> sub-process to execute some scripts provided by OS occasionally. I know >>>> this >>>> is not portable, but seems like there is no better way to open a URL in >>>> standalone browser from a java application. >>>> >>>> >>> But these regions are mapped as MAP_NORESERVE, so it shouldn't matter. >>> >>> >>> This may be failed because of lack of swap space to backup address >>> space. >>> >>>> >>>> >>> OK, so now I understand what the real problem is. >>> >>> I'm assuming Linux. >>> >>> I don't understand why this is happening. I wonder if you have some >>> odd setting. >>> >>> What is /proc/sys/vm/overcommit_memory? /proc/sys/vm/overcommit_ratio? >>> >>> /proc/meminfo ? >>> >>> >> Because it will be deployed as a desktop application. So I have no control >> over settings of /proc/sys/vm/overcommit_memory. And some distributions >> set >> it as 0, at least it is 0 on my Ubuntu 10.04. >> > > 0 should be fine. > > > The failure can be observed only on resource limited environment. >> >> I have written a small script and communicate with JVM through local >> loopback TCP connection. This is a possible workaround. But, it is quite >> ugly... >> > > I've had a look, and the big mappings seem to be > MAP_PRIVATE|MAP_NORESERVE per-thread regions allocated for the malloc > heap by glibc. Every thread has its own heap, and these are > pre-allocated in 64M chunks. A bunch of special-purpose threads are > started by the VM, so you have a multiple of these 64M mappings. So, > I don't think there's much you can do about it. > > But in any case, MAP_NORESERVE doesn't reserve memory, so you > shouldn't start getting an OOM condition until you really run out of > memory, not just address space. > That's very helpful. I really appreciate your response. One more question, please :-) Does this behavior(MAP_NORESERVE) consistent on other *NIX platform. For example, OSX or freebsd? > Andrew. > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110113/c0ffab3a/attachment.html From aph at redhat.com Thu Jan 13 06:40:24 2011 From: aph at redhat.com (Andrew Haley) Date: Thu, 13 Jan 2011 14:40:24 +0000 Subject: "-client" option In-Reply-To: References: <4D2B3147.20100@redhat.com> <4D2C3787.60702@redhat.com> <4D2D9711.9050206@redhat.com> Message-ID: <4D2F0ED8.6040902@redhat.com> On 01/13/2011 02:12 PM, Zhu Han wrote: > On Wed, Jan 12, 2011 at 7:57 PM, Andrew Haley wrote: >> I've had a look, and the big mappings seem to be >> MAP_PRIVATE|MAP_NORESERVE per-thread regions allocated for the malloc >> heap by glibc. Every thread has its own heap, and these are >> pre-allocated in 64M chunks. A bunch of special-purpose threads are >> started by the VM, so you have a multiple of these 64M mappings. So, >> I don't think there's much you can do about it. >> >> But in any case, MAP_NORESERVE doesn't reserve memory, so you >> shouldn't start getting an OOM condition until you really run out of >> memory, not just address space. > > That's very helpful. I really appreciate your response. > > One more question, please :-) > > Does this behavior(MAP_NORESERVE) consistent on other *NIX platform. For > example, OSX or freebsd? It's not an uncommon thing to do, but I couldn't speak about any particular OS version. Andrew. From omajid at redhat.com Thu Jan 13 10:31:13 2011 From: omajid at redhat.com (Omair Majid) Date: Thu, 13 Jan 2011 13:31:13 -0500 Subject: [icedtea-web] RFC: fix comments in ResourcesDesc Message-ID: <4D2F44F1.8010005@redhat.com> Hi, The attached patch fixes a typo in comments in ResourcesDesc. Ok to commit? Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: fix-resourcedesc-javadoc-01.patch Type: text/x-patch Size: 754 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110113/ee5f67c1/fix-resourcedesc-javadoc-01.patch From asu at redhat.com Thu Jan 13 15:19:13 2011 From: asu at redhat.com (Andrew Su) Date: Thu, 13 Jan 2011 18:19:13 -0500 (EST) Subject: [RFC][IcedTea-Web]: Removing dead unused commented code In-Reply-To: <1765352810.5658.1294952590109.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Message-ID: <724777475.7604.1294960753067.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Hello, This patch is an attempt to remove dead, unused or commented code from the plugin directory in icedtea-web. (I have provided the patch for each file separately for easier reading.) Some comments though.. General Note: Changed the copyright to be 2011 for all the modified files. These are the methods that will be removed with the patch (unused private methods) PluginMessageConsumer.java:getReference(String[]) PluginMessageConsumer.java:isInInit(Integer) PluginMessageConsumer.java:dumpWorkerStatus() PluginAppletViewer.java:makeReader(InputStream) PluginMessageConsumer.java:getReference(String[]) PluginMessageConsumer.java:isInInit(Integer) PluginMessageConsumer.java:dumpWorkerStatus() In the following method, will we be needing this block of commented out conditions in the future? PluginAppletSecurityContext.java:getAccessControlContext(String[], String) I have tried building it and that succeeds. Tested running some simple applets and those seem to work as well. Questions comments concerns? Regards, Andrew -------------- next part -------------- A non-text attachment was scrubbed... Name: diff_patch.tar Type: application/x-tar Size: 51200 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110113/ed463bdc/diff_patch.tar -------------- next part -------------- A non-text attachment was scrubbed... Name: 20110113_remove_unused_imports_and_private_v2.patch Type: text/x-patch Size: 33370 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110113/ed463bdc/20110113_remove_unused_imports_and_private_v2.patch From ahughes at redhat.com Thu Jan 13 15:31:24 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Thu, 13 Jan 2011 23:31:24 +0000 Subject: [RFC][IcedTea-Web]: Removing dead unused commented code In-Reply-To: <724777475.7604.1294960753067.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> References: <1765352810.5658.1294952590109.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <724777475.7604.1294960753067.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Message-ID: <20110113233124.GP4081@rivendell.middle-earth.co.uk> On 18:19 Thu 13 Jan , Andrew Su wrote: > Hello, > > This patch is an attempt to remove dead, unused or commented code from the plugin directory in icedtea-web. > > (I have provided the patch for each file separately for easier reading.) > > Some comments though.. > General Note: > Changed the copyright to be 2011 for all the modified files. > The copyright updates should extend the range, not remove the original. So: > - Copyright (C) 2008 Red Hat > + Copyright (C) 2011 Red Hat becomes - Copyright (C) 2008 Red Hat + Copyright (C) 2008, 2011 Red Hat Also I'm not sure removing code is worth a copyright update. > These are the methods that will be removed with the patch (unused private methods) > PluginMessageConsumer.java:getReference(String[]) > PluginMessageConsumer.java:isInInit(Integer) > PluginMessageConsumer.java:dumpWorkerStatus() > PluginAppletViewer.java:makeReader(InputStream) > PluginMessageConsumer.java:getReference(String[]) > PluginMessageConsumer.java:isInInit(Integer) > PluginMessageConsumer.java:dumpWorkerStatus() > > In the following method, will we be needing this block of commented out conditions in the future? > PluginAppletSecurityContext.java:getAccessControlContext(String[], String) > > > I have tried building it and that succeeds. Tested running some simple applets and those seem to work as well. > > Questions comments concerns? > > Regards, > Andrew > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/GetWindowPluginCallRequest.java > --- a/plugin/icedteanp/java/sun/applet/GetWindowPluginCallRequest.java Wed Jan 12 12:50:13 2011 -0500 > +++ b/plugin/icedteanp/java/sun/applet/GetWindowPluginCallRequest.java Thu Jan 13 18:02:32 2011 -0500 > @@ -1,5 +1,5 @@ > /* GetWindowPluginCallRequest -- represent Java-to-JavaScript requests > - Copyright (C) 2008 Red Hat > + Copyright (C) 2011 Red Hat > > This file is part of IcedTea. > > @@ -37,9 +37,6 @@ > > package sun.applet; > > -import java.security.AccessControlContext; > -import java.security.ProtectionDomain; > - > public class GetWindowPluginCallRequest extends PluginCallRequest { > // FIXME: look into int vs long JavaScript internal values. > long internal; > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/MethodOverloadResolver.java > --- a/plugin/icedteanp/java/sun/applet/MethodOverloadResolver.java Wed Jan 12 12:50:13 2011 -0500 > +++ b/plugin/icedteanp/java/sun/applet/MethodOverloadResolver.java Thu Jan 13 18:02:32 2011 -0500 > @@ -1,5 +1,5 @@ > /* MethodOverloadResolver -- Resolves overloaded methods > - Copyright (C) 2009 Red Hat > + Copyright (C) 2011 Red Hat > > This file is part of IcedTea. > > @@ -175,8 +175,6 @@ > > int lowestCost = Integer.MAX_VALUE; > > - ArrayList paramList = new ArrayList(); > - > for (Method matchingMethod : matchingMethods) { > > int methodCost = 0; > @@ -240,8 +238,6 @@ > > int lowestCost = Integer.MAX_VALUE; > > - ArrayList paramList = new ArrayList(); > - > for (Constructor matchingConstructor : matchingConstructors) { > > int constructorCost = 0; > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginAppletSecurityContext.java > --- a/plugin/icedteanp/java/sun/applet/PluginAppletSecurityContext.java Wed Jan 12 12:50:13 2011 -0500 > +++ b/plugin/icedteanp/java/sun/applet/PluginAppletSecurityContext.java Thu Jan 13 18:02:32 2011 -0500 > @@ -1,5 +1,5 @@ > /* PluginAppletSecurityContext -- execute plugin JNI messages > - Copyright (C) 2008, 2010 Red Hat > + Copyright (C) 2008, 2010, 2011 Red Hat > > This file is part of IcedTea. > > @@ -37,7 +37,6 @@ > > package sun.applet; > > -import java.io.File; > import java.lang.reflect.Array; > import java.lang.reflect.Constructor; > import java.lang.reflect.Field; > @@ -53,14 +52,11 @@ > import java.security.Permissions; > import java.security.PrivilegedAction; > import java.security.ProtectionDomain; > -import java.text.DecimalFormat; > import java.util.ArrayList; > import java.util.Hashtable; > import java.util.List; > import java.util.Map; > > -import javax.swing.text.html.HTMLDocument.HTMLReader.IsindexAction; > - > import net.sourceforge.jnlp.runtime.JNLPRuntime; > import netscape.javascript.JSObjectCreatePermission; > > @@ -144,32 +140,25 @@ > if (elem == null) // end of signature > continue; > > - // System.out.println ("NEXT TYPE: " + elem); > Class primitive = primitiveNameToType(elem); > if (primitive != null) > typeList.add(primitive); > else { > - // System.out.println ("HERE1"); > int dimsize = 0; > int n = elem.indexOf('['); > if (n != -1) { > - // System.out.println ("HERE2"); > String arrayType = elem.substring(0, n); > dimsize++; > n = elem.indexOf('[', n + 1); > - // System.out.println ("HERE2.5"); > while (n != -1) { > dimsize++; > n = elem.indexOf('[', n + 1); > - // System.out.println ("HERE2.8"); > } > int[] dims = new int[dimsize]; > primitive = primitiveNameToType(arrayType); > - // System.out.println ("HERE3"); > if (primitive != null) { > typeList.add(Array.newInstance(primitive, dims) > .getClass()); > - // System.out.println ("HERE4"); > } else > typeList.add(Array.newInstance( > getClass(arrayType, cl), dims).getClass()); > @@ -557,11 +546,6 @@ > // Cast the object to appropriate type before insertion > value = MethodOverloadResolver.getCostAndCastedObject(value, store.getObject(arrayID).getClass().getComponentType())[1]; > > - //if (value == null && > - // store.getObject(arrayID).getClass().getComponentType().isPrimitive()) { > - // value = 0; > - //} > - > Array.set(store.getObject(arrayID), index, value); > > write(reference, "SetObjectArrayElement"); > @@ -569,13 +553,10 @@ > String[] args = message.split(" "); > Integer arrayID = parseCall(args[1], null, Integer.class); > > - //System.out.println("ARRAYID: " + arrayID); > Object o = store.getObject(arrayID); > int len = 0; > len = Array.getLength(o); > - // System.out.println ("Returning array length: " + len); > > - // System.out.println ("array length: " + o + " " + len); > write(reference, "GetArrayLength " + Array.getLength(o)); > } else if (message.startsWith("GetField")) { > String[] args = message.split(" "); > @@ -624,10 +605,7 @@ > } else if (message.startsWith("GetObjectClass")) { > int oid = Integer.parseInt(message.substring("GetObjectClass" > .length() + 1)); > - // System.out.println ("GETTING CLASS FOR: " + oid); > Class c = store.getObject(oid).getClass(); > - // System.out.println (" OBJ: " + store.getObject(oid)); > - // System.out.println (" CLS: " + c); > store.reference(c); > > write(reference, "GetObjectClass " + store.getIdentifier(c)); > @@ -773,8 +751,6 @@ > byte[] b = null; > o = (String) store.getObject(stringID); > b = o.getBytes("UTF-8"); > - // System.out.println ("STRING UTF-8 LENGTH: " + o + " " + > - // b.length); > > write(reference, "GetStringUTFLength " + o.length()); > } else if (message.startsWith("GetStringLength")) { > @@ -785,10 +761,7 @@ > byte[] b = null; > o = (String) store.getObject(stringID); > b = o.getBytes("UTF-16LE"); > - // System.out.println ("STRING UTF-16 LENGTH: " + o + " " + > - // b.length); > > - // System.out.println ("Java: GetStringLength " + b.length); > write(reference, "GetStringLength " + o.length()); > } else if (message.startsWith("GetStringUTFChars")) { > String[] args = message.split(" "); > @@ -807,8 +780,6 @@ > + Integer > .toString(((int) b[i]) & 0x0ff, 16)); > > - // System.out.println ("Java: GetStringUTFChars: " + o); > - // //System.out.println ("String UTF BYTES: " + buf); > write(reference, "GetStringUTFChars " + buf); > } else if (message.startsWith("GetStringChars")) { > String[] args = message.split(" "); > @@ -854,10 +825,6 @@ > String type = parseCall(args[1], null, String.class); > Integer length = parseCall(args[2], null, Integer.class); > > - // System.out.println ("CALLING: NewArray: " + type + " " + > - // length + " " > - // + Signature.primitiveNameToType(type)); > - > Object newArray = null; > > Class c; > @@ -939,10 +906,6 @@ > Integer classID = parseCall(args[2], null, Integer.class); > Integer objectID = parseCall(args[3], null, Integer.class); > > - // System.out.println ("CALLING: NewObjectArray: " + > - // classID + " " + length + " " > - // + objectID); > - > Object newArray = null; > newArray = Array.newInstance((Class) store.getObject(classID), > length); > @@ -962,12 +925,9 @@ > final Constructor m = (Constructor) store.getObject(methodID); > Class[] argTypes = m.getParameterTypes(); > > - // System.out.println ("NEWOBJ: HERE1"); > Object[] arguments = new Object[argTypes.length]; > - // System.out.println ("NEWOBJ: HERE2"); > for (int i = 0; i < argTypes.length; i++) { > arguments[i] = parseArgs(args[3 + i], argTypes[i]); > - // System.out.println ("NEWOBJ: GOT ARG: " + arguments[i]); > } > > final Object[] fArguments = arguments; > @@ -1090,9 +1050,6 @@ > ret = new String(byteArray, 0, bytelength, "UTF-16LE"); > PluginDebug.debug("NEWSTRING: " + ret); > > - // System.out.println ("NEWOBJ: CALLED: " + ret); > - // System.out.println ("NEWOBJ: CALLED: " + > - // store.getObject(ret)); > store.reference(ret); > write(reference, "NewString " + store.getIdentifier(ret)); > > @@ -1336,106 +1293,6 @@ > > public AccessControlContext getAccessControlContext(String[] nsPrivilegeList, String src) { > > - /* > - for (int i=0; i < nsPrivilegeList.length; i++) { > - String privilege = nsPrivilegeList[i]; > - > - if (privilege.equals("UniversalAccept")) { > - SocketPermission sp = new SocketPermission("*", "accept,resolve"); > - grantedPermissions.add(sp); > - } else if (privilege.equals("UniversalAwtEventQueueAccess")) { > - AWTPermission awtp = new AWTPermission("accessEventQueue"); > - grantedPermissions.add(awtp); > - } else if (privilege.equals("UniversalConnect")) { > - SocketPermission sp = new SocketPermission("*", "connect,resolve"); > - grantedPermissions.add(sp); > - } else if (privilege.equals("UniversalListen")) { > - SocketPermission sp = new SocketPermission("*", "listen,resolve"); > - grantedPermissions.add(sp); > - } else if (privilege.equals("UniversalExecAccess")) { > - FilePermission fp = new FilePermission("<>", "execute"); > - RuntimePermission rtp = new RuntimePermission("setIO"); > - grantedPermissions.add(fp); > - grantedPermissions.add(rtp); > - } else if (privilege.equals("UniversalExitAccess")) { > - // Doesn't matter what the permissions are. Do not allow VM to exit.. we > - // use a single VM for the entire browser lifecycle once invoked, we > - // cannot let it exit > - > - //RuntimePermission rtp = new RuntimePermission("exitVM.*"); > - //grantedPermissions.add(rtp); > - } else if (privilege.equals("UniversalFileDelete")) { > - FilePermission fp = new FilePermission("<>", "delete"); > - grantedPermissions.add(fp); > - } else if (privilege.equals("UniversalFileRead")) { > - FilePermission fp = new FilePermission("<>", "read"); > - grantedPermissions.add(fp); > - } else if (privilege.equals("UniversalFileWrite")) { > - FilePermission fp = new FilePermission("<>", "write"); > - grantedPermissions.add(fp); > - } else if (privilege.equals("UniversalFdRead")) { > - RuntimePermission rtp = new RuntimePermission("readFileDescriptor"); > - grantedPermissions.add(rtp); > - } else if (privilege.equals("UniversalFdWrite")) { > - RuntimePermission rtp = new RuntimePermission("writeFileDescriptor"); > - grantedPermissions.add(rtp); > - } else if (privilege.equals("UniversalLinkAccess")) { > - RuntimePermission rtp = new RuntimePermission("loadLibrary.*"); > - grantedPermissions.add(rtp); > - } else if (privilege.equals("UniversalListen")) { > - SocketPermission sp = new SocketPermission("*", "listen"); > - grantedPermissions.add(sp); > - } else if (privilege.equals("UniversalMulticast")) { > - SocketPermission sp = new SocketPermission("*", "accept,connect,resolve"); > - grantedPermissions.add(sp); > - } else if (privilege.equals("UniversalPackageAccess")) { > - RuntimePermission rtp = new RuntimePermission("defineClassInPackage.*"); > - grantedPermissions.add(rtp); > - } else if (privilege.equals("UniversalPackageDefinition")) { > - RuntimePermission rtp = new RuntimePermission("accessClassInPackage.*"); > - grantedPermissions.add(rtp); > - } else if (privilege.equals("UniversalPrintJobAccess")) { > - RuntimePermission rtp = new RuntimePermission("queuePrintJob"); > - grantedPermissions.add(rtp); > - } else if (privilege.equals("UniversalPropertyRead")) { > - PropertyPermission pp = new PropertyPermission("*", "read"); > - grantedPermissions.add(pp); > - } else if (privilege.equals("UniversalPropertyWrite")) { > - PropertyPermission pp = new PropertyPermission("*", "write"); > - grantedPermissions.add(pp); > - } else if (privilege.equals("UniversalSetFactory")) { > - RuntimePermission rtp = new RuntimePermission("setFactory"); > - grantedPermissions.add(rtp); > - } else if (privilege.equals("UniversalSystemClipboardAccess")) { > - AWTPermission awtp = new AWTPermission("accessClipboard"); > - grantedPermissions.add(awtp); > - } else if (privilege.equals("UniversalThreadAccess")) { > - RuntimePermission rtp1 = new RuntimePermission("modifyThread"); > - RuntimePermission rtp2 = new RuntimePermission("stopThread"); > - grantedPermissions.add(rtp1); > - grantedPermissions.add(rtp2); > - } else if (privilege.equals("UniversalThreadGroupAccess")) { > - RuntimePermission rtp1 = new RuntimePermission("modifyThreadGroup"); > - RuntimePermission rtp2 = new RuntimePermission("modifyThread"); > - RuntimePermission rtp3 = new RuntimePermission("stopThread"); > - grantedPermissions.add(rtp1); > - grantedPermissions.add(rtp2); > - grantedPermissions.add(rtp3); > - } else if (privilege.equals("UniversalTopLevelWindow")) { > - AWTPermission awtp = new AWTPermission("topLevelWindow"); > - grantedPermissions.add(awtp); > - } else if (privilege.equals("UniversalBrowserRead")) { > - BrowserReadPermission bp = new BrowserReadPermission(); > - grantedPermissions.add(bp); > - } else if (privilege.equals("UniversalJavaPermissions")) { > - AllPermission ap = new AllPermission(); > - grantedPermissions.add(ap); > - } > - } > - > - // what to do with these is unknown: UniversalConnectWithRedirect, UniversalDialogModality, UniversalSendMail, LimitedInstall, FullInstall, SilentInstall > - */ > - > Permissions grantedPermissions = new Permissions(); > > for (int i = 0; i < nsPrivilegeList.length; i++) { > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginAppletViewer.java > --- a/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java Wed Jan 12 12:50:13 2011 -0500 > +++ b/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java Thu Jan 13 18:02:32 2011 -0500 > @@ -836,7 +836,6 @@ > } > > private Image getCachedImage(URL url) { > - // System.getSecurityManager().checkConnection(url.getHost(), url.getPort()); > return (Image) getCachedImageRef(url).get(); > } > > @@ -1825,18 +1824,6 @@ > > static String encoding = null; > > - static private Reader makeReader(InputStream is) { > - if (encoding != null) { > - try { > - return new BufferedReader(new InputStreamReader(is, encoding)); > - } catch (IOException x) { > - } > - } > - InputStreamReader r = new InputStreamReader(is); > - encoding = r.getEncoding(); > - return new BufferedReader(r); > - } > - > /** > * Scan an html file for tags > */ > @@ -1869,10 +1856,7 @@ > PrintStream statusMsgStream, > PluginAppletPanelFactory factory) > throws IOException { > - // tag flags > - boolean isAppletTag = false; > boolean isObjectTag = false; > - boolean isEmbedTag = false; > boolean objectTagAlreadyParsed = false; > > // The current character > @@ -1948,9 +1932,7 @@ > } > } > atts = null; > - isAppletTag = false; > isObjectTag = false; > - isEmbedTag = false; > } > } else { > String nm = scanIdentifier(c, in); > @@ -1967,15 +1949,12 @@ > String val = t.get("value"); > if (val == null) { > statusMsgStream.println(requiresNameWarning); > - } else if (atts != null) { > + } else { > PluginDebug.debug("PUT " + att + " = " + val); > atts.put(att.toLowerCase(), val); > - } else { > - statusMsgStream.println(paramOutsideWarning); > } > } > } else if (nm.equalsIgnoreCase("applet")) { > - isAppletTag = true; > atts = scanTag(c, in); > > // If there is a classid and no code tag present, transform it to code tag > @@ -2055,7 +2034,6 @@ > atts.put("height", height); > } > } else if (nm.equalsIgnoreCase("embed")) { > - isEmbedTag = true; > atts = scanTag(c, in); > > // If there is a classid and no code tag present, transform it to code tag > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginCallRequest.java > --- a/plugin/icedteanp/java/sun/applet/PluginCallRequest.java Wed Jan 12 12:50:13 2011 -0500 > +++ b/plugin/icedteanp/java/sun/applet/PluginCallRequest.java Thu Jan 13 18:02:32 2011 -0500 > @@ -1,5 +1,5 @@ > /* PluginCallRequest -- represent Java-to-JavaScript requests > - Copyright (C) 2008 Red Hat > + Copyright (C) 2011 Red Hat > > This file is part of IcedTea. > > @@ -37,9 +37,6 @@ > > package sun.applet; > > -import java.security.AccessControlContext; > -import java.security.ProtectionDomain; > - > // FIXME: for each type of request extend a new (anonymous?) > // PluginCallRequest. > public abstract class PluginCallRequest { > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginDebug.java > --- a/plugin/icedteanp/java/sun/applet/PluginDebug.java Wed Jan 12 12:50:13 2011 -0500 > +++ b/plugin/icedteanp/java/sun/applet/PluginDebug.java Thu Jan 13 18:02:32 2011 -0500 > @@ -1,5 +1,5 @@ > /* VoidPluginCallRequest -- represent Java-to-JavaScript requests > - Copyright (C) 2008 Red Hat > + Copyright (C) 2011 Red Hat > > This file is part of IcedTea. > > @@ -37,8 +37,6 @@ > > package sun.applet; > > -import java.io.*; > - > public class PluginDebug { > > static final boolean DEBUG = System.getenv().containsKey("ICEDTEAPLUGIN_DEBUG"); > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginMessageConsumer.java > --- a/plugin/icedteanp/java/sun/applet/PluginMessageConsumer.java Wed Jan 12 12:50:13 2011 -0500 > +++ b/plugin/icedteanp/java/sun/applet/PluginMessageConsumer.java Thu Jan 13 18:02:32 2011 -0500 > @@ -1,5 +1,5 @@ > /* VoidPluginCallRequest -- represent Java-to-JavaScript requests > - Copyright (C) 2008 Red Hat > + Copyright (C) 2011 Red Hat > > This file is part of IcedTea. > > @@ -41,7 +41,6 @@ > import java.util.Hashtable; > import java.util.Iterator; > import java.util.LinkedList; > -import java.util.Set; > > class PluginMessageConsumer { > > @@ -107,17 +106,6 @@ > } > } > > - /** > - * Returns the reference for this message. This method assumes that > - * the message has a reference number. > - * > - * @param The message > - * @return the reference number > - */ > - private Long getReference(String[] msgParts) { > - return Long.parseLong(msgParts[3]); > - } > - > public PluginMessageConsumer(PluginStreamHandler streamHandler) { > > as = new AppletSecurity(); > @@ -144,10 +132,6 @@ > return null; > } > > - private boolean isInInit(Integer instanceNum) { > - return initWorkers.containsKey(instanceNum); > - } > - > private void addToInitWorkers(Integer instanceNum, PluginMessageHandlerWorker worker) { > synchronized (initWorkers) { > initWorkers.put(instanceNum, worker); > @@ -291,10 +275,4 @@ > // No workers available. Better luck next time! > return null; > } > - > - private void dumpWorkerStatus() { > - for (PluginMessageHandlerWorker worker : workers) { > - PluginDebug.debug(worker.toString()); > - } > - } > } > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginMessageHandlerWorker.java > --- a/plugin/icedteanp/java/sun/applet/PluginMessageHandlerWorker.java Wed Jan 12 12:50:13 2011 -0500 > +++ b/plugin/icedteanp/java/sun/applet/PluginMessageHandlerWorker.java Thu Jan 13 18:02:32 2011 -0500 > @@ -1,5 +1,5 @@ > /* VoidPluginCallRequest -- represent Java-to-JavaScript requests > - Copyright (C) 2008 Red Hat > + Copyright (C) 2011 Red Hat > > This file is part of IcedTea. > > @@ -43,7 +43,6 @@ > private boolean isPriorityWorker = false; > private int id; > private String message = null; > - private SecurityManager sm; > PluginStreamHandler streamHandler = null; > PluginMessageConsumer consumer = null; > > @@ -54,7 +53,6 @@ > > this.id = id; > this.streamHandler = streamHandler; > - this.sm = sm; > this.isPriorityWorker = isPriorityWorker; > this.consumer = consumer; > > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginObjectStore.java > --- a/plugin/icedteanp/java/sun/applet/PluginObjectStore.java Wed Jan 12 12:50:13 2011 -0500 > +++ b/plugin/icedteanp/java/sun/applet/PluginObjectStore.java Thu Jan 13 18:02:32 2011 -0500 > @@ -1,5 +1,5 @@ > /* PluginObjectStore -- manage identifier-to-object mapping > - Copyright (C) 2008 Red Hat > + Copyright (C) 2011 Red Hat > > This file is part of IcedTea. > > @@ -38,8 +38,6 @@ > package sun.applet; > > import java.util.*; > -import java.lang.reflect.*; > -import java.io.*; > > public class PluginObjectStore { > private static HashMap objects = new HashMap(); > @@ -87,36 +85,24 @@ > objects.put(nextUniqueIdentifier, object); > counts.put(nextUniqueIdentifier, 1); > identifiers.put(object, nextUniqueIdentifier); > - //System.out.println("JAVA ADDED: " + nextUniqueIdentifier); > - //System.out.println("JAVA REFERENCED: " + nextUniqueIdentifier > - // + " to: 1"); > nextUniqueIdentifier++; > } else { > counts.put(identifier, counts.get(identifier) + 1); > - //System.out.println("JAVA REFERENCED: " + identifier + > - // " to: " + counts.get(identifier)); > } > } > > public void unreference(int identifier) { > Integer currentCount = counts.get(identifier); > if (currentCount == null) { > - //System.out.println("ERROR UNREFERENCING: " + identifier); > return; > } > if (currentCount == 1) { > - //System.out.println("JAVA DEREFERENCED: " + identifier > - // + " to: 0"); > Object object = objects.get(identifier); > objects.remove(identifier); > counts.remove(identifier); > identifiers.remove(object); > - //System.out.println("JAVA REMOVED: " + identifier); > } else { > counts.put(identifier, currentCount - 1); > - //System.out.println("JAVA DEREFERENCED: " + > - // identifier + " to: " + > - // counts.get(identifier)); > } > } > > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginProxyInfoRequest.java > --- a/plugin/icedteanp/java/sun/applet/PluginProxyInfoRequest.java Wed Jan 12 12:50:13 2011 -0500 > +++ b/plugin/icedteanp/java/sun/applet/PluginProxyInfoRequest.java Thu Jan 13 18:02:32 2011 -0500 > @@ -1,5 +1,5 @@ > /* PluginProxyInfoRequest -- Object representing a request for proxy information from the browser > - Copyright (C) 2009 Red Hat > + Copyright (C) 2011 Red Hat > > This file is part of IcedTea. > > @@ -37,7 +37,6 @@ > > package sun.applet; > > -import java.net.MalformedURLException; > import java.net.URI; > > /** > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginStreamHandler.java > --- a/plugin/icedteanp/java/sun/applet/PluginStreamHandler.java Wed Jan 12 12:50:13 2011 -0500 > +++ b/plugin/icedteanp/java/sun/applet/PluginStreamHandler.java Thu Jan 13 18:02:32 2011 -0500 > @@ -1,5 +1,5 @@ > /* VoidPluginCallRequest -- represent Java-to-JavaScript requests > - Copyright (C) 2008 Red Hat > + Copyright (C) 2011 Red Hat > > This file is part of IcedTea. > > @@ -39,13 +39,11 @@ > > import java.io.BufferedReader; > import java.io.BufferedWriter; > -import java.io.FileWriter; > import java.io.IOException; > import java.io.InputStream; > import java.io.InputStreamReader; > import java.io.OutputStream; > import java.io.OutputStreamWriter; > -import java.io.StreamTokenizer; > import java.net.MalformedURLException; > import java.nio.charset.Charset; > import java.util.Date; > @@ -56,7 +54,6 @@ > public class PluginStreamHandler { > > private BufferedReader pluginInputReader; > - private StreamTokenizer pluginInputTokenizer; > private BufferedWriter pluginOutputWriter; > > private RequestQueue queue = new RequestQueue(); > @@ -70,10 +67,6 @@ > > PluginAppletViewer pav; > > - static Date d = new Date(); > - static long startTime = d.getTime(); > - static long totalWait = 0; > - > public PluginStreamHandler(InputStream inputstream, OutputStream outputstream) > throws MalformedURLException, IOException { > > @@ -82,13 +75,10 @@ > pav = (PluginAppletViewer) ClassLoader.getSystemClassLoader().loadClass("sun.applet.PluginAppletViewer").newInstance(); > PluginDebug.debug("Loaded: " + pav + " CL=" + pav.getClass().getClassLoader()); > } catch (InstantiationException e) { > - // TODO Auto-generated catch block > e.printStackTrace(); > } catch (IllegalAccessException e) { > - // TODO Auto-generated catch block > e.printStackTrace(); > } catch (ClassNotFoundException e) { > - // TODO Auto-generated catch block > e.printStackTrace(); > } > > @@ -99,23 +89,9 @@ > pluginInputReader = > new BufferedReader(new InputStreamReader(inputstream, > Charset.forName("UTF-8"))); > - /*pluginInputTokenizer = new StreamTokenizer(pluginInputReader); > - pluginInputTokenizer.resetSyntax(); > - pluginInputTokenizer.whitespaceChars('\u0000', '\u0000'); > - pluginInputTokenizer.wordChars('\u0001', '\u00FF');*/ > pluginOutputWriter = > new BufferedWriter(new OutputStreamWriter > (outputstream, Charset.forName("UTF-8"))); > - > - /* > - while(true) { > - String message = read(); > - PluginDebug.debug(message); > - handleMessage(message); > - // TODO: > - // write(queue.peek()); > - } > - */ > } > > public void startProcessing() { > @@ -128,15 +104,8 @@ > > PluginDebug.debug("Waiting for data..."); > > - long b4 = new Date().getTime(); > - > String s = read(); > > - long after = new Date().getTime(); > - > - totalWait += (after - b4); > - //System.err.println("Total wait time: " + totalWait); > - > if (s != null) { > consumer.queue(s); > } else { > @@ -152,35 +121,6 @@ > PluginDebug.debug("APPLETVIEWER: exiting appletviewer"); > System.exit(0); > } > - > - /* > - int readChar = -1; > - // blocking read, discard first character > - try { > - readChar = pluginInputReader.read(); > - } catch (IOException ioe) { > - // plugin may have detached > - } > - > - // if not disconnected > - if (readChar != -1) { > - String s = read(); > - PluginDebug.debug("Got data, consuming " + s); > - consumer.consume(s); > - } else { > - try { > - // Close input/output channels to plugin. > - pluginInputReader.close(); > - pluginOutputWriter.close(); > - } catch (IOException exception) { > - // Deliberately ignore IOException caused by broken > - // pipe since plugin may have already detached. > - } > - AppletSecurityContextManager.dumpStore(0); > - PluginDebug.debug("APPLETVIEWER: exiting appletviewer"); > - System.exit(0); > - } > - */ > } > } > }; > @@ -411,13 +351,6 @@ > } > > return; > - /* > - synchronized(writeQueue) { > - writeQueue.add(message); > - PluginDebug.debug(" PIPE: appletviewer wrote: " + message); > - } > - */ > - > } > > public boolean messageAvailable() { -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From andrew at icedtea.classpath.org Fri Jan 14 05:58:48 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Fri, 14 Jan 2011 13:58:48 +0000 Subject: /hg/icedtea6-hg: Drop jtreg-DeleteFont.patch due to backport of ... Message-ID: changeset b68332db2560 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=b68332db2560 author: Andrew John Hughes date: Fri Jan 14 13:58:40 2011 +0000 Drop jtreg-DeleteFont.patch due to backport of 7009828 regression fix. 2011-01-13 Andrew John Hughes * patches/jtreg-DeleteFont.patch: Drop patch. No longer needed due to backport of 7009828 upstream. * Makefile.am: Drop above. diffstat: 3 files changed, 8 insertions(+), 22 deletions(-) ChangeLog | 9 ++++++++- Makefile.am | 1 - patches/jtreg-DeleteFont.patch | 20 -------------------- diffs (51 lines): diff -r 8fbbbe4af6bc -r b68332db2560 ChangeLog --- a/ChangeLog Thu Jan 13 09:57:38 2011 +0000 +++ b/ChangeLog Fri Jan 14 13:58:40 2011 +0000 @@ -1,4 +1,11 @@ 2011-01-10 Andrew John Hughes +2011-01-13 Andrew John Hughes + + * patches/jtreg-DeleteFont.patch: + Drop patch. No longer needed due to backport + of 7009828 upstream. + * Makefile.am: Drop above. + +2011-01-13 Andrew John Hughes * patches/openjdk/6980392-fix_test6581734.patch: Remove upstreamed patch. diff -r 8fbbbe4af6bc -r b68332db2560 Makefile.am --- a/Makefile.am Thu Jan 13 09:57:38 2011 +0000 +++ b/Makefile.am Fri Jan 14 13:58:40 2011 +0000 @@ -263,7 +263,6 @@ ICEDTEA_PATCHES = \ patches/openjdk/6967436-6976265-6967434-pisces.patch \ patches/openjdk/6997495-test_correction_6857159.patch \ patches/f14-fonts.patch \ - patches/jtreg-DeleteFont.patch \ patches/jtreg-WindowWithWarningTest.patch \ patches/jtreg-T6638712-fix.patch \ patches/jtreg-T6650759m-fix.patch \ diff -r 8fbbbe4af6bc -r b68332db2560 patches/jtreg-DeleteFont.patch --- a/patches/jtreg-DeleteFont.patch Thu Jan 13 09:57:38 2011 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,20 +0,0 @@ ---- openjdk-old/jdk/test/java/awt/FontClass/CreateFont/DeleteFont.sh 2010-06-21 23:15:49.000000000 +0200 -+++ openjdk/jdk/test/java/awt/FontClass/CreateFont/DeleteFont.sh 2010-11-15 14:13:13.000000000 +0100 -@@ -46,7 +46,7 @@ - - cd ${TESTCLASSES} - --numfiles0=`ls ${TESTCLASSES} | wc -l` -+numfiles0=`ls ${TESTCLASSES} | grep -v "^hsperfdata*" | wc -l` - ${TESTJAVA}/bin/java -Djava.io.tmpdir=${TESTCLASSES} DeleteFont - - if [ $? -ne 0 ] -@@ -55,7 +55,7 @@ - exit 1 - fi - --numfiles1=`ls ${TESTCLASSES} | wc -l` -+numfiles1=`ls ${TESTCLASSES} | grep -v "^hsperfdata*" | wc -l` - - if [ $numfiles0 -ne $numfiles1 ] - then From asu at redhat.com Fri Jan 14 07:22:48 2011 From: asu at redhat.com (Andrew Su) Date: Fri, 14 Jan 2011 10:22:48 -0500 (EST) Subject: [RFC][IcedTea-Web]: Added missing package name to Makefile Message-ID: <475865610.18135.1295018568237.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Hi, This patch adds the net.sourceforge.jnlp.config package to NETX_PKGS. Questions? Comments? Concerns? Cheers, Andrew From asu at redhat.com Fri Jan 14 07:23:48 2011 From: asu at redhat.com (Andrew Su) Date: Fri, 14 Jan 2011 10:23:48 -0500 (EST) Subject: [RFC][IcedTea-Web]: Added missing package name to Makefile In-Reply-To: <475865610.18135.1295018568237.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Message-ID: <900329256.18191.1295018628319.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> And here is the patch.. ----- Original Message ----- > From: "Andrew Su" > To: "OpenJDK" > Sent: Friday, January 14, 2011 10:22:48 AM > Subject: [RFC][IcedTea-Web]: Added missing package name to Makefile > Hi, > > This patch adds the net.sourceforge.jnlp.config package to NETX_PKGS. > > Questions? Comments? Concerns? > > Cheers, > Andrew -------------- next part -------------- A non-text attachment was scrubbed... Name: 20110114_add_package_to_makefile.patch Type: text/x-patch Size: 895 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110114/28c0266b/20110114_add_package_to_makefile.patch From omajid at redhat.com Fri Jan 14 07:49:07 2011 From: omajid at redhat.com (Omair Majid) Date: Fri, 14 Jan 2011 10:49:07 -0500 Subject: [RFC][IcedTea-Web]: Added missing package name to Makefile In-Reply-To: <900329256.18191.1295018628319.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> References: <900329256.18191.1295018628319.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Message-ID: <4D307073.9020900@redhat.com> On 01/14/2011 10:23 AM, Andrew Su wrote: > And here is the patch.. > Looks good to me. It would be better if we could keep the list sorted too. Ok for HEAD. Cheers, Omair From asu at redhat.com Fri Jan 14 08:01:41 2011 From: asu at redhat.com (Andrew Su) Date: Fri, 14 Jan 2011 11:01:41 -0500 Subject: [RFC][IcedTea-Web]: Added missing package name to Makefile In-Reply-To: <4D307073.9020900@redhat.com> References: <900329256.18191.1295018628319.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <4D307073.9020900@redhat.com> Message-ID: <4D307365.9080103@redhat.com> On 01/14/2011 10:49 AM, Omair Majid wrote: > On 01/14/2011 10:23 AM, Andrew Su wrote: >> And here is the patch.. >> > > Looks good to me. It would be better if we could keep the list sorted > too. Ok for HEAD. > > Cheers, > Omair Ah, here is the updated patch with another package added as well. net.sourceforge.jnlp.config net.sourceforge.jnlp.runtime in sorted order :) Cheers, Andrew -------------- next part -------------- A non-text attachment was scrubbed... Name: 20110114_add_package_to_makefile_v3.patch Type: text/x-patch Size: 1300 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110114/90f780f2/20110114_add_package_to_makefile_v3.patch From omajid at redhat.com Fri Jan 14 08:12:05 2011 From: omajid at redhat.com (Omair Majid) Date: Fri, 14 Jan 2011 11:12:05 -0500 Subject: [RFC][IcedTea-Web]: Added missing package name to Makefile In-Reply-To: <4D307365.9080103@redhat.com> References: <900329256.18191.1295018628319.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <4D307073.9020900@redhat.com> <4D307365.9080103@redhat.com> Message-ID: <4D3075D5.4080802@redhat.com> On 01/14/2011 11:01 AM, Andrew Su wrote: > Ah, here is the updated patch with another package added as well. > > net.sourceforge.jnlp.config > net.sourceforge.jnlp.runtime > > in sorted order :) > Thanks for catching the missing packages from the list. The change looks good to me. Ok for HEAD. Cheers, Omair From asu at icedtea.classpath.org Fri Jan 14 08:14:52 2011 From: asu at icedtea.classpath.org (asu at icedtea.classpath.org) Date: Fri, 14 Jan 2011 16:14:52 +0000 Subject: /hg/icedtea-web: Add missing netx package names to NETX_PKGS in ... Message-ID: changeset ce755342e8e8 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=ce755342e8e8 author: Andrew Su date: Fri Jan 14 11:14:46 2011 -0500 Add missing netx package names to NETX_PKGS in Makefile.am. diffstat: 2 files changed, 10 insertions(+), 4 deletions(-) ChangeLog | 5 +++++ Makefile.am | 9 +++++---- diffs (31 lines): diff -r 4e84e06b54e9 -r ce755342e8e8 ChangeLog --- a/ChangeLog Wed Jan 12 12:50:13 2011 -0500 +++ b/ChangeLog Fri Jan 14 11:14:46 2011 -0500 @@ -1,3 +1,8 @@ 2011-01-12 Omair Majid + + * Makefile.am: Added net.sourceforge.jnlp.config and + net.sourceforge.jnlp.runtime to NETX_PKGS. + 2011-01-12 Omair Majid * netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java diff -r 4e84e06b54e9 -r ce755342e8e8 Makefile.am --- a/Makefile.am Wed Jan 12 12:50:13 2011 -0500 +++ b/Makefile.am Fri Jan 14 11:14:46 2011 -0500 @@ -26,10 +26,11 @@ PLUGIN_TEST_SRCS = $(abs_top_srcdir)/plu PLUGIN_TEST_SRCS = $(abs_top_srcdir)/plugin/tests/LiveConnect/*.java NETX_PKGS = javax.jnlp net.sourceforge.nanoxml net.sourceforge.jnlp \ - net.sourceforge.jnlp.cache net.sourceforge.jnlp.event \ - net.sourceforge.jnlp.security net.sourceforge.jnlp.security.viewer \ - net.sourceforge.jnlp.services net.sourceforge.jnlp.tools \ - net.sourceforge.jnlp.util net.sourceforge.jnlp.controlpanel + net.sourceforge.jnlp.cache net.sourceforge.jnlp.config \ + net.sourceforge.jnlp.controlpanel net.sourceforge.jnlp.event \ + net.sourceforge.jnlp.runtime net.sourceforge.jnlp.security \ + net.sourceforge.jnlp.security.viewer net.sourceforge.jnlp.services \ + net.sourceforge.jnlp.tools net.sourceforge.jnlp.util # Conditional defintions if ENABLE_PLUGIN From asu at redhat.com Fri Jan 14 08:19:06 2011 From: asu at redhat.com (Andrew Su) Date: Fri, 14 Jan 2011 11:19:06 -0500 Subject: [RFC][IcedTea-Web]: Added missing package name to Makefile In-Reply-To: <4D3075D5.4080802@redhat.com> References: <900329256.18191.1295018628319.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <4D307073.9020900@redhat.com> <4D307365.9080103@redhat.com> <4D3075D5.4080802@redhat.com> Message-ID: <4D30777A.8080300@redhat.com> On 01/14/2011 11:12 AM, Omair Majid wrote: > On 01/14/2011 11:01 AM, Andrew Su wrote: >> Ah, here is the updated patch with another package added as well. >> >> net.sourceforge.jnlp.config >> net.sourceforge.jnlp.runtime >> >> in sorted order :) >> > > Thanks for catching the missing packages from the list. The change > looks good to me. Ok for HEAD. > > Cheers, > Omair Thanks for the review! Pushed to HEAD Cheers, Andrew From bugzilla-daemon at icedtea.classpath.org Mon Jan 17 02:35:47 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Mon, 17 Jan 2011 10:35:47 +0000 Subject: [Bug 611] Minecraft Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=611 ------- Comment #2 from ulo_kapta at hotmail.com 2011-01-17 10:35 ------- >From what I understand of the exception that you've pasted it looks like a PixelFormat error. Which usually means OpenGL drivers have not been found. -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From ahughes at redhat.com Mon Jan 17 06:10:07 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Mon, 17 Jan 2011 14:10:07 +0000 Subject: Request to backport 6736649 and 6797139 In-Reply-To: <4D30CFB1.6050705@redhat.com> References: <4D30CFB1.6050705@redhat.com> Message-ID: <20110117141006.GA13471@rivendell.middle-earth.co.uk> On 17:35 Fri 14 Jan , Omair Majid wrote: > Hi, > > I would like to backport the following two changesets to openjdk6: > > changeset: 624:e78c2f17a606 > user: mlapshin > date: Tue Aug 26 12:16:23 2008 +0400 > summary: 6736649: > test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on > Linux > > changeset: 1637:281fbd82a971 > user: alexp > date: Wed Sep 02 17:47:19 2009 +0400 > summary: 6797139: JButton title is truncating for some strings > irrespective of preferred size. > > Together, these changesets fix a bug where some strings are incorrectly > being truncated. > > Thanks, > Omair I don't see either of these in IcedTea6. Please add them there first before trying to upstream them. Thanks, -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at redhat.com Mon Jan 17 06:40:25 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 17 Jan 2011 09:40:25 -0500 Subject: Request to backport 6736649 and 6797139 In-Reply-To: <20110117141006.GA13471@rivendell.middle-earth.co.uk> References: <4D30CFB1.6050705@redhat.com> <20110117141006.GA13471@rivendell.middle-earth.co.uk> Message-ID: <4D3454D9.7040200@redhat.com> On 01/17/2011 09:10 AM, Dr Andrew John Hughes wrote: > On 17:35 Fri 14 Jan , Omair Majid wrote: >> I would like to backport the following two changesets to openjdk6: >> >> changeset: 624:e78c2f17a606 >> user: mlapshin >> date: Tue Aug 26 12:16:23 2008 +0400 >> summary: 6736649: >> test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on >> Linux >> >> changeset: 1637:281fbd82a971 >> user: alexp >> date: Wed Sep 02 17:47:19 2009 +0400 >> summary: 6797139: JButton title is truncating for some strings >> irrespective of preferred size. >> >> Together, these changesets fix a bug where some strings are incorrectly >> being truncated. >> > > I don't see either of these in IcedTea6. Please add them there first before > trying to upstream them. > I was going to add them to IcedTea6 as soon as Joe approved them for openjdk6. Can I assume you are okay with adding it to IcedTea6 without waiting for Joe's comments? The reason I ping openjdk6 is that they are much more likely to notice things like accidental conflicts with specs. Cheers, Omair From ptisnovs at redhat.com Mon Jan 17 07:27:07 2011 From: ptisnovs at redhat.com (Pavel Tisnovsky) Date: Mon, 17 Jan 2011 16:27:07 +0100 Subject: Reviewer needed - new regression test for checking font rendering & addition of copyright text to existing test Message-ID: <4D345FCB.8000900@redhat.com> Hi all, I'd like to add new regression test which check proper rendering of international fonts using various logical font names and font styles. This new test is stored in attachment as [InternationalFontsStyles.java] (for review) and it is also part of icedtea-jtreg-international-fonts.patch. I also added copyright text into existing test InternationalFontRendering..java. Both changes are included as hg diff done against recent IcedTea6 [hg_diff]. Can anyone please review these changes? Thank you in advance Pavel -------------- next part -------------- A non-text attachment was scrubbed... Name: InternationalFontsStyles.java Type: text/x-java Size: 9949 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110117/0d1daf39/InternationalFontsStyles.java -------------- next part -------------- An embedded and charset-unspecified text was scrubbed... Name: hg_diff Url: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110117/0d1daf39/hg_diff.ksh From ahughes at redhat.com Mon Jan 17 07:43:58 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Mon, 17 Jan 2011 15:43:58 +0000 Subject: Reviewer needed - new regression test for checking font rendering & addition of copyright text to existing test In-Reply-To: <4D345FCB.8000900@redhat.com> References: <4D345FCB.8000900@redhat.com> Message-ID: <20110117154358.GC13471@rivendell.middle-earth.co.uk> On 16:27 Mon 17 Jan , Pavel Tisnovsky wrote: > Hi all, > > I'd like to add new regression test which check proper rendering of > international fonts using various logical font names and font styles. > This new test is stored in attachment as [InternationalFontsStyles.java] > (for review) and it is also part of icedtea-jtreg-international-fonts.patch. > > I also added copyright text into existing test > InternationalFontRendering..java. Both changes are included as hg diff > done against recent IcedTea6 [hg_diff]. > > Can anyone please review these changes? > > Thank you in advance > Pavel Couple of points: * I think the characters used should use the Unicode escape notation (\uXXXX). Here in the mail, at least, they are just displaying as ?????. * You don't include any change to Makefile.am to actually apply the patch. Also for future reference, the ChangeLog should be in the body of the e-mail not the patch, when posting to the list, so others can more easily apply and test the patch. > import java.awt.Color; > import java.awt.Font; > import java.awt.Graphics2D; > import java.awt.RenderingHints; > import java.awt.image.BufferedImage; > import java.io.File; > import java.io.IOException; > import java.util.Arrays; > import java.util.List; > import java.util.ArrayList; > > import javax.imageio.ImageIO; > > /** > * @test > * @run main InternationalFontsStyles > * @author Pavel Tisnovsky > * > * @summary This test check if selected international characters could be > * properly rendered with various font styles and logical names. > * > * This regression test check if selected international characters > * could be properly rendered using various styles and logical font > * names - the test check rendering using all combinations of logical > * font names (Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, > * Font.DIALOG, Font.DIALOG_INPUT) and font styles (Font.PLAIN, > * Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC). > * > * The test is based on rendering certain characters from selected code > * pages into BufferedImage. > * > * When the shape of selected character does not exists or font > * configuration is broken, only empty rectangle is rendered instead of > * the selected character shape. This rectangle is filtered and then > * the destination image is tested whether it is empty (=white). > * > * If test images with rendered characters needs to be created use > * following flag: -create-images > * > */ > public class InternationalFontsStyles > { > // all logical font names which are tested > private static final String[] fontNames = {Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, Font.DIALOG, Font.DIALOG_INPUT}; > > // all font styles which are tested > private static final int[] fontStyles = {Font.PLAIN, Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC}; > > // width and height of image where is each character rendered > private static int WIDTH = 200; > private static int HEIGHT = 200; > > // font size used for rendering > private static final int FONT_SIZE = 160; > > private static final int MINIMUM_HORIZONTAL_LINE_LENGTH = 70; > private static final int MINIMUM_VERTICAL_LINE_LENGTH = 80; > private static final int BLACK_WHITE_THRESHOLD = 128; > private static final int BLACK_PIXEL_COUNT_THRESHOLD = WIDTH * HEIGHT / 1000; > > private static final String[][] testedStrings = { > {"Latin-1", "abcdefABCDEF"}, > {"Latin-2", "??????????????????????????"}, > {"Cyrilic", "??????????????????"}, > {"Greek", "????????????????????????????????"}, > {"Asia-Test1", "???????????????"}, > {"Asia-Test2", "??????????????????"}, > {"Asia-Test3", "???????????????"}, > {"Asia-Test4", "???????????????"}, > }; > > /** > * Returns string containing given font style. This style could > * be PLAIN, BOLD, ITALIC or combination of these styles. > * > * @param fontStyle selected font style, eg. Font.BOLD > * @return textual representation of font style > */ > private static String getFontStyle(int fontStyle) > { > return new String[] > // 0 1 2 1+2 > { "PLAIN", "BOLD", "ITALIC", "BOLD+ITALIC" }[fontStyle]; > } > > /** > * Creates test image a renders one big character to it. > * @param str string to be rendered > * @param fontStyle selected font style > * @param fontName selected font name > * @return > */ > private BufferedImage createTestImage(String str, String fontName, int fontStyle) { > BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); > Graphics2D gc = image.createGraphics(); > gc.setBackground(Color.WHITE); > gc.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_OFF); > gc.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING, RenderingHints.VALUE_TEXT_ANTIALIAS_OFF); > gc.clearRect(0, 0, WIDTH, HEIGHT); > gc.setFont(new Font(fontName, fontStyle, FONT_SIZE)); > gc.setColor(Color.BLACK); > gc.drawString(str, 0, HEIGHT - 40); > gc.dispose(); > return image; > } > > /** > * Creates destination image and then copies data from source image to it > * @param src source image > * @return destination image as copy of source image > */ > private BufferedImage createDestinationImage(BufferedImage src) > { > BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); > src.copyData(image.getRaster()); > return image; > } > > /** > * Removes long horizontal lines from image > */ > private void removeHorizontalLines(BufferedImage image) > { > for (int y = 0; y < image.getHeight(); y++) > { > int startX = -1, endX = -1; > for (int x = 0; x < image.getWidth(); x++) > { > int color = image.getRaster().getSample(x, y, 0); > if (startX < 0 && color <= BLACK_WHITE_THRESHOLD) { > startX = x; > //System.out.println("> " + y + "\t" + x); > } > if (startX > 0 && endX < 0 && color > BLACK_WHITE_THRESHOLD) > { > endX = x; > //System.out.println("< " + y + "\t" + x); > } > } > // remove long horizontal line, but only if this line found detected in image > if (startX > 0 && endX > 0 && (endX - startX) > MINIMUM_HORIZONTAL_LINE_LENGTH) > { > for (int x = startX; x < endX; x++) { > image.getRaster().setSample(x, y, 0, 255); > } > } > } > } > > /** > * Removes long vertical lines from image > */ > private void removeVerticalLines(BufferedImage image) > { > for (int x = 0; x < image.getWidth(); x++) > { > int startY = -1, endY = -1; > for (int y = 0; y < image.getHeight(); y++) > { > int color = image.getRaster().getSample(x, y, 0); > if (startY < 0 && color <= BLACK_WHITE_THRESHOLD) > { > startY = y; > } > if (startY > 0 && endY < 0 && color > BLACK_WHITE_THRESHOLD) > { > endY = y; > //System.out.println("< " + y + "\t" + x); > } > } > // remove long vertical line, but only if this line found detected in image > if (startY > 0 && endY > 0 && (endY - startY) > MINIMUM_VERTICAL_LINE_LENGTH) > { > for (int y = startY; y < endY; y++) { > image.getRaster().setSample(x, y, 0, 255); > } > } > } > } > > /** > * Test if image is almost empty (one large white area) > * @param image > * @return > */ > private boolean isImageAlmostEmpty(BufferedImage image) > { > int blackPixelCount = 0; > for (int y = 0; y < image.getHeight(); y++) > { > for (int x = 0; x < image.getWidth(); x++) > { > if (image.getRaster().getSample(x, y, 0) < BLACK_WHITE_THRESHOLD) > { > blackPixelCount++; > } > } > } > return blackPixelCount < BLACK_PIXEL_COUNT_THRESHOLD; > } > > private String constructImageFileName(String fontName, int fontStyle, int code, String suffix) > { > return fontName + "_" + getFontStyle(fontStyle) + "_" + code + "_" + suffix + ".png"; > } > > public void runTest(boolean createImages) throws IOException > { > List badCharacters = new ArrayList(); > for (String[] testedString : testedStrings) > { > for (String fontName : fontNames) > { > for (int fontStyle : fontStyles) > { > System.out.format("check string %s rendered by font %s with style %s\n", testedString[1], fontName, > getFontStyle(fontStyle)); > for (int i = 0; i < testedString[1].length(); i++) > { > String str = testedString[1].substring(i, 1 + i); > int code = str.charAt(0); > System.out.print(code + "\t"); > BufferedImage src = createTestImage(str, fontName, fontStyle); > BufferedImage dst = createDestinationImage(src); > removeHorizontalLines(dst); > removeVerticalLines(dst); > > if (createImages /*|| true*/) > { > ImageIO.write(src, "png", > new File(constructImageFileName(fontName, fontStyle, code, "scr"))); > ImageIO.write(dst, "png", > new File(constructImageFileName(fontName, fontStyle, code, "dst"))); > } > > if (isImageAlmostEmpty(dst)) > { > System.out.println("*** Error in rendering of character with code: " + code); > badCharacters.add(Integer.valueOf(code)); > } > } > System.out.println(); > } > } > } > // if at least one character is not rendered properly throw an exception > if (!badCharacters.isEmpty()) > { > throw new RuntimeException("There are some broken characters: " + badCharacters.toString()); > } > System.out.println("done!"); > } > > public static void main(String[] args) throws IOException > { > new InternationalFontsStyles().runTest(Arrays.asList(args).contains("-create-images")); > } > } > diff -r fd09f4a3b767 ChangeLog > --- a/ChangeLog Sun Jan 09 00:43:01 2011 +0000 > +++ b/ChangeLog Mon Jan 17 16:09:19 2011 +0100 > @@ -1,3 +1,9 @@ > +2011-01-17 Pavel Tisnovsky > + > + * patches/icedtea-jtreg-international-fonts.patch: > + Added new font test - InternationalFontsStyles > + Added copyright text into InternationalFontRendering > + > 2011-01-07 Andrew John Hughes > > * patches/jtreg-TestXEmbedServer-fix.patch: > diff -r fd09f4a3b767 patches/icedtea-jtreg-international-fonts.patch > --- a/patches/icedtea-jtreg-international-fonts.patch Sun Jan 09 00:43:01 2011 +0000 > +++ b/patches/icedtea-jtreg-international-fonts.patch Mon Jan 17 16:09:19 2011 +0100 > @@ -1,6 +1,25 @@ > ---- /dev/null 2010-06-29 14:56:30.329576932 +0200 > -+++ openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsRendering.java 2010-11-01 11:27:46.000000000 +0100 > -@@ -0,0 +1,192 @@ > +--- /dev/null 2010-06-29 11:10:08.737208357 +0200 > ++++ openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsRendering.java 2011-01-17 16:01:02.000000000 +0100 > +@@ -0,0 +1,211 @@ > ++/* > ++ * Copyright 2010 Red Hat, Inc. All Rights Reserved. > ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. > ++ * > ++ * This code is free software; you can redistribute it and/or modify it > ++ * under the terms of the GNU General Public License version 2 only, as > ++ * published by the Free Software Foundation. > ++ * > ++ * This code is distributed in the hope that it will be useful, but WITHOUT > ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or > ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License > ++ * version 2 for more details (a copy is included in the LICENSE file that > ++ * accompanied this code). > ++ * > ++ * You should have received a copy of the GNU General Public License version > ++ * 2 along with this work; if not, write to the Free Software Foundation, > ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. > ++ */ > ++ > +import java.awt.Color; > +import java.awt.Font; > +import java.awt.Graphics2D; > @@ -193,3 +212,283 @@ > + } > +} > + > +--- /dev/null 2010-06-29 11:10:08.737208357 +0200 > ++++ openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsStyles.java 2011-01-17 16:01:18.000000000 +0100 > +@@ -0,0 +1,277 @@ > ++/* > ++ * Copyright 2011 Red Hat, Inc. All Rights Reserved. > ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. > ++ * > ++ * This code is free software; you can redistribute it and/or modify it > ++ * under the terms of the GNU General Public License version 2 only, as > ++ * published by the Free Software Foundation. > ++ * > ++ * This code is distributed in the hope that it will be useful, but WITHOUT > ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or > ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License > ++ * version 2 for more details (a copy is included in the LICENSE file that > ++ * accompanied this code). > ++ * > ++ * You should have received a copy of the GNU General Public License version > ++ * 2 along with this work; if not, write to the Free Software Foundation, > ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. > ++ */ > ++ > ++import java.awt.Color; > ++import java.awt.Font; > ++import java.awt.Graphics2D; > ++import java.awt.RenderingHints; > ++import java.awt.image.BufferedImage; > ++import java.io.File; > ++import java.io.IOException; > ++import java.util.Arrays; > ++import java.util.List; > ++import java.util.ArrayList; > ++ > ++import javax.imageio.ImageIO; > ++ > ++/** > ++ * @test > ++ * @run main InternationalFontsStyles > ++ * @author Pavel Tisnovsky > ++ * > ++ * @summary This test check if selected international characters could be > ++ * properly rendered with various font styles and logical names. > ++ * > ++ * This regression test check if selected international characters > ++ * could be properly rendered using various styles and logical font > ++ * names - the test check rendering using all combinations of logical > ++ * font names (Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, > ++ * Font.DIALOG, Font.DIALOG_INPUT) and font styles (Font.PLAIN, > ++ * Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC). > ++ * > ++ * The test is based on rendering certain characters from selected code > ++ * pages into BufferedImage. > ++ * > ++ * When the shape of selected character does not exists or font > ++ * configuration is broken, only empty rectangle is rendered instead of > ++ * the selected character shape. This rectangle is filtered and then > ++ * the destination image is tested whether it is empty (=white). > ++ * > ++ * If test images with rendered characters needs to be created use > ++ * following flag: -create-images > ++ * > ++ */ > ++public class InternationalFontsStyles > ++{ > ++ // all logical font names which are tested > ++ private static final String[] fontNames = {Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, Font.DIALOG, Font.DIALOG_INPUT}; > ++ > ++ // all font styles which are tested > ++ private static final int[] fontStyles = {Font.PLAIN, Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC}; > ++ > ++ // width and height of image where is each character rendered > ++ private static int WIDTH = 200; > ++ private static int HEIGHT = 200; > ++ > ++ // font size used for rendering > ++ private static final int FONT_SIZE = 160; > ++ > ++ private static final int MINIMUM_HORIZONTAL_LINE_LENGTH = 70; > ++ private static final int MINIMUM_VERTICAL_LINE_LENGTH = 80; > ++ private static final int BLACK_WHITE_THRESHOLD = 128; > ++ private static final int BLACK_PIXEL_COUNT_THRESHOLD = WIDTH * HEIGHT / 1000; > ++ > ++ private static final String[][] testedStrings = { > ++ {"Latin-1", "abcdefABCDEF"}, > ++ {"Latin-2", "??????????????????????????"}, > ++ {"Cyrilic", "??????????????????"}, > ++ {"Greek", "????????????????????????????????"}, > ++ {"Asia-Test1", "???????????????"}, > ++ {"Asia-Test2", "??????????????????"}, > ++ {"Asia-Test3", "???????????????"}, > ++ {"Asia-Test4", "???????????????"}, > ++ }; > ++ > ++ /** > ++ * Returns string containing given font style. This style could > ++ * be PLAIN, BOLD, ITALIC or combination of these styles. > ++ * > ++ * @param fontStyle selected font style, eg. Font.BOLD > ++ * @return textual representation of font style > ++ */ > ++ private static String getFontStyle(int fontStyle) > ++ { > ++ return new String[] > ++ // 0 1 2 1+2 > ++ { "PLAIN", "BOLD", "ITALIC", "BOLD+ITALIC" }[fontStyle]; > ++ } > ++ > ++ /** > ++ * Creates test image a renders one big character to it. > ++ * @param str string to be rendered > ++ * @param fontStyle selected font style > ++ * @param fontName selected font name > ++ * @return > ++ */ > ++ private BufferedImage createTestImage(String str, String fontName, int fontStyle) { > ++ BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); > ++ Graphics2D gc = image.createGraphics(); > ++ gc.setBackground(Color.WHITE); > ++ gc.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_OFF); > ++ gc.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING, RenderingHints.VALUE_TEXT_ANTIALIAS_OFF); > ++ gc.clearRect(0, 0, WIDTH, HEIGHT); > ++ gc.setFont(new Font(fontName, fontStyle, FONT_SIZE)); > ++ gc.setColor(Color.BLACK); > ++ gc.drawString(str, 0, HEIGHT - 40); > ++ gc.dispose(); > ++ return image; > ++ } > ++ > ++ /** > ++ * Creates destination image and then copies data from source image to it > ++ * @param src source image > ++ * @return destination image as copy of source image > ++ */ > ++ private BufferedImage createDestinationImage(BufferedImage src) > ++ { > ++ BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); > ++ src.copyData(image.getRaster()); > ++ return image; > ++ } > ++ > ++ /** > ++ * Removes long horizontal lines from image > ++ */ > ++ private void removeHorizontalLines(BufferedImage image) > ++ { > ++ for (int y = 0; y < image.getHeight(); y++) > ++ { > ++ int startX = -1, endX = -1; > ++ for (int x = 0; x < image.getWidth(); x++) > ++ { > ++ int color = image.getRaster().getSample(x, y, 0); > ++ if (startX < 0 && color <= BLACK_WHITE_THRESHOLD) { > ++ startX = x; > ++ //System.out.println("> " + y + "\t" + x); > ++ } > ++ if (startX > 0 && endX < 0 && color > BLACK_WHITE_THRESHOLD) > ++ { > ++ endX = x; > ++ //System.out.println("< " + y + "\t" + x); > ++ } > ++ } > ++ // remove long horizontal line, but only if this line found detected in image > ++ if (startX > 0 && endX > 0 && (endX - startX) > MINIMUM_HORIZONTAL_LINE_LENGTH) > ++ { > ++ for (int x = startX; x < endX; x++) { > ++ image.getRaster().setSample(x, y, 0, 255); > ++ } > ++ } > ++ } > ++ } > ++ > ++ /** > ++ * Removes long vertical lines from image > ++ */ > ++ private void removeVerticalLines(BufferedImage image) > ++ { > ++ for (int x = 0; x < image.getWidth(); x++) > ++ { > ++ int startY = -1, endY = -1; > ++ for (int y = 0; y < image.getHeight(); y++) > ++ { > ++ int color = image.getRaster().getSample(x, y, 0); > ++ if (startY < 0 && color <= BLACK_WHITE_THRESHOLD) > ++ { > ++ startY = y; > ++ } > ++ if (startY > 0 && endY < 0 && color > BLACK_WHITE_THRESHOLD) > ++ { > ++ endY = y; > ++ //System.out.println("< " + y + "\t" + x); > ++ } > ++ } > ++ // remove long vertical line, but only if this line found detected in image > ++ if (startY > 0 && endY > 0 && (endY - startY) > MINIMUM_VERTICAL_LINE_LENGTH) > ++ { > ++ for (int y = startY; y < endY; y++) { > ++ image.getRaster().setSample(x, y, 0, 255); > ++ } > ++ } > ++ } > ++ } > ++ > ++ /** > ++ * Test if image is almost empty (one large white area) > ++ * @param image > ++ * @return > ++ */ > ++ private boolean isImageAlmostEmpty(BufferedImage image) > ++ { > ++ int blackPixelCount = 0; > ++ for (int y = 0; y < image.getHeight(); y++) > ++ { > ++ for (int x = 0; x < image.getWidth(); x++) > ++ { > ++ if (image.getRaster().getSample(x, y, 0) < BLACK_WHITE_THRESHOLD) > ++ { > ++ blackPixelCount++; > ++ } > ++ } > ++ } > ++ return blackPixelCount < BLACK_PIXEL_COUNT_THRESHOLD; > ++ } > ++ > ++ private String constructImageFileName(String fontName, int fontStyle, int code, String suffix) > ++ { > ++ return fontName + "_" + getFontStyle(fontStyle) + "_" + code + "_" + suffix + ".png"; > ++ } > ++ > ++ public void runTest(boolean createImages) throws IOException > ++ { > ++ List badCharacters = new ArrayList(); > ++ for (String[] testedString : testedStrings) > ++ { > ++ for (String fontName : fontNames) > ++ { > ++ for (int fontStyle : fontStyles) > ++ { > ++ System.out.format("check string %s rendered by font %s with style %s\n", testedString[1], fontName, > ++ getFontStyle(fontStyle)); > ++ for (int i = 0; i < testedString[1].length(); i++) > ++ { > ++ String str = testedString[1].substring(i, 1 + i); > ++ int code = str.charAt(0); > ++ System.out.print(code + "\t"); > ++ BufferedImage src = createTestImage(str, fontName, fontStyle); > ++ BufferedImage dst = createDestinationImage(src); > ++ removeHorizontalLines(dst); > ++ removeVerticalLines(dst); > ++ > ++ if (createImages /*|| true*/) > ++ { > ++ ImageIO.write(src, "png", > ++ new File(constructImageFileName(fontName, fontStyle, code, "scr"))); > ++ ImageIO.write(dst, "png", > ++ new File(constructImageFileName(fontName, fontStyle, code, "dst"))); > ++ } > ++ > ++ if (isImageAlmostEmpty(dst)) > ++ { > ++ System.out.println("*** Error in rendering of character with code: " + code); > ++ badCharacters.add(Integer.valueOf(code)); > ++ } > ++ } > ++ System.out.println(); > ++ } > ++ } > ++ } > ++ // if at least one character is not rendered properly throw an exception > ++ if (!badCharacters.isEmpty()) > ++ { > ++ throw new RuntimeException("There are some broken characters: " + badCharacters.toString()); > ++ } > ++ System.out.println("done!"); > ++ } > ++ > ++ public static void main(String[] args) throws IOException > ++ { > ++ new InternationalFontsStyles().runTest(Arrays.asList(args).contains("-create-images")); > ++ } > ++} -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ptisnovs at redhat.com Mon Jan 17 07:53:50 2011 From: ptisnovs at redhat.com (Pavel Tisnovsky) Date: Mon, 17 Jan 2011 16:53:50 +0100 Subject: Reviewer needed - new regression test for checking font rendering & addition of copyright text to existing test In-Reply-To: <20110117154358.GC13471@rivendell.middle-earth.co.uk> References: <4D345FCB.8000900@redhat.com> <20110117154358.GC13471@rivendell.middle-earth.co.uk> Message-ID: <4D34660E.1070507@redhat.com> Dr Andrew John Hughes wrote: > On 16:27 Mon 17 Jan , Pavel Tisnovsky wrote: >> Hi all, >> >> I'd like to add new regression test which check proper rendering of >> international fonts using various logical font names and font styles. >> This new test is stored in attachment as [InternationalFontsStyles.java] >> (for review) and it is also part of icedtea-jtreg-international-fonts.patch. >> >> I also added copyright text into existing test >> InternationalFontRendering..java. Both changes are included as hg diff >> done against recent IcedTea6 [hg_diff]. >> >> Can anyone please review these changes? >> >> Thank you in advance >> Pavel > > Couple of points: > > * I think the characters used should use the Unicode escape notation (\uXXXX). > Here in the mail, at least, they are just displaying as ?????. It's probably caused by some problem with my mailer configuration or mailman at openjdk.java.net, but you are right - I'll use escape notation (original source file were stored using UTF-8 btw). > * You don't include any change to Makefile.am to actually apply the patch. It's correct because icedtea-jtreg-international-fonts.patch already exists and is properly processed during make so I only changed existed patch. Or do I have to create new patch file? > > Also for future reference, the ChangeLog should be in the body of the > e-mail not the patch, when posting to the list, so others can more > easily apply and test the patch. > >> import java.awt.Color; >> import java.awt.Font; >> import java.awt.Graphics2D; >> import java.awt.RenderingHints; >> import java.awt.image.BufferedImage; >> import java.io.File; >> import java.io.IOException; >> import java.util.Arrays; >> import java.util.List; >> import java.util.ArrayList; >> >> import javax.imageio.ImageIO; >> >> /** >> * @test >> * @run main InternationalFontsStyles >> * @author Pavel Tisnovsky >> * >> * @summary This test check if selected international characters could be >> * properly rendered with various font styles and logical names. >> * >> * This regression test check if selected international characters >> * could be properly rendered using various styles and logical font >> * names - the test check rendering using all combinations of logical >> * font names (Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, >> * Font.DIALOG, Font.DIALOG_INPUT) and font styles (Font.PLAIN, >> * Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC). >> * >> * The test is based on rendering certain characters from selected code >> * pages into BufferedImage. >> * >> * When the shape of selected character does not exists or font >> * configuration is broken, only empty rectangle is rendered instead of >> * the selected character shape. This rectangle is filtered and then >> * the destination image is tested whether it is empty (=white). >> * >> * If test images with rendered characters needs to be created use >> * following flag: -create-images >> * >> */ >> public class InternationalFontsStyles >> { >> // all logical font names which are tested >> private static final String[] fontNames = {Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, Font.DIALOG, Font.DIALOG_INPUT}; >> >> // all font styles which are tested >> private static final int[] fontStyles = {Font.PLAIN, Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC}; >> >> // width and height of image where is each character rendered >> private static int WIDTH = 200; >> private static int HEIGHT = 200; >> >> // font size used for rendering >> private static final int FONT_SIZE = 160; >> >> private static final int MINIMUM_HORIZONTAL_LINE_LENGTH = 70; >> private static final int MINIMUM_VERTICAL_LINE_LENGTH = 80; >> private static final int BLACK_WHITE_THRESHOLD = 128; >> private static final int BLACK_PIXEL_COUNT_THRESHOLD = WIDTH * HEIGHT / 1000; >> >> private static final String[][] testedStrings = { >> {"Latin-1", "abcdefABCDEF"}, >> {"Latin-2", "??????????????????????????"}, >> {"Cyrilic", "??????????????????"}, >> {"Greek", "????????????????????????????????"}, >> {"Asia-Test1", "???????????????"}, >> {"Asia-Test2", "??????????????????"}, >> {"Asia-Test3", "???????????????"}, >> {"Asia-Test4", "???????????????"}, >> }; >> >> /** >> * Returns string containing given font style. This style could >> * be PLAIN, BOLD, ITALIC or combination of these styles. >> * >> * @param fontStyle selected font style, eg. Font.BOLD >> * @return textual representation of font style >> */ >> private static String getFontStyle(int fontStyle) >> { >> return new String[] >> // 0 1 2 1+2 >> { "PLAIN", "BOLD", "ITALIC", "BOLD+ITALIC" }[fontStyle]; >> } >> >> /** >> * Creates test image a renders one big character to it. >> * @param str string to be rendered >> * @param fontStyle selected font style >> * @param fontName selected font name >> * @return >> */ >> private BufferedImage createTestImage(String str, String fontName, int fontStyle) { >> BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); >> Graphics2D gc = image.createGraphics(); >> gc.setBackground(Color.WHITE); >> gc.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_OFF); >> gc.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING, RenderingHints.VALUE_TEXT_ANTIALIAS_OFF); >> gc.clearRect(0, 0, WIDTH, HEIGHT); >> gc.setFont(new Font(fontName, fontStyle, FONT_SIZE)); >> gc.setColor(Color.BLACK); >> gc.drawString(str, 0, HEIGHT - 40); >> gc.dispose(); >> return image; >> } >> >> /** >> * Creates destination image and then copies data from source image to it >> * @param src source image >> * @return destination image as copy of source image >> */ >> private BufferedImage createDestinationImage(BufferedImage src) >> { >> BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); >> src.copyData(image.getRaster()); >> return image; >> } >> >> /** >> * Removes long horizontal lines from image >> */ >> private void removeHorizontalLines(BufferedImage image) >> { >> for (int y = 0; y < image.getHeight(); y++) >> { >> int startX = -1, endX = -1; >> for (int x = 0; x < image.getWidth(); x++) >> { >> int color = image.getRaster().getSample(x, y, 0); >> if (startX < 0 && color <= BLACK_WHITE_THRESHOLD) { >> startX = x; >> //System.out.println("> " + y + "\t" + x); >> } >> if (startX > 0 && endX < 0 && color > BLACK_WHITE_THRESHOLD) >> { >> endX = x; >> //System.out.println("< " + y + "\t" + x); >> } >> } >> // remove long horizontal line, but only if this line found detected in image >> if (startX > 0 && endX > 0 && (endX - startX) > MINIMUM_HORIZONTAL_LINE_LENGTH) >> { >> for (int x = startX; x < endX; x++) { >> image.getRaster().setSample(x, y, 0, 255); >> } >> } >> } >> } >> >> /** >> * Removes long vertical lines from image >> */ >> private void removeVerticalLines(BufferedImage image) >> { >> for (int x = 0; x < image.getWidth(); x++) >> { >> int startY = -1, endY = -1; >> for (int y = 0; y < image.getHeight(); y++) >> { >> int color = image.getRaster().getSample(x, y, 0); >> if (startY < 0 && color <= BLACK_WHITE_THRESHOLD) >> { >> startY = y; >> } >> if (startY > 0 && endY < 0 && color > BLACK_WHITE_THRESHOLD) >> { >> endY = y; >> //System.out.println("< " + y + "\t" + x); >> } >> } >> // remove long vertical line, but only if this line found detected in image >> if (startY > 0 && endY > 0 && (endY - startY) > MINIMUM_VERTICAL_LINE_LENGTH) >> { >> for (int y = startY; y < endY; y++) { >> image.getRaster().setSample(x, y, 0, 255); >> } >> } >> } >> } >> >> /** >> * Test if image is almost empty (one large white area) >> * @param image >> * @return >> */ >> private boolean isImageAlmostEmpty(BufferedImage image) >> { >> int blackPixelCount = 0; >> for (int y = 0; y < image.getHeight(); y++) >> { >> for (int x = 0; x < image.getWidth(); x++) >> { >> if (image.getRaster().getSample(x, y, 0) < BLACK_WHITE_THRESHOLD) >> { >> blackPixelCount++; >> } >> } >> } >> return blackPixelCount < BLACK_PIXEL_COUNT_THRESHOLD; >> } >> >> private String constructImageFileName(String fontName, int fontStyle, int code, String suffix) >> { >> return fontName + "_" + getFontStyle(fontStyle) + "_" + code + "_" + suffix + ".png"; >> } >> >> public void runTest(boolean createImages) throws IOException >> { >> List badCharacters = new ArrayList(); >> for (String[] testedString : testedStrings) >> { >> for (String fontName : fontNames) >> { >> for (int fontStyle : fontStyles) >> { >> System.out.format("check string %s rendered by font %s with style %s\n", testedString[1], fontName, >> getFontStyle(fontStyle)); >> for (int i = 0; i < testedString[1].length(); i++) >> { >> String str = testedString[1].substring(i, 1 + i); >> int code = str.charAt(0); >> System.out.print(code + "\t"); >> BufferedImage src = createTestImage(str, fontName, fontStyle); >> BufferedImage dst = createDestinationImage(src); >> removeHorizontalLines(dst); >> removeVerticalLines(dst); >> >> if (createImages /*|| true*/) >> { >> ImageIO.write(src, "png", >> new File(constructImageFileName(fontName, fontStyle, code, "scr"))); >> ImageIO.write(dst, "png", >> new File(constructImageFileName(fontName, fontStyle, code, "dst"))); >> } >> >> if (isImageAlmostEmpty(dst)) >> { >> System.out.println("*** Error in rendering of character with code: " + code); >> badCharacters.add(Integer.valueOf(code)); >> } >> } >> System.out.println(); >> } >> } >> } >> // if at least one character is not rendered properly throw an exception >> if (!badCharacters.isEmpty()) >> { >> throw new RuntimeException("There are some broken characters: " + badCharacters.toString()); >> } >> System.out.println("done!"); >> } >> >> public static void main(String[] args) throws IOException >> { >> new InternationalFontsStyles().runTest(Arrays.asList(args).contains("-create-images")); >> } >> } > >> diff -r fd09f4a3b767 ChangeLog >> --- a/ChangeLog Sun Jan 09 00:43:01 2011 +0000 >> +++ b/ChangeLog Mon Jan 17 16:09:19 2011 +0100 >> @@ -1,3 +1,9 @@ >> +2011-01-17 Pavel Tisnovsky >> + >> + * patches/icedtea-jtreg-international-fonts.patch: >> + Added new font test - InternationalFontsStyles >> + Added copyright text into InternationalFontRendering >> + >> 2011-01-07 Andrew John Hughes >> >> * patches/jtreg-TestXEmbedServer-fix.patch: >> diff -r fd09f4a3b767 patches/icedtea-jtreg-international-fonts.patch >> --- a/patches/icedtea-jtreg-international-fonts.patch Sun Jan 09 00:43:01 2011 +0000 >> +++ b/patches/icedtea-jtreg-international-fonts.patch Mon Jan 17 16:09:19 2011 +0100 >> @@ -1,6 +1,25 @@ >> ---- /dev/null 2010-06-29 14:56:30.329576932 +0200 >> -+++ openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsRendering.java 2010-11-01 11:27:46.000000000 +0100 >> -@@ -0,0 +1,192 @@ >> +--- /dev/null 2010-06-29 11:10:08.737208357 +0200 >> ++++ openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsRendering.java 2011-01-17 16:01:02.000000000 +0100 >> +@@ -0,0 +1,211 @@ >> ++/* >> ++ * Copyright 2010 Red Hat, Inc. All Rights Reserved. >> ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. >> ++ * >> ++ * This code is free software; you can redistribute it and/or modify it >> ++ * under the terms of the GNU General Public License version 2 only, as >> ++ * published by the Free Software Foundation. >> ++ * >> ++ * This code is distributed in the hope that it will be useful, but WITHOUT >> ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or >> ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License >> ++ * version 2 for more details (a copy is included in the LICENSE file that >> ++ * accompanied this code). >> ++ * >> ++ * You should have received a copy of the GNU General Public License version >> ++ * 2 along with this work; if not, write to the Free Software Foundation, >> ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. >> ++ */ >> ++ >> +import java.awt.Color; >> +import java.awt.Font; >> +import java.awt.Graphics2D; >> @@ -193,3 +212,283 @@ >> + } >> +} >> + >> +--- /dev/null 2010-06-29 11:10:08.737208357 +0200 >> ++++ openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsStyles.java 2011-01-17 16:01:18.000000000 +0100 >> +@@ -0,0 +1,277 @@ >> ++/* >> ++ * Copyright 2011 Red Hat, Inc. All Rights Reserved. >> ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. >> ++ * >> ++ * This code is free software; you can redistribute it and/or modify it >> ++ * under the terms of the GNU General Public License version 2 only, as >> ++ * published by the Free Software Foundation. >> ++ * >> ++ * This code is distributed in the hope that it will be useful, but WITHOUT >> ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or >> ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License >> ++ * version 2 for more details (a copy is included in the LICENSE file that >> ++ * accompanied this code). >> ++ * >> ++ * You should have received a copy of the GNU General Public License version >> ++ * 2 along with this work; if not, write to the Free Software Foundation, >> ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. >> ++ */ >> ++ >> ++import java.awt.Color; >> ++import java.awt.Font; >> ++import java.awt.Graphics2D; >> ++import java.awt.RenderingHints; >> ++import java.awt.image.BufferedImage; >> ++import java.io.File; >> ++import java.io.IOException; >> ++import java.util.Arrays; >> ++import java.util.List; >> ++import java.util.ArrayList; >> ++ >> ++import javax.imageio.ImageIO; >> ++ >> ++/** >> ++ * @test >> ++ * @run main InternationalFontsStyles >> ++ * @author Pavel Tisnovsky >> ++ * >> ++ * @summary This test check if selected international characters could be >> ++ * properly rendered with various font styles and logical names. >> ++ * >> ++ * This regression test check if selected international characters >> ++ * could be properly rendered using various styles and logical font >> ++ * names - the test check rendering using all combinations of logical >> ++ * font names (Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, >> ++ * Font.DIALOG, Font.DIALOG_INPUT) and font styles (Font.PLAIN, >> ++ * Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC). >> ++ * >> ++ * The test is based on rendering certain characters from selected code >> ++ * pages into BufferedImage. >> ++ * >> ++ * When the shape of selected character does not exists or font >> ++ * configuration is broken, only empty rectangle is rendered instead of >> ++ * the selected character shape. This rectangle is filtered and then >> ++ * the destination image is tested whether it is empty (=white). >> ++ * >> ++ * If test images with rendered characters needs to be created use >> ++ * following flag: -create-images >> ++ * >> ++ */ >> ++public class InternationalFontsStyles >> ++{ >> ++ // all logical font names which are tested >> ++ private static final String[] fontNames = {Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, Font.DIALOG, Font.DIALOG_INPUT}; >> ++ >> ++ // all font styles which are tested >> ++ private static final int[] fontStyles = {Font.PLAIN, Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC}; >> ++ >> ++ // width and height of image where is each character rendered >> ++ private static int WIDTH = 200; >> ++ private static int HEIGHT = 200; >> ++ >> ++ // font size used for rendering >> ++ private static final int FONT_SIZE = 160; >> ++ >> ++ private static final int MINIMUM_HORIZONTAL_LINE_LENGTH = 70; >> ++ private static final int MINIMUM_VERTICAL_LINE_LENGTH = 80; >> ++ private static final int BLACK_WHITE_THRESHOLD = 128; >> ++ private static final int BLACK_PIXEL_COUNT_THRESHOLD = WIDTH * HEIGHT / 1000; >> ++ >> ++ private static final String[][] testedStrings = { >> ++ {"Latin-1", "abcdefABCDEF"}, >> ++ {"Latin-2", "??????????????????????????"}, >> ++ {"Cyrilic", "??????????????????"}, >> ++ {"Greek", "????????????????????????????????"}, >> ++ {"Asia-Test1", "???????????????"}, >> ++ {"Asia-Test2", "??????????????????"}, >> ++ {"Asia-Test3", "???????????????"}, >> ++ {"Asia-Test4", "???????????????"}, >> ++ }; >> ++ >> ++ /** >> ++ * Returns string containing given font style. This style could >> ++ * be PLAIN, BOLD, ITALIC or combination of these styles. >> ++ * >> ++ * @param fontStyle selected font style, eg. Font.BOLD >> ++ * @return textual representation of font style >> ++ */ >> ++ private static String getFontStyle(int fontStyle) >> ++ { >> ++ return new String[] >> ++ // 0 1 2 1+2 >> ++ { "PLAIN", "BOLD", "ITALIC", "BOLD+ITALIC" }[fontStyle]; >> ++ } >> ++ >> ++ /** >> ++ * Creates test image a renders one big character to it. >> ++ * @param str string to be rendered >> ++ * @param fontStyle selected font style >> ++ * @param fontName selected font name >> ++ * @return >> ++ */ >> ++ private BufferedImage createTestImage(String str, String fontName, int fontStyle) { >> ++ BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); >> ++ Graphics2D gc = image.createGraphics(); >> ++ gc.setBackground(Color.WHITE); >> ++ gc.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_OFF); >> ++ gc.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING, RenderingHints.VALUE_TEXT_ANTIALIAS_OFF); >> ++ gc.clearRect(0, 0, WIDTH, HEIGHT); >> ++ gc.setFont(new Font(fontName, fontStyle, FONT_SIZE)); >> ++ gc.setColor(Color.BLACK); >> ++ gc.drawString(str, 0, HEIGHT - 40); >> ++ gc.dispose(); >> ++ return image; >> ++ } >> ++ >> ++ /** >> ++ * Creates destination image and then copies data from source image to it >> ++ * @param src source image >> ++ * @return destination image as copy of source image >> ++ */ >> ++ private BufferedImage createDestinationImage(BufferedImage src) >> ++ { >> ++ BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); >> ++ src.copyData(image.getRaster()); >> ++ return image; >> ++ } >> ++ >> ++ /** >> ++ * Removes long horizontal lines from image >> ++ */ >> ++ private void removeHorizontalLines(BufferedImage image) >> ++ { >> ++ for (int y = 0; y < image.getHeight(); y++) >> ++ { >> ++ int startX = -1, endX = -1; >> ++ for (int x = 0; x < image.getWidth(); x++) >> ++ { >> ++ int color = image.getRaster().getSample(x, y, 0); >> ++ if (startX < 0 && color <= BLACK_WHITE_THRESHOLD) { >> ++ startX = x; >> ++ //System.out.println("> " + y + "\t" + x); >> ++ } >> ++ if (startX > 0 && endX < 0 && color > BLACK_WHITE_THRESHOLD) >> ++ { >> ++ endX = x; >> ++ //System.out.println("< " + y + "\t" + x); >> ++ } >> ++ } >> ++ // remove long horizontal line, but only if this line found detected in image >> ++ if (startX > 0 && endX > 0 && (endX - startX) > MINIMUM_HORIZONTAL_LINE_LENGTH) >> ++ { >> ++ for (int x = startX; x < endX; x++) { >> ++ image.getRaster().setSample(x, y, 0, 255); >> ++ } >> ++ } >> ++ } >> ++ } >> ++ >> ++ /** >> ++ * Removes long vertical lines from image >> ++ */ >> ++ private void removeVerticalLines(BufferedImage image) >> ++ { >> ++ for (int x = 0; x < image.getWidth(); x++) >> ++ { >> ++ int startY = -1, endY = -1; >> ++ for (int y = 0; y < image.getHeight(); y++) >> ++ { >> ++ int color = image.getRaster().getSample(x, y, 0); >> ++ if (startY < 0 && color <= BLACK_WHITE_THRESHOLD) >> ++ { >> ++ startY = y; >> ++ } >> ++ if (startY > 0 && endY < 0 && color > BLACK_WHITE_THRESHOLD) >> ++ { >> ++ endY = y; >> ++ //System.out.println("< " + y + "\t" + x); >> ++ } >> ++ } >> ++ // remove long vertical line, but only if this line found detected in image >> ++ if (startY > 0 && endY > 0 && (endY - startY) > MINIMUM_VERTICAL_LINE_LENGTH) >> ++ { >> ++ for (int y = startY; y < endY; y++) { >> ++ image.getRaster().setSample(x, y, 0, 255); >> ++ } >> ++ } >> ++ } >> ++ } >> ++ >> ++ /** >> ++ * Test if image is almost empty (one large white area) >> ++ * @param image >> ++ * @return >> ++ */ >> ++ private boolean isImageAlmostEmpty(BufferedImage image) >> ++ { >> ++ int blackPixelCount = 0; >> ++ for (int y = 0; y < image.getHeight(); y++) >> ++ { >> ++ for (int x = 0; x < image.getWidth(); x++) >> ++ { >> ++ if (image.getRaster().getSample(x, y, 0) < BLACK_WHITE_THRESHOLD) >> ++ { >> ++ blackPixelCount++; >> ++ } >> ++ } >> ++ } >> ++ return blackPixelCount < BLACK_PIXEL_COUNT_THRESHOLD; >> ++ } >> ++ >> ++ private String constructImageFileName(String fontName, int fontStyle, int code, String suffix) >> ++ { >> ++ return fontName + "_" + getFontStyle(fontStyle) + "_" + code + "_" + suffix + ".png"; >> ++ } >> ++ >> ++ public void runTest(boolean createImages) throws IOException >> ++ { >> ++ List badCharacters = new ArrayList(); >> ++ for (String[] testedString : testedStrings) >> ++ { >> ++ for (String fontName : fontNames) >> ++ { >> ++ for (int fontStyle : fontStyles) >> ++ { >> ++ System.out.format("check string %s rendered by font %s with style %s\n", testedString[1], fontName, >> ++ getFontStyle(fontStyle)); >> ++ for (int i = 0; i < testedString[1].length(); i++) >> ++ { >> ++ String str = testedString[1].substring(i, 1 + i); >> ++ int code = str.charAt(0); >> ++ System.out.print(code + "\t"); >> ++ BufferedImage src = createTestImage(str, fontName, fontStyle); >> ++ BufferedImage dst = createDestinationImage(src); >> ++ removeHorizontalLines(dst); >> ++ removeVerticalLines(dst); >> ++ >> ++ if (createImages /*|| true*/) >> ++ { >> ++ ImageIO.write(src, "png", >> ++ new File(constructImageFileName(fontName, fontStyle, code, "scr"))); >> ++ ImageIO.write(dst, "png", >> ++ new File(constructImageFileName(fontName, fontStyle, code, "dst"))); >> ++ } >> ++ >> ++ if (isImageAlmostEmpty(dst)) >> ++ { >> ++ System.out.println("*** Error in rendering of character with code: " + code); >> ++ badCharacters.add(Integer.valueOf(code)); >> ++ } >> ++ } >> ++ System.out.println(); >> ++ } >> ++ } >> ++ } >> ++ // if at least one character is not rendered properly throw an exception >> ++ if (!badCharacters.isEmpty()) >> ++ { >> ++ throw new RuntimeException("There are some broken characters: " + badCharacters.toString()); >> ++ } >> ++ System.out.println("done!"); >> ++ } >> ++ >> ++ public static void main(String[] args) throws IOException >> ++ { >> ++ new InternationalFontsStyles().runTest(Arrays.asList(args).contains("-create-images")); >> ++ } >> ++} > > From omajid at redhat.com Mon Jan 17 08:06:36 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 17 Jan 2011 11:06:36 -0500 Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. In-Reply-To: <4D2D15E8.6040708@redhat.com> References: <1483225093.62137.1294778392529.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <4D2CCBEC.9060009@redhat.com> <4D2D15E8.6040708@redhat.com> Message-ID: <4D34690C.6030701@redhat.com> On 01/11/2011 09:46 PM, Andrew Su wrote: > Thanks for looking it over, here is the updated patch with the said > changes. I have added some comments in-line. > diff -r dc02a605f905 netx/net/sourceforge/jnlp/NetxPanel.java > --- a/netx/net/sourceforge/jnlp/NetxPanel.java Fri Jan 07 08:00:08 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/NetxPanel.java Tue Jan 11 21:45:49 2011 -0500 ; > @@ -68,6 +69,12 @@ > super.run(); > } > > + @Override > + protected void showAppletException(Throwable t) { > + AppletLog.log(t); // log the exception Please remove this in-line comment. It doesnt add anything that's isn't already clear. Perhaps a function level comment explaining what types of exceptions are this function logs might be better. > + super.showAppletException(t); > + } > + > //Overriding to use Netx classloader. You might need to relax visibility > //in sun.applet.AppletPanel for runLoader(). > protected void runLoader() { > diff -r dc02a605f905 netx/net/sourceforge/jnlp/debug/AppletLog.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/debug/AppletLog.java Tue Jan 11 21:45:49 2011 -0500 > @@ -0,0 +1,48 @@ > +package net.sourceforge.jnlp.debug; > + > +import java.io.ByteArrayOutputStream; > +import java.io.IOException; > +import java.io.PrintStream; > +import java.util.logging.FileHandler; > +import java.util.logging.Level; > +import java.util.logging.Logger; > +import java.util.logging.XMLFormatter; > + > +/** > + * This class writes log information to file. > + * @author Andrew Su (asu at redhat.com,andrew.su at utoronto.ca) > + * > + */ > +public class AppletLog extends Log { Is there a reason this has to be public? I recommend moving this class (and Log) to net.sourceforge.jnlp package and making it package-private. > + public static Logger logger; Please avoid using public static objects. This is likely to lead to security issues. An untrusted applet may be able to access this logger and grab the stream, reading potentially sensitive information. > + > + static { > + try { > + // If logging is enabled, we create logger. > + if (enableLogging) { > + String fn = icedteaLogDir + "Plugin" + java.lang.System.currentTimeMillis() + ".log"; If I understand this correctly, every applet creates a new log file. Is there anything that cleans logs up? You may want to add a FIXME or a TODO here noting this. Is there any specific reason you use "Plugin" as opposed to "plugin"? > + boolean append = false; > + FileHandler fh = new FileHandler(fn, append); > + fh.setFormatter(new XMLFormatter()); > + String logClassName = AppletLog.class.getName(); > + logger = Logger.getLogger(logClassName); > + logger.setLevel(Level.ALL); > + logger.addHandler(fh); > + } > + } catch (IOException e) { > + e.printStackTrace(); If an exception occurs during setup of logging, shouldn't logging be disabled? I am not sure what happens here if fh = new FileHandler() throws an exception. > diff -r dc02a605f905 netx/net/sourceforge/jnlp/debug/Log.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/debug/Log.java Tue Jan 11 21:45:49 2011 -0500 > @@ -0,0 +1,43 @@ > +package net.sourceforge.jnlp.debug; > + > +import java.io.File; > + > +import net.sourceforge.jnlp.config.DeploymentConfiguration; > +import net.sourceforge.jnlp.runtime.JNLPRuntime; > + > +/** > + * This file provides the information required to do logging. > + * @author Andrew Su (asu at redhat.com,andrew.su at utoronto.ca) > + * > + */ > +public class Log { If you can, please make this class non-public. > + > + // Directory where the logs are stored. > + public static String icedteaLogDir; > + Please make these fields private (or protected). An attacker might be able to figure out $HOME from this log dir. > + public static boolean enableLogging = false; > + public static boolean enableTracing = false; > + [snip] > + Log() {} > + If you dont want this class to be initialized, perhaps make it abstract? Cheers, Omair From ptisnovs at redhat.com Mon Jan 17 08:47:49 2011 From: ptisnovs at redhat.com (Pavel Tisnovsky) Date: Mon, 17 Jan 2011 17:47:49 +0100 Subject: Reviewer needed - new regression test for checking font rendering & addition of copyright text to existing test In-Reply-To: <20110117154358.GC13471@rivendell.middle-earth.co.uk> References: <4D345FCB.8000900@redhat.com> <20110117154358.GC13471@rivendell.middle-earth.co.uk> Message-ID: <4D3472B5.6050306@redhat.com> Dr Andrew John Hughes wrote: > On 16:27 Mon 17 Jan , Pavel Tisnovsky wrote: >> Hi all, >> >> I'd like to add new regression test which check proper rendering of >> international fonts using various logical font names and font styles. >> This new test is stored in attachment as [InternationalFontsStyles.java] >> (for review) and it is also part of icedtea-jtreg-international-fonts.patch. >> >> I also added copyright text into existing test >> InternationalFontRendering..java. Both changes are included as hg diff >> done against recent IcedTea6 [hg_diff]. >> >> Can anyone please review these changes? >> >> Thank you in advance >> Pavel > > Couple of points: > > * I think the characters used should use the Unicode escape notation (\uXXXX). > Here in the mail, at least, they are just displaying as ?????. > * You don't include any change to Makefile.am to actually apply the patch. > > Also for future reference, the ChangeLog should be in the body of the > e-mail not the patch, when posting to the list, so others can more > easily apply and test the patch. > Hi Andrew and all, here are [InternationalFontsStyles.java] updated version of new regression test I'd like to add to IcedTea6. hg diff containing changes in icedtea-jtreg-international-fonts.patch is stored in [hg_diff]. Please note that the patch file mentioned above already exists, so no changes has to be made in Makefile.am. This version uses escape notation of Unicode (non-ASCII) characters and I've also changed recent test InternationalFontRendering.java to use this notation too. Excerpt from ChangeLog: 2011-01-17 Pavel Tisnovsky * patches/icedtea-jtreg-international-fonts.patch: Added new font test - InternationalFontsStyles Added copyright text into InternationalFontRendering 2011-01-07 Andrew John Hughes Could you please review this version? Thank you in advance Pavel -------------- next part -------------- An embedded and charset-unspecified text was scrubbed... Name: hg_diff Url: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110117/75368ac3/hg_diff.ksh -------------- next part -------------- A non-text attachment was scrubbed... Name: InternationalFontsStyles.java Type: text/x-java Size: 11029 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110117/75368ac3/InternationalFontsStyles.java From ahughes at redhat.com Mon Jan 17 09:00:55 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Mon, 17 Jan 2011 17:00:55 +0000 Subject: Request to backport 6736649 and 6797139 In-Reply-To: <4D3454D9.7040200@redhat.com> References: <4D30CFB1.6050705@redhat.com> <20110117141006.GA13471@rivendell.middle-earth.co.uk> <4D3454D9.7040200@redhat.com> Message-ID: <20110117170055.GD13471@rivendell.middle-earth.co.uk> On 09:40 Mon 17 Jan , Omair Majid wrote: > On 01/17/2011 09:10 AM, Dr Andrew John Hughes wrote: > > On 17:35 Fri 14 Jan , Omair Majid wrote: > >> I would like to backport the following two changesets to openjdk6: > >> > >> changeset: 624:e78c2f17a606 > >> user: mlapshin > >> date: Tue Aug 26 12:16:23 2008 +0400 > >> summary: 6736649: > >> test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on > >> Linux > >> > >> changeset: 1637:281fbd82a971 > >> user: alexp > >> date: Wed Sep 02 17:47:19 2009 +0400 > >> summary: 6797139: JButton title is truncating for some strings > >> irrespective of preferred size. > >> > >> Together, these changesets fix a bug where some strings are incorrectly > >> being truncated. > >> > > > > I don't see either of these in IcedTea6. Please add them there first before > > trying to upstream them. > > > > I was going to add them to IcedTea6 as soon as Joe approved them for > openjdk6. Can I assume you are okay with adding it to IcedTea6 without > waiting for Joe's comments? Post the patch and we can make that decision :-) > The reason I ping openjdk6 is that they are > much more likely to notice things like accidental conflicts with specs. > There's no reason the patch can't be upstream concurrently to OpenJDK6, but the first priority should be to IcedTea6 as that's what gets packaged in GNU/Linux distributions and consumed by end users. IME, it's more likely that issues will be picked up through general IcedTea6 use by developers and distro usage. It's nice to get stuff into OpenJDK too, but it takes time, firstly for it to be approved and then for it to actually be released. b21 still hasn't been released, for example. > Cheers, > Omair -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Mon Jan 17 09:15:36 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Mon, 17 Jan 2011 17:15:36 +0000 Subject: Reviewer needed - new regression test for checking font rendering & addition of copyright text to existing test In-Reply-To: <4D34732E.5000906@redhat.com> References: <4D345FCB.8000900@redhat.com> <20110117154358.GC13471@rivendell.middle-earth.co.uk> <4D34732E.5000906@redhat.com> Message-ID: <20110117171535.GF13471@rivendell.middle-earth.co.uk> On 17:49 Mon 17 Jan , Pavel Tisnovsky wrote: > Dr Andrew John Hughes wrote: > > On 16:27 Mon 17 Jan , Pavel Tisnovsky wrote: > >> Hi all, > >> > >> I'd like to add new regression test which check proper rendering of > >> international fonts using various logical font names and font styles. > >> This new test is stored in attachment as [InternationalFontsStyles.java] > >> (for review) and it is also part of icedtea-jtreg-international-fonts.patch. > >> > >> I also added copyright text into existing test > >> InternationalFontRendering..java. Both changes are included as hg diff > >> done against recent IcedTea6 [hg_diff]. > >> > >> Can anyone please review these changes? > >> > >> Thank you in advance > >> Pavel > > > > Couple of points: > > > > * I think the characters used should use the Unicode escape notation (\uXXXX). > > Here in the mail, at least, they are just displaying as ?????. > > * You don't include any change to Makefile.am to actually apply the patch. > > > > Also for future reference, the ChangeLog should be in the body of the > > e-mail not the patch, when posting to the list, so others can more > > easily apply and test the patch. > > > > Hi Andrew and all, > > here are [InternationalFontsStyles.java] updated version of new > regression test I'd like to add to IcedTea6. hg diff containing changes > in icedtea-jtreg-international-fonts.patch is stored in [hg_diff]. > Please note that the patch file mentioned above already exists, so no > changes has to be made in Makefile.am. > Ok, can we please have a fresh patch for this new test? And as mentioned before, no 'icedtea-' prefix on the new patch. > This version uses escape notation of Unicode (non-ASCII) characters and > I've also changed recent test InternationalFontRendering.java to use > this notation too. > > Excerpt from ChangeLog: > 2011-01-17 Pavel Tisnovsky > > * patches/icedtea-jtreg-international-fonts.patch: > Added new font test - InternationalFontsStyles > Added copyright text into InternationalFontRendering > > 2011-01-07 Andrew John Hughes > > Could you please review this version? > > Thank you in advance > Pavel > > diff -r fd09f4a3b767 patches/icedtea-jtreg-international-fonts.patch > --- a/patches/icedtea-jtreg-international-fonts.patch Sun Jan 09 00:43:01 2011 +0000 > +++ b/patches/icedtea-jtreg-international-fonts.patch Mon Jan 17 17:24:30 2011 +0100 > @@ -1,6 +1,25 @@ > ---- /dev/null 2010-06-29 14:56:30.329576932 +0200 > -+++ openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsRendering.java 2010-11-01 11:27:46.000000000 +0100 > -@@ -0,0 +1,192 @@ > +--- /dev/null 2010-06-29 11:10:08.737208357 +0200 > ++++ openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsRendering.java 2011-01-17 17:06:44.452369000 +0100 > +@@ -0,0 +1,211 @@ > ++/* > ++ * Copyright 2010 Red Hat, Inc. All Rights Reserved. > ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. > ++ * > ++ * This code is free software; you can redistribute it and/or modify it > ++ * under the terms of the GNU General Public License version 2 only, as > ++ * published by the Free Software Foundation. > ++ * > ++ * This code is distributed in the hope that it will be useful, but WITHOUT > ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or > ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License > ++ * version 2 for more details (a copy is included in the LICENSE file that > ++ * accompanied this code). > ++ * > ++ * You should have received a copy of the GNU General Public License version > ++ * 2 along with this work; if not, write to the Free Software Foundation, > ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. > ++ */ > ++ > +import java.awt.Color; > +import java.awt.Font; > +import java.awt.Graphics2D; > @@ -51,13 +70,13 @@ > + > + private static final String[][] testedStrings = { > + {"Latin-1", "abcdefABCDEF"}, > -+ {"Latin-2", "??????????????????????????"}, > -+ {"Cyrilic", "??????????????????"}, > -+ {"Greek", "????????????????????????????????"}, > -+ {"Asia-Test1", "???????????????"}, > -+ {"Asia-Test2", "??????????????????"}, > -+ {"Asia-Test3", "???????????????"}, > -+ {"Asia-Test4", "???????????????"}, > ++ {"Latin-2", "\u011b\u0161\u010d\u0159\u017e\u00fd\u00e1\u00ed\u00e9\u00fa\u016f\u013e\u0148"}, > ++ {"Cyrilic", "\u0414\u0417\u0418\u0472\u0424\u0425\u0470\u0460\u0426"}, > ++ {"Greek", "\u03b2\u03be\u03b3\u03b4\u03c0\u03b5\u03c1\u03b6\u03a3\u03c3\u03c2\u03b7\u03c4\u03b8\u03c5\u03a9"}, > ++ {"Asia-Test1", "\u4f53\u4e2d\u6587\u7b26\u53f7"}, > ++ {"Asia-Test2", "\u7e41\u9ad4\u4e2d\u6587\u7b26\u865f"}, > ++ {"Asia-Test3", "\u65e5\u672c\u306e\u8c61\u5fb4"}, > ++ {"Asia-Test4", "\ud55c\uad6d\uc5b4\uae30\ud638"}, > + }; > + > + /** > @@ -193,3 +212,283 @@ > + } > +} > + > +--- /dev/null 2010-06-29 11:10:08.737208357 +0200 > ++++ openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsStyles.java 2011-01-17 17:06:44.452369000 +0100 > +@@ -0,0 +1,277 @@ > ++/* > ++ * Copyright 2011 Red Hat, Inc. All Rights Reserved. > ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. > ++ * > ++ * This code is free software; you can redistribute it and/or modify it > ++ * under the terms of the GNU General Public License version 2 only, as > ++ * published by the Free Software Foundation. > ++ * > ++ * This code is distributed in the hope that it will be useful, but WITHOUT > ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or > ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License > ++ * version 2 for more details (a copy is included in the LICENSE file that > ++ * accompanied this code). > ++ * > ++ * You should have received a copy of the GNU General Public License version > ++ * 2 along with this work; if not, write to the Free Software Foundation, > ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. > ++ */ > ++ > ++import java.awt.Color; > ++import java.awt.Font; > ++import java.awt.Graphics2D; > ++import java.awt.RenderingHints; > ++import java.awt.image.BufferedImage; > ++import java.io.File; > ++import java.io.IOException; > ++import java.util.Arrays; > ++import java.util.List; > ++import java.util.ArrayList; > ++ > ++import javax.imageio.ImageIO; > ++ > ++/** > ++ * @test > ++ * @run main InternationalFontsStyles > ++ * @author Pavel Tisnovsky > ++ * > ++ * @summary This test check if selected international characters could be > ++ * properly rendered with various font styles and logical names. > ++ * > ++ * This regression test check if selected international characters > ++ * could be properly rendered using various styles and logical font > ++ * names - the test check rendering using all combinations of logical > ++ * font names (Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, > ++ * Font.DIALOG, Font.DIALOG_INPUT) and font styles (Font.PLAIN, > ++ * Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC). > ++ * > ++ * The test is based on rendering certain characters from selected code > ++ * pages into BufferedImage. > ++ * > ++ * When the shape of selected character does not exists or font > ++ * configuration is broken, only empty rectangle is rendered instead of > ++ * the selected character shape. This rectangle is filtered and then > ++ * the destination image is tested whether it is empty (=white). > ++ * > ++ * If test images with rendered characters needs to be created use > ++ * following flag: -create-images > ++ * > ++ */ > ++public class InternationalFontsStyles > ++{ > ++ // all logical font names which are tested > ++ private static final String[] fontNames = {Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, Font.DIALOG, Font.DIALOG_INPUT}; > ++ > ++ // all font styles which are tested > ++ private static final int[] fontStyles = {Font.PLAIN, Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC}; > ++ > ++ // width and height of image where is each character rendered > ++ private static int WIDTH = 200; > ++ private static int HEIGHT = 200; > ++ > ++ // font size used for rendering > ++ private static final int FONT_SIZE = 160; > ++ > ++ private static final int MINIMUM_HORIZONTAL_LINE_LENGTH = 70; > ++ private static final int MINIMUM_VERTICAL_LINE_LENGTH = 80; > ++ private static final int BLACK_WHITE_THRESHOLD = 128; > ++ private static final int BLACK_PIXEL_COUNT_THRESHOLD = WIDTH * HEIGHT / 1000; > ++ > ++ private static final String[][] testedStrings = { > ++ {"Latin-1", "abcdefABCDEF"}, > ++ {"Latin-2", "\u011b\u0161\u010d\u0159\u017e\u00fd\u00e1\u00ed\u00e9\u00fa\u016f\u013e\u0148"}, > ++ {"Cyrilic", "\u0414\u0417\u0418\u0472\u0424\u0425\u0470\u0460\u0426"}, > ++ {"Greek", "\u03b2\u03be\u03b3\u03b4\u03c0\u03b5\u03c1\u03b6\u03a3\u03c3\u03c2\u03b7\u03c4\u03b8\u03c5\u03a9"}, > ++ {"Asia-Test1", "\u4f53\u4e2d\u6587\u7b26\u53f7"}, > ++ {"Asia-Test2", "\u7e41\u9ad4\u4e2d\u6587\u7b26\u865f"}, > ++ {"Asia-Test3", "\u65e5\u672c\u306e\u8c61\u5fb4"}, > ++ {"Asia-Test4", "\ud55c\uad6d\uc5b4\uae30\ud638"}, > ++ }; > ++ > ++ /** > ++ * Returns string containing given font style. This style could > ++ * be PLAIN, BOLD, ITALIC or combination of these styles. > ++ * > ++ * @param fontStyle selected font style, eg. Font.BOLD > ++ * @return textual representation of font style > ++ */ > ++ private static String getFontStyle(int fontStyle) > ++ { > ++ return new String[] > ++ // 0 1 2 1+2 > ++ { "PLAIN", "BOLD", "ITALIC", "BOLD+ITALIC" }[fontStyle]; > ++ } > ++ > ++ /** > ++ * Creates test image a renders one big character to it. > ++ * @param str string to be rendered > ++ * @param fontStyle selected font style > ++ * @param fontName selected font name > ++ * @return > ++ */ > ++ private BufferedImage createTestImage(String str, String fontName, int fontStyle) { > ++ BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); > ++ Graphics2D gc = image.createGraphics(); > ++ gc.setBackground(Color.WHITE); > ++ gc.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_OFF); > ++ gc.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING, RenderingHints.VALUE_TEXT_ANTIALIAS_OFF); > ++ gc.clearRect(0, 0, WIDTH, HEIGHT); > ++ gc.setFont(new Font(fontName, fontStyle, FONT_SIZE)); > ++ gc.setColor(Color.BLACK); > ++ gc.drawString(str, 0, HEIGHT - 40); > ++ gc.dispose(); > ++ return image; > ++ } > ++ > ++ /** > ++ * Creates destination image and then copies data from source image to it > ++ * @param src source image > ++ * @return destination image as copy of source image > ++ */ > ++ private BufferedImage createDestinationImage(BufferedImage src) > ++ { > ++ BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); > ++ src.copyData(image.getRaster()); > ++ return image; > ++ } > ++ > ++ /** > ++ * Removes long horizontal lines from image > ++ */ > ++ private void removeHorizontalLines(BufferedImage image) > ++ { > ++ for (int y = 0; y < image.getHeight(); y++) > ++ { > ++ int startX = -1, endX = -1; > ++ for (int x = 0; x < image.getWidth(); x++) > ++ { > ++ int color = image.getRaster().getSample(x, y, 0); > ++ if (startX < 0 && color <= BLACK_WHITE_THRESHOLD) { > ++ startX = x; > ++ //System.out.println("> " + y + "\t" + x); > ++ } > ++ if (startX > 0 && endX < 0 && color > BLACK_WHITE_THRESHOLD) > ++ { > ++ endX = x; > ++ //System.out.println("< " + y + "\t" + x); > ++ } > ++ } > ++ // remove long horizontal line, but only if this line found detected in image > ++ if (startX > 0 && endX > 0 && (endX - startX) > MINIMUM_HORIZONTAL_LINE_LENGTH) > ++ { > ++ for (int x = startX; x < endX; x++) { > ++ image.getRaster().setSample(x, y, 0, 255); > ++ } > ++ } > ++ } > ++ } > ++ > ++ /** > ++ * Removes long vertical lines from image > ++ */ > ++ private void removeVerticalLines(BufferedImage image) > ++ { > ++ for (int x = 0; x < image.getWidth(); x++) > ++ { > ++ int startY = -1, endY = -1; > ++ for (int y = 0; y < image.getHeight(); y++) > ++ { > ++ int color = image.getRaster().getSample(x, y, 0); > ++ if (startY < 0 && color <= BLACK_WHITE_THRESHOLD) > ++ { > ++ startY = y; > ++ } > ++ if (startY > 0 && endY < 0 && color > BLACK_WHITE_THRESHOLD) > ++ { > ++ endY = y; > ++ //System.out.println("< " + y + "\t" + x); > ++ } > ++ } > ++ // remove long vertical line, but only if this line found detected in image > ++ if (startY > 0 && endY > 0 && (endY - startY) > MINIMUM_VERTICAL_LINE_LENGTH) > ++ { > ++ for (int y = startY; y < endY; y++) { > ++ image.getRaster().setSample(x, y, 0, 255); > ++ } > ++ } > ++ } > ++ } > ++ > ++ /** > ++ * Test if image is almost empty (one large white area) > ++ * @param image > ++ * @return > ++ */ > ++ private boolean isImageAlmostEmpty(BufferedImage image) > ++ { > ++ int blackPixelCount = 0; > ++ for (int y = 0; y < image.getHeight(); y++) > ++ { > ++ for (int x = 0; x < image.getWidth(); x++) > ++ { > ++ if (image.getRaster().getSample(x, y, 0) < BLACK_WHITE_THRESHOLD) > ++ { > ++ blackPixelCount++; > ++ } > ++ } > ++ } > ++ return blackPixelCount < BLACK_PIXEL_COUNT_THRESHOLD; > ++ } > ++ > ++ private String constructImageFileName(String fontName, int fontStyle, int code, String suffix) > ++ { > ++ return fontName + "_" + getFontStyle(fontStyle) + "_" + code + "_" + suffix + ".png"; > ++ } > ++ > ++ public void runTest(boolean createImages) throws IOException > ++ { > ++ List badCharacters = new ArrayList(); > ++ for (String[] testedString : testedStrings) > ++ { > ++ for (String fontName : fontNames) > ++ { > ++ for (int fontStyle : fontStyles) > ++ { > ++ System.out.format("check string %s rendered by font %s with style %s\n", testedString[1], fontName, > ++ getFontStyle(fontStyle)); > ++ for (int i = 0; i < testedString[1].length(); i++) > ++ { > ++ String str = testedString[1].substring(i, 1 + i); > ++ int code = str.charAt(0); > ++ System.out.print(code + "\t"); > ++ BufferedImage src = createTestImage(str, fontName, fontStyle); > ++ BufferedImage dst = createDestinationImage(src); > ++ removeHorizontalLines(dst); > ++ removeVerticalLines(dst); > ++ > ++ if (createImages /*|| true*/) > ++ { > ++ ImageIO.write(src, "png", > ++ new File(constructImageFileName(fontName, fontStyle, code, "scr"))); > ++ ImageIO.write(dst, "png", > ++ new File(constructImageFileName(fontName, fontStyle, code, "dst"))); > ++ } > ++ > ++ if (isImageAlmostEmpty(dst)) > ++ { > ++ System.out.println("*** Error in rendering of character with code: " + code); > ++ badCharacters.add(Integer.valueOf(code)); > ++ } > ++ } > ++ System.out.println(); > ++ } > ++ } > ++ } > ++ // if at least one character is not rendered properly throw an exception > ++ if (!badCharacters.isEmpty()) > ++ { > ++ throw new RuntimeException("There are some broken characters: " + badCharacters.toString()); > ++ } > ++ System.out.println("done!"); > ++ } > ++ > ++ public static void main(String[] args) throws IOException > ++ { > ++ new InternationalFontsStyles().runTest(Arrays.asList(args).contains("-create-images")); > ++ } > ++} > > /* > * Copyright 2011 Red Hat, Inc. All Rights Reserved. > * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. > * > * This code is free software; you can redistribute it and/or modify it > * under the terms of the GNU General Public License version 2 only, as > * published by the Free Software Foundation. > * > * This code is distributed in the hope that it will be useful, but WITHOUT > * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or > * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License > * version 2 for more details (a copy is included in the LICENSE file that > * accompanied this code). > * > * You should have received a copy of the GNU General Public License version > * 2 along with this work; if not, write to the Free Software Foundation, > * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. > */ > > import java.awt.Color; > import java.awt.Font; > import java.awt.Graphics2D; > import java.awt.RenderingHints; > import java.awt.image.BufferedImage; > import java.io.File; > import java.io.IOException; > import java.util.Arrays; > import java.util.List; > import java.util.ArrayList; > > import javax.imageio.ImageIO; > > /** > * @test > * @run main InternationalFontsStyles > * @author Pavel Tisnovsky > * > * @summary This test check if selected international characters could be > * properly rendered with various font styles and logical names. > * > * This regression test check if selected international characters > * could be properly rendered using various styles and logical font > * names - the test check rendering using all combinations of logical > * font names (Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, > * Font.DIALOG, Font.DIALOG_INPUT) and font styles (Font.PLAIN, > * Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC). > * > * The test is based on rendering certain characters from selected code > * pages into BufferedImage. > * > * When the shape of selected character does not exists or font > * configuration is broken, only empty rectangle is rendered instead of > * the selected character shape. This rectangle is filtered and then > * the destination image is tested whether it is empty (=white). > * > * If test images with rendered characters needs to be created use > * following flag: -create-images > * > */ > public class InternationalFontsStyles > { > // all logical font names which are tested > private static final String[] fontNames = {Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, Font.DIALOG, Font.DIALOG_INPUT}; > > // all font styles which are tested > private static final int[] fontStyles = {Font.PLAIN, Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC}; > > // width and height of image where is each character rendered > private static int WIDTH = 200; > private static int HEIGHT = 200; > > // font size used for rendering > private static final int FONT_SIZE = 160; > > private static final int MINIMUM_HORIZONTAL_LINE_LENGTH = 70; > private static final int MINIMUM_VERTICAL_LINE_LENGTH = 80; > private static final int BLACK_WHITE_THRESHOLD = 128; > private static final int BLACK_PIXEL_COUNT_THRESHOLD = WIDTH * HEIGHT / 1000; > > private static final String[][] testedStrings = { > {"Latin-1", "abcdefABCDEF"}, > {"Latin-2", "\u011b\u0161\u010d\u0159\u017e\u00fd\u00e1\u00ed\u00e9\u00fa\u016f\u013e\u0148"}, > {"Cyrilic", "\u0414\u0417\u0418\u0472\u0424\u0425\u0470\u0460\u0426"}, > {"Greek", "\u03b2\u03be\u03b3\u03b4\u03c0\u03b5\u03c1\u03b6\u03a3\u03c3\u03c2\u03b7\u03c4\u03b8\u03c5\u03a9"}, > {"Asia-Test1", "\u4f53\u4e2d\u6587\u7b26\u53f7"}, > {"Asia-Test2", "\u7e41\u9ad4\u4e2d\u6587\u7b26\u865f"}, > {"Asia-Test3", "\u65e5\u672c\u306e\u8c61\u5fb4"}, > {"Asia-Test4", "\ud55c\uad6d\uc5b4\uae30\ud638"}, > }; > > /** > * Returns string containing given font style. This style could > * be PLAIN, BOLD, ITALIC or combination of these styles. > * > * @param fontStyle selected font style, eg. Font.BOLD > * @return textual representation of font style > */ > private static String getFontStyle(int fontStyle) > { > return new String[] > // 0 1 2 1+2 > { "PLAIN", "BOLD", "ITALIC", "BOLD+ITALIC" }[fontStyle]; > } > > /** > * Creates test image a renders one big character to it. > * @param str string to be rendered > * @param fontStyle selected font style > * @param fontName selected font name > * @return > */ > private BufferedImage createTestImage(String str, String fontName, int fontStyle) { > BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); > Graphics2D gc = image.createGraphics(); > gc.setBackground(Color.WHITE); > gc.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_OFF); > gc.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING, RenderingHints.VALUE_TEXT_ANTIALIAS_OFF); > gc.clearRect(0, 0, WIDTH, HEIGHT); > gc.setFont(new Font(fontName, fontStyle, FONT_SIZE)); > gc.setColor(Color.BLACK); > gc.drawString(str, 0, HEIGHT - 40); > gc.dispose(); > return image; > } > > /** > * Creates destination image and then copies data from source image to it > * @param src source image > * @return destination image as copy of source image > */ > private BufferedImage createDestinationImage(BufferedImage src) > { > BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); > src.copyData(image.getRaster()); > return image; > } > > /** > * Removes long horizontal lines from image > */ > private void removeHorizontalLines(BufferedImage image) > { > for (int y = 0; y < image.getHeight(); y++) > { > int startX = -1, endX = -1; > for (int x = 0; x < image.getWidth(); x++) > { > int color = image.getRaster().getSample(x, y, 0); > if (startX < 0 && color <= BLACK_WHITE_THRESHOLD) { > startX = x; > //System.out.println("> " + y + "\t" + x); > } > if (startX > 0 && endX < 0 && color > BLACK_WHITE_THRESHOLD) > { > endX = x; > //System.out.println("< " + y + "\t" + x); > } > } > // remove long horizontal line, but only if this line found detected in image > if (startX > 0 && endX > 0 && (endX - startX) > MINIMUM_HORIZONTAL_LINE_LENGTH) > { > for (int x = startX; x < endX; x++) { > image.getRaster().setSample(x, y, 0, 255); > } > } > } > } > > /** > * Removes long vertical lines from image > */ > private void removeVerticalLines(BufferedImage image) > { > for (int x = 0; x < image.getWidth(); x++) > { > int startY = -1, endY = -1; > for (int y = 0; y < image.getHeight(); y++) > { > int color = image.getRaster().getSample(x, y, 0); > if (startY < 0 && color <= BLACK_WHITE_THRESHOLD) > { > startY = y; > } > if (startY > 0 && endY < 0 && color > BLACK_WHITE_THRESHOLD) > { > endY = y; > //System.out.println("< " + y + "\t" + x); > } > } > // remove long vertical line, but only if this line found detected in image > if (startY > 0 && endY > 0 && (endY - startY) > MINIMUM_VERTICAL_LINE_LENGTH) > { > for (int y = startY; y < endY; y++) { > image.getRaster().setSample(x, y, 0, 255); > } > } > } > } > > /** > * Test if image is almost empty (one large white area) > * @param image > * @return > */ > private boolean isImageAlmostEmpty(BufferedImage image) > { > int blackPixelCount = 0; > for (int y = 0; y < image.getHeight(); y++) > { > for (int x = 0; x < image.getWidth(); x++) > { > if (image.getRaster().getSample(x, y, 0) < BLACK_WHITE_THRESHOLD) > { > blackPixelCount++; > } > } > } > return blackPixelCount < BLACK_PIXEL_COUNT_THRESHOLD; > } > > private String constructImageFileName(String fontName, int fontStyle, int code, String suffix) > { > return fontName + "_" + getFontStyle(fontStyle) + "_" + code + "_" + suffix + ".png"; > } > > public void runTest(boolean createImages) throws IOException > { > List badCharacters = new ArrayList(); > for (String[] testedString : testedStrings) > { > for (String fontName : fontNames) > { > for (int fontStyle : fontStyles) > { > System.out.format("check string %s rendered by font %s with style %s\n", testedString[1], fontName, > getFontStyle(fontStyle)); > for (int i = 0; i < testedString[1].length(); i++) > { > String str = testedString[1].substring(i, 1 + i); > int code = str.charAt(0); > System.out.print(code + "\t"); > BufferedImage src = createTestImage(str, fontName, fontStyle); > BufferedImage dst = createDestinationImage(src); > removeHorizontalLines(dst); > removeVerticalLines(dst); > > if (createImages /*|| true*/) > { > ImageIO.write(src, "png", > new File(constructImageFileName(fontName, fontStyle, code, "scr"))); > ImageIO.write(dst, "png", > new File(constructImageFileName(fontName, fontStyle, code, "dst"))); > } > > if (isImageAlmostEmpty(dst)) > { > System.out.println("*** Error in rendering of character with code: " + code); > badCharacters.add(Integer.valueOf(code)); > } > } > System.out.println(); > } > } > } > // if at least one character is not rendered properly throw an exception > if (!badCharacters.isEmpty()) > { > throw new RuntimeException("There are some broken characters: " + badCharacters.toString()); > } > System.out.println("done!"); > } > > public static void main(String[] args) throws IOException > { > new InternationalFontsStyles().runTest(Arrays.asList(args).contains("-create-images")); > } > } > -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at redhat.com Mon Jan 17 10:19:47 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 17 Jan 2011 13:19:47 -0500 Subject: Request to backport 6736649 and 6797139 In-Reply-To: <20110117170055.GD13471@rivendell.middle-earth.co.uk> References: <4D30CFB1.6050705@redhat.com> <20110117141006.GA13471@rivendell.middle-earth.co.uk> <4D3454D9.7040200@redhat.com> <20110117170055.GD13471@rivendell.middle-earth.co.uk> Message-ID: <4D348843.2060602@redhat.com> On 01/17/2011 12:00 PM, Dr Andrew John Hughes wrote: > On 09:40 Mon 17 Jan , Omair Majid wrote: >> On 01/17/2011 09:10 AM, Dr Andrew John Hughes wrote: >>> On 17:35 Fri 14 Jan , Omair Majid wrote: >>>> I would like to backport the following two changesets to openjdk6: >>>> >>>> changeset: 624:e78c2f17a606 >>>> user: mlapshin >>>> date: Tue Aug 26 12:16:23 2008 +0400 >>>> summary: 6736649: >>>> test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on >>>> Linux >>>> >>>> changeset: 1637:281fbd82a971 >>>> user: alexp >>>> date: Wed Sep 02 17:47:19 2009 +0400 >>>> summary: 6797139: JButton title is truncating for some strings >>>> irrespective of preferred size. >>>> >>>> Together, these changesets fix a bug where some strings are incorrectly >>>> being truncated. >>>> >>> >>> I don't see either of these in IcedTea6. Please add them there first before >>> trying to upstream them. >>> >> >> I was going to add them to IcedTea6 as soon as Joe approved them for >> openjdk6. Can I assume you are okay with adding it to IcedTea6 without >> waiting for Joe's comments? > > Post the patch and we can make that decision :-) > I have attached the patch for icedtea6. Ok to commit? Thanks, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: icedtea6-jbutton-truncation.patch Type: text/x-patch Size: 32343 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110117/94915bc6/icedtea6-jbutton-truncation.patch From asu at redhat.com Mon Jan 17 10:32:33 2011 From: asu at redhat.com (Andrew Su) Date: Mon, 17 Jan 2011 13:32:33 -0500 Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. Message-ID: <4D348B41.5030608@redhat.com> ----- Original Message ----- > From: "Omair Majid" > To: "Andrew Su" > Cc: "OpenJDK" > Sent: Monday, January 17, 2011 11:06:36 AM > Subject: Re: [RFC][IcedTea-Web]: Add Logging of applet exceptions. > On 01/11/2011 09:46 PM, Andrew Su wrote: > > Thanks for looking it over, here is the updated patch with the said > > changes. > > I have added some comments in-line. > > > diff -r dc02a605f905 netx/net/sourceforge/jnlp/NetxPanel.java > > --- a/netx/net/sourceforge/jnlp/NetxPanel.java Fri Jan 07 08:00:08 > > 2011 -0500 > > +++ b/netx/net/sourceforge/jnlp/NetxPanel.java Tue Jan 11 21:45:49 > > 2011 -0500 > ; > > @@ -68,6 +69,12 @@ > > super.run(); > > } > > > > + @Override > > + protected void showAppletException(Throwable t) { > > + AppletLog.log(t); // log the exception > > Please remove this in-line comment. It doesnt add anything that's > isn't > already clear. Perhaps a function level comment explaining what types > of > exceptions are this function logs might be better. Removed + fixed. > > > + super.showAppletException(t); > > + } > > + > > //Overriding to use Netx classloader. You might need to relax > > visibility > > //in sun.applet.AppletPanel for runLoader(). > > protected void runLoader() { > > diff -r dc02a605f905 netx/net/sourceforge/jnlp/debug/AppletLog.java > > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > > +++ b/netx/net/sourceforge/jnlp/debug/AppletLog.java Tue Jan 11 > > 21:45:49 2011 -0500 > > @@ -0,0 +1,48 @@ > > +package net.sourceforge.jnlp.debug; > > + > > +import java.io.ByteArrayOutputStream; > > +import java.io.IOException; > > +import java.io.PrintStream; > > +import java.util.logging.FileHandler; > > +import java.util.logging.Level; > > +import java.util.logging.Logger; > > +import java.util.logging.XMLFormatter; > > + > > +/** > > + * This class writes log information to file. > > + * @author Andrew Su (asu at redhat.com,andrew.su at utoronto.ca) > > + * > > + */ > > +public class AppletLog extends Log { > > Is there a reason this has to be public? I recommend moving this class > (and Log) to net.sourceforge.jnlp package and making it > package-private. I am happy with the recommendation, changed. > > > + public static Logger logger; > > Please avoid using public static objects. This is likely to lead to > security issues. An untrusted applet may be able to access this logger > and grab the stream, reading potentially sensitive information. Changed to private. > > > + > > + static { > > + try { > > + // If logging is enabled, we create logger. > > + if (enableLogging) { > > + String fn = icedteaLogDir + "Plugin" + > > java.lang.System.currentTimeMillis() + ".log"; > > If I understand this correctly, every applet creates a new log file. No, static initialization blocks are called only once when loading the class. Unless they kill the plugin then reload another page it will use the same file. > Is > there anything that cleans logs up? You may want to add a FIXME or a > TODO here noting this. As of this moment, no. But can be added to itw-settings to clean the logs. (Similar to how we clean cache) > Is there any specific reason you use "Plugin" > as > opposed to "plugin"? The naming was a typo, meant to be lower case. Fixed. > > > + boolean append = false; > > + FileHandler fh = new FileHandler(fn, append); > > + fh.setFormatter(new XMLFormatter()); > > + String logClassName = AppletLog.class.getName(); > > + logger = Logger.getLogger(logClassName); > > + logger.setLevel(Level.ALL); > > + logger.addHandler(fh); > > + } > > + } catch (IOException e) { > > + e.printStackTrace(); > > If an exception occurs during setup of logging, shouldn't logging be > disabled? I am not sure what happens here if fh = new FileHandler() > throws an exception. Added condition on whether logger is null, if logger is null, that means we were not successful in getting the filehandle. > > > diff -r dc02a605f905 netx/net/sourceforge/jnlp/debug/Log.java > > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > > +++ b/netx/net/sourceforge/jnlp/debug/Log.java Tue Jan 11 21:45:49 > > 2011 -0500 > > @@ -0,0 +1,43 @@ > > +package net.sourceforge.jnlp.debug; > > + > > +import java.io.File; > > + > > +import net.sourceforge.jnlp.config.DeploymentConfiguration; > > +import net.sourceforge.jnlp.runtime.JNLPRuntime; > > + > > +/** > > + * This file provides the information required to do logging. > > + * @author Andrew Su (asu at redhat.com,andrew.su at utoronto.ca) > > + * > > + */ > > +public class Log { > > If you can, please make this class non-public. I've left it at package-level. > > > + > > + // Directory where the logs are stored. > > + public static String icedteaLogDir; > > + > > Please make these fields private (or protected). An attacker might be > able to figure out $HOME from this log dir. > > > + public static boolean enableLogging = false; > > + public static boolean enableTracing = false; > > + > > [snip] > > > + Log() {} > > + > > If you dont want this class to be initialized, perhaps make it > abstract? Ah, slipped my mind. Changed to abstract. Regards, Andrew -------------- next part -------------- A non-text attachment was scrubbed... Name: 20110117_add_package_to_makefile_v5.patch Type: text/x-patch Size: 4434 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110117/85fbb8d0/20110117_add_package_to_makefile_v5.patch From omajid at redhat.com Mon Jan 17 10:39:14 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 17 Jan 2011 13:39:14 -0500 Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. In-Reply-To: <4D348B41.5030608@redhat.com> References: <4D348B41.5030608@redhat.com> Message-ID: <4D348CD2.9030000@redhat.com> On 01/17/2011 01:32 PM, Andrew Su wrote: >> > + >> > + static { >> > + try { >> > + // If logging is enabled, we create logger. >> > + if (enableLogging) { >> > + String fn = icedteaLogDir + "Plugin" + >> > java.lang.System.currentTimeMillis() + ".log"; >> >> If I understand this correctly, every applet creates a new log file. > No, static initialization blocks are called only once when loading the > class. > Unless they kill the plugin then reload another page it will use the > same file. > Ok, that's much better than a log file per applet. Everything else looks good to me. Assuming that you have tested this and that there are no objections from anyone else, please go ahead and commit the patch. Thanks, Omair From asu at icedtea.classpath.org Mon Jan 17 10:44:53 2011 From: asu at icedtea.classpath.org (asu at icedtea.classpath.org) Date: Mon, 17 Jan 2011 18:44:53 +0000 Subject: /hg/icedtea-web: Add logging for applet exceptions. Message-ID: changeset 98215ab000dd in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=98215ab000dd author: Andrew Su date: Mon Jan 17 13:44:31 2011 -0500 Add logging for applet exceptions. diffstat: 4 files changed, 113 insertions(+) ChangeLog | 8 ++++ netx/net/sourceforge/jnlp/AppletLog.java | 52 ++++++++++++++++++++++++++++++ netx/net/sourceforge/jnlp/Log.java | 42 ++++++++++++++++++++++++ netx/net/sourceforge/jnlp/NetxPanel.java | 11 ++++++ diffs (145 lines): diff -r ce755342e8e8 -r 98215ab000dd ChangeLog --- a/ChangeLog Fri Jan 14 11:14:46 2011 -0500 +++ b/ChangeLog Mon Jan 17 13:44:31 2011 -0500 @@ -1,3 +1,11 @@ 2011-01-14 Andrew Su +2011-01-17 Andrew Su + + * netx/net/sourceforge/jnlp/NetxPanel.java: + (showAppletException): Override, adds logging to file then proceed + with showAppletException in sun.applet.AppletPanel. + * netx/net/sourceforge/jnlp/AppletLog.java: New class. + * netx/net/sourceforge/jnlp/Log.java: New class. + 2011-01-14 Andrew Su * Makefile.am: Added net.sourceforge.jnlp.config and diff -r ce755342e8e8 -r 98215ab000dd netx/net/sourceforge/jnlp/AppletLog.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/netx/net/sourceforge/jnlp/AppletLog.java Mon Jan 17 13:44:31 2011 -0500 @@ -0,0 +1,52 @@ +package net.sourceforge.jnlp; + +import java.io.ByteArrayOutputStream; +import java.io.PrintStream; +import java.util.logging.FileHandler; +import java.util.logging.Level; +import java.util.logging.Logger; +import java.util.logging.XMLFormatter; + +/** + * This class writes log information to file. + * + * @author Andrew Su (asu at redhat.com, andrew.su at utoronto.ca) + * + */ +class AppletLog extends Log { + private static Logger logger; + static { + try { + // If logging is enabled, we create logger. + if (enableLogging) { + String fn = icedteaLogDir + "plugin" + java.lang.System.currentTimeMillis() + ".log"; + boolean append = false; + FileHandler fh = new FileHandler(fn, append); + fh.setFormatter(new XMLFormatter()); + String logClassName = AppletLog.class.getName(); + logger = Logger.getLogger(logClassName); + logger.setLevel(Level.ALL); + logger.addHandler(fh); + } + } catch (Exception e) { + e.printStackTrace(); + } + } + + private AppletLog() { + } + + /** + * Log the exception to file. + * + * @param e Exception that was thrown. + */ + public synchronized static void log(Throwable e) { + if (enableLogging && logger != null) { + ByteArrayOutputStream baos = new ByteArrayOutputStream(); + PrintStream ps = new PrintStream(baos); + e.printStackTrace(ps); + logger.log(Level.FINE, baos.toString()); + } + } +} diff -r ce755342e8e8 -r 98215ab000dd netx/net/sourceforge/jnlp/Log.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/netx/net/sourceforge/jnlp/Log.java Mon Jan 17 13:44:31 2011 -0500 @@ -0,0 +1,42 @@ +package net.sourceforge.jnlp; + +import java.io.File; + +import net.sourceforge.jnlp.config.DeploymentConfiguration; +import net.sourceforge.jnlp.runtime.JNLPRuntime; + +/** + * This file provides the information required to do logging. + * + * @author Andrew Su (asu at redhat.com, andrew.su at utoronto.ca) + * + */ +abstract class Log { + + // Directory where the logs are stored. + protected static String icedteaLogDir; + + protected static boolean enableLogging = false; + protected static boolean enableTracing = false; + + // Prepare for logging. + static { + DeploymentConfiguration config = JNLPRuntime.getConfiguration(); + + // Check whether logging and tracing is enabled. + enableLogging = Boolean.parseBoolean(config.getProperty(DeploymentConfiguration.KEY_ENABLE_LOGGING)); + enableTracing = Boolean.parseBoolean(config.getProperty(DeploymentConfiguration.KEY_ENABLE_TRACING)); + + // Get log directory, create it if it doesn't exist. If unable to create and doesn't exist, don't log. + icedteaLogDir = config.getProperty(DeploymentConfiguration.KEY_USER_LOG_DIR); + if (icedteaLogDir != null) { + File f = new File(icedteaLogDir); + if (f.isDirectory() || f.mkdirs()) + icedteaLogDir += File.separator; + else { + enableLogging = false; + enableTracing = false; + } + } + } +} diff -r ce755342e8e8 -r 98215ab000dd netx/net/sourceforge/jnlp/NetxPanel.java --- a/netx/net/sourceforge/jnlp/NetxPanel.java Fri Jan 14 11:14:46 2011 -0500 +++ b/netx/net/sourceforge/jnlp/NetxPanel.java Mon Jan 17 13:44:31 2011 -0500 @@ -22,6 +22,7 @@ package net.sourceforge.jnlp; +import net.sourceforge.jnlp.AppletLog; import net.sourceforge.jnlp.runtime.AppThreadGroup; import net.sourceforge.jnlp.runtime.AppletInstance; import net.sourceforge.jnlp.runtime.JNLPRuntime; @@ -68,6 +69,16 @@ public class NetxPanel extends AppletVie super.run(); } + @Override + protected void showAppletException(Throwable t) { + /* + * Log any exceptions thrown while loading, initializing, starting, + * and stopping the applet. + */ + AppletLog.log(t); + super.showAppletException(t); + } + //Overriding to use Netx classloader. You might need to relax visibility //in sun.applet.AppletPanel for runLoader(). protected void runLoader() { From asu at redhat.com Mon Jan 17 10:45:56 2011 From: asu at redhat.com (Andrew Su) Date: Mon, 17 Jan 2011 13:45:56 -0500 Subject: [RFC][IcedTea-Web]: Add Logging of applet exceptions. In-Reply-To: <4D348CD2.9030000@redhat.com> References: <4D348B41.5030608@redhat.com> <4D348CD2.9030000@redhat.com> Message-ID: <4D348E64.9080806@redhat.com> On 01/17/2011 01:39 PM, Omair Majid wrote: > On 01/17/2011 01:32 PM, Andrew Su wrote: >>> > + >>> > + static { >>> > + try { >>> > + // If logging is enabled, we create logger. >>> > + if (enableLogging) { >>> > + String fn = icedteaLogDir + "Plugin" + >>> > java.lang.System.currentTimeMillis() + ".log"; >>> >>> If I understand this correctly, every applet creates a new log file. >> No, static initialization blocks are called only once when loading the >> class. >> Unless they kill the plugin then reload another page it will use the >> same file. >> > > Ok, that's much better than a log file per applet. > > Everything else looks good to me. Assuming that you have tested this > and that there are no objections from anyone else, please go ahead and > commit the patch. > Thanks for looking it over! Pushed to HEAD. > Thanks, > Omair From omajid at redhat.com Mon Jan 17 10:54:23 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 17 Jan 2011 13:54:23 -0500 Subject: Backporting S6642612 to icedtea6 Message-ID: <4D34905F.1040204@redhat.com> Hi, I would like to backport SS6642612 to icedtea6. The changeset makes the OK and Cancel buttons in JFileChooser dialogs have the same size. The patch is attached. Ok to commit? Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: icedtea6-filechooser-button-size.patch Type: text/x-patch Size: 4698 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110117/f87100ee/icedtea6-filechooser-button-size.patch From ahughes at redhat.com Mon Jan 17 10:55:48 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Mon, 17 Jan 2011 18:55:48 +0000 Subject: Request to backport 6736649 and 6797139 In-Reply-To: <4D348843.2060602@redhat.com> References: <4D30CFB1.6050705@redhat.com> <20110117141006.GA13471@rivendell.middle-earth.co.uk> <4D3454D9.7040200@redhat.com> <20110117170055.GD13471@rivendell.middle-earth.co.uk> <4D348843.2060602@redhat.com> Message-ID: <20110117185548.GJ13471@rivendell.middle-earth.co.uk> On 13:19 Mon 17 Jan , Omair Majid wrote: > On 01/17/2011 12:00 PM, Dr Andrew John Hughes wrote: > > On 09:40 Mon 17 Jan , Omair Majid wrote: > >> On 01/17/2011 09:10 AM, Dr Andrew John Hughes wrote: > >>> On 17:35 Fri 14 Jan , Omair Majid wrote: > >>>> I would like to backport the following two changesets to openjdk6: > >>>> > >>>> changeset: 624:e78c2f17a606 > >>>> user: mlapshin > >>>> date: Tue Aug 26 12:16:23 2008 +0400 > >>>> summary: 6736649: > >>>> test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on > >>>> Linux > >>>> > >>>> changeset: 1637:281fbd82a971 > >>>> user: alexp > >>>> date: Wed Sep 02 17:47:19 2009 +0400 > >>>> summary: 6797139: JButton title is truncating for some strings > >>>> irrespective of preferred size. > >>>> > >>>> Together, these changesets fix a bug where some strings are incorrectly > >>>> being truncated. > >>>> > >>> > >>> I don't see either of these in IcedTea6. Please add them there first before > >>> trying to upstream them. > >>> > >> > >> I was going to add them to IcedTea6 as soon as Joe approved them for > >> openjdk6. Can I assume you are okay with adding it to IcedTea6 without > >> waiting for Joe's comments? > > > > Post the patch and we can make that decision :-) > > > > I have attached the patch for icedtea6. Ok to commit? > > Thanks, > Omair The changesets seem to have a lot of whitespace changes, which make it hard to read, but as these come from the upstream changesets, there's not much to be done about that. Is it correct that the first adds the calculation of the right width and then the second removes it? > +- textRect.width += getLeftTextExtraWidth() + getRightTextExtraWidth(); > ++ textRect.width += getLeftTextExtraWidth(); I'm a little worried by the addition of an exception: > + * Returns the left side bearing of the first character of string. The > +- * left side bearing is calculated from the passed in FontMetrics. > ++ * left side bearing is calculated from the passed in > ++ * FontMetrics. If the passed in String is less than one > ++ * character, this will throw a StringIndexOutOfBoundsException exception. > + * > + * @param c JComponent that will display the string > + * @param fm FontMetrics used to measure the String width > +@@ -234,14 +245,11 @@ > + */ > + public static int getLeftSideBearing(JComponent c, FontMetrics fm, > + String string) { > +- if ((string == null) || (string.length() == 0)) { > +- return 0; > +- } > + return getLeftSideBearing(c, fm, string.charAt(0)); > + } Is this visible further up the stack? Do the new tests pass? They should be fixed to use the newer Oracle copyright notices. This is not a concern of this patch, but I notice from the diff that: > - RH661505: JPEGs with sRGB IEC61966-2.1 color profiles have wrong colors is presumably under 'backports'. Can anyone explain why this is here and not under bug fixes? > diff -r fd09f4a3b767 ChangeLog > --- a/ChangeLog Sun Jan 09 00:43:01 2011 +0000 > +++ b/ChangeLog Mon Jan 17 13:16:36 2011 -0500 > @@ -1,3 +1,10 @@ > +2011-01-17 Omair Majid > + > + Backport S6736649, S6797139. Fix RH661610 > + * Makefile.am (ICEDTEA_PATCHES): Add new patches > + * patches/openjdk/6736649-text_bearings.patch: New file. > + * patches/openjdk/6797139-jbutton_truncation.patch: Likewise. > + > 2011-01-07 Andrew John Hughes > > * patches/jtreg-TestXEmbedServer-fix.patch: > diff -r fd09f4a3b767 Makefile.am > --- a/Makefile.am Sun Jan 09 00:43:01 2011 +0000 > +++ b/Makefile.am Mon Jan 17 13:16:36 2011 -0500 > @@ -316,7 +316,9 @@ > patches/openjdk/6687968-pngimagereader_mem_leak.patch \ > patches/openjdk/6541476-png-iTXt-chunk.patch \ > patches/openjdk/6782079-png_metadata_oom.patch \ > - patches/661505-jpeg.patch > + patches/661505-jpeg.patch \ > + patches/openjdk/6736649-text_bearings.patch \ > + patches/openjdk/6797139-jbutton_truncation.patch > > if WITH_ALT_HSBUILD > ICEDTEA_PATCHES += \ > diff -r fd09f4a3b767 NEWS > --- a/NEWS Sun Jan 09 00:43:01 2011 +0000 > +++ b/NEWS Mon Jan 17 13:16:36 2011 -0500 > @@ -55,7 +55,8 @@ > - S6541476, RH665355: PNG imageio plugin incorrectly handles iTXt chunk > - S6782079: PNG: reading metadata may cause OOM on truncated images > - RH661505: JPEGs with sRGB IEC61966-2.1 color profiles have wrong colors > - > + - S6736649: test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on Linux > + - S6797139, RH661610: JButton title is truncating for some strings irrespective of preferred size > * Bug fixes > - S7003777, RH647674: JTextPane produces incorrect content after parsing the html text > - S7004655, PR590: Unable to activate (click) checkboxes in jtable > diff -r fd09f4a3b767 patches/openjdk/6736649-text_bearings.patch > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/patches/openjdk/6736649-text_bearings.patch Mon Jan 17 13:16:36 2011 -0500 > @@ -0,0 +1,112 @@ > +# HG changeset patch > +# User mlapshin > +# Date 1219738583 -14400 > +# Node ID e78c2f17a60646b8198279b2f676712094b833a0 > +# Parent c9d407ab230941d41025428b25bc5d787cf7c18f > +6736649: test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on Linux > +Summary: Now text bearings are taken into account when labelRect width is calculated > +Reviewed-by: alexp > + > +diff -r c9d407ab2309 -r e78c2f17a606 src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java > +--- openjdk/jdk/src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java Tue Aug 12 17:59:58 2008 -0700 > ++++ openjdk/jdk/src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java Tue Aug 26 12:16:23 2008 +0400 > +@@ -136,7 +136,7 @@ > + > + // accRect > + if (!getAccText().equals("")) { > +- getAccSize().setWidth(accGu.computeStringWidth(getAccContext(), > ++ getAccSize().setWidth(accGu.computeStringWidth(getAccContext(), > + getAccFontMetrics().getFont(), getAccFontMetrics(), > + getAccText())); > + getAccSize().setHeight(getAccFontMetrics().getHeight()); > +@@ -195,6 +195,7 @@ > + getHorizontalAlignment(), getVerticalAlignment(), > + getHorizontalTextPosition(), getVerticalTextPosition(), > + getViewRect(), iconRect, textRect, getGap()); > ++ textRect.width += getLeftTextExtraWidth() + getRightTextExtraWidth(); > + Rectangle labelRect = iconRect.union(textRect); > + getLabelSize().setHeight(labelRect.height); > + getLabelSize().setWidth(labelRect.width); > +diff -r c9d407ab2309 -r e78c2f17a606 src/share/classes/sun/swing/MenuItemLayoutHelper.java > +--- openjdk/jdk/src/share/classes/sun/swing/MenuItemLayoutHelper.java Tue Aug 12 17:59:58 2008 -0700 > ++++ openjdk/jdk/src/share/classes/sun/swing/MenuItemLayoutHelper.java Tue Aug 26 12:16:23 2008 +0400 > +@@ -83,6 +83,9 @@ > + private int afterCheckIconGap; > + private int minTextOffset; > + > ++ private int leftTextExtraWidth; > ++ private int rightTextExtraWidth; > ++ > + private Rectangle viewRect; > + > + private RectSize iconSize; > +@@ -143,6 +146,7 @@ > + this.checkSize = new RectSize(); > + this.arrowSize = new RectSize(); > + this.labelSize = new RectSize(); > ++ calcExtraWidths(); > + calcWidthsAndHeights(); > + setOriginalWidths(); > + calcMaxWidths(); > +@@ -151,6 +155,29 @@ > + calcMaxTextOffset(viewRect); > + } > + > ++ private void calcExtraWidths() { > ++ leftTextExtraWidth = getLeftExtraWidth(text); > ++ rightTextExtraWidth = getRightExtraWidth(text); > ++ } > ++ > ++ private int getLeftExtraWidth(String str) { > ++ int lsb = SwingUtilities2.getLeftSideBearing(mi, fm, str); > ++ if (lsb < 0) { > ++ return -lsb; > ++ } else { > ++ return 0; > ++ } > ++ } > ++ > ++ private int getRightExtraWidth(String str) { > ++ int rsb = SwingUtilities2.getRightSideBearing(mi, fm, str); > ++ if (rsb > 0) { > ++ return rsb; > ++ } else { > ++ return 0; > ++ } > ++ } > ++ > + private void setOriginalWidths() { > + iconSize.origWidth = iconSize.width; > + textSize.origWidth = textSize.width; > +@@ -286,6 +313,7 @@ > + verticalAlignment, horizontalAlignment, > + verticalTextPosition, horizontalTextPosition, > + viewRect, iconRect, textRect, gap); > ++ textRect.width += leftTextExtraWidth + rightTextExtraWidth; > + Rectangle labelRect = iconRect.union(textRect); > + labelSize.height = labelRect.height; > + labelSize.width = labelRect.width; > +@@ -727,7 +755,7 @@ > + } > + } > + > +- /** > ++ /** > + * Sets Y coordinates of text and icon > + * taking into account the vertical alignment > + */ > +@@ -1089,6 +1117,14 @@ > + this.labelSize = labelSize; > + } > + > ++ public int getLeftTextExtraWidth() { > ++ return leftTextExtraWidth; > ++ } > ++ > ++ public int getRightTextExtraWidth() { > ++ return rightTextExtraWidth; > ++ } > ++ > + /** > + * Returns false if the component is a JMenu and it is a top > + * level menu (on the menubar). > diff -r fd09f4a3b767 patches/openjdk/6797139-jbutton_truncation.patch > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/patches/openjdk/6797139-jbutton_truncation.patch Mon Jan 17 13:16:36 2011 -0500 > @@ -0,0 +1,610 @@ > +# HG changeset patch > +# User alexp > +# Date 1251899239 -14400 > +# Node ID 281fbd82a971f05fcf6f2c31cfe7db7ef74909e9 > +# Parent 935814bd43a62d1b2c6871f0298c5b59fbf54428 > +6797139: JButton title is truncating for some strings irrespective of preferred size. > +Reviewed-by: peterz > + > +diff -r 935814bd43a6 -r 281fbd82a971 src/share/classes/javax/swing/SwingUtilities.java > +--- openjdk/jdk/src/share/classes/javax/swing/SwingUtilities.java Tue Sep 01 18:51:15 2009 +0400 > ++++ openjdk/jdk/src/share/classes/javax/swing/SwingUtilities.java Wed Sep 02 17:47:19 2009 +0400 > +@@ -999,24 +999,20 @@ > + textR.height = (int) v.getPreferredSpan(View.Y_AXIS); > + } else { > + textR.width = SwingUtilities2.stringWidth(c, fm, text); > +- > +- // Take into account the left and right side bearings. > +- // This gives more space than it is actually needed, > +- // but there are two reasons: > +- // 1. If we set the width to the actual bounds, > +- // all callers would have to account for the bearings > +- // themselves. NOTE: all pref size calculations don't do it. > +- // 2. You can do a drawString at the returned location > +- // and the text won't be clipped. > + lsb = SwingUtilities2.getLeftSideBearing(c, fm, text); > + if (lsb < 0) { > ++ // If lsb is negative, add it to the width and later > ++ // adjust the x location. This gives more space than is > ++ // actually needed. > ++ // This is done like this for two reasons: > ++ // 1. If we set the width to the actual bounds all > ++ // callers would have to account for negative lsb > ++ // (pref size calculations ONLY look at width of > ++ // textR) > ++ // 2. You can do a drawString at the returned location > ++ // and the text won't be clipped. > + textR.width -= lsb; > + } > +- rsb = SwingUtilities2.getRightSideBearing(c, fm, text); > +- if (rsb > 0) { > +- textR.width += rsb; > +- } > +- > + if (textR.width > availTextWidth) { > + text = SwingUtilities2.clipString(c, fm, text, > + availTextWidth); > +diff -r 935814bd43a6 -r 281fbd82a971 src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java > +--- openjdk/jdk/src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java Tue Sep 01 18:51:15 2009 +0400 > ++++ openjdk/jdk/src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java Wed Sep 02 17:47:19 2009 +0400 > +@@ -195,7 +195,7 @@ > + getHorizontalAlignment(), getVerticalAlignment(), > + getHorizontalTextPosition(), getVerticalTextPosition(), > + getViewRect(), iconRect, textRect, getGap()); > +- textRect.width += getLeftTextExtraWidth() + getRightTextExtraWidth(); > ++ textRect.width += getLeftTextExtraWidth(); > + Rectangle labelRect = iconRect.union(textRect); > + getLabelSize().setHeight(labelRect.height); > + getLabelSize().setWidth(labelRect.width); > +diff -r 935814bd43a6 -r 281fbd82a971 src/share/classes/sun/swing/MenuItemLayoutHelper.java > +--- openjdk/jdk/src/share/classes/sun/swing/MenuItemLayoutHelper.java Tue Sep 01 18:51:15 2009 +0400 > ++++ openjdk/jdk/src/share/classes/sun/swing/MenuItemLayoutHelper.java Wed Sep 02 17:47:19 2009 +0400 > +@@ -84,7 +84,6 @@ > + private int minTextOffset; > + > + private int leftTextExtraWidth; > +- private int rightTextExtraWidth; > + > + private Rectangle viewRect; > + > +@@ -157,7 +156,6 @@ > + > + private void calcExtraWidths() { > + leftTextExtraWidth = getLeftExtraWidth(text); > +- rightTextExtraWidth = getRightExtraWidth(text); > + } > + > + private int getLeftExtraWidth(String str) { > +@@ -169,15 +167,6 @@ > + } > + } > + > +- private int getRightExtraWidth(String str) { > +- int rsb = SwingUtilities2.getRightSideBearing(mi, fm, str); > +- if (rsb > 0) { > +- return rsb; > +- } else { > +- return 0; > +- } > +- } > +- > + private void setOriginalWidths() { > + iconSize.origWidth = iconSize.width; > + textSize.origWidth = textSize.width; > +@@ -313,7 +302,7 @@ > + verticalAlignment, horizontalAlignment, > + verticalTextPosition, horizontalTextPosition, > + viewRect, iconRect, textRect, gap); > +- textRect.width += leftTextExtraWidth + rightTextExtraWidth; > ++ textRect.width += leftTextExtraWidth; > + Rectangle labelRect = iconRect.union(textRect); > + labelSize.height = labelRect.height; > + labelSize.width = labelRect.width; > +@@ -1121,10 +1110,6 @@ > + return leftTextExtraWidth; > + } > + > +- public int getRightTextExtraWidth() { > +- return rightTextExtraWidth; > +- } > +- > + /** > + * Returns false if the component is a JMenu and it is a top > + * level menu (on the menubar). > +diff -r 935814bd43a6 -r 281fbd82a971 src/share/classes/sun/swing/SwingUtilities2.java > +--- openjdk/jdk/src/share/classes/sun/swing/SwingUtilities2.java Tue Sep 01 18:51:15 2009 +0400 > ++++ openjdk/jdk/src/share/classes/sun/swing/SwingUtilities2.java Wed Sep 02 17:47:19 2009 +0400 > +@@ -27,7 +27,6 @@ > + > + import java.security.*; > + import java.lang.reflect.*; > +-import java.lang.ref.SoftReference; > + import java.awt.*; > + import static java.awt.RenderingHints.*; > + import java.awt.event.*; > +@@ -78,17 +77,23 @@ > + public static final Object LAF_STATE_KEY = > + new StringBuffer("LookAndFeel State"); > + > +- // Most of applications use 10 or less fonts simultaneously > +- private static final int STRONG_BEARING_CACHE_SIZE = 10; > +- // Strong cache for the left and right side bearings > +- // for STRONG_BEARING_CACHE_SIZE most recently used fonts. > +- private static BearingCacheEntry[] strongBearingCache = > +- new BearingCacheEntry[STRONG_BEARING_CACHE_SIZE]; > +- // Next index to insert an entry into the strong bearing cache > +- private static int strongBearingCacheNextIndex = 0; > +- // Soft cache for the left and right side bearings > +- private static Set> softBearingCache = > +- new HashSet>(); > ++ // Maintain a cache of CACHE_SIZE fonts and the left side bearing > ++ // of the characters falling into the range MIN_CHAR_INDEX to > ++ // MAX_CHAR_INDEX. The values in fontCache are created as needed. > ++ private static LSBCacheEntry[] fontCache; > ++ // Windows defines 6 font desktop properties, we will therefore only > ++ // cache the metrics for 6 fonts. > ++ private static final int CACHE_SIZE = 6; > ++ // nextIndex in fontCache to insert a font into. > ++ private static int nextIndex; > ++ // LSBCacheEntry used to search in fontCache to see if we already > ++ // have an entry for a particular font > ++ private static LSBCacheEntry searchKey; > ++ > ++ // getLeftSideBearing will consult all characters that fall in the > ++ // range MIN_CHAR_INDEX to MAX_CHAR_INDEX. > ++ private static final int MIN_CHAR_INDEX = (int)'W'; > ++ private static final int MAX_CHAR_INDEX = (int)'W' + 1; > + > + public static final FontRenderContext DEFAULT_FRC = > + new FontRenderContext(null, false, false); > +@@ -183,6 +188,10 @@ > + private static final Object charsBufferLock = new Object(); > + private static char[] charsBuffer = new char[CHAR_BUFFER_SIZE]; > + > ++ static { > ++ fontCache = new LSBCacheEntry[CACHE_SIZE]; > ++ } > ++ > + /** > + * checks whether TextLayout is required to handle characters. > + * > +@@ -226,7 +235,9 @@ > + > + /** > + * Returns the left side bearing of the first character of string. The > +- * left side bearing is calculated from the passed in FontMetrics. > ++ * left side bearing is calculated from the passed in > ++ * FontMetrics. If the passed in String is less than one > ++ * character, this will throw a StringIndexOutOfBoundsException exception. > + * > + * @param c JComponent that will display the string > + * @param fm FontMetrics used to measure the String width > +@@ -234,14 +245,11 @@ > + */ > + public static int getLeftSideBearing(JComponent c, FontMetrics fm, > + String string) { > +- if ((string == null) || (string.length() == 0)) { > +- return 0; > +- } > + return getLeftSideBearing(c, fm, string.charAt(0)); > + } > + > + /** > +- * Returns the left side bearing of the specified character. The > ++ * Returns the left side bearing of the first character of string. The > + * left side bearing is calculated from the passed in FontMetrics. > + * > + * @param c JComponent that will display the string > +@@ -250,105 +258,37 @@ > + */ > + public static int getLeftSideBearing(JComponent c, FontMetrics fm, > + char firstChar) { > +- return getBearing(c, fm, firstChar, true); > +- } > ++ int charIndex = (int) firstChar; > ++ if (charIndex < MAX_CHAR_INDEX && charIndex >= MIN_CHAR_INDEX) { > ++ byte[] lsbs = null; > + > +- /** > +- * Returns the right side bearing of the last character of string. The > +- * right side bearing is calculated from the passed in FontMetrics. > +- * > +- * @param c JComponent that will display the string > +- * @param fm FontMetrics used to measure the String width > +- * @param string String to get the right side bearing for. > +- */ > +- public static int getRightSideBearing(JComponent c, FontMetrics fm, > +- String string) { > +- if ((string == null) || (string.length() == 0)) { > +- return 0; > +- } > +- return getRightSideBearing(c, fm, string.charAt(string.length() - 1)); > +- } > +- > +- /** > +- * Returns the right side bearing of the specified character. The > +- * right side bearing is calculated from the passed in FontMetrics. > +- * > +- * @param c JComponent that will display the string > +- * @param fm FontMetrics used to measure the String width > +- * @param lastChar Character to get the right side bearing for. > +- */ > +- public static int getRightSideBearing(JComponent c, FontMetrics fm, > +- char lastChar) { > +- return getBearing(c, fm, lastChar, false); > +- } > +- > +- /* Calculates the left and right side bearing for a character. > +- * Strongly caches bearings for STRONG_BEARING_CACHE_SIZE > +- * most recently used Fonts and softly caches as many as GC allows. > +- */ > +- private static int getBearing(JComponent comp, FontMetrics fm, char c, > +- boolean isLeftBearing) { > +- if (fm == null) { > +- if (comp == null) { > +- return 0; > +- } else { > +- fm = comp.getFontMetrics(comp.getFont()); > +- } > +- } > +- synchronized (SwingUtilities2.class) { > +- BearingCacheEntry entry = null; > +- BearingCacheEntry searchKey = new BearingCacheEntry(fm); > +- // See if we already have an entry in the strong cache > +- for (BearingCacheEntry cacheEntry : strongBearingCache) { > +- if (searchKey.equals(cacheEntry)) { > +- entry = cacheEntry; > +- break; > ++ FontRenderContext frc = getFontRenderContext(c, fm); > ++ Font font = fm.getFont(); > ++ synchronized (SwingUtilities2.class) { > ++ LSBCacheEntry entry = null; > ++ if (searchKey == null) { > ++ searchKey = new LSBCacheEntry(frc, font); > ++ } else { > ++ searchKey.reset(frc, font); > + } > +- } > +- // See if we already have an entry in the soft cache > +- if (entry == null) { > +- Iterator> iter = > +- softBearingCache.iterator(); > +- while (iter.hasNext()) { > +- BearingCacheEntry cacheEntry = iter.next().get(); > +- if (cacheEntry == null) { > +- // Remove discarded soft reference from the cache > +- iter.remove(); > +- continue; > +- } > ++ // See if we already have an entry for this pair > ++ for (LSBCacheEntry cacheEntry : fontCache) { > + if (searchKey.equals(cacheEntry)) { > + entry = cacheEntry; > +- putEntryInStrongCache(entry); > + break; > + } > + } > ++ if (entry == null) { > ++ // No entry for this pair, add it. > ++ entry = searchKey; > ++ fontCache[nextIndex] = searchKey; > ++ searchKey = null; > ++ nextIndex = (nextIndex + 1) % CACHE_SIZE; > ++ } > ++ return entry.getLeftSideBearing(firstChar); > + } > +- if (entry == null) { > +- // No entry, add it > +- entry = searchKey; > +- cacheEntry(entry); > +- } > +- return (isLeftBearing) > +- ? entry.getLeftSideBearing(c) > +- : entry.getRightSideBearing(c); > + } > +- } > +- > +- private synchronized static void cacheEntry(BearingCacheEntry entry) { > +- // Move the oldest entry from the strong cache into the soft cache > +- BearingCacheEntry oldestEntry = > +- strongBearingCache[strongBearingCacheNextIndex]; > +- if (oldestEntry != null) { > +- softBearingCache.add(new SoftReference(oldestEntry)); > +- } > +- // Put entry in the strong cache > +- putEntryInStrongCache(entry); > +- } > +- > +- private synchronized static void putEntryInStrongCache(BearingCacheEntry entry) { > +- strongBearingCache[strongBearingCacheNextIndex] = entry; > +- strongBearingCacheNextIndex = (strongBearingCacheNextIndex + 1) > +- % STRONG_BEARING_CACHE_SIZE; > ++ return 0; > + } > + > + /** > +@@ -1063,99 +1003,72 @@ > + } > + > + /** > +- * BearingCacheEntry is used to cache left and right character bearings > +- * for a particular Font and FontRenderContext. > ++ * LSBCacheEntry is used to cache the left side bearing (lsb) for > ++ * a particular Font and FontRenderContext. > ++ * This only caches characters that fall in the range > ++ * MIN_CHAR_INDEX to MAX_CHAR_INDEX. > + */ > +- private static class BearingCacheEntry { > +- private FontMetrics fontMetrics; > ++ private static class LSBCacheEntry { > ++ // Used to indicate a particular entry in lsb has not been set. > ++ private static final byte UNSET = Byte.MAX_VALUE; > ++ // Used in creating a GlyphVector to get the lsb > ++ private static final char[] oneChar = new char[1]; > ++ > ++ private byte[] lsbCache; > + private Font font; > + private FontRenderContext frc; > +- private Map cache; > +- // Used for the creation of a GlyphVector > +- private static final char[] oneChar = new char[1]; > + > +- public BearingCacheEntry(FontMetrics fontMetrics) { > +- this.fontMetrics = fontMetrics; > +- this.font = fontMetrics.getFont(); > +- this.frc = fontMetrics.getFontRenderContext(); > +- this.cache = new HashMap(); > +- assert (font != null && frc != null); > ++ > ++ public LSBCacheEntry(FontRenderContext frc, Font font) { > ++ lsbCache = new byte[MAX_CHAR_INDEX - MIN_CHAR_INDEX]; > ++ reset(frc, font); > ++ > ++ } > ++ > ++ public void reset(FontRenderContext frc, Font font) { > ++ this.font = font; > ++ this.frc = frc; > ++ for (int counter = lsbCache.length - 1; counter >= 0; counter--) { > ++ lsbCache[counter] = UNSET; > ++ } > + } > + > + public int getLeftSideBearing(char aChar) { > +- Short bearing = cache.get(aChar); > +- if (bearing == null) { > +- bearing = calcBearing(aChar); > +- cache.put(aChar, bearing); > ++ int index = aChar - MIN_CHAR_INDEX; > ++ assert (index >= 0 && index < (MAX_CHAR_INDEX - MIN_CHAR_INDEX)); > ++ byte lsb = lsbCache[index]; > ++ if (lsb == UNSET) { > ++ oneChar[0] = aChar; > ++ GlyphVector gv = font.createGlyphVector(frc, oneChar); > ++ lsb = (byte) gv.getGlyphPixelBounds(0, frc, 0f, 0f).x; > ++ if (lsb < 0) { > ++ /* HRGB/HBGR LCD glyph images will always have a pixel > ++ * on the left used in colour fringe reduction. > ++ * Text rendering positions this correctly but here > ++ * we are using the glyph image to adjust that position > ++ * so must account for it. > ++ */ > ++ Object aaHint = frc.getAntiAliasingHint(); > ++ if (aaHint == VALUE_TEXT_ANTIALIAS_LCD_HRGB || > ++ aaHint == VALUE_TEXT_ANTIALIAS_LCD_HBGR) { > ++ lsb++; > ++ } > ++ } > ++ lsbCache[index] = lsb; > + } > +- return ((0xFF00 & bearing) >>> 8) - 127; > +- } > ++ return lsb; > + > +- public int getRightSideBearing(char aChar) { > +- Short bearing = cache.get(aChar); > +- if (bearing == null) { > +- bearing = calcBearing(aChar); > +- cache.put(aChar, bearing); > +- } > +- return (0xFF & bearing) - 127; > +- } > + > +- /* Calculates left and right side bearings for a character. > +- * Makes an assumption that bearing is a value between -127 and +127. > +- * Stores LSB and RSB as single two-byte number (short): > +- * LSB is the high byte, RSB is the low byte. > +- */ > +- private short calcBearing(char aChar) { > +- oneChar[0] = aChar; > +- GlyphVector gv = font.createGlyphVector(frc, oneChar); > +- Rectangle pixelBounds = gv.getGlyphPixelBounds(0, frc, 0f, 0f); > +- > +- // Get bearings > +- int lsb = pixelBounds.x; > +- int rsb = pixelBounds.width - fontMetrics.charWidth(aChar); > +- > +- /* HRGB/HBGR LCD glyph images will always have a pixel > +- * on the left and a pixel on the right > +- * used in colour fringe reduction. > +- * Text rendering positions this correctly but here > +- * we are using the glyph image to adjust that position > +- * so must account for it. > +- */ > +- if (lsb < 0) { > +- Object aaHint = frc.getAntiAliasingHint(); > +- if (aaHint == VALUE_TEXT_ANTIALIAS_LCD_HRGB || > +- aaHint == VALUE_TEXT_ANTIALIAS_LCD_HBGR) { > +- lsb++; > +- } > +- } > +- if (rsb > 0) { > +- Object aaHint = frc.getAntiAliasingHint(); > +- if (aaHint == VALUE_TEXT_ANTIALIAS_LCD_HRGB || > +- aaHint == VALUE_TEXT_ANTIALIAS_LCD_HBGR) { > +- rsb--; > +- } > +- } > +- > +- // Make sure that LSB and RSB are valid (see 6472972) > +- if (lsb < -127 || lsb > 127) { > +- lsb = 0; > +- } > +- if (rsb < -127 || rsb > 127) { > +- rsb = 0; > +- } > +- > +- int bearing = ((lsb + 127) << 8) + (rsb + 127); > +- return (short)bearing; > + } > + > + public boolean equals(Object entry) { > + if (entry == this) { > + return true; > + } > +- if (!(entry instanceof BearingCacheEntry)) { > ++ if (!(entry instanceof LSBCacheEntry)) { > + return false; > + } > +- BearingCacheEntry oEntry = (BearingCacheEntry)entry; > ++ LSBCacheEntry oEntry = (LSBCacheEntry) entry; > + return (font.equals(oEntry.font) && > + frc.equals(oEntry.frc)); > + } > +@@ -1172,7 +1085,6 @@ > + } > + } > + > +- > + /* > + * here goes the fix for 4856343 [Problem with applet interaction > + * with system selection clipboard] > +@@ -1181,36 +1093,34 @@ > + * are to be performed > + */ > + > +- > + /** > +- * checks the security permissions for accessing system clipboard > +- * > +- * for untrusted context (see isTrustedContext) checks the > +- * permissions for the current event being handled > +- * > +- */ > +- public static boolean canAccessSystemClipboard() { > +- boolean canAccess = false; > +- if (!GraphicsEnvironment.isHeadless()) { > +- SecurityManager sm = System.getSecurityManager(); > +- if (sm == null) { > +- canAccess = true; > +- } else { > +- try { > +- sm.checkSystemClipboardAccess(); > +- canAccess = true; > +- } catch (SecurityException e) { > +- } > +- if (canAccess && ! isTrustedContext()) { > +- canAccess = canCurrentEventAccessSystemClipboard(true); > +- } > +- } > +- } > +- return canAccess; > +- } > +- > ++ * checks the security permissions for accessing system clipboard > ++ * > ++ * for untrusted context (see isTrustedContext) checks the > ++ * permissions for the current event being handled > ++ * > ++ */ > ++ public static boolean canAccessSystemClipboard() { > ++ boolean canAccess = false; > ++ if (!GraphicsEnvironment.isHeadless()) { > ++ SecurityManager sm = System.getSecurityManager(); > ++ if (sm == null) { > ++ canAccess = true; > ++ } else { > ++ try { > ++ sm.checkSystemClipboardAccess(); > ++ canAccess = true; > ++ } catch (SecurityException e) { > ++ } > ++ if (canAccess && ! isTrustedContext()) { > ++ canAccess = canCurrentEventAccessSystemClipboard(true); > ++ } > ++ } > ++ } > ++ return canAccess; > ++ } > + /** > +- * Returns true if EventQueue.getCurrentEvent() has the permissions to > ++ * Returns true if EventQueue.getCurrentEvent() has the permissions to > + * access the system clipboard > + */ > + public static boolean canCurrentEventAccessSystemClipboard() { > +diff -r 935814bd43a6 -r 281fbd82a971 test/javax/swing/SwingUtilities/6797139/bug6797139.java > +--- /dev/null Thu Jan 01 00:00:00 1970 +0000 > ++++ openjdk/jdk/test/javax/swing/SwingUtilities/6797139/bug6797139.java Wed Sep 02 17:47:19 2009 +0400 > +@@ -0,0 +1,62 @@ > ++/* > ++ * Copyright 2009 Sun Microsystems, Inc. All Rights Reserved. > ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. > ++ * > ++ * This code is free software; you can redistribute it and/or modify it > ++ * under the terms of the GNU General Public License version 2 only, as > ++ * published by the Free Software Foundation. > ++ * > ++ * This code is distributed in the hope that it will be useful, but WITHOUT > ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or > ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License > ++ * version 2 for more details (a copy is included in the LICENSE file that > ++ * accompanied this code). > ++ * > ++ * You should have received a copy of the GNU General Public License version > ++ * 2 along with this work; if not, write to the Free Software Foundation, > ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. > ++ * > ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, > ++ * CA 95054 USA or visit www.sun.com if you need additional information or > ++ * have any questions. > ++ */ > ++ > ++/* @test > ++ * > ++ * @bug 6797139 > ++ * @author Alexander Potochkin > ++ * @summary tests that JButton's text is not incorrectly truncated > ++ */ > ++import javax.swing.*; > ++import javax.swing.plaf.basic.BasicButtonUI; > ++import java.awt.*; > ++import java.awt.image.BufferedImage; > ++ > ++public class bug6797139 { > ++ > ++ private static void createGui() { > ++ JButton b = new JButton("Probably"); > ++ b.setUI(new BasicButtonUI() { > ++ protected void paintText(Graphics g, AbstractButton b, Rectangle textRect, String text) { > ++ super.paintText(g, b, textRect, text); > ++ if (text.endsWith("...")) { > ++ throw new RuntimeException("Text is truncated!"); > ++ } > ++ } > ++ }); > ++ b.setSize(b.getPreferredSize()); > ++ BufferedImage image = new BufferedImage(b.getWidth(), b.getHeight(), > ++ BufferedImage.TYPE_INT_ARGB); > ++ Graphics g = image.getGraphics(); > ++ b.paint(g); > ++ g.dispose(); > ++ } > ++ > ++ public static void main(String[] args) throws Exception { > ++ SwingUtilities.invokeAndWait(new Runnable() { > ++ public void run() { > ++ createGui(); > ++ } > ++ }); > ++ } > ++} -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Mon Jan 17 11:16:59 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Mon, 17 Jan 2011 19:16:59 +0000 Subject: Backporting S6642612 to icedtea6 In-Reply-To: <4D34905F.1040204@redhat.com> References: <4D34905F.1040204@redhat.com> Message-ID: <20110117191659.GK13471@rivendell.middle-earth.co.uk> On 13:54 Mon 17 Jan , Omair Majid wrote: > Hi, > > I would like to backport SS6642612 to icedtea6. The changeset makes the > OK and Cancel buttons in JFileChooser dialogs have the same size. The > patch is attached. > > Ok to commit? > > Cheers, > Omair Looks fine, though committing this will break the patch you posted previously. > diff -r fd09f4a3b767 ChangeLog > --- a/ChangeLog Sun Jan 09 00:43:01 2011 +0000 > +++ b/ChangeLog Mon Jan 17 13:30:24 2011 -0500 > @@ -1,3 +1,8 @@ > +2011-01-17 Omair Majid > + > + * Makefile.am (ICEDTEA_PATCHES): Add new patch. > + * patches/openjdk/6642612-filechooser_button_sizes.patch: New file. > + > 2011-01-07 Andrew John Hughes > > * patches/jtreg-TestXEmbedServer-fix.patch: > diff -r fd09f4a3b767 Makefile.am > --- a/Makefile.am Sun Jan 09 00:43:01 2011 +0000 > +++ b/Makefile.am Mon Jan 17 13:30:24 2011 -0500 > @@ -316,7 +316,8 @@ > patches/openjdk/6687968-pngimagereader_mem_leak.patch \ > patches/openjdk/6541476-png-iTXt-chunk.patch \ > patches/openjdk/6782079-png_metadata_oom.patch \ > - patches/661505-jpeg.patch > + patches/661505-jpeg.patch \ > + patches/openjdk/6642612-filechooser_button_sizes.patch > > if WITH_ALT_HSBUILD > ICEDTEA_PATCHES += \ > diff -r fd09f4a3b767 NEWS > --- a/NEWS Sun Jan 09 00:43:01 2011 +0000 > +++ b/NEWS Mon Jan 17 13:30:24 2011 -0500 > @@ -55,7 +55,7 @@ > - S6541476, RH665355: PNG imageio plugin incorrectly handles iTXt chunk > - S6782079: PNG: reading metadata may cause OOM on truncated images > - RH661505: JPEGs with sRGB IEC61966-2.1 color profiles have wrong colors > - > + - S6642612: JFileChooser approve buttons should use Open and Save text (GTK) > * Bug fixes > - S7003777, RH647674: JTextPane produces incorrect content after parsing the html text > - S7004655, PR590: Unable to activate (click) checkboxes in jtable > diff -r fd09f4a3b767 patches/openjdk/6642612-filechooser_button_sizes.patch > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/patches/openjdk/6642612-filechooser_button_sizes.patch Mon Jan 17 13:30:24 2011 -0500 > @@ -0,0 +1,67 @@ > +# HG changeset patch > +# User rupashka > +# Date 1209546061 -14400 > +# Node ID 9a322f3dccd8bf3ab5726ec18fbaa0131938f2c4 > +# Parent eca2e5716b86c31a2f6421473bcee3fec30a500f > +6642612: JFileChooser approve buttons should use Open and Save text (GTK) > +Summary: In FileChooser under GTK LaF "Ok" and "Cancel" buttons were made with the same size > +Reviewed-by: peterz > + > +diff -r eca2e5716b86 -r 9a322f3dccd8 src/share/classes/com/sun/java/swing/plaf/gtk/GTKFileChooserUI.java > +--- openjdk/jdk/src/share/classes/com/sun/java/swing/plaf/gtk/GTKFileChooserUI.java Wed Apr 30 12:32:05 2008 +0400 > ++++ openjdk/jdk/src/share/classes/com/sun/java/swing/plaf/gtk/GTKFileChooserUI.java Wed Apr 30 13:01:01 2008 +0400 > +@@ -97,14 +97,11 @@ > + private static final Dimension hstrut3 = new Dimension(3, 1); > + private static final Dimension vstrut10 = new Dimension(1, 10); > + > +- private static final Insets insets = new Insets(10, 10, 10, 10); > +- > + private static Dimension prefListSize = new Dimension(75, 150); > + > + private static Dimension PREF_SIZE = new Dimension(435, 360); > + private static Dimension MIN_SIZE = new Dimension(200, 300); > + > +- private static Dimension PREF_ACC_SIZE = new Dimension(10, 10); > + private static Dimension ZERO_ACC_SIZE = new Dimension(1, 1); > + > + private static Dimension MAX_SIZE = new Dimension(Short.MAX_VALUE, Short.MAX_VALUE); > +@@ -125,7 +122,6 @@ > + private JPanel bottomButtonPanel; > + private GTKDirectoryModel model = null; > + private Action newFolderAction; > +- private JPanel interior; > + private boolean readOnly; > + private boolean showDirectoryIcons; > + private boolean showFileIcons; > +@@ -710,15 +706,19 @@ > + bottomButtonPanel.setName("GTKFileChooser.bottomButtonPanel"); > + align(bottomButtonPanel); > + > ++ JPanel pnButtons = new JPanel(new GridLayout(1, 2, 5, 0)); > ++ > + JButton cancelButton = getCancelButton(fc); > + align(cancelButton); > + cancelButton.setMargin(buttonMargin); > +- bottomButtonPanel.add(cancelButton); > ++ pnButtons.add(cancelButton); > + > +- JButton approveButton = getApproveButton(fc);; > ++ JButton approveButton = getApproveButton(fc); > + align(approveButton); > + approveButton.setMargin(buttonMargin); > +- bottomButtonPanel.add(approveButton); > ++ pnButtons.add(approveButton); > ++ > ++ bottomButtonPanel.add(pnButtons); > + > + if (fc.getControlButtonsAreShown()) { > + fc.add(bottomButtonPanel, BorderLayout.SOUTH); > +@@ -1108,7 +1108,7 @@ > + // Get the canonical (full) path. This has the side > + // benefit of removing extraneous chars from the path, > + // for example /foo/bar/ becomes /foo/bar > +- File canonical = null; > ++ File canonical; > + try { > + canonical = fsv.createFileObject(ShellFolder.getNormalizedFile(directory).getPath()); > + } catch (IOException e) { -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at redhat.com Mon Jan 17 11:29:13 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 17 Jan 2011 14:29:13 -0500 Subject: Request to backport 6736649 and 6797139 In-Reply-To: <20110117185548.GJ13471@rivendell.middle-earth.co.uk> References: <4D30CFB1.6050705@redhat.com> <20110117141006.GA13471@rivendell.middle-earth.co.uk> <4D3454D9.7040200@redhat.com> <20110117170055.GD13471@rivendell.middle-earth.co.uk> <4D348843.2060602@redhat.com> <20110117185548.GJ13471@rivendell.middle-earth.co.uk> Message-ID: <4D349889.80701@redhat.com> On 01/17/2011 01:55 PM, Dr Andrew John Hughes wrote: > On 13:19 Mon 17 Jan , Omair Majid wrote: >> On 01/17/2011 12:00 PM, Dr Andrew John Hughes wrote: >>> On 09:40 Mon 17 Jan , Omair Majid wrote: >>>> On 01/17/2011 09:10 AM, Dr Andrew John Hughes wrote: >>>>> On 17:35 Fri 14 Jan , Omair Majid wrote: >>>>>> I would like to backport the following two changesets to openjdk6: >>>>>> >>>>>> changeset: 624:e78c2f17a606 >>>>>> user: mlapshin >>>>>> date: Tue Aug 26 12:16:23 2008 +0400 >>>>>> summary: 6736649: >>>>>> test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on >>>>>> Linux >>>>>> >>>>>> changeset: 1637:281fbd82a971 >>>>>> user: alexp >>>>>> date: Wed Sep 02 17:47:19 2009 +0400 >>>>>> summary: 6797139: JButton title is truncating for some strings >>>>>> irrespective of preferred size. >>>>>> >>>>>> Together, these changesets fix a bug where some strings are incorrectly >>>>>> being truncated. >>>>>> >>>>> >>>>> I don't see either of these in IcedTea6. Please add them there first before >>>>> trying to upstream them. >>>>> >>>> >>>> I was going to add them to IcedTea6 as soon as Joe approved them for >>>> openjdk6. Can I assume you are okay with adding it to IcedTea6 without >>>> waiting for Joe's comments? >>> >>> Post the patch and we can make that decision :-) >>> >> >> I have attached the patch for icedtea6. Ok to commit? >> >> Thanks, >> Omair > > The changesets seem to have a lot of whitespace changes, which make it > hard to read, but as these come from the upstream changesets, there's > not much to be done about that. Is it correct that the first adds the > calculation of the right width and then the second removes it? > >> +- textRect.width += getLeftTextExtraWidth() + getRightTextExtraWidth(); >> ++ textRect.width += getLeftTextExtraWidth(); > Yes. Apparently there were some fixes that were performed before OpenJDK was branched; the second patch rolls back some of those changes. From what I can tell, this rollback patch seems quite hackish. But perhaps this is just the complexity of the JDK code. > I'm a little worried by the addition of an exception: > >> + * Returns the left side bearing of the first character of string. The >> +- * left side bearing is calculated from the passed in FontMetrics. >> ++ * left side bearing is calculated from the passed in >> ++ * FontMetrics. If the passed in String is less than one >> ++ * character, this will throw a StringIndexOutOfBoundsException exception. >> + * >> + * @param c JComponent that will display the string >> + * @param fm FontMetrics used to measure the String width >> +@@ -234,14 +245,11 @@ >> + */ >> + public static int getLeftSideBearing(JComponent c, FontMetrics fm, >> + String string) { >> +- if ((string == null) || (string.length() == 0)) { >> +- return 0; >> +- } >> + return getLeftSideBearing(c, fm, string.charAt(0)); >> + } > > Is this visible further up the stack? > Hm. I missed that. In general yes, it will be visible - sun.swing.SwingUtilities2 is a public class. On the other hand, it is supposed to be an internal class not part of the public API. From the Javadocs: WARNING: While this class is public, it should not be treated as public API and its API may change in incompatable ways between dot dot releases and even patch releases. You should not rely on this class even existing. Perhaps worse than the exception, the patch removes a public method: +- public static int getRightSideBearing(JComponent c, FontMetrics fm, +- String string) { I am starting to have second thoughts about backporting this. On the other hand, I can see (using reflection) that the proprietary JDK 6 does not have getRightSideBearing methods either. > Do the new tests pass? They should be fixed to use the newer Oracle copyright notices. > Sorry, but I forgot to run the tests. I will fix the copyrights, run the tests and post the results. I can confirm that the patch does fix the issue pointed out in the bug report at https://bugzilla.redhat.com/show_bug.cgi?id=661610 Thanks, Omair From ahughes at redhat.com Mon Jan 17 12:00:53 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Mon, 17 Jan 2011 20:00:53 +0000 Subject: Request to backport 6736649 and 6797139 In-Reply-To: <4D349889.80701@redhat.com> References: <4D30CFB1.6050705@redhat.com> <20110117141006.GA13471@rivendell.middle-earth.co.uk> <4D3454D9.7040200@redhat.com> <20110117170055.GD13471@rivendell.middle-earth.co.uk> <4D348843.2060602@redhat.com> <20110117185548.GJ13471@rivendell.middle-earth.co.uk> <4D349889.80701@redhat.com> Message-ID: <20110117200053.GL13471@rivendell.middle-earth.co.uk> On 14:29 Mon 17 Jan , Omair Majid wrote: > On 01/17/2011 01:55 PM, Dr Andrew John Hughes wrote: > > On 13:19 Mon 17 Jan , Omair Majid wrote: > >> On 01/17/2011 12:00 PM, Dr Andrew John Hughes wrote: > >>> On 09:40 Mon 17 Jan , Omair Majid wrote: > >>>> On 01/17/2011 09:10 AM, Dr Andrew John Hughes wrote: > >>>>> On 17:35 Fri 14 Jan , Omair Majid wrote: > >>>>>> I would like to backport the following two changesets to openjdk6: > >>>>>> > >>>>>> changeset: 624:e78c2f17a606 > >>>>>> user: mlapshin > >>>>>> date: Tue Aug 26 12:16:23 2008 +0400 > >>>>>> summary: 6736649: > >>>>>> test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on > >>>>>> Linux > >>>>>> > >>>>>> changeset: 1637:281fbd82a971 > >>>>>> user: alexp > >>>>>> date: Wed Sep 02 17:47:19 2009 +0400 > >>>>>> summary: 6797139: JButton title is truncating for some strings > >>>>>> irrespective of preferred size. > >>>>>> > >>>>>> Together, these changesets fix a bug where some strings are incorrectly > >>>>>> being truncated. > >>>>>> > >>>>> > >>>>> I don't see either of these in IcedTea6. Please add them there first before > >>>>> trying to upstream them. > >>>>> > >>>> > >>>> I was going to add them to IcedTea6 as soon as Joe approved them for > >>>> openjdk6. Can I assume you are okay with adding it to IcedTea6 without > >>>> waiting for Joe's comments? > >>> > >>> Post the patch and we can make that decision :-) > >>> > >> > >> I have attached the patch for icedtea6. Ok to commit? > >> > >> Thanks, > >> Omair > > > > The changesets seem to have a lot of whitespace changes, which make it > > hard to read, but as these come from the upstream changesets, there's > > not much to be done about that. Is it correct that the first adds the > > calculation of the right width and then the second removes it? > > > >> +- textRect.width += getLeftTextExtraWidth() + getRightTextExtraWidth(); > >> ++ textRect.width += getLeftTextExtraWidth(); > > > > Yes. Apparently there were some fixes that were performed before OpenJDK > was branched; the second patch rolls back some of those changes. From > what I can tell, this rollback patch seems quite hackish. But perhaps > this is just the complexity of the JDK code. > It's annoying that so much history has not been preserved correctly. > > I'm a little worried by the addition of an exception: > > > >> + * Returns the left side bearing of the first character of string. The > >> +- * left side bearing is calculated from the passed in FontMetrics. > >> ++ * left side bearing is calculated from the passed in > >> ++ * FontMetrics. If the passed in String is less than one > >> ++ * character, this will throw a StringIndexOutOfBoundsException exception. > >> + * > >> + * @param c JComponent that will display the string > >> + * @param fm FontMetrics used to measure the String width > >> +@@ -234,14 +245,11 @@ > >> + */ > >> + public static int getLeftSideBearing(JComponent c, FontMetrics fm, > >> + String string) { > >> +- if ((string == null) || (string.length() == 0)) { > >> +- return 0; > >> +- } > >> + return getLeftSideBearing(c, fm, string.charAt(0)); > >> + } > > > > Is this visible further up the stack? > > > > Hm. I missed that. In general yes, it will be visible - > sun.swing.SwingUtilities2 is a public class. On the other hand, it is > supposed to be an internal class not part of the public API. From the > Javadocs: > > WARNING: While this class is public, it should not be treated as > public API and its API may change in incompatable ways between dot dot > releases and even patch releases. You should not rely on this class even > existing. > > Perhaps worse than the exception, the patch removes a public method: > +- public static int getRightSideBearing(JComponent c, FontMetrics fm, > +- String string) { > > I am starting to have second thoughts about backporting this. > > On the other hand, I can see (using reflection) that the proprietary JDK > 6 does not have getRightSideBearing methods either. > It doesn't matter about changing the API of classes outside those that form part of the public documentation (mainly java.* and javax.*.). My concern was that this exception would travel up the stack and be thrown from a javax.swing method where it wasn't previously. Can you check what calls this method and whether it can reach that level? I'm still for backporting as it fixes a bug users have encountered. If necessary, we can just drop the changes which allow the exception to be thrown. > > Do the new tests pass? They should be fixed to use the newer Oracle copyright notices. > > > > Sorry, but I forgot to run the tests. I will fix the copyrights, run the > tests and post the results. I can confirm that the patch does fix the > issue pointed out in the bug report at > https://bugzilla.redhat.com/show_bug.cgi?id=661610 > This sounds a good reason to backport. I'll await the results. > Thanks, > Omair Thanks, -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at icedtea.classpath.org Mon Jan 17 13:57:43 2011 From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org) Date: Mon, 17 Jan 2011 21:57:43 +0000 Subject: /hg/icedtea6: Backport S6642612: JFileChooser's approve buttons ... Message-ID: changeset 974192ac0471 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=974192ac0471 author: Omair Majid date: Mon Jan 17 16:51:25 2011 -0500 Backport S6642612: JFileChooser's approve buttons should be the same size (GTK) 2011-01-17 Omair Majid * Makefile.am (ICEDTEA_PATCHES): Add new patch. * patches/openjdk/6642612-filechooser_button_sizes.patch: New file. diffstat: 4 files changed, 75 insertions(+), 2 deletions(-) ChangeLog | 5 + Makefile.am | 3 NEWS | 2 patches/openjdk/6642612-filechooser_button_sizes.patch | 67 ++++++++++++++++ diffs (108 lines): diff -r fd09f4a3b767 -r 974192ac0471 ChangeLog --- a/ChangeLog Sun Jan 09 00:43:01 2011 +0000 +++ b/ChangeLog Mon Jan 17 16:51:25 2011 -0500 @@ -1,3 +1,8 @@ 2011-01-07 Andrew John Hughes + + * Makefile.am (ICEDTEA_PATCHES): Add new patch. + * patches/openjdk/6642612-filechooser_button_sizes.patch: New file. + 2011-01-07 Andrew John Hughes * patches/jtreg-TestXEmbedServer-fix.patch: diff -r fd09f4a3b767 -r 974192ac0471 Makefile.am --- a/Makefile.am Sun Jan 09 00:43:01 2011 +0000 +++ b/Makefile.am Mon Jan 17 16:51:25 2011 -0500 @@ -316,7 +316,8 @@ ICEDTEA_PATCHES = \ patches/openjdk/6687968-pngimagereader_mem_leak.patch \ patches/openjdk/6541476-png-iTXt-chunk.patch \ patches/openjdk/6782079-png_metadata_oom.patch \ - patches/661505-jpeg.patch + patches/661505-jpeg.patch \ + patches/openjdk/6642612-filechooser_button_sizes.patch if WITH_ALT_HSBUILD ICEDTEA_PATCHES += \ diff -r fd09f4a3b767 -r 974192ac0471 NEWS --- a/NEWS Sun Jan 09 00:43:01 2011 +0000 +++ b/NEWS Mon Jan 17 16:51:25 2011 -0500 @@ -55,7 +55,7 @@ New in release 1.10 (2010-XX-XX): - S6541476, RH665355: PNG imageio plugin incorrectly handles iTXt chunk - S6782079: PNG: reading metadata may cause OOM on truncated images - RH661505: JPEGs with sRGB IEC61966-2.1 color profiles have wrong colors - + - S6642612: JFileChooser's approve buttons should be the same size (GTK) * Bug fixes - S7003777, RH647674: JTextPane produces incorrect content after parsing the html text - S7004655, PR590: Unable to activate (click) checkboxes in jtable diff -r fd09f4a3b767 -r 974192ac0471 patches/openjdk/6642612-filechooser_button_sizes.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/openjdk/6642612-filechooser_button_sizes.patch Mon Jan 17 16:51:25 2011 -0500 @@ -0,0 +1,67 @@ +# HG changeset patch +# User rupashka +# Date 1209546061 -14400 +# Node ID 9a322f3dccd8bf3ab5726ec18fbaa0131938f2c4 +# Parent eca2e5716b86c31a2f6421473bcee3fec30a500f +6642612: JFileChooser approve buttons should use Open and Save text (GTK) +Summary: In FileChooser under GTK LaF "Ok" and "Cancel" buttons were made with the same size +Reviewed-by: peterz + +diff -r eca2e5716b86 -r 9a322f3dccd8 src/share/classes/com/sun/java/swing/plaf/gtk/GTKFileChooserUI.java +--- openjdk/jdk/src/share/classes/com/sun/java/swing/plaf/gtk/GTKFileChooserUI.java Wed Apr 30 12:32:05 2008 +0400 ++++ openjdk/jdk/src/share/classes/com/sun/java/swing/plaf/gtk/GTKFileChooserUI.java Wed Apr 30 13:01:01 2008 +0400 +@@ -97,14 +97,11 @@ + private static final Dimension hstrut3 = new Dimension(3, 1); + private static final Dimension vstrut10 = new Dimension(1, 10); + +- private static final Insets insets = new Insets(10, 10, 10, 10); +- + private static Dimension prefListSize = new Dimension(75, 150); + + private static Dimension PREF_SIZE = new Dimension(435, 360); + private static Dimension MIN_SIZE = new Dimension(200, 300); + +- private static Dimension PREF_ACC_SIZE = new Dimension(10, 10); + private static Dimension ZERO_ACC_SIZE = new Dimension(1, 1); + + private static Dimension MAX_SIZE = new Dimension(Short.MAX_VALUE, Short.MAX_VALUE); +@@ -125,7 +122,6 @@ + private JPanel bottomButtonPanel; + private GTKDirectoryModel model = null; + private Action newFolderAction; +- private JPanel interior; + private boolean readOnly; + private boolean showDirectoryIcons; + private boolean showFileIcons; +@@ -710,15 +706,19 @@ + bottomButtonPanel.setName("GTKFileChooser.bottomButtonPanel"); + align(bottomButtonPanel); + ++ JPanel pnButtons = new JPanel(new GridLayout(1, 2, 5, 0)); ++ + JButton cancelButton = getCancelButton(fc); + align(cancelButton); + cancelButton.setMargin(buttonMargin); +- bottomButtonPanel.add(cancelButton); ++ pnButtons.add(cancelButton); + +- JButton approveButton = getApproveButton(fc);; ++ JButton approveButton = getApproveButton(fc); + align(approveButton); + approveButton.setMargin(buttonMargin); +- bottomButtonPanel.add(approveButton); ++ pnButtons.add(approveButton); ++ ++ bottomButtonPanel.add(pnButtons); + + if (fc.getControlButtonsAreShown()) { + fc.add(bottomButtonPanel, BorderLayout.SOUTH); +@@ -1108,7 +1108,7 @@ + // Get the canonical (full) path. This has the side + // benefit of removing extraneous chars from the path, + // for example /foo/bar/ becomes /foo/bar +- File canonical = null; ++ File canonical; + try { + canonical = fsv.createFileObject(ShellFolder.getNormalizedFile(directory).getPath()); + } catch (IOException e) { From omajid at redhat.com Mon Jan 17 14:00:52 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 17 Jan 2011 17:00:52 -0500 Subject: Backporting S6642612 to icedtea6 In-Reply-To: <20110117191659.GK13471@rivendell.middle-earth.co.uk> References: <4D34905F.1040204@redhat.com> <20110117191659.GK13471@rivendell.middle-earth.co.uk> Message-ID: <4D34BC14.5080100@redhat.com> On 01/17/2011 02:16 PM, Dr Andrew John Hughes wrote: > On 13:54 Mon 17 Jan , Omair Majid wrote: >> Hi, >> >> I would like to backport SS6642612 to icedtea6. The changeset makes the >> OK and Cancel buttons in JFileChooser dialogs have the same size. The >> patch is attached. >> >> Ok to commit? >> > > Looks fine, though committing this will break the patch you posted previously. > Thanks. I have pushed the fix. Breaking the other patch is okay - we might have to refine it a bit more anyway. Thanks, Omair From ptisnovs at redhat.com Tue Jan 18 02:26:01 2011 From: ptisnovs at redhat.com (Pavel Tisnovsky) Date: Tue, 18 Jan 2011 11:26:01 +0100 Subject: Reviewer needed - new regression test for checking font rendering & addition of copyright text to existing test In-Reply-To: <20110117171535.GF13471@rivendell.middle-earth.co.uk> References: <4D345FCB.8000900@redhat.com> <20110117154358.GC13471@rivendell.middle-earth.co.uk> <4D34732E.5000906@redhat.com> <20110117171535.GF13471@rivendell.middle-earth.co.uk> Message-ID: <4D356AB9.2010505@redhat.com> Dr Andrew John Hughes wrote: > Ok, can we please have a fresh patch for this new test? And as mentioned > before, no 'icedtea-' prefix on the new patch. > Hi Andrew, sure, new version of patch is stored in attachment [jtreg-international-fonts-styles.patch]. There's also hg diff done against recent version of IcedTea6 (w/o ChangeLog) and new version of ChangeLog. Do you think this new version is 'pushable' ;-) Cheers Pavel -------------- next part -------------- An embedded and charset-unspecified text was scrubbed... Name: hg_diff Url: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110118/5eb9cc4e/hg_diff.ksh -------------- next part -------------- A non-text attachment was scrubbed... Name: jtreg-international-fonts-styles.patch Type: text/x-patch Size: 11495 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110118/5eb9cc4e/jtreg-international-fonts-styles.patch -------------- next part -------------- An embedded and charset-unspecified text was scrubbed... Name: ChangeLog Url: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110118/5eb9cc4e/ChangeLog.ksh From ahughes at redhat.com Tue Jan 18 06:22:48 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Tue, 18 Jan 2011 14:22:48 +0000 Subject: Reviewer needed - new regression test for checking font rendering & addition of copyright text to existing test In-Reply-To: <4D356AB9.2010505@redhat.com> References: <4D345FCB.8000900@redhat.com> <20110117154358.GC13471@rivendell.middle-earth.co.uk> <4D34732E.5000906@redhat.com> <20110117171535.GF13471@rivendell.middle-earth.co.uk> <4D356AB9.2010505@redhat.com> Message-ID: <20110118142248.GA14019@rivendell.middle-earth.co.uk> On 11:26 Tue 18 Jan , Pavel Tisnovsky wrote: > Dr Andrew John Hughes wrote: > > Ok, can we please have a fresh patch for this new test? And as mentioned > > before, no 'icedtea-' prefix on the new patch. > > > > Hi Andrew, > > sure, new version of patch is stored in attachment > [jtreg-international-fonts-styles.patch]. There's also hg diff done > against recent version of IcedTea6 (w/o ChangeLog) and new version of > ChangeLog. > > Do you think this new version is 'pushable' ;-) > > Cheers > Pavel > Yes, looks ok. You only needed to attach the patch for IcedTea6 with the ChangeLog in the e-mail body i.e. we don't need two copies of the ifs patch itself :-) > diff -r 974192ac0471 Makefile.am > --- a/Makefile.am Mon Jan 17 16:51:25 2011 -0500 > +++ b/Makefile.am Tue Jan 18 11:17:29 2011 +0100 > @@ -317,7 +317,8 @@ > patches/openjdk/6541476-png-iTXt-chunk.patch \ > patches/openjdk/6782079-png_metadata_oom.patch \ > patches/661505-jpeg.patch \ > - patches/openjdk/6642612-filechooser_button_sizes.patch > + patches/openjdk/6642612-filechooser_button_sizes.patch \ > + patches/jtreg-international-fonts-styles.patch > > if WITH_ALT_HSBUILD > ICEDTEA_PATCHES += \ > diff -r 974192ac0471 patches/jtreg-international-fonts-styles.patch > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/patches/jtreg-international-fonts-styles.patch Tue Jan 18 11:17:29 2011 +0100 > @@ -0,0 +1,280 @@ > +--- /dev/null 2010-06-29 11:10:08.737208357 +0200 > ++++ openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsStyles.java 2011-01-17 17:06:44.452369000 +0100 > +@@ -0,0 +1,277 @@ > ++/* > ++ * Copyright 2011 Red Hat, Inc. All Rights Reserved. > ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. > ++ * > ++ * This code is free software; you can redistribute it and/or modify it > ++ * under the terms of the GNU General Public License version 2 only, as > ++ * published by the Free Software Foundation. > ++ * > ++ * This code is distributed in the hope that it will be useful, but WITHOUT > ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or > ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License > ++ * version 2 for more details (a copy is included in the LICENSE file that > ++ * accompanied this code). > ++ * > ++ * You should have received a copy of the GNU General Public License version > ++ * 2 along with this work; if not, write to the Free Software Foundation, > ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. > ++ */ > ++ > ++import java.awt.Color; > ++import java.awt.Font; > ++import java.awt.Graphics2D; > ++import java.awt.RenderingHints; > ++import java.awt.image.BufferedImage; > ++import java.io.File; > ++import java.io.IOException; > ++import java.util.Arrays; > ++import java.util.List; > ++import java.util.ArrayList; > ++ > ++import javax.imageio.ImageIO; > ++ > ++/** > ++ * @test > ++ * @run main InternationalFontsStyles > ++ * @author Pavel Tisnovsky > ++ * > ++ * @summary This test check if selected international characters could be > ++ * properly rendered with various font styles and logical names. > ++ * > ++ * This regression test check if selected international characters > ++ * could be properly rendered using various styles and logical font > ++ * names - the test check rendering using all combinations of logical > ++ * font names (Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, > ++ * Font.DIALOG, Font.DIALOG_INPUT) and font styles (Font.PLAIN, > ++ * Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC). > ++ * > ++ * The test is based on rendering certain characters from selected code > ++ * pages into BufferedImage. > ++ * > ++ * When the shape of selected character does not exists or font > ++ * configuration is broken, only empty rectangle is rendered instead of > ++ * the selected character shape. This rectangle is filtered and then > ++ * the destination image is tested whether it is empty (=white). > ++ * > ++ * If test images with rendered characters needs to be created use > ++ * following flag: -create-images > ++ * > ++ */ > ++public class InternationalFontsStyles > ++{ > ++ // all logical font names which are tested > ++ private static final String[] fontNames = {Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, Font.DIALOG, Font.DIALOG_INPUT}; > ++ > ++ // all font styles which are tested > ++ private static final int[] fontStyles = {Font.PLAIN, Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC}; > ++ > ++ // width and height of image where is each character rendered > ++ private static int WIDTH = 200; > ++ private static int HEIGHT = 200; > ++ > ++ // font size used for rendering > ++ private static final int FONT_SIZE = 160; > ++ > ++ private static final int MINIMUM_HORIZONTAL_LINE_LENGTH = 70; > ++ private static final int MINIMUM_VERTICAL_LINE_LENGTH = 80; > ++ private static final int BLACK_WHITE_THRESHOLD = 128; > ++ private static final int BLACK_PIXEL_COUNT_THRESHOLD = WIDTH * HEIGHT / 1000; > ++ > ++ private static final String[][] testedStrings = { > ++ {"Latin-1", "abcdefABCDEF"}, > ++ {"Latin-2", "\u011b\u0161\u010d\u0159\u017e\u00fd\u00e1\u00ed\u00e9\u00fa\u016f\u013e\u0148"}, > ++ {"Cyrilic", "\u0414\u0417\u0418\u0472\u0424\u0425\u0470\u0460\u0426"}, > ++ {"Greek", "\u03b2\u03be\u03b3\u03b4\u03c0\u03b5\u03c1\u03b6\u03a3\u03c3\u03c2\u03b7\u03c4\u03b8\u03c5\u03a9"}, > ++ {"Asia-Test1", "\u4f53\u4e2d\u6587\u7b26\u53f7"}, > ++ {"Asia-Test2", "\u7e41\u9ad4\u4e2d\u6587\u7b26\u865f"}, > ++ {"Asia-Test3", "\u65e5\u672c\u306e\u8c61\u5fb4"}, > ++ {"Asia-Test4", "\ud55c\uad6d\uc5b4\uae30\ud638"}, > ++ }; > ++ > ++ /** > ++ * Returns string containing given font style. This style could > ++ * be PLAIN, BOLD, ITALIC or combination of these styles. > ++ * > ++ * @param fontStyle selected font style, eg. Font.BOLD > ++ * @return textual representation of font style > ++ */ > ++ private static String getFontStyle(int fontStyle) > ++ { > ++ return new String[] > ++ // 0 1 2 1+2 > ++ { "PLAIN", "BOLD", "ITALIC", "BOLD+ITALIC" }[fontStyle]; > ++ } > ++ > ++ /** > ++ * Creates test image a renders one big character to it. > ++ * @param str string to be rendered > ++ * @param fontStyle selected font style > ++ * @param fontName selected font name > ++ * @return > ++ */ > ++ private BufferedImage createTestImage(String str, String fontName, int fontStyle) { > ++ BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); > ++ Graphics2D gc = image.createGraphics(); > ++ gc.setBackground(Color.WHITE); > ++ gc.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_OFF); > ++ gc.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING, RenderingHints.VALUE_TEXT_ANTIALIAS_OFF); > ++ gc.clearRect(0, 0, WIDTH, HEIGHT); > ++ gc.setFont(new Font(fontName, fontStyle, FONT_SIZE)); > ++ gc.setColor(Color.BLACK); > ++ gc.drawString(str, 0, HEIGHT - 40); > ++ gc.dispose(); > ++ return image; > ++ } > ++ > ++ /** > ++ * Creates destination image and then copies data from source image to it > ++ * @param src source image > ++ * @return destination image as copy of source image > ++ */ > ++ private BufferedImage createDestinationImage(BufferedImage src) > ++ { > ++ BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); > ++ src.copyData(image.getRaster()); > ++ return image; > ++ } > ++ > ++ /** > ++ * Removes long horizontal lines from image > ++ */ > ++ private void removeHorizontalLines(BufferedImage image) > ++ { > ++ for (int y = 0; y < image.getHeight(); y++) > ++ { > ++ int startX = -1, endX = -1; > ++ for (int x = 0; x < image.getWidth(); x++) > ++ { > ++ int color = image.getRaster().getSample(x, y, 0); > ++ if (startX < 0 && color <= BLACK_WHITE_THRESHOLD) { > ++ startX = x; > ++ //System.out.println("> " + y + "\t" + x); > ++ } > ++ if (startX > 0 && endX < 0 && color > BLACK_WHITE_THRESHOLD) > ++ { > ++ endX = x; > ++ //System.out.println("< " + y + "\t" + x); > ++ } > ++ } > ++ // remove long horizontal line, but only if this line found detected in image > ++ if (startX > 0 && endX > 0 && (endX - startX) > MINIMUM_HORIZONTAL_LINE_LENGTH) > ++ { > ++ for (int x = startX; x < endX; x++) { > ++ image.getRaster().setSample(x, y, 0, 255); > ++ } > ++ } > ++ } > ++ } > ++ > ++ /** > ++ * Removes long vertical lines from image > ++ */ > ++ private void removeVerticalLines(BufferedImage image) > ++ { > ++ for (int x = 0; x < image.getWidth(); x++) > ++ { > ++ int startY = -1, endY = -1; > ++ for (int y = 0; y < image.getHeight(); y++) > ++ { > ++ int color = image.getRaster().getSample(x, y, 0); > ++ if (startY < 0 && color <= BLACK_WHITE_THRESHOLD) > ++ { > ++ startY = y; > ++ } > ++ if (startY > 0 && endY < 0 && color > BLACK_WHITE_THRESHOLD) > ++ { > ++ endY = y; > ++ //System.out.println("< " + y + "\t" + x); > ++ } > ++ } > ++ // remove long vertical line, but only if this line found detected in image > ++ if (startY > 0 && endY > 0 && (endY - startY) > MINIMUM_VERTICAL_LINE_LENGTH) > ++ { > ++ for (int y = startY; y < endY; y++) { > ++ image.getRaster().setSample(x, y, 0, 255); > ++ } > ++ } > ++ } > ++ } > ++ > ++ /** > ++ * Test if image is almost empty (one large white area) > ++ * @param image > ++ * @return > ++ */ > ++ private boolean isImageAlmostEmpty(BufferedImage image) > ++ { > ++ int blackPixelCount = 0; > ++ for (int y = 0; y < image.getHeight(); y++) > ++ { > ++ for (int x = 0; x < image.getWidth(); x++) > ++ { > ++ if (image.getRaster().getSample(x, y, 0) < BLACK_WHITE_THRESHOLD) > ++ { > ++ blackPixelCount++; > ++ } > ++ } > ++ } > ++ return blackPixelCount < BLACK_PIXEL_COUNT_THRESHOLD; > ++ } > ++ > ++ private String constructImageFileName(String fontName, int fontStyle, int code, String suffix) > ++ { > ++ return fontName + "_" + getFontStyle(fontStyle) + "_" + code + "_" + suffix + ".png"; > ++ } > ++ > ++ public void runTest(boolean createImages) throws IOException > ++ { > ++ List badCharacters = new ArrayList(); > ++ for (String[] testedString : testedStrings) > ++ { > ++ for (String fontName : fontNames) > ++ { > ++ for (int fontStyle : fontStyles) > ++ { > ++ System.out.format("check string %s rendered by font %s with style %s\n", testedString[1], fontName, > ++ getFontStyle(fontStyle)); > ++ for (int i = 0; i < testedString[1].length(); i++) > ++ { > ++ String str = testedString[1].substring(i, 1 + i); > ++ int code = str.charAt(0); > ++ System.out.print(code + "\t"); > ++ BufferedImage src = createTestImage(str, fontName, fontStyle); > ++ BufferedImage dst = createDestinationImage(src); > ++ removeHorizontalLines(dst); > ++ removeVerticalLines(dst); > ++ > ++ if (createImages /*|| true*/) > ++ { > ++ ImageIO.write(src, "png", > ++ new File(constructImageFileName(fontName, fontStyle, code, "scr"))); > ++ ImageIO.write(dst, "png", > ++ new File(constructImageFileName(fontName, fontStyle, code, "dst"))); > ++ } > ++ > ++ if (isImageAlmostEmpty(dst)) > ++ { > ++ System.out.println("*** Error in rendering of character with code: " + code); > ++ badCharacters.add(Integer.valueOf(code)); > ++ } > ++ } > ++ System.out.println(); > ++ } > ++ } > ++ } > ++ // if at least one character is not rendered properly throw an exception > ++ if (!badCharacters.isEmpty()) > ++ { > ++ throw new RuntimeException("There are some broken characters: " + badCharacters.toString()); > ++ } > ++ System.out.println("done!"); > ++ } > ++ > ++ public static void main(String[] args) throws IOException > ++ { > ++ new InternationalFontsStyles().runTest(Arrays.asList(args).contains("-create-images")); > ++ } > ++} > > --- /dev/null 2010-06-29 11:10:08.737208357 +0200 > +++ openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsStyles.java 2011-01-17 17:06:44.452369000 +0100 > @@ -0,0 +1,277 @@ > +/* > + * Copyright 2011 Red Hat, Inc. All Rights Reserved. > + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. > + * > + * This code is free software; you can redistribute it and/or modify it > + * under the terms of the GNU General Public License version 2 only, as > + * published by the Free Software Foundation. > + * > + * This code is distributed in the hope that it will be useful, but WITHOUT > + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or > + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License > + * version 2 for more details (a copy is included in the LICENSE file that > + * accompanied this code). > + * > + * You should have received a copy of the GNU General Public License version > + * 2 along with this work; if not, write to the Free Software Foundation, > + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. > + */ > + > +import java.awt.Color; > +import java.awt.Font; > +import java.awt.Graphics2D; > +import java.awt.RenderingHints; > +import java.awt.image.BufferedImage; > +import java.io.File; > +import java.io.IOException; > +import java.util.Arrays; > +import java.util.List; > +import java.util.ArrayList; > + > +import javax.imageio.ImageIO; > + > +/** > + * @test > + * @run main InternationalFontsStyles > + * @author Pavel Tisnovsky > + * > + * @summary This test check if selected international characters could be > + * properly rendered with various font styles and logical names. > + * > + * This regression test check if selected international characters > + * could be properly rendered using various styles and logical font > + * names - the test check rendering using all combinations of logical > + * font names (Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, > + * Font.DIALOG, Font.DIALOG_INPUT) and font styles (Font.PLAIN, > + * Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC). > + * > + * The test is based on rendering certain characters from selected code > + * pages into BufferedImage. > + * > + * When the shape of selected character does not exists or font > + * configuration is broken, only empty rectangle is rendered instead of > + * the selected character shape. This rectangle is filtered and then > + * the destination image is tested whether it is empty (=white). > + * > + * If test images with rendered characters needs to be created use > + * following flag: -create-images > + * > + */ > +public class InternationalFontsStyles > +{ > + // all logical font names which are tested > + private static final String[] fontNames = {Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, Font.DIALOG, Font.DIALOG_INPUT}; > + > + // all font styles which are tested > + private static final int[] fontStyles = {Font.PLAIN, Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC}; > + > + // width and height of image where is each character rendered > + private static int WIDTH = 200; > + private static int HEIGHT = 200; > + > + // font size used for rendering > + private static final int FONT_SIZE = 160; > + > + private static final int MINIMUM_HORIZONTAL_LINE_LENGTH = 70; > + private static final int MINIMUM_VERTICAL_LINE_LENGTH = 80; > + private static final int BLACK_WHITE_THRESHOLD = 128; > + private static final int BLACK_PIXEL_COUNT_THRESHOLD = WIDTH * HEIGHT / 1000; > + > + private static final String[][] testedStrings = { > + {"Latin-1", "abcdefABCDEF"}, > + {"Latin-2", "\u011b\u0161\u010d\u0159\u017e\u00fd\u00e1\u00ed\u00e9\u00fa\u016f\u013e\u0148"}, > + {"Cyrilic", "\u0414\u0417\u0418\u0472\u0424\u0425\u0470\u0460\u0426"}, > + {"Greek", "\u03b2\u03be\u03b3\u03b4\u03c0\u03b5\u03c1\u03b6\u03a3\u03c3\u03c2\u03b7\u03c4\u03b8\u03c5\u03a9"}, > + {"Asia-Test1", "\u4f53\u4e2d\u6587\u7b26\u53f7"}, > + {"Asia-Test2", "\u7e41\u9ad4\u4e2d\u6587\u7b26\u865f"}, > + {"Asia-Test3", "\u65e5\u672c\u306e\u8c61\u5fb4"}, > + {"Asia-Test4", "\ud55c\uad6d\uc5b4\uae30\ud638"}, > + }; > + > + /** > + * Returns string containing given font style. This style could > + * be PLAIN, BOLD, ITALIC or combination of these styles. > + * > + * @param fontStyle selected font style, eg. Font.BOLD > + * @return textual representation of font style > + */ > + private static String getFontStyle(int fontStyle) > + { > + return new String[] > + // 0 1 2 1+2 > + { "PLAIN", "BOLD", "ITALIC", "BOLD+ITALIC" }[fontStyle]; > + } > + > + /** > + * Creates test image a renders one big character to it. > + * @param str string to be rendered > + * @param fontStyle selected font style > + * @param fontName selected font name > + * @return > + */ > + private BufferedImage createTestImage(String str, String fontName, int fontStyle) { > + BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); > + Graphics2D gc = image.createGraphics(); > + gc.setBackground(Color.WHITE); > + gc.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_OFF); > + gc.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING, RenderingHints.VALUE_TEXT_ANTIALIAS_OFF); > + gc.clearRect(0, 0, WIDTH, HEIGHT); > + gc.setFont(new Font(fontName, fontStyle, FONT_SIZE)); > + gc.setColor(Color.BLACK); > + gc.drawString(str, 0, HEIGHT - 40); > + gc.dispose(); > + return image; > + } > + > + /** > + * Creates destination image and then copies data from source image to it > + * @param src source image > + * @return destination image as copy of source image > + */ > + private BufferedImage createDestinationImage(BufferedImage src) > + { > + BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); > + src.copyData(image.getRaster()); > + return image; > + } > + > + /** > + * Removes long horizontal lines from image > + */ > + private void removeHorizontalLines(BufferedImage image) > + { > + for (int y = 0; y < image.getHeight(); y++) > + { > + int startX = -1, endX = -1; > + for (int x = 0; x < image.getWidth(); x++) > + { > + int color = image.getRaster().getSample(x, y, 0); > + if (startX < 0 && color <= BLACK_WHITE_THRESHOLD) { > + startX = x; > + //System.out.println("> " + y + "\t" + x); > + } > + if (startX > 0 && endX < 0 && color > BLACK_WHITE_THRESHOLD) > + { > + endX = x; > + //System.out.println("< " + y + "\t" + x); > + } > + } > + // remove long horizontal line, but only if this line found detected in image > + if (startX > 0 && endX > 0 && (endX - startX) > MINIMUM_HORIZONTAL_LINE_LENGTH) > + { > + for (int x = startX; x < endX; x++) { > + image.getRaster().setSample(x, y, 0, 255); > + } > + } > + } > + } > + > + /** > + * Removes long vertical lines from image > + */ > + private void removeVerticalLines(BufferedImage image) > + { > + for (int x = 0; x < image.getWidth(); x++) > + { > + int startY = -1, endY = -1; > + for (int y = 0; y < image.getHeight(); y++) > + { > + int color = image.getRaster().getSample(x, y, 0); > + if (startY < 0 && color <= BLACK_WHITE_THRESHOLD) > + { > + startY = y; > + } > + if (startY > 0 && endY < 0 && color > BLACK_WHITE_THRESHOLD) > + { > + endY = y; > + //System.out.println("< " + y + "\t" + x); > + } > + } > + // remove long vertical line, but only if this line found detected in image > + if (startY > 0 && endY > 0 && (endY - startY) > MINIMUM_VERTICAL_LINE_LENGTH) > + { > + for (int y = startY; y < endY; y++) { > + image.getRaster().setSample(x, y, 0, 255); > + } > + } > + } > + } > + > + /** > + * Test if image is almost empty (one large white area) > + * @param image > + * @return > + */ > + private boolean isImageAlmostEmpty(BufferedImage image) > + { > + int blackPixelCount = 0; > + for (int y = 0; y < image.getHeight(); y++) > + { > + for (int x = 0; x < image.getWidth(); x++) > + { > + if (image.getRaster().getSample(x, y, 0) < BLACK_WHITE_THRESHOLD) > + { > + blackPixelCount++; > + } > + } > + } > + return blackPixelCount < BLACK_PIXEL_COUNT_THRESHOLD; > + } > + > + private String constructImageFileName(String fontName, int fontStyle, int code, String suffix) > + { > + return fontName + "_" + getFontStyle(fontStyle) + "_" + code + "_" + suffix + ".png"; > + } > + > + public void runTest(boolean createImages) throws IOException > + { > + List badCharacters = new ArrayList(); > + for (String[] testedString : testedStrings) > + { > + for (String fontName : fontNames) > + { > + for (int fontStyle : fontStyles) > + { > + System.out.format("check string %s rendered by font %s with style %s\n", testedString[1], fontName, > + getFontStyle(fontStyle)); > + for (int i = 0; i < testedString[1].length(); i++) > + { > + String str = testedString[1].substring(i, 1 + i); > + int code = str.charAt(0); > + System.out.print(code + "\t"); > + BufferedImage src = createTestImage(str, fontName, fontStyle); > + BufferedImage dst = createDestinationImage(src); > + removeHorizontalLines(dst); > + removeVerticalLines(dst); > + > + if (createImages /*|| true*/) > + { > + ImageIO.write(src, "png", > + new File(constructImageFileName(fontName, fontStyle, code, "scr"))); > + ImageIO.write(dst, "png", > + new File(constructImageFileName(fontName, fontStyle, code, "dst"))); > + } > + > + if (isImageAlmostEmpty(dst)) > + { > + System.out.println("*** Error in rendering of character with code: " + code); > + badCharacters.add(Integer.valueOf(code)); > + } > + } > + System.out.println(); > + } > + } > + } > + // if at least one character is not rendered properly throw an exception > + if (!badCharacters.isEmpty()) > + { > + throw new RuntimeException("There are some broken characters: " + badCharacters.toString()); > + } > + System.out.println("done!"); > + } > + > + public static void main(String[] args) throws IOException > + { > + new InternationalFontsStyles().runTest(Arrays.asList(args).contains("-create-images")); > + } > +} > > 2011-01-18 Pavel Tisnovsky > > * Makefile.am: Apply patch. > * patches/jtreg-international-fonts-styles.patch: > Added new font regression test - InternationalFontsStyles > > 2011-01-07 Andrew John Hughes > > * patches/jtreg-TestXEmbedServer-fix.patch: > Moved to... > * Makefile.am: > Fix path to above patch. Only apply jtreg-6929067-fix.patch > when building hs19. > * patches/openjdk/6560348-jtreg-TestXEmbedServer-fix.patch: > ... OpenJDK patch with appropriate bug ID. > -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From andrew at icedtea.classpath.org Tue Jan 18 06:26:09 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Tue, 18 Jan 2011 14:26:09 +0000 Subject: /hg/release/icedtea6-1.7: 4 new changesets Message-ID: changeset 6f7d633c355a in /hg/release/icedtea6-1.7 details: http://icedtea.classpath.org/hg/release/icedtea6-1.7?cmd=changeset;node=6f7d633c355a author: Andrew John Hughes date: Thu Dec 16 19:51:32 2010 +0000 RH663680, CVE-2010-4351: JNLP SecurityManager bypass 2010-12-16 Omair Majid RH663680, CVE-2010-4351: * NEWS: List issue. * rt/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: Make sure SecurityException is thrown if necessary. changeset 8784e22fa289 in /hg/release/icedtea6-1.7 details: http://icedtea.classpath.org/hg/release/icedtea6-1.7?cmd=changeset;node=8784e22fa289 author: Andrew John Hughes date: Thu Dec 16 22:32:32 2010 +0000 Bump to 1.7.7. 2010-12-16 Andrew John Hughes * NEWS: Fix formatting. * configure.ac: Bump to 1.7.7. changeset 0ee477f3daf2 in /hg/release/icedtea6-1.7 details: http://icedtea.classpath.org/hg/release/icedtea6-1.7?cmd=changeset;node=0ee477f3daf2 author: Andrew John Hughes date: Tue Jan 18 14:15:15 2011 +0000 Added tag icedtea6-1.7.7 for changeset 8784e22fa289 changeset cb6c55ac1cd6 in /hg/release/icedtea6-1.7 details: http://icedtea.classpath.org/hg/release/icedtea6-1.7?cmd=changeset;node=cb6c55ac1cd6 author: Andrew John Hughes date: Tue Jan 18 14:25:25 2011 +0000 Merge diffstat: 10 files changed, 5086 insertions(+), 182 deletions(-) .hgtags | 1 ChangeLog | 30 Makefile.am | 5 NEWS | 9 configure.ac | 2 patches/fonts-rhel.patch | 146 patches/openjdk/6541476-png-iTXt-chunk.patch | 549 + patches/openjdk/6687968-pngimagereader_mem_leak.patch | 126 patches/openjdk/6782079-png_metadata_oom.patch | 4122 ++++++++++++++ rt/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java | 278 diffs (truncated from 5667 to 500 lines): diff -r af20d64bc8b9 -r cb6c55ac1cd6 .hgtags --- a/.hgtags Thu Dec 16 19:41:01 2010 +0000 +++ b/.hgtags Tue Jan 18 14:25:25 2011 +0000 @@ -28,3 +28,4 @@ 0000000000000000000000000000000000000000 0000000000000000000000000000000000000000 icedtea6-1.7.5 6282308dea7401c00bb779bd4ab2ff7f4d269114 icedtea6-1.7.5 f5667b14ce7eb0dc9b121164a28d3b3fcd516c61 icedtea6-1.7.6 +8784e22fa2897df7373ca8869e7dab8d3af8c8c9 icedtea6-1.7.7 diff -r af20d64bc8b9 -r cb6c55ac1cd6 ChangeLog --- a/ChangeLog Thu Dec 16 19:41:01 2010 +0000 +++ b/ChangeLog Tue Jan 18 14:25:25 2011 +0000 @@ -1,3 +1,33 @@ 2010-12-16 Andrew John Hughes + + Backport S6687968, S6541476, S6782079 + * Makefile.am: Add missing "\" to the patch list, update to include + new patches. + * NEWS: Updated. + * patches/openjdk/6687968-pngimagereader_mem_leak.patch: Backport to allow + S6541476 fix to apply cleanly. + * patches/openjdk/6541476-png-iTXt-chunk.patch: Backport to fix iTXt chunk + handling for png images. Also addresses RH665355. + * patches/openjdk/6782079-png_metadata_oom.patch: Backport to fix + potential OOM error when reading metadata on truncated pngs. + +2010-12-23 Jiri Vanek + + * NEWS: Updated with rh.bugzilas. + * patches/fonts-rhel.patch:repaired rhel 6 fonts configuration. + +2010-12-16 Andrew John Hughes + + * NEWS: Fix formatting. + * configure.ac: Bump to 1.7.7. + +2010-12-16 Omair Majid + + RH663680, CVE-2010-4351: + * NEWS: List issue. + * rt/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: + Make sure SecurityException is thrown if necessary. + 2010-12-16 Andrew John Hughes * NEWS: Fix issue placement. diff -r af20d64bc8b9 -r cb6c55ac1cd6 Makefile.am --- a/Makefile.am Thu Dec 16 19:41:01 2010 +0000 +++ b/Makefile.am Tue Jan 18 14:25:25 2011 +0000 @@ -380,7 +380,10 @@ ICEDTEA_PATCHES = \ patches/openjdk/6438179-systray_check.patch \ patches/openjdk/4356282-opentype.patch \ patches/openjdk/6954424-opentype_javadoc.patch \ - patches/openjdk/6795356-proxylazyvalue-leak.patch + patches/openjdk/6795356-proxylazyvalue-leak.patch \ + patches/openjdk/6687968-pngimagereader_mem_leak.patch \ + patches/openjdk/6541476-png-iTXt-chunk.patch \ + patches/openjdk/6782079-png_metadata_oom.patch if WITH_ALT_HSBUILD ICEDTEA_PATCHES += patches/hotspot/$(HSBUILD)/openjdk-6886353-ignore_deoptimizealot.patch \ diff -r af20d64bc8b9 -r cb6c55ac1cd6 NEWS --- a/NEWS Thu Dec 16 19:41:01 2010 +0000 +++ b/NEWS Tue Jan 18 14:25:25 2011 +0000 @@ -8,7 +8,10 @@ GX - http://bugs.gentoo.org/show_bug.cg CVE-XXXX-YYYY: http://www.cve.mitre.org/cgi-bin/cvename.cgi?name=XXXX-YYYY -New in release 1.7.7 (201X-XX-XX): +New in release 1.7.7 (2011-01-12): + +* Security updates + - RH663680, CVE-2010-4351: IcedTea JNLP SecurityManager bypass * Backports - S6438179, RH569121: XToolkit.isTraySupported() result has nothing to do with the system tray - S4356282: RFE: JDK should support OpenType/CFF fonts @@ -18,8 +21,12 @@ New in release 1.7.7 (201X-XX-XX): - S6967433: dashed lines broken when using scaling transforms. - S6976265: No STROKE_CONTROL - S6967434, PR450, RH530642: Round joins/caps of scaled up lines have poor quality. + - S6687968: PNGImageReader leaks native memory through an Inflater + - S6541476, RH665355: PNG imageio plugin incorrectly handles iTXt chunk + - S6782079: PNG: reading metadata may cause OOM on truncated images * Fixes: - S7003777, RH647674: JTextPane produces incorrect content after parsing the html text + - RH647157,RH582455: Update fontconfig files for rhel 6 New in release 1.7.6 (2010-11-24): diff -r af20d64bc8b9 -r cb6c55ac1cd6 configure.ac --- a/configure.ac Thu Dec 16 19:41:01 2010 +0000 +++ b/configure.ac Tue Jan 18 14:25:25 2011 +0000 @@ -1,4 +1,4 @@ AC_INIT([icedtea6], [1.7.7pre], [distro- -AC_INIT([icedtea6], [1.7.7pre], [distro-pkg-dev at openjdk.java.net]) +AC_INIT([icedtea6], [1.7.7], [distro-pkg-dev at openjdk.java.net]) AM_INIT_AUTOMAKE([1.9 tar-pax foreign]) AC_CONFIG_FILES([Makefile]) diff -r af20d64bc8b9 -r cb6c55ac1cd6 patches/fonts-rhel.patch --- a/patches/fonts-rhel.patch Thu Dec 16 19:41:01 2010 +0000 +++ b/patches/fonts-rhel.patch Tue Jan 18 14:25:25 2011 +0000 @@ -11,10 +11,9 @@ diff -Nru openjdk.orig/jdk/make/sun/awt/ else FONTCONFIGS_SRC = $(CLOSED_SRC)/solaris/classes/sun/awt/fontconfigs -diff -Nru openjdk.orig/jdk/src/solaris/classes/sun/awt/fontconfigs/linux.fontconfig.RedHat.6.0.properties openjdk/jdk/src/solaris/classes/sun/awt/fontconfigs/linux.fontconfig.RedHat.6.0.properties ---- openjdk.orig/jdk/src/solaris/classes/sun/awt/fontconfigs/linux.fontconfig.RedHat.6.0.properties 1970-01-01 01:00:00.000000000 +0100 -+++ openjdk/jdk/src/solaris/classes/sun/awt/fontconfigs/linux.fontconfig.RedHat.6.0.properties 2010-08-12 22:52:55.716852554 +0100 -@@ -0,0 +1,376 @@ +--- /dev/null 2010-12-20 09:26:08.850062021 +0100 ++++ openjdk/jdk/src/solaris/classes/sun/awt/fontconfigs/linux.fontconfig.RedHat.6.0.properties 2010-12-22 11:21:32.606781127 +0100 +@@ -0,0 +1,441 @@ +# +# Copyright (c) 2007, Oracle and/or its affiliates. All rights reserved. +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -42,16 +41,19 @@ diff -Nru openjdk.orig/jdk/src/solaris/c + +# Version + -+# Uses Fedora 9 fonts and file paths. ++# Uses Fedora 14 fonts and file paths, added VL-gothic +version=1 + +# Component Font Mappings + +dialog.plain.latin-1=DejaVu Sans -+dialog.plain.japanese-x0208=Sazanami Gothic ++#dialog.plain.japanese-x0208=Sazanami Gothic ++dialog.plain.japanese-x0208=VL PGothic +dialog.plain.korean=Baekmuk Gulim +dialog.plain.chinese-big5=AR PL ShanHeiSun Uni +dialog.plain.chinese-gb18030=AR PL ShanHeiSun Uni ++dialog.plain.assamese=Lohit Assamese ++dialog.plain.devanagari=Lohit Devanagari +dialog.plain.bengali=Lohit Bengali +dialog.plain.gujarati=Lohit Gujarati +dialog.plain.hindi=Lohit Hindi @@ -63,10 +65,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +dialog.plain.sinhala=LKLUG + +dialog.bold.latin-1=DejaVu Sans Bold -+dialog.bold.japanese-x0208=Sazanami Gothic ++#dialog.bold.japanese-x0208=Sazanami Gothic ++dialog.bold.japanese-x0208=VL PGothic +dialog.bold.korean=Baekmuk Gulim +dialog.bold.chinese-big5=AR PL ShanHeiSun Uni +dialog.bold.chinese-gb18030=AR PL ShanHeiSun Uni ++dialog.bold.assamese=Lohit Assamese ++dialog.bold.devanagari=Lohit Devanagari +dialog.bold.bengali=Lohit Bengali +dialog.bold.gujarati=Lohit Gujarati +dialog.bold.hindi=Lohit Hindi @@ -78,10 +83,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +dialog.bold.sinhala=LKLUG + +dialog.italic.latin-1=DejaVu Sans Oblique -+dialog.italic.japanese-x0208=Sazanami Gothic ++#dialog.italic.japanese-x0208=Sazanami Gothic ++dialog.italic.japanese-x0208=VL PGothic +dialog.italic.korean=Baekmuk Gulim +dialog.italic.chinese-big5=AR PL ShanHeiSun Uni +dialog.italic.chinese-gb18030=AR PL ShanHeiSun Uni ++dialog.italic.assamese=Lohit Assamese ++dialog.italic.devanagari=Lohit Devanagari +dialog.italic.bengali=Lohit Bengali +dialog.italic.gujarati=Lohit Gujarati +dialog.italic.hindi=Lohit Hindi @@ -93,10 +101,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +dialog.italic.sinhala=LKLUG + +dialog.bolditalic.latin-1=DejaVu Sans Bold Oblique -+dialog.bolditalic.japanese-x0208=Sazanami Gothic ++#dialog.bolditalic.japanese-x0208=Sazanami Gothic ++dialog.bolditalic.japanese-x0208=VL PGothic +dialog.bolditalic.korean=Baekmuk Gulim +dialog.bolditalic.chinese-big5=AR PL ShanHeiSun Uni +dialog.bolditalic.chinese-gb18030=AR PL ShanHeiSun Uni ++dialog.bolditalic.assamese=Lohit Assamese ++dialog.bolditalic.devanagari=Lohit Devanagari +dialog.bolditalic.bengali=Lohit Bengali +dialog.bolditalic.gujarati=Lohit Gujarati +dialog.bolditalic.hindi=Lohit Hindi @@ -108,10 +119,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +dialog.bolditalic.sinhala=LKLUG + +sansserif.plain.latin-1=DejaVu Sans -+sansserif.plain.japanese-x0208=Sazanami Gothic ++#sansserif.plain.japanese-x0208=Sazanami Gothic ++sansserif.plain.japanese-x0208=VL PGothic +sansserif.plain.korean=Baekmuk Gulim +sansserif.plain.chinese-big5=AR PL ShanHeiSun Uni +sansserif.plain.chinese-gb18030=AR PL ShanHeiSun Uni ++sansserif.plain.assamese=Lohit Assamese ++sansserif.plain.devanagari=Lohit Devanagari +sansserif.plain.bengali=Lohit Bengali +sansserif.plain.gujarati=Lohit Gujarati +sansserif.plain.hindi=Lohit Hindi @@ -123,10 +137,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +sansserif.plain.sinhala=LKLUG + +sansserif.bold.latin-1=DejaVu Sans Bold -+sansserif.bold.japanese-x0208=Sazanami Gothic ++#sansserif.bold.japanese-x0208=Sazanami Gothic ++sansserif.bold.japanese-x0208=VL PGothic +sansserif.bold.korean=Baekmuk Gulim +sansserif.bold.chinese-big5=AR PL ShanHeiSun Uni +sansserif.bold.chinese-gb18030=AR PL ShanHeiSun Uni ++sansserif.bold.assamese=Lohit Assamese ++sansserif.bold.devanagari=Lohit Devanagari +sansserif.bold.bengali=Lohit Bengali +sansserif.bold.gujarati=Lohit Gujarati +sansserif.bold.hindi=Lohit Hindi @@ -138,10 +155,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +sansserif.bold.sinhala=LKLUG + +sansserif.italic.latin-1=DejaVu Sans Oblique -+sansserif.italic.japanese-x0208=Sazanami Gothic ++#sansserif.italic.japanese-x0208=Sazanami Gothic ++sansserif.italic.japanese-x0208=VL PGothic +sansserif.italic.korean=Baekmuk Gulim +sansserif.italic.chinese-big5=AR PL ShanHeiSun Uni +sansserif.italic.chinese-gb18030=AR PL ShanHeiSun Uni ++sansserif.italic.assamese=Lohit Assamese ++sansserif.italic.devanagari=Lohit Devanagari +sansserif.italic.bengali=Lohit Bengali +sansserif.italic.gujarati=Lohit Gujarati +sansserif.italic.hindi=Lohit Hindi @@ -153,10 +173,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +sansserif.italic.sinhala=LKLUG + +sansserif.bolditalic.latin-1=DejaVu Sans Bold Oblique -+sansserif.bolditalic.japanese-x0208=Sazanami Gothic ++#sansserif.bolditalic.japanese-x0208=Sazanami Gothic ++sansserif.bolditalic.japanese-x0208=VL PGothic +sansserif.bolditalic.korean=Baekmuk Gulim +sansserif.bolditalic.chinese-big5=AR PL ShanHeiSun Uni +sansserif.bolditalic.chinese-gb18030=AR PL ShanHeiSun Uni ++sansserif.bolditalic.assamese=Lohit Assamese ++sansserif.bolditalic.devanagari=Lohit Devanagari +sansserif.bolditalic.bengali=Lohit Bengali +sansserif.bolditalic.gujarati=Lohit Gujarati +sansserif.bolditalic.hindi=Lohit Hindi @@ -168,10 +191,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +sansserif.bolditalic.sinhala=LKLUG + +serif.plain.latin-1=DejaVu Serif -+serif.plain.japanese-x0208=Sazanami Mincho ++#serif.plain.japanese-x0208=Sazanami Mincho ++serif.plain.japanese-x0208=VL PGothic +serif.plain.korean=Baekmuk Batang +serif.plain.chinese-big5=AR PL ZenKai Uni +serif.plain.chinese-gb18030=AR PL ZenKai Uni ++serif.plain.assamese=Lohit Assamese ++serif.plain.devanagari=Lohit Devanagari +serif.plain.bengali=Lohit Bengali +serif.plain.gujarati=Lohit Gujarati +serif.plain.hindi=Lohit Hindi @@ -183,10 +209,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +serif.plain.sinhala=LKLUG + +serif.bold.latin-1=DejaVu Serif Bold -+serif.bold.japanese-x0208=Sazanami Mincho ++#serif.bold.japanese-x0208=Sazanami Mincho ++serif.bold.japanese-x0208=VL PGothic +serif.bold.korean=Baekmuk Batang +serif.bold.chinese-big5=AR PL ZenKai Uni +serif.bold.chinese-gb18030=AR PL ZenKai Uni ++serif.bold.assamese=Lohit Assamese ++serif.bold.devanagari=Lohit Devanagari +serif.bold.bengali=Lohit Bengali +serif.bold.gujarati=Lohit Gujarati +serif.bold.hindi=Lohit Hindi @@ -198,10 +227,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +serif.bold.sinhala=LKLUG + +serif.italic.latin-1=DejaVu Serif Oblique -+serif.italic.japanese-x0208=Sazanami Mincho ++#serif.italic.japanese-x0208=Sazanami Mincho ++serif.italic.japanese-x0208=VL PGothic +serif.italic.korean=Baekmuk Batang +serif.italic.chinese-big5=AR PL ZenKai Uni +serif.italic.chinese-gb18030=AR PL ZenKai Uni ++serif.italic.assamese=Lohit Assamese ++serif.italic.devanagari=Lohit Devanagari +serif.italic.bengali=Lohit Bengali +serif.italic.gujarati=Lohit Gujarati +serif.italic.hindi=Lohit Hindi @@ -213,10 +245,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +serif.italic.sinhala=LKLUG + +serif.bolditalic.latin-1=DejaVu Serif Bold Oblique -+serif.bolditalic.japanese-x0208=Sazanami Mincho ++#serif.bolditalic.japanese-x0208=Sazanami Mincho ++serif.bolditalic.japanese-x0208=VL PGothic +serif.bolditalic.korean=Baekmuk Batang +serif.bolditalic.chinese-big5=AR PL ZenKai Uni +serif.bolditalic.chinese-gb18030=AR PL ZenKai Uni ++serif.bolditalic.assamese=Lohit Assamese ++serif.bolditalic.devanagari=Lohit Devanagari +serif.bolditalic.bengali=Lohit Bengali +serif.bolditalic.gujarati=Lohit Gujarati +serif.bolditalic.hindi=Lohit Hindi @@ -228,10 +263,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +serif.bolditalic.sinhala=LKLUG + +monospaced.plain.latin-1=DejaVu Sans Mono -+monospaced.plain.japanese-x0208=Sazanami Gothic ++#monospaced.plain.japanese-x0208=Sazanami Gothic ++monospaced.plain.japanese-x0208=VL Gothic +monospaced.plain.korean=Baekmuk Gulim +monospaced.plain.chinese-big5=AR PL ShanHeiSun Uni +monospaced.plain.chinese-gb18030=AR PL ShanHeiSun Uni ++monospaced.plain.assamese=Lohit Assamese ++monospaced.plain.devanagari=Lohit Devanagari +monospaced.plain.bengali=Lohit Bengali +monospaced.plain.gujarati=Lohit Gujarati +monospaced.plain.hindi=Lohit Hindi @@ -243,10 +281,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +monospaced.plain.sinhala=LKLUG + +monospaced.bold.latin-1=DejaVu Sans Mono Bold -+monospaced.bold.japanese-x0208=Sazanami Gothic ++#monospaced.bold.japanese-x0208=Sazanami Gothic ++monospaced.bold.japanese-x0208=VL Gothic +monospaced.bold.korean=Baekmuk Gulim +monospaced.bold.chinese-big5=AR PL ShanHeiSun Uni +monospaced.bold.chinese-gb18030=AR PL ShanHeiSun Uni ++monospaced.bold.assamese=Lohit Assamese ++monospaced.bold.devanagari=Lohit Devanagari +monospaced.bold.bengali=Lohit Bengali +monospaced.bold.gujarati=Lohit Gujarati +monospaced.bold.hindi=Lohit Hindi @@ -258,10 +299,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +monospaced.bold.sinhala=LKLUG + +monospaced.italic.latin-1=DejaVu Sans Mono Oblique -+monospaced.italic.japanese-x0208=Sazanami Gothic ++#monospaced.italic.japanese-x0208=Sazanami Gothic ++monospaced.italic.japanese-x0208=VL Gothic +monospaced.italic.korean=Baekmuk Gulim +monospaced.italic.chinese-big5=AR PL ShanHeiSun Uni +monospaced.italic.chinese-gb18030=AR PL ShanHeiSun Uni ++monospaced.italic.assamese=Lohit Assamese ++monospaced.italic.devanagari=Lohit Devanagari +monospaced.italic.bengali=Lohit Bengali +monospaced.italic.gujarati=Lohit Gujarati +monospaced.italic.hindi=Lohit Hindi @@ -273,10 +317,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +monospaced.italic.sinhala=LKLUG + +monospaced.bolditalic.latin-1=DejaVu Sans Mono Bold Oblique -+monospaced.bolditalic.japanese-x0208=Sazanami Gothic ++#monospaced.bolditalic.japanese-x0208=Sazanami Gothic ++monospaced.bolditalic.japanese-x0208=VL Gothic +monospaced.bolditalic.korean=Baekmuk Gulim +monospaced.bolditalic.chinese-big5=AR PL ShanHeiSun Uni +monospaced.bolditalic.chinese-gb18030=AR PL ShanHeiSun Uni ++monospaced.bolditalic.assamese=Lohit Assamese ++monospaced.bolditalic.devanagari=Lohit Devanagari +monospaced.bolditalic.bengali=Lohit Bengali +monospaced.bolditalic.gujarati=Lohit Gujarati +monospaced.bolditalic.hindi=Lohit Hindi @@ -288,10 +335,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +monospaced.bolditalic.sinhala=LKLUG + +dialoginput.plain.latin-1=DejaVu Sans Mono -+dialoginput.plain.japanese-x0208=Sazanami Gothic ++#dialoginput.plain.japanese-x0208=Sazanami Gothic ++dialoginput.plain.japanese-x0208=VL PGothic +dialoginput.plain.korean=Baekmuk Gulim +dialoginput.plain.chinese-big5=AR PL ShanHeiSun Uni +dialoginput.plain.chinese-gb18030=AR PL ShanHeiSun Uni ++dialoginput.plain.assamese=Lohit Assamese ++dialoginput.plain.devanagari=Lohit Devanagari +dialoginput.plain.bengali=Lohit Bengali +dialoginput.plain.gujarati=Lohit Gujarati +dialoginput.plain.hindi=Lohit Hindi @@ -303,10 +353,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +dialoginput.plain.sinhala=LKLUG + +dialoginput.bold.latin-1=DejaVu Sans Mono Bold -+dialoginput.bold.japanese-x0208=Sazanami Gothic ++#dialoginput.bold.japanese-x0208=Sazanami Gothic ++dialoginput.bold.japanese-x0208=VL PGothic +dialoginput.bold.korean=Baekmuk Gulim +dialoginput.bold.chinese-big5=AR PL ShanHeiSun Uni +dialoginput.bold.chinese-gb18030=AR PL ShanHeiSun Uni ++dialoginput.bold.assamese=Lohit Assamese ++dialoginput.bold.devanagari=Lohit Devanagari +dialoginput.bold.bengali=Lohit Bengali +dialoginput.bold.gujarati=Lohit Gujarati +dialoginput.bold.hindi=Lohit Hindi @@ -318,10 +371,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +dialoginput.bold.sinhala=LKLUG + +dialoginput.italic.latin-1=DejaVu Sans Mono Oblique -+dialoginput.italic.japanese-x0208=Sazanami Gothic ++#dialoginput.italic.japanese-x0208=Sazanami Gothic ++dialoginput.italic.japanese-x0208=VL PGothic +dialoginput.italic.korean=Baekmuk Gulim +dialoginput.italic.chinese-big5=AR PL ShanHeiSun Uni +dialoginput.italic.chinese-gb18030=AR PL ShanHeiSun Uni ++dialoginput.italic.assamese=Lohit Assamese ++dialoginput.italic.devanagari=Lohit Devanagari +dialoginput.italic.bengali=Lohit Bengali +dialoginput.italic.gujarati=Lohit Gujarati +dialoginput.italic.hindi=Lohit Hindi @@ -333,10 +389,13 @@ diff -Nru openjdk.orig/jdk/src/solaris/c +dialoginput.italic.sinhala=LKLUG + +dialoginput.bolditalic.latin-1=DejaVu Sans Mono Bold Oblique -+dialoginput.bolditalic.japanese-x0208=Sazanami Gothic ++#dialoginput.bolditalic.japanese-x0208=Sazanami Gothic ++dialoginput.bolditalic.japanese-x0208=VL PGothic +dialoginput.bolditalic.korean=Baekmuk Gulim +dialoginput.bolditalic.chinese-big5=AR PL ShanHeiSun Uni +dialoginput.bolditalic.chinese-gb18030=AR PL ShanHeiSun Uni ++dialoginput.bolditalic.assamese=Lohit Assamese ++dialoginput.bolditalic.devanagari=Lohit Devanagari +dialoginput.bolditalic.bengali=Lohit Bengali +dialoginput.bolditalic.gujarati=Lohit Gujarati +dialoginput.bolditalic.hindi=Lohit Hindi @@ -370,24 +429,29 @@ diff -Nru openjdk.orig/jdk/src/solaris/c + +filename.DejaVu_Serif=/usr/share/fonts/dejavu/DejaVuSerif.ttf +filename.DejaVu_Serif_Bold=/usr/share/fonts/dejavu/DejaVuSerif-Bold.ttf -+filename.DejaVu_Serif_Oblique=/usr/share/fonts/dejavu/DejaVuSerif-Oblique.ttf ++filename.DejaVu_Serif_Oblique=/usr/share/fonts/dejavu/DejaVuSerif-Oblique.ttfok +filename.DejaVu_Serif_Bold_Oblique=/usr/share/fonts/dejavu/DejaVuSerif-BoldOblique.ttf + -+filename.Sazanami_Gothic=/usr/share/fonts/sazanami-fonts-gothic/sazanami-gothic.ttf -+filename.Sazanami_Mincho=/usr/share/fonts/sazanami-fonts-mincho/sazanami-mincho.ttf -+filename.AR_PL_ShanHeiSun_Uni=/usr/share/fonts/cjkunifonts-uming/uming.ttc -+filename.AR_PL_ZenKai_Uni=/usr/share/fonts/cjkunifonts-ukai/ukai.ttc -+filename.Baekmuk_Gulim=/usr/share/fonts/baekmuk-ttf-gulim/gulim.ttf -+filename.Baekmuk_Batang=/usr/share/fonts/baekmuk-ttf-batang/batang.ttf ++#filename.Sazanami_Gothic=/usr/share/fonts/sazanami/gothic/sazanami-gothic.ttf ++#filename.Sazanami_Mincho=/usr/share/fonts/sazanami/mincho/sazanami-mincho.ttf ++filename.VL_Gothic=/usr/share/fonts/vlgothic/VL-Gothic-Regular.ttf ++filename.VL_PGothic=/usr/share/fonts/svlgothic/VL-PGothic-Regular.ttf ++filename.AR_PL_ShanHeiSun_Uni=/usr/share/fonts/cjkuni-uming/uming.ttc ++filename.AR_PL_ZenKai_Uni=/usr/share/fonts/cjkuni-ukai/ukai.ttc ++filename.Baekmuk_Gulim=/usr/share/fonts/baekmuk-ttf/gulim.ttf ++filename.Baekmuk_Batang=/usr/share/fonts/baekmuk-ttf/batang.ttf + -+filename.Lohit_Bengali=/usr/share/fonts/lohit-bengali/lohit_bn.ttf -+filename.Lohit_Gujarati=/usr/share/fonts/lohit-gujarati/lohit_gu.ttf -+filename.Lohit_Hindi=/usr/share/fonts/lohit-hindi/lohit_hi.ttf -+filename.Lohit_Kannda=/usr/share/fonts/lohit-kannada/lohit_kn.ttf -+filename.Lohit_Malayalam=/usr/share/fonts/lohit-malayalam/lohit_ml.ttf -+filename.Lohit_Oriya=/usr/share/fonts/lohit-oriya/lohit_or.ttf -+filename.Lohit_Punjabi=/usr/share/fonts/lohit-punjabi/lohit_pa.ttf -+filename.Lohit_Tamil=/usr/share/fonts/lohit-tamil/lohit_ta.ttf -+filename.Lohit_Telugu=/usr/share/fonts/lohit-telugu/lohit_te.ttf ++filename.Lohit_Assamese=/usr/share/fonts/lohit-assamese/Lohit-Assamese.ttf ++filename.Lohit_Devanagari=/usr/share/fonts/lohit-devanagari/Lohit-Devanagari.ttf ++filename.Lohit_Bengali=/usr/share/fonts/lohit-bengali/Lohit-Bengali.ttf ++filename.Lohit_Gujarati=/usr/share/fonts/lohit-gujarati/Lohit-Gujarati.ttf ++filename.Lohit_Hindi=/usr/share/fonts/lohit-devanagari/Lohit-Devanagari.ttf ++filename.Lohit_Kannda=/usr/share/fonts/lohit-kannada/Lohit-Kannada.ttf ++filename.Lohit_Malayalam=/usr/share/fonts/lohit-malayalam/Lohit-Malayalam.ttf ++filename.Lohit_Oriya=/usr/share/fonts/lohit-oriya/Lohit-Oriya.ttf ++filename.Lohit_Punjabi=/usr/share/fonts/lohit-punjabi/Lohit-Punjabi.ttf ++filename.Lohit_Tamil=/usr/share/fonts/lohit-tamil/Lohit-Tamil.ttf ++filename.Lohit_Telugu=/usr/share/fonts/lohit-telugu/Lohit-Telugu.ttf ++ +filename.LKLUG=/usr/share/fonts/lklug/lklug.ttf + diff -r af20d64bc8b9 -r cb6c55ac1cd6 patches/openjdk/6541476-png-iTXt-chunk.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/openjdk/6541476-png-iTXt-chunk.patch Tue Jan 18 14:25:25 2011 +0000 @@ -0,0 +1,549 @@ +diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java +--- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java 2010-12-23 17:11:16.193446425 -0500 ++++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java 2010-12-23 17:11:29.399447037 -0500 +@@ -44,7 +44,6 @@ + import java.util.Arrays; + import java.util.Enumeration; + import java.util.Iterator; +-import java.util.List; + import java.util.zip.Inflater; + import java.util.zip.InflaterInputStream; + import javax.imageio.IIOException; +@@ -57,6 +56,7 @@ + import com.sun.imageio.plugins.common.InputStreamAdapter; + import com.sun.imageio.plugins.common.ReaderUtil; + import com.sun.imageio.plugins.common.SubImageInputStream; ++import java.io.ByteArrayOutputStream; + import sun.awt.image.ByteInterleavedRaster; + + class PNGImageDataEnumeration implements Enumeration { +@@ -209,6 +209,15 @@ + resetStreamSettings(); + } + ++ private String readNullTerminatedString(String charset) throws IOException { ++ ByteArrayOutputStream baos = new ByteArrayOutputStream(); ++ int b; ++ while ((b = stream.read()) != 0) { ++ baos.write(b); ++ } From andrew at icedtea.classpath.org Tue Jan 18 06:33:35 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Tue, 18 Jan 2011 14:33:35 +0000 Subject: /hg/release/icedtea6-1.8: 5 new changesets Message-ID: changeset aa77afad613c in /hg/release/icedtea6-1.8 details: http://icedtea.classpath.org/hg/release/icedtea6-1.8?cmd=changeset;node=aa77afad613c author: Andrew John Hughes date: Thu Dec 16 22:37:25 2010 +0000 RH663680, CVE-2010-4351: JNLP SecurityManager bypass 2010-12-16 Omair Majid RH663680, CVE-2010-4351: * NEWS: List issue. * netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: Make sure SecurityException is thrown if necessary. changeset 975f7989ae66 in /hg/release/icedtea6-1.8 details: http://icedtea.classpath.org/hg/release/icedtea6-1.8?cmd=changeset;node=975f7989ae66 author: Andrew John Hughes date: Thu Dec 16 23:46:20 2010 +0000 Bump to 1.8.4. 2010-12-16 Andrew John Hughes * configure.ac: Bump to 1.8.4. changeset 16ff9ccc0634 in /hg/release/icedtea6-1.8 details: http://icedtea.classpath.org/hg/release/icedtea6-1.8?cmd=changeset;node=16ff9ccc0634 author: Andrew John Hughes date: Tue Jan 18 14:28:55 2011 +0000 Added tag icedtea6-1.8.4 for changeset 975f7989ae66 changeset 1f604d5d30e4 in /hg/release/icedtea6-1.8 details: http://icedtea.classpath.org/hg/release/icedtea6-1.8?cmd=changeset;node=1f604d5d30e4 author: Andrew John Hughes date: Tue Jan 18 14:31:26 2011 +0000 Merge changeset ddfe477c1b26 in /hg/release/icedtea6-1.8 details: http://icedtea.classpath.org/hg/release/icedtea6-1.8?cmd=changeset;node=ddfe477c1b26 author: Andrew John Hughes date: Tue Jan 18 14:33:22 2011 +0000 Prepare for 1.8.5. 2011-01-18 Andrew John Hughes * configure.ac: Bump to 1.8.5pre. * NEWS: Add 1.8.5. diffstat: 10 files changed, 5095 insertions(+), 182 deletions(-) .hgtags | 1 ChangeLog | 34 Makefile.am | 5 NEWS | 14 configure.ac | 2 netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java | 278 patches/fonts-rhel.patch | 146 patches/openjdk/6541476-png-iTXt-chunk.patch | 549 + patches/openjdk/6687968-pngimagereader_mem_leak.patch | 126 patches/openjdk/6782079-png_metadata_oom.patch | 4122 ++++++++++++ diffs (truncated from 5667 to 500 lines): diff -r 7fbd2259a4c1 -r ddfe477c1b26 .hgtags --- a/.hgtags Thu Dec 16 19:37:17 2010 +0000 +++ b/.hgtags Tue Jan 18 14:33:22 2011 +0000 @@ -24,3 +24,4 @@ 1419166fcebf45ac187cfe2a4e1a45548cdeb5bd 1419166fcebf45ac187cfe2a4e1a45548cdeb5bd icedtea6-1.8.1 e96213dd3cd67306ded33a13319e8681728c7299 icedtea6-1.8.2 4f06af1897c3feff8708ff35a94df642f363d190 icedtea6-1.8.3 +975f7989ae6615f5d0cbce3089291a7c8841364f icedtea6-1.8.4 diff -r 7fbd2259a4c1 -r ddfe477c1b26 ChangeLog --- a/ChangeLog Thu Dec 16 19:37:17 2010 +0000 +++ b/ChangeLog Tue Jan 18 14:33:22 2011 +0000 @@ -1,3 +1,37 @@ 2010-12-16 Andrew John Hughes + + * configure.ac: Bump to 1.8.5pre. + * NEWS: Add 1.8.5. + +2010-12-24 Deepak Bhole + + Backport S6687968, S6541476, S6782079 + * Makefile.am: Add missing "\" to the patch list, update to include + new patches. + * NEWS: Updated. + * patches/openjdk/6687968-pngimagereader_mem_leak.patch: Backport to allow + S6541476 fix to apply cleanly. + * patches/openjdk/6541476-png-iTXt-chunk.patch: Backport to fix iTXt chunk + handling for png images. Also addresses RH665355. + * patches/openjdk/6782079-png_metadata_oom.patch: Backport to fix + potential OOM error when reading metadata on truncated pngs. + +2010-12-23 Jiri Vanek + + * NEWS: Updated with rh.bugzilas. + * patches/fonts-rhel.patch:repaired rhel 6 fonts configuration. + +2010-12-16 Andrew John Hughes + + * configure.ac: Bump to 1.8.4. + +2010-12-16 Omair Majid + + RH663680, CVE-2010-4351: + * NEWS: List issue. + * netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: + Make sure SecurityException is thrown if necessary. + 2010-12-16 Andrew John Hughes * NEWS: Fix issue placement. diff -r 7fbd2259a4c1 -r ddfe477c1b26 Makefile.am --- a/Makefile.am Thu Dec 16 19:37:17 2010 +0000 +++ b/Makefile.am Tue Jan 18 14:33:22 2011 +0000 @@ -360,7 +360,10 @@ ICEDTEA_PATCHES = \ patches/openjdk/6438179-systray_check.patch \ patches/openjdk/4356282-opentype.patch \ patches/openjdk/6954424-opentype_javadoc.patch \ - patches/openjdk/6795356-proxylazyvalue-leak.patch + patches/openjdk/6795356-proxylazyvalue-leak.patch \ + patches/openjdk/6687968-pngimagereader_mem_leak.patch \ + patches/openjdk/6541476-png-iTXt-chunk.patch \ + patches/openjdk/6782079-png_metadata_oom.patch if WITH_ALT_HSBUILD ICEDTEA_PATCHES += patches/hotspot/$(HSBUILD)/openjdk-6886353-ignore_deoptimizealot.patch \ diff -r 7fbd2259a4c1 -r ddfe477c1b26 NEWS --- a/NEWS Thu Dec 16 19:37:17 2010 +0000 +++ b/NEWS Tue Jan 18 14:33:22 2011 +0000 @@ -8,7 +8,19 @@ GX - http://bugs.gentoo.org/show_bug.cg CVE-XXXX-YYYY: http://www.cve.mitre.org/cgi-bin/cvename.cgi?name=XXXX-YYYY -New in release 1.8.4 (201X-XX-XX): +New in release 1.8.5 (2011-XX-XX): + +* Backports + - S6687968: PNGImageReader leaks native memory through an Inflater + - S6541476, RH665355: PNG imageio plugin incorrectly handles iTXt chunk + - S6782079: PNG: reading metadata may cause OOM on truncated images +* Fixes + - RH647157,RH582455: Update fontconfig files for rhel 6 + +New in release 1.8.4 (2011-01-12): + +* Security updates + - RH663680, CVE-2010-4351: IcedTea JNLP SecurityManager bypass * Backports - S6438179, RH569121: XToolkit.isTraySupported() result has nothing to do with the system tray - S4356282: RFE: JDK should support OpenType/CFF fonts diff -r 7fbd2259a4c1 -r ddfe477c1b26 configure.ac --- a/configure.ac Thu Dec 16 19:37:17 2010 +0000 +++ b/configure.ac Tue Jan 18 14:33:22 2011 +0000 @@ -1,4 +1,4 @@ AC_INIT([icedtea6],[1.8.4pre],[distro-pk -AC_INIT([icedtea6],[1.8.4pre],[distro-pkg-dev at openjdk.java.net]) +AC_INIT([icedtea6],[1.8.5pre],[distro-pkg-dev at openjdk.java.net]) AM_INIT_AUTOMAKE([1.9 tar-pax foreign]) AC_CONFIG_FILES([Makefile]) diff -r 7fbd2259a4c1 -r ddfe477c1b26 netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java --- a/netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java Thu Dec 16 19:37:17 2010 +0000 +++ b/netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java Tue Jan 18 14:33:22 2011 +0000 @@ -188,21 +188,21 @@ class JNLPSecurityManager extends Securi * Return the current Application, or null. */ protected ApplicationInstance getApplication(Class stack[], int maxDepth) { - if (maxDepth <= 0) - maxDepth = stack.length; + if (maxDepth <= 0) + maxDepth = stack.length; - // this needs to be tightened up - for (int i=0; i < stack.length && i < maxDepth; i++) { - if (stack[i].getClassLoader() instanceof JNLPClassLoader) { - JNLPClassLoader loader = (JNLPClassLoader) stack[i].getClassLoader(); + // this needs to be tightened up + for (int i=0; i < stack.length && i < maxDepth; i++) { + if (stack[i].getClassLoader() instanceof JNLPClassLoader) { + JNLPClassLoader loader = (JNLPClassLoader) stack[i].getClassLoader(); - if (loader != null && loader.getApplication() != null) { - return loader.getApplication(); - } - } - } + if (loader != null && loader.getApplication() != null) { + return loader.getApplication(); + } + } + } - return null; + return null; } /** @@ -227,17 +227,17 @@ class JNLPSecurityManager extends Securi // Enable this manually -- it'll produce too much output for -verbose // otherwise. - // if (true) - // System.out.println("Checking permission: " + perm.toString()); + // if (true) + // System.out.println("Checking permission: " + perm.toString()); - if (!JNLPRuntime.isWebstartApplication() && - ("setPolicy".equals(name) || "setSecurityManager".equals(name))) + if (!JNLPRuntime.isWebstartApplication() && + ("setPolicy".equals(name) || "setSecurityManager".equals(name))) throw new SecurityException(R("RCantReplaceSM")); try { // deny all permissions to stopped applications - // The call to getApplication() below might not work if an - // application hasn't been fully initialized yet. + // The call to getApplication() below might not work if an + // application hasn't been fully initialized yet. // if (JNLPRuntime.isDebug()) { // if (!"getClassLoader".equals(name)) { // ApplicationInstance app = getApplication(); @@ -245,95 +245,97 @@ class JNLPSecurityManager extends Securi // throw new SecurityException(R("RDenyStopped")); // } // } - - try { - super.checkPermission(perm); - } catch (SecurityException se) { - //This section is a special case for dealing with SocketPermissions. - if (JNLPRuntime.isDebug()) - System.err.println("Requesting permission: " + perm.toString()); + try { + super.checkPermission(perm); + } catch (SecurityException se) { - //Change this SocketPermission's action to connect and accept - //(and resolve). This is to avoid asking for connect permission - //on every address resolve. - Permission tmpPerm = null; - if (perm instanceof SocketPermission) { - tmpPerm = new SocketPermission(perm.getName(), - SecurityConstants.SOCKET_CONNECT_ACCEPT_ACTION); - - // before proceeding, check if we are trying to connect to same origin - ApplicationInstance app = getApplication(); - JNLPFile file = app.getJNLPFile(); + //This section is a special case for dealing with SocketPermissions. + if (JNLPRuntime.isDebug()) + System.err.println("Requesting permission: " + perm.toString()); - String srcHost = file.getSourceLocation().getAuthority(); - String destHost = name; - - // host = abc.xyz.com or abc.xyz.com: - if (destHost.indexOf(':') >= 0) - destHost = destHost.substring(0, destHost.indexOf(':')); - - // host = abc.xyz.com - String[] hostComponents = destHost.split("\\."); - - int length = hostComponents.length; - if (length >= 2) { - - // address is in xxx.xxx.xxx format - destHost = hostComponents[length -2] + "." + hostComponents[length -1]; - - // host = xyz.com i.e. origin - boolean isDestHostName = false; + //Change this SocketPermission's action to connect and accept + //(and resolve). This is to avoid asking for connect permission + //on every address resolve. + Permission tmpPerm = null; + if (perm instanceof SocketPermission) { + tmpPerm = new SocketPermission(perm.getName(), + SecurityConstants.SOCKET_CONNECT_ACCEPT_ACTION); - // make sure that it is not an ip address - try { - Integer.parseInt(hostComponents[length -1]); - } catch (NumberFormatException e) { - isDestHostName = true; - } + // before proceeding, check if we are trying to connect to same origin + ApplicationInstance app = getApplication(); + JNLPFile file = app.getJNLPFile(); - if (isDestHostName) { - // okay, destination is hostname. Now figure out if it is a subset of origin - if (srcHost.endsWith(destHost)) { - addPermission(tmpPerm); - return; - } - } - } + String srcHost = file.getSourceLocation().getAuthority(); + String destHost = name; - } else if (perm instanceof SecurityPermission) { + // host = abc.xyz.com or abc.xyz.com: + if (destHost.indexOf(':') >= 0) + destHost = destHost.substring(0, destHost.indexOf(':')); - // JCE's initialization requires putProviderProperty permission - if (perm.equals(new SecurityPermission("putProviderProperty.SunJCE"))) { - if (inTrustedCallChain("com.sun.crypto.provider.SunJCE", "run")) { - return; - } - } + // host = abc.xyz.com + String[] hostComponents = destHost.split("\\."); - } else if (perm instanceof RuntimePermission) { + int length = hostComponents.length; + if (length >= 2) { - // KeyGenerator's init method requires internal spec access - if (perm.equals(new SecurityPermission("accessClassInPackage.sun.security.internal.spec"))) { - if (inTrustedCallChain("javax.crypto.KeyGenerator", "init")) { - return; - } - } + // address is in xxx.xxx.xxx format + destHost = hostComponents[length -2] + "." + hostComponents[length -1]; - } else { - tmpPerm = perm; - } + // host = xyz.com i.e. origin + boolean isDestHostName = false; - if (tmpPerm != null) { - //askPermission will only prompt the user on SocketPermission - //meaning we're denying all other SecurityExceptions that may arise. - if (askPermission(tmpPerm)) { - addPermission(tmpPerm); - //return quietly. - } else { - throw se; - } - } - } + // make sure that it is not an ip address + try { + Integer.parseInt(hostComponents[length -1]); + } catch (NumberFormatException e) { + isDestHostName = true; + } + + if (isDestHostName) { + // okay, destination is hostname. Now figure out if it is a subset of origin + if (srcHost.endsWith(destHost)) { + addPermission(tmpPerm); + return; + } + } + } + + } else if (perm instanceof SecurityPermission) { + tmpPerm = perm; + + // JCE's initialization requires putProviderProperty permission + if (perm.equals(new SecurityPermission("putProviderProperty.SunJCE"))) { + if (inTrustedCallChain("com.sun.crypto.provider.SunJCE", "run")) { + return; + } + } + + } else if (perm instanceof RuntimePermission) { + tmpPerm = perm; + + // KeyGenerator's init method requires internal spec access + if (perm.equals(new SecurityPermission("accessClassInPackage.sun.security.internal.spec"))) { + if (inTrustedCallChain("javax.crypto.KeyGenerator", "init")) { + return; + } + } + + } else { + tmpPerm = perm; + } + + if (tmpPerm != null) { + //askPermission will only prompt the user on SocketPermission + //meaning we're denying all other SecurityExceptions that may arise. + if (askPermission(tmpPerm)) { + addPermission(tmpPerm); + //return quietly. + } else { + throw se; + } + } + } } catch (SecurityException ex) { if (JNLPRuntime.isDebug()) { @@ -343,18 +345,18 @@ class JNLPSecurityManager extends Securi } } - /** - * Returns weather the given class and method are in the current stack, + /** + * Returns weather the given class and method are in the current stack, * and whether or not everything upto then is trusted - * + * * @param className The name of the class to look for in the stack * @param methodName The name of the method for the given class to look for in the stack * @return Weather or not class::method() are in the chain, and everything upto there is trusted */ private boolean inTrustedCallChain(String className, String methodName) { - + StackTraceElement[] stack = Thread.currentThread().getStackTrace(); - + for (int i=0; i < stack.length; i++) { // Everything up to the desired class/method must be trusted @@ -367,49 +369,49 @@ class JNLPSecurityManager extends Securi return true; } } - + return false; } - + /** * Asks the user whether or not to grant permission. * @param perm the permission to be granted * @return true if the permission was granted, false otherwise. */ - private boolean askPermission(Permission perm) { - - ApplicationInstance app = getApplication(); - if (app != null && !app.isSigned()) { - if (perm instanceof SocketPermission - && ServiceUtil.checkAccess(SecurityWarningDialog.AccessType.NETWORK, perm.getName())) { - return true; - } - } + private boolean askPermission(Permission perm) { - return false; + ApplicationInstance app = getApplication(); + if (app != null && !app.isSigned()) { + if (perm instanceof SocketPermission + && ServiceUtil.checkAccess(SecurityWarningDialog.AccessType.NETWORK, perm.getName())) { + return true; + } + } + + return false; } /** * Adds a permission to the JNLPClassLoader. * @param perm the permission to add to the JNLPClassLoader */ - private void addPermission(Permission perm) { - if (JNLPRuntime.getApplication().getClassLoader() instanceof JNLPClassLoader) { + private void addPermission(Permission perm) { + if (JNLPRuntime.getApplication().getClassLoader() instanceof JNLPClassLoader) { - JNLPClassLoader cl = (JNLPClassLoader) JNLPRuntime.getApplication().getClassLoader(); - cl.addPermission(perm); - if (JNLPRuntime.isDebug()) { - if (cl.getPermissions(null).implies(perm)) - System.err.println("Added permission: " + perm.toString()); - else - System.err.println("Unable to add permission: " + perm.toString()); - } - } else { - if (JNLPRuntime.isDebug()) - System.err.println("Unable to add permission: " + perm + ", classloader not JNLP."); - } + JNLPClassLoader cl = (JNLPClassLoader) JNLPRuntime.getApplication().getClassLoader(); + cl.addPermission(perm); + if (JNLPRuntime.isDebug()) { + if (cl.getPermissions(null).implies(perm)) + System.err.println("Added permission: " + perm.toString()); + else + System.err.println("Unable to add permission: " + perm.toString()); + } + } else { + if (JNLPRuntime.isDebug()) + System.err.println("Unable to add permission: " + perm + ", classloader not JNLP."); + } } - + /** * Checks whether the window can be displayed without an applet * warning banner, and adds the window to the list of windows to @@ -418,7 +420,7 @@ class JNLPSecurityManager extends Securi public boolean checkTopLevelWindow(Object window) { ApplicationInstance app = getApplication(); - // remember window -> application mapping for focus, close on exit + // remember window -> application mapping for focus, close on exit if (app != null && window instanceof Window) { Window w = (Window) window; @@ -439,7 +441,7 @@ class JNLPSecurityManager extends Securi // todo: set awt.appletWarning to custom message // todo: logo on with glass pane on JFrame/JWindow? - + return super.checkTopLevelWindow(window); } @@ -458,16 +460,16 @@ class JNLPSecurityManager extends Securi */ public void checkExit(int status) { - // applets are not allowed to exit, but the plugin main class (primordial loader) is + // applets are not allowed to exit, but the plugin main class (primordial loader) is Class stack[] = getClassContext(); if (!exitAllowed) { - for (int i=0; i < stack.length; i++) - if (stack[i].getClassLoader() != null) - throw new AccessControlException("Applets may not call System.exit()"); + for (int i=0; i < stack.length; i++) + if (stack[i].getClassLoader() != null) + throw new AccessControlException("Applets may not call System.exit()"); } - super.checkExit(status); - + super.checkExit(status); + boolean realCall = (stack[1] == Runtime.class); if (isExitClass(stack)) // either exitClass called or no exitClass set @@ -498,9 +500,9 @@ class JNLPSecurityManager extends Securi } protected void disableExit() { - exitAllowed = false; + exitAllowed = false; } - + } diff -r 7fbd2259a4c1 -r ddfe477c1b26 patches/fonts-rhel.patch --- a/patches/fonts-rhel.patch Thu Dec 16 19:37:17 2010 +0000 +++ b/patches/fonts-rhel.patch Tue Jan 18 14:33:22 2011 +0000 @@ -11,10 +11,9 @@ diff -Nru openjdk.orig/jdk/make/sun/awt/ else FONTCONFIGS_SRC = $(CLOSED_SRC)/solaris/classes/sun/awt/fontconfigs -diff -Nru openjdk.orig/jdk/src/solaris/classes/sun/awt/fontconfigs/linux.fontconfig.RedHat.6.0.properties openjdk/jdk/src/solaris/classes/sun/awt/fontconfigs/linux.fontconfig.RedHat.6.0.properties ---- openjdk.orig/jdk/src/solaris/classes/sun/awt/fontconfigs/linux.fontconfig.RedHat.6.0.properties 1970-01-01 01:00:00.000000000 +0100 -+++ openjdk/jdk/src/solaris/classes/sun/awt/fontconfigs/linux.fontconfig.RedHat.6.0.properties 2010-08-12 22:52:55.716852554 +0100 -@@ -0,0 +1,376 @@ +--- /dev/null 2010-12-20 09:26:08.850062021 +0100 From ahughes at redhat.com Tue Jan 18 06:40:13 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Tue, 18 Jan 2011 14:40:13 +0000 Subject: [SECURITY] IcedTea6 1.7.7, 1.8.4, 1.9.4 Released! In-Reply-To: <20101124141550.GC1530@rivendell.middle-earth.co.uk> References: <20101124141550.GC1530@rivendell.middle-earth.co.uk> Message-ID: <20110118144013.GB14019@rivendell.middle-earth.co.uk> We are pleased to announce a new set of security releases, IcedTea6 1.7.7, IcedTea6 1.8.4 and IcedTea6 1.9.4. This update contains the following security updates: * RH663680, CVE-2010-4351: IcedTea JNLP SecurityManager bypass The IcedTea project provides a harness to build the source code from OpenJDK6 using Free Software build tools. It also includes the only Free Java plugin and Web Start implementation, and support for additional architectures over and above x86, x86_64 and SPARC via the Zero assembler port. What?s New? ?????? IcedTea6 1.7.7 ============== * Security updates - RH663680, CVE-2010-4351: IcedTea JNLP SecurityManager bypass * Backports - S6438179, RH569121: XToolkit.isTraySupported() result has nothing to do with the system tray - S4356282: RFE: JDK should support OpenType/CFF fonts - S6954424, RH525870: Support OpenType/CFF fonts in JDK 7 - S6795356, PR590: Leak caused by javax.swing.UIDefaults.ProxyLazyValue.acc - S6967436, RH597227: lines longer than 2^15 can fill window. - S6967433: dashed lines broken when using scaling transforms. - S6976265: No STROKE_CONTROL - S6967434, PR450, RH530642: Round joins/caps of scaled up lines have poor quality. * Fixes: - S7003777, RH647674: JTextPane produces incorrect content after parsing the html text IcedTea6 1.8.4 ============== * Security updates - RH663680, CVE-2010-4351: IcedTea JNLP SecurityManager bypass * Backports - S6438179, RH569121: XToolkit.isTraySupported() result has nothing to do with the system tray - S4356282: RFE: JDK should support OpenType/CFF fonts - S6954424, RH525870: Support OpenType/CFF fonts in JDK 7 - S6795356, PR590: Leak caused by javax.swing.UIDefaults.ProxyLazyValue.acc - S6967436, RH597227: lines longer than 2^15 can fill window. - S6967433: dashed lines broken when using scaling transforms. - S6976265: No STROKE_CONTROL - S6967434, PR450, RH530642: Round joins/caps of scaled up lines have poor quality. * Fixes: - S7003777, RH647674: JTextPane produces incorrect content after parsing the html text IcedTea6 1.9.4 ============== * Security updates - RH663680, CVE-2010-4351: IcedTea JNLP SecurityManager bypass * Backports - S4356282: RFE: JDK should support OpenType/CFF fonts - S6954424, RH525870: Support OpenType/CFF fonts in JDK 7 - S6795356, PR590: Leak caused by javax.swing.UIDefaults.ProxyLazyValue.acc - S6967436, RH597227: lines longer than 2^15 can fill window. - S6967433: dashed lines broken when using scaling transforms. - S6976265: No STROKE_CONTROL - S6967434, PR450, RH530642: Round joins/caps of scaled up lines have poor quality. - S6438179, RH569121: XToolkit.isTraySupported() result has nothing to do with the system tray * Fixes - S7003777, RH647674: JTextPane produces incorrect content after parsing the html text The tarballs can be downloaded from: * http://icedtea.classpath.org/download/source/icedtea6-1.7.7.tar.gz * http://icedtea.classpath.org/download/source/icedtea6-1.8.4.tar.gz * http://icedtea.classpath.org/download/source/icedtea6-1.9.4.tar.gz SHA256 sums: 4c35574df1214c2e2533b282d6045f79f61eb702d59cd4ac73eec973f4c51fb6 icedtea6-1.7.7.tar.gz 0f89e920a829f3f1a6057065c85520b910504a0be1fbc94f8db2390242edc784 icedtea6-1.8.4.tar.gz 2194b59d8c17ad6ff2fb495e10f9e6023993df5f8ce8a3739bf057f6562ef077 icedtea6-1.9.4.tar.gz The following people helped with these releases: Andrew John Hughes, Denis Lila, Omair Majid We would also like to thank the bug reporters and testers! To get started: $ tar xzf icedtea6-.tar.gz $ cd icedtea6- Full build requirements and instructions are in INSTALL: $ ./configure [--enable-zero --enable-pulse-java --enable-systemtap ...] $ make -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From andrew at icedtea.classpath.org Tue Jan 18 07:07:47 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Tue, 18 Jan 2011 15:07:47 +0000 Subject: /hg/release/icedtea6-1.7: Prepare for 1.7.8. Message-ID: changeset 9cfe7a59b531 in /hg/release/icedtea6-1.7 details: http://icedtea.classpath.org/hg/release/icedtea6-1.7?cmd=changeset;node=9cfe7a59b531 author: Andrew John Hughes date: Tue Jan 18 15:07:41 2011 +0000 Prepare for 1.7.8. 2011-01-18 Andrew John Hughes * NEWS: Update date of 1.7.7 release. Move items not released to 1.7.8. * configure.ac: Bump to 1.7.8pre. diffstat: 3 files changed, 17 insertions(+), 6 deletions(-) ChangeLog | 6 ++++++ NEWS | 15 ++++++++++----- configure.ac | 2 +- diffs (56 lines): diff -r cb6c55ac1cd6 -r 9cfe7a59b531 ChangeLog --- a/ChangeLog Tue Jan 18 14:25:25 2011 +0000 +++ b/ChangeLog Tue Jan 18 15:07:41 2011 +0000 @@ -1,3 +1,9 @@ 2010-12-24 Deepak Bhole + + * NEWS: Update date of 1.7.7 release. + Move items not released to 1.7.8. + * configure.ac: Bump to 1.7.8pre. + 2010-12-24 Deepak Bhole Backport S6687968, S6541476, S6782079 diff -r cb6c55ac1cd6 -r 9cfe7a59b531 NEWS --- a/NEWS Tue Jan 18 14:25:25 2011 +0000 +++ b/NEWS Tue Jan 18 15:07:41 2011 +0000 @@ -8,7 +8,16 @@ GX - http://bugs.gentoo.org/show_bug.cg CVE-XXXX-YYYY: http://www.cve.mitre.org/cgi-bin/cvename.cgi?name=XXXX-YYYY -New in release 1.7.7 (2011-01-12): +New in release 1.7.8 (2011-XX-XX): + +* Backports + - S6687968: PNGImageReader leaks native memory through an Inflater + - S6541476, RH665355: PNG imageio plugin incorrectly handles iTXt chunk + - S6782079: PNG: reading metadata may cause OOM on truncated images +* Fixes: + - RH647157,RH582455: Update fontconfig files for rhel 6 + +New in release 1.7.7 (2011-01-18): * Security updates - RH663680, CVE-2010-4351: IcedTea JNLP SecurityManager bypass @@ -21,12 +30,8 @@ New in release 1.7.7 (2011-01-12): - S6967433: dashed lines broken when using scaling transforms. - S6976265: No STROKE_CONTROL - S6967434, PR450, RH530642: Round joins/caps of scaled up lines have poor quality. - - S6687968: PNGImageReader leaks native memory through an Inflater - - S6541476, RH665355: PNG imageio plugin incorrectly handles iTXt chunk - - S6782079: PNG: reading metadata may cause OOM on truncated images * Fixes: - S7003777, RH647674: JTextPane produces incorrect content after parsing the html text - - RH647157,RH582455: Update fontconfig files for rhel 6 New in release 1.7.6 (2010-11-24): diff -r cb6c55ac1cd6 -r 9cfe7a59b531 configure.ac --- a/configure.ac Tue Jan 18 14:25:25 2011 +0000 +++ b/configure.ac Tue Jan 18 15:07:41 2011 +0000 @@ -1,4 +1,4 @@ AC_INIT([icedtea6], [1.7.7], [distro-pkg -AC_INIT([icedtea6], [1.7.7], [distro-pkg-dev at openjdk.java.net]) +AC_INIT([icedtea6], [1.7.8pre], [distro-pkg-dev at openjdk.java.net]) AM_INIT_AUTOMAKE([1.9 tar-pax foreign]) AC_CONFIG_FILES([Makefile]) From andrew at icedtea.classpath.org Tue Jan 18 07:10:25 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Tue, 18 Jan 2011 15:10:25 +0000 Subject: /hg/release/icedtea6-1.8: Fix date of delayed 1.8.4 release. Message-ID: changeset 9b0c926d0965 in /hg/release/icedtea6-1.8 details: http://icedtea.classpath.org/hg/release/icedtea6-1.8?cmd=changeset;node=9b0c926d0965 author: Andrew John Hughes date: Tue Jan 18 15:10:06 2011 +0000 Fix date of delayed 1.8.4 release. 2011-01-18 Andrew John Hughes * NEWS: Fix date of delayed 1.8.4 release. diffstat: 2 files changed, 5 insertions(+), 1 deletion(-) ChangeLog | 4 ++++ NEWS | 2 +- diffs (23 lines): diff -r ddfe477c1b26 -r 9b0c926d0965 ChangeLog --- a/ChangeLog Tue Jan 18 14:33:22 2011 +0000 +++ b/ChangeLog Tue Jan 18 15:10:06 2011 +0000 @@ -1,3 +1,7 @@ 2011-01-18 Andrew John Hughes + + * NEWS: Fix date of delayed 1.8.4 release. + 2011-01-18 Andrew John Hughes * configure.ac: Bump to 1.8.5pre. diff -r ddfe477c1b26 -r 9b0c926d0965 NEWS --- a/NEWS Tue Jan 18 14:33:22 2011 +0000 +++ b/NEWS Tue Jan 18 15:10:06 2011 +0000 @@ -17,7 +17,7 @@ New in release 1.8.5 (2011-XX-XX): * Fixes - RH647157,RH582455: Update fontconfig files for rhel 6 -New in release 1.8.4 (2011-01-12): +New in release 1.8.4 (2011-01-18): * Security updates - RH663680, CVE-2010-4351: IcedTea JNLP SecurityManager bypass From andrew at icedtea.classpath.org Tue Jan 18 07:17:53 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Tue, 18 Jan 2011 15:17:53 +0000 Subject: /hg/release/icedtea6-1.9: 5 new changesets Message-ID: changeset 7ec6c82e69ee in /hg/release/icedtea6-1.9 details: http://icedtea.classpath.org/hg/release/icedtea6-1.9?cmd=changeset;node=7ec6c82e69ee author: Andrew John Hughes date: Fri Dec 17 01:02:47 2010 +0000 RH663680, CVE-2010-4351: JNLP SecurityManager bypass 2010-12-16 Omair Majid RH663680, CVE-2010-4351: * NEWS: List issue. * netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: Make sure SecurityException is thrown if necessary. changeset fdefc65b1e3f in /hg/release/icedtea6-1.9 details: http://icedtea.classpath.org/hg/release/icedtea6-1.9?cmd=changeset;node=fdefc65b1e3f author: Andrew John Hughes date: Fri Dec 17 11:24:50 2010 +0000 Bump to 1.9.4. 2010-12-17 Andrew John Hughes * configure.ac: Bump to 1.9.4. changeset 8a85eb5d8fba in /hg/release/icedtea6-1.9 details: http://icedtea.classpath.org/hg/release/icedtea6-1.9?cmd=changeset;node=8a85eb5d8fba author: Andrew John Hughes date: Tue Jan 18 15:14:08 2011 +0000 Added tag icedtea6-1.9.4 for changeset fdefc65b1e3f changeset 1f02f57e1add in /hg/release/icedtea6-1.9 details: http://icedtea.classpath.org/hg/release/icedtea6-1.9?cmd=changeset;node=1f02f57e1add author: Andrew John Hughes date: Tue Jan 18 15:16:21 2011 +0000 Merge changeset 6ec6e96141d8 in /hg/release/icedtea6-1.9 details: http://icedtea.classpath.org/hg/release/icedtea6-1.9?cmd=changeset;node=6ec6e96141d8 author: Andrew John Hughes date: Tue Jan 18 15:17:47 2011 +0000 Prepare for 1.9.5. 2011-01-18 Andrew John Hughes * configure.ac: Bump to 1.9.5pre. * NEWS: Add 1.9.5 and correct delayed date of 1.9.4 release. diffstat: 10 files changed, 4957 insertions(+), 44 deletions(-) .hgtags | 1 ChangeLog | 35 Makefile.am | 5 NEWS | 13 configure.ac | 2 netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java | 2 patches/fonts-rhel.patch | 146 patches/openjdk/6541476-png-iTXt-chunk.patch | 549 + patches/openjdk/6687968-pngimagereader_mem_leak.patch | 126 patches/openjdk/6782079-png_metadata_oom.patch | 4122 ++++++++++++ diffs (truncated from 5296 to 500 lines): diff -r 5af2053661b9 -r 6ec6e96141d8 .hgtags --- a/.hgtags Thu Dec 16 19:31:39 2010 +0000 +++ b/.hgtags Tue Jan 18 15:17:47 2011 +0000 @@ -23,3 +23,4 @@ 2fa3935ab384958d06614cec587506702bc8e658 2fa3935ab384958d06614cec587506702bc8e658 icedtea6-1.9.1 c298e31212047871e12f07d6900d7580f83b5831 icedtea6-1.9.2 42cb6cbb7ba6fbbcdd3499ea91c283637994db98 icedtea6-1.9.3 +fdefc65b1e3f7ab140ce4da42716c2439796dfda icedtea6-1.9.4 diff -r 5af2053661b9 -r 6ec6e96141d8 ChangeLog --- a/ChangeLog Thu Dec 16 19:31:39 2010 +0000 +++ b/ChangeLog Tue Jan 18 15:17:47 2011 +0000 @@ -1,3 +1,38 @@ 2010-12-16 Andrew John Hughes + + * configure.ac: Bump to 1.9.5pre. + * NEWS: Add 1.9.5 and correct delayed + date of 1.9.4 release. + +2010-12-24 Deepak Bhole + + Backport S6687968, S6541476, S6782079 + * Makefile.am: Add missing "\" to the patch list, update to include + new patches. + * NEWS: Updated. + * patches/openjdk/6687968-pngimagereader_mem_leak.patch: Backport to allow + S6541476 fix to apply cleanly. + * patches/openjdk/6541476-png-iTXt-chunk.patch: Backport to fix iTXt chunk + handling for png images. Also addresses RH665355. + * patches/openjdk/6782079-png_metadata_oom.patch: Backport to fix + potential OOM error when reading metadata on truncated pngs. + +2010-12-23 Jiri Vanek + + * NEWS: Updated with rh.bugzilas. + * patches/fonts-rhel.patch:repaired rhel 6 fonts configuration. + +2010-12-17 Andrew John Hughes + + * configure.ac: Bump to 1.9.4. + +2010-12-16 Omair Majid + + RH663680, CVE-2010-4351: + * NEWS: List issue. + * netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: + Make sure SecurityException is thrown if necessary. + 2010-12-16 Andrew John Hughes * NEWS: Place RH647674 under correct section. diff -r 5af2053661b9 -r 6ec6e96141d8 Makefile.am --- a/Makefile.am Thu Dec 16 19:31:39 2010 +0000 +++ b/Makefile.am Tue Jan 18 15:17:47 2011 +0000 @@ -323,7 +323,10 @@ ICEDTEA_PATCHES = \ patches/openjdk/6438179-systray_check.patch \ patches/openjdk/4356282-opentype.patch \ patches/openjdk/6954424-opentype_javadoc.patch \ - patches/openjdk/6795356-proxylazyvalue-leak.patch + patches/openjdk/6795356-proxylazyvalue-leak.patch \ + patches/openjdk/6687968-pngimagereader_mem_leak.patch \ + patches/openjdk/6541476-png-iTXt-chunk.patch \ + patches/openjdk/6782079-png_metadata_oom.patch if WITH_ALT_HSBUILD ICEDTEA_PATCHES += \ diff -r 5af2053661b9 -r 6ec6e96141d8 NEWS --- a/NEWS Thu Dec 16 19:31:39 2010 +0000 +++ b/NEWS Tue Jan 18 15:17:47 2011 +0000 @@ -8,8 +8,19 @@ GX - http://bugs.gentoo.org/show_bug.cg CVE-XXXX-YYYY: http://www.cve.mitre.org/cgi-bin/cvename.cgi?name=XXXX-YYYY -New in release 1.9.4 (2011-XX-XX): +New in release 1.9.5 (2011-XX-XX): +* Backports + - S6687968: PNGImageReader leaks native memory through an Inflater + - S6541476, RH665355: PNG imageio plugin incorrectly handles iTXt chunk + - S6782079: PNG: reading metadata may cause OOM on truncated images +* Fixes + - RH647157,RH582455: Update fontconfig files for rhel 6 + +New in release 1.9.4 (2011-01-18): + +* Security updates + - RH663680, CVE-2010-4351: IcedTea JNLP SecurityManager bypass * Backports - S4356282: RFE: JDK should support OpenType/CFF fonts - S6954424, RH525870: Support OpenType/CFF fonts in JDK 7 diff -r 5af2053661b9 -r 6ec6e96141d8 configure.ac --- a/configure.ac Thu Dec 16 19:31:39 2010 +0000 +++ b/configure.ac Tue Jan 18 15:17:47 2011 +0000 @@ -1,4 +1,4 @@ AC_INIT([icedtea6],[1.9.4pre],[distro-pk -AC_INIT([icedtea6],[1.9.4pre],[distro-pkg-dev at openjdk.java.net]) +AC_INIT([icedtea6],[1.9.5pre],[distro-pkg-dev at openjdk.java.net]) AM_INIT_AUTOMAKE([1.9 tar-pax foreign]) AC_CONFIG_FILES([Makefile]) diff -r 5af2053661b9 -r 6ec6e96141d8 netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java --- a/netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java Thu Dec 16 19:31:39 2010 +0000 +++ b/netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java Tue Jan 18 15:17:47 2011 +0000 @@ -302,6 +302,7 @@ class JNLPSecurityManager extends Securi } } else if (perm instanceof SecurityPermission) { + tmpPerm = perm; // JCE's initialization requires putProviderProperty permission if (perm.equals(new SecurityPermission("putProviderProperty.SunJCE"))) { @@ -311,6 +312,7 @@ class JNLPSecurityManager extends Securi } } else if (perm instanceof RuntimePermission) { + tmpPerm = perm; // KeyGenerator's init method requires internal spec access if (perm.equals(new SecurityPermission("accessClassInPackage.sun.security.internal.spec"))) { diff -r 5af2053661b9 -r 6ec6e96141d8 patches/fonts-rhel.patch --- a/patches/fonts-rhel.patch Thu Dec 16 19:31:39 2010 +0000 +++ b/patches/fonts-rhel.patch Tue Jan 18 15:17:47 2011 +0000 @@ -11,10 +11,9 @@ diff -r ea703df72762 make/sun/awt/Makefi else FONTCONFIGS_SRC = $(CLOSED_SRC)/solaris/classes/sun/awt/fontconfigs -diff -r ea703df72762 src/solaris/classes/sun/awt/fontconfigs/linux.fontconfig.RedHat.6.0.properties ---- /dev/null Thu Jan 01 00:00:00 1970 +0000 -+++ openjdk/jdk/src/solaris/classes/sun/awt/fontconfigs/linux.fontconfig.RedHat.6.0.properties Mon Aug 02 16:56:20 2010 +0100 -@@ -0,0 +1,376 @@ +--- /dev/null 2010-12-20 09:26:08.850062021 +0100 ++++ openjdk/jdk/src/solaris/classes/sun/awt/fontconfigs/linux.fontconfig.RedHat.6.0.properties 2010-12-22 11:21:32.606781127 +0100 +@@ -0,0 +1,441 @@ +# +# Copyright (c) 2007, Oracle and/or its affiliates. All rights reserved. +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -42,16 +41,19 @@ diff -r ea703df72762 src/solaris/classes + +# Version + -+# Uses Fedora 9 fonts and file paths. ++# Uses Fedora 14 fonts and file paths, added VL-gothic +version=1 + +# Component Font Mappings + +dialog.plain.latin-1=DejaVu Sans -+dialog.plain.japanese-x0208=Sazanami Gothic ++#dialog.plain.japanese-x0208=Sazanami Gothic ++dialog.plain.japanese-x0208=VL PGothic +dialog.plain.korean=Baekmuk Gulim +dialog.plain.chinese-big5=AR PL ShanHeiSun Uni +dialog.plain.chinese-gb18030=AR PL ShanHeiSun Uni ++dialog.plain.assamese=Lohit Assamese ++dialog.plain.devanagari=Lohit Devanagari +dialog.plain.bengali=Lohit Bengali +dialog.plain.gujarati=Lohit Gujarati +dialog.plain.hindi=Lohit Hindi @@ -63,10 +65,13 @@ diff -r ea703df72762 src/solaris/classes +dialog.plain.sinhala=LKLUG + +dialog.bold.latin-1=DejaVu Sans Bold -+dialog.bold.japanese-x0208=Sazanami Gothic ++#dialog.bold.japanese-x0208=Sazanami Gothic ++dialog.bold.japanese-x0208=VL PGothic +dialog.bold.korean=Baekmuk Gulim +dialog.bold.chinese-big5=AR PL ShanHeiSun Uni +dialog.bold.chinese-gb18030=AR PL ShanHeiSun Uni ++dialog.bold.assamese=Lohit Assamese ++dialog.bold.devanagari=Lohit Devanagari +dialog.bold.bengali=Lohit Bengali +dialog.bold.gujarati=Lohit Gujarati +dialog.bold.hindi=Lohit Hindi @@ -78,10 +83,13 @@ diff -r ea703df72762 src/solaris/classes +dialog.bold.sinhala=LKLUG + +dialog.italic.latin-1=DejaVu Sans Oblique -+dialog.italic.japanese-x0208=Sazanami Gothic ++#dialog.italic.japanese-x0208=Sazanami Gothic ++dialog.italic.japanese-x0208=VL PGothic +dialog.italic.korean=Baekmuk Gulim +dialog.italic.chinese-big5=AR PL ShanHeiSun Uni +dialog.italic.chinese-gb18030=AR PL ShanHeiSun Uni ++dialog.italic.assamese=Lohit Assamese ++dialog.italic.devanagari=Lohit Devanagari +dialog.italic.bengali=Lohit Bengali +dialog.italic.gujarati=Lohit Gujarati +dialog.italic.hindi=Lohit Hindi @@ -93,10 +101,13 @@ diff -r ea703df72762 src/solaris/classes +dialog.italic.sinhala=LKLUG + +dialog.bolditalic.latin-1=DejaVu Sans Bold Oblique -+dialog.bolditalic.japanese-x0208=Sazanami Gothic ++#dialog.bolditalic.japanese-x0208=Sazanami Gothic ++dialog.bolditalic.japanese-x0208=VL PGothic +dialog.bolditalic.korean=Baekmuk Gulim +dialog.bolditalic.chinese-big5=AR PL ShanHeiSun Uni +dialog.bolditalic.chinese-gb18030=AR PL ShanHeiSun Uni ++dialog.bolditalic.assamese=Lohit Assamese ++dialog.bolditalic.devanagari=Lohit Devanagari +dialog.bolditalic.bengali=Lohit Bengali +dialog.bolditalic.gujarati=Lohit Gujarati +dialog.bolditalic.hindi=Lohit Hindi @@ -108,10 +119,13 @@ diff -r ea703df72762 src/solaris/classes +dialog.bolditalic.sinhala=LKLUG + +sansserif.plain.latin-1=DejaVu Sans -+sansserif.plain.japanese-x0208=Sazanami Gothic ++#sansserif.plain.japanese-x0208=Sazanami Gothic ++sansserif.plain.japanese-x0208=VL PGothic +sansserif.plain.korean=Baekmuk Gulim +sansserif.plain.chinese-big5=AR PL ShanHeiSun Uni +sansserif.plain.chinese-gb18030=AR PL ShanHeiSun Uni ++sansserif.plain.assamese=Lohit Assamese ++sansserif.plain.devanagari=Lohit Devanagari +sansserif.plain.bengali=Lohit Bengali +sansserif.plain.gujarati=Lohit Gujarati +sansserif.plain.hindi=Lohit Hindi @@ -123,10 +137,13 @@ diff -r ea703df72762 src/solaris/classes +sansserif.plain.sinhala=LKLUG + +sansserif.bold.latin-1=DejaVu Sans Bold -+sansserif.bold.japanese-x0208=Sazanami Gothic ++#sansserif.bold.japanese-x0208=Sazanami Gothic ++sansserif.bold.japanese-x0208=VL PGothic +sansserif.bold.korean=Baekmuk Gulim +sansserif.bold.chinese-big5=AR PL ShanHeiSun Uni +sansserif.bold.chinese-gb18030=AR PL ShanHeiSun Uni ++sansserif.bold.assamese=Lohit Assamese ++sansserif.bold.devanagari=Lohit Devanagari +sansserif.bold.bengali=Lohit Bengali +sansserif.bold.gujarati=Lohit Gujarati +sansserif.bold.hindi=Lohit Hindi @@ -138,10 +155,13 @@ diff -r ea703df72762 src/solaris/classes +sansserif.bold.sinhala=LKLUG + +sansserif.italic.latin-1=DejaVu Sans Oblique -+sansserif.italic.japanese-x0208=Sazanami Gothic ++#sansserif.italic.japanese-x0208=Sazanami Gothic ++sansserif.italic.japanese-x0208=VL PGothic +sansserif.italic.korean=Baekmuk Gulim +sansserif.italic.chinese-big5=AR PL ShanHeiSun Uni +sansserif.italic.chinese-gb18030=AR PL ShanHeiSun Uni ++sansserif.italic.assamese=Lohit Assamese ++sansserif.italic.devanagari=Lohit Devanagari +sansserif.italic.bengali=Lohit Bengali +sansserif.italic.gujarati=Lohit Gujarati +sansserif.italic.hindi=Lohit Hindi @@ -153,10 +173,13 @@ diff -r ea703df72762 src/solaris/classes +sansserif.italic.sinhala=LKLUG + +sansserif.bolditalic.latin-1=DejaVu Sans Bold Oblique -+sansserif.bolditalic.japanese-x0208=Sazanami Gothic ++#sansserif.bolditalic.japanese-x0208=Sazanami Gothic ++sansserif.bolditalic.japanese-x0208=VL PGothic +sansserif.bolditalic.korean=Baekmuk Gulim +sansserif.bolditalic.chinese-big5=AR PL ShanHeiSun Uni +sansserif.bolditalic.chinese-gb18030=AR PL ShanHeiSun Uni ++sansserif.bolditalic.assamese=Lohit Assamese ++sansserif.bolditalic.devanagari=Lohit Devanagari +sansserif.bolditalic.bengali=Lohit Bengali +sansserif.bolditalic.gujarati=Lohit Gujarati +sansserif.bolditalic.hindi=Lohit Hindi @@ -168,10 +191,13 @@ diff -r ea703df72762 src/solaris/classes +sansserif.bolditalic.sinhala=LKLUG + +serif.plain.latin-1=DejaVu Serif -+serif.plain.japanese-x0208=Sazanami Mincho ++#serif.plain.japanese-x0208=Sazanami Mincho ++serif.plain.japanese-x0208=VL PGothic +serif.plain.korean=Baekmuk Batang +serif.plain.chinese-big5=AR PL ZenKai Uni +serif.plain.chinese-gb18030=AR PL ZenKai Uni ++serif.plain.assamese=Lohit Assamese ++serif.plain.devanagari=Lohit Devanagari +serif.plain.bengali=Lohit Bengali +serif.plain.gujarati=Lohit Gujarati +serif.plain.hindi=Lohit Hindi @@ -183,10 +209,13 @@ diff -r ea703df72762 src/solaris/classes +serif.plain.sinhala=LKLUG + +serif.bold.latin-1=DejaVu Serif Bold -+serif.bold.japanese-x0208=Sazanami Mincho ++#serif.bold.japanese-x0208=Sazanami Mincho ++serif.bold.japanese-x0208=VL PGothic +serif.bold.korean=Baekmuk Batang +serif.bold.chinese-big5=AR PL ZenKai Uni +serif.bold.chinese-gb18030=AR PL ZenKai Uni ++serif.bold.assamese=Lohit Assamese ++serif.bold.devanagari=Lohit Devanagari +serif.bold.bengali=Lohit Bengali +serif.bold.gujarati=Lohit Gujarati +serif.bold.hindi=Lohit Hindi @@ -198,10 +227,13 @@ diff -r ea703df72762 src/solaris/classes +serif.bold.sinhala=LKLUG + +serif.italic.latin-1=DejaVu Serif Oblique -+serif.italic.japanese-x0208=Sazanami Mincho ++#serif.italic.japanese-x0208=Sazanami Mincho ++serif.italic.japanese-x0208=VL PGothic +serif.italic.korean=Baekmuk Batang +serif.italic.chinese-big5=AR PL ZenKai Uni +serif.italic.chinese-gb18030=AR PL ZenKai Uni ++serif.italic.assamese=Lohit Assamese ++serif.italic.devanagari=Lohit Devanagari +serif.italic.bengali=Lohit Bengali +serif.italic.gujarati=Lohit Gujarati +serif.italic.hindi=Lohit Hindi @@ -213,10 +245,13 @@ diff -r ea703df72762 src/solaris/classes +serif.italic.sinhala=LKLUG + +serif.bolditalic.latin-1=DejaVu Serif Bold Oblique -+serif.bolditalic.japanese-x0208=Sazanami Mincho ++#serif.bolditalic.japanese-x0208=Sazanami Mincho ++serif.bolditalic.japanese-x0208=VL PGothic +serif.bolditalic.korean=Baekmuk Batang +serif.bolditalic.chinese-big5=AR PL ZenKai Uni +serif.bolditalic.chinese-gb18030=AR PL ZenKai Uni ++serif.bolditalic.assamese=Lohit Assamese ++serif.bolditalic.devanagari=Lohit Devanagari +serif.bolditalic.bengali=Lohit Bengali +serif.bolditalic.gujarati=Lohit Gujarati +serif.bolditalic.hindi=Lohit Hindi @@ -228,10 +263,13 @@ diff -r ea703df72762 src/solaris/classes +serif.bolditalic.sinhala=LKLUG + +monospaced.plain.latin-1=DejaVu Sans Mono -+monospaced.plain.japanese-x0208=Sazanami Gothic ++#monospaced.plain.japanese-x0208=Sazanami Gothic ++monospaced.plain.japanese-x0208=VL Gothic +monospaced.plain.korean=Baekmuk Gulim +monospaced.plain.chinese-big5=AR PL ShanHeiSun Uni +monospaced.plain.chinese-gb18030=AR PL ShanHeiSun Uni ++monospaced.plain.assamese=Lohit Assamese ++monospaced.plain.devanagari=Lohit Devanagari +monospaced.plain.bengali=Lohit Bengali +monospaced.plain.gujarati=Lohit Gujarati +monospaced.plain.hindi=Lohit Hindi @@ -243,10 +281,13 @@ diff -r ea703df72762 src/solaris/classes +monospaced.plain.sinhala=LKLUG + +monospaced.bold.latin-1=DejaVu Sans Mono Bold -+monospaced.bold.japanese-x0208=Sazanami Gothic ++#monospaced.bold.japanese-x0208=Sazanami Gothic ++monospaced.bold.japanese-x0208=VL Gothic +monospaced.bold.korean=Baekmuk Gulim +monospaced.bold.chinese-big5=AR PL ShanHeiSun Uni +monospaced.bold.chinese-gb18030=AR PL ShanHeiSun Uni ++monospaced.bold.assamese=Lohit Assamese ++monospaced.bold.devanagari=Lohit Devanagari +monospaced.bold.bengali=Lohit Bengali +monospaced.bold.gujarati=Lohit Gujarati +monospaced.bold.hindi=Lohit Hindi @@ -258,10 +299,13 @@ diff -r ea703df72762 src/solaris/classes +monospaced.bold.sinhala=LKLUG + +monospaced.italic.latin-1=DejaVu Sans Mono Oblique -+monospaced.italic.japanese-x0208=Sazanami Gothic ++#monospaced.italic.japanese-x0208=Sazanami Gothic ++monospaced.italic.japanese-x0208=VL Gothic +monospaced.italic.korean=Baekmuk Gulim +monospaced.italic.chinese-big5=AR PL ShanHeiSun Uni +monospaced.italic.chinese-gb18030=AR PL ShanHeiSun Uni ++monospaced.italic.assamese=Lohit Assamese ++monospaced.italic.devanagari=Lohit Devanagari +monospaced.italic.bengali=Lohit Bengali +monospaced.italic.gujarati=Lohit Gujarati +monospaced.italic.hindi=Lohit Hindi @@ -273,10 +317,13 @@ diff -r ea703df72762 src/solaris/classes +monospaced.italic.sinhala=LKLUG + +monospaced.bolditalic.latin-1=DejaVu Sans Mono Bold Oblique -+monospaced.bolditalic.japanese-x0208=Sazanami Gothic ++#monospaced.bolditalic.japanese-x0208=Sazanami Gothic ++monospaced.bolditalic.japanese-x0208=VL Gothic +monospaced.bolditalic.korean=Baekmuk Gulim +monospaced.bolditalic.chinese-big5=AR PL ShanHeiSun Uni +monospaced.bolditalic.chinese-gb18030=AR PL ShanHeiSun Uni ++monospaced.bolditalic.assamese=Lohit Assamese ++monospaced.bolditalic.devanagari=Lohit Devanagari +monospaced.bolditalic.bengali=Lohit Bengali +monospaced.bolditalic.gujarati=Lohit Gujarati +monospaced.bolditalic.hindi=Lohit Hindi @@ -288,10 +335,13 @@ diff -r ea703df72762 src/solaris/classes +monospaced.bolditalic.sinhala=LKLUG + +dialoginput.plain.latin-1=DejaVu Sans Mono -+dialoginput.plain.japanese-x0208=Sazanami Gothic ++#dialoginput.plain.japanese-x0208=Sazanami Gothic ++dialoginput.plain.japanese-x0208=VL PGothic +dialoginput.plain.korean=Baekmuk Gulim +dialoginput.plain.chinese-big5=AR PL ShanHeiSun Uni +dialoginput.plain.chinese-gb18030=AR PL ShanHeiSun Uni ++dialoginput.plain.assamese=Lohit Assamese ++dialoginput.plain.devanagari=Lohit Devanagari +dialoginput.plain.bengali=Lohit Bengali +dialoginput.plain.gujarati=Lohit Gujarati +dialoginput.plain.hindi=Lohit Hindi @@ -303,10 +353,13 @@ diff -r ea703df72762 src/solaris/classes +dialoginput.plain.sinhala=LKLUG + +dialoginput.bold.latin-1=DejaVu Sans Mono Bold -+dialoginput.bold.japanese-x0208=Sazanami Gothic ++#dialoginput.bold.japanese-x0208=Sazanami Gothic ++dialoginput.bold.japanese-x0208=VL PGothic +dialoginput.bold.korean=Baekmuk Gulim +dialoginput.bold.chinese-big5=AR PL ShanHeiSun Uni +dialoginput.bold.chinese-gb18030=AR PL ShanHeiSun Uni ++dialoginput.bold.assamese=Lohit Assamese ++dialoginput.bold.devanagari=Lohit Devanagari +dialoginput.bold.bengali=Lohit Bengali +dialoginput.bold.gujarati=Lohit Gujarati +dialoginput.bold.hindi=Lohit Hindi @@ -318,10 +371,13 @@ diff -r ea703df72762 src/solaris/classes +dialoginput.bold.sinhala=LKLUG + +dialoginput.italic.latin-1=DejaVu Sans Mono Oblique -+dialoginput.italic.japanese-x0208=Sazanami Gothic ++#dialoginput.italic.japanese-x0208=Sazanami Gothic ++dialoginput.italic.japanese-x0208=VL PGothic +dialoginput.italic.korean=Baekmuk Gulim +dialoginput.italic.chinese-big5=AR PL ShanHeiSun Uni +dialoginput.italic.chinese-gb18030=AR PL ShanHeiSun Uni ++dialoginput.italic.assamese=Lohit Assamese ++dialoginput.italic.devanagari=Lohit Devanagari +dialoginput.italic.bengali=Lohit Bengali +dialoginput.italic.gujarati=Lohit Gujarati +dialoginput.italic.hindi=Lohit Hindi @@ -333,10 +389,13 @@ diff -r ea703df72762 src/solaris/classes +dialoginput.italic.sinhala=LKLUG + +dialoginput.bolditalic.latin-1=DejaVu Sans Mono Bold Oblique -+dialoginput.bolditalic.japanese-x0208=Sazanami Gothic ++#dialoginput.bolditalic.japanese-x0208=Sazanami Gothic ++dialoginput.bolditalic.japanese-x0208=VL PGothic +dialoginput.bolditalic.korean=Baekmuk Gulim +dialoginput.bolditalic.chinese-big5=AR PL ShanHeiSun Uni +dialoginput.bolditalic.chinese-gb18030=AR PL ShanHeiSun Uni ++dialoginput.bolditalic.assamese=Lohit Assamese ++dialoginput.bolditalic.devanagari=Lohit Devanagari +dialoginput.bolditalic.bengali=Lohit Bengali +dialoginput.bolditalic.gujarati=Lohit Gujarati +dialoginput.bolditalic.hindi=Lohit Hindi @@ -370,24 +429,29 @@ diff -r ea703df72762 src/solaris/classes + +filename.DejaVu_Serif=/usr/share/fonts/dejavu/DejaVuSerif.ttf +filename.DejaVu_Serif_Bold=/usr/share/fonts/dejavu/DejaVuSerif-Bold.ttf -+filename.DejaVu_Serif_Oblique=/usr/share/fonts/dejavu/DejaVuSerif-Oblique.ttf ++filename.DejaVu_Serif_Oblique=/usr/share/fonts/dejavu/DejaVuSerif-Oblique.ttfok +filename.DejaVu_Serif_Bold_Oblique=/usr/share/fonts/dejavu/DejaVuSerif-BoldOblique.ttf + -+filename.Sazanami_Gothic=/usr/share/fonts/sazanami-fonts-gothic/sazanami-gothic.ttf -+filename.Sazanami_Mincho=/usr/share/fonts/sazanami-fonts-mincho/sazanami-mincho.ttf -+filename.AR_PL_ShanHeiSun_Uni=/usr/share/fonts/cjkunifonts-uming/uming.ttc -+filename.AR_PL_ZenKai_Uni=/usr/share/fonts/cjkunifonts-ukai/ukai.ttc -+filename.Baekmuk_Gulim=/usr/share/fonts/baekmuk-ttf-gulim/gulim.ttf -+filename.Baekmuk_Batang=/usr/share/fonts/baekmuk-ttf-batang/batang.ttf ++#filename.Sazanami_Gothic=/usr/share/fonts/sazanami/gothic/sazanami-gothic.ttf ++#filename.Sazanami_Mincho=/usr/share/fonts/sazanami/mincho/sazanami-mincho.ttf ++filename.VL_Gothic=/usr/share/fonts/vlgothic/VL-Gothic-Regular.ttf ++filename.VL_PGothic=/usr/share/fonts/svlgothic/VL-PGothic-Regular.ttf ++filename.AR_PL_ShanHeiSun_Uni=/usr/share/fonts/cjkuni-uming/uming.ttc ++filename.AR_PL_ZenKai_Uni=/usr/share/fonts/cjkuni-ukai/ukai.ttc ++filename.Baekmuk_Gulim=/usr/share/fonts/baekmuk-ttf/gulim.ttf ++filename.Baekmuk_Batang=/usr/share/fonts/baekmuk-ttf/batang.ttf + -+filename.Lohit_Bengali=/usr/share/fonts/lohit-bengali/lohit_bn.ttf -+filename.Lohit_Gujarati=/usr/share/fonts/lohit-gujarati/lohit_gu.ttf -+filename.Lohit_Hindi=/usr/share/fonts/lohit-hindi/lohit_hi.ttf -+filename.Lohit_Kannda=/usr/share/fonts/lohit-kannada/lohit_kn.ttf -+filename.Lohit_Malayalam=/usr/share/fonts/lohit-malayalam/lohit_ml.ttf -+filename.Lohit_Oriya=/usr/share/fonts/lohit-oriya/lohit_or.ttf -+filename.Lohit_Punjabi=/usr/share/fonts/lohit-punjabi/lohit_pa.ttf -+filename.Lohit_Tamil=/usr/share/fonts/lohit-tamil/lohit_ta.ttf -+filename.Lohit_Telugu=/usr/share/fonts/lohit-telugu/lohit_te.ttf ++filename.Lohit_Assamese=/usr/share/fonts/lohit-assamese/Lohit-Assamese.ttf ++filename.Lohit_Devanagari=/usr/share/fonts/lohit-devanagari/Lohit-Devanagari.ttf ++filename.Lohit_Bengali=/usr/share/fonts/lohit-bengali/Lohit-Bengali.ttf ++filename.Lohit_Gujarati=/usr/share/fonts/lohit-gujarati/Lohit-Gujarati.ttf ++filename.Lohit_Hindi=/usr/share/fonts/lohit-devanagari/Lohit-Devanagari.ttf ++filename.Lohit_Kannda=/usr/share/fonts/lohit-kannada/Lohit-Kannada.ttf ++filename.Lohit_Malayalam=/usr/share/fonts/lohit-malayalam/Lohit-Malayalam.ttf ++filename.Lohit_Oriya=/usr/share/fonts/lohit-oriya/Lohit-Oriya.ttf ++filename.Lohit_Punjabi=/usr/share/fonts/lohit-punjabi/Lohit-Punjabi.ttf ++filename.Lohit_Tamil=/usr/share/fonts/lohit-tamil/Lohit-Tamil.ttf ++filename.Lohit_Telugu=/usr/share/fonts/lohit-telugu/Lohit-Telugu.ttf ++ +filename.LKLUG=/usr/share/fonts/lklug/lklug.ttf + diff -r 5af2053661b9 -r 6ec6e96141d8 patches/openjdk/6541476-png-iTXt-chunk.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/openjdk/6541476-png-iTXt-chunk.patch Tue Jan 18 15:17:47 2011 +0000 @@ -0,0 +1,549 @@ +diff -urN openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java +--- openjdk.orig/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java 2010-12-23 17:11:16.193446425 -0500 ++++ openjdk/jdk/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java 2010-12-23 17:11:29.399447037 -0500 +@@ -44,7 +44,6 @@ + import java.util.Arrays; + import java.util.Enumeration; + import java.util.Iterator; +-import java.util.List; + import java.util.zip.Inflater; From ptisnovs at icedtea.classpath.org Tue Jan 18 07:46:10 2011 From: ptisnovs at icedtea.classpath.org (ptisnovs at icedtea.classpath.org) Date: Tue, 18 Jan 2011 15:46:10 +0000 Subject: /hg/icedtea6: Added new regression test InternationalFontsStyles... Message-ID: changeset 477489da7897 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=477489da7897 author: ptisnovs date: Tue Jan 18 16:45:33 2011 +0100 Added new regression test InternationalFontsStyles.java. diffstat: 3 files changed, 288 insertions(+), 1 deletion(-) ChangeLog | 6 Makefile.am | 3 patches/jtreg-international-fonts-styles.patch | 280 ++++++++++++++++++++++++ diffs (310 lines): diff -r 974192ac0471 -r 477489da7897 ChangeLog --- a/ChangeLog Mon Jan 17 16:51:25 2011 -0500 +++ b/ChangeLog Tue Jan 18 16:45:33 2011 +0100 @@ -1,3 +1,9 @@ 2011-01-17 Omair Majid + + * Makefile.am: Apply patch. + * patches/jtreg-international-fonts-styles.patch: + Added new font regression test - InternationalFontsStyles + 2011-01-17 Omair Majid * Makefile.am (ICEDTEA_PATCHES): Add new patch. diff -r 974192ac0471 -r 477489da7897 Makefile.am --- a/Makefile.am Mon Jan 17 16:51:25 2011 -0500 +++ b/Makefile.am Tue Jan 18 16:45:33 2011 +0100 @@ -317,7 +317,8 @@ ICEDTEA_PATCHES = \ patches/openjdk/6541476-png-iTXt-chunk.patch \ patches/openjdk/6782079-png_metadata_oom.patch \ patches/661505-jpeg.patch \ - patches/openjdk/6642612-filechooser_button_sizes.patch + patches/openjdk/6642612-filechooser_button_sizes.patch \ + patches/jtreg-international-fonts-styles.patch if WITH_ALT_HSBUILD ICEDTEA_PATCHES += \ diff -r 974192ac0471 -r 477489da7897 patches/jtreg-international-fonts-styles.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/jtreg-international-fonts-styles.patch Tue Jan 18 16:45:33 2011 +0100 @@ -0,0 +1,280 @@ +--- /dev/null 2010-06-29 11:10:08.737208357 +0200 ++++ openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsStyles.java 2011-01-17 17:06:44.452369000 +0100 +@@ -0,0 +1,277 @@ ++/* ++ * Copyright 2011 Red Hat, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ */ ++ ++import java.awt.Color; ++import java.awt.Font; ++import java.awt.Graphics2D; ++import java.awt.RenderingHints; ++import java.awt.image.BufferedImage; ++import java.io.File; ++import java.io.IOException; ++import java.util.Arrays; ++import java.util.List; ++import java.util.ArrayList; ++ ++import javax.imageio.ImageIO; ++ ++/** ++ * @test ++ * @run main InternationalFontsStyles ++ * @author Pavel Tisnovsky ++ * ++ * @summary This test check if selected international characters could be ++ * properly rendered with various font styles and logical names. ++ * ++ * This regression test check if selected international characters ++ * could be properly rendered using various styles and logical font ++ * names - the test check rendering using all combinations of logical ++ * font names (Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, ++ * Font.DIALOG, Font.DIALOG_INPUT) and font styles (Font.PLAIN, ++ * Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC). ++ * ++ * The test is based on rendering certain characters from selected code ++ * pages into BufferedImage. ++ * ++ * When the shape of selected character does not exists or font ++ * configuration is broken, only empty rectangle is rendered instead of ++ * the selected character shape. This rectangle is filtered and then ++ * the destination image is tested whether it is empty (=white). ++ * ++ * If test images with rendered characters needs to be created use ++ * following flag: -create-images ++ * ++ */ ++public class InternationalFontsStyles ++{ ++ // all logical font names which are tested ++ private static final String[] fontNames = {Font.SERIF, Font.SANS_SERIF, Font.MONOSPACED, Font.DIALOG, Font.DIALOG_INPUT}; ++ ++ // all font styles which are tested ++ private static final int[] fontStyles = {Font.PLAIN, Font.BOLD, Font.ITALIC, Font.BOLD+Font.ITALIC}; ++ ++ // width and height of image where is each character rendered ++ private static int WIDTH = 200; ++ private static int HEIGHT = 200; ++ ++ // font size used for rendering ++ private static final int FONT_SIZE = 160; ++ ++ private static final int MINIMUM_HORIZONTAL_LINE_LENGTH = 70; ++ private static final int MINIMUM_VERTICAL_LINE_LENGTH = 80; ++ private static final int BLACK_WHITE_THRESHOLD = 128; ++ private static final int BLACK_PIXEL_COUNT_THRESHOLD = WIDTH * HEIGHT / 1000; ++ ++ private static final String[][] testedStrings = { ++ {"Latin-1", "abcdefABCDEF"}, ++ {"Latin-2", "\u011b\u0161\u010d\u0159\u017e\u00fd\u00e1\u00ed\u00e9\u00fa\u016f\u013e\u0148"}, ++ {"Cyrilic", "\u0414\u0417\u0418\u0472\u0424\u0425\u0470\u0460\u0426"}, ++ {"Greek", "\u03b2\u03be\u03b3\u03b4\u03c0\u03b5\u03c1\u03b6\u03a3\u03c3\u03c2\u03b7\u03c4\u03b8\u03c5\u03a9"}, ++ {"Asia-Test1", "\u4f53\u4e2d\u6587\u7b26\u53f7"}, ++ {"Asia-Test2", "\u7e41\u9ad4\u4e2d\u6587\u7b26\u865f"}, ++ {"Asia-Test3", "\u65e5\u672c\u306e\u8c61\u5fb4"}, ++ {"Asia-Test4", "\ud55c\uad6d\uc5b4\uae30\ud638"}, ++ }; ++ ++ /** ++ * Returns string containing given font style. This style could ++ * be PLAIN, BOLD, ITALIC or combination of these styles. ++ * ++ * @param fontStyle selected font style, eg. Font.BOLD ++ * @return textual representation of font style ++ */ ++ private static String getFontStyle(int fontStyle) ++ { ++ return new String[] ++ // 0 1 2 1+2 ++ { "PLAIN", "BOLD", "ITALIC", "BOLD+ITALIC" }[fontStyle]; ++ } ++ ++ /** ++ * Creates test image a renders one big character to it. ++ * @param str string to be rendered ++ * @param fontStyle selected font style ++ * @param fontName selected font name ++ * @return ++ */ ++ private BufferedImage createTestImage(String str, String fontName, int fontStyle) { ++ BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); ++ Graphics2D gc = image.createGraphics(); ++ gc.setBackground(Color.WHITE); ++ gc.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_OFF); ++ gc.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING, RenderingHints.VALUE_TEXT_ANTIALIAS_OFF); ++ gc.clearRect(0, 0, WIDTH, HEIGHT); ++ gc.setFont(new Font(fontName, fontStyle, FONT_SIZE)); ++ gc.setColor(Color.BLACK); ++ gc.drawString(str, 0, HEIGHT - 40); ++ gc.dispose(); ++ return image; ++ } ++ ++ /** ++ * Creates destination image and then copies data from source image to it ++ * @param src source image ++ * @return destination image as copy of source image ++ */ ++ private BufferedImage createDestinationImage(BufferedImage src) ++ { ++ BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_BYTE_GRAY); ++ src.copyData(image.getRaster()); ++ return image; ++ } ++ ++ /** ++ * Removes long horizontal lines from image ++ */ ++ private void removeHorizontalLines(BufferedImage image) ++ { ++ for (int y = 0; y < image.getHeight(); y++) ++ { ++ int startX = -1, endX = -1; ++ for (int x = 0; x < image.getWidth(); x++) ++ { ++ int color = image.getRaster().getSample(x, y, 0); ++ if (startX < 0 && color <= BLACK_WHITE_THRESHOLD) { ++ startX = x; ++ //System.out.println("> " + y + "\t" + x); ++ } ++ if (startX > 0 && endX < 0 && color > BLACK_WHITE_THRESHOLD) ++ { ++ endX = x; ++ //System.out.println("< " + y + "\t" + x); ++ } ++ } ++ // remove long horizontal line, but only if this line found detected in image ++ if (startX > 0 && endX > 0 && (endX - startX) > MINIMUM_HORIZONTAL_LINE_LENGTH) ++ { ++ for (int x = startX; x < endX; x++) { ++ image.getRaster().setSample(x, y, 0, 255); ++ } ++ } ++ } ++ } ++ ++ /** ++ * Removes long vertical lines from image ++ */ ++ private void removeVerticalLines(BufferedImage image) ++ { ++ for (int x = 0; x < image.getWidth(); x++) ++ { ++ int startY = -1, endY = -1; ++ for (int y = 0; y < image.getHeight(); y++) ++ { ++ int color = image.getRaster().getSample(x, y, 0); ++ if (startY < 0 && color <= BLACK_WHITE_THRESHOLD) ++ { ++ startY = y; ++ } ++ if (startY > 0 && endY < 0 && color > BLACK_WHITE_THRESHOLD) ++ { ++ endY = y; ++ //System.out.println("< " + y + "\t" + x); ++ } ++ } ++ // remove long vertical line, but only if this line found detected in image ++ if (startY > 0 && endY > 0 && (endY - startY) > MINIMUM_VERTICAL_LINE_LENGTH) ++ { ++ for (int y = startY; y < endY; y++) { ++ image.getRaster().setSample(x, y, 0, 255); ++ } ++ } ++ } ++ } ++ ++ /** ++ * Test if image is almost empty (one large white area) ++ * @param image ++ * @return ++ */ ++ private boolean isImageAlmostEmpty(BufferedImage image) ++ { ++ int blackPixelCount = 0; ++ for (int y = 0; y < image.getHeight(); y++) ++ { ++ for (int x = 0; x < image.getWidth(); x++) ++ { ++ if (image.getRaster().getSample(x, y, 0) < BLACK_WHITE_THRESHOLD) ++ { ++ blackPixelCount++; ++ } ++ } ++ } ++ return blackPixelCount < BLACK_PIXEL_COUNT_THRESHOLD; ++ } ++ ++ private String constructImageFileName(String fontName, int fontStyle, int code, String suffix) ++ { ++ return fontName + "_" + getFontStyle(fontStyle) + "_" + code + "_" + suffix + ".png"; ++ } ++ ++ public void runTest(boolean createImages) throws IOException ++ { ++ List badCharacters = new ArrayList(); ++ for (String[] testedString : testedStrings) ++ { ++ for (String fontName : fontNames) ++ { ++ for (int fontStyle : fontStyles) ++ { ++ System.out.format("check string %s rendered by font %s with style %s\n", testedString[1], fontName, ++ getFontStyle(fontStyle)); ++ for (int i = 0; i < testedString[1].length(); i++) ++ { ++ String str = testedString[1].substring(i, 1 + i); ++ int code = str.charAt(0); ++ System.out.print(code + "\t"); ++ BufferedImage src = createTestImage(str, fontName, fontStyle); ++ BufferedImage dst = createDestinationImage(src); ++ removeHorizontalLines(dst); ++ removeVerticalLines(dst); ++ ++ if (createImages /*|| true*/) ++ { ++ ImageIO.write(src, "png", ++ new File(constructImageFileName(fontName, fontStyle, code, "scr"))); ++ ImageIO.write(dst, "png", ++ new File(constructImageFileName(fontName, fontStyle, code, "dst"))); ++ } ++ ++ if (isImageAlmostEmpty(dst)) ++ { ++ System.out.println("*** Error in rendering of character with code: " + code); ++ badCharacters.add(Integer.valueOf(code)); ++ } ++ } ++ System.out.println(); ++ } ++ } ++ } ++ // if at least one character is not rendered properly throw an exception ++ if (!badCharacters.isEmpty()) ++ { ++ throw new RuntimeException("There are some broken characters: " + badCharacters.toString()); ++ } ++ System.out.println("done!"); ++ } ++ ++ public static void main(String[] args) throws IOException ++ { ++ new InternationalFontsStyles().runTest(Arrays.asList(args).contains("-create-images")); ++ } ++} From ptisnovs at redhat.com Tue Jan 18 09:00:10 2011 From: ptisnovs at redhat.com (Pavel Tisnovsky) Date: Tue, 18 Jan 2011 18:00:10 +0100 Subject: Reviewer needed - simple changes in regression test InternationalFontsRendering Message-ID: <4D35C71A.3090605@redhat.com> Hi all, could anybody please review two simple changes in regression test InternationalFontsRendering.java which is included in IcedTea6 as patch icedtea-jtreg-international-fonts.patch? 1st change: added missing copyright info (this test was created by me last year hence I used 2010 in (c)) 2nd change: string which contained UTF-8 characters were translated using native2ascii to use Unicode escape notation Thank you in advance Pavel Here is hg diff generated against recent IcedTea6 version: diff -r 477489da7897 ChangeLog --- a/ChangeLog Tue Jan 18 16:45:33 2011 +0100 +++ b/ChangeLog Tue Jan 18 17:50:18 2011 +0100 @@ -1,3 +1,10 @@ +2011-01-18 Pavel Tisnovsky + + * patches/icedtea-jtreg-international-fonts.patch: + Added copyright info and translated string originally encoded + in UTF-8 into string using Unicode escape notation in + regression test InternationalFontsRendering.java + 2011-01-18 Pavel Tisnovsky * Makefile.am: Apply patch. diff -r 477489da7897 patches/icedtea-jtreg-international-fonts.patch --- a/patches/icedtea-jtreg-international-fonts.patch Tue Jan 18 16:45:33 2011 +0100 +++ b/patches/icedtea-jtreg-international-fonts.patch Tue Jan 18 17:50:18 2011 +0100 @@ -1,6 +1,25 @@ ---- /dev/null 2010-06-29 14:56:30.329576932 +0200 -+++ openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsRendering.java 2010-11-01 11:27:46.000000000 +0100 -@@ -0,0 +1,192 @@ +--- /dev/null 2010-06-29 11:10:08.737208357 +0200 ++++ openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsRendering.java 2011-01-17 17:06:44.000000000 +0100 +@@ -0,0 +1,211 @@ ++/* ++ * Copyright 2010 Red Hat, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ */ ++ +import java.awt.Color; +import java.awt.Font; +import java.awt.Graphics2D; @@ -51,13 +70,13 @@ + + private static final String[][] testedStrings = { + {"Latin-1", "abcdefABCDEF"}, -+ {"Latin-2", "?????????????"}, -+ {"Cyrilic", "?????????"}, -+ {"Greek", "????????????????"}, -+ {"Asia-Test1", "?????"}, -+ {"Asia-Test2", "??????"}, -+ {"Asia-Test3", "?????"}, -+ {"Asia-Test4", "?????"}, ++ {"Latin-2", "\u011b\u0161\u010d\u0159\u017e\u00fd\u00e1\u00ed\u00e9\u00fa\u016f\u013e\u0148"}, ++ {"Cyrilic", "\u0414\u0417\u0418\u0472\u0424\u0425\u0470\u0460\u0426"}, ++ {"Greek", "\u03b2\u03be\u03b3\u03b4\u03c0\u03b5\u03c1\u03b6\u03a3\u03c3\u03c2\u03b7\u03c4\u03b8\u03c5\u03a9"}, ++ {"Asia-Test1", "\u4f53\u4e2d\u6587\u7b26\u53f7"}, ++ {"Asia-Test2", "\u7e41\u9ad4\u4e2d\u6587\u7b26\u865f"}, ++ {"Asia-Test3", "\u65e5\u672c\u306e\u8c61\u5fb4"}, ++ {"Asia-Test4", "\ud55c\uad6d\uc5b4\uae30\ud638"}, + }; + + /** From dbhole at redhat.com Tue Jan 18 10:02:30 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Tue, 18 Jan 2011 13:02:30 -0500 Subject: [RFC][IcedTea-Web]: Moved creation of swing thread. In-Reply-To: <4D13B9CB.2090604@redhat.com> References: <678041380.73892.1293138257029.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <4D13B9CB.2090604@redhat.com> Message-ID: <20110118180227.GC4315@redhat.com> * Omair Majid [2010-12-23 16:07]: > On 12/23/2010 04:04 PM, Andrew Su wrote: > >>> setSystemLookAndFeel(); > >> > >>Can you please remove this? I dont think this is doing anything. > >As said in previous e-mail, this will be in the patch to follow. > > Sorry, I must have missed it. > > > > >Can you look it over again once more, for some of the changes. Thanks. > >Ok for head? > > > > Yup. Ok for HEAD. Okay for 1.0 as well. Would be a nice bugfix to have in stable release. Deepak > > Cheers, > Omair From dbhole at icedtea.classpath.org Tue Jan 18 10:09:23 2011 From: dbhole at icedtea.classpath.org (dbhole at icedtea.classpath.org) Date: Tue, 18 Jan 2011 18:09:23 +0000 Subject: /hg/release/icedtea-web-1.0: RH663680, CVE-2010-4351: JNLP Secur... Message-ID: changeset ee7a2e5e3849 in /hg/release/icedtea-web-1.0 details: http://icedtea.classpath.org/hg/release/icedtea-web-1.0?cmd=changeset;node=ee7a2e5e3849 author: Deepak Bhole date: Tue Jan 18 12:07:45 2011 -0500 RH663680, CVE-2010-4351: JNLP SecurityManager bypass 2010-12-16 Omair Majid RH663680, CVE-2010-4351: * NEWS: List issue. * netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: Make sure SecurityException is thrown if necessary. diffstat: 3 files changed, 10 insertions(+) ChangeLog | 7 +++++++ NEWS | 1 + netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java | 2 ++ diffs (46 lines): diff -r b3647620fa41 -r ee7a2e5e3849 ChangeLog --- a/ChangeLog Fri Jan 07 08:08:41 2011 -0500 +++ b/ChangeLog Tue Jan 18 12:07:45 2011 -0500 @@ -24,6 +24,13 @@ 2010-12-22 Deepak Bhole + + RH663680, CVE-2010-4351: + * NEWS: List issue. + * netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: + Make sure SecurityException is thrown if necessary. 2010-12-14 Andrew John Hughes diff -r b3647620fa41 -r ee7a2e5e3849 NEWS --- a/NEWS Fri Jan 07 08:08:41 2011 -0500 +++ b/NEWS Tue Jan 18 12:07:45 2011 -0500 @@ -28,5 +28,6 @@ New in release 1.0 (2010-XX-XX): - Add a new option -Xclearcache - Interfaces javax.jnlp.IntegrationService and javax.jnlp.DownloadService2 are now available - PR592: NetX can create invalid desktop entry files + - RH663680, CVE-2010-4351: IcedTea JNLP SecurityManager bypass * Control Panel - Modifications to deployments.properties file can now be done through a GUI diff -r b3647620fa41 -r ee7a2e5e3849 netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java --- a/netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java Fri Jan 07 08:08:41 2011 -0500 +++ b/netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java Tue Jan 18 12:07:45 2011 -0500 @@ -313,6 +313,7 @@ class JNLPSecurityManager extends AWTSec } } else if (perm instanceof SecurityPermission) { + tmpPerm = perm; // JCE's initialization requires putProviderProperty permission if (perm.equals(new SecurityPermission("putProviderProperty.SunJCE"))) { @@ -322,6 +323,7 @@ class JNLPSecurityManager extends AWTSec } } else if (perm instanceof RuntimePermission) { + tmpPerm = perm; // KeyGenerator's init method requires internal spec access if (perm.equals(new SecurityPermission("accessClassInPackage.sun.security.internal.spec"))) { From dbhole at icedtea.classpath.org Tue Jan 18 10:13:34 2011 From: dbhole at icedtea.classpath.org (dbhole at icedtea.classpath.org) Date: Tue, 18 Jan 2011 18:13:34 +0000 Subject: /hg/icedtea-web: RH663680, CVE-2010-4351: JNLP SecurityManager b... Message-ID: changeset 925f97c584a8 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=925f97c584a8 author: Deepak Bhole date: Tue Jan 18 12:07:45 2011 -0500 RH663680, CVE-2010-4351: JNLP SecurityManager bypass 2010-12-16 Omair Majid RH663680, CVE-2010-4351: * NEWS: List issue. * netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: Make sure SecurityException is thrown if necessary. diffstat: 3 files changed, 10 insertions(+) ChangeLog | 7 +++++++ NEWS | 1 + netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java | 2 ++ diffs (46 lines): diff -r 98215ab000dd -r 925f97c584a8 ChangeLog --- a/ChangeLog Mon Jan 17 13:44:31 2011 -0500 +++ b/ChangeLog Tue Jan 18 12:07:45 2011 -0500 @@ -248,6 +248,13 @@ 2010-12-17 Omair Majid + + RH663680, CVE-2010-4351: + * NEWS: List issue. + * netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: + Make sure SecurityException is thrown if necessary. 2010-12-15 Omair Majid diff -r 98215ab000dd -r 925f97c584a8 NEWS --- a/NEWS Mon Jan 17 13:44:31 2011 -0500 +++ b/NEWS Tue Jan 18 12:07:45 2011 -0500 @@ -28,5 +28,6 @@ New in release 1.0 (2010-XX-XX): - Add a new option -Xclearcache - Interfaces javax.jnlp.IntegrationService and javax.jnlp.DownloadService2 are now available - PR592: NetX can create invalid desktop entry files + - RH663680, CVE-2010-4351: IcedTea JNLP SecurityManager bypass * Control Panel - Modifications to deployments.properties file can now be done through a GUI diff -r 98215ab000dd -r 925f97c584a8 netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java --- a/netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java Mon Jan 17 13:44:31 2011 -0500 +++ b/netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java Tue Jan 18 12:07:45 2011 -0500 @@ -308,6 +308,7 @@ class JNLPSecurityManager extends AWTSec } } else if (perm instanceof SecurityPermission) { + tmpPerm = perm; // JCE's initialization requires putProviderProperty permission if (perm.equals(new SecurityPermission("putProviderProperty.SunJCE"))) { @@ -317,6 +318,7 @@ class JNLPSecurityManager extends AWTSec } } else if (perm instanceof RuntimePermission) { + tmpPerm = perm; // KeyGenerator's init method requires internal spec access if (perm.equals(new SecurityPermission("accessClassInPackage.sun.security.internal.spec"))) { From asu at redhat.com Tue Jan 18 10:42:06 2011 From: asu at redhat.com (Andrew Su) Date: Tue, 18 Jan 2011 13:42:06 -0500 (EST) Subject: [RFC][IcedTea-Web]: Moved creation of swing thread. In-Reply-To: <20110118180227.GC4315@redhat.com> Message-ID: <1785592872.4230.1295376126510.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> ----- Original Message ----- > From: "Deepak Bhole" > To: "Omair Majid" > Cc: "Andrew Su" , "distro-pkg-dev" > Sent: Tuesday, January 18, 2011 1:02:30 PM > Subject: Re: [RFC][IcedTea-Web]: Moved creation of swing thread. > * Omair Majid [2010-12-23 16:07]: > > On 12/23/2010 04:04 PM, Andrew Su wrote: > > >>> setSystemLookAndFeel(); > > >> > > >>Can you please remove this? I dont think this is doing anything. > > >As said in previous e-mail, this will be in the patch to follow. > > > > Sorry, I must have missed it. > > > > > > > >Can you look it over again once more, for some of the changes. > > >Thanks. > > >Ok for head? > > > > > > > Yup. Ok for HEAD. > > Okay for 1.0 as well. Would be a nice bugfix to have in stable > release. Hello, The export does not apply cleanly due to other changes from other changesets prior to this one. I have attached a patch that will fix the appropriate files. Cheer, Andrew > > Deepak > > > > > Cheers, > > Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: fix.patch Type: text/x-patch Size: 1740 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110118/485a5bda/fix.patch From dbhole at redhat.com Tue Jan 18 10:16:45 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Tue, 18 Jan 2011 13:16:45 -0500 Subject: [RFC][IcedTea-Web]: Moved creation of swing thread. In-Reply-To: <1785592872.4230.1295376126510.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> References: <20110118180227.GC4315@redhat.com> <1785592872.4230.1295376126510.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Message-ID: <20110118181644.GA3966@redhat.com> * Andrew Su [2011-01-18 13:42]: > > > ----- Original Message ----- > > From: "Deepak Bhole" > > To: "Omair Majid" > > Cc: "Andrew Su" , "distro-pkg-dev" > > Sent: Tuesday, January 18, 2011 1:02:30 PM > > Subject: Re: [RFC][IcedTea-Web]: Moved creation of swing thread. > > * Omair Majid [2010-12-23 16:07]: > > > On 12/23/2010 04:04 PM, Andrew Su wrote: > > > >>> setSystemLookAndFeel(); > > > >> > > > >>Can you please remove this? I dont think this is doing anything. > > > >As said in previous e-mail, this will be in the patch to follow. > > > > > > Sorry, I must have missed it. > > > > > > > > > > >Can you look it over again once more, for some of the changes. > > > >Thanks. > > > >Ok for head? > > > > > > > > > > Yup. Ok for HEAD. > > > > Okay for 1.0 as well. Would be a nice bugfix to have in stable > > release. > Hello, > > The export does not apply cleanly due to other changes from other changesets prior to this one. > > I have attached a patch that will fix the appropriate files. > > Cheer, > Andrew > Looks fine. Okay for 1.0. Cheers, Deepak > > > > > > Deepak > > > > > > > > Cheers, > > > Omair > diff -r ee7a2e5e3849 ChangeLog > --- a/ChangeLog Tue Jan 18 12:07:45 2011 -0500 > +++ b/ChangeLog Tue Jan 18 13:41:01 2011 -0500 > @@ -1,3 +1,8 @@ > +2011-01-18 Andrew Su > + > + * netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java: > + (showAdvancedProxySettingsDialog): Removed creation of swing thread. > + > 2011-01-04 Omair Majid > > * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java > diff -r ee7a2e5e3849 netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java > --- a/netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java Tue Jan 18 12:07:45 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java Tue Jan 18 13:41:01 2011 -0500 > @@ -116,21 +116,13 @@ > * > * @param config > * A loaded DeploymentConfiguration file. > - * @throws Exception > */ > - public static void showAdvancedProxySettingsDialog(final DeploymentConfiguration config) throws Exception { > - setSystemLookAndFeel(); > - SwingUtilities.invokeLater(new Runnable() { > - @Override > - public void run() { > - AdvancedProxySettingsDialog psd = new AdvancedProxySettingsDialog(config); > - psd.setResizable(false); > - psd.centerDialog(); > - psd.setVisible(true); > - psd.dispose(); > - } > - }); > - > + public static void showAdvancedProxySettingsDialog(final DeploymentConfiguration config) { > + AdvancedProxySettingsDialog psd = new AdvancedProxySettingsDialog(config); > + psd.setResizable(false); > + psd.centerDialog(); > + psd.setVisible(true); > + psd.dispose(); > } > > /** From asu at icedtea.classpath.org Tue Jan 18 10:51:52 2011 From: asu at icedtea.classpath.org (asu at icedtea.classpath.org) Date: Tue, 18 Jan 2011 18:51:52 +0000 Subject: /hg/release/icedtea-web-1.0: Remove creation of swing thread for... Message-ID: changeset 71d6595e800c in /hg/release/icedtea-web-1.0 details: http://icedtea.classpath.org/hg/release/icedtea-web-1.0?cmd=changeset;node=71d6595e800c author: Andrew Su date: Tue Jan 18 13:51:34 2011 -0500 Remove creation of swing thread for displaying dialogs. diffstat: 2 files changed, 11 insertions(+), 14 deletions(-) ChangeLog | 5 ++ netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java | 20 +++------- diffs (43 lines): diff -r ee7a2e5e3849 -r 71d6595e800c ChangeLog --- a/ChangeLog Tue Jan 18 12:07:45 2011 -0500 +++ b/ChangeLog Tue Jan 18 13:51:34 2011 -0500 @@ -1,3 +1,8 @@ 2011-01-04 Omair Majid + + * netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java: + (showAdvancedProxySettingsDialog): Removed creation of swing thread. + 2011-01-04 Omair Majid * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java diff -r ee7a2e5e3849 -r 71d6595e800c netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java --- a/netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java Tue Jan 18 12:07:45 2011 -0500 +++ b/netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java Tue Jan 18 13:51:34 2011 -0500 @@ -116,21 +116,13 @@ public class AdvancedProxySettingsDialog * * @param config * A loaded DeploymentConfiguration file. - * @throws Exception */ - public static void showAdvancedProxySettingsDialog(final DeploymentConfiguration config) throws Exception { - setSystemLookAndFeel(); - SwingUtilities.invokeLater(new Runnable() { - @Override - public void run() { - AdvancedProxySettingsDialog psd = new AdvancedProxySettingsDialog(config); - psd.setResizable(false); - psd.centerDialog(); - psd.setVisible(true); - psd.dispose(); - } - }); - + public static void showAdvancedProxySettingsDialog(final DeploymentConfiguration config) { + AdvancedProxySettingsDialog psd = new AdvancedProxySettingsDialog(config); + psd.setResizable(false); + psd.centerDialog(); + psd.setVisible(true); + psd.dispose(); } /** From dbhole at redhat.com Tue Jan 18 12:58:21 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Tue, 18 Jan 2011 15:58:21 -0500 Subject: [icedtea-web] Tests for IcedTea-Web Message-ID: <20110118205820.GA6100@redhat.com> Hi, Omair and I had a talk about adding tests to icedtea-web. Currently, only the plugin has liveconnect tests. It would be nice to have tests for webstart as well. Omair has some unit tests, and some standalone jnlp applications that he has used in the past and he is going to start uploading them. In order to accommodate various kinds of tests, IcedTea-Web's directory structure will be changed as follows: $ROOT/plugin/tests will be moved to $ROOT/tests/plugin A new directory, $ROOT/tests/netx will be created, and it will house unit tests, application tests (for applications we created) and a list of 3rd party jnlp applications that we will attempt to tie in for some sort of automatic testing. Comments? Suggestions? Cheers, Deepak From mark at klomp.org Tue Jan 18 13:22:44 2011 From: mark at klomp.org (Mark Wielaard) Date: Tue, 18 Jan 2011 22:22:44 +0100 Subject: [icedtea-web] Tests for IcedTea-Web In-Reply-To: <20110118205820.GA6100@redhat.com> References: <20110118205820.GA6100@redhat.com> Message-ID: <1295385764.5442.22.camel@springer.wildebeest.org> On Tue, 2011-01-18 at 15:58 -0500, Deepak Bhole wrote: > A new directory, $ROOT/tests/netx will be created, and it will house > unit tests, application tests (for applications we created) and a list > of 3rd party jnlp applications that we will attempt to tie in for some > sort of automatic testing. > > Comments? Suggestions? Could you make it so that the unit tests are run on a make check? And that they produce some easily parseble format (PASS/FAIL)? Then the new buildbot setup (not announced yet, need to tweak it so it sends proper emails when things break) should automagically pick it up and show when tests started failing (it already calls make check, which currently trivially succeeds). http://builder.classpath.org/icedtea/buildbot/waterfall?show=icedtea-web-squeeze-x86_64 Thanks, Mark From omajid at redhat.com Tue Jan 18 13:26:38 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 18 Jan 2011 16:26:38 -0500 Subject: Request to backport 6736649 and 6797139 In-Reply-To: <20110117200053.GL13471@rivendell.middle-earth.co.uk> References: <4D30CFB1.6050705@redhat.com> <20110117141006.GA13471@rivendell.middle-earth.co.uk> <4D3454D9.7040200@redhat.com> <20110117170055.GD13471@rivendell.middle-earth.co.uk> <4D348843.2060602@redhat.com> <20110117185548.GJ13471@rivendell.middle-earth.co.uk> <4D349889.80701@redhat.com> <20110117200053.GL13471@rivendell.middle-earth.co.uk> Message-ID: <4D36058E.3080209@redhat.com> On 01/17/2011 03:00 PM, Dr Andrew John Hughes wrote: > On 14:29 Mon 17 Jan , Omair Majid wrote: >> On 01/17/2011 01:55 PM, Dr Andrew John Hughes wrote: >>> On 13:19 Mon 17 Jan , Omair Majid wrote: >>>> On 01/17/2011 12:00 PM, Dr Andrew John Hughes wrote: >>>>> On 09:40 Mon 17 Jan , Omair Majid wrote: >>>>>> On 01/17/2011 09:10 AM, Dr Andrew John Hughes wrote: >>>>>>> On 17:35 Fri 14 Jan , Omair Majid wrote: >>>>>>>> I would like to backport the following two changesets to openjdk6: >>>>>>>> >>>>>>>> changeset: 624:e78c2f17a606 >>>>>>>> user: mlapshin >>>>>>>> date: Tue Aug 26 12:16:23 2008 +0400 >>>>>>>> summary: 6736649: >>>>>>>> test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on >>>>>>>> Linux >>>>>>>> >>>>>>>> changeset: 1637:281fbd82a971 >>>>>>>> user: alexp >>>>>>>> date: Wed Sep 02 17:47:19 2009 +0400 >>>>>>>> summary: 6797139: JButton title is truncating for some strings >>>>>>>> irrespective of preferred size. >>>>>>>> >>>>>>>> Together, these changesets fix a bug where some strings are incorrectly >>>>>>>> being truncated. >>>>>>>> >>>>>>> >>>>>>> I don't see either of these in IcedTea6. Please add them there first before >>>>>>> trying to upstream them. >>>>>>> >>>>>> >>>>>> I was going to add them to IcedTea6 as soon as Joe approved them for >>>>>> openjdk6. Can I assume you are okay with adding it to IcedTea6 without >>>>>> waiting for Joe's comments? >>>>> >>>>> Post the patch and we can make that decision :-) >>>>> >>>> >>>> I have attached the patch for icedtea6. Ok to commit? >>>> >>>> Thanks, >>>> Omair >>> >>> The changesets seem to have a lot of whitespace changes, which make it >>> hard to read, but as these come from the upstream changesets, there's >>> not much to be done about that. Is it correct that the first adds the >>> calculation of the right width and then the second removes it? >>> >>>> +- textRect.width += getLeftTextExtraWidth() + getRightTextExtraWidth(); >>>> ++ textRect.width += getLeftTextExtraWidth(); >>> >> >> Yes. Apparently there were some fixes that were performed before OpenJDK >> was branched; the second patch rolls back some of those changes. From >> what I can tell, this rollback patch seems quite hackish. But perhaps >> this is just the complexity of the JDK code. >> > > It's annoying that so much history has not been preserved correctly. > Agreed. The bug reports leave much to be desired as well :( >>> I'm a little worried by the addition of an exception: >>> >>>> + * Returns the left side bearing of the first character of string. The >>>> +- * left side bearing is calculated from the passed in FontMetrics. >>>> ++ * left side bearing is calculated from the passed in >>>> ++ * FontMetrics. If the passed in String is less than one >>>> ++ * character, this will throw a StringIndexOutOfBoundsException exception. >>>> + * >>>> + * @param c JComponent that will display the string >>>> + * @param fm FontMetrics used to measure the String width >>>> +@@ -234,14 +245,11 @@ >>>> + */ >>>> + public static int getLeftSideBearing(JComponent c, FontMetrics fm, >>>> + String string) { >>>> +- if ((string == null) || (string.length() == 0)) { >>>> +- return 0; >>>> +- } >>>> + return getLeftSideBearing(c, fm, string.charAt(0)); >>>> + } >>> >>> Is this visible further up the stack? >>> >> >> Hm. I missed that. In general yes, it will be visible - >> sun.swing.SwingUtilities2 is a public class. On the other hand, it is >> supposed to be an internal class not part of the public API. From the >> Javadocs: >> >> WARNING: While this class is public, it should not be treated as >> public API and its API may change in incompatable ways between dot dot >> releases and even patch releases. You should not rely on this class even >> existing. >> >> Perhaps worse than the exception, the patch removes a public method: >> +- public static int getRightSideBearing(JComponent c, FontMetrics fm, >> +- String string) { >> >> I am starting to have second thoughts about backporting this. >> >> On the other hand, I can see (using reflection) that the proprietary JDK >> 6 does not have getRightSideBearing methods either. >> > > It doesn't matter about changing the API of classes outside those that form part > of the public documentation (mainly java.* and javax.*.). My concern was that > this exception would travel up the stack and be thrown from a javax.swing method > where it wasn't previously. Can you check what calls this method and whether it > can reach that level? > Pretty much any swing program using JMenus will hit this code and cause a StringIndexOutOfBoundsException :/ > I'm still for backporting as it fixes a bug users have encountered. If necessary, > we can just drop the changes which allow the exception to be thrown. > Looks like the openjdk7 folks ran into this same problem and fixed it: changeset: 1738:9d78c3d9def2 user: alexp date: Mon Sep 21 17:58:09 2009 +0400 summary: 6883341: SWAT: jdk7-b72 swat build(2009-09-17) threw exceptions when running Java2D demo by clicking Paint ta This changeset gets rid of the StringIndexOutOfBoundsException (by effectively reverting the exception changes). >>> Do the new tests pass? They should be fixed to use the newer Oracle copyright notices. >>> >> >> Sorry, but I forgot to run the tests. I will fix the copyrights, run the >> tests and post the results. I can confirm that the patch does fix the >> issue pointed out in the bug report at >> https://bugzilla.redhat.com/show_bug.cgi?id=661610 >> > > This sounds a good reason to backport. > > I'll await the results. I can confirm that the new tests pass. However, I also discovered that swing programs using JMenus crash, so I didnt attempt to run all the tests. I will post an updated patch soon. Thanks, Omair From dbhole at redhat.com Tue Jan 18 13:27:39 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Tue, 18 Jan 2011 16:27:39 -0500 Subject: [icedtea-web] Tests for IcedTea-Web In-Reply-To: <1295385764.5442.22.camel@springer.wildebeest.org> References: <20110118205820.GA6100@redhat.com> <1295385764.5442.22.camel@springer.wildebeest.org> Message-ID: <20110118212739.GB6100@redhat.com> * Mark Wielaard [2011-01-18 16:23]: > On Tue, 2011-01-18 at 15:58 -0500, Deepak Bhole wrote: > > A new directory, $ROOT/tests/netx will be created, and it will house > > unit tests, application tests (for applications we created) and a list > > of 3rd party jnlp applications that we will attempt to tie in for some > > sort of automatic testing. > > > > Comments? Suggestions? > > Could you make it so that the unit tests are run on a make check? > And that they produce some easily parseble format (PASS/FAIL)? > Then the new buildbot setup (not announced yet, need to tweak it so it > sends proper emails when things break) should automagically pick it up > and show when tests started failing (it already calls make check, which > currently trivially succeeds). > http://builder.classpath.org/icedtea/buildbot/waterfall?show=icedtea-web-squeeze-x86_64 > Yes, that was Omair's suggestion and I concur. Whatever can be done automatically via make check, will be! Cheers, Deepak > Thanks, > > Mark > From ahughes at redhat.com Tue Jan 18 15:56:03 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Tue, 18 Jan 2011 23:56:03 +0000 Subject: Request to backport 6736649 and 6797139 In-Reply-To: <4D36058E.3080209@redhat.com> References: <4D30CFB1.6050705@redhat.com> <20110117141006.GA13471@rivendell.middle-earth.co.uk> <4D3454D9.7040200@redhat.com> <20110117170055.GD13471@rivendell.middle-earth.co.uk> <4D348843.2060602@redhat.com> <20110117185548.GJ13471@rivendell.middle-earth.co.uk> <4D349889.80701@redhat.com> <20110117200053.GL13471@rivendell.middle-earth.co.uk> <4D36058E.3080209@redhat.com> Message-ID: <20110118235603.GI14019@rivendell.middle-earth.co.uk> On 16:26 Tue 18 Jan , Omair Majid wrote: > On 01/17/2011 03:00 PM, Dr Andrew John Hughes wrote: > > On 14:29 Mon 17 Jan , Omair Majid wrote: > >> On 01/17/2011 01:55 PM, Dr Andrew John Hughes wrote: > >>> On 13:19 Mon 17 Jan , Omair Majid wrote: > >>>> On 01/17/2011 12:00 PM, Dr Andrew John Hughes wrote: > >>>>> On 09:40 Mon 17 Jan , Omair Majid wrote: > >>>>>> On 01/17/2011 09:10 AM, Dr Andrew John Hughes wrote: > >>>>>>> On 17:35 Fri 14 Jan , Omair Majid wrote: > >>>>>>>> I would like to backport the following two changesets to openjdk6: > >>>>>>>> > >>>>>>>> changeset: 624:e78c2f17a606 > >>>>>>>> user: mlapshin > >>>>>>>> date: Tue Aug 26 12:16:23 2008 +0400 > >>>>>>>> summary: 6736649: > >>>>>>>> test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on > >>>>>>>> Linux > >>>>>>>> > >>>>>>>> changeset: 1637:281fbd82a971 > >>>>>>>> user: alexp > >>>>>>>> date: Wed Sep 02 17:47:19 2009 +0400 > >>>>>>>> summary: 6797139: JButton title is truncating for some strings > >>>>>>>> irrespective of preferred size. > >>>>>>>> > >>>>>>>> Together, these changesets fix a bug where some strings are incorrectly > >>>>>>>> being truncated. > >>>>>>>> > >>>>>>> > >>>>>>> I don't see either of these in IcedTea6. Please add them there first before > >>>>>>> trying to upstream them. > >>>>>>> > >>>>>> > >>>>>> I was going to add them to IcedTea6 as soon as Joe approved them for > >>>>>> openjdk6. Can I assume you are okay with adding it to IcedTea6 without > >>>>>> waiting for Joe's comments? > >>>>> > >>>>> Post the patch and we can make that decision :-) > >>>>> > >>>> > >>>> I have attached the patch for icedtea6. Ok to commit? > >>>> > >>>> Thanks, > >>>> Omair > >>> > >>> The changesets seem to have a lot of whitespace changes, which make it > >>> hard to read, but as these come from the upstream changesets, there's > >>> not much to be done about that. Is it correct that the first adds the > >>> calculation of the right width and then the second removes it? > >>> > >>>> +- textRect.width += getLeftTextExtraWidth() + getRightTextExtraWidth(); > >>>> ++ textRect.width += getLeftTextExtraWidth(); > >>> > >> > >> Yes. Apparently there were some fixes that were performed before OpenJDK > >> was branched; the second patch rolls back some of those changes. From > >> what I can tell, this rollback patch seems quite hackish. But perhaps > >> this is just the complexity of the JDK code. > >> > > > > It's annoying that so much history has not been preserved correctly. > > > > Agreed. The bug reports leave much to be desired as well :( > > >>> I'm a little worried by the addition of an exception: > >>> > >>>> + * Returns the left side bearing of the first character of string. The > >>>> +- * left side bearing is calculated from the passed in FontMetrics. > >>>> ++ * left side bearing is calculated from the passed in > >>>> ++ * FontMetrics. If the passed in String is less than one > >>>> ++ * character, this will throw a StringIndexOutOfBoundsException exception. > >>>> + * > >>>> + * @param c JComponent that will display the string > >>>> + * @param fm FontMetrics used to measure the String width > >>>> +@@ -234,14 +245,11 @@ > >>>> + */ > >>>> + public static int getLeftSideBearing(JComponent c, FontMetrics fm, > >>>> + String string) { > >>>> +- if ((string == null) || (string.length() == 0)) { > >>>> +- return 0; > >>>> +- } > >>>> + return getLeftSideBearing(c, fm, string.charAt(0)); > >>>> + } > >>> > >>> Is this visible further up the stack? > >>> > >> > >> Hm. I missed that. In general yes, it will be visible - > >> sun.swing.SwingUtilities2 is a public class. On the other hand, it is > >> supposed to be an internal class not part of the public API. From the > >> Javadocs: > >> > >> WARNING: While this class is public, it should not be treated as > >> public API and its API may change in incompatable ways between dot dot > >> releases and even patch releases. You should not rely on this class even > >> existing. > >> > >> Perhaps worse than the exception, the patch removes a public method: > >> +- public static int getRightSideBearing(JComponent c, FontMetrics fm, > >> +- String string) { > >> > >> I am starting to have second thoughts about backporting this. > >> > >> On the other hand, I can see (using reflection) that the proprietary JDK > >> 6 does not have getRightSideBearing methods either. > >> > > > > It doesn't matter about changing the API of classes outside those that form part > > of the public documentation (mainly java.* and javax.*.). My concern was that > > this exception would travel up the stack and be thrown from a javax.swing method > > where it wasn't previously. Can you check what calls this method and whether it > > can reach that level? > > > > Pretty much any swing program using JMenus will hit this code and cause > a StringIndexOutOfBoundsException :/ > > > I'm still for backporting as it fixes a bug users have encountered. If necessary, > > we can just drop the changes which allow the exception to be thrown. > > > > Looks like the openjdk7 folks ran into this same problem and fixed it: > > changeset: 1738:9d78c3d9def2 > user: alexp > date: Mon Sep 21 17:58:09 2009 +0400 > summary: 6883341: SWAT: jdk7-b72 swat build(2009-09-17) threw > exceptions when running Java2D demo by clicking Paint ta > > This changeset gets rid of the StringIndexOutOfBoundsException (by > effectively reverting the exception changes). > Ok, so I guess I spotted it quicker than them ;-) Please backport this one as well. > >>> Do the new tests pass? They should be fixed to use the newer Oracle copyright notices. > >>> > >> > >> Sorry, but I forgot to run the tests. I will fix the copyrights, run the > >> tests and post the results. I can confirm that the patch does fix the > >> issue pointed out in the bug report at > >> https://bugzilla.redhat.com/show_bug.cgi?id=661610 > >> > > > > This sounds a good reason to backport. > > > > I'll await the results. > > I can confirm that the new tests pass. However, I also discovered that > swing programs using JMenus crash, so I didnt attempt to run all the tests. > > I will post an updated patch soon. > > Thanks, > Omair -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From bugzilla-daemon at icedtea.classpath.org Wed Jan 19 01:05:45 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 19 Jan 2011 09:05:45 +0000 Subject: [Bug 617] New: Virtual Machine Crashes while using GMOTE Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=617 Summary: Virtual Machine Crashes while using GMOTE Product: VisualVM Harness Version: unspecified Platform: 64-bit OS/Version: Linux Status: NEW Severity: normal Priority: P2 Component: VisualVM AssignedTo: unassigned at icedtea.classpath.org ReportedBy: amatos at gmail.com I installed Gmote on an Android Device and the Gmote server on my computer running Debian Testing. The program is a remote control for Linux using an Android phone. When selecting a video file, this message appears in the console: '# A fatal error has been detected by the Java Runtime Environment:' I hope this helps. The text in the log file can be downloaded from: http://dl.dropbox.com/u/177538/hs_err_pid10210.log as there was a limitation with the size of this message =/ Please let me know if you need more info. Alejandro -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Wed Jan 19 05:53:01 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 19 Jan 2011 13:53:01 +0000 Subject: [Bug 617] Virtual Machine Crashes while using GMOTE Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=617 ------- Comment #1 from dlila at redhat.com 2011-01-19 13:53 ------- Hi. Does the problem happen with any video file, or just the one? -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Wed Jan 19 07:12:40 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 19 Jan 2011 15:12:40 +0000 Subject: [Bug 617] Virtual Machine Crashes while using GMOTE Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=617 ------- Comment #2 from amatos at gmail.com 2011-01-19 15:12 ------- (In reply to comment #1) > Hi. > > Does the problem happen with any video file, or just the one? > with any video that I tried -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Wed Jan 19 08:19:11 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 19 Jan 2011 16:19:11 +0000 Subject: [Bug 617] Virtual Machine Crashes while using GMOTE Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=617 gnu_andrew at member.fsf.org changed: What |Removed |Added ---------------------------------------------------------------------------- Component|VisualVM |IcedTea6 Product|VisualVM Harness |IcedTea ------- Comment #3 from gnu_andrew at member.fsf.org 2011-01-19 16:19 ------- Please file bugs under the correct product (IcedTea) and component where possible. -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Wed Jan 19 08:26:03 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 19 Jan 2011 16:26:03 +0000 Subject: [Bug 617] Virtual Machine Crashes while using GMOTE Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=617 ------- Comment #4 from gnu_andrew at member.fsf.org 2011-01-19 16:26 ------- The file you linked to is coming up as a binary file. Can you please attach it to this bug as a plain text file? Thanks. -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Wed Jan 19 09:57:06 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 19 Jan 2011 17:57:06 +0000 Subject: [Bug 617] Virtual Machine Crashes while using GMOTE Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=617 ------- Comment #5 from amatos at gmail.com 2011-01-19 17:57 ------- Created an attachment (id=450) --> (http://icedtea.classpath.org/bugzilla/attachment.cgi?id=450&action=view) Error Log here is the file -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Wed Jan 19 09:58:12 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Wed, 19 Jan 2011 17:58:12 +0000 Subject: [Bug 617] Virtual Machine Crashes while using GMOTE Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=617 ------- Comment #6 from amatos at gmail.com 2011-01-19 17:58 ------- (In reply to comment #3) > Please file bugs under the correct product (IcedTea) and component where > possible. > Sorry, I thought it was from the virtual machine, didn't realize it was from icedtea. Should I open a new bug and close this one? -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From omajid at redhat.com Wed Jan 19 12:58:01 2011 From: omajid at redhat.com (Omair Majid) Date: Wed, 19 Jan 2011 15:58:01 -0500 Subject: [icedtea-web] RFC: exit with error code on failures Message-ID: <4D375059.4060501@redhat.com> Hi, The attached patch makes netx (and plugin) exit with an error code other than 0 on an error. netx already exits with appropriate error code in some cases (for example, if the input JNLP file is malformed), but not if running the downloaded program fails. Before this patch: $ javaws jnlp.jnlp net.sourceforge.jnlp.LaunchException: Fatal: Launch Error: Could not launch JNLP file. (... more output ...) $ echo $? 0 After this patch: $ javaws jnlp.jnlp net.sourceforge.jnlp.LaunchException: Fatal: Launch Error: Could not launch JNLP file. (... more output ...) $ echo $? 1 Any thoughts or comments? Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: exit-with-error.patch Type: text/x-patch Size: 969 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110119/c7f9db3a/exit-with-error.patch From ahughes at redhat.com Wed Jan 19 13:05:20 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Wed, 19 Jan 2011 21:05:20 +0000 Subject: [icedtea-web] RFC: exit with error code on failures In-Reply-To: <4D375059.4060501@redhat.com> References: <4D375059.4060501@redhat.com> Message-ID: <20110119210520.GB16826@rivendell.middle-earth.co.uk> On 15:58 Wed 19 Jan , Omair Majid wrote: > Hi, > > The attached patch makes netx (and plugin) exit with an error code other > than 0 on an error. netx already exits with appropriate error code in > some cases (for example, if the input JNLP file is malformed), but not > if running the downloaded program fails. > > Before this patch: > > $ javaws jnlp.jnlp > net.sourceforge.jnlp.LaunchException: Fatal: Launch Error: Could not > launch JNLP file. > (... more output ...) > $ echo $? > 0 > > After this patch: > > $ javaws jnlp.jnlp > net.sourceforge.jnlp.LaunchException: Fatal: Launch Error: Could not > launch JNLP file. > (... more output ...) > $ echo $? > 1 > > Any thoughts or comments? > > Cheers, > Omair Sounds good to me. > diff -r 4e84e06b54e9 netx/net/sourceforge/jnlp/Launcher.java > --- a/netx/net/sourceforge/jnlp/Launcher.java Wed Jan 12 12:50:13 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/Launcher.java Wed Jan 19 15:41:17 2011 -0500 > @@ -834,7 +834,7 @@ > exception = ex; > // Exit if we can't launch the application. > if (exitOnFailure) > - System.exit(0); > + System.exit(1); > } > } > > diff -r 4e84e06b54e9 netx/net/sourceforge/jnlp/NetxPanel.java > --- a/netx/net/sourceforge/jnlp/NetxPanel.java Wed Jan 12 12:50:13 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/NetxPanel.java Wed Jan 19 15:41:17 2011 -0500 > @@ -93,7 +93,7 @@ > // Assume user has indicated he does not trust the > // applet. > if (exitOnFailure) > - System.exit(0); > + System.exit(1); > } > applet = appInst.getApplet(); > -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From dbhole at redhat.com Wed Jan 19 14:24:54 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Wed, 19 Jan 2011 17:24:54 -0500 Subject: RFE: Patch for potential browser crash by the plugin Message-ID: <20110119222453.GB5250@redhat.com> Hi, Attached patch fixes Bug# 619: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=619 ChangeLog: 2011-01-19 Deepak Bhole * plugin/icedteanp/java/netscape/javascript/JSObject.java (finalize): Proceed with finalization only if JSObject is valid. Okay for HEAD, 1.0 and backport to maintained icedtea6 branches? Cheers, Deepak -------------- next part -------------- diff -r bbbe02c58ddc plugin/icedteanp/java/netscape/javascript/JSObject.java --- a/plugin/icedteanp/java/netscape/javascript/JSObject.java Mon Dec 20 13:37:59 2010 -0500 +++ b/plugin/icedteanp/java/netscape/javascript/JSObject.java Wed Dec 22 14:34:58 2010 -0500 @@ -259,6 +259,11 @@ * JavaScript object. */ protected void finalize() { + + // Proceed if this is a valid object (0L == default long == invalid) + if (internal == 0L) + return; + PluginDebug.debug("JSObject.finalize "); PluginAppletViewer.JavaScriptFinalize(internal); } From ahughes at redhat.com Wed Jan 19 16:16:13 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Thu, 20 Jan 2011 00:16:13 +0000 Subject: RFE: Patch for potential browser crash by the plugin In-Reply-To: <20110119222453.GB5250@redhat.com> References: <20110119222453.GB5250@redhat.com> Message-ID: <20110120001613.GC16826@rivendell.middle-earth.co.uk> On 17:24 Wed 19 Jan , Deepak Bhole wrote: > Hi, > > Attached patch fixes Bug# 619: > http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=619 > > ChangeLog: > 2011-01-19 Deepak Bhole > > * plugin/icedteanp/java/netscape/javascript/JSObject.java (finalize): > Proceed with finalization only if JSObject is valid. > > > Okay for HEAD, 1.0 and backport to maintained icedtea6 branches? > > Cheers, > Deepak Assuming you mean IcedTea-Web HEAD, then yes fine for all (including 1.7, 1.8 and 1.9 branches). Please make sure to document the fix in NEWS. > diff -r bbbe02c58ddc plugin/icedteanp/java/netscape/javascript/JSObject.java > --- a/plugin/icedteanp/java/netscape/javascript/JSObject.java Mon Dec 20 13:37:59 2010 -0500 > +++ b/plugin/icedteanp/java/netscape/javascript/JSObject.java Wed Dec 22 14:34:58 2010 -0500 > @@ -259,6 +259,11 @@ > * JavaScript object. > */ > protected void finalize() { > + > + // Proceed if this is a valid object (0L == default long == invalid) > + if (internal == 0L) > + return; > + > PluginDebug.debug("JSObject.finalize "); > PluginAppletViewer.JavaScriptFinalize(internal); > } -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From dj at lucasit.com Wed Jan 19 17:31:57 2011 From: dj at lucasit.com (DJ Lucas) Date: Wed, 19 Jan 2011 19:31:57 -0600 Subject: Cacerts generation patch for IcedTea6 HEAD In-Reply-To: <4D108AD5.4010809@redhat.com> References: <4D108AD5.4010809@redhat.com> Message-ID: <4D37908D.1020900@lucasit.com> On 12/21/2010 05:09 AM, Pavel Tisnovsky wrote: > Hi all, > > I've created patch for cacerts generation prepared for IcedTea6 HEAD. > This patch is heavily based on DJ Lucas's patch (thank you very much!) > but I had to apply three changes: > > 1) I had to change the lines where the patch is applied to Makefile.am > due to several changes in this file (it's understandable as the original > patch is quite old and it's been prepared for older IcedTea version) > > 1) DEBUG_BUILD_OUTPUT_DIR macro is used instead of BUILD_OUTPUT_DIR when > cacerts are about to be generated for debug build of IcedTea6 (already > approved by DJ Lucas) > > 2) I also changed the decision logic which determinates whether the > certificates have to be generated from one .crt file or from an existing > list of .pem files. This ensures correct work in case when only file > containing certificates is installed (this is RHEL 5 and RHEL 6 case: > /etc/ssl/certs/ca-bundle.crt) > > > > I also tried to run JTReg against unpatched and patched IcedTea6. Here > is diff: > > +FAILED: lib/security/cacerts/VerifyCACerts.java > +FAILED: sun/security/rsa/TestCACerts.java > > I realize it has been a while, but on a fresh build of IcedTea6-1.9.3 on a pure x86_64 machine, with the proposed patch applied (offsets and ac*# corrected), I do not see these additional test failures. I have others to look into, but those aren't related (likely due to me playing on the bleeding edge). I'll begin a build on x86 momentarily, and then start back on head when I can. Also, what is the content of the cert with 95750816 hash? Is it expired or otherwise untrusted? I do not have this certificate in my chain. I'm using only Mozilla certdata.txt as the source for my distro CAs as any additional trusted certificates are left for the users' responsibility in my case. If maybe you can point me to the certificate package you were using, I could take a peek at it myself as well. There are other options here too, like including a minimal one as is done with the proprietary JDK, distributing a fully populated one with an option to override it (though I think most will probably cringe at the idea of defining a default security policy), or throwing a warning in configure if a pre-populated cacerts file is not provided/found. A simple AC warning might even be enough. However, even with those other options in play, I'm still more partial to providing the _option_ to generate one on the fly using the already trusted certificates from the build machine. The big thing I wanted to see is that Joe or Jane User aren't left completely in the dark when they go to build their own copy of IcedTea and the security tests are failing. -- DJ -- This message has been scanned for viruses and dangerous content, and is believed to be clean. From ahughes at redhat.com Thu Jan 20 06:50:21 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Thu, 20 Jan 2011 14:50:21 +0000 Subject: Reviewer needed - simple changes in regression test InternationalFontsRendering In-Reply-To: <4D35C71A.3090605@redhat.com> References: <4D35C71A.3090605@redhat.com> Message-ID: <20110120145021.GA4611@rivendell.middle-earth.co.uk> On 18:00 Tue 18 Jan , Pavel Tisnovsky wrote: > Hi all, > > could anybody please review two simple changes in regression test > InternationalFontsRendering.java which is included in IcedTea6 as patch > icedtea-jtreg-international-fonts.patch? > > 1st change: added missing copyright info (this test was created by me > last year hence I used 2010 in (c)) > 2nd change: string which contained UTF-8 characters were translated > using native2ascii to use Unicode escape notation > > Thank you in advance > Pavel > Changes look good. Approved. > > Here is hg diff generated against recent IcedTea6 version: > > > diff -r 477489da7897 ChangeLog > --- a/ChangeLog Tue Jan 18 16:45:33 2011 +0100 > +++ b/ChangeLog Tue Jan 18 17:50:18 2011 +0100 > @@ -1,3 +1,10 @@ > +2011-01-18 Pavel Tisnovsky > + > + * patches/icedtea-jtreg-international-fonts.patch: > + Added copyright info and translated string originally encoded > + in UTF-8 into string using Unicode escape notation in > + regression test InternationalFontsRendering.java > + > 2011-01-18 Pavel Tisnovsky > > * Makefile.am: Apply patch. > diff -r 477489da7897 patches/icedtea-jtreg-international-fonts.patch > --- a/patches/icedtea-jtreg-international-fonts.patch Tue Jan 18 > 16:45:33 2011 +0100 > +++ b/patches/icedtea-jtreg-international-fonts.patch Tue Jan 18 > 17:50:18 2011 +0100 > @@ -1,6 +1,25 @@ > ---- /dev/null 2010-06-29 14:56:30.329576932 +0200 > -+++ > openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsRendering.java > 2010-11-01 11:27:46.000000000 +0100 > -@@ -0,0 +1,192 @@ > +--- /dev/null 2010-06-29 11:10:08.737208357 +0200 > ++++ > openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsRendering.java > 2011-01-17 17:06:44.000000000 +0100 > +@@ -0,0 +1,211 @@ > ++/* > ++ * Copyright 2010 Red Hat, Inc. All Rights Reserved. > ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. > ++ * > ++ * This code is free software; you can redistribute it and/or modify it > ++ * under the terms of the GNU General Public License version 2 only, as > ++ * published by the Free Software Foundation. > ++ * > ++ * This code is distributed in the hope that it will be useful, but > WITHOUT > ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or > ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License > ++ * version 2 for more details (a copy is included in the LICENSE file that > ++ * accompanied this code). > ++ * > ++ * You should have received a copy of the GNU General Public License > version > ++ * 2 along with this work; if not, write to the Free Software Foundation, > ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. > ++ */ > ++ > +import java.awt.Color; > +import java.awt.Font; > +import java.awt.Graphics2D; > @@ -51,13 +70,13 @@ > + > + private static final String[][] testedStrings = { > + {"Latin-1", "abcdefABCDEF"}, > -+ {"Latin-2", "?????????????"}, > -+ {"Cyrilic", "?????????"}, > -+ {"Greek", "????????????????"}, > -+ {"Asia-Test1", "?????"}, > -+ {"Asia-Test2", "??????"}, > -+ {"Asia-Test3", "?????"}, > -+ {"Asia-Test4", "?????"}, > ++ {"Latin-2", > "\u011b\u0161\u010d\u0159\u017e\u00fd\u00e1\u00ed\u00e9\u00fa\u016f\u013e\u0148"}, > ++ {"Cyrilic", > "\u0414\u0417\u0418\u0472\u0424\u0425\u0470\u0460\u0426"}, > ++ {"Greek", > "\u03b2\u03be\u03b3\u03b4\u03c0\u03b5\u03c1\u03b6\u03a3\u03c3\u03c2\u03b7\u03c4\u03b8\u03c5\u03a9"}, > ++ {"Asia-Test1", "\u4f53\u4e2d\u6587\u7b26\u53f7"}, > ++ {"Asia-Test2", "\u7e41\u9ad4\u4e2d\u6587\u7b26\u865f"}, > ++ {"Asia-Test3", "\u65e5\u672c\u306e\u8c61\u5fb4"}, > ++ {"Asia-Test4", "\ud55c\uad6d\uc5b4\uae30\ud638"}, > + }; > + > + /** -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Thu Jan 20 07:00:55 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Thu, 20 Jan 2011 15:00:55 +0000 Subject: [RFC][IcedTea-Web]: Removing dead unused commented code In-Reply-To: <20110113233124.GP4081@rivendell.middle-earth.co.uk> References: <1765352810.5658.1294952590109.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <724777475.7604.1294960753067.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <20110113233124.GP4081@rivendell.middle-earth.co.uk> Message-ID: <20110120150055.GB4611@rivendell.middle-earth.co.uk> On 23:31 Thu 13 Jan , Dr Andrew John Hughes wrote: > On 18:19 Thu 13 Jan , Andrew Su wrote: > > Hello, > > > > This patch is an attempt to remove dead, unused or commented code from the plugin directory in icedtea-web. > > > > (I have provided the patch for each file separately for easier reading.) > > > > Some comments though.. > > General Note: > > Changed the copyright to be 2011 for all the modified files. > > > > The copyright updates should extend the range, not remove the original. > So: > > > - Copyright (C) 2008 Red Hat > > + Copyright (C) 2011 Red Hat > > becomes > > - Copyright (C) 2008 Red Hat > + Copyright (C) 2008, 2011 Red Hat > > Also I'm not sure removing code is worth a copyright update. > > > These are the methods that will be removed with the patch (unused private methods) > > PluginMessageConsumer.java:getReference(String[]) > > PluginMessageConsumer.java:isInInit(Integer) > > PluginMessageConsumer.java:dumpWorkerStatus() > > PluginAppletViewer.java:makeReader(InputStream) > > PluginMessageConsumer.java:getReference(String[]) > > PluginMessageConsumer.java:isInInit(Integer) > > PluginMessageConsumer.java:dumpWorkerStatus() > > > > In the following method, will we be needing this block of commented out conditions in the future? > > PluginAppletSecurityContext.java:getAccessControlContext(String[], String) > > > > > > I have tried building it and that succeeds. Tested running some simple applets and those seem to work as well. > > > > Questions comments concerns? > > > > Regards, > > Andrew > > The copyright doesn't need updating for these modifications (as they only remove code), but the files probably do need a general update so that the year of latest modification is used. Please do this as a separate patch. I approve the removal of dead code without the copyright changes. > > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/GetWindowPluginCallRequest.java > > --- a/plugin/icedteanp/java/sun/applet/GetWindowPluginCallRequest.java Wed Jan 12 12:50:13 2011 -0500 > > +++ b/plugin/icedteanp/java/sun/applet/GetWindowPluginCallRequest.java Thu Jan 13 18:02:32 2011 -0500 > > @@ -1,5 +1,5 @@ > > /* GetWindowPluginCallRequest -- represent Java-to-JavaScript requests > > - Copyright (C) 2008 Red Hat > > + Copyright (C) 2011 Red Hat > > > > This file is part of IcedTea. > > > > @@ -37,9 +37,6 @@ > > > > package sun.applet; > > > > -import java.security.AccessControlContext; > > -import java.security.ProtectionDomain; > > - > > public class GetWindowPluginCallRequest extends PluginCallRequest { > > // FIXME: look into int vs long JavaScript internal values. > > long internal; > > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/MethodOverloadResolver.java > > --- a/plugin/icedteanp/java/sun/applet/MethodOverloadResolver.java Wed Jan 12 12:50:13 2011 -0500 > > +++ b/plugin/icedteanp/java/sun/applet/MethodOverloadResolver.java Thu Jan 13 18:02:32 2011 -0500 > > @@ -1,5 +1,5 @@ > > /* MethodOverloadResolver -- Resolves overloaded methods > > - Copyright (C) 2009 Red Hat > > + Copyright (C) 2011 Red Hat > > > > This file is part of IcedTea. > > > > @@ -175,8 +175,6 @@ > > > > int lowestCost = Integer.MAX_VALUE; > > > > - ArrayList paramList = new ArrayList(); > > - > > for (Method matchingMethod : matchingMethods) { > > > > int methodCost = 0; > > @@ -240,8 +238,6 @@ > > > > int lowestCost = Integer.MAX_VALUE; > > > > - ArrayList paramList = new ArrayList(); > > - > > for (Constructor matchingConstructor : matchingConstructors) { > > > > int constructorCost = 0; > > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginAppletSecurityContext.java > > --- a/plugin/icedteanp/java/sun/applet/PluginAppletSecurityContext.java Wed Jan 12 12:50:13 2011 -0500 > > +++ b/plugin/icedteanp/java/sun/applet/PluginAppletSecurityContext.java Thu Jan 13 18:02:32 2011 -0500 > > @@ -1,5 +1,5 @@ > > /* PluginAppletSecurityContext -- execute plugin JNI messages > > - Copyright (C) 2008, 2010 Red Hat > > + Copyright (C) 2008, 2010, 2011 Red Hat > > > > This file is part of IcedTea. > > > > @@ -37,7 +37,6 @@ > > > > package sun.applet; > > > > -import java.io.File; > > import java.lang.reflect.Array; > > import java.lang.reflect.Constructor; > > import java.lang.reflect.Field; > > @@ -53,14 +52,11 @@ > > import java.security.Permissions; > > import java.security.PrivilegedAction; > > import java.security.ProtectionDomain; > > -import java.text.DecimalFormat; > > import java.util.ArrayList; > > import java.util.Hashtable; > > import java.util.List; > > import java.util.Map; > > > > -import javax.swing.text.html.HTMLDocument.HTMLReader.IsindexAction; > > - > > import net.sourceforge.jnlp.runtime.JNLPRuntime; > > import netscape.javascript.JSObjectCreatePermission; > > > > @@ -144,32 +140,25 @@ > > if (elem == null) // end of signature > > continue; > > > > - // System.out.println ("NEXT TYPE: " + elem); > > Class primitive = primitiveNameToType(elem); > > if (primitive != null) > > typeList.add(primitive); > > else { > > - // System.out.println ("HERE1"); > > int dimsize = 0; > > int n = elem.indexOf('['); > > if (n != -1) { > > - // System.out.println ("HERE2"); > > String arrayType = elem.substring(0, n); > > dimsize++; > > n = elem.indexOf('[', n + 1); > > - // System.out.println ("HERE2.5"); > > while (n != -1) { > > dimsize++; > > n = elem.indexOf('[', n + 1); > > - // System.out.println ("HERE2.8"); > > } > > int[] dims = new int[dimsize]; > > primitive = primitiveNameToType(arrayType); > > - // System.out.println ("HERE3"); > > if (primitive != null) { > > typeList.add(Array.newInstance(primitive, dims) > > .getClass()); > > - // System.out.println ("HERE4"); > > } else > > typeList.add(Array.newInstance( > > getClass(arrayType, cl), dims).getClass()); > > @@ -557,11 +546,6 @@ > > // Cast the object to appropriate type before insertion > > value = MethodOverloadResolver.getCostAndCastedObject(value, store.getObject(arrayID).getClass().getComponentType())[1]; > > > > - //if (value == null && > > - // store.getObject(arrayID).getClass().getComponentType().isPrimitive()) { > > - // value = 0; > > - //} > > - > > Array.set(store.getObject(arrayID), index, value); > > > > write(reference, "SetObjectArrayElement"); > > @@ -569,13 +553,10 @@ > > String[] args = message.split(" "); > > Integer arrayID = parseCall(args[1], null, Integer.class); > > > > - //System.out.println("ARRAYID: " + arrayID); > > Object o = store.getObject(arrayID); > > int len = 0; > > len = Array.getLength(o); > > - // System.out.println ("Returning array length: " + len); > > > > - // System.out.println ("array length: " + o + " " + len); > > write(reference, "GetArrayLength " + Array.getLength(o)); > > } else if (message.startsWith("GetField")) { > > String[] args = message.split(" "); > > @@ -624,10 +605,7 @@ > > } else if (message.startsWith("GetObjectClass")) { > > int oid = Integer.parseInt(message.substring("GetObjectClass" > > .length() + 1)); > > - // System.out.println ("GETTING CLASS FOR: " + oid); > > Class c = store.getObject(oid).getClass(); > > - // System.out.println (" OBJ: " + store.getObject(oid)); > > - // System.out.println (" CLS: " + c); > > store.reference(c); > > > > write(reference, "GetObjectClass " + store.getIdentifier(c)); > > @@ -773,8 +751,6 @@ > > byte[] b = null; > > o = (String) store.getObject(stringID); > > b = o.getBytes("UTF-8"); > > - // System.out.println ("STRING UTF-8 LENGTH: " + o + " " + > > - // b.length); > > > > write(reference, "GetStringUTFLength " + o.length()); > > } else if (message.startsWith("GetStringLength")) { > > @@ -785,10 +761,7 @@ > > byte[] b = null; > > o = (String) store.getObject(stringID); > > b = o.getBytes("UTF-16LE"); > > - // System.out.println ("STRING UTF-16 LENGTH: " + o + " " + > > - // b.length); > > > > - // System.out.println ("Java: GetStringLength " + b.length); > > write(reference, "GetStringLength " + o.length()); > > } else if (message.startsWith("GetStringUTFChars")) { > > String[] args = message.split(" "); > > @@ -807,8 +780,6 @@ > > + Integer > > .toString(((int) b[i]) & 0x0ff, 16)); > > > > - // System.out.println ("Java: GetStringUTFChars: " + o); > > - // //System.out.println ("String UTF BYTES: " + buf); > > write(reference, "GetStringUTFChars " + buf); > > } else if (message.startsWith("GetStringChars")) { > > String[] args = message.split(" "); > > @@ -854,10 +825,6 @@ > > String type = parseCall(args[1], null, String.class); > > Integer length = parseCall(args[2], null, Integer.class); > > > > - // System.out.println ("CALLING: NewArray: " + type + " " + > > - // length + " " > > - // + Signature.primitiveNameToType(type)); > > - > > Object newArray = null; > > > > Class c; > > @@ -939,10 +906,6 @@ > > Integer classID = parseCall(args[2], null, Integer.class); > > Integer objectID = parseCall(args[3], null, Integer.class); > > > > - // System.out.println ("CALLING: NewObjectArray: " + > > - // classID + " " + length + " " > > - // + objectID); > > - > > Object newArray = null; > > newArray = Array.newInstance((Class) store.getObject(classID), > > length); > > @@ -962,12 +925,9 @@ > > final Constructor m = (Constructor) store.getObject(methodID); > > Class[] argTypes = m.getParameterTypes(); > > > > - // System.out.println ("NEWOBJ: HERE1"); > > Object[] arguments = new Object[argTypes.length]; > > - // System.out.println ("NEWOBJ: HERE2"); > > for (int i = 0; i < argTypes.length; i++) { > > arguments[i] = parseArgs(args[3 + i], argTypes[i]); > > - // System.out.println ("NEWOBJ: GOT ARG: " + arguments[i]); > > } > > > > final Object[] fArguments = arguments; > > @@ -1090,9 +1050,6 @@ > > ret = new String(byteArray, 0, bytelength, "UTF-16LE"); > > PluginDebug.debug("NEWSTRING: " + ret); > > > > - // System.out.println ("NEWOBJ: CALLED: " + ret); > > - // System.out.println ("NEWOBJ: CALLED: " + > > - // store.getObject(ret)); > > store.reference(ret); > > write(reference, "NewString " + store.getIdentifier(ret)); > > > > @@ -1336,106 +1293,6 @@ > > > > public AccessControlContext getAccessControlContext(String[] nsPrivilegeList, String src) { > > > > - /* > > - for (int i=0; i < nsPrivilegeList.length; i++) { > > - String privilege = nsPrivilegeList[i]; > > - > > - if (privilege.equals("UniversalAccept")) { > > - SocketPermission sp = new SocketPermission("*", "accept,resolve"); > > - grantedPermissions.add(sp); > > - } else if (privilege.equals("UniversalAwtEventQueueAccess")) { > > - AWTPermission awtp = new AWTPermission("accessEventQueue"); > > - grantedPermissions.add(awtp); > > - } else if (privilege.equals("UniversalConnect")) { > > - SocketPermission sp = new SocketPermission("*", "connect,resolve"); > > - grantedPermissions.add(sp); > > - } else if (privilege.equals("UniversalListen")) { > > - SocketPermission sp = new SocketPermission("*", "listen,resolve"); > > - grantedPermissions.add(sp); > > - } else if (privilege.equals("UniversalExecAccess")) { > > - FilePermission fp = new FilePermission("<>", "execute"); > > - RuntimePermission rtp = new RuntimePermission("setIO"); > > - grantedPermissions.add(fp); > > - grantedPermissions.add(rtp); > > - } else if (privilege.equals("UniversalExitAccess")) { > > - // Doesn't matter what the permissions are. Do not allow VM to exit.. we > > - // use a single VM for the entire browser lifecycle once invoked, we > > - // cannot let it exit > > - > > - //RuntimePermission rtp = new RuntimePermission("exitVM.*"); > > - //grantedPermissions.add(rtp); > > - } else if (privilege.equals("UniversalFileDelete")) { > > - FilePermission fp = new FilePermission("<>", "delete"); > > - grantedPermissions.add(fp); > > - } else if (privilege.equals("UniversalFileRead")) { > > - FilePermission fp = new FilePermission("<>", "read"); > > - grantedPermissions.add(fp); > > - } else if (privilege.equals("UniversalFileWrite")) { > > - FilePermission fp = new FilePermission("<>", "write"); > > - grantedPermissions.add(fp); > > - } else if (privilege.equals("UniversalFdRead")) { > > - RuntimePermission rtp = new RuntimePermission("readFileDescriptor"); > > - grantedPermissions.add(rtp); > > - } else if (privilege.equals("UniversalFdWrite")) { > > - RuntimePermission rtp = new RuntimePermission("writeFileDescriptor"); > > - grantedPermissions.add(rtp); > > - } else if (privilege.equals("UniversalLinkAccess")) { > > - RuntimePermission rtp = new RuntimePermission("loadLibrary.*"); > > - grantedPermissions.add(rtp); > > - } else if (privilege.equals("UniversalListen")) { > > - SocketPermission sp = new SocketPermission("*", "listen"); > > - grantedPermissions.add(sp); > > - } else if (privilege.equals("UniversalMulticast")) { > > - SocketPermission sp = new SocketPermission("*", "accept,connect,resolve"); > > - grantedPermissions.add(sp); > > - } else if (privilege.equals("UniversalPackageAccess")) { > > - RuntimePermission rtp = new RuntimePermission("defineClassInPackage.*"); > > - grantedPermissions.add(rtp); > > - } else if (privilege.equals("UniversalPackageDefinition")) { > > - RuntimePermission rtp = new RuntimePermission("accessClassInPackage.*"); > > - grantedPermissions.add(rtp); > > - } else if (privilege.equals("UniversalPrintJobAccess")) { > > - RuntimePermission rtp = new RuntimePermission("queuePrintJob"); > > - grantedPermissions.add(rtp); > > - } else if (privilege.equals("UniversalPropertyRead")) { > > - PropertyPermission pp = new PropertyPermission("*", "read"); > > - grantedPermissions.add(pp); > > - } else if (privilege.equals("UniversalPropertyWrite")) { > > - PropertyPermission pp = new PropertyPermission("*", "write"); > > - grantedPermissions.add(pp); > > - } else if (privilege.equals("UniversalSetFactory")) { > > - RuntimePermission rtp = new RuntimePermission("setFactory"); > > - grantedPermissions.add(rtp); > > - } else if (privilege.equals("UniversalSystemClipboardAccess")) { > > - AWTPermission awtp = new AWTPermission("accessClipboard"); > > - grantedPermissions.add(awtp); > > - } else if (privilege.equals("UniversalThreadAccess")) { > > - RuntimePermission rtp1 = new RuntimePermission("modifyThread"); > > - RuntimePermission rtp2 = new RuntimePermission("stopThread"); > > - grantedPermissions.add(rtp1); > > - grantedPermissions.add(rtp2); > > - } else if (privilege.equals("UniversalThreadGroupAccess")) { > > - RuntimePermission rtp1 = new RuntimePermission("modifyThreadGroup"); > > - RuntimePermission rtp2 = new RuntimePermission("modifyThread"); > > - RuntimePermission rtp3 = new RuntimePermission("stopThread"); > > - grantedPermissions.add(rtp1); > > - grantedPermissions.add(rtp2); > > - grantedPermissions.add(rtp3); > > - } else if (privilege.equals("UniversalTopLevelWindow")) { > > - AWTPermission awtp = new AWTPermission("topLevelWindow"); > > - grantedPermissions.add(awtp); > > - } else if (privilege.equals("UniversalBrowserRead")) { > > - BrowserReadPermission bp = new BrowserReadPermission(); > > - grantedPermissions.add(bp); > > - } else if (privilege.equals("UniversalJavaPermissions")) { > > - AllPermission ap = new AllPermission(); > > - grantedPermissions.add(ap); > > - } > > - } > > - > > - // what to do with these is unknown: UniversalConnectWithRedirect, UniversalDialogModality, UniversalSendMail, LimitedInstall, FullInstall, SilentInstall > > - */ > > - > > Permissions grantedPermissions = new Permissions(); > > > > for (int i = 0; i < nsPrivilegeList.length; i++) { > > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginAppletViewer.java > > --- a/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java Wed Jan 12 12:50:13 2011 -0500 > > +++ b/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java Thu Jan 13 18:02:32 2011 -0500 > > @@ -836,7 +836,6 @@ > > } > > > > private Image getCachedImage(URL url) { > > - // System.getSecurityManager().checkConnection(url.getHost(), url.getPort()); > > return (Image) getCachedImageRef(url).get(); > > } > > > > @@ -1825,18 +1824,6 @@ > > > > static String encoding = null; > > > > - static private Reader makeReader(InputStream is) { > > - if (encoding != null) { > > - try { > > - return new BufferedReader(new InputStreamReader(is, encoding)); > > - } catch (IOException x) { > > - } > > - } > > - InputStreamReader r = new InputStreamReader(is); > > - encoding = r.getEncoding(); > > - return new BufferedReader(r); > > - } > > - > > /** > > * Scan an html file for tags > > */ > > @@ -1869,10 +1856,7 @@ > > PrintStream statusMsgStream, > > PluginAppletPanelFactory factory) > > throws IOException { > > - // tag flags > > - boolean isAppletTag = false; > > boolean isObjectTag = false; > > - boolean isEmbedTag = false; > > boolean objectTagAlreadyParsed = false; > > > > // The current character > > @@ -1948,9 +1932,7 @@ > > } > > } > > atts = null; > > - isAppletTag = false; > > isObjectTag = false; > > - isEmbedTag = false; > > } > > } else { > > String nm = scanIdentifier(c, in); > > @@ -1967,15 +1949,12 @@ > > String val = t.get("value"); > > if (val == null) { > > statusMsgStream.println(requiresNameWarning); > > - } else if (atts != null) { > > + } else { > > PluginDebug.debug("PUT " + att + " = " + val); > > atts.put(att.toLowerCase(), val); > > - } else { > > - statusMsgStream.println(paramOutsideWarning); > > } > > } > > } else if (nm.equalsIgnoreCase("applet")) { > > - isAppletTag = true; > > atts = scanTag(c, in); > > > > // If there is a classid and no code tag present, transform it to code tag > > @@ -2055,7 +2034,6 @@ > > atts.put("height", height); > > } > > } else if (nm.equalsIgnoreCase("embed")) { > > - isEmbedTag = true; > > atts = scanTag(c, in); > > > > // If there is a classid and no code tag present, transform it to code tag > > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginCallRequest.java > > --- a/plugin/icedteanp/java/sun/applet/PluginCallRequest.java Wed Jan 12 12:50:13 2011 -0500 > > +++ b/plugin/icedteanp/java/sun/applet/PluginCallRequest.java Thu Jan 13 18:02:32 2011 -0500 > > @@ -1,5 +1,5 @@ > > /* PluginCallRequest -- represent Java-to-JavaScript requests > > - Copyright (C) 2008 Red Hat > > + Copyright (C) 2011 Red Hat > > > > This file is part of IcedTea. > > > > @@ -37,9 +37,6 @@ > > > > package sun.applet; > > > > -import java.security.AccessControlContext; > > -import java.security.ProtectionDomain; > > - > > // FIXME: for each type of request extend a new (anonymous?) > > // PluginCallRequest. > > public abstract class PluginCallRequest { > > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginDebug.java > > --- a/plugin/icedteanp/java/sun/applet/PluginDebug.java Wed Jan 12 12:50:13 2011 -0500 > > +++ b/plugin/icedteanp/java/sun/applet/PluginDebug.java Thu Jan 13 18:02:32 2011 -0500 > > @@ -1,5 +1,5 @@ > > /* VoidPluginCallRequest -- represent Java-to-JavaScript requests > > - Copyright (C) 2008 Red Hat > > + Copyright (C) 2011 Red Hat > > > > This file is part of IcedTea. > > > > @@ -37,8 +37,6 @@ > > > > package sun.applet; > > > > -import java.io.*; > > - > > public class PluginDebug { > > > > static final boolean DEBUG = System.getenv().containsKey("ICEDTEAPLUGIN_DEBUG"); > > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginMessageConsumer.java > > --- a/plugin/icedteanp/java/sun/applet/PluginMessageConsumer.java Wed Jan 12 12:50:13 2011 -0500 > > +++ b/plugin/icedteanp/java/sun/applet/PluginMessageConsumer.java Thu Jan 13 18:02:32 2011 -0500 > > @@ -1,5 +1,5 @@ > > /* VoidPluginCallRequest -- represent Java-to-JavaScript requests > > - Copyright (C) 2008 Red Hat > > + Copyright (C) 2011 Red Hat > > > > This file is part of IcedTea. > > > > @@ -41,7 +41,6 @@ > > import java.util.Hashtable; > > import java.util.Iterator; > > import java.util.LinkedList; > > -import java.util.Set; > > > > class PluginMessageConsumer { > > > > @@ -107,17 +106,6 @@ > > } > > } > > > > - /** > > - * Returns the reference for this message. This method assumes that > > - * the message has a reference number. > > - * > > - * @param The message > > - * @return the reference number > > - */ > > - private Long getReference(String[] msgParts) { > > - return Long.parseLong(msgParts[3]); > > - } > > - > > public PluginMessageConsumer(PluginStreamHandler streamHandler) { > > > > as = new AppletSecurity(); > > @@ -144,10 +132,6 @@ > > return null; > > } > > > > - private boolean isInInit(Integer instanceNum) { > > - return initWorkers.containsKey(instanceNum); > > - } > > - > > private void addToInitWorkers(Integer instanceNum, PluginMessageHandlerWorker worker) { > > synchronized (initWorkers) { > > initWorkers.put(instanceNum, worker); > > @@ -291,10 +275,4 @@ > > // No workers available. Better luck next time! > > return null; > > } > > - > > - private void dumpWorkerStatus() { > > - for (PluginMessageHandlerWorker worker : workers) { > > - PluginDebug.debug(worker.toString()); > > - } > > - } > > } > > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginMessageHandlerWorker.java > > --- a/plugin/icedteanp/java/sun/applet/PluginMessageHandlerWorker.java Wed Jan 12 12:50:13 2011 -0500 > > +++ b/plugin/icedteanp/java/sun/applet/PluginMessageHandlerWorker.java Thu Jan 13 18:02:32 2011 -0500 > > @@ -1,5 +1,5 @@ > > /* VoidPluginCallRequest -- represent Java-to-JavaScript requests > > - Copyright (C) 2008 Red Hat > > + Copyright (C) 2011 Red Hat > > > > This file is part of IcedTea. > > > > @@ -43,7 +43,6 @@ > > private boolean isPriorityWorker = false; > > private int id; > > private String message = null; > > - private SecurityManager sm; > > PluginStreamHandler streamHandler = null; > > PluginMessageConsumer consumer = null; > > > > @@ -54,7 +53,6 @@ > > > > this.id = id; > > this.streamHandler = streamHandler; > > - this.sm = sm; > > this.isPriorityWorker = isPriorityWorker; > > this.consumer = consumer; > > > > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginObjectStore.java > > --- a/plugin/icedteanp/java/sun/applet/PluginObjectStore.java Wed Jan 12 12:50:13 2011 -0500 > > +++ b/plugin/icedteanp/java/sun/applet/PluginObjectStore.java Thu Jan 13 18:02:32 2011 -0500 > > @@ -1,5 +1,5 @@ > > /* PluginObjectStore -- manage identifier-to-object mapping > > - Copyright (C) 2008 Red Hat > > + Copyright (C) 2011 Red Hat > > > > This file is part of IcedTea. > > > > @@ -38,8 +38,6 @@ > > package sun.applet; > > > > import java.util.*; > > -import java.lang.reflect.*; > > -import java.io.*; > > > > public class PluginObjectStore { > > private static HashMap objects = new HashMap(); > > @@ -87,36 +85,24 @@ > > objects.put(nextUniqueIdentifier, object); > > counts.put(nextUniqueIdentifier, 1); > > identifiers.put(object, nextUniqueIdentifier); > > - //System.out.println("JAVA ADDED: " + nextUniqueIdentifier); > > - //System.out.println("JAVA REFERENCED: " + nextUniqueIdentifier > > - // + " to: 1"); > > nextUniqueIdentifier++; > > } else { > > counts.put(identifier, counts.get(identifier) + 1); > > - //System.out.println("JAVA REFERENCED: " + identifier + > > - // " to: " + counts.get(identifier)); > > } > > } > > > > public void unreference(int identifier) { > > Integer currentCount = counts.get(identifier); > > if (currentCount == null) { > > - //System.out.println("ERROR UNREFERENCING: " + identifier); > > return; > > } > > if (currentCount == 1) { > > - //System.out.println("JAVA DEREFERENCED: " + identifier > > - // + " to: 0"); > > Object object = objects.get(identifier); > > objects.remove(identifier); > > counts.remove(identifier); > > identifiers.remove(object); > > - //System.out.println("JAVA REMOVED: " + identifier); > > } else { > > counts.put(identifier, currentCount - 1); > > - //System.out.println("JAVA DEREFERENCED: " + > > - // identifier + " to: " + > > - // counts.get(identifier)); > > } > > } > > > > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginProxyInfoRequest.java > > --- a/plugin/icedteanp/java/sun/applet/PluginProxyInfoRequest.java Wed Jan 12 12:50:13 2011 -0500 > > +++ b/plugin/icedteanp/java/sun/applet/PluginProxyInfoRequest.java Thu Jan 13 18:02:32 2011 -0500 > > @@ -1,5 +1,5 @@ > > /* PluginProxyInfoRequest -- Object representing a request for proxy information from the browser > > - Copyright (C) 2009 Red Hat > > + Copyright (C) 2011 Red Hat > > > > This file is part of IcedTea. > > > > @@ -37,7 +37,6 @@ > > > > package sun.applet; > > > > -import java.net.MalformedURLException; > > import java.net.URI; > > > > /** > > diff -r 4e84e06b54e9 plugin/icedteanp/java/sun/applet/PluginStreamHandler.java > > --- a/plugin/icedteanp/java/sun/applet/PluginStreamHandler.java Wed Jan 12 12:50:13 2011 -0500 > > +++ b/plugin/icedteanp/java/sun/applet/PluginStreamHandler.java Thu Jan 13 18:02:32 2011 -0500 > > @@ -1,5 +1,5 @@ > > /* VoidPluginCallRequest -- represent Java-to-JavaScript requests > > - Copyright (C) 2008 Red Hat > > + Copyright (C) 2011 Red Hat > > > > This file is part of IcedTea. > > > > @@ -39,13 +39,11 @@ > > > > import java.io.BufferedReader; > > import java.io.BufferedWriter; > > -import java.io.FileWriter; > > import java.io.IOException; > > import java.io.InputStream; > > import java.io.InputStreamReader; > > import java.io.OutputStream; > > import java.io.OutputStreamWriter; > > -import java.io.StreamTokenizer; > > import java.net.MalformedURLException; > > import java.nio.charset.Charset; > > import java.util.Date; > > @@ -56,7 +54,6 @@ > > public class PluginStreamHandler { > > > > private BufferedReader pluginInputReader; > > - private StreamTokenizer pluginInputTokenizer; > > private BufferedWriter pluginOutputWriter; > > > > private RequestQueue queue = new RequestQueue(); > > @@ -70,10 +67,6 @@ > > > > PluginAppletViewer pav; > > > > - static Date d = new Date(); > > - static long startTime = d.getTime(); > > - static long totalWait = 0; > > - > > public PluginStreamHandler(InputStream inputstream, OutputStream outputstream) > > throws MalformedURLException, IOException { > > > > @@ -82,13 +75,10 @@ > > pav = (PluginAppletViewer) ClassLoader.getSystemClassLoader().loadClass("sun.applet.PluginAppletViewer").newInstance(); > > PluginDebug.debug("Loaded: " + pav + " CL=" + pav.getClass().getClassLoader()); > > } catch (InstantiationException e) { > > - // TODO Auto-generated catch block > > e.printStackTrace(); > > } catch (IllegalAccessException e) { > > - // TODO Auto-generated catch block > > e.printStackTrace(); > > } catch (ClassNotFoundException e) { > > - // TODO Auto-generated catch block > > e.printStackTrace(); > > } > > > > @@ -99,23 +89,9 @@ > > pluginInputReader = > > new BufferedReader(new InputStreamReader(inputstream, > > Charset.forName("UTF-8"))); > > - /*pluginInputTokenizer = new StreamTokenizer(pluginInputReader); > > - pluginInputTokenizer.resetSyntax(); > > - pluginInputTokenizer.whitespaceChars('\u0000', '\u0000'); > > - pluginInputTokenizer.wordChars('\u0001', '\u00FF');*/ > > pluginOutputWriter = > > new BufferedWriter(new OutputStreamWriter > > (outputstream, Charset.forName("UTF-8"))); > > - > > - /* > > - while(true) { > > - String message = read(); > > - PluginDebug.debug(message); > > - handleMessage(message); > > - // TODO: > > - // write(queue.peek()); > > - } > > - */ > > } > > > > public void startProcessing() { > > @@ -128,15 +104,8 @@ > > > > PluginDebug.debug("Waiting for data..."); > > > > - long b4 = new Date().getTime(); > > - > > String s = read(); > > > > - long after = new Date().getTime(); > > - > > - totalWait += (after - b4); > > - //System.err.println("Total wait time: " + totalWait); > > - > > if (s != null) { > > consumer.queue(s); > > } else { > > @@ -152,35 +121,6 @@ > > PluginDebug.debug("APPLETVIEWER: exiting appletviewer"); > > System.exit(0); > > } > > - > > - /* > > - int readChar = -1; > > - // blocking read, discard first character > > - try { > > - readChar = pluginInputReader.read(); > > - } catch (IOException ioe) { > > - // plugin may have detached > > - } > > - > > - // if not disconnected > > - if (readChar != -1) { > > - String s = read(); > > - PluginDebug.debug("Got data, consuming " + s); > > - consumer.consume(s); > > - } else { > > - try { > > - // Close input/output channels to plugin. > > - pluginInputReader.close(); > > - pluginOutputWriter.close(); > > - } catch (IOException exception) { > > - // Deliberately ignore IOException caused by broken > > - // pipe since plugin may have already detached. > > - } > > - AppletSecurityContextManager.dumpStore(0); > > - PluginDebug.debug("APPLETVIEWER: exiting appletviewer"); > > - System.exit(0); > > - } > > - */ > > } > > } > > }; > > @@ -411,13 +351,6 @@ > > } > > > > return; > > - /* > > - synchronized(writeQueue) { > > - writeQueue.add(message); > > - PluginDebug.debug(" PIPE: appletviewer wrote: " + message); > > - } > > - */ > > - > > } > > > > public boolean messageAvailable() { > > > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ptisnovs at icedtea.classpath.org Thu Jan 20 07:34:41 2011 From: ptisnovs at icedtea.classpath.org (ptisnovs at icedtea.classpath.org) Date: Thu, 20 Jan 2011 15:34:41 +0000 Subject: /hg/icedtea6: Added copyright info and translated string origina... Message-ID: changeset f3aee1b5e567 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=f3aee1b5e567 author: ptisnovs date: Thu Jan 20 16:33:23 2011 +0100 Added copyright info and translated string originally encoded in UTF-8 into string using Unicode escape notation in regression test InternationalFontsRendering.java diffstat: 2 files changed, 36 insertions(+), 10 deletions(-) ChangeLog | 7 ++++ patches/icedtea-jtreg-international-fonts.patch | 39 +++++++++++++++++------ diffs (67 lines): diff -r 477489da7897 -r f3aee1b5e567 ChangeLog --- a/ChangeLog Tue Jan 18 16:45:33 2011 +0100 +++ b/ChangeLog Thu Jan 20 16:33:23 2011 +0100 @@ -1,3 +1,10 @@ 2011-01-18 Pavel Tisnovsky + + * patches/icedtea-jtreg-international-fonts.patch: + Added copyright info and translated string originally encoded + in UTF-8 into string using Unicode escape notation in + regression test InternationalFontsRendering.java + 2011-01-18 Pavel Tisnovsky * Makefile.am: Apply patch. diff -r 477489da7897 -r f3aee1b5e567 patches/icedtea-jtreg-international-fonts.patch --- a/patches/icedtea-jtreg-international-fonts.patch Tue Jan 18 16:45:33 2011 +0100 +++ b/patches/icedtea-jtreg-international-fonts.patch Thu Jan 20 16:33:23 2011 +0100 @@ -1,6 +1,25 @@ ---- /dev/null 2010-06-29 14:56:30.329576932 +0200 -+++ openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsRendering.java 2010-11-01 11:27:46.000000000 +0100 -@@ -0,0 +1,192 @@ +--- /dev/null 2010-06-29 11:10:08.737208357 +0200 ++++ openjdk/jdk/test/java/awt/font/InternationalFonts/InternationalFontsRendering.java 2011-01-17 17:06:44.000000000 +0100 +@@ -0,0 +1,211 @@ ++/* ++ * Copyright 2010 Red Hat, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ */ ++ +import java.awt.Color; +import java.awt.Font; +import java.awt.Graphics2D; @@ -51,13 +70,13 @@ + + private static final String[][] testedStrings = { + {"Latin-1", "abcdefABCDEF"}, -+ {"Latin-2", "??????????????????????????"}, -+ {"Cyrilic", "??????????????????"}, -+ {"Greek", "????????????????????????????????"}, -+ {"Asia-Test1", "???????????????"}, -+ {"Asia-Test2", "??????????????????"}, -+ {"Asia-Test3", "???????????????"}, -+ {"Asia-Test4", "???????????????"}, ++ {"Latin-2", "\u011b\u0161\u010d\u0159\u017e\u00fd\u00e1\u00ed\u00e9\u00fa\u016f\u013e\u0148"}, ++ {"Cyrilic", "\u0414\u0417\u0418\u0472\u0424\u0425\u0470\u0460\u0426"}, ++ {"Greek", "\u03b2\u03be\u03b3\u03b4\u03c0\u03b5\u03c1\u03b6\u03a3\u03c3\u03c2\u03b7\u03c4\u03b8\u03c5\u03a9"}, ++ {"Asia-Test1", "\u4f53\u4e2d\u6587\u7b26\u53f7"}, ++ {"Asia-Test2", "\u7e41\u9ad4\u4e2d\u6587\u7b26\u865f"}, ++ {"Asia-Test3", "\u65e5\u672c\u306e\u8c61\u5fb4"}, ++ {"Asia-Test4", "\ud55c\uad6d\uc5b4\uae30\ud638"}, + }; + + /** From dbhole at icedtea.classpath.org Thu Jan 20 08:13:02 2011 From: dbhole at icedtea.classpath.org (dbhole at icedtea.classpath.org) Date: Thu, 20 Jan 2011 16:13:02 +0000 Subject: /hg/icedtea-web: Fix PR619: Improper finalization by the plugin ... Message-ID: changeset 06940cdcfef8 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=06940cdcfef8 author: Deepak Bhole date: Thu Jan 20 11:06:41 2011 -0500 Fix PR619: Improper finalization by the plugin can crash the browser diffstat: 3 files changed, 12 insertions(+) ChangeLog | 6 ++++++ NEWS | 1 + plugin/icedteanp/java/netscape/javascript/JSObject.java | 5 +++++ diffs (39 lines): diff -r 925f97c584a8 -r 06940cdcfef8 ChangeLog --- a/ChangeLog Tue Jan 18 12:07:45 2011 -0500 +++ b/ChangeLog Thu Jan 20 11:06:41 2011 -0500 @@ -1,3 +1,9 @@ 2011-01-17 Andrew Su +2011-01-20 Deepak Bhole + + PR619: Improper finalization by the plugin can crash the browser + * plugin/icedteanp/java/netscape/javascript/JSObject.java (finalize): + Proceed with finalization only if JSObject is valid. + 2011-01-17 Andrew Su * netx/net/sourceforge/jnlp/NetxPanel.java: diff -r 925f97c584a8 -r 06940cdcfef8 NEWS --- a/NEWS Tue Jan 18 12:07:45 2011 -0500 +++ b/NEWS Thu Jan 20 11:06:41 2011 -0500 @@ -22,6 +22,7 @@ New in release 1.0 (2010-XX-XX): - PR565: UIDefaults.getUI fails with jgoodies:looks 2.3.1 - PR593: Increment of invalidated iterator in IcedTeaPluginUtils (patch from barbara.xxx1975 at libero.it) - PR597: Entities are parsed incorrectly in PARAM tag in applet plugin + - PR619: Improper finalization by the plugin can crash the browser - Applets are now double-buffered to eliminate flicker in ones that do heavy drawing - RH665104: OpenJDK Firefox Java plugin loses a cookie * NetX diff -r 925f97c584a8 -r 06940cdcfef8 plugin/icedteanp/java/netscape/javascript/JSObject.java --- a/plugin/icedteanp/java/netscape/javascript/JSObject.java Tue Jan 18 12:07:45 2011 -0500 +++ b/plugin/icedteanp/java/netscape/javascript/JSObject.java Thu Jan 20 11:06:41 2011 -0500 @@ -259,6 +259,11 @@ public final class JSObject { * JavaScript object. */ protected void finalize() { + + // Proceed if this is a valid object (0L == default long == invalid) + if (internal == 0L) + return; + PluginDebug.debug("JSObject.finalize "); PluginAppletViewer.JavaScriptFinalize(internal); } From dbhole at icedtea.classpath.org Thu Jan 20 08:13:10 2011 From: dbhole at icedtea.classpath.org (dbhole at icedtea.classpath.org) Date: Thu, 20 Jan 2011 16:13:10 +0000 Subject: /hg/release/icedtea-web-1.0: Fix PR619: Improper finalization by... Message-ID: changeset d07ccc83a09c in /hg/release/icedtea-web-1.0 details: http://icedtea.classpath.org/hg/release/icedtea-web-1.0?cmd=changeset;node=d07ccc83a09c author: Deepak Bhole date: Thu Jan 20 11:06:41 2011 -0500 Fix PR619: Improper finalization by the plugin can crash the browser diffstat: 3 files changed, 12 insertions(+) ChangeLog | 6 ++++++ NEWS | 1 + plugin/icedteanp/java/netscape/javascript/JSObject.java | 5 +++++ diffs (39 lines): diff -r 71d6595e800c -r d07ccc83a09c ChangeLog --- a/ChangeLog Tue Jan 18 13:51:34 2011 -0500 +++ b/ChangeLog Thu Jan 20 11:06:41 2011 -0500 @@ -1,3 +1,9 @@ 2011-01-18 Andrew Su +2011-01-20 Deepak Bhole + + PR619: Improper finalization by the plugin can crash the browser + * plugin/icedteanp/java/netscape/javascript/JSObject.java (finalize): + Proceed with finalization only if JSObject is valid. + 2011-01-18 Andrew Su * netx/net/sourceforge/jnlp/controlpanel/AdvancedProxySettingsDialog.java: diff -r 71d6595e800c -r d07ccc83a09c NEWS --- a/NEWS Tue Jan 18 13:51:34 2011 -0500 +++ b/NEWS Thu Jan 20 11:06:41 2011 -0500 @@ -22,6 +22,7 @@ New in release 1.0 (2010-XX-XX): - PR565: UIDefaults.getUI fails with jgoodies:looks 2.3.1 - PR593: Increment of invalidated iterator in IcedTeaPluginUtils (patch from barbara.xxx1975 at libero.it) - PR597: Entities are parsed incorrectly in PARAM tag in applet plugin + - PR619: Improper finalization by the plugin can crash the browser - Applets are now double-buffered to eliminate flicker in ones that do heavy drawing - RH665104: OpenJDK Firefox Java plugin loses a cookie * NetX diff -r 71d6595e800c -r d07ccc83a09c plugin/icedteanp/java/netscape/javascript/JSObject.java --- a/plugin/icedteanp/java/netscape/javascript/JSObject.java Tue Jan 18 13:51:34 2011 -0500 +++ b/plugin/icedteanp/java/netscape/javascript/JSObject.java Thu Jan 20 11:06:41 2011 -0500 @@ -259,6 +259,11 @@ public final class JSObject { * JavaScript object. */ protected void finalize() { + + // Proceed if this is a valid object (0L == default long == invalid) + if (internal == 0L) + return; + PluginDebug.debug("JSObject.finalize "); PluginAppletViewer.JavaScriptFinalize(internal); } From dbhole at icedtea.classpath.org Thu Jan 20 08:13:19 2011 From: dbhole at icedtea.classpath.org (dbhole at icedtea.classpath.org) Date: Thu, 20 Jan 2011 16:13:19 +0000 Subject: /hg/release/icedtea6-1.7: Fix PR619: Improper finalization by th... Message-ID: changeset 500f06b81c78 in /hg/release/icedtea6-1.7 details: http://icedtea.classpath.org/hg/release/icedtea6-1.7?cmd=changeset;node=500f06b81c78 author: Deepak Bhole date: Thu Jan 20 11:11:20 2011 -0500 Fix PR619: Improper finalization by the plugin can crash the browser diffstat: 3 files changed, 12 insertions(+) ChangeLog | 6 ++++++ NEWS | 1 + plugin/icedteanp/java/netscape/javascript/JSObject.java | 5 +++++ diffs (39 lines): diff -r 9cfe7a59b531 -r 500f06b81c78 ChangeLog --- a/ChangeLog Tue Jan 18 15:07:41 2011 +0000 +++ b/ChangeLog Thu Jan 20 11:11:20 2011 -0500 @@ -1,3 +1,9 @@ 2011-01-18 Andrew John Hughes + + PR619: Improper finalization by the plugin can crash the browser + * plugin/icedteanp/java/netscape/javascript/JSObject.java (finalize): + Proceed with finalization only if JSObject is valid. + 2011-01-18 Andrew John Hughes * NEWS: Update date of 1.7.7 release. diff -r 9cfe7a59b531 -r 500f06b81c78 NEWS --- a/NEWS Tue Jan 18 15:07:41 2011 +0000 +++ b/NEWS Thu Jan 20 11:11:20 2011 -0500 @@ -16,6 +16,7 @@ New in release 1.7.8 (2011-XX-XX): - S6782079: PNG: reading metadata may cause OOM on truncated images * Fixes: - RH647157,RH582455: Update fontconfig files for rhel 6 + - PR619: Improper finalization by the plugin can crash the browser New in release 1.7.7 (2011-01-18): diff -r 9cfe7a59b531 -r 500f06b81c78 plugin/icedteanp/java/netscape/javascript/JSObject.java --- a/plugin/icedteanp/java/netscape/javascript/JSObject.java Tue Jan 18 15:07:41 2011 +0000 +++ b/plugin/icedteanp/java/netscape/javascript/JSObject.java Thu Jan 20 11:11:20 2011 -0500 @@ -279,6 +279,11 @@ public final class JSObject { */ protected void finalize() { + + // Proceed if this is a valid object (0L == default long == invalid) + if (internal == 0L) + return; + PluginDebug.debug("JSObject.finalize "); PluginAppletViewer.JavaScriptFinalize(internal); } From dbhole at icedtea.classpath.org Thu Jan 20 08:13:24 2011 From: dbhole at icedtea.classpath.org (dbhole at icedtea.classpath.org) Date: Thu, 20 Jan 2011 16:13:24 +0000 Subject: /hg/release/icedtea6-1.8: Fix PR619: Improper finalization by th... Message-ID: changeset 83b92103693a in /hg/release/icedtea6-1.8 details: http://icedtea.classpath.org/hg/release/icedtea6-1.8?cmd=changeset;node=83b92103693a author: Deepak Bhole date: Thu Jan 20 11:11:20 2011 -0500 Fix PR619: Improper finalization by the plugin can crash the browser diffstat: 3 files changed, 12 insertions(+) ChangeLog | 6 ++++++ NEWS | 1 + plugin/icedteanp/java/netscape/javascript/JSObject.java | 5 +++++ diffs (39 lines): diff -r 9b0c926d0965 -r 83b92103693a ChangeLog --- a/ChangeLog Tue Jan 18 15:10:06 2011 +0000 +++ b/ChangeLog Thu Jan 20 11:11:20 2011 -0500 @@ -1,3 +1,9 @@ 2011-01-18 Andrew John Hughes + + PR619: Improper finalization by the plugin can crash the browser + * plugin/icedteanp/java/netscape/javascript/JSObject.java (finalize): + Proceed with finalization only if JSObject is valid. + 2011-01-18 Andrew John Hughes * NEWS: Fix date of delayed 1.8.4 release. diff -r 9b0c926d0965 -r 83b92103693a NEWS --- a/NEWS Tue Jan 18 15:10:06 2011 +0000 +++ b/NEWS Thu Jan 20 11:11:20 2011 -0500 @@ -16,6 +16,7 @@ New in release 1.8.5 (2011-XX-XX): - S6782079: PNG: reading metadata may cause OOM on truncated images * Fixes - RH647157,RH582455: Update fontconfig files for rhel 6 + - PR619: Improper finalization by the plugin can crash the browser New in release 1.8.4 (2011-01-18): diff -r 9b0c926d0965 -r 83b92103693a plugin/icedteanp/java/netscape/javascript/JSObject.java --- a/plugin/icedteanp/java/netscape/javascript/JSObject.java Tue Jan 18 15:10:06 2011 +0000 +++ b/plugin/icedteanp/java/netscape/javascript/JSObject.java Thu Jan 20 11:11:20 2011 -0500 @@ -279,6 +279,11 @@ public final class JSObject { */ protected void finalize() { + + // Proceed if this is a valid object (0L == default long == invalid) + if (internal == 0L) + return; + PluginDebug.debug("JSObject.finalize "); PluginAppletViewer.JavaScriptFinalize(internal); } From dbhole at icedtea.classpath.org Thu Jan 20 08:13:30 2011 From: dbhole at icedtea.classpath.org (dbhole at icedtea.classpath.org) Date: Thu, 20 Jan 2011 16:13:30 +0000 Subject: /hg/release/icedtea6-1.9: Fix PR619: Improper finalization by th... Message-ID: changeset 09eef2decb0f in /hg/release/icedtea6-1.9 details: http://icedtea.classpath.org/hg/release/icedtea6-1.9?cmd=changeset;node=09eef2decb0f author: Deepak Bhole date: Thu Jan 20 11:11:20 2011 -0500 Fix PR619: Improper finalization by the plugin can crash the browser diffstat: 3 files changed, 12 insertions(+) ChangeLog | 6 ++++++ NEWS | 1 + plugin/icedteanp/java/netscape/javascript/JSObject.java | 5 +++++ diffs (39 lines): diff -r 6ec6e96141d8 -r 09eef2decb0f ChangeLog --- a/ChangeLog Tue Jan 18 15:17:47 2011 +0000 +++ b/ChangeLog Thu Jan 20 11:11:20 2011 -0500 @@ -1,3 +1,9 @@ 2011-01-18 Andrew John Hughes + + PR619: Improper finalization by the plugin can crash the browser + * plugin/icedteanp/java/netscape/javascript/JSObject.java (finalize): + Proceed with finalization only if JSObject is valid. + 2011-01-18 Andrew John Hughes * configure.ac: Bump to 1.9.5pre. diff -r 6ec6e96141d8 -r 09eef2decb0f NEWS --- a/NEWS Tue Jan 18 15:17:47 2011 +0000 +++ b/NEWS Thu Jan 20 11:11:20 2011 -0500 @@ -16,6 +16,7 @@ New in release 1.9.5 (2011-XX-XX): - S6782079: PNG: reading metadata may cause OOM on truncated images * Fixes - RH647157,RH582455: Update fontconfig files for rhel 6 + - PR619: Improper finalization by the plugin can crash the browser New in release 1.9.4 (2011-01-18): diff -r 6ec6e96141d8 -r 09eef2decb0f plugin/icedteanp/java/netscape/javascript/JSObject.java --- a/plugin/icedteanp/java/netscape/javascript/JSObject.java Tue Jan 18 15:17:47 2011 +0000 +++ b/plugin/icedteanp/java/netscape/javascript/JSObject.java Thu Jan 20 11:11:20 2011 -0500 @@ -279,6 +279,11 @@ public final class JSObject { */ protected void finalize() { + + // Proceed if this is a valid object (0L == default long == invalid) + if (internal == 0L) + return; + PluginDebug.debug("JSObject.finalize "); PluginAppletViewer.JavaScriptFinalize(internal); } From dbhole at redhat.com Thu Jan 20 08:14:17 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Thu, 20 Jan 2011 11:14:17 -0500 Subject: RFE: Patch for potential browser crash by the plugin In-Reply-To: <20110120001613.GC16826@rivendell.middle-earth.co.uk> References: <20110119222453.GB5250@redhat.com> <20110120001613.GC16826@rivendell.middle-earth.co.uk> Message-ID: <20110120161417.GA18293@redhat.com> * Dr Andrew John Hughes [2011-01-19 19:16]: > On 17:24 Wed 19 Jan , Deepak Bhole wrote: > > Hi, > > > > Attached patch fixes Bug# 619: > > http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=619 > > > > ChangeLog: > > 2011-01-19 Deepak Bhole > > > > * plugin/icedteanp/java/netscape/javascript/JSObject.java (finalize): > > Proceed with finalization only if JSObject is valid. > > > > > > Okay for HEAD, 1.0 and backport to maintained icedtea6 branches? > > > > Cheers, > > Deepak > > Assuming you mean IcedTea-Web HEAD, then yes fine for all (including > 1.7, 1.8 and 1.9 branches). > > Please make sure to document the fix in NEWS. > Done. Thanks for reviewing. Change pushed to icedtea6-1.7, icedtea6-1.8, icedtea6-1.9, icedtea-web-1.0 and icedtea-web (HEAD). Cheers, Deepak > > diff -r bbbe02c58ddc plugin/icedteanp/java/netscape/javascript/JSObject.java > > --- a/plugin/icedteanp/java/netscape/javascript/JSObject.java Mon Dec 20 13:37:59 2010 -0500 > > +++ b/plugin/icedteanp/java/netscape/javascript/JSObject.java Wed Dec 22 14:34:58 2010 -0500 > > @@ -259,6 +259,11 @@ > > * JavaScript object. > > */ > > protected void finalize() { > > + > > + // Proceed if this is a valid object (0L == default long == invalid) > > + if (internal == 0L) > > + return; > > + > > PluginDebug.debug("JSObject.finalize "); > > PluginAppletViewer.JavaScriptFinalize(internal); > > } > > > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From dbhole at redhat.com Thu Jan 20 08:33:25 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Thu, 20 Jan 2011 11:33:25 -0500 Subject: [icedtea-web] RFC: Update NEWS file In-Reply-To: <4CF7BCE0.8080800@redhat.com> References: <4CF7BCE0.8080800@redhat.com> Message-ID: <20110120163325.GB18293@redhat.com> * Omair Majid [2010-12-02 12:17]: > Hi, > > The attached patch updates the NEWS file. It reorganizes things into > major/minor sections, so all important items are visible first. > > Thoughts/comments? > Sorry, I thought I had approved this. Okay for HEAD and 1.0. Cheers, Deepak > Cheers, > Omair > diff -r 6c8e9229bded NEWS > --- a/NEWS Thu Dec 02 10:22:44 2010 -0500 > +++ b/NEWS Thu Dec 02 10:34:27 2010 -0500 > @@ -13,18 +13,29 @@ > * Initial release of IcedTea-Web > * Security updates > - RH645843, CVE-2010-3860: IcedTea System property information leak via public static > -* Plugin > - - PR542: Plugin fails with NPE on http://www.openprocessing.org/visuals/iframe.php?visualID=2615 > - - PR552: Support for FreeBSD's pthread implementation > - - PR554: System.err writes content two times > - - PR556: Applet initialization code is prone to race conditions > - - PR557: Applet opens in a separate window if tab is closed when the applet loads > - - PR565: UIDefaults.getUI fails with jgoodies:looks 2.3.1 > - - PR593: Increment of invalidated iterator in IcedTeaPluginUtils (patch from barbara.xxx1975 at libero.it) > - - Applets are now double-buffered to eliminate flicker in ones that do heavy drawing > -* NetX > - - Add a new option -Xclearcache > - - Interfaces javax.jnlp.IntegrationService and javax.jnlp.DownloadService2 are now available > - - PR592: NetX can create invalid desktop entry files > -* Control Panel > - - Modifications to deployments.properties file can now be done through a GUI > +* New Features > + - IcedTea-Web now uses a deployment.properties file to specify configuration > + - An preview of a Control Panel that allows configuring IcedTea-Web using a GUI > + - System-level as well as user-level deployment.properties files with locked configuration are supported > + - Static proxies are now supported using the deployment.properties file > + - User prompts can now be configured using the deployment.properties > + - Applications and applets can now have a Look and Feel different from rest of IcedTea-Web > +* Minor improvements and fixes > + - common: Clean up native directories on exit > + - common: Cached files with special characters in filenames are now handled correctly > + - common: Interfaces javax.jnlp.IntegrationService and javax.jnlp.DownloadService2 are now available > + - javaws: PR592: NetX can create invalid desktop entry files > + - javaws: Add a new option -Xclearcache > + - javaws: Removed option -umask > + - javaws: Applications with non-public main classes are now supported. > + - javaws: JNLP files containing as well as will now work > + - javaws: The javaws.desktop file now points explicitly to NetX's javaws binary > + - plugin: PR542: Plugin fails with NPE on http://www.openprocessing.org/visuals/iframe.php?visualID=2615 > + - plugin: PR552: Support for FreeBSD's pthread implementation > + - plugin: PR554: System.err writes content two times > + - plugin: PR556: Applet initialization code is prone to race conditions > + - plugin: PR557: Applet opens in a separate window if tab is closed when the applet loads > + - plugin: PR565: UIDefaults.getUI fails with jgoodies:looks 2.3.1 > + - plugin: PR593: Increment of invalidated iterator in IcedTeaPluginUtils (patch from barbara.xxx1975 at libero.it) > + - plugin: JNLP files referenced in the applet tag are now parsed to detect applet properties > + - plugin: Applets are now double-buffered to eliminate flicker in ones that do heavy drawing From omajid at icedtea.classpath.org Thu Jan 20 09:10:46 2011 From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org) Date: Thu, 20 Jan 2011 17:10:46 +0000 Subject: /hg/release/icedtea-web-1.0: Change the format of NEWS file to e... Message-ID: changeset bafc58e4df46 in /hg/release/icedtea-web-1.0 details: http://icedtea.classpath.org/hg/release/icedtea-web-1.0?cmd=changeset;node=bafc58e4df46 author: Omair Majid date: Thu Jan 20 12:09:09 2011 -0500 Change the format of NEWS file to emphasize new features and indicate common fixes 2011-01-20 Omair Majid * NEWS: Change to a new format to emphasize new features as well as indicate common fixes. diffstat: 2 files changed, 34 insertions(+), 18 deletions(-) ChangeLog | 5 +++++ NEWS | 47 +++++++++++++++++++++++++++++------------------ diffs (67 lines): diff -r d07ccc83a09c -r bafc58e4df46 ChangeLog --- a/ChangeLog Thu Jan 20 11:06:41 2011 -0500 +++ b/ChangeLog Thu Jan 20 12:09:09 2011 -0500 @@ -1,3 +1,8 @@ 2011-01-20 Deepak Bhole + + * NEWS: Change to a new format to emphasize new features as well as + indicate common fixes. + 2011-01-20 Deepak Bhole PR619: Improper finalization by the plugin can crash the browser diff -r d07ccc83a09c -r bafc58e4df46 NEWS --- a/NEWS Thu Jan 20 11:06:41 2011 -0500 +++ b/NEWS Thu Jan 20 12:09:09 2011 -0500 @@ -13,22 +13,33 @@ New in release 1.0 (2010-XX-XX): * Initial release of IcedTea-Web * Security updates - RH645843, CVE-2010-3860: IcedTea System property information leak via public static -* Plugin - - PR542: Plugin fails with NPE on http://www.openprocessing.org/visuals/iframe.php?visualID=2615 - - PR552: Support for FreeBSD's pthread implementation - - PR554: System.err writes content two times - - PR556: Applet initialization code is prone to race conditions - - PR557: Applet opens in a separate window if tab is closed when the applet loads - - PR565: UIDefaults.getUI fails with jgoodies:looks 2.3.1 - - PR593: Increment of invalidated iterator in IcedTeaPluginUtils (patch from barbara.xxx1975 at libero.it) - - PR597: Entities are parsed incorrectly in PARAM tag in applet plugin - - PR619: Improper finalization by the plugin can crash the browser - - Applets are now double-buffered to eliminate flicker in ones that do heavy drawing - - RH665104: OpenJDK Firefox Java plugin loses a cookie -* NetX - - Add a new option -Xclearcache - - Interfaces javax.jnlp.IntegrationService and javax.jnlp.DownloadService2 are now available - - PR592: NetX can create invalid desktop entry files - RH663680, CVE-2010-4351: IcedTea JNLP SecurityManager bypass -* Control Panel - - Modifications to deployments.properties file can now be done through a GUI +* New Features + - IcedTea-Web now uses a deployment.properties file to specify configuration + - System-level as well as user-level deployment.properties files with locked configuration are supported + - Preview of a Control Panel that allows configuring IcedTea-Web using a GUI + - Static proxies are now supported using the deployment.properties file + - User prompts can now be configured using the deployment.properties + - Applications and applets can now have a Look and Feel different from rest of IcedTea-Web +* Minor improvements and fixes + - common: Clean up native directories on exit + - common: Cached files with special characters in filenames are now handled correctly + - common: Interfaces javax.jnlp.IntegrationService and javax.jnlp.DownloadService2 are now available + - javaws: PR592: NetX can create invalid desktop entry files + - javaws: Add a new option -Xclearcache + - javaws: Removed option -umask + - javaws: Applications with non-public main classes are now supported. + - javaws: JNLP files containing as well as will now work + - javaws: The javaws.desktop file now points explicitly to NetX's javaws binary + - plugin: PR542: Plugin fails with NPE on http://www.openprocessing.org/visuals/iframe.php?visualID=2615 + - plugin: PR552: Support for FreeBSD's pthread implementation + - plugin: PR554: System.err writes content two times + - plugin: PR556: Applet initialization code is prone to race conditions + - plugin: PR557: Applet opens in a separate window if tab is closed when the applet loads + - plugin: PR565: UIDefaults.getUI fails with jgoodies:looks 2.3.1 + - plugin: PR593: Increment of invalidated iterator in IcedTeaPluginUtils (patch from barbara.xxx1975 at libero.it) + - plugin: PR597: Entities are parsed incorrectly in PARAM tag in applet plugin + - plugin: PR619: Improper finalization by the plugin can crash the browser + - plugin: RH665104: OpenJDK Firefox Java plugin loses a cookie + - plugin: JNLP files referenced in the applet tag are now parsed to detect applet properties + - plugin: Applets are now double-buffered to eliminate flicker in ones that do heavy drawing From omajid at redhat.com Thu Jan 20 09:46:45 2011 From: omajid at redhat.com (Omair Majid) Date: Thu, 20 Jan 2011 12:46:45 -0500 Subject: [icedtea-web] RFC: backport changeset 9397074c2c39 to icedtea-web 1.0 Message-ID: <4D387505.9090305@redhat.com> Hi, I would like to backport changeset 9397074c2c39 from icedtea-web HEAD to icedtea-web 1.0. This changeset adds symlinks for javaws and itweb-settings under JDK_HOME/jre/bin. Without this patch, JNLPs which require a new VM to start will fail: $ javaws SweetHome3D.jnlp net.sourceforge.jnlp.LaunchException: Fatal: External Launch Error: Could not launch JNLP file. Caused by: java.io.IOException: Cannot run program "$JDK_HOME/jre/bin/javaws": java.io.IOException: error=2, No such file or directory The backport is attached. Ok to commit? Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: symlink.patch Type: text/x-patch Size: 4442 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110120/94c95ed2/symlink.patch From dbhole at redhat.com Thu Jan 20 09:57:52 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Thu, 20 Jan 2011 12:57:52 -0500 Subject: [icedtea-web] RFC: backport changeset 9397074c2c39 to icedtea-web 1.0 In-Reply-To: <4D387505.9090305@redhat.com> References: <4D387505.9090305@redhat.com> Message-ID: <20110120175752.GC18293@redhat.com> * Omair Majid [2011-01-20 12:46]: > Hi, > > I would like to backport changeset 9397074c2c39 from icedtea-web > HEAD to icedtea-web 1.0. > > This changeset adds symlinks for javaws and itweb-settings under > JDK_HOME/jre/bin. Without this patch, JNLPs which require a new VM > to start will fail: > > $ javaws SweetHome3D.jnlp > net.sourceforge.jnlp.LaunchException: Fatal: External Launch Error: > Could not launch JNLP file. > Caused by: java.io.IOException: Cannot run program > "$JDK_HOME/jre/bin/javaws": java.io.IOException: error=2, No such > file or directory > > The backport is attached. > > Ok to commit? > The binary in jre/bin should be the actual file, not the one in JAVA_HOME/bin. JAVA_HOME/bin is optional and installed as part of the JDK. However the JRE (and all the components therein) should be independently runnable. Cheers, Deepak > Cheers, > Omair > diff -r bafc58e4df46 ChangeLog > --- a/ChangeLog Thu Jan 20 12:09:09 2011 -0500 > +++ b/ChangeLog Thu Jan 20 12:39:16 2011 -0500 > @@ -48,6 +48,17 @@ > * netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: > Make sure SecurityException is thrown if necessary. > > +2010-12-15 Omair Majid > + > + * Makefile.am > + (install-exec-local): Install plugin.jar as data. If $(prefix)/jre/bin > + exists, then install symlinks to real javaws and itweb-settings binaries > + under it. > + ($(NETX_DIR)/launcher/%.o): Set system property java.icedtea-web.bin to > + point to the installed location of the javaws binary. > + * netx/net/sourceforge/jnlp/Launcher.java (launchExternal): Use the system > + property java.icedtea-web.bin to locate javaws binary. > + > 2010-12-14 Andrew John Hughes > > * Makefile.am: > diff -r bafc58e4df46 Makefile.am > --- a/Makefile.am Thu Jan 20 12:09:09 2011 -0500 > +++ b/Makefile.am Thu Jan 20 12:39:16 2011 -0500 > @@ -106,12 +106,28 @@ > if ENABLE_PLUGIN > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) > - ${INSTALL_PROGRAM} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > endif > ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > + if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > + if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > + rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > + fi ; \ > + if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > + ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > + fi ; \ > + fi > ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > + if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > + if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > + rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > + fi ; \ > + if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > + ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > + fi ; \ > + fi > > install-data-local: > ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 > @@ -142,7 +158,14 @@ > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > rm -f $(DESTDIR)$(bindir)/javaws > + if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > + rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > + fi > + rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > rm -f $(DESTDIR)$(bindir)/itweb-settings > + if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > + rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > + fi > rm -rf $(DESTDIR)$(htmldir) > > # Plugin > @@ -325,8 +348,9 @@ > > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > mkdir -p $(NETX_DIR)/launcher && \ > - $(CC) $(LAUNCHER_FLAGS) -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' -DPROGNAME='"javaws"' \ > - -c -o $@ $< > + $(CC) $(LAUNCHER_FLAGS) \ > + -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > + -DPROGNAME='"javaws"' -c -o $@ $< > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > mkdir -p $(NETX_DIR)/launcher/controlpanel && \ > diff -r bafc58e4df46 netx/net/sourceforge/jnlp/Launcher.java > --- a/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 12:09:09 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 12:39:16 2011 -0500 > @@ -329,11 +329,8 @@ > > List commands = new LinkedList(); > > - String pathToWebstartBinary = System.getProperty("java.home") + > - File.separatorChar + > - "bin" + > - File.separatorChar + > - "javaws"; > + // this property is set by the javaws launcher to point to the javaws binary > + String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); > commands.add(pathToWebstartBinary); > // use -Jargument format to pass arguments to the JVM through the launcher > for (String arg : vmArgs) { From dbhole at redhat.com Thu Jan 20 10:18:22 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Thu, 20 Jan 2011 13:18:22 -0500 Subject: [icedtea-web] RFC: backport changeset 9397074c2c39 to icedtea-web 1.0 In-Reply-To: <20110120175752.GC18293@redhat.com> References: <4D387505.9090305@redhat.com> <20110120175752.GC18293@redhat.com> Message-ID: <20110120181821.GD18293@redhat.com> * Deepak Bhole [2011-01-20 12:59]: > * Omair Majid [2011-01-20 12:46]: > > Hi, > > > > I would like to backport changeset 9397074c2c39 from icedtea-web > > HEAD to icedtea-web 1.0. > > > > This changeset adds symlinks for javaws and itweb-settings under > > JDK_HOME/jre/bin. Without this patch, JNLPs which require a new VM > > to start will fail: > > > > $ javaws SweetHome3D.jnlp > > net.sourceforge.jnlp.LaunchException: Fatal: External Launch Error: > > Could not launch JNLP file. > > Caused by: java.io.IOException: Cannot run program > > "$JDK_HOME/jre/bin/javaws": java.io.IOException: error=2, No such > > file or directory > > > > The backport is attached. > > > > Ok to commit? > > > > The binary in jre/bin should be the actual file, not the one in > JAVA_HOME/bin. JAVA_HOME/bin is optional and installed as part of the > JDK. However the JRE (and all the components therein) should be > independently runnable. > Something else just came to mind... the change to Launcher.java should be reverted. The patches changes the code to use java.icedtea-web.bin which is defined at build time. This makes the build un-relocatable. java.home is the right property to use in this situation. Cheers, Deepak > Cheers, > Deepak > > > Cheers, > > Omair > > > diff -r bafc58e4df46 ChangeLog > > --- a/ChangeLog Thu Jan 20 12:09:09 2011 -0500 > > +++ b/ChangeLog Thu Jan 20 12:39:16 2011 -0500 > > @@ -48,6 +48,17 @@ > > * netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: > > Make sure SecurityException is thrown if necessary. > > > > +2010-12-15 Omair Majid > > + > > + * Makefile.am > > + (install-exec-local): Install plugin.jar as data. If $(prefix)/jre/bin > > + exists, then install symlinks to real javaws and itweb-settings binaries > > + under it. > > + ($(NETX_DIR)/launcher/%.o): Set system property java.icedtea-web.bin to > > + point to the installed location of the javaws binary. > > + * netx/net/sourceforge/jnlp/Launcher.java (launchExternal): Use the system > > + property java.icedtea-web.bin to locate javaws binary. > > + > > 2010-12-14 Andrew John Hughes > > > > * Makefile.am: > > diff -r bafc58e4df46 Makefile.am > > --- a/Makefile.am Thu Jan 20 12:09:09 2011 -0500 > > +++ b/Makefile.am Thu Jan 20 12:39:16 2011 -0500 > > @@ -106,12 +106,28 @@ > > if ENABLE_PLUGIN > > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ > > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) > > - ${INSTALL_PROGRAM} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > endif > > ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > > + if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > + if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > + rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > + fi ; \ > > + if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > > + ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > + fi ; \ > > + fi > > ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > > + if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > + if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > + rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > + fi ; \ > > + if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > > + ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > > + fi ; \ > > + fi > > > > install-data-local: > > ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 > > @@ -142,7 +158,14 @@ > > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > > rm -f $(DESTDIR)$(bindir)/javaws > > + if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > + rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > + fi > > + rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > > rm -f $(DESTDIR)$(bindir)/itweb-settings > > + if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > + rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > + fi > > rm -rf $(DESTDIR)$(htmldir) > > > > # Plugin > > @@ -325,8 +348,9 @@ > > > > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > > mkdir -p $(NETX_DIR)/launcher && \ > > - $(CC) $(LAUNCHER_FLAGS) -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' -DPROGNAME='"javaws"' \ > > - -c -o $@ $< > > + $(CC) $(LAUNCHER_FLAGS) \ > > + -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > > + -DPROGNAME='"javaws"' -c -o $@ $< > > > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > > mkdir -p $(NETX_DIR)/launcher/controlpanel && \ > > diff -r bafc58e4df46 netx/net/sourceforge/jnlp/Launcher.java > > --- a/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 12:09:09 2011 -0500 > > +++ b/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 12:39:16 2011 -0500 > > @@ -329,11 +329,8 @@ > > > > List commands = new LinkedList(); > > > > - String pathToWebstartBinary = System.getProperty("java.home") + > > - File.separatorChar + > > - "bin" + > > - File.separatorChar + > > - "javaws"; > > + // this property is set by the javaws launcher to point to the javaws binary > > + String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); > > commands.add(pathToWebstartBinary); > > // use -Jargument format to pass arguments to the JVM through the launcher > > for (String arg : vmArgs) { > From omajid at redhat.com Thu Jan 20 10:38:24 2011 From: omajid at redhat.com (Omair Majid) Date: Thu, 20 Jan 2011 13:38:24 -0500 Subject: [icedtea-web] RFC: backport changeset 9397074c2c39 to icedtea-web 1.0 In-Reply-To: <20110120181821.GD18293@redhat.com> References: <4D387505.9090305@redhat.com> <20110120175752.GC18293@redhat.com> <20110120181821.GD18293@redhat.com> Message-ID: <4D388120.1030802@redhat.com> On 01/20/2011 01:18 PM, Deepak Bhole wrote: > * Deepak Bhole [2011-01-20 12:59]: >> * Omair Majid [2011-01-20 12:46]: >>> Hi, >>> >>> I would like to backport changeset 9397074c2c39 from icedtea-web >>> HEAD to icedtea-web 1.0. >>> >>> This changeset adds symlinks for javaws and itweb-settings under >>> JDK_HOME/jre/bin. Without this patch, JNLPs which require a new VM >>> to start will fail: >>> >>> $ javaws SweetHome3D.jnlp >>> net.sourceforge.jnlp.LaunchException: Fatal: External Launch Error: >>> Could not launch JNLP file. >>> Caused by: java.io.IOException: Cannot run program >>> "$JDK_HOME/jre/bin/javaws": java.io.IOException: error=2, No such >>> file or directory >>> >>> The backport is attached. >>> >>> Ok to commit? >>> >> >> The binary in jre/bin should be the actual file, not the one in >> JAVA_HOME/bin. JAVA_HOME/bin is optional and installed as part of the >> JDK. However the JRE (and all the components therein) should be >> independently runnable. >> > > Something else just came to mind... the change to Launcher.java should > be reverted. The patches changes the code to use java.icedtea-web.bin > which is defined at build time. This makes the build un-relocatable. > java.home is the right property to use in this situation. > I didn't realize there were these issues with the patch, thanks for pointing them out. From what I understand, we want two (possibly different) binaries in two locations such that the two binaries dont depend on each other? Or can $JDK/bin/javaws assume that $JDK/jre/bin/javaws exists? Also, how does this address the issue where $(prefix) is not a JDK folder (as pointed out by Andrew Hughes while he was reviewing the original patch [1]). Thanks, Omair [1] http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2010-December/011426.html From dbhole at redhat.com Thu Jan 20 11:15:42 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Thu, 20 Jan 2011 14:15:42 -0500 Subject: [icedtea-web] RFC: backport changeset 9397074c2c39 to icedtea-web 1.0 In-Reply-To: <4D388120.1030802@redhat.com> References: <4D387505.9090305@redhat.com> <20110120175752.GC18293@redhat.com> <20110120181821.GD18293@redhat.com> <4D388120.1030802@redhat.com> Message-ID: <20110120191542.GE18293@redhat.com> * Omair Majid [2011-01-20 13:38]: > On 01/20/2011 01:18 PM, Deepak Bhole wrote: > >* Deepak Bhole [2011-01-20 12:59]: > >>* Omair Majid [2011-01-20 12:46]: > >>>Hi, > >>> > >>>I would like to backport changeset 9397074c2c39 from icedtea-web > >>>HEAD to icedtea-web 1.0. > >>> > >>>This changeset adds symlinks for javaws and itweb-settings under > >>>JDK_HOME/jre/bin. Without this patch, JNLPs which require a new VM > >>>to start will fail: > >>> > >>>$ javaws SweetHome3D.jnlp > >>>net.sourceforge.jnlp.LaunchException: Fatal: External Launch Error: > >>>Could not launch JNLP file. > >>>Caused by: java.io.IOException: Cannot run program > >>>"$JDK_HOME/jre/bin/javaws": java.io.IOException: error=2, No such > >>>file or directory > >>> > >>>The backport is attached. > >>> > >>>Ok to commit? > >>> > >> > >>The binary in jre/bin should be the actual file, not the one in > >>JAVA_HOME/bin. JAVA_HOME/bin is optional and installed as part of the > >>JDK. However the JRE (and all the components therein) should be > >>independently runnable. > >> > > > >Something else just came to mind... the change to Launcher.java should > >be reverted. The patches changes the code to use java.icedtea-web.bin > >which is defined at build time. This makes the build un-relocatable. > >java.home is the right property to use in this situation. > > > > I didn't realize there were these issues with the patch, thanks for > pointing them out. > > From what I understand, we want two (possibly different) binaries in > two locations such that the two binaries dont depend on each other? > Or can $JDK/bin/javaws assume that $JDK/jre/bin/javaws exists? > Hmm, the JRE is a subset of the JDK (atleast in all RPM installations I've seen). However it seems that files are always duplicated across JAVA_HOME/bin and JAVA_HOME/jre/bin rather than linked. Perhaps this was to maintain consistency with Windows (which doesn't have symlinks) but I am unsure. Either way, perhaps we should maintain consistency and duplicate the files as well. > Also, how does this address the issue where $(prefix) is not a JDK > folder (as pointed out by Andrew Hughes while he was reviewing the > original patch [1]). > I think Andrew's suggestion is correct, that jre/bin/javaws should only be installed if prefix/jre/bin exists. Btw, we might have to build binaries for JAVA_HOME/jre/bin and for JAVA_HOME/bin separately with different args as the binaries rely on relative paths to find libjvm.so -- I haven't looked into it in detail, but please keep that in mind when re-working the patch. Cheers, Deepak > Thanks, > Omair > > [1] http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2010-December/011426.html From asu at icedtea.classpath.org Thu Jan 20 11:52:57 2011 From: asu at icedtea.classpath.org (asu at icedtea.classpath.org) Date: Thu, 20 Jan 2011 19:52:57 +0000 Subject: /hg/icedtea-web: Remove dead, commented, unused code. Message-ID: changeset c5b209388b54 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=c5b209388b54 author: Andrew Su date: Thu Jan 20 14:54:27 2011 -0500 Remove dead, commented, unused code. diffstat: 12 files changed, 43 insertions(+), 284 deletions(-) ChangeLog | 42 ++ plugin/icedteanp/java/sun/applet/GetWindowPluginCallRequest.java | 3 plugin/icedteanp/java/sun/applet/MethodOverloadResolver.java | 4 plugin/icedteanp/java/sun/applet/PluginAppletSecurityContext.java | 143 ---------- plugin/icedteanp/java/sun/applet/PluginAppletViewer.java | 24 - plugin/icedteanp/java/sun/applet/PluginCallRequest.java | 3 plugin/icedteanp/java/sun/applet/PluginDebug.java | 2 plugin/icedteanp/java/sun/applet/PluginMessageConsumer.java | 22 - plugin/icedteanp/java/sun/applet/PluginMessageHandlerWorker.java | 2 plugin/icedteanp/java/sun/applet/PluginObjectStore.java | 14 plugin/icedteanp/java/sun/applet/PluginProxyInfoRequest.java | 1 plugin/icedteanp/java/sun/applet/PluginStreamHandler.java | 67 ---- diffs (truncated from 729 to 500 lines): diff -r 06940cdcfef8 -r c5b209388b54 ChangeLog --- a/ChangeLog Thu Jan 20 11:06:41 2011 -0500 +++ b/ChangeLog Thu Jan 20 14:54:27 2011 -0500 @@ -1,3 +1,45 @@ 2011-01-20 Deepak Bhole + + Removing dead/commented/unused code. + * plugin/icedteanp/java/sun/applet/GetWindowPluginCallRequest.java: + Removed unused imports. + * plugin/icedteanp/java/sun/applet/MethodOverloadResolver.java: + (getMatchingMethod): Removed unused variable. + (getMatchingConstructor): Removed unused variable. + * plugin/icedteanp/java/sun/applet/PluginAppletSecurityContext.java: + Removed unused imports. + (Signature): Removed commented code. + (handleMessage): Removed commented code. + (getAccessControlContext): Remove commented code. + * plugin/icedteanp/java/sun/applet/PluginAppletViewer.java: + (getCachedImage): Removed commented code. + (makeReader): Removed unused method. + (parse): Removed unused variables. Removed dead code. + * plugin/icedteanp/java/sun/applet/PluginCallRequest.java: Removed + unused imports. + * plugin/icedteanp/java/sun/applet/PluginDebug.java: Removed unused + imports. + * plugin/icedteanp/java/sun/applet/PluginMessageConsumer.java: Removed + unused imports. + (getReference): Removed unused method. + (isInInit): Removed unused method. + (dumpWorkerStatus): Removed unused method. + * plugin/icedteanp/java/sun/applet/PluginMessageHandlerWorker.java: + Removed unused variable. + (PluginMessageHandlerWorker): Removed unused variable. + (plugin/icedteanp/java/sun/applet/PluginObjectStore.java): Removed + unused imports. + (reference): Removed commented code. + (unreference): Removed commented code. + * plugin/icedteanp/java/sun/applet/PluginProxyInfoRequest.java: + Removed unused import. + * plugin/icedteanp/java/sun/applet/PluginStreamHandler.java: Removed + unused imports. Removed unused variable. + (PluginStreamHandler): Removed unnecessary comments. Removed commented + code. + (startProcessing): Removed unused variables. Removed commented code. + (write): Removed commented code. + 2011-01-20 Deepak Bhole PR619: Improper finalization by the plugin can crash the browser diff -r 06940cdcfef8 -r c5b209388b54 plugin/icedteanp/java/sun/applet/GetWindowPluginCallRequest.java --- a/plugin/icedteanp/java/sun/applet/GetWindowPluginCallRequest.java Thu Jan 20 11:06:41 2011 -0500 +++ b/plugin/icedteanp/java/sun/applet/GetWindowPluginCallRequest.java Thu Jan 20 14:54:27 2011 -0500 @@ -37,9 +37,6 @@ exception statement from your version. * package sun.applet; -import java.security.AccessControlContext; -import java.security.ProtectionDomain; - public class GetWindowPluginCallRequest extends PluginCallRequest { // FIXME: look into int vs long JavaScript internal values. long internal; diff -r 06940cdcfef8 -r c5b209388b54 plugin/icedteanp/java/sun/applet/MethodOverloadResolver.java --- a/plugin/icedteanp/java/sun/applet/MethodOverloadResolver.java Thu Jan 20 11:06:41 2011 -0500 +++ b/plugin/icedteanp/java/sun/applet/MethodOverloadResolver.java Thu Jan 20 14:54:27 2011 -0500 @@ -175,8 +175,6 @@ public class MethodOverloadResolver { int lowestCost = Integer.MAX_VALUE; - ArrayList paramList = new ArrayList(); - for (Method matchingMethod : matchingMethods) { int methodCost = 0; @@ -239,8 +237,6 @@ public class MethodOverloadResolver { System.out.println("getMatchingConstructor called with: " + printList(callList)); int lowestCost = Integer.MAX_VALUE; - - ArrayList paramList = new ArrayList(); for (Constructor matchingConstructor : matchingConstructors) { diff -r 06940cdcfef8 -r c5b209388b54 plugin/icedteanp/java/sun/applet/PluginAppletSecurityContext.java --- a/plugin/icedteanp/java/sun/applet/PluginAppletSecurityContext.java Thu Jan 20 11:06:41 2011 -0500 +++ b/plugin/icedteanp/java/sun/applet/PluginAppletSecurityContext.java Thu Jan 20 14:54:27 2011 -0500 @@ -37,7 +37,6 @@ exception statement from your version. * package sun.applet; -import java.io.File; import java.lang.reflect.Array; import java.lang.reflect.Constructor; import java.lang.reflect.Field; @@ -53,13 +52,10 @@ import java.security.Permissions; import java.security.Permissions; import java.security.PrivilegedAction; import java.security.ProtectionDomain; -import java.text.DecimalFormat; import java.util.ArrayList; import java.util.Hashtable; import java.util.List; import java.util.Map; - -import javax.swing.text.html.HTMLDocument.HTMLReader.IsindexAction; import net.sourceforge.jnlp.runtime.JNLPRuntime; import netscape.javascript.JSObjectCreatePermission; @@ -144,32 +140,25 @@ class Signature { if (elem == null) // end of signature continue; - // System.out.println ("NEXT TYPE: " + elem); Class primitive = primitiveNameToType(elem); if (primitive != null) typeList.add(primitive); else { - // System.out.println ("HERE1"); int dimsize = 0; int n = elem.indexOf('['); if (n != -1) { - // System.out.println ("HERE2"); String arrayType = elem.substring(0, n); dimsize++; n = elem.indexOf('[', n + 1); - // System.out.println ("HERE2.5"); while (n != -1) { dimsize++; n = elem.indexOf('[', n + 1); - // System.out.println ("HERE2.8"); } int[] dims = new int[dimsize]; primitive = primitiveNameToType(arrayType); - // System.out.println ("HERE3"); if (primitive != null) { typeList.add(Array.newInstance(primitive, dims) .getClass()); - // System.out.println ("HERE4"); } else typeList.add(Array.newInstance( getClass(arrayType, cl), dims).getClass()); @@ -557,11 +546,6 @@ public class PluginAppletSecurityContext // Cast the object to appropriate type before insertion value = MethodOverloadResolver.getCostAndCastedObject(value, store.getObject(arrayID).getClass().getComponentType())[1]; - //if (value == null && - // store.getObject(arrayID).getClass().getComponentType().isPrimitive()) { - // value = 0; - //} - Array.set(store.getObject(arrayID), index, value); write(reference, "SetObjectArrayElement"); @@ -569,13 +553,10 @@ public class PluginAppletSecurityContext String[] args = message.split(" "); Integer arrayID = parseCall(args[1], null, Integer.class); - //System.out.println("ARRAYID: " + arrayID); Object o = store.getObject(arrayID); int len = 0; len = Array.getLength(o); - // System.out.println ("Returning array length: " + len); - // System.out.println ("array length: " + o + " " + len); write(reference, "GetArrayLength " + Array.getLength(o)); } else if (message.startsWith("GetField")) { String[] args = message.split(" "); @@ -624,10 +605,7 @@ public class PluginAppletSecurityContext } else if (message.startsWith("GetObjectClass")) { int oid = Integer.parseInt(message.substring("GetObjectClass" .length() + 1)); - // System.out.println ("GETTING CLASS FOR: " + oid); Class c = store.getObject(oid).getClass(); - // System.out.println (" OBJ: " + store.getObject(oid)); - // System.out.println (" CLS: " + c); store.reference(c); write(reference, "GetObjectClass " + store.getIdentifier(c)); @@ -773,8 +751,6 @@ public class PluginAppletSecurityContext byte[] b = null; o = (String) store.getObject(stringID); b = o.getBytes("UTF-8"); - // System.out.println ("STRING UTF-8 LENGTH: " + o + " " + - // b.length); write(reference, "GetStringUTFLength " + o.length()); } else if (message.startsWith("GetStringLength")) { @@ -785,10 +761,7 @@ public class PluginAppletSecurityContext byte[] b = null; o = (String) store.getObject(stringID); b = o.getBytes("UTF-16LE"); - // System.out.println ("STRING UTF-16 LENGTH: " + o + " " + - // b.length); - // System.out.println ("Java: GetStringLength " + b.length); write(reference, "GetStringLength " + o.length()); } else if (message.startsWith("GetStringUTFChars")) { String[] args = message.split(" "); @@ -807,8 +780,6 @@ public class PluginAppletSecurityContext + Integer .toString(((int) b[i]) & 0x0ff, 16)); - // System.out.println ("Java: GetStringUTFChars: " + o); - // //System.out.println ("String UTF BYTES: " + buf); write(reference, "GetStringUTFChars " + buf); } else if (message.startsWith("GetStringChars")) { String[] args = message.split(" "); @@ -853,10 +824,6 @@ public class PluginAppletSecurityContext String[] args = message.split(" "); String type = parseCall(args[1], null, String.class); Integer length = parseCall(args[2], null, Integer.class); - - // System.out.println ("CALLING: NewArray: " + type + " " + - // length + " " - // + Signature.primitiveNameToType(type)); Object newArray = null; @@ -939,10 +906,6 @@ public class PluginAppletSecurityContext Integer classID = parseCall(args[2], null, Integer.class); Integer objectID = parseCall(args[3], null, Integer.class); - // System.out.println ("CALLING: NewObjectArray: " + - // classID + " " + length + " " - // + objectID); - Object newArray = null; newArray = Array.newInstance((Class) store.getObject(classID), length); @@ -962,12 +925,9 @@ public class PluginAppletSecurityContext final Constructor m = (Constructor) store.getObject(methodID); Class[] argTypes = m.getParameterTypes(); - // System.out.println ("NEWOBJ: HERE1"); Object[] arguments = new Object[argTypes.length]; - // System.out.println ("NEWOBJ: HERE2"); for (int i = 0; i < argTypes.length; i++) { arguments[i] = parseArgs(args[3 + i], argTypes[i]); - // System.out.println ("NEWOBJ: GOT ARG: " + arguments[i]); } final Object[] fArguments = arguments; @@ -1090,9 +1050,6 @@ public class PluginAppletSecurityContext ret = new String(byteArray, 0, bytelength, "UTF-16LE"); PluginDebug.debug("NEWSTRING: " + ret); - // System.out.println ("NEWOBJ: CALLED: " + ret); - // System.out.println ("NEWOBJ: CALLED: " + - // store.getObject(ret)); store.reference(ret); write(reference, "NewString " + store.getIdentifier(ret)); @@ -1336,106 +1293,6 @@ public class PluginAppletSecurityContext public AccessControlContext getAccessControlContext(String[] nsPrivilegeList, String src) { - /* - for (int i=0; i < nsPrivilegeList.length; i++) { - String privilege = nsPrivilegeList[i]; - - if (privilege.equals("UniversalAccept")) { - SocketPermission sp = new SocketPermission("*", "accept,resolve"); - grantedPermissions.add(sp); - } else if (privilege.equals("UniversalAwtEventQueueAccess")) { - AWTPermission awtp = new AWTPermission("accessEventQueue"); - grantedPermissions.add(awtp); - } else if (privilege.equals("UniversalConnect")) { - SocketPermission sp = new SocketPermission("*", "connect,resolve"); - grantedPermissions.add(sp); - } else if (privilege.equals("UniversalListen")) { - SocketPermission sp = new SocketPermission("*", "listen,resolve"); - grantedPermissions.add(sp); - } else if (privilege.equals("UniversalExecAccess")) { - FilePermission fp = new FilePermission("<>", "execute"); - RuntimePermission rtp = new RuntimePermission("setIO"); - grantedPermissions.add(fp); - grantedPermissions.add(rtp); - } else if (privilege.equals("UniversalExitAccess")) { - // Doesn't matter what the permissions are. Do not allow VM to exit.. we - // use a single VM for the entire browser lifecycle once invoked, we - // cannot let it exit - - //RuntimePermission rtp = new RuntimePermission("exitVM.*"); - //grantedPermissions.add(rtp); - } else if (privilege.equals("UniversalFileDelete")) { - FilePermission fp = new FilePermission("<>", "delete"); - grantedPermissions.add(fp); - } else if (privilege.equals("UniversalFileRead")) { - FilePermission fp = new FilePermission("<>", "read"); - grantedPermissions.add(fp); - } else if (privilege.equals("UniversalFileWrite")) { - FilePermission fp = new FilePermission("<>", "write"); - grantedPermissions.add(fp); - } else if (privilege.equals("UniversalFdRead")) { - RuntimePermission rtp = new RuntimePermission("readFileDescriptor"); - grantedPermissions.add(rtp); - } else if (privilege.equals("UniversalFdWrite")) { - RuntimePermission rtp = new RuntimePermission("writeFileDescriptor"); - grantedPermissions.add(rtp); - } else if (privilege.equals("UniversalLinkAccess")) { - RuntimePermission rtp = new RuntimePermission("loadLibrary.*"); - grantedPermissions.add(rtp); - } else if (privilege.equals("UniversalListen")) { - SocketPermission sp = new SocketPermission("*", "listen"); - grantedPermissions.add(sp); - } else if (privilege.equals("UniversalMulticast")) { - SocketPermission sp = new SocketPermission("*", "accept,connect,resolve"); - grantedPermissions.add(sp); - } else if (privilege.equals("UniversalPackageAccess")) { - RuntimePermission rtp = new RuntimePermission("defineClassInPackage.*"); - grantedPermissions.add(rtp); - } else if (privilege.equals("UniversalPackageDefinition")) { - RuntimePermission rtp = new RuntimePermission("accessClassInPackage.*"); - grantedPermissions.add(rtp); - } else if (privilege.equals("UniversalPrintJobAccess")) { - RuntimePermission rtp = new RuntimePermission("queuePrintJob"); - grantedPermissions.add(rtp); - } else if (privilege.equals("UniversalPropertyRead")) { - PropertyPermission pp = new PropertyPermission("*", "read"); - grantedPermissions.add(pp); - } else if (privilege.equals("UniversalPropertyWrite")) { - PropertyPermission pp = new PropertyPermission("*", "write"); - grantedPermissions.add(pp); - } else if (privilege.equals("UniversalSetFactory")) { - RuntimePermission rtp = new RuntimePermission("setFactory"); - grantedPermissions.add(rtp); - } else if (privilege.equals("UniversalSystemClipboardAccess")) { - AWTPermission awtp = new AWTPermission("accessClipboard"); - grantedPermissions.add(awtp); - } else if (privilege.equals("UniversalThreadAccess")) { - RuntimePermission rtp1 = new RuntimePermission("modifyThread"); - RuntimePermission rtp2 = new RuntimePermission("stopThread"); - grantedPermissions.add(rtp1); - grantedPermissions.add(rtp2); - } else if (privilege.equals("UniversalThreadGroupAccess")) { - RuntimePermission rtp1 = new RuntimePermission("modifyThreadGroup"); - RuntimePermission rtp2 = new RuntimePermission("modifyThread"); - RuntimePermission rtp3 = new RuntimePermission("stopThread"); - grantedPermissions.add(rtp1); - grantedPermissions.add(rtp2); - grantedPermissions.add(rtp3); - } else if (privilege.equals("UniversalTopLevelWindow")) { - AWTPermission awtp = new AWTPermission("topLevelWindow"); - grantedPermissions.add(awtp); - } else if (privilege.equals("UniversalBrowserRead")) { - BrowserReadPermission bp = new BrowserReadPermission(); - grantedPermissions.add(bp); - } else if (privilege.equals("UniversalJavaPermissions")) { - AllPermission ap = new AllPermission(); - grantedPermissions.add(ap); - } - } - - // what to do with these is unknown: UniversalConnectWithRedirect, UniversalDialogModality, UniversalSendMail, LimitedInstall, FullInstall, SilentInstall - */ - Permissions grantedPermissions = new Permissions(); for (int i = 0; i < nsPrivilegeList.length; i++) { diff -r 06940cdcfef8 -r c5b209388b54 plugin/icedteanp/java/sun/applet/PluginAppletViewer.java --- a/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java Thu Jan 20 11:06:41 2011 -0500 +++ b/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java Thu Jan 20 14:54:27 2011 -0500 @@ -836,7 +836,6 @@ public class PluginAppletViewer extends } private Image getCachedImage(URL url) { - // System.getSecurityManager().checkConnection(url.getHost(), url.getPort()); return (Image) getCachedImageRef(url).get(); } @@ -1825,18 +1824,6 @@ public class PluginAppletViewer extends static String encoding = null; - static private Reader makeReader(InputStream is) { - if (encoding != null) { - try { - return new BufferedReader(new InputStreamReader(is, encoding)); - } catch (IOException x) { - } - } - InputStreamReader r = new InputStreamReader(is); - encoding = r.getEncoding(); - return new BufferedReader(r); - } - /** * Scan an html file for tags */ @@ -1869,10 +1856,7 @@ public class PluginAppletViewer extends PrintStream statusMsgStream, PluginAppletPanelFactory factory) throws IOException { - // tag flags - boolean isAppletTag = false; boolean isObjectTag = false; - boolean isEmbedTag = false; boolean objectTagAlreadyParsed = false; // The current character @@ -1948,9 +1932,7 @@ public class PluginAppletViewer extends } } atts = null; - isAppletTag = false; isObjectTag = false; - isEmbedTag = false; } } else { String nm = scanIdentifier(c, in); @@ -1967,15 +1949,12 @@ public class PluginAppletViewer extends String val = t.get("value"); if (val == null) { statusMsgStream.println(requiresNameWarning); - } else if (atts != null) { + } else { PluginDebug.debug("PUT " + att + " = " + val); atts.put(att.toLowerCase(), val); - } else { - statusMsgStream.println(paramOutsideWarning); } } } else if (nm.equalsIgnoreCase("applet")) { - isAppletTag = true; atts = scanTag(c, in); // If there is a classid and no code tag present, transform it to code tag @@ -2055,7 +2034,6 @@ public class PluginAppletViewer extends atts.put("height", height); } } else if (nm.equalsIgnoreCase("embed")) { - isEmbedTag = true; atts = scanTag(c, in); // If there is a classid and no code tag present, transform it to code tag diff -r 06940cdcfef8 -r c5b209388b54 plugin/icedteanp/java/sun/applet/PluginCallRequest.java --- a/plugin/icedteanp/java/sun/applet/PluginCallRequest.java Thu Jan 20 11:06:41 2011 -0500 +++ b/plugin/icedteanp/java/sun/applet/PluginCallRequest.java Thu Jan 20 14:54:27 2011 -0500 @@ -36,9 +36,6 @@ exception statement from your version. * exception statement from your version. */ package sun.applet; - -import java.security.AccessControlContext; -import java.security.ProtectionDomain; // FIXME: for each type of request extend a new (anonymous?) // PluginCallRequest. diff -r 06940cdcfef8 -r c5b209388b54 plugin/icedteanp/java/sun/applet/PluginDebug.java --- a/plugin/icedteanp/java/sun/applet/PluginDebug.java Thu Jan 20 11:06:41 2011 -0500 +++ b/plugin/icedteanp/java/sun/applet/PluginDebug.java Thu Jan 20 14:54:27 2011 -0500 @@ -37,8 +37,6 @@ exception statement from your version. * package sun.applet; -import java.io.*; - public class PluginDebug { static final boolean DEBUG = System.getenv().containsKey("ICEDTEAPLUGIN_DEBUG"); diff -r 06940cdcfef8 -r c5b209388b54 plugin/icedteanp/java/sun/applet/PluginMessageConsumer.java --- a/plugin/icedteanp/java/sun/applet/PluginMessageConsumer.java Thu Jan 20 11:06:41 2011 -0500 +++ b/plugin/icedteanp/java/sun/applet/PluginMessageConsumer.java Thu Jan 20 14:54:27 2011 -0500 @@ -41,7 +41,6 @@ import java.util.Hashtable; import java.util.Hashtable; import java.util.Iterator; import java.util.LinkedList; -import java.util.Set; class PluginMessageConsumer { @@ -107,17 +106,6 @@ class PluginMessageConsumer { } } - /** - * Returns the reference for this message. This method assumes that - * the message has a reference number. - * - * @param The message - * @return the reference number - */ - private Long getReference(String[] msgParts) { - return Long.parseLong(msgParts[3]); - } - public PluginMessageConsumer(PluginStreamHandler streamHandler) { as = new AppletSecurity(); @@ -142,10 +130,6 @@ class PluginMessageConsumer { } return null; - } - - private boolean isInInit(Integer instanceNum) { - return initWorkers.containsKey(instanceNum); } private void addToInitWorkers(Integer instanceNum, PluginMessageHandlerWorker worker) { From asu at redhat.com Thu Jan 20 11:55:26 2011 From: asu at redhat.com (Andrew Su) Date: Thu, 20 Jan 2011 14:55:26 -0500 (EST) Subject: [RFC][IcedTea-Web]: Removing dead unused commented code In-Reply-To: <20110120150055.GB4611@rivendell.middle-earth.co.uk> Message-ID: <297763785.48011.1295553326663.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> ----- Original Message ----- > From: "Dr Andrew John Hughes" > To: "Andrew Su" , "OpenJDK" > Sent: Thursday, January 20, 2011 10:00:55 AM > Subject: Re: [RFC][IcedTea-Web]: Removing dead unused commented code > On 23:31 Thu 13 Jan , Dr Andrew John Hughes wrote: > > On 18:19 Thu 13 Jan , Andrew Su wrote: > > > Hello, > > > > > > This patch is an attempt to remove dead, unused or commented code > > > from the plugin directory in icedtea-web. > > > > > > (I have provided the patch for each file separately for easier > > > reading.) > > > > > > Some comments though.. > > > General Note: > > > Changed the copyright to be 2011 for all the modified files. > > > > > > > The copyright updates should extend the range, not remove the > > original. > > So: > > > > > - Copyright (C) 2008 Red Hat > > > + Copyright (C) 2011 Red Hat > > > > becomes > > > > - Copyright (C) 2008 Red Hat > > + Copyright (C) 2008, 2011 Red Hat > > > > Also I'm not sure removing code is worth a copyright update. > > > > > These are the methods that will be removed with the patch (unused > > > private methods) > > > PluginMessageConsumer.java:getReference(String[]) > > > PluginMessageConsumer.java:isInInit(Integer) > > > PluginMessageConsumer.java:dumpWorkerStatus() > > > PluginAppletViewer.java:makeReader(InputStream) > > > PluginMessageConsumer.java:getReference(String[]) > > > PluginMessageConsumer.java:isInInit(Integer) > > > PluginMessageConsumer.java:dumpWorkerStatus() > > > > > > In the following method, will we be needing this block of > > > commented out conditions in the future? > > > PluginAppletSecurityContext.java:getAccessControlContext(String[], > > > String) > > > > > > > > > I have tried building it and that succeeds. Tested running some > > > simple applets and those seem to work as well. > > > > > > Questions comments concerns? > > > > > > Regards, > > > Andrew > > > > > > The copyright doesn't need updating for these modifications (as they > only remove code), but the files > probably do need a general update so that the year of latest > modification is used. Please do this > as a separate patch. > > I approve the removal of dead code without the copyright changes. --snip-- Thanks for looking it over! I have pushed the patch minus the copyright changes. http://icedtea.classpath.org/hg/icedtea-web/rev/c5b209388b54 Cheers, Andrew From omajid at redhat.com Thu Jan 20 12:57:04 2011 From: omajid at redhat.com (Omair Majid) Date: Thu, 20 Jan 2011 15:57:04 -0500 Subject: [icedtea-web] RFC: add binaries to jre/bin as well (was backport changeset 9397074c2c39 to icedtea-web 1.0) In-Reply-To: <20110120191542.GE18293@redhat.com> References: <4D387505.9090305@redhat.com> <20110120175752.GC18293@redhat.com> <20110120181821.GD18293@redhat.com> <4D388120.1030802@redhat.com> <20110120191542.GE18293@redhat.com> Message-ID: <4D38A1A0.6040501@redhat.com> On 01/20/2011 02:15 PM, Deepak Bhole wrote: > * Omair Majid [2011-01-20 13:38]: >> On 01/20/2011 01:18 PM, Deepak Bhole wrote: >>> * Deepak Bhole [2011-01-20 12:59]: >>>> * Omair Majid [2011-01-20 12:46]: >>>>> I would like to backport changeset 9397074c2c39 from icedtea-web >>>>> HEAD to icedtea-web 1.0. >>>> >>>> The binary in jre/bin should be the actual file, not the one in >>>> JAVA_HOME/bin. JAVA_HOME/bin is optional and installed as part of the >>>> JDK. However the JRE (and all the components therein) should be >>>> independently runnable. >>>> >>> >>> Something else just came to mind... the change to Launcher.java should >>> be reverted. The patches changes the code to use java.icedtea-web.bin >>> which is defined at build time. This makes the build un-relocatable. >>> java.home is the right property to use in this situation. >>> >> >> I didn't realize there were these issues with the patch, thanks for >> pointing them out. >> >> From what I understand, we want two (possibly different) binaries in >> two locations such that the two binaries dont depend on each other? >> Or can $JDK/bin/javaws assume that $JDK/jre/bin/javaws exists? >> > > Hmm, the JRE is a subset of the JDK (atleast in all RPM installations > I've seen). However it seems that files are always duplicated across > JAVA_HOME/bin and JAVA_HOME/jre/bin rather than linked. Perhaps this was > to maintain consistency with Windows (which doesn't have symlinks) but I > am unsure. > > Either way, perhaps we should maintain consistency and duplicate the > files as well. > Done. Please see the attached patch. >> Also, how does this address the issue where $(prefix) is not a JDK >> folder (as pointed out by Andrew Hughes while he was reviewing the >> original patch [1]). >> > > I think Andrew's suggestion is correct, that jre/bin/javaws should only > be installed if prefix/jre/bin exists. > Right. But he also talks about how $(prefix) may not be a JDK. In which case there is no $JAVA_HOME there. But then again, I have no clue how our launcher deals with that situation either. > Btw, we might have to build binaries for JAVA_HOME/jre/bin and for > JAVA_HOME/bin separately with different args as the binaries rely on > relative paths to find libjvm.so -- I haven't looked into it in detail, > but please keep that in mind when re-working the patch. > The attached patch hacks the launcher so it simply passes along argv[0] to Netx as the system property "java.icedtea-web.bin". Netx can then run itself by running the value of this system property. Can you please look over the patch to see if it makes sense? Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: binaries-in-jre.patch Type: text/x-patch Size: 3424 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110120/68ae505e/binaries-in-jre.patch From dbhole at redhat.com Thu Jan 20 15:56:20 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Thu, 20 Jan 2011 18:56:20 -0500 Subject: [icedtea-web] RFE: Fix for broken JRE dir install Message-ID: <20110120235619.GA22586@redhat.com> Hi, Currently, installation to a jre directory is broken in both HEAD and 1.0. Installing to j2re-image for example will end up creating jre-image/jre/lib which is incorrect (files should go into j2re-image/lib in this case). Attached patch fixes it so that install to both, jre and jdk works and as does uninstall. It also makes javaws and itweb-setings actual files (similar to 'java' and other binaries which are copied to JDK_HOME/bin and JDK_HOME/jre/bin rather than being symlinked) and makes sure that javaws can be called from either location and that it works. ChangeLog: 2011-01-20 Deepak Bhole * Makefile.am (install-exec-local): Use new JRE_DIR_PREFIX variables rather than hardcoded '/jre' in pathname. Copy javaws and itweb-settings rather than symlinking. (install-data-local): Use new JRE_DIR_PREFIX variables rather than jardcoded '/jre' in pathname. (uninstall-local): Same. Also, remove all parent dirs of $(htmldir) until a non-empty one is encountered. * configure.ac: Set JRE_DIR_PREFIX to jre/ if prefix is a JDK dir and set it to empty if prefix apears to be a JRE dir. * netx/net/sourceforge/jnlp/Launcher.java (launchExternal): Revert back to using java.home when selecting javaws binary to execute for fork. Note: This should be backported to 1.0 after 9397074c2c39 is. Please see this for rationale: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011806.html I have tested this considerably to make sure nothing is broken, but if anyone feels the scope of this patch is too much for 1.0 this close to release (I was hoping to tag today but looks like it will have to be tomorrow now), I can post a separate path for 1.0 that only addresses the issues mentioned in the thread above. Cheers, Deepak -------------- next part -------------- diff -r 06940cdcfef8 Makefile.am --- a/Makefile.am Thu Jan 20 11:06:41 2011 -0500 +++ b/Makefile.am Thu Jan 20 18:47:48 2011 -0500 @@ -103,37 +103,37 @@ clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs install-exec-local: - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) if ENABLE_PLUGIN - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar endif - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ + if [ -e $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ fi ; \ if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ fi ; \ fi - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ + if [ -e $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ fi ; \ if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ + cp -a $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin ; \ fi ; \ fi install-data-local: ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib if ENABLE_DOCS ${mkinstalldirs} $(DESTDIR)$(htmldir) (cd ${abs_top_builddir}/docs/netx; \ @@ -151,23 +151,25 @@ endif uninstall-local: - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 rm -f $(DESTDIR)$(bindir)/pluginappletviewer rm -f $(DESTDIR)$(bindir)/javaws - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ + if [ -e $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ fi - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws rm -f $(DESTDIR)$(bindir)/itweb-settings - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ + if [ -e $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ fi - rm -rf $(DESTDIR)$(htmldir) + rm -rf $(DESTDIR)$(htmldir)/* + if [ -d $(DESTDIR)$(htmldir) ] ; then \ + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ + fi # Plugin @@ -350,7 +352,7 @@ $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c mkdir -p $(NETX_DIR)/launcher && \ $(CC) $(LAUNCHER_FLAGS) \ - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ -DPROGNAME='"javaws"' -c -o $@ $< $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c diff -r 06940cdcfef8 configure.ac --- a/configure.ac Thu Jan 20 11:06:41 2011 -0500 +++ b/configure.ac Thu Jan 20 18:47:48 2011 -0500 @@ -80,4 +80,12 @@ IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE +# Set JRE prefix based on weather to-level prefix is a JDK dir or a JRE dir +if test -d ${prefix}/jre ; then + JRE_DIR_PREFIX="/jre" ; +else + JRE_DIR_PREFIX="" ; +fi ; +AC_SUBST([JRE_DIR_PREFIX]) + AC_OUTPUT diff -r 06940cdcfef8 netx/net/sourceforge/jnlp/Launcher.java --- a/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 11:06:41 2011 -0500 +++ b/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 18:47:48 2011 -0500 @@ -327,7 +327,12 @@ List commands = new LinkedList(); // this property is set by the javaws launcher to point to the javaws binary - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); + String pathToWebstartBinary = System.getProperty("java.home") + + File.separatorChar + + "bin" + + File.separatorChar + + "javaws"; + commands.add(pathToWebstartBinary); // use -Jargument format to pass arguments to the JVM through the launcher for (String arg : vmArgs) { From dbhole at redhat.com Thu Jan 20 15:59:36 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Thu, 20 Jan 2011 18:59:36 -0500 Subject: [icedtea-web] RFC: add binaries to jre/bin as well (was backport changeset 9397074c2c39 to icedtea-web 1.0) In-Reply-To: <4D38A1A0.6040501@redhat.com> References: <4D387505.9090305@redhat.com> <20110120175752.GC18293@redhat.com> <20110120181821.GD18293@redhat.com> <4D388120.1030802@redhat.com> <20110120191542.GE18293@redhat.com> <4D38A1A0.6040501@redhat.com> Message-ID: <20110120235936.GB22586@redhat.com> * Omair Majid [2011-01-20 15:57]: > On 01/20/2011 02:15 PM, Deepak Bhole wrote: > >* Omair Majid [2011-01-20 13:38]: > >>On 01/20/2011 01:18 PM, Deepak Bhole wrote: > >>>* Deepak Bhole [2011-01-20 12:59]: > >>>>* Omair Majid [2011-01-20 12:46]: > >>>>>I would like to backport changeset 9397074c2c39 from icedtea-web > >>>>>HEAD to icedtea-web 1.0. > >>>> > >>>>The binary in jre/bin should be the actual file, not the one in > >>>>JAVA_HOME/bin. JAVA_HOME/bin is optional and installed as part of the > >>>>JDK. However the JRE (and all the components therein) should be > >>>>independently runnable. > >>>> > >>> > >>>Something else just came to mind... the change to Launcher.java should > >>>be reverted. The patches changes the code to use java.icedtea-web.bin > >>>which is defined at build time. This makes the build un-relocatable. > >>>java.home is the right property to use in this situation. > >>> > >> > >>I didn't realize there were these issues with the patch, thanks for > >>pointing them out. > >> > >> From what I understand, we want two (possibly different) binaries in > >>two locations such that the two binaries dont depend on each other? > >>Or can $JDK/bin/javaws assume that $JDK/jre/bin/javaws exists? > >> > > > >Hmm, the JRE is a subset of the JDK (atleast in all RPM installations > >I've seen). However it seems that files are always duplicated across > >JAVA_HOME/bin and JAVA_HOME/jre/bin rather than linked. Perhaps this was > >to maintain consistency with Windows (which doesn't have symlinks) but I > >am unsure. > > > >Either way, perhaps we should maintain consistency and duplicate the > >files as well. > > > > Done. Please see the attached patch. > > >>Also, how does this address the issue where $(prefix) is not a JDK > >>folder (as pointed out by Andrew Hughes while he was reviewing the > >>original patch [1]). > >> > > > >I think Andrew's suggestion is correct, that jre/bin/javaws should only > >be installed if prefix/jre/bin exists. > > > > Right. But he also talks about how $(prefix) may not be a JDK. In > which case there is no $JAVA_HOME there. But then again, I have no > clue how our launcher deals with that situation either. > > >Btw, we might have to build binaries for JAVA_HOME/jre/bin and for > >JAVA_HOME/bin separately with different args as the binaries rely on > >relative paths to find libjvm.so -- I haven't looked into it in detail, > >but please keep that in mind when re-working the patch. > > > > The attached patch hacks the launcher so it simply passes along > argv[0] to Netx as the system property "java.icedtea-web.bin". Netx > can then run itself by running the value of this system property. > > Can you please look over the patch to see if it makes sense? > I don't think it needs to be that complex (modifying the .c files and all). Please see the patch I just posted in this thread: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011814.html It is against HEAD and mitigates this issue. If approved, I can push it into 1.0 after 9397074c2c39, otherwise I will post a subset thereof. Cheers, Deepak > Cheers, > Omair > diff -r 06940cdcfef8 Makefile.am > --- a/Makefile.am Thu Jan 20 11:06:41 2011 -0500 > +++ b/Makefile.am Thu Jan 20 15:45:48 2011 -0500 > @@ -112,22 +112,12 @@ > ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > - fi ; \ > - if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > - fi ; \ > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > fi > ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > - fi ; \ > - if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > - fi ; \ > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > fi > > install-data-local: > @@ -159,12 +149,11 @@ > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > rm -f $(DESTDIR)$(bindir)/javaws > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > + if [ -e $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > fi > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > rm -f $(DESTDIR)$(bindir)/itweb-settings > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > + if [ -e $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > fi > rm -rf $(DESTDIR)$(htmldir) > @@ -350,8 +339,8 @@ > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > mkdir -p $(NETX_DIR)/launcher && \ > $(CC) $(LAUNCHER_FLAGS) \ > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > - -DPROGNAME='"javaws"' -c -o $@ $< > + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ > + -DPROGNAME='"javaws"' -DICEDTEA_WEB_BIN -c -o $@ $< > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > mkdir -p $(NETX_DIR)/launcher/controlpanel && \ > diff -r 06940cdcfef8 launcher/java.c > --- a/launcher/java.c Thu Jan 20 11:06:41 2011 -0500 > +++ b/launcher/java.c Thu Jan 20 15:45:48 2011 -0500 > @@ -288,6 +288,10 @@ > launchername = progname; > #endif /* LAUNCHER_NAME */ > > +#ifdef ICEDTEA_WEB_BIN > + SetIcedTeaWebProp(argc, argv); > +#endif > + > ++argv; > --argc; > > @@ -1654,6 +1658,21 @@ > } > > /* > + * IcedTea-Web Hack > + * > + * This method sets the value of the system property java.icedtea-web.bin to > + * argv[0] of this process. This allows an icedtea-web app to exec itself by > + * exec'ing the value of System.getProperty("java.icedtea-web.bin") > + */ > +void SetIcedTeaWebProp(int argc, char** argv) { > + char* property = "-Djava.icedtea-web.bin="; > + char* s = JLI_MemAlloc(strlen(property) + strlen(argv[0])); > + strcat(s,property); > + strcat(s,argv[0]); > + AddOption(s, NULL); > +} > + > +/* > * Prints the version information from the java.version and other properties. > */ > static void From ahughes at redhat.com Thu Jan 20 16:22:25 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 21 Jan 2011 00:22:25 +0000 Subject: [icedtea-web] RFE: Fix for broken JRE dir install In-Reply-To: <20110120235619.GA22586@redhat.com> References: <20110120235619.GA22586@redhat.com> Message-ID: <20110121002225.GD4611@rivendell.middle-earth.co.uk> On 18:56 Thu 20 Jan , Deepak Bhole wrote: > Hi, > > Currently, installation to a jre directory is broken in both HEAD and > 1.0. Installing to j2re-image for example will end up creating > jre-image/jre/lib which is incorrect (files should go into > j2re-image/lib in this case). > > Attached patch fixes it so that install to both, jre and jdk works and > as does uninstall. It also makes javaws and itweb-setings actual files > (similar to 'java' and other binaries which are copied to JDK_HOME/bin > and JDK_HOME/jre/bin rather than being symlinked) and makes sure that > javaws can be called from either location and that it works. > > ChangeLog: > 2011-01-20 Deepak Bhole > > * Makefile.am > (install-exec-local): Use new JRE_DIR_PREFIX variables rather than > hardcoded '/jre' in pathname. Copy javaws and itweb-settings rather than > symlinking. > (install-data-local): Use new JRE_DIR_PREFIX variables rather than > jardcoded '/jre' in pathname. > (uninstall-local): Same. Also, remove all parent dirs of $(htmldir) until > a non-empty one is encountered. > * configure.ac: Set JRE_DIR_PREFIX to jre/ if prefix is a JDK dir and set > it to empty if prefix apears to be a JRE dir. > * netx/net/sourceforge/jnlp/Launcher.java (launchExternal): Revert back to > using java.home when selecting javaws binary to execute for fork. > > > Note: This should be backported to 1.0 after 9397074c2c39 is. Please see this > for rationale: > http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011806.html > > I have tested this considerably to make sure nothing is broken, but if > anyone feels the scope of this patch is too much for 1.0 this close to > release (I was hoping to tag today but looks like it will have to be > tomorrow now), I can post a separate path for 1.0 that only addresses > the issues mentioned in the thread above. > > Cheers, > Deepak Ok, number of points: * Why do we need to have duplicate copies? What is wrong with the symlink? We discussed this previously and no objections were raised at the time. * Why the change to the htmldir deletion? How does rm -rf fail? I don't think this long option to rmdir should be used as I doubt it is standard. * Using java.home breaks installation outside a JDK tree. See previous discussion. That's why icedtea.web.bin was introduced. * Typo: whether not weather. > diff -r 06940cdcfef8 Makefile.am > --- a/Makefile.am Thu Jan 20 11:06:41 2011 -0500 > +++ b/Makefile.am Thu Jan 20 18:47:48 2011 -0500 > @@ -103,37 +103,37 @@ > clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs > > install-exec-local: > - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) > + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > if ENABLE_PLUGIN > - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ > + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) > - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > endif > - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > + if [ -e $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > fi ; \ > if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > fi ; \ > fi > - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > + if [ -e $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > fi ; \ > if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > + cp -a $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin ; \ > fi ; \ > fi > > install-data-local: > ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 > ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 > - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib > + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > if ENABLE_DOCS > ${mkinstalldirs} $(DESTDIR)$(htmldir) > (cd ${abs_top_builddir}/docs/netx; \ > @@ -151,23 +151,25 @@ > endif > > uninstall-local: > - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar > - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > rm -f $(DESTDIR)$(bindir)/javaws > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > + if [ -e $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > fi > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > rm -f $(DESTDIR)$(bindir)/itweb-settings > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > + if [ -e $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > fi > - rm -rf $(DESTDIR)$(htmldir) > + rm -rf $(DESTDIR)$(htmldir)/* > + if [ -d $(DESTDIR)$(htmldir) ] ; then \ > + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ > + fi > > # Plugin > > @@ -350,7 +352,7 @@ > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > mkdir -p $(NETX_DIR)/launcher && \ > $(CC) $(LAUNCHER_FLAGS) \ > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ > -DPROGNAME='"javaws"' -c -o $@ $< > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > diff -r 06940cdcfef8 configure.ac > --- a/configure.ac Thu Jan 20 11:06:41 2011 -0500 > +++ b/configure.ac Thu Jan 20 18:47:48 2011 -0500 > @@ -80,4 +80,12 @@ > IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) > IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE > > +# Set JRE prefix based on weather to-level prefix is a JDK dir or a JRE dir > +if test -d ${prefix}/jre ; then > + JRE_DIR_PREFIX="/jre" ; > +else > + JRE_DIR_PREFIX="" ; > +fi ; > +AC_SUBST([JRE_DIR_PREFIX]) > + > AC_OUTPUT > diff -r 06940cdcfef8 netx/net/sourceforge/jnlp/Launcher.java > --- a/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 11:06:41 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 18:47:48 2011 -0500 > @@ -327,7 +327,12 @@ > List commands = new LinkedList(); > > // this property is set by the javaws launcher to point to the javaws binary > - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); > + String pathToWebstartBinary = System.getProperty("java.home") + > + File.separatorChar + > + "bin" + > + File.separatorChar + > + "javaws"; > + > commands.add(pathToWebstartBinary); > // use -Jargument format to pass arguments to the JVM through the launcher > for (String arg : vmArgs) { -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From dbhole at redhat.com Thu Jan 20 16:27:13 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Thu, 20 Jan 2011 19:27:13 -0500 Subject: Patch to make icedtea-web work with icedtea Message-ID: <20110121002713.GC22586@redhat.com> Hi, Unlike icedtea6, icedtea currently does not append plugin.jar and netx.jar to the default boot classpath. Attached patch makes it so that like icedtea6, the bootclasspath update is moved to a separate patch which updates for rhino, netx and plugin. After applying this patch, icedtea-web works correctly with icedtea. Cheers, Deepak -------------- next part -------------- diff -r 93ac4fddecf3 Makefile.am --- a/Makefile.am Fri Dec 10 13:43:00 2010 +0000 +++ b/Makefile.am Thu Jan 20 19:19:28 2011 -0500 @@ -303,7 +303,8 @@ patches/no-precompiled.patch \ patches/parisc.patch \ patches/sh4-support.patch \ - patches/jtreg-httpTest.patch + patches/jtreg-httpTest.patch \ + patches/hotspot/$(HSBUILD)/icedtea-update-bootclasspath.patch # Conditional patches diff -r 93ac4fddecf3 patches/hotspot/default/icedtea-update-bootclasspath.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/hotspot/default/icedtea-update-bootclasspath.patch Thu Jan 20 19:19:28 2011 -0500 @@ -0,0 +1,13 @@ +diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/os.cpp openjdk/hotspot/src/share/vm/runtime/os.cpp +--- openjdk.orig/hotspot/src/share/vm/runtime/os.cpp 2010-09-01 01:23:45.000000000 +0100 ++++ openjdk/hotspot/src/share/vm/runtime/os.cpp 2010-09-19 17:34:30.859345954 +0100 +@@ -1032,6 +1032,9 @@ + "%/lib/jsse.jar:" + "%/lib/jce.jar:" + "%/lib/charsets.jar:" ++ "%/lib/netx.jar:" ++ "%/lib/plugin.jar:" ++ "%/lib/rhino.jar:" + + // ## TEMPORARY hack to keep the legacy launcher working when + // ## only the boot module is installed (cf. j.l.ClassLoader) diff -r 93ac4fddecf3 patches/icedtea-rhino.patch --- a/patches/icedtea-rhino.patch Fri Dec 10 13:43:00 2010 +0000 +++ b/patches/icedtea-rhino.patch Thu Jan 20 19:19:28 2011 -0500 @@ -1,16 +1,3 @@ -diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/os.cpp openjdk/hotspot/src/share/vm/runtime/os.cpp ---- openjdk.orig/hotspot/src/share/vm/runtime/os.cpp 2010-08-27 19:15:27.000000000 +0100 -+++ openjdk/hotspot/src/share/vm/runtime/os.cpp 2010-09-01 18:12:38.850408989 +0100 -@@ -1033,6 +1033,9 @@ - "%/lib/jce.jar:" - "%/lib/charsets.jar:" - -+ // IcedTea addition to support Rhino via javax.script -+ "%/lib/rhino.jar:" -+ - // ## TEMPORARY hack to keep the legacy launcher working when - // ## only the boot module is installed (cf. j.l.ClassLoader) - "%/lib/modules/jdk.boot.jar:" diff -Nru openjdk.orig/jdk/make/com/sun/Makefile openjdk/jdk/make/com/sun/Makefile --- openjdk.orig/jdk/make/com/sun/Makefile 2010-07-29 21:55:26.000000000 +0100 +++ openjdk/jdk/make/com/sun/Makefile 2010-09-01 18:08:22.164610031 +0100 From ahughes at redhat.com Thu Jan 20 16:33:24 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 21 Jan 2011 00:33:24 +0000 Subject: Patch to make icedtea-web work with icedtea In-Reply-To: <20110121002713.GC22586@redhat.com> References: <20110121002713.GC22586@redhat.com> Message-ID: <20110121003324.GE4611@rivendell.middle-earth.co.uk> On 19:27 Thu 20 Jan , Deepak Bhole wrote: > Hi, > > Unlike icedtea6, icedtea currently does not append plugin.jar and > netx.jar to the default boot classpath. > > Attached patch makes it so that like icedtea6, the bootclasspath update > is moved to a separate patch which updates for rhino, netx and plugin. > > After applying this patch, icedtea-web works correctly with icedtea. > > Cheers, > Deepak Doesn't this need to be conditional on Rhino being installed? Also please just use patches. IcedTea7 only supports one HotSpot version. > diff -r 93ac4fddecf3 Makefile.am > --- a/Makefile.am Fri Dec 10 13:43:00 2010 +0000 > +++ b/Makefile.am Thu Jan 20 19:19:28 2011 -0500 > @@ -303,7 +303,8 @@ > patches/no-precompiled.patch \ > patches/parisc.patch \ > patches/sh4-support.patch \ > - patches/jtreg-httpTest.patch > + patches/jtreg-httpTest.patch \ > + patches/hotspot/$(HSBUILD)/icedtea-update-bootclasspath.patch > > # Conditional patches > > diff -r 93ac4fddecf3 patches/hotspot/default/icedtea-update-bootclasspath.patch > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/patches/hotspot/default/icedtea-update-bootclasspath.patch Thu Jan 20 19:19:28 2011 -0500 > @@ -0,0 +1,13 @@ > +diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/os.cpp openjdk/hotspot/src/share/vm/runtime/os.cpp > +--- openjdk.orig/hotspot/src/share/vm/runtime/os.cpp 2010-09-01 01:23:45.000000000 +0100 > ++++ openjdk/hotspot/src/share/vm/runtime/os.cpp 2010-09-19 17:34:30.859345954 +0100 > +@@ -1032,6 +1032,9 @@ > + "%/lib/jsse.jar:" > + "%/lib/jce.jar:" > + "%/lib/charsets.jar:" > ++ "%/lib/netx.jar:" > ++ "%/lib/plugin.jar:" > ++ "%/lib/rhino.jar:" > + > + // ## TEMPORARY hack to keep the legacy launcher working when > + // ## only the boot module is installed (cf. j.l.ClassLoader) > diff -r 93ac4fddecf3 patches/icedtea-rhino.patch > --- a/patches/icedtea-rhino.patch Fri Dec 10 13:43:00 2010 +0000 > +++ b/patches/icedtea-rhino.patch Thu Jan 20 19:19:28 2011 -0500 > @@ -1,16 +1,3 @@ > -diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/os.cpp openjdk/hotspot/src/share/vm/runtime/os.cpp > ---- openjdk.orig/hotspot/src/share/vm/runtime/os.cpp 2010-08-27 19:15:27.000000000 +0100 > -+++ openjdk/hotspot/src/share/vm/runtime/os.cpp 2010-09-01 18:12:38.850408989 +0100 > -@@ -1033,6 +1033,9 @@ > - "%/lib/jce.jar:" > - "%/lib/charsets.jar:" > - > -+ // IcedTea addition to support Rhino via javax.script > -+ "%/lib/rhino.jar:" > -+ > - // ## TEMPORARY hack to keep the legacy launcher working when > - // ## only the boot module is installed (cf. j.l.ClassLoader) > - "%/lib/modules/jdk.boot.jar:" > diff -Nru openjdk.orig/jdk/make/com/sun/Makefile openjdk/jdk/make/com/sun/Makefile > --- openjdk.orig/jdk/make/com/sun/Makefile 2010-07-29 21:55:26.000000000 +0100 > +++ openjdk/jdk/make/com/sun/Makefile 2010-09-01 18:08:22.164610031 +0100 -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From dbhole at redhat.com Thu Jan 20 16:37:24 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Thu, 20 Jan 2011 19:37:24 -0500 Subject: [icedtea-web] RFE: Fix for broken JRE dir install In-Reply-To: <20110121002225.GD4611@rivendell.middle-earth.co.uk> References: <20110120235619.GA22586@redhat.com> <20110121002225.GD4611@rivendell.middle-earth.co.uk> Message-ID: <20110121003724.GD22586@redhat.com> * Dr Andrew John Hughes [2011-01-20 19:22]: > On 18:56 Thu 20 Jan , Deepak Bhole wrote: > > Hi, > > > > Currently, installation to a jre directory is broken in both HEAD and > > 1.0. Installing to j2re-image for example will end up creating > > jre-image/jre/lib which is incorrect (files should go into > > j2re-image/lib in this case). > > > > Attached patch fixes it so that install to both, jre and jdk works and > > as does uninstall. It also makes javaws and itweb-setings actual files > > (similar to 'java' and other binaries which are copied to JDK_HOME/bin > > and JDK_HOME/jre/bin rather than being symlinked) and makes sure that > > javaws can be called from either location and that it works. > > > > ChangeLog: > > 2011-01-20 Deepak Bhole > > > > * Makefile.am > > (install-exec-local): Use new JRE_DIR_PREFIX variables rather than > > hardcoded '/jre' in pathname. Copy javaws and itweb-settings rather than > > symlinking. > > (install-data-local): Use new JRE_DIR_PREFIX variables rather than > > jardcoded '/jre' in pathname. > > (uninstall-local): Same. Also, remove all parent dirs of $(htmldir) until > > a non-empty one is encountered. > > * configure.ac: Set JRE_DIR_PREFIX to jre/ if prefix is a JDK dir and set > > it to empty if prefix apears to be a JRE dir. > > * netx/net/sourceforge/jnlp/Launcher.java (launchExternal): Revert back to > > using java.home when selecting javaws binary to execute for fork. > > > > > > Note: This should be backported to 1.0 after 9397074c2c39 is. Please see this > > for rationale: > > http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011806.html > > > > I have tested this considerably to make sure nothing is broken, but if > > anyone feels the scope of this patch is too much for 1.0 this close to > > release (I was hoping to tag today but looks like it will have to be > > tomorrow now), I can post a separate path for 1.0 that only addresses > > the issues mentioned in the thread above. > > > > Cheers, > > Deepak > > Ok, number of points: > > * Why do we need to have duplicate copies? What is wrong with the symlink? > We discussed this previously and no objections were raised at the time. I have no objections to symlink. I was just trying to mimic what the default upstream openjdk install does with its binaries. I am fine with symlinking too. > * Why the change to the htmldir deletion? How does rm -rf fail? I don't > think this long option to rmdir should be used as I doubt it is standard. We create a JDK_HOME/share/... dir. By default there is no share/ dir in JDK_HOME. I think an uninstall should attempt to remove _everything_ it creates, and hence the rmdir -p which attempts to remove the dir and its parents all the way to the top (until it encounters a non-empty dir). > * Using java.home breaks installation outside a JDK tree. See previous > discussion. That's why icedtea.web.bin was introduced. I was unable to reproduce such breakage after this patch. http://download.oracle.com/javase/tutorial/essential/environment/sysprop.html states that java.home is the jre install dir (and this is true even if javaws is invoked from JDK_HOME/bin rather than JDK_HOME/jre/bin). Assuming jre/bin contains the actual file, java.home/bin/javaws will always exist and work regardless of where javaws was called from. > * Typo: whether not weather. > Doh! Thanks. Cheers, Deepak > > diff -r 06940cdcfef8 Makefile.am > > --- a/Makefile.am Thu Jan 20 11:06:41 2011 -0500 > > +++ b/Makefile.am Thu Jan 20 18:47:48 2011 -0500 > > @@ -103,37 +103,37 @@ > > clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs > > > > install-exec-local: > > - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) > > + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > > if ENABLE_PLUGIN > > - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ > > + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ > > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) > > - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > endif > > - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > > + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > fi ; \ > > if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > fi ; \ > > fi > > - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > > + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > fi ; \ > > if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > > - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > > + cp -a $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin ; \ > > fi ; \ > > fi > > > > install-data-local: > > ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 > > ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 > > - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib > > + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > if ENABLE_DOCS > > ${mkinstalldirs} $(DESTDIR)$(htmldir) > > (cd ${abs_top_builddir}/docs/netx; \ > > @@ -151,23 +151,25 @@ > > endif > > > > uninstall-local: > > - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar > > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > > rm -f $(DESTDIR)$(bindir)/javaws > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > fi > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > > rm -f $(DESTDIR)$(bindir)/itweb-settings > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > fi > > - rm -rf $(DESTDIR)$(htmldir) > > + rm -rf $(DESTDIR)$(htmldir)/* > > + if [ -d $(DESTDIR)$(htmldir) ] ; then \ > > + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ > > + fi > > > > # Plugin > > > > @@ -350,7 +352,7 @@ > > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > > mkdir -p $(NETX_DIR)/launcher && \ > > $(CC) $(LAUNCHER_FLAGS) \ > > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > > + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ > > -DPROGNAME='"javaws"' -c -o $@ $< > > > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > > diff -r 06940cdcfef8 configure.ac > > --- a/configure.ac Thu Jan 20 11:06:41 2011 -0500 > > +++ b/configure.ac Thu Jan 20 18:47:48 2011 -0500 > > @@ -80,4 +80,12 @@ > > IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) > > IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE > > > > +# Set JRE prefix based on weather to-level prefix is a JDK dir or a JRE dir > > +if test -d ${prefix}/jre ; then > > + JRE_DIR_PREFIX="/jre" ; > > +else > > + JRE_DIR_PREFIX="" ; > > +fi ; > > +AC_SUBST([JRE_DIR_PREFIX]) > > + > > AC_OUTPUT > > diff -r 06940cdcfef8 netx/net/sourceforge/jnlp/Launcher.java > > --- a/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 11:06:41 2011 -0500 > > +++ b/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 18:47:48 2011 -0500 > > @@ -327,7 +327,12 @@ > > List commands = new LinkedList(); > > > > // this property is set by the javaws launcher to point to the javaws binary > > - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); > > + String pathToWebstartBinary = System.getProperty("java.home") + > > + File.separatorChar + > > + "bin" + > > + File.separatorChar + > > + "javaws"; > > + > > commands.add(pathToWebstartBinary); > > // use -Jargument format to pass arguments to the JVM through the launcher > > for (String arg : vmArgs) { > > > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From dbhole at redhat.com Thu Jan 20 16:39:32 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Thu, 20 Jan 2011 19:39:32 -0500 Subject: Patch to make icedtea-web work with icedtea In-Reply-To: <20110121003324.GE4611@rivendell.middle-earth.co.uk> References: <20110121002713.GC22586@redhat.com> <20110121003324.GE4611@rivendell.middle-earth.co.uk> Message-ID: <20110121003932.GE22586@redhat.com> * Dr Andrew John Hughes [2011-01-20 19:33]: > On 19:27 Thu 20 Jan , Deepak Bhole wrote: > > Hi, > > > > Unlike icedtea6, icedtea currently does not append plugin.jar and > > netx.jar to the default boot classpath. > > > > Attached patch makes it so that like icedtea6, the bootclasspath update > > is moved to a separate patch which updates for rhino, netx and plugin. > > > > After applying this patch, icedtea-web works correctly with icedtea. > > > > Cheers, > > Deepak > > Doesn't this need to be conditional on Rhino being installed? > Having a jar that doesn't exist in the classpath has no ill effect. In icedtea6 we do the same thing, rhino is always on classpath whether it is enabled or disabled. > Also please just use patches. IcedTea7 only supports one HotSpot version. > Ah sorry, I wasn't aware of that. Cheers, Deepak > > diff -r 93ac4fddecf3 Makefile.am > > --- a/Makefile.am Fri Dec 10 13:43:00 2010 +0000 > > +++ b/Makefile.am Thu Jan 20 19:19:28 2011 -0500 > > @@ -303,7 +303,8 @@ > > patches/no-precompiled.patch \ > > patches/parisc.patch \ > > patches/sh4-support.patch \ > > - patches/jtreg-httpTest.patch > > + patches/jtreg-httpTest.patch \ > > + patches/hotspot/$(HSBUILD)/icedtea-update-bootclasspath.patch > > > > # Conditional patches > > > > diff -r 93ac4fddecf3 patches/hotspot/default/icedtea-update-bootclasspath.patch > > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > > +++ b/patches/hotspot/default/icedtea-update-bootclasspath.patch Thu Jan 20 19:19:28 2011 -0500 > > @@ -0,0 +1,13 @@ > > +diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/os.cpp openjdk/hotspot/src/share/vm/runtime/os.cpp > > +--- openjdk.orig/hotspot/src/share/vm/runtime/os.cpp 2010-09-01 01:23:45.000000000 +0100 > > ++++ openjdk/hotspot/src/share/vm/runtime/os.cpp 2010-09-19 17:34:30.859345954 +0100 > > +@@ -1032,6 +1032,9 @@ > > + "%/lib/jsse.jar:" > > + "%/lib/jce.jar:" > > + "%/lib/charsets.jar:" > > ++ "%/lib/netx.jar:" > > ++ "%/lib/plugin.jar:" > > ++ "%/lib/rhino.jar:" > > + > > + // ## TEMPORARY hack to keep the legacy launcher working when > > + // ## only the boot module is installed (cf. j.l.ClassLoader) > > diff -r 93ac4fddecf3 patches/icedtea-rhino.patch > > --- a/patches/icedtea-rhino.patch Fri Dec 10 13:43:00 2010 +0000 > > +++ b/patches/icedtea-rhino.patch Thu Jan 20 19:19:28 2011 -0500 > > @@ -1,16 +1,3 @@ > > -diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/os.cpp openjdk/hotspot/src/share/vm/runtime/os.cpp > > ---- openjdk.orig/hotspot/src/share/vm/runtime/os.cpp 2010-08-27 19:15:27.000000000 +0100 > > -+++ openjdk/hotspot/src/share/vm/runtime/os.cpp 2010-09-01 18:12:38.850408989 +0100 > > -@@ -1033,6 +1033,9 @@ > > - "%/lib/jce.jar:" > > - "%/lib/charsets.jar:" > > - > > -+ // IcedTea addition to support Rhino via javax.script > > -+ "%/lib/rhino.jar:" > > -+ > > - // ## TEMPORARY hack to keep the legacy launcher working when > > - // ## only the boot module is installed (cf. j.l.ClassLoader) > > - "%/lib/modules/jdk.boot.jar:" > > diff -Nru openjdk.orig/jdk/make/com/sun/Makefile openjdk/jdk/make/com/sun/Makefile > > --- openjdk.orig/jdk/make/com/sun/Makefile 2010-07-29 21:55:26.000000000 +0100 > > +++ openjdk/jdk/make/com/sun/Makefile 2010-09-01 18:08:22.164610031 +0100 > > > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Thu Jan 20 16:46:14 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 21 Jan 2011 00:46:14 +0000 Subject: [icedtea-web] RFE: Fix for broken JRE dir install In-Reply-To: <20110121003724.GD22586@redhat.com> References: <20110120235619.GA22586@redhat.com> <20110121002225.GD4611@rivendell.middle-earth.co.uk> <20110121003724.GD22586@redhat.com> Message-ID: <20110121004614.GG4611@rivendell.middle-earth.co.uk> On 19:37 Thu 20 Jan , Deepak Bhole wrote: > * Dr Andrew John Hughes [2011-01-20 19:22]: > > On 18:56 Thu 20 Jan , Deepak Bhole wrote: > > > Hi, > > > > > > Currently, installation to a jre directory is broken in both HEAD and > > > 1.0. Installing to j2re-image for example will end up creating > > > jre-image/jre/lib which is incorrect (files should go into > > > j2re-image/lib in this case). > > > > > > Attached patch fixes it so that install to both, jre and jdk works and > > > as does uninstall. It also makes javaws and itweb-setings actual files > > > (similar to 'java' and other binaries which are copied to JDK_HOME/bin > > > and JDK_HOME/jre/bin rather than being symlinked) and makes sure that > > > javaws can be called from either location and that it works. > > > > > > ChangeLog: > > > 2011-01-20 Deepak Bhole > > > > > > * Makefile.am > > > (install-exec-local): Use new JRE_DIR_PREFIX variables rather than > > > hardcoded '/jre' in pathname. Copy javaws and itweb-settings rather than > > > symlinking. > > > (install-data-local): Use new JRE_DIR_PREFIX variables rather than > > > jardcoded '/jre' in pathname. > > > (uninstall-local): Same. Also, remove all parent dirs of $(htmldir) until > > > a non-empty one is encountered. > > > * configure.ac: Set JRE_DIR_PREFIX to jre/ if prefix is a JDK dir and set > > > it to empty if prefix apears to be a JRE dir. > > > * netx/net/sourceforge/jnlp/Launcher.java (launchExternal): Revert back to > > > using java.home when selecting javaws binary to execute for fork. > > > > > > > > > Note: This should be backported to 1.0 after 9397074c2c39 is. Please see this > > > for rationale: > > > http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011806.html > > > > > > I have tested this considerably to make sure nothing is broken, but if > > > anyone feels the scope of this patch is too much for 1.0 this close to > > > release (I was hoping to tag today but looks like it will have to be > > > tomorrow now), I can post a separate path for 1.0 that only addresses > > > the issues mentioned in the thread above. > > > > > > Cheers, > > > Deepak > > > > Ok, number of points: > > > > * Why do we need to have duplicate copies? What is wrong with the symlink? > > We discussed this previously and no objections were raised at the time. > > I have no objections to symlink. I was just trying to mimic what the > default upstream openjdk install does with its binaries. I am fine with > symlinking too. > Ok, then don't change it :-) > > * Why the change to the htmldir deletion? How does rm -rf fail? I don't > > think this long option to rmdir should be used as I doubt it is standard. > > We create a JDK_HOME/share/... dir. By default there is no share/ dir > in JDK_HOME. I think an uninstall should attempt to remove _everything_ > it creates, and hence the rmdir -p which attempts to remove the dir and > its parents all the way to the top (until it encounters a non-empty > dir). > I suppose we can accomodate this, though it again seems to be something just to handle installing in a JDK tree. /usr/share would normally exist and be non-empty. > > * Using java.home breaks installation outside a JDK tree. See previous > > discussion. That's why icedtea.web.bin was introduced. > > I was unable to reproduce such breakage after this patch. > > http://download.oracle.com/javase/tutorial/essential/environment/sysprop.html > states that java.home is the jre install dir (and this is true even if > javaws is invoked from JDK_HOME/bin rather than JDK_HOME/jre/bin). > Assuming jre/bin contains the actual file, java.home/bin/javaws will always > exist and work regardless of where javaws was called from. > I don't follow. If the user specifies --prefix=/usr, your patch will be looking in completely the wrong place. You shouldn't let the user specify the install directory and then just completely ignore it and assume something else. I gather that /usr installation is broken in the code at present too, but I don't see why we want to create even more breakage. > > * Typo: whether not weather. > > > > Doh! Thanks. > > Cheers, > Deepak > > > > diff -r 06940cdcfef8 Makefile.am > > > --- a/Makefile.am Thu Jan 20 11:06:41 2011 -0500 > > > +++ b/Makefile.am Thu Jan 20 18:47:48 2011 -0500 > > > @@ -103,37 +103,37 @@ > > > clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs > > > > > > install-exec-local: > > > - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) > > > + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > > > if ENABLE_PLUGIN > > > - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ > > > + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ > > > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) > > > - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > > + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > > endif > > > - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > > > + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > > fi ; \ > > > if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > > > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > > + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > > fi ; \ > > > fi > > > - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > > > + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > > fi ; \ > > > if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > > > - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > > > + cp -a $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin ; \ > > > fi ; \ > > > fi > > > > > > install-data-local: > > > ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 > > > ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 > > > - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib > > > + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > > if ENABLE_DOCS > > > ${mkinstalldirs} $(DESTDIR)$(htmldir) > > > (cd ${abs_top_builddir}/docs/netx; \ > > > @@ -151,23 +151,25 @@ > > > endif > > > > > > uninstall-local: > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar > > > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > > > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > > > rm -f $(DESTDIR)$(bindir)/javaws > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > > fi > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > > > rm -f $(DESTDIR)$(bindir)/itweb-settings > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > > fi > > > - rm -rf $(DESTDIR)$(htmldir) > > > + rm -rf $(DESTDIR)$(htmldir)/* > > > + if [ -d $(DESTDIR)$(htmldir) ] ; then \ > > > + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ > > > + fi > > > > > > # Plugin > > > > > > @@ -350,7 +352,7 @@ > > > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > > > mkdir -p $(NETX_DIR)/launcher && \ > > > $(CC) $(LAUNCHER_FLAGS) \ > > > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > > > + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ > > > -DPROGNAME='"javaws"' -c -o $@ $< > > > > > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > > > diff -r 06940cdcfef8 configure.ac > > > --- a/configure.ac Thu Jan 20 11:06:41 2011 -0500 > > > +++ b/configure.ac Thu Jan 20 18:47:48 2011 -0500 > > > @@ -80,4 +80,12 @@ > > > IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) > > > IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE > > > > > > +# Set JRE prefix based on weather to-level prefix is a JDK dir or a JRE dir > > > +if test -d ${prefix}/jre ; then > > > + JRE_DIR_PREFIX="/jre" ; > > > +else > > > + JRE_DIR_PREFIX="" ; > > > +fi ; > > > +AC_SUBST([JRE_DIR_PREFIX]) > > > + > > > AC_OUTPUT > > > diff -r 06940cdcfef8 netx/net/sourceforge/jnlp/Launcher.java > > > --- a/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 11:06:41 2011 -0500 > > > +++ b/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 18:47:48 2011 -0500 > > > @@ -327,7 +327,12 @@ > > > List commands = new LinkedList(); > > > > > > // this property is set by the javaws launcher to point to the javaws binary > > > - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); > > > + String pathToWebstartBinary = System.getProperty("java.home") + > > > + File.separatorChar + > > > + "bin" + > > > + File.separatorChar + > > > + "javaws"; > > > + > > > commands.add(pathToWebstartBinary); > > > // use -Jargument format to pass arguments to the JVM through the launcher > > > for (String arg : vmArgs) { > > > > > > -- > > Andrew :) > > > > Free Java Software Engineer > > Red Hat, Inc. (http://www.redhat.com) > > > > Support Free Java! > > Contribute to GNU Classpath and IcedTea > > http://www.gnu.org/software/classpath > > http://icedtea.classpath.org > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Thu Jan 20 16:38:29 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 21 Jan 2011 00:38:29 +0000 Subject: [icedtea-web] RFC: Update NEWS file In-Reply-To: <20110120163325.GB18293@redhat.com> References: <4CF7BCE0.8080800@redhat.com> <20110120163325.GB18293@redhat.com> Message-ID: <20110121003829.GF4611@rivendell.middle-earth.co.uk> On 11:33 Thu 20 Jan , Deepak Bhole wrote: > * Omair Majid [2010-12-02 12:17]: > > Hi, > > > > The attached patch updates the NEWS file. It reorganizes things into > > major/minor sections, so all important items are visible first. > > > > Thoughts/comments? > > > > Sorry, I thought I had approved this. Okay for HEAD and 1.0. > > Cheers, > Deepak > Please don't apply as is. The common, javaws and plugin headers look ugly and will break the NEWS generation I do for release. Please use: * Common Minor Improvements and Fixes * Java Web Start Minor Improvements and Fixes * Plugin Minor Improvements and Fixes as headers instead. > > Cheers, > > Omair > > > diff -r 6c8e9229bded NEWS > > --- a/NEWS Thu Dec 02 10:22:44 2010 -0500 > > +++ b/NEWS Thu Dec 02 10:34:27 2010 -0500 > > @@ -13,18 +13,29 @@ > > * Initial release of IcedTea-Web > > * Security updates > > - RH645843, CVE-2010-3860: IcedTea System property information leak via public static > > -* Plugin > > - - PR542: Plugin fails with NPE on http://www.openprocessing.org/visuals/iframe.php?visualID=2615 > > - - PR552: Support for FreeBSD's pthread implementation > > - - PR554: System.err writes content two times > > - - PR556: Applet initialization code is prone to race conditions > > - - PR557: Applet opens in a separate window if tab is closed when the applet loads > > - - PR565: UIDefaults.getUI fails with jgoodies:looks 2.3.1 > > - - PR593: Increment of invalidated iterator in IcedTeaPluginUtils (patch from barbara.xxx1975 at libero.it) > > - - Applets are now double-buffered to eliminate flicker in ones that do heavy drawing > > -* NetX > > - - Add a new option -Xclearcache > > - - Interfaces javax.jnlp.IntegrationService and javax.jnlp.DownloadService2 are now available > > - - PR592: NetX can create invalid desktop entry files > > -* Control Panel > > - - Modifications to deployments.properties file can now be done through a GUI > > +* New Features > > + - IcedTea-Web now uses a deployment.properties file to specify configuration > > + - An preview of a Control Panel that allows configuring IcedTea-Web using a GUI > > + - System-level as well as user-level deployment.properties files with locked configuration are supported > > + - Static proxies are now supported using the deployment.properties file > > + - User prompts can now be configured using the deployment.properties > > + - Applications and applets can now have a Look and Feel different from rest of IcedTea-Web > > +* Minor improvements and fixes > > + - common: Clean up native directories on exit > > + - common: Cached files with special characters in filenames are now handled correctly > > + - common: Interfaces javax.jnlp.IntegrationService and javax.jnlp.DownloadService2 are now available > > + - javaws: PR592: NetX can create invalid desktop entry files > > + - javaws: Add a new option -Xclearcache > > + - javaws: Removed option -umask > > + - javaws: Applications with non-public main classes are now supported. > > + - javaws: JNLP files containing as well as will now work > > + - javaws: The javaws.desktop file now points explicitly to NetX's javaws binary > > + - plugin: PR542: Plugin fails with NPE on http://www.openprocessing.org/visuals/iframe.php?visualID=2615 > > + - plugin: PR552: Support for FreeBSD's pthread implementation > > + - plugin: PR554: System.err writes content two times > > + - plugin: PR556: Applet initialization code is prone to race conditions > > + - plugin: PR557: Applet opens in a separate window if tab is closed when the applet loads > > + - plugin: PR565: UIDefaults.getUI fails with jgoodies:looks 2.3.1 > > + - plugin: PR593: Increment of invalidated iterator in IcedTeaPluginUtils (patch from barbara.xxx1975 at libero.it) > > + - plugin: JNLP files referenced in the applet tag are now parsed to detect applet properties > > + - plugin: Applets are now double-buffered to eliminate flicker in ones that do heavy drawing > -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From dbhole at redhat.com Thu Jan 20 17:10:17 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Thu, 20 Jan 2011 20:10:17 -0500 Subject: [icedtea-web] RFE: Fix for broken JRE dir install In-Reply-To: <20110121004614.GG4611@rivendell.middle-earth.co.uk> References: <20110120235619.GA22586@redhat.com> <20110121002225.GD4611@rivendell.middle-earth.co.uk> <20110121003724.GD22586@redhat.com> <20110121004614.GG4611@rivendell.middle-earth.co.uk> Message-ID: <20110121011017.GF22586@redhat.com> * Dr Andrew John Hughes [2011-01-20 19:46]: > On 19:37 Thu 20 Jan , Deepak Bhole wrote: > > * Dr Andrew John Hughes [2011-01-20 19:22]: > > > On 18:56 Thu 20 Jan , Deepak Bhole wrote: > > > > Hi, > > > > > > > > Currently, installation to a jre directory is broken in both HEAD and > > > > 1.0. Installing to j2re-image for example will end up creating > > > > jre-image/jre/lib which is incorrect (files should go into > > > > j2re-image/lib in this case). > > > > > > > > Attached patch fixes it so that install to both, jre and jdk works and > > > > as does uninstall. It also makes javaws and itweb-setings actual files > > > > (similar to 'java' and other binaries which are copied to JDK_HOME/bin > > > > and JDK_HOME/jre/bin rather than being symlinked) and makes sure that > > > > javaws can be called from either location and that it works. > > > > > > > > ChangeLog: > > > > 2011-01-20 Deepak Bhole > > > > > > > > * Makefile.am > > > > (install-exec-local): Use new JRE_DIR_PREFIX variables rather than > > > > hardcoded '/jre' in pathname. Copy javaws and itweb-settings rather than > > > > symlinking. > > > > (install-data-local): Use new JRE_DIR_PREFIX variables rather than > > > > jardcoded '/jre' in pathname. > > > > (uninstall-local): Same. Also, remove all parent dirs of $(htmldir) until > > > > a non-empty one is encountered. > > > > * configure.ac: Set JRE_DIR_PREFIX to jre/ if prefix is a JDK dir and set > > > > it to empty if prefix apears to be a JRE dir. > > > > * netx/net/sourceforge/jnlp/Launcher.java (launchExternal): Revert back to > > > > using java.home when selecting javaws binary to execute for fork. > > > > > > > > > > > > Note: This should be backported to 1.0 after 9397074c2c39 is. Please see this > > > > for rationale: > > > > http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011806.html > > > > > > > > I have tested this considerably to make sure nothing is broken, but if > > > > anyone feels the scope of this patch is too much for 1.0 this close to > > > > release (I was hoping to tag today but looks like it will have to be > > > > tomorrow now), I can post a separate path for 1.0 that only addresses > > > > the issues mentioned in the thread above. > > > > > > > > Cheers, > > > > Deepak > > > > > > Ok, number of points: > > > > > > * Why do we need to have duplicate copies? What is wrong with the symlink? > > > We discussed this previously and no objections were raised at the time. > > > > I have no objections to symlink. I was just trying to mimic what the > > default upstream openjdk install does with its binaries. I am fine with > > symlinking too. > > > > Ok, then don't change it :-) > Heh, okay :) > > > * Why the change to the htmldir deletion? How does rm -rf fail? I don't > > > think this long option to rmdir should be used as I doubt it is standard. > > > > We create a JDK_HOME/share/... dir. By default there is no share/ dir > > in JDK_HOME. I think an uninstall should attempt to remove _everything_ > > it creates, and hence the rmdir -p which attempts to remove the dir and > > its parents all the way to the top (until it encounters a non-empty > > dir). > > > > I suppose we can accomodate this, though it again seems to be something > just to handle installing in a JDK tree. /usr/share would normally exist > and be non-empty. > Yep, I understand. Once that is working, this may be removed. > > > * Using java.home breaks installation outside a JDK tree. See previous > > > discussion. That's why icedtea.web.bin was introduced. > > > > I was unable to reproduce such breakage after this patch. > > > > http://download.oracle.com/javase/tutorial/essential/environment/sysprop.html > > states that java.home is the jre install dir (and this is true even if > > javaws is invoked from JDK_HOME/bin rather than JDK_HOME/jre/bin). > > Assuming jre/bin contains the actual file, java.home/bin/javaws will always > > exist and work regardless of where javaws was called from. > > > > I don't follow. If the user specifies --prefix=/usr, your patch will be looking > in completely the wrong place. You shouldn't let the user specify the install > directory and then just completely ignore it and assume something else. > > I gather that /usr installation is broken in the code at present too, > but I don't see why we want to create even more breakage. > Fair enough. However in it's current incarnation, the JDK is relocatable just by copying the tree. Until we can support /usr installation, we need to install in the JDK tree, and while we are installation there, I would like icedtea-web to not be the reason why relocatability is broken... Cheers, Deepak > > > * Typo: whether not weather. > > > > > > > Doh! Thanks. > > > > Cheers, > > Deepak > > > > > > diff -r 06940cdcfef8 Makefile.am > > > > --- a/Makefile.am Thu Jan 20 11:06:41 2011 -0500 > > > > +++ b/Makefile.am Thu Jan 20 18:47:48 2011 -0500 > > > > @@ -103,37 +103,37 @@ > > > > clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs > > > > > > > > install-exec-local: > > > > - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) > > > > + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > > > > if ENABLE_PLUGIN > > > > - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ > > > > + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ > > > > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) > > > > - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > > > + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > > > endif > > > > - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > > > > + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > > > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > > > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > > rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > > > fi ; \ > > > > if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > > > > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > > > + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > > > fi ; \ > > > > fi > > > > - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > > > > + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > > > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > > > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > > rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > > > fi ; \ > > > > if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > > > > - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > > > > + cp -a $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin ; \ > > > > fi ; \ > > > > fi > > > > > > > > install-data-local: > > > > ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 > > > > ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 > > > > - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib > > > > + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > > > if ENABLE_DOCS > > > > ${mkinstalldirs} $(DESTDIR)$(htmldir) > > > > (cd ${abs_top_builddir}/docs/netx; \ > > > > @@ -151,23 +151,25 @@ > > > > endif > > > > > > > > uninstall-local: > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar > > > > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > > > > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > > > > rm -f $(DESTDIR)$(bindir)/javaws > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > > rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > > > fi > > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > > > > rm -f $(DESTDIR)$(bindir)/itweb-settings > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > > rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > > > fi > > > > - rm -rf $(DESTDIR)$(htmldir) > > > > + rm -rf $(DESTDIR)$(htmldir)/* > > > > + if [ -d $(DESTDIR)$(htmldir) ] ; then \ > > > > + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ > > > > + fi > > > > > > > > # Plugin > > > > > > > > @@ -350,7 +352,7 @@ > > > > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > > > > mkdir -p $(NETX_DIR)/launcher && \ > > > > $(CC) $(LAUNCHER_FLAGS) \ > > > > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > > > > + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ > > > > -DPROGNAME='"javaws"' -c -o $@ $< > > > > > > > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > > > > diff -r 06940cdcfef8 configure.ac > > > > --- a/configure.ac Thu Jan 20 11:06:41 2011 -0500 > > > > +++ b/configure.ac Thu Jan 20 18:47:48 2011 -0500 > > > > @@ -80,4 +80,12 @@ > > > > IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) > > > > IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE > > > > > > > > +# Set JRE prefix based on weather to-level prefix is a JDK dir or a JRE dir > > > > +if test -d ${prefix}/jre ; then > > > > + JRE_DIR_PREFIX="/jre" ; > > > > +else > > > > + JRE_DIR_PREFIX="" ; > > > > +fi ; > > > > +AC_SUBST([JRE_DIR_PREFIX]) > > > > + > > > > AC_OUTPUT > > > > diff -r 06940cdcfef8 netx/net/sourceforge/jnlp/Launcher.java > > > > --- a/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 11:06:41 2011 -0500 > > > > +++ b/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 18:47:48 2011 -0500 > > > > @@ -327,7 +327,12 @@ > > > > List commands = new LinkedList(); > > > > > > > > // this property is set by the javaws launcher to point to the javaws binary > > > > - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); > > > > + String pathToWebstartBinary = System.getProperty("java.home") + > > > > + File.separatorChar + > > > > + "bin" + > > > > + File.separatorChar + > > > > + "javaws"; > > > > + > > > > commands.add(pathToWebstartBinary); > > > > // use -Jargument format to pass arguments to the JVM through the launcher > > > > for (String arg : vmArgs) { > > > > > > > > > -- > > > Andrew :) > > > > > > Free Java Software Engineer > > > Red Hat, Inc. (http://www.redhat.com) > > > > > > Support Free Java! > > > Contribute to GNU Classpath and IcedTea > > > http://www.gnu.org/software/classpath > > > http://icedtea.classpath.org > > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 > > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Thu Jan 20 17:10:41 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 21 Jan 2011 01:10:41 +0000 Subject: Patch to make icedtea-web work with icedtea In-Reply-To: <20110121003932.GE22586@redhat.com> References: <20110121002713.GC22586@redhat.com> <20110121003324.GE4611@rivendell.middle-earth.co.uk> <20110121003932.GE22586@redhat.com> Message-ID: <20110121011041.GH4611@rivendell.middle-earth.co.uk> On 19:39 Thu 20 Jan , Deepak Bhole wrote: > * Dr Andrew John Hughes [2011-01-20 19:33]: > > On 19:27 Thu 20 Jan , Deepak Bhole wrote: > > > Hi, > > > > > > Unlike icedtea6, icedtea currently does not append plugin.jar and > > > netx.jar to the default boot classpath. > > > > > > Attached patch makes it so that like icedtea6, the bootclasspath update > > > is moved to a separate patch which updates for rhino, netx and plugin. > > > > > > After applying this patch, icedtea-web works correctly with icedtea. > > > > > > Cheers, > > > Deepak > > > > Doesn't this need to be conditional on Rhino being installed? > > > > Having a jar that doesn't exist in the classpath has no ill effect. In > icedtea6 we do the same thing, rhino is always on classpath whether it > is enabled or disabled. > Ok, well presumably you do need to remove 'icedtea-rhino.patch' from Makefile.am? :-) > > Also please just use patches. IcedTea7 only supports one HotSpot version. > > > > Ah sorry, I wasn't aware of that. > > Cheers, > Deepak > > > > diff -r 93ac4fddecf3 Makefile.am > > > --- a/Makefile.am Fri Dec 10 13:43:00 2010 +0000 > > > +++ b/Makefile.am Thu Jan 20 19:19:28 2011 -0500 > > > @@ -303,7 +303,8 @@ > > > patches/no-precompiled.patch \ > > > patches/parisc.patch \ > > > patches/sh4-support.patch \ > > > - patches/jtreg-httpTest.patch > > > + patches/jtreg-httpTest.patch \ > > > + patches/hotspot/$(HSBUILD)/icedtea-update-bootclasspath.patch > > > > > > # Conditional patches > > > > > > diff -r 93ac4fddecf3 patches/hotspot/default/icedtea-update-bootclasspath.patch > > > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > > > +++ b/patches/hotspot/default/icedtea-update-bootclasspath.patch Thu Jan 20 19:19:28 2011 -0500 > > > @@ -0,0 +1,13 @@ > > > +diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/os.cpp openjdk/hotspot/src/share/vm/runtime/os.cpp > > > +--- openjdk.orig/hotspot/src/share/vm/runtime/os.cpp 2010-09-01 01:23:45.000000000 +0100 > > > ++++ openjdk/hotspot/src/share/vm/runtime/os.cpp 2010-09-19 17:34:30.859345954 +0100 > > > +@@ -1032,6 +1032,9 @@ > > > + "%/lib/jsse.jar:" > > > + "%/lib/jce.jar:" > > > + "%/lib/charsets.jar:" > > > ++ "%/lib/netx.jar:" > > > ++ "%/lib/plugin.jar:" > > > ++ "%/lib/rhino.jar:" > > > + > > > + // ## TEMPORARY hack to keep the legacy launcher working when > > > + // ## only the boot module is installed (cf. j.l.ClassLoader) > > > diff -r 93ac4fddecf3 patches/icedtea-rhino.patch > > > --- a/patches/icedtea-rhino.patch Fri Dec 10 13:43:00 2010 +0000 > > > +++ b/patches/icedtea-rhino.patch Thu Jan 20 19:19:28 2011 -0500 > > > @@ -1,16 +1,3 @@ > > > -diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/os.cpp openjdk/hotspot/src/share/vm/runtime/os.cpp > > > ---- openjdk.orig/hotspot/src/share/vm/runtime/os.cpp 2010-08-27 19:15:27.000000000 +0100 > > > -+++ openjdk/hotspot/src/share/vm/runtime/os.cpp 2010-09-01 18:12:38.850408989 +0100 > > > -@@ -1033,6 +1033,9 @@ > > > - "%/lib/jce.jar:" > > > - "%/lib/charsets.jar:" > > > - > > > -+ // IcedTea addition to support Rhino via javax.script > > > -+ "%/lib/rhino.jar:" > > > -+ > > > - // ## TEMPORARY hack to keep the legacy launcher working when > > > - // ## only the boot module is installed (cf. j.l.ClassLoader) > > > - "%/lib/modules/jdk.boot.jar:" > > > diff -Nru openjdk.orig/jdk/make/com/sun/Makefile openjdk/jdk/make/com/sun/Makefile > > > --- openjdk.orig/jdk/make/com/sun/Makefile 2010-07-29 21:55:26.000000000 +0100 > > > +++ openjdk/jdk/make/com/sun/Makefile 2010-09-01 18:08:22.164610031 +0100 > > > > > > -- > > Andrew :) > > > > Free Java Software Engineer > > Red Hat, Inc. (http://www.redhat.com) > > > > Support Free Java! > > Contribute to GNU Classpath and IcedTea > > http://www.gnu.org/software/classpath > > http://icedtea.classpath.org > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Thu Jan 20 17:32:28 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 21 Jan 2011 01:32:28 +0000 Subject: [icedtea-web] RFE: Fix for broken JRE dir install In-Reply-To: <20110121011017.GF22586@redhat.com> References: <20110120235619.GA22586@redhat.com> <20110121002225.GD4611@rivendell.middle-earth.co.uk> <20110121003724.GD22586@redhat.com> <20110121004614.GG4611@rivendell.middle-earth.co.uk> <20110121011017.GF22586@redhat.com> Message-ID: <20110121013228.GI4611@rivendell.middle-earth.co.uk> On 20:10 Thu 20 Jan , Deepak Bhole wrote: > * Dr Andrew John Hughes [2011-01-20 19:46]: snip... > > > > I don't follow. If the user specifies --prefix=/usr, your patch will be looking > > in completely the wrong place. You shouldn't let the user specify the install > > directory and then just completely ignore it and assume something else. > > > > I gather that /usr installation is broken in the code at present too, > > but I don't see why we want to create even more breakage. > > > > Fair enough. However in it's current incarnation, the JDK is relocatable > just by copying the tree. Until we can support /usr installation, we > need to install in the JDK tree, and while we are installation there, I > would like icedtea-web to not be the reason why relocatability is > broken... > Ok, I approve reverting to java.home and the rest of this patch, bar the copying changes, on the 1.0 branch only. It needs fixing properly on the main tree and should not be reverted there. 1.1 should support installing anywhere. > Cheers, > Deepak > > > > > * Typo: whether not weather. > > > > > > > > > > Doh! Thanks. > > > > > > Cheers, > > > Deepak > > > > > > > > diff -r 06940cdcfef8 Makefile.am > > > > > --- a/Makefile.am Thu Jan 20 11:06:41 2011 -0500 > > > > > +++ b/Makefile.am Thu Jan 20 18:47:48 2011 -0500 > > > > > @@ -103,37 +103,37 @@ > > > > > clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs > > > > > > > > > > install-exec-local: > > > > > - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) > > > > > + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > > > > > if ENABLE_PLUGIN > > > > > - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ > > > > > + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ > > > > > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) > > > > > - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > > > > + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > > > > endif > > > > > - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > > > > > + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > > > > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > > > > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > > > rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > > > > fi ; \ > > > > > if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > > > > > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > > > > + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > > > > fi ; \ > > > > > fi > > > > > - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > > > > > + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > > > > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > > > > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > > > rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > > > > fi ; \ > > > > > if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > > > > > - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > > > > > + cp -a $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin ; \ > > > > > fi ; \ > > > > > fi > > > > > > > > > > install-data-local: > > > > > ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 > > > > > ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 > > > > > - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib > > > > > + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > > > > if ENABLE_DOCS > > > > > ${mkinstalldirs} $(DESTDIR)$(htmldir) > > > > > (cd ${abs_top_builddir}/docs/netx; \ > > > > > @@ -151,23 +151,25 @@ > > > > > endif > > > > > > > > > > uninstall-local: > > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar > > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp > > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar > > > > > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > > > > > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > > > > > rm -f $(DESTDIR)$(bindir)/javaws > > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > > > rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > > > > fi > > > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > > > > > rm -f $(DESTDIR)$(bindir)/itweb-settings > > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > > > rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > > > > fi > > > > > - rm -rf $(DESTDIR)$(htmldir) > > > > > + rm -rf $(DESTDIR)$(htmldir)/* > > > > > + if [ -d $(DESTDIR)$(htmldir) ] ; then \ > > > > > + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ > > > > > + fi > > > > > > > > > > # Plugin > > > > > > > > > > @@ -350,7 +352,7 @@ > > > > > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > > > > > mkdir -p $(NETX_DIR)/launcher && \ > > > > > $(CC) $(LAUNCHER_FLAGS) \ > > > > > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > > > > > + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ > > > > > -DPROGNAME='"javaws"' -c -o $@ $< > > > > > > > > > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > > > > > diff -r 06940cdcfef8 configure.ac > > > > > --- a/configure.ac Thu Jan 20 11:06:41 2011 -0500 > > > > > +++ b/configure.ac Thu Jan 20 18:47:48 2011 -0500 > > > > > @@ -80,4 +80,12 @@ > > > > > IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) > > > > > IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE > > > > > > > > > > +# Set JRE prefix based on weather to-level prefix is a JDK dir or a JRE dir > > > > > +if test -d ${prefix}/jre ; then > > > > > + JRE_DIR_PREFIX="/jre" ; > > > > > +else > > > > > + JRE_DIR_PREFIX="" ; > > > > > +fi ; > > > > > +AC_SUBST([JRE_DIR_PREFIX]) > > > > > + > > > > > AC_OUTPUT > > > > > diff -r 06940cdcfef8 netx/net/sourceforge/jnlp/Launcher.java > > > > > --- a/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 11:06:41 2011 -0500 > > > > > +++ b/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 18:47:48 2011 -0500 > > > > > @@ -327,7 +327,12 @@ > > > > > List commands = new LinkedList(); > > > > > > > > > > // this property is set by the javaws launcher to point to the javaws binary > > > > > - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); > > > > > + String pathToWebstartBinary = System.getProperty("java.home") + > > > > > + File.separatorChar + > > > > > + "bin" + > > > > > + File.separatorChar + > > > > > + "javaws"; > > > > > + > > > > > commands.add(pathToWebstartBinary); > > > > > // use -Jargument format to pass arguments to the JVM through the launcher > > > > > for (String arg : vmArgs) { > > > > > > > > > > > > -- > > > > Andrew :) > > > > > > > > Free Java Software Engineer > > > > Red Hat, Inc. (http://www.redhat.com) > > > > > > > > Support Free Java! > > > > Contribute to GNU Classpath and IcedTea > > > > http://www.gnu.org/software/classpath > > > > http://icedtea.classpath.org > > > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 > > > > -- > > Andrew :) > > > > Free Java Software Engineer > > Red Hat, Inc. (http://www.redhat.com) > > > > Support Free Java! > > Contribute to GNU Classpath and IcedTea > > http://www.gnu.org/software/classpath > > http://icedtea.classpath.org > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From dbhole at redhat.com Thu Jan 20 17:56:19 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Thu, 20 Jan 2011 20:56:19 -0500 Subject: Patch to make icedtea-web work with icedtea In-Reply-To: <20110121011041.GH4611@rivendell.middle-earth.co.uk> References: <20110121002713.GC22586@redhat.com> <20110121003324.GE4611@rivendell.middle-earth.co.uk> <20110121003932.GE22586@redhat.com> <20110121011041.GH4611@rivendell.middle-earth.co.uk> Message-ID: <20110121015619.GG22586@redhat.com> * Dr Andrew John Hughes [2011-01-20 20:10]: > On 19:39 Thu 20 Jan , Deepak Bhole wrote: > > * Dr Andrew John Hughes [2011-01-20 19:33]: > > > On 19:27 Thu 20 Jan , Deepak Bhole wrote: > > > > Hi, > > > > > > > > Unlike icedtea6, icedtea currently does not append plugin.jar and > > > > netx.jar to the default boot classpath. > > > > > > > > Attached patch makes it so that like icedtea6, the bootclasspath update > > > > is moved to a separate patch which updates for rhino, netx and plugin. > > > > > > > > After applying this patch, icedtea-web works correctly with icedtea. > > > > > > > > Cheers, > > > > Deepak > > > > > > Doesn't this need to be conditional on Rhino being installed? > > > > > > > Having a jar that doesn't exist in the classpath has no ill effect. In > > icedtea6 we do the same thing, rhino is always on classpath whether it > > is enabled or disabled. > > > > Ok, well presumably you do need to remove 'icedtea-rhino.patch' from Makefile.am? :-) > Nope, that one will still be needed as it wires in the rest of the rhino support. The reason the hunk related to classpath change was removed was because the change to add rhino.jar and netx/plugin.jar would interfere with each other, making one patch dependent on the other. That's why the whole 'classpath update' part was moved to a separate part in icedtea6. Cheers, Deepak > > > Also please just use patches. IcedTea7 only supports one HotSpot version. > > > > > > > Ah sorry, I wasn't aware of that. > > > > Cheers, > > Deepak > > > > > > diff -r 93ac4fddecf3 Makefile.am > > > > --- a/Makefile.am Fri Dec 10 13:43:00 2010 +0000 > > > > +++ b/Makefile.am Thu Jan 20 19:19:28 2011 -0500 > > > > @@ -303,7 +303,8 @@ > > > > patches/no-precompiled.patch \ > > > > patches/parisc.patch \ > > > > patches/sh4-support.patch \ > > > > - patches/jtreg-httpTest.patch > > > > + patches/jtreg-httpTest.patch \ > > > > + patches/hotspot/$(HSBUILD)/icedtea-update-bootclasspath.patch > > > > > > > > # Conditional patches > > > > > > > > diff -r 93ac4fddecf3 patches/hotspot/default/icedtea-update-bootclasspath.patch > > > > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > > > > +++ b/patches/hotspot/default/icedtea-update-bootclasspath.patch Thu Jan 20 19:19:28 2011 -0500 > > > > @@ -0,0 +1,13 @@ > > > > +diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/os.cpp openjdk/hotspot/src/share/vm/runtime/os.cpp > > > > +--- openjdk.orig/hotspot/src/share/vm/runtime/os.cpp 2010-09-01 01:23:45.000000000 +0100 > > > > ++++ openjdk/hotspot/src/share/vm/runtime/os.cpp 2010-09-19 17:34:30.859345954 +0100 > > > > +@@ -1032,6 +1032,9 @@ > > > > + "%/lib/jsse.jar:" > > > > + "%/lib/jce.jar:" > > > > + "%/lib/charsets.jar:" > > > > ++ "%/lib/netx.jar:" > > > > ++ "%/lib/plugin.jar:" > > > > ++ "%/lib/rhino.jar:" > > > > + > > > > + // ## TEMPORARY hack to keep the legacy launcher working when > > > > + // ## only the boot module is installed (cf. j.l.ClassLoader) > > > > diff -r 93ac4fddecf3 patches/icedtea-rhino.patch > > > > --- a/patches/icedtea-rhino.patch Fri Dec 10 13:43:00 2010 +0000 > > > > +++ b/patches/icedtea-rhino.patch Thu Jan 20 19:19:28 2011 -0500 > > > > @@ -1,16 +1,3 @@ > > > > -diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/os.cpp openjdk/hotspot/src/share/vm/runtime/os.cpp > > > > ---- openjdk.orig/hotspot/src/share/vm/runtime/os.cpp 2010-08-27 19:15:27.000000000 +0100 > > > > -+++ openjdk/hotspot/src/share/vm/runtime/os.cpp 2010-09-01 18:12:38.850408989 +0100 > > > > -@@ -1033,6 +1033,9 @@ > > > > - "%/lib/jce.jar:" > > > > - "%/lib/charsets.jar:" > > > > - > > > > -+ // IcedTea addition to support Rhino via javax.script > > > > -+ "%/lib/rhino.jar:" > > > > -+ > > > > - // ## TEMPORARY hack to keep the legacy launcher working when > > > > - // ## only the boot module is installed (cf. j.l.ClassLoader) > > > > - "%/lib/modules/jdk.boot.jar:" > > > > diff -Nru openjdk.orig/jdk/make/com/sun/Makefile openjdk/jdk/make/com/sun/Makefile > > > > --- openjdk.orig/jdk/make/com/sun/Makefile 2010-07-29 21:55:26.000000000 +0100 > > > > +++ openjdk/jdk/make/com/sun/Makefile 2010-09-01 18:08:22.164610031 +0100 > > > > > > > > > -- > > > Andrew :) > > > > > > Free Java Software Engineer > > > Red Hat, Inc. (http://www.redhat.com) > > > > > > Support Free Java! > > > Contribute to GNU Classpath and IcedTea > > > http://www.gnu.org/software/classpath > > > http://icedtea.classpath.org > > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 > > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at redhat.com Thu Jan 20 18:19:40 2011 From: omajid at redhat.com (Omair Majid) Date: Thu, 20 Jan 2011 21:19:40 -0500 Subject: [icedtea-web] RFC: add binaries to jre/bin as well (was backport changeset 9397074c2c39 to icedtea-web 1.0) In-Reply-To: <20110120235936.GB22586@redhat.com> References: <4D387505.9090305@redhat.com> <20110120175752.GC18293@redhat.com> <20110120181821.GD18293@redhat.com> <4D388120.1030802@redhat.com> <20110120191542.GE18293@redhat.com> <4D38A1A0.6040501@redhat.com> <20110120235936.GB22586@redhat.com> Message-ID: <4D38ED3C.8070604@redhat.com> On 01/20/2011 06:59 PM, Deepak Bhole wrote: > * Omair Majid [2011-01-20 15:57]: >> >> The attached patch hacks the launcher so it simply passes along >> argv[0] to Netx as the system property "java.icedtea-web.bin". Netx >> can then run itself by running the value of this system property. >> >> Can you please look over the patch to see if it makes sense? >> > > I don't think it needs to be that complex (modifying the .c files and > all). Please see the patch I just posted in this thread: > > http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011814.html > > It is against HEAD and mitigates this issue. If approved, I can push it > into 1.0 after 9397074c2c39, otherwise I will post a subset thereof. > For 1.0, I agree that the patch I posted may be too complex. But going forward, when IcedTea-Web becomes installable under /usr/, it may be the only way of telling javaws how to invoke itself (and still being relocatable). Cheers, Omair From dbhole at redhat.com Thu Jan 20 18:53:33 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Thu, 20 Jan 2011 21:53:33 -0500 Subject: [icedtea-web] RFE: Fix for broken JRE dir install In-Reply-To: <20110121013228.GI4611@rivendell.middle-earth.co.uk> References: <20110120235619.GA22586@redhat.com> <20110121002225.GD4611@rivendell.middle-earth.co.uk> <20110121003724.GD22586@redhat.com> <20110121004614.GG4611@rivendell.middle-earth.co.uk> <20110121011017.GF22586@redhat.com> <20110121013228.GI4611@rivendell.middle-earth.co.uk> Message-ID: <20110121025333.GA24487@redhat.com> * Dr Andrew John Hughes [2011-01-20 20:32]: > On 20:10 Thu 20 Jan , Deepak Bhole wrote: > > * Dr Andrew John Hughes [2011-01-20 19:46]: > > snip... > Thanks for the review! I'm attaching a new patch that addresses all the issues discussed. ChangeLog: * Makefile.am ($(NETX_DIR)/launcher/%.o): Build javaws without the "-J-Djava.icedtea-web.bin=..." arg. (install-exec-local): Use new JRE_DIR_PREFIX variables rather than hardcoded '/jre' in pathname. Fix mechanism used to determine if links should be created in jre/bin. (install-data-local): Use new JRE_DIR_PREFIX variables rather than hardcoded '/jre' in pathname. (uninstall-local): Same. Also, remove all parent dirs of $(htmldir) until a non-empty one is encountered. * configure.ac: Set JRE_DIR_PREFIX to jre/ if prefix is a JDK dir and set it to empty if prefix apears to be a JRE dir. * netx/net/sourceforge/jnlp/Launcher.java (launchExternal): Revert back to using java.home when selecting javaws binary to execute for fork. I've also tweaked the link creation logic slightly as the previous logic was inadequate to handle jre dir installations correctly. I'll commit tomorrow if there are no further comments. Thanks, Deepak > > > > > > I don't follow. If the user specifies --prefix=/usr, your patch will be looking > > > in completely the wrong place. You shouldn't let the user specify the install > > > directory and then just completely ignore it and assume something else. > > > > > > I gather that /usr installation is broken in the code at present too, > > > but I don't see why we want to create even more breakage. > > > > > > > Fair enough. However in it's current incarnation, the JDK is relocatable > > just by copying the tree. Until we can support /usr installation, we > > need to install in the JDK tree, and while we are installation there, I > > would like icedtea-web to not be the reason why relocatability is > > broken... > > > > Ok, I approve reverting to java.home and the rest of this patch, bar > the copying changes, on the 1.0 branch only. It needs fixing properly > on the main tree and should not be reverted there. 1.1 should support > installing anywhere. > > > Cheers, > > Deepak > > > > > > > * Typo: whether not weather. > > > > > > > > > > > > > Doh! Thanks. > > > > > > > > Cheers, > > > > Deepak > > > > > > > > > > diff -r 06940cdcfef8 Makefile.am > > > > > > --- a/Makefile.am Thu Jan 20 11:06:41 2011 -0500 > > > > > > +++ b/Makefile.am Thu Jan 20 18:47:48 2011 -0500 > > > > > > @@ -103,37 +103,37 @@ > > > > > > clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs > > > > > > > > > > > > install-exec-local: > > > > > > - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) > > > > > > + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > > > > > > if ENABLE_PLUGIN > > > > > > - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ > > > > > > + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ > > > > > > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) > > > > > > - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > > > > > + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > > > > > endif > > > > > > - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > > > > > > + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > > > > > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > > > > > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > > > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > > > > rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > > > > > fi ; \ > > > > > > if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > > > > > > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > > > > > + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > > > > > fi ; \ > > > > > > fi > > > > > > - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > > > > > > + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > > > > > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > > > > > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > > > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > > > > rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > > > > > fi ; \ > > > > > > if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > > > > > > - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > > > > > > + cp -a $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin ; \ > > > > > > fi ; \ > > > > > > fi > > > > > > > > > > > > install-data-local: > > > > > > ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 > > > > > > ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 > > > > > > - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib > > > > > > + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > > > > > if ENABLE_DOCS > > > > > > ${mkinstalldirs} $(DESTDIR)$(htmldir) > > > > > > (cd ${abs_top_builddir}/docs/netx; \ > > > > > > @@ -151,23 +151,25 @@ > > > > > > endif > > > > > > > > > > > > uninstall-local: > > > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar > > > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp > > > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar > > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp > > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar > > > > > > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > > > > > > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > > > > > > rm -f $(DESTDIR)$(bindir)/javaws > > > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > > > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > > > > rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > > > > > fi > > > > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > > > > > > rm -f $(DESTDIR)$(bindir)/itweb-settings > > > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > > > > + if [ -e $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > > > > rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > > > > > fi > > > > > > - rm -rf $(DESTDIR)$(htmldir) > > > > > > + rm -rf $(DESTDIR)$(htmldir)/* > > > > > > + if [ -d $(DESTDIR)$(htmldir) ] ; then \ > > > > > > + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ > > > > > > + fi > > > > > > > > > > > > # Plugin > > > > > > > > > > > > @@ -350,7 +352,7 @@ > > > > > > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > > > > > > mkdir -p $(NETX_DIR)/launcher && \ > > > > > > $(CC) $(LAUNCHER_FLAGS) \ > > > > > > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > > > > > > + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ > > > > > > -DPROGNAME='"javaws"' -c -o $@ $< > > > > > > > > > > > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > > > > > > diff -r 06940cdcfef8 configure.ac > > > > > > --- a/configure.ac Thu Jan 20 11:06:41 2011 -0500 > > > > > > +++ b/configure.ac Thu Jan 20 18:47:48 2011 -0500 > > > > > > @@ -80,4 +80,12 @@ > > > > > > IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) > > > > > > IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE > > > > > > > > > > > > +# Set JRE prefix based on weather to-level prefix is a JDK dir or a JRE dir > > > > > > +if test -d ${prefix}/jre ; then > > > > > > + JRE_DIR_PREFIX="/jre" ; > > > > > > +else > > > > > > + JRE_DIR_PREFIX="" ; > > > > > > +fi ; > > > > > > +AC_SUBST([JRE_DIR_PREFIX]) > > > > > > + > > > > > > AC_OUTPUT > > > > > > diff -r 06940cdcfef8 netx/net/sourceforge/jnlp/Launcher.java > > > > > > --- a/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 11:06:41 2011 -0500 > > > > > > +++ b/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 18:47:48 2011 -0500 > > > > > > @@ -327,7 +327,12 @@ > > > > > > List commands = new LinkedList(); > > > > > > > > > > > > // this property is set by the javaws launcher to point to the javaws binary > > > > > > - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); > > > > > > + String pathToWebstartBinary = System.getProperty("java.home") + > > > > > > + File.separatorChar + > > > > > > + "bin" + > > > > > > + File.separatorChar + > > > > > > + "javaws"; > > > > > > + > > > > > > commands.add(pathToWebstartBinary); > > > > > > // use -Jargument format to pass arguments to the JVM through the launcher > > > > > > for (String arg : vmArgs) { > > > > > > > > > > > > > > > -- > > > > > Andrew :) > > > > > > > > > > Free Java Software Engineer > > > > > Red Hat, Inc. (http://www.redhat.com) > > > > > > > > > > Support Free Java! > > > > > Contribute to GNU Classpath and IcedTea > > > > > http://www.gnu.org/software/classpath > > > > > http://icedtea.classpath.org > > > > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > > > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 > > > > > > -- > > > Andrew :) > > > > > > Free Java Software Engineer > > > Red Hat, Inc. (http://www.redhat.com) > > > > > > Support Free Java! > > > Contribute to GNU Classpath and IcedTea > > > http://www.gnu.org/software/classpath > > > http://icedtea.classpath.org > > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 > > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 -------------- next part -------------- diff -r 43212217e9c0 Makefile.am --- a/Makefile.am Wed Dec 15 10:17:51 2010 -0500 +++ b/Makefile.am Thu Jan 20 21:51:05 2011 -0500 @@ -102,37 +102,29 @@ clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs install-exec-local: - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) if ENABLE_PLUGIN - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar endif - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ - fi ; \ - if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ - fi ; \ + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ + ln -sf $(DESTDIR)$(prefix)/jre/bin/javaws $(DESTDIR)$(bindir)/javaws ; \ fi - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ - fi ; \ - if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ - fi ; \ + cp -a $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ + ln -sf $(DESTDIR)$(prefix)/jre/bin/itweb-settings $(DESTDIR)$(bindir)/itweb-settings ; \ fi install-data-local: ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib if ENABLE_DOCS ${mkinstalldirs} $(DESTDIR)$(htmldir) (cd ${abs_top_builddir}/docs/netx; \ @@ -150,23 +142,25 @@ endif uninstall-local: - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 rm -f $(DESTDIR)$(bindir)/pluginappletviewer - rm -f $(DESTDIR)$(bindir)/javaws - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/javaws + if [ -L $(DESTDIR)$(prefix)/bin/javaws ] ; then \ + rm -f $(DESTDIR)$(prefix)/bin/javaws ; \ fi - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws - rm -f $(DESTDIR)$(bindir)/itweb-settings - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/itweb-settings + if [ -L $(DESTDIR)$(prefix)/bin/itweb-settings ] ; then \ + rm -f $(DESTDIR)$(prefix)/bin/itweb-settings ; \ fi - rm -rf $(DESTDIR)$(htmldir) + rm -rf $(DESTDIR)$(htmldir)/* + if [ -d $(DESTDIR)$(htmldir) ] ; then \ + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ + fi # Plugin @@ -349,7 +343,7 @@ $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c mkdir -p $(NETX_DIR)/launcher && \ $(CC) $(LAUNCHER_FLAGS) \ - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ -DPROGNAME='"javaws"' -c -o $@ $< $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c diff -r 43212217e9c0 configure.ac --- a/configure.ac Wed Dec 15 10:17:51 2010 -0500 +++ b/configure.ac Thu Jan 20 21:51:05 2011 -0500 @@ -78,4 +78,12 @@ IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE +# Set JRE prefix based on whether to-level prefix is a JDK dir or a JRE dir +if test -d ${prefix}/jre ; then + JRE_DIR_PREFIX="/jre" ; +else + JRE_DIR_PREFIX="" ; +fi ; +AC_SUBST([JRE_DIR_PREFIX]) + AC_OUTPUT diff -r 43212217e9c0 netx/net/sourceforge/jnlp/Launcher.java --- a/netx/net/sourceforge/jnlp/Launcher.java Wed Dec 15 10:17:51 2010 -0500 +++ b/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 21:51:05 2011 -0500 @@ -330,7 +330,12 @@ List commands = new LinkedList(); // this property is set by the javaws launcher to point to the javaws binary - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); + String pathToWebstartBinary = System.getProperty("java.home") + + File.separatorChar + + "bin" + + File.separatorChar + + "javaws"; + commands.add(pathToWebstartBinary); // use -Jargument format to pass arguments to the JVM through the launcher for (String arg : vmArgs) { From ahughes at redhat.com Fri Jan 21 05:05:30 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 21 Jan 2011 13:05:30 +0000 Subject: Patch to make icedtea-web work with icedtea In-Reply-To: <20110121015619.GG22586@redhat.com> References: <20110121002713.GC22586@redhat.com> <20110121003324.GE4611@rivendell.middle-earth.co.uk> <20110121003932.GE22586@redhat.com> <20110121011041.GH4611@rivendell.middle-earth.co.uk> <20110121015619.GG22586@redhat.com> Message-ID: <20110121130530.GB13935@rivendell.middle-earth.co.uk> On 20:56 Thu 20 Jan , Deepak Bhole wrote: > * Dr Andrew John Hughes [2011-01-20 20:10]: > > On 19:39 Thu 20 Jan , Deepak Bhole wrote: > > > * Dr Andrew John Hughes [2011-01-20 19:33]: > > > > On 19:27 Thu 20 Jan , Deepak Bhole wrote: > > > > > Hi, > > > > > > > > > > Unlike icedtea6, icedtea currently does not append plugin.jar and > > > > > netx.jar to the default boot classpath. > > > > > > > > > > Attached patch makes it so that like icedtea6, the bootclasspath update > > > > > is moved to a separate patch which updates for rhino, netx and plugin. > > > > > > > > > > After applying this patch, icedtea-web works correctly with icedtea. > > > > > > > > > > Cheers, > > > > > Deepak > > > > > > > > Doesn't this need to be conditional on Rhino being installed? > > > > > > > > > > Having a jar that doesn't exist in the classpath has no ill effect. In > > > icedtea6 we do the same thing, rhino is always on classpath whether it > > > is enabled or disabled. > > > > > > > Ok, well presumably you do need to remove 'icedtea-rhino.patch' from Makefile.am? :-) > > > > Nope, that one will still be needed as it wires in the rest of the rhino > support. > > The reason the hunk related to classpath change was removed was because > the change to add rhino.jar and netx/plugin.jar would interfere with > each other, making one patch dependent on the other. That's why the > whole 'classpath update' part was moved to a separate part in icedtea6. > Yeah, I get that. I forgot there was anything else to the patch. Ok, approved. > Cheers, > Deepak > > > > > Also please just use patches. IcedTea7 only supports one HotSpot version. > > > > > > > > > > Ah sorry, I wasn't aware of that. > > > > > > Cheers, > > > Deepak > > > > > > > > diff -r 93ac4fddecf3 Makefile.am > > > > > --- a/Makefile.am Fri Dec 10 13:43:00 2010 +0000 > > > > > +++ b/Makefile.am Thu Jan 20 19:19:28 2011 -0500 > > > > > @@ -303,7 +303,8 @@ > > > > > patches/no-precompiled.patch \ > > > > > patches/parisc.patch \ > > > > > patches/sh4-support.patch \ > > > > > - patches/jtreg-httpTest.patch > > > > > + patches/jtreg-httpTest.patch \ > > > > > + patches/hotspot/$(HSBUILD)/icedtea-update-bootclasspath.patch > > > > > > > > > > # Conditional patches > > > > > > > > > > diff -r 93ac4fddecf3 patches/hotspot/default/icedtea-update-bootclasspath.patch > > > > > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > > > > > +++ b/patches/hotspot/default/icedtea-update-bootclasspath.patch Thu Jan 20 19:19:28 2011 -0500 > > > > > @@ -0,0 +1,13 @@ > > > > > +diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/os.cpp openjdk/hotspot/src/share/vm/runtime/os.cpp > > > > > +--- openjdk.orig/hotspot/src/share/vm/runtime/os.cpp 2010-09-01 01:23:45.000000000 +0100 > > > > > ++++ openjdk/hotspot/src/share/vm/runtime/os.cpp 2010-09-19 17:34:30.859345954 +0100 > > > > > +@@ -1032,6 +1032,9 @@ > > > > > + "%/lib/jsse.jar:" > > > > > + "%/lib/jce.jar:" > > > > > + "%/lib/charsets.jar:" > > > > > ++ "%/lib/netx.jar:" > > > > > ++ "%/lib/plugin.jar:" > > > > > ++ "%/lib/rhino.jar:" > > > > > + > > > > > + // ## TEMPORARY hack to keep the legacy launcher working when > > > > > + // ## only the boot module is installed (cf. j.l.ClassLoader) > > > > > diff -r 93ac4fddecf3 patches/icedtea-rhino.patch > > > > > --- a/patches/icedtea-rhino.patch Fri Dec 10 13:43:00 2010 +0000 > > > > > +++ b/patches/icedtea-rhino.patch Thu Jan 20 19:19:28 2011 -0500 > > > > > @@ -1,16 +1,3 @@ > > > > > -diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/os.cpp openjdk/hotspot/src/share/vm/runtime/os.cpp > > > > > ---- openjdk.orig/hotspot/src/share/vm/runtime/os.cpp 2010-08-27 19:15:27.000000000 +0100 > > > > > -+++ openjdk/hotspot/src/share/vm/runtime/os.cpp 2010-09-01 18:12:38.850408989 +0100 > > > > > -@@ -1033,6 +1033,9 @@ > > > > > - "%/lib/jce.jar:" > > > > > - "%/lib/charsets.jar:" > > > > > - > > > > > -+ // IcedTea addition to support Rhino via javax.script > > > > > -+ "%/lib/rhino.jar:" > > > > > -+ > > > > > - // ## TEMPORARY hack to keep the legacy launcher working when > > > > > - // ## only the boot module is installed (cf. j.l.ClassLoader) > > > > > - "%/lib/modules/jdk.boot.jar:" > > > > > diff -Nru openjdk.orig/jdk/make/com/sun/Makefile openjdk/jdk/make/com/sun/Makefile > > > > > --- openjdk.orig/jdk/make/com/sun/Makefile 2010-07-29 21:55:26.000000000 +0100 > > > > > +++ openjdk/jdk/make/com/sun/Makefile 2010-09-01 18:08:22.164610031 +0100 > > > > > > > > > > > > -- > > > > Andrew :) > > > > > > > > Free Java Software Engineer > > > > Red Hat, Inc. (http://www.redhat.com) > > > > > > > > Support Free Java! > > > > Contribute to GNU Classpath and IcedTea > > > > http://www.gnu.org/software/classpath > > > > http://icedtea.classpath.org > > > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 > > > > -- > > Andrew :) > > > > Free Java Software Engineer > > Red Hat, Inc. (http://www.redhat.com) > > > > Support Free Java! > > Contribute to GNU Classpath and IcedTea > > http://www.gnu.org/software/classpath > > http://icedtea.classpath.org > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Fri Jan 21 05:35:40 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 21 Jan 2011 13:35:40 +0000 Subject: [icedtea-web] RFE: Fix for broken JRE dir install In-Reply-To: <20110121025333.GA24487@redhat.com> References: <20110120235619.GA22586@redhat.com> <20110121002225.GD4611@rivendell.middle-earth.co.uk> <20110121003724.GD22586@redhat.com> <20110121004614.GG4611@rivendell.middle-earth.co.uk> <20110121011017.GF22586@redhat.com> <20110121013228.GI4611@rivendell.middle-earth.co.uk> <20110121025333.GA24487@redhat.com> Message-ID: <20110121133540.GC13935@rivendell.middle-earth.co.uk> On 21:53 Thu 20 Jan , Deepak Bhole wrote: > * Dr Andrew John Hughes [2011-01-20 20:32]: > > On 20:10 Thu 20 Jan , Deepak Bhole wrote: > > > * Dr Andrew John Hughes [2011-01-20 19:46]: > > > > snip... > > > > Thanks for the review! I'm attaching a new patch that addresses all the > issues discussed. > > ChangeLog: > * Makefile.am > ($(NETX_DIR)/launcher/%.o): Build javaws without the > "-J-Djava.icedtea-web.bin=..." arg. > (install-exec-local): Use new JRE_DIR_PREFIX variables rather than > hardcoded '/jre' in pathname. Fix mechanism used to determine if links > should be created in jre/bin. > (install-data-local): Use new JRE_DIR_PREFIX variables rather than > hardcoded '/jre' in pathname. > (uninstall-local): Same. Also, remove all parent dirs of $(htmldir) until > a non-empty one is encountered. > * configure.ac: Set JRE_DIR_PREFIX to jre/ if prefix is a JDK dir and set > it to empty if prefix apears to be a JRE dir. > * netx/net/sourceforge/jnlp/Launcher.java (launchExternal): Revert back to > using java.home when selecting javaws binary to execute for fork. > > I've also tweaked the link creation logic slightly as the previous logic was > inadequate to handle jre dir installations correctly. > > I'll commit tomorrow if there are no further comments. > This bit is confusing: > - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > - fi ; \ > - if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > - fi ; \ > + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > + ln -sf $(DESTDIR)$(prefix)/jre/bin/javaws $(DESTDIR)$(bindir)/javaws ; \ > fi Why are we still copying? I thought we agreed this didn't need changing? As I read this, it installs to jre/bin and then tries to also copy over the top from $(bindir) where nothing has been installed? If you're working with a jre tree, there won't be a jre/bin so the first line will install to $(DESTDIR)$(bindir) as before. If it's a JDK tree, it will install to jre/bin then try to copy from $(bindir) to jre/bin and fail. The existing logic seems fine (install to bindir, add a link in jre/bin if it exists). Why are you trying to change this and breaking it in the process? We already went through several revisions to get the current version. Please leave it as it is unless there is a very good reason to change it. I approve the JRE_DIR_PREFIX additions and the java.home logic for 1.0 ONLY. Please remove these other changes and post a new patch. > Thanks, > Deepak > > diff -r 43212217e9c0 Makefile.am > --- a/Makefile.am Wed Dec 15 10:17:51 2010 -0500 > +++ b/Makefile.am Thu Jan 20 21:51:05 2011 -0500 > @@ -102,37 +102,29 @@ > clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs > > install-exec-local: > - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) > + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > if ENABLE_PLUGIN > - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ > + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) > - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > endif > - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > - fi ; \ > - if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > - fi ; \ > + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > + ln -sf $(DESTDIR)$(prefix)/jre/bin/javaws $(DESTDIR)$(bindir)/javaws ; \ > fi > - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > - fi ; \ > - if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > - fi ; \ > + cp -a $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > + ln -sf $(DESTDIR)$(prefix)/jre/bin/itweb-settings $(DESTDIR)$(bindir)/itweb-settings ; \ > fi > > install-data-local: > ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 > ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 > - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib > + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > if ENABLE_DOCS > ${mkinstalldirs} $(DESTDIR)$(htmldir) > (cd ${abs_top_builddir}/docs/netx; \ > @@ -150,23 +142,25 @@ > endif > > uninstall-local: > - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar > - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > - rm -f $(DESTDIR)$(bindir)/javaws > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/javaws > + if [ -L $(DESTDIR)$(prefix)/bin/javaws ] ; then \ > + rm -f $(DESTDIR)$(prefix)/bin/javaws ; \ > fi > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > - rm -f $(DESTDIR)$(bindir)/itweb-settings > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/itweb-settings > + if [ -L $(DESTDIR)$(prefix)/bin/itweb-settings ] ; then \ > + rm -f $(DESTDIR)$(prefix)/bin/itweb-settings ; \ > fi > - rm -rf $(DESTDIR)$(htmldir) > + rm -rf $(DESTDIR)$(htmldir)/* > + if [ -d $(DESTDIR)$(htmldir) ] ; then \ > + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ > + fi > > # Plugin > > @@ -349,7 +343,7 @@ > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > mkdir -p $(NETX_DIR)/launcher && \ > $(CC) $(LAUNCHER_FLAGS) \ > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ > -DPROGNAME='"javaws"' -c -o $@ $< > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > diff -r 43212217e9c0 configure.ac > --- a/configure.ac Wed Dec 15 10:17:51 2010 -0500 > +++ b/configure.ac Thu Jan 20 21:51:05 2011 -0500 > @@ -78,4 +78,12 @@ > IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) > IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE > > +# Set JRE prefix based on whether to-level prefix is a JDK dir or a JRE dir > +if test -d ${prefix}/jre ; then > + JRE_DIR_PREFIX="/jre" ; > +else > + JRE_DIR_PREFIX="" ; > +fi ; > +AC_SUBST([JRE_DIR_PREFIX]) > + > AC_OUTPUT > diff -r 43212217e9c0 netx/net/sourceforge/jnlp/Launcher.java > --- a/netx/net/sourceforge/jnlp/Launcher.java Wed Dec 15 10:17:51 2010 -0500 > +++ b/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 21:51:05 2011 -0500 > @@ -330,7 +330,12 @@ > List commands = new LinkedList(); > > // this property is set by the javaws launcher to point to the javaws binary > - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); > + String pathToWebstartBinary = System.getProperty("java.home") + > + File.separatorChar + > + "bin" + > + File.separatorChar + > + "javaws"; > + > commands.add(pathToWebstartBinary); > // use -Jargument format to pass arguments to the JVM through the launcher > for (String arg : vmArgs) { -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Fri Jan 21 05:37:19 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 21 Jan 2011 13:37:19 +0000 Subject: [icedtea-web] RFC: add binaries to jre/bin as well (was backport changeset 9397074c2c39 to icedtea-web 1.0) In-Reply-To: <4D38ED3C.8070604@redhat.com> References: <4D387505.9090305@redhat.com> <20110120175752.GC18293@redhat.com> <20110120181821.GD18293@redhat.com> <4D388120.1030802@redhat.com> <20110120191542.GE18293@redhat.com> <4D38A1A0.6040501@redhat.com> <20110120235936.GB22586@redhat.com> <4D38ED3C.8070604@redhat.com> Message-ID: <20110121133719.GD13935@rivendell.middle-earth.co.uk> On 21:19 Thu 20 Jan , Omair Majid wrote: > On 01/20/2011 06:59 PM, Deepak Bhole wrote: > > * Omair Majid [2011-01-20 15:57]: > >> > >> The attached patch hacks the launcher so it simply passes along > >> argv[0] to Netx as the system property "java.icedtea-web.bin". Netx > >> can then run itself by running the value of this system property. > >> > >> Can you please look over the patch to see if it makes sense? > >> > > > > I don't think it needs to be that complex (modifying the .c files and > > all). Please see the patch I just posted in this thread: > > > > http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011814.html > > > > It is against HEAD and mitigates this issue. If approved, I can push it > > into 1.0 after 9397074c2c39, otherwise I will post a subset thereof. > > > > For 1.0, I agree that the patch I posted may be too complex. But going > forward, when IcedTea-Web becomes installable under /usr/, it may be the > only way of telling javaws how to invoke itself (and still being > relocatable). > I agree. Deepak's changes look like a hack to make the JDK tree installation work flexibly but break everything else. For 1.1, proper installation needs to be sorted for the plugin & NetX, and the existing version in HEAD works fine for this. > Cheers, > Omair -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at redhat.com Fri Jan 21 07:05:54 2011 From: omajid at redhat.com (Omair Majid) Date: Fri, 21 Jan 2011 10:05:54 -0500 Subject: [icedtea-web] RFC: add binaries to jre/bin as well (was backport changeset 9397074c2c39 to icedtea-web 1.0) In-Reply-To: <20110121133719.GD13935@rivendell.middle-earth.co.uk> References: <4D387505.9090305@redhat.com> <20110120175752.GC18293@redhat.com> <20110120181821.GD18293@redhat.com> <4D388120.1030802@redhat.com> <20110120191542.GE18293@redhat.com> <4D38A1A0.6040501@redhat.com> <20110120235936.GB22586@redhat.com> <4D38ED3C.8070604@redhat.com> <20110121133719.GD13935@rivendell.middle-earth.co.uk> Message-ID: <4D39A0D2.4030402@redhat.com> On 01/21/2011 08:37 AM, Dr Andrew John Hughes wrote: > > I agree. Deepak's changes look like a hack to make the JDK tree > installation work flexibly but break everything else. For 1.1, proper > installation needs to be sorted for the plugin& NetX, and the existing > version in HEAD works fine for this. > The version in HEAD suffers from a problem as Deepak pointed out: the binaries have the path coded in them at build time. If I move the binaries to a different location after building them, they will not work. This particular issue is what my patch to launcher/java.c addresses. Cheers, Omair From omajid at redhat.com Fri Jan 21 07:12:41 2011 From: omajid at redhat.com (Omair Majid) Date: Fri, 21 Jan 2011 10:12:41 -0500 Subject: [icedtea-web] RFC: Update NEWS file In-Reply-To: <20110121003829.GF4611@rivendell.middle-earth.co.uk> References: <4CF7BCE0.8080800@redhat.com> <20110120163325.GB18293@redhat.com> <20110121003829.GF4611@rivendell.middle-earth.co.uk> Message-ID: <4D39A269.5090104@redhat.com> On 01/20/2011 07:38 PM, Dr Andrew John Hughes wrote: > On 11:33 Thu 20 Jan , Deepak Bhole wrote: >> * Omair Majid [2010-12-02 12:17]: >>> Hi, >>> >>> The attached patch updates the NEWS file. It reorganizes things into >>> major/minor sections, so all important items are visible first. >>> >>> Thoughts/comments? >>> >> >> Sorry, I thought I had approved this. Okay for HEAD and 1.0. >> >> Cheers, >> Deepak >> > > Please don't apply as is. > I pushed the changeset before I saw this response. If you like, I can rollback. > The common, javaws and plugin headers look ugly and will break the NEWS generation I do for release. > Please use: > > * Common Minor Improvements and Fixes > * Java Web Start Minor Improvements and Fixes > * Plugin Minor Improvements and Fixes > > as headers instead. > I will do that in a new commit. Sorry about the mess :( Thanks, Omair From dbhole at redhat.com Fri Jan 21 07:13:27 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Fri, 21 Jan 2011 10:13:27 -0500 Subject: [icedtea-web] RFE: Fix for broken JRE dir install In-Reply-To: <20110121133540.GC13935@rivendell.middle-earth.co.uk> References: <20110120235619.GA22586@redhat.com> <20110121002225.GD4611@rivendell.middle-earth.co.uk> <20110121003724.GD22586@redhat.com> <20110121004614.GG4611@rivendell.middle-earth.co.uk> <20110121011017.GF22586@redhat.com> <20110121013228.GI4611@rivendell.middle-earth.co.uk> <20110121025333.GA24487@redhat.com> <20110121133540.GC13935@rivendell.middle-earth.co.uk> Message-ID: <20110121151327.GA10878@redhat.com> * Dr Andrew John Hughes [2011-01-21 08:35]: > On 21:53 Thu 20 Jan , Deepak Bhole wrote: > > * Dr Andrew John Hughes [2011-01-20 20:32]: > > > On 20:10 Thu 20 Jan , Deepak Bhole wrote: > > > > * Dr Andrew John Hughes [2011-01-20 19:46]: > > > > > > snip... > > > > > > > Thanks for the review! I'm attaching a new patch that addresses all the > > issues discussed. > > > > ChangeLog: > > * Makefile.am > > ($(NETX_DIR)/launcher/%.o): Build javaws without the > > "-J-Djava.icedtea-web.bin=..." arg. > > (install-exec-local): Use new JRE_DIR_PREFIX variables rather than > > hardcoded '/jre' in pathname. Fix mechanism used to determine if links > > should be created in jre/bin. > > (install-data-local): Use new JRE_DIR_PREFIX variables rather than > > hardcoded '/jre' in pathname. > > (uninstall-local): Same. Also, remove all parent dirs of $(htmldir) until > > a non-empty one is encountered. > > * configure.ac: Set JRE_DIR_PREFIX to jre/ if prefix is a JDK dir and set > > it to empty if prefix apears to be a JRE dir. > > * netx/net/sourceforge/jnlp/Launcher.java (launchExternal): Revert back to > > using java.home when selecting javaws binary to execute for fork. > > > > I've also tweaked the link creation logic slightly as the previous logic was > > inadequate to handle jre dir installations correctly. > > > > I'll commit tomorrow if there are no further comments. > > > > This bit is confusing: > > > - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > - fi ; \ > > - if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > - fi ; \ > > + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > + ln -sf $(DESTDIR)$(prefix)/jre/bin/javaws $(DESTDIR)$(bindir)/javaws ; \ > > fi > > Why are we still copying? I thought we agreed this didn't need changing? > > As I read this, it installs to jre/bin and then tries to also copy over the top from > $(bindir) where nothing has been installed? If you're working with a jre tree, there > won't be a jre/bin so the first line will install to $(DESTDIR)$(bindir) as before. > If it's a JDK tree, it will install to jre/bin then try to copy from $(bindir) to > jre/bin and fail. > > The existing logic seems fine (install to bindir, add a link in jre/bin if it exists). > Why are you trying to change this and breaking it in the process? > > We already went through several revisions to get the current version. Please leave it > as it is unless there is a very good reason to change it. > > I approve the JRE_DIR_PREFIX additions and the java.home logic for 1.0 ONLY. > Please remove these other changes and post a new patch. > The previous logic was: "Install to JDK|JRE bin/; check if jre/bin exists; link there if so" This is incorrect because the _file_ should be in jre/bin and it must because of the way installations work with packages. RPM for example builds the whole tree, and divides it into subpackages. In such a case, if RPM were to split off JRE and install it, JRE/bin will have a dangling symlink. The new logic "Install to JDK/JRE bin; check if there is a JRE/bin; if yes, move the actual file to it, and link from JDK/bin; else leave it alone" This guarantees that the actual file will be in jre/bin, and should the prefix have been a JDK tree, a link will be created from JDK_BIN/bin to jre/bin/. Deepak > > Thanks, > > Deepak > > > > > diff -r 43212217e9c0 Makefile.am > > --- a/Makefile.am Wed Dec 15 10:17:51 2010 -0500 > > +++ b/Makefile.am Thu Jan 20 21:51:05 2011 -0500 > > @@ -102,37 +102,29 @@ > > clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs > > > > install-exec-local: > > - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) > > + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > > if ENABLE_PLUGIN > > - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ > > + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ > > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) > > - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > endif > > - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > > - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > > + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > - fi ; \ > > - if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > - fi ; \ > > + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > + ln -sf $(DESTDIR)$(prefix)/jre/bin/javaws $(DESTDIR)$(bindir)/javaws ; \ > > fi > > - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > > - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > > + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > - fi ; \ > > - if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > > - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > > - fi ; \ > > + cp -a $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > > + ln -sf $(DESTDIR)$(prefix)/jre/bin/itweb-settings $(DESTDIR)$(bindir)/itweb-settings ; \ > > fi > > > > install-data-local: > > ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 > > ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 > > - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib > > + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > if ENABLE_DOCS > > ${mkinstalldirs} $(DESTDIR)$(htmldir) > > (cd ${abs_top_builddir}/docs/netx; \ > > @@ -150,23 +142,25 @@ > > endif > > > > uninstall-local: > > - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar > > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > > - rm -f $(DESTDIR)$(bindir)/javaws > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/javaws > > + if [ -L $(DESTDIR)$(prefix)/bin/javaws ] ; then \ > > + rm -f $(DESTDIR)$(prefix)/bin/javaws ; \ > > fi > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > > - rm -f $(DESTDIR)$(bindir)/itweb-settings > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/itweb-settings > > + if [ -L $(DESTDIR)$(prefix)/bin/itweb-settings ] ; then \ > > + rm -f $(DESTDIR)$(prefix)/bin/itweb-settings ; \ > > fi > > - rm -rf $(DESTDIR)$(htmldir) > > + rm -rf $(DESTDIR)$(htmldir)/* > > + if [ -d $(DESTDIR)$(htmldir) ] ; then \ > > + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ > > + fi > > > > # Plugin > > > > @@ -349,7 +343,7 @@ > > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > > mkdir -p $(NETX_DIR)/launcher && \ > > $(CC) $(LAUNCHER_FLAGS) \ > > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > > + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ > > -DPROGNAME='"javaws"' -c -o $@ $< > > > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > > diff -r 43212217e9c0 configure.ac > > --- a/configure.ac Wed Dec 15 10:17:51 2010 -0500 > > +++ b/configure.ac Thu Jan 20 21:51:05 2011 -0500 > > @@ -78,4 +78,12 @@ > > IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) > > IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE > > > > +# Set JRE prefix based on whether to-level prefix is a JDK dir or a JRE dir > > +if test -d ${prefix}/jre ; then > > + JRE_DIR_PREFIX="/jre" ; > > +else > > + JRE_DIR_PREFIX="" ; > > +fi ; > > +AC_SUBST([JRE_DIR_PREFIX]) > > + > > AC_OUTPUT > > diff -r 43212217e9c0 netx/net/sourceforge/jnlp/Launcher.java > > --- a/netx/net/sourceforge/jnlp/Launcher.java Wed Dec 15 10:17:51 2010 -0500 > > +++ b/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 21:51:05 2011 -0500 > > @@ -330,7 +330,12 @@ > > List commands = new LinkedList(); > > > > // this property is set by the javaws launcher to point to the javaws binary > > - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); > > + String pathToWebstartBinary = System.getProperty("java.home") + > > + File.separatorChar + > > + "bin" + > > + File.separatorChar + > > + "javaws"; > > + > > commands.add(pathToWebstartBinary); > > // use -Jargument format to pass arguments to the JVM through the launcher > > for (String arg : vmArgs) { > > > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From dbhole at redhat.com Fri Jan 21 07:18:39 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Fri, 21 Jan 2011 10:18:39 -0500 Subject: [icedtea-web] RFC: add binaries to jre/bin as well (was backport changeset 9397074c2c39 to icedtea-web 1.0) In-Reply-To: <20110121133719.GD13935@rivendell.middle-earth.co.uk> References: <4D387505.9090305@redhat.com> <20110120175752.GC18293@redhat.com> <20110120181821.GD18293@redhat.com> <4D388120.1030802@redhat.com> <20110120191542.GE18293@redhat.com> <4D38A1A0.6040501@redhat.com> <20110120235936.GB22586@redhat.com> <4D38ED3C.8070604@redhat.com> <20110121133719.GD13935@rivendell.middle-earth.co.uk> Message-ID: <20110121151839.GB10878@redhat.com> * Dr Andrew John Hughes [2011-01-21 08:37]: > On 21:19 Thu 20 Jan , Omair Majid wrote: > > On 01/20/2011 06:59 PM, Deepak Bhole wrote: > > > * Omair Majid [2011-01-20 15:57]: > > >> > > >> The attached patch hacks the launcher so it simply passes along > > >> argv[0] to Netx as the system property "java.icedtea-web.bin". Netx > > >> can then run itself by running the value of this system property. > > >> > > >> Can you please look over the patch to see if it makes sense? > > >> > > > > > > I don't think it needs to be that complex (modifying the .c files and > > > all). Please see the patch I just posted in this thread: > > > > > > http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011814.html > > > > > > It is against HEAD and mitigates this issue. If approved, I can push it > > > into 1.0 after 9397074c2c39, otherwise I will post a subset thereof. > > > > > > > For 1.0, I agree that the patch I posted may be too complex. But going > > forward, when IcedTea-Web becomes installable under /usr/, it may be the > > only way of telling javaws how to invoke itself (and still being > > relocatable). > > > > I agree. Deepak's changes look like a hack to make the JDK tree > installation work flexibly but break everything else. For 1.1, proper > installation needs to be sorted for the plugin & NetX, and the existing > version in HEAD works fine for this. > Can you clarify what you mean by 'break everything else'? JRE dir installation is broken, plain and simple. Even if we were to let that be, the Launcher.java change has to be made as the JDK is un-relocatable in its current state. This is a major issue. Something like icedtea-web should never remove that sort of flexibility. That said, I do agree, that the solution will need rework for 1.1. Deepak > > Cheers, > > Omair > > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Fri Jan 21 08:00:02 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 21 Jan 2011 16:00:02 +0000 Subject: [icedtea-web] RFC: Update NEWS file In-Reply-To: <4D39A269.5090104@redhat.com> References: <4CF7BCE0.8080800@redhat.com> <20110120163325.GB18293@redhat.com> <20110121003829.GF4611@rivendell.middle-earth.co.uk> <4D39A269.5090104@redhat.com> Message-ID: <20110121160002.GF13935@rivendell.middle-earth.co.uk> On 10:12 Fri 21 Jan , Omair Majid wrote: > On 01/20/2011 07:38 PM, Dr Andrew John Hughes wrote: > > On 11:33 Thu 20 Jan , Deepak Bhole wrote: > >> * Omair Majid [2010-12-02 12:17]: > >>> Hi, > >>> > >>> The attached patch updates the NEWS file. It reorganizes things into > >>> major/minor sections, so all important items are visible first. > >>> > >>> Thoughts/comments? > >>> > >> > >> Sorry, I thought I had approved this. Okay for HEAD and 1.0. > >> > >> Cheers, > >> Deepak > >> > > > > Please don't apply as is. > > > > I pushed the changeset before I saw this response. If you like, I can > rollback. > > > The common, javaws and plugin headers look ugly and will break the NEWS generation I do for release. > > Please use: > > > > * Common Minor Improvements and Fixes > > * Java Web Start Minor Improvements and Fixes > > * Plugin Minor Improvements and Fixes > > > > as headers instead. > > > > I will do that in a new commit. Sorry about the mess :( > Yes, just apply the changes to fix that section. Thanks. > Thanks, > Omair -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From asu at redhat.com Fri Jan 21 08:56:57 2011 From: asu at redhat.com (Andrew Su) Date: Fri, 21 Jan 2011 11:56:57 -0500 (EST) Subject: [Review][IcedTea-Web]: Add tracing to itw In-Reply-To: <815713470.64555.1295628944245.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Message-ID: <1124998606.64615.1295629017350.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Hello, Here is a patch to add some tracing to indicate which part of the plugin is being executed at the moment. There are still some more places to add the traces to, so it's only a preview to see if there are any objections to how it's being done. Cheers, Andrew -------------- next part -------------- A non-text attachment was scrubbed... Name: 20110121_add_trace_partial_v2.patch Type: text/x-patch Size: 14970 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110121/7d23263d/20110121_add_trace_partial_v2.patch From dbhole at redhat.com Fri Jan 21 09:21:50 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Fri, 21 Jan 2011 12:21:50 -0500 Subject: Patch to make icedtea-web work with icedtea In-Reply-To: <20110121130530.GB13935@rivendell.middle-earth.co.uk> References: <20110121002713.GC22586@redhat.com> <20110121003324.GE4611@rivendell.middle-earth.co.uk> <20110121003932.GE22586@redhat.com> <20110121011041.GH4611@rivendell.middle-earth.co.uk> <20110121015619.GG22586@redhat.com> <20110121130530.GB13935@rivendell.middle-earth.co.uk> Message-ID: <20110121172149.GA12250@redhat.com> * Dr Andrew John Hughes [2011-01-21 08:05]: > On 20:56 Thu 20 Jan , Deepak Bhole wrote: > > * Dr Andrew John Hughes [2011-01-20 20:10]: > > > On 19:39 Thu 20 Jan , Deepak Bhole wrote: > > > > * Dr Andrew John Hughes [2011-01-20 19:33]: > > > > > On 19:27 Thu 20 Jan , Deepak Bhole wrote: > > > > > > Hi, > > > > > > > > > > > > Unlike icedtea6, icedtea currently does not append plugin.jar and > > > > > > netx.jar to the default boot classpath. > > > > > > > > > > > > Attached patch makes it so that like icedtea6, the bootclasspath update > > > > > > is moved to a separate patch which updates for rhino, netx and plugin. > > > > > > > > > > > > After applying this patch, icedtea-web works correctly with icedtea. > > > > > > > > > > > > Cheers, > > > > > > Deepak > > > > > > > > > > Doesn't this need to be conditional on Rhino being installed? > > > > > > > > > > > > > Having a jar that doesn't exist in the classpath has no ill effect. In > > > > icedtea6 we do the same thing, rhino is always on classpath whether it > > > > is enabled or disabled. > > > > > > > > > > Ok, well presumably you do need to remove 'icedtea-rhino.patch' from Makefile.am? :-) > > > > > > > Nope, that one will still be needed as it wires in the rest of the rhino > > support. > > > > The reason the hunk related to classpath change was removed was because > > the change to add rhino.jar and netx/plugin.jar would interfere with > > each other, making one patch dependent on the other. That's why the > > whole 'classpath update' part was moved to a separate part in icedtea6. > > > > Yeah, I get that. I forgot there was anything else to the patch. > > Ok, approved. > Thanks! Pushed after moving patch into patches and updating Makefile.am. Cheers, Deepak > > Cheers, > > Deepak > > > > > > > Also please just use patches. IcedTea7 only supports one HotSpot version. > > > > > > > > > > > > > Ah sorry, I wasn't aware of that. > > > > > > > > Cheers, > > > > Deepak > > > > > > > > > > diff -r 93ac4fddecf3 Makefile.am > > > > > > --- a/Makefile.am Fri Dec 10 13:43:00 2010 +0000 > > > > > > +++ b/Makefile.am Thu Jan 20 19:19:28 2011 -0500 > > > > > > @@ -303,7 +303,8 @@ > > > > > > patches/no-precompiled.patch \ > > > > > > patches/parisc.patch \ > > > > > > patches/sh4-support.patch \ > > > > > > - patches/jtreg-httpTest.patch > > > > > > + patches/jtreg-httpTest.patch \ > > > > > > + patches/hotspot/$(HSBUILD)/icedtea-update-bootclasspath.patch > > > > > > > > > > > > # Conditional patches > > > > > > > > > > > > diff -r 93ac4fddecf3 patches/hotspot/default/icedtea-update-bootclasspath.patch > > > > > > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > > > > > > +++ b/patches/hotspot/default/icedtea-update-bootclasspath.patch Thu Jan 20 19:19:28 2011 -0500 > > > > > > @@ -0,0 +1,13 @@ > > > > > > +diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/os.cpp openjdk/hotspot/src/share/vm/runtime/os.cpp > > > > > > +--- openjdk.orig/hotspot/src/share/vm/runtime/os.cpp 2010-09-01 01:23:45.000000000 +0100 > > > > > > ++++ openjdk/hotspot/src/share/vm/runtime/os.cpp 2010-09-19 17:34:30.859345954 +0100 > > > > > > +@@ -1032,6 +1032,9 @@ > > > > > > + "%/lib/jsse.jar:" > > > > > > + "%/lib/jce.jar:" > > > > > > + "%/lib/charsets.jar:" > > > > > > ++ "%/lib/netx.jar:" > > > > > > ++ "%/lib/plugin.jar:" > > > > > > ++ "%/lib/rhino.jar:" > > > > > > + > > > > > > + // ## TEMPORARY hack to keep the legacy launcher working when > > > > > > + // ## only the boot module is installed (cf. j.l.ClassLoader) > > > > > > diff -r 93ac4fddecf3 patches/icedtea-rhino.patch > > > > > > --- a/patches/icedtea-rhino.patch Fri Dec 10 13:43:00 2010 +0000 > > > > > > +++ b/patches/icedtea-rhino.patch Thu Jan 20 19:19:28 2011 -0500 > > > > > > @@ -1,16 +1,3 @@ > > > > > > -diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/os.cpp openjdk/hotspot/src/share/vm/runtime/os.cpp > > > > > > ---- openjdk.orig/hotspot/src/share/vm/runtime/os.cpp 2010-08-27 19:15:27.000000000 +0100 > > > > > > -+++ openjdk/hotspot/src/share/vm/runtime/os.cpp 2010-09-01 18:12:38.850408989 +0100 > > > > > > -@@ -1033,6 +1033,9 @@ > > > > > > - "%/lib/jce.jar:" > > > > > > - "%/lib/charsets.jar:" > > > > > > - > > > > > > -+ // IcedTea addition to support Rhino via javax.script > > > > > > -+ "%/lib/rhino.jar:" > > > > > > -+ > > > > > > - // ## TEMPORARY hack to keep the legacy launcher working when > > > > > > - // ## only the boot module is installed (cf. j.l.ClassLoader) > > > > > > - "%/lib/modules/jdk.boot.jar:" > > > > > > diff -Nru openjdk.orig/jdk/make/com/sun/Makefile openjdk/jdk/make/com/sun/Makefile > > > > > > --- openjdk.orig/jdk/make/com/sun/Makefile 2010-07-29 21:55:26.000000000 +0100 > > > > > > +++ openjdk/jdk/make/com/sun/Makefile 2010-09-01 18:08:22.164610031 +0100 > > > > > > > > > > > > > > > -- > > > > > Andrew :) > > > > > > > > > > Free Java Software Engineer > > > > > Red Hat, Inc. (http://www.redhat.com) > > > > > > > > > > Support Free Java! > > > > > Contribute to GNU Classpath and IcedTea > > > > > http://www.gnu.org/software/classpath > > > > > http://icedtea.classpath.org > > > > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > > > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 > > > > > > -- > > > Andrew :) > > > > > > Free Java Software Engineer > > > Red Hat, Inc. (http://www.redhat.com) > > > > > > Support Free Java! > > > Contribute to GNU Classpath and IcedTea > > > http://www.gnu.org/software/classpath > > > http://icedtea.classpath.org > > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 > > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From dbhole at icedtea.classpath.org Fri Jan 21 09:25:40 2011 From: dbhole at icedtea.classpath.org (dbhole at icedtea.classpath.org) Date: Fri, 21 Jan 2011 17:25:40 +0000 Subject: /hg/icedtea: Added netx.jar and plugin.jar to bootclasspath to m... Message-ID: changeset ee7d7790fcc7 in /hg/icedtea details: http://icedtea.classpath.org/hg/icedtea?cmd=changeset;node=ee7d7790fcc7 author: Deepak Bhole date: Fri Jan 21 12:20:56 2011 -0500 Added netx.jar and plugin.jar to bootclasspath to make icedtea-web work with icedtea Updated rhino patch to move classpath update into a separate update- bootclasspath patch diffstat: 4 files changed, 24 insertions(+), 14 deletions(-) ChangeLog | 9 +++++++++ Makefile.am | 3 ++- patches/icedtea-rhino.patch | 13 ------------- patches/icedtea-update-bootclasspath.patch | 13 +++++++++++++ diffs (66 lines): diff -r 93ac4fddecf3 -r ee7d7790fcc7 ChangeLog --- a/ChangeLog Fri Dec 10 13:43:00 2010 +0000 +++ b/ChangeLog Fri Jan 21 12:20:56 2011 -0500 @@ -1,3 +1,12 @@ 2010-12-09 Andrew John Hughes + + * Makefile.am + (ICEDTEA_PATCHES): Apply the new icedtea-update-bootclasspath patch. + * patches/hotspot/default/icedtea-update-bootclasspath.patch: New patch. + Adds rhino.jar, netx.jar and plugin.jar to the default boot classpath. + * patches/icedtea-rhino.patch: Remove the classpath update hunk, as it has + now been moved to icedtea-update-bootclasspath.patch. + 2010-12-09 Andrew John Hughes * patches/hotspot/default/icedtea-gcc-4.3.patch, diff -r 93ac4fddecf3 -r ee7d7790fcc7 Makefile.am --- a/Makefile.am Fri Dec 10 13:43:00 2010 +0000 +++ b/Makefile.am Fri Jan 21 12:20:56 2011 -0500 @@ -303,7 +303,8 @@ ICEDTEA_PATCHES = \ patches/no-precompiled.patch \ patches/parisc.patch \ patches/sh4-support.patch \ - patches/jtreg-httpTest.patch + patches/jtreg-httpTest.patch \ + patches/icedtea-update-bootclasspath.patch # Conditional patches diff -r 93ac4fddecf3 -r ee7d7790fcc7 patches/icedtea-rhino.patch --- a/patches/icedtea-rhino.patch Fri Dec 10 13:43:00 2010 +0000 +++ b/patches/icedtea-rhino.patch Fri Jan 21 12:20:56 2011 -0500 @@ -1,16 +1,3 @@ diff -Nru openjdk.orig/hotspot/src/share -diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/os.cpp openjdk/hotspot/src/share/vm/runtime/os.cpp ---- openjdk.orig/hotspot/src/share/vm/runtime/os.cpp 2010-08-27 19:15:27.000000000 +0100 -+++ openjdk/hotspot/src/share/vm/runtime/os.cpp 2010-09-01 18:12:38.850408989 +0100 -@@ -1033,6 +1033,9 @@ - "%/lib/jce.jar:" - "%/lib/charsets.jar:" - -+ // IcedTea addition to support Rhino via javax.script -+ "%/lib/rhino.jar:" -+ - // ## TEMPORARY hack to keep the legacy launcher working when - // ## only the boot module is installed (cf. j.l.ClassLoader) - "%/lib/modules/jdk.boot.jar:" diff -Nru openjdk.orig/jdk/make/com/sun/Makefile openjdk/jdk/make/com/sun/Makefile --- openjdk.orig/jdk/make/com/sun/Makefile 2010-07-29 21:55:26.000000000 +0100 +++ openjdk/jdk/make/com/sun/Makefile 2010-09-01 18:08:22.164610031 +0100 diff -r 93ac4fddecf3 -r ee7d7790fcc7 patches/icedtea-update-bootclasspath.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/icedtea-update-bootclasspath.patch Fri Jan 21 12:20:56 2011 -0500 @@ -0,0 +1,13 @@ +diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/os.cpp openjdk/hotspot/src/share/vm/runtime/os.cpp +--- openjdk.orig/hotspot/src/share/vm/runtime/os.cpp 2010-09-01 01:23:45.000000000 +0100 ++++ openjdk/hotspot/src/share/vm/runtime/os.cpp 2010-09-19 17:34:30.859345954 +0100 +@@ -1032,6 +1032,9 @@ + "%/lib/jsse.jar:" + "%/lib/jce.jar:" + "%/lib/charsets.jar:" ++ "%/lib/netx.jar:" ++ "%/lib/plugin.jar:" ++ "%/lib/rhino.jar:" + + // ## TEMPORARY hack to keep the legacy launcher working when + // ## only the boot module is installed (cf. j.l.ClassLoader) From mark at klomp.org Fri Jan 21 11:26:35 2011 From: mark at klomp.org (Mark Wielaard) Date: Fri, 21 Jan 2011 20:26:35 +0100 (CET) Subject: Transplant --with-llvm-config support from icedtea6 to icedtea Message-ID: <44453.80.101.103.228.1295637995.squirrel@gnu.wildebeest.org> Hi, On debian based systems you can have multiple llvms installed, icedtea6 already contained a patch from Matthias to support this. I just transplanted it to icedtea[7] (the new autobuilder runs on a Debian squeeze setup). Cheers, Mark -------------- next part -------------- A non-text attachment was scrubbed... Name: llvm-config.patch Type: text/x-diff Size: 2533 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110121/fe33811e/llvm-config.patch From mjw at icedtea.classpath.org Fri Jan 21 11:29:50 2011 From: mjw at icedtea.classpath.org (mjw at icedtea.classpath.org) Date: Fri, 21 Jan 2011 19:29:50 +0000 Subject: /hg/icedtea: New configure option --with-llvm-config Message-ID: changeset da307731d8d2 in /hg/icedtea details: http://icedtea.classpath.org/hg/icedtea?cmd=changeset;node=da307731d8d2 author: doko at ubuntu.com date: Thu Oct 14 13:25:44 2010 +0200 New configure option --with-llvm-config 2010-10-14 Matthias Klose * configure.ac: New option --with-llvm-config. * INSTALL: Document it. diffstat: 3 files changed, 22 insertions(+), 1 deletion(-) ChangeLog | 5 +++++ INSTALL | 1 + configure.ac | 17 ++++++++++++++++- diffs (51 lines): diff -r ee7d7790fcc7 -r da307731d8d2 ChangeLog --- a/ChangeLog Fri Jan 21 12:20:56 2011 -0500 +++ b/ChangeLog Thu Oct 14 13:25:44 2010 +0200 @@ -1,3 +1,8 @@ 2011-01-21 Deepak Bhole + + * configure.ac: New option --with-llvm-config. + * INSTALL: Document it. + 2011-01-21 Deepak Bhole * Makefile.am diff -r ee7d7790fcc7 -r da307731d8d2 INSTALL --- a/INSTALL Fri Jan 21 12:20:56 2011 -0500 +++ b/INSTALL Thu Oct 14 13:25:44 2010 +0200 @@ -152,6 +152,7 @@ to configure: * --with-tzdata-dir: Specify the location of Java timezone data, defaulting to /usr/share/javazi. * --with-netbeans: Specify the location of NetBeans for VisualVM, defaulting to the netbeans on the path. * --with-abs-install-dir: The final install location of the j2sdk-image, for use in the SystemTap tapset. +* --with-llvm-config: Specify the location of the llvm-config binary. * --with-version-suffix: Appends the given text to the JDK version output. * --with-project: Build an OpenJDK project from the following: icedtea, jdk7, closures, cvmi, cacaiocavallo, bsd, nio2. The default is icedtea. Use of others is at the user's risk and builds may fail. This setting diff -r ee7d7790fcc7 -r da307731d8d2 configure.ac --- a/configure.ac Fri Jan 21 12:20:56 2011 -0500 +++ b/configure.ac Thu Oct 14 13:25:44 2010 +0200 @@ -391,8 +391,23 @@ AC_SUBST(LIBFFI_CFLAGS) AC_SUBST(LIBFFI_CFLAGS) AC_SUBST(LIBFFI_LIBS) +AC_ARG_WITH([llvm-config], + [AS_HELP_STRING([--with-llvm-config], + [llvm-config binary (default is llvm-config)])], + [ + if test "x${withval}" != x; then + if which ${withval} >/dev/null 2>&1 && ${withval} --version >/dev/null 2>&1; then + LLVM_CONFIG=${withval} + else + AC_MSG_ERROR([invalid argument for --with-llvm-config ($withval)]) + fi + fi + ]) + if test "x${SHARK_BUILD_TRUE}" = x || test "x${ADD_SHARK_BUILD_TRUE}" = x; then - FIND_TOOL([LLVM_CONFIG], [llvm-config]) + if test "x${LLVM_CONFIG}" = x; then + FIND_TOOL([LLVM_CONFIG], [llvm-config]) + fi llvm_components="jit engine nativecodegen" LLVM_VERSION="`$LLVM_CONFIG --version`" dnl LLVM_CFLAGS From ahughes at redhat.com Fri Jan 21 12:04:24 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 21 Jan 2011 20:04:24 +0000 Subject: /hg/icedtea: New configure option --with-llvm-config In-Reply-To: References: Message-ID: <20110121200424.GA21893@rivendell.middle-earth.co.uk> On 19:29 Fri 21 Jan , mjw at icedtea.classpath.org wrote: > changeset da307731d8d2 in /hg/icedtea > details: http://icedtea.classpath.org/hg/icedtea?cmd=changeset;node=da307731d8d2 > author: doko at ubuntu.com > date: Thu Oct 14 13:25:44 2010 +0200 > > New configure option --with-llvm-config > > 2010-10-14 Matthias Klose > > * configure.ac: New option --with-llvm-config. > * INSTALL: Document it. > > This will error out if --without-llvm-config is specified (withval=no), which I don't think is the right behaviour. Worse, if --with-llvm-config is specified, withval will be yes and 'which yes' will return /bin/yes, setting LLVM_CONFIG to this value. Please add cases to handle these values. > diffstat: > > 3 files changed, 22 insertions(+), 1 deletion(-) > ChangeLog | 5 +++++ > INSTALL | 1 + > configure.ac | 17 ++++++++++++++++- > > diffs (51 lines): > > diff -r ee7d7790fcc7 -r da307731d8d2 ChangeLog > --- a/ChangeLog Fri Jan 21 12:20:56 2011 -0500 > +++ b/ChangeLog Thu Oct 14 13:25:44 2010 +0200 > @@ -1,3 +1,8 @@ 2011-01-21 Deepak Bhole +2011-11-21 Matthias Klose > + > + * configure.ac: New option --with-llvm-config. > + * INSTALL: Document it. > + > 2011-01-21 Deepak Bhole > > * Makefile.am > diff -r ee7d7790fcc7 -r da307731d8d2 INSTALL > --- a/INSTALL Fri Jan 21 12:20:56 2011 -0500 > +++ b/INSTALL Thu Oct 14 13:25:44 2010 +0200 > @@ -152,6 +152,7 @@ to configure: > * --with-tzdata-dir: Specify the location of Java timezone data, defaulting to /usr/share/javazi. > * --with-netbeans: Specify the location of NetBeans for VisualVM, defaulting to the netbeans on the path. > * --with-abs-install-dir: The final install location of the j2sdk-image, for use in the SystemTap tapset. > +* --with-llvm-config: Specify the location of the llvm-config binary. > * --with-version-suffix: Appends the given text to the JDK version output. > * --with-project: Build an OpenJDK project from the following: icedtea, jdk7, closures, cvmi, cacaiocavallo, > bsd, nio2. The default is icedtea. Use of others is at the user's risk and builds may fail. This setting > diff -r ee7d7790fcc7 -r da307731d8d2 configure.ac > --- a/configure.ac Fri Jan 21 12:20:56 2011 -0500 > +++ b/configure.ac Thu Oct 14 13:25:44 2010 +0200 > @@ -391,8 +391,23 @@ AC_SUBST(LIBFFI_CFLAGS) > AC_SUBST(LIBFFI_CFLAGS) > AC_SUBST(LIBFFI_LIBS) > > +AC_ARG_WITH([llvm-config], > + [AS_HELP_STRING([--with-llvm-config], > + [llvm-config binary (default is llvm-config)])], > + [ > + if test "x${withval}" != x; then > + if which ${withval} >/dev/null 2>&1 && ${withval} --version >/dev/null 2>&1; then > + LLVM_CONFIG=${withval} > + else > + AC_MSG_ERROR([invalid argument for --with-llvm-config ($withval)]) > + fi > + fi > + ]) > + > if test "x${SHARK_BUILD_TRUE}" = x || test "x${ADD_SHARK_BUILD_TRUE}" = x; then > - FIND_TOOL([LLVM_CONFIG], [llvm-config]) > + if test "x${LLVM_CONFIG}" = x; then > + FIND_TOOL([LLVM_CONFIG], [llvm-config]) > + fi > llvm_components="jit engine nativecodegen" > LLVM_VERSION="`$LLVM_CONFIG --version`" > dnl LLVM_CFLAGS -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Fri Jan 21 12:46:49 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 21 Jan 2011 20:46:49 +0000 Subject: [icedtea-web] RFE: Fix for broken JRE dir install In-Reply-To: <20110121151327.GA10878@redhat.com> References: <20110120235619.GA22586@redhat.com> <20110121002225.GD4611@rivendell.middle-earth.co.uk> <20110121003724.GD22586@redhat.com> <20110121004614.GG4611@rivendell.middle-earth.co.uk> <20110121011017.GF22586@redhat.com> <20110121013228.GI4611@rivendell.middle-earth.co.uk> <20110121025333.GA24487@redhat.com> <20110121133540.GC13935@rivendell.middle-earth.co.uk> <20110121151327.GA10878@redhat.com> Message-ID: <20110121204649.GB21893@rivendell.middle-earth.co.uk> On 10:13 Fri 21 Jan , Deepak Bhole wrote: > * Dr Andrew John Hughes [2011-01-21 08:35]: > > [I'm going to reply to http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011835.html here too, as we have two concurrent discussions going on here and it's about time we did a join() ;-)] By 'break everything else', I meant that you break installation where the root is not java.home. As I've said previously, the user is going to specify something like --prefix=/blah and you're going to blatantly ignore that and use something else. I don't see why the JDK needs to be relocatable. If you move installed system files and directories around, it's likely that things will break. If I move /lib/libc.so.6 into /var/tmp, should I be surprised that something goes wrong? I don't see why were bending over backwards to allow for this. I guess we're talking about flexibility from two different angles here. From a FOSS perspective, users generally expect to be able to choose where an application is installed using the standard autotools machinery. Your patch would break this. >From the 'application living in its own little directory hierarchy' idea favoured by many proprietary applications, or ones with such heritage like the JDK, flexibility is "I can unpack it anywhere, but I can't break apart this homogenous blob of stuff". I would have thought that distros generally were strong proponents of the former approach, while you seem to be advocating the latter. Maybe you need to explain more clearly what you need and why, because you seem to be doing something more convoluted than just wanting to work with the jre-image as opposed to j2sdk-image. > > The previous logic was: > > "Install to JDK|JRE bin/; check if jre/bin exists; link there if so" > No it says install in the $(bindir) specified by the user as expected. It then supports the unusual case of jre/bin existing (wouldn't work in /usr for example), and adds a link into it. > This is incorrect because the _file_ should be in jre/bin Why should it? What if it doesn't exist? > and it must > because of the way installations work with packages. Please explain. >RPM for example builds the whole tree, and divides it into subpackages. In such a case, > if RPM were to split off JRE and install it, JRE/bin will have a dangling symlink. Why is this relevant to IcedTea-Web? This is a separate package which should depend on the openjdk package already being installed. If you want the behaviour you're asking for, why not just using ${java.home}/jre as your prefix? > > The new logic > > "Install to JDK/JRE bin; check if there is a JRE/bin; if yes, move the > actual file to it, and link from JDK/bin; else leave it alone" > That might be what you meant, but it's not what your patch says: + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ + ln -sf $(DESTDIR)$(prefix)/jre/bin/javaws $(DESTDIR)$(bindir)/javaws ; \ > fi If jre/bin exists and JRE_DIR_PREFIX is thus jre/, this does: 1. Installs javaws in $(prefix)/jre/bin 2. Tries to _copy_ $(prefix)/bin/javaws (which doesn't exist) into $(prefix)/jre/bin where it was already installed to 3. Links $(prefix)/jre/bin/javaws to $(prefix)/bin/javaws I think what you actually intended was just 1 & 3. + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ + ln -sf $(DESTDIR)$(prefix)/jre/bin/javaws $(DESTDIR)$(bindir)/javaws ; \ fi If jre/bin doesn't exist, the symlink will not be created and the binary will have already been installed in $(bindir) as $(JRE_DIR_PREFIX) is empty, giving $(prefix)/bin which is equal to $(bindir) by default. > This guarantees that the actual file will be in jre/bin, and should the > prefix have been a JDK tree, a link will be created from JDK_BIN/bin to > jre/bin/. > > Deepak > > > > Thanks, > > > Deepak > > > > > > > > diff -r 43212217e9c0 Makefile.am > > > --- a/Makefile.am Wed Dec 15 10:17:51 2010 -0500 > > > +++ b/Makefile.am Thu Jan 20 21:51:05 2011 -0500 > > > @@ -102,37 +102,29 @@ > > > clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs > > > > > > install-exec-local: > > > - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) > > > + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > > > if ENABLE_PLUGIN > > > - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ > > > + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ > > > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) > > > - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > > + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > > endif > > > - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > > > - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > > > + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > > - fi ; \ > > > - if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > > > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > > - fi ; \ > > > + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > > + ln -sf $(DESTDIR)$(prefix)/jre/bin/javaws $(DESTDIR)$(bindir)/javaws ; \ > > > fi > > > - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > > > - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > > > + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > > - fi ; \ > > > - if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > > > - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > > > - fi ; \ > > > + cp -a $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > > > + ln -sf $(DESTDIR)$(prefix)/jre/bin/itweb-settings $(DESTDIR)$(bindir)/itweb-settings ; \ > > > fi > > > > > > install-data-local: > > > ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 > > > ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 > > > - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib > > > + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > > if ENABLE_DOCS > > > ${mkinstalldirs} $(DESTDIR)$(htmldir) > > > (cd ${abs_top_builddir}/docs/netx; \ > > > @@ -150,23 +142,25 @@ > > > endif > > > > > > uninstall-local: > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar > > > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > > > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > > > - rm -f $(DESTDIR)$(bindir)/javaws > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/javaws > > > + if [ -L $(DESTDIR)$(prefix)/bin/javaws ] ; then \ > > > + rm -f $(DESTDIR)$(prefix)/bin/javaws ; \ > > > fi > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > > > - rm -f $(DESTDIR)$(bindir)/itweb-settings > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/itweb-settings > > > + if [ -L $(DESTDIR)$(prefix)/bin/itweb-settings ] ; then \ > > > + rm -f $(DESTDIR)$(prefix)/bin/itweb-settings ; \ > > > fi > > > - rm -rf $(DESTDIR)$(htmldir) > > > + rm -rf $(DESTDIR)$(htmldir)/* > > > + if [ -d $(DESTDIR)$(htmldir) ] ; then \ > > > + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ > > > + fi > > > > > > # Plugin > > > > > > @@ -349,7 +343,7 @@ > > > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > > > mkdir -p $(NETX_DIR)/launcher && \ > > > $(CC) $(LAUNCHER_FLAGS) \ > > > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > > > + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ > > > -DPROGNAME='"javaws"' -c -o $@ $< > > > > > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > > > diff -r 43212217e9c0 configure.ac > > > --- a/configure.ac Wed Dec 15 10:17:51 2010 -0500 > > > +++ b/configure.ac Thu Jan 20 21:51:05 2011 -0500 > > > @@ -78,4 +78,12 @@ > > > IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) > > > IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE > > > > > > +# Set JRE prefix based on whether to-level prefix is a JDK dir or a JRE dir > > > +if test -d ${prefix}/jre ; then > > > + JRE_DIR_PREFIX="/jre" ; > > > +else > > > + JRE_DIR_PREFIX="" ; > > > +fi ; > > > +AC_SUBST([JRE_DIR_PREFIX]) > > > + > > > AC_OUTPUT > > > diff -r 43212217e9c0 netx/net/sourceforge/jnlp/Launcher.java > > > --- a/netx/net/sourceforge/jnlp/Launcher.java Wed Dec 15 10:17:51 2010 -0500 > > > +++ b/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 21:51:05 2011 -0500 > > > @@ -330,7 +330,12 @@ > > > List commands = new LinkedList(); > > > > > > // this property is set by the javaws launcher to point to the javaws binary > > > - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); > > > + String pathToWebstartBinary = System.getProperty("java.home") + > > > + File.separatorChar + > > > + "bin" + > > > + File.separatorChar + > > > + "javaws"; > > > + > > > commands.add(pathToWebstartBinary); > > > // use -Jargument format to pass arguments to the JVM through the launcher > > > for (String arg : vmArgs) { > > > > > > -- > > Andrew :) > > > > Free Java Software Engineer > > Red Hat, Inc. (http://www.redhat.com) > > > > Support Free Java! > > Contribute to GNU Classpath and IcedTea > > http://www.gnu.org/software/classpath > > http://icedtea.classpath.org > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From mark at klomp.org Fri Jan 21 12:46:00 2011 From: mark at klomp.org (Mark Wielaard) Date: Fri, 21 Jan 2011 21:46:00 +0100 (CET) Subject: /hg/icedtea: New configure option --with-llvm-config In-Reply-To: <20110121200424.GA21893@rivendell.middle-earth.co.uk> References: <20110121200424.GA21893@rivendell.middle-earth.co.uk> Message-ID: <33331.80.101.103.228.1295642760.squirrel@gnu.wildebeest.org> On Fri, January 21, 2011 21:04, Dr Andrew John Hughes wrote: > On 19:29 Fri 21 Jan , mjw at icedtea.classpath.org wrote: >> http://icedtea.classpath.org/hg/icedtea?cmd=changeset;node=da307731d8d2 >> author: doko at ubuntu.com >> date: Thu Oct 14 13:25:44 2010 +0200 >> >> New configure option --with-llvm-config >> >> 2010-10-14 Matthias Klose >> >> * configure.ac: New option --with-llvm-config. >> * INSTALL: Document it. > > This will error out if --without-llvm-config is specified > (withval=no), which I don't think is the right behaviour. Worse, if > --with-llvm-config is specified, withval will be yes and 'which yes' > will return /bin/yes, setting LLVM_CONFIG to this value. > > Please add cases to handle these values. To be honest, both cases seem somewhat far fetched. And even if people would try such things configure will indicate that by just failing with an error message that llvm-config is setup wrongly when they us it (when shark is enabled). But I assume you would like something like this? diff -r da307731d8d2 configure.ac --- a/configure.ac Thu Oct 14 13:25:44 2010 +0200 +++ b/configure.ac Fri Jan 21 21:48:07 2011 +0100 @@ -395,7 +395,7 @@ [AS_HELP_STRING([--with-llvm-config], [llvm-config binary (default is llvm-config)])], [ - if test "x${withval}" != x; then + if test "x${withval}" != x && test "x${withval}" != xyes && test "x${withval}" != xno; then if which ${withval} >/dev/null 2>&1 && ${withval} --version >/dev/null 2>&1; then LLVM_CONFIG=${withval} else Cheers, Mark From ahughes at redhat.com Fri Jan 21 13:03:29 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 21 Jan 2011 21:03:29 +0000 Subject: /hg/icedtea: New configure option --with-llvm-config In-Reply-To: <33331.80.101.103.228.1295642760.squirrel@gnu.wildebeest.org> References: <20110121200424.GA21893@rivendell.middle-earth.co.uk> <33331.80.101.103.228.1295642760.squirrel@gnu.wildebeest.org> Message-ID: <20110121210329.GC21893@rivendell.middle-earth.co.uk> On 21:46 Fri 21 Jan , Mark Wielaard wrote: > On Fri, January 21, 2011 21:04, Dr Andrew John Hughes wrote: > > On 19:29 Fri 21 Jan , mjw at icedtea.classpath.org wrote: > >> http://icedtea.classpath.org/hg/icedtea?cmd=changeset;node=da307731d8d2 > >> author: doko at ubuntu.com > >> date: Thu Oct 14 13:25:44 2010 +0200 > >> > >> New configure option --with-llvm-config > >> > >> 2010-10-14 Matthias Klose > >> > >> * configure.ac: New option --with-llvm-config. > >> * INSTALL: Document it. > > > > This will error out if --without-llvm-config is specified > > (withval=no), which I don't think is the right behaviour. Worse, if > > --with-llvm-config is specified, withval will be yes and 'which yes' > > will return /bin/yes, setting LLVM_CONFIG to this value. > > > > Please add cases to handle these values. > > To be honest, both cases seem somewhat far fetched. Maybe, but undoubtably someone will do it. I know it's been reported in the past. > And even if people would try such things configure will > indicate that by just failing with an error message that llvm-config > is setup wrongly when they us it (when shark is enabled). > Only for the no case. yes would succeed as I said. > But I assume you would like something like this? > Yeah, that's fine. Sorry, I didn't realise before that this was a forwardport (and thus doko's bad, not yours). The same needs fixing in IcedTea6. > diff -r da307731d8d2 configure.ac > --- a/configure.ac Thu Oct 14 13:25:44 2010 +0200 > +++ b/configure.ac Fri Jan 21 21:48:07 2011 +0100 > @@ -395,7 +395,7 @@ > [AS_HELP_STRING([--with-llvm-config], > [llvm-config binary (default is llvm-config)])], > [ > - if test "x${withval}" != x; then > + if test "x${withval}" != x && test "x${withval}" != xyes && > test "x${withval}" != xno; then > if which ${withval} >/dev/null 2>&1 && ${withval} --version > >/dev/null 2>&1; then > LLVM_CONFIG=${withval} > else > > Cheers, > > Mark > -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From asu at redhat.com Fri Jan 21 13:28:19 2011 From: asu at redhat.com (Andrew Su) Date: Fri, 21 Jan 2011 16:28:19 -0500 (EST) Subject: [RFC][Icedtea-web]: Make log files restricted to owner only. In-Reply-To: <1924793110.70083.1295645093830.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Message-ID: <361587104.70164.1295645299209.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Hello, This ensures that the logs created are only accessible by the owner. Cheers, Andrew -------------- next part -------------- A non-text attachment was scrubbed... Name: 20110121_make_logs_restricted.patch Type: text/x-patch Size: 1235 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110121/8632d615/20110121_make_logs_restricted.patch From ahughes at redhat.com Fri Jan 21 13:32:27 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Fri, 21 Jan 2011 21:32:27 +0000 Subject: [RFC][Icedtea-web]: Make log files restricted to owner only. In-Reply-To: <361587104.70164.1295645299209.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> References: <1924793110.70083.1295645093830.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> <361587104.70164.1295645299209.JavaMail.root@zmail01.collab.prod.int.phx2.redhat.com> Message-ID: <20110121213227.GD21893@rivendell.middle-earth.co.uk> On 16:28 Fri 21 Jan , Andrew Su wrote: > Hello, > > This ensures that the logs created are only accessible by the owner. > > Cheers, > Andrew Looks good. > diff -r c5b209388b54 netx/net/sourceforge/jnlp/AppletLog.java > --- a/netx/net/sourceforge/jnlp/AppletLog.java Thu Jan 20 14:54:27 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/AppletLog.java Fri Jan 21 16:24:21 2011 -0500 > @@ -1,12 +1,15 @@ > package net.sourceforge.jnlp; > > import java.io.ByteArrayOutputStream; > +import java.io.File; > import java.io.PrintStream; > import java.util.logging.FileHandler; > import java.util.logging.Level; > import java.util.logging.Logger; > import java.util.logging.XMLFormatter; > > +import net.sourceforge.jnlp.util.FileUtils; > + > /** > * This class writes log information to file. > * > @@ -20,8 +23,8 @@ > // If logging is enabled, we create logger. > if (enableLogging) { > String fn = icedteaLogDir + "plugin" + java.lang.System.currentTimeMillis() + ".log"; > - boolean append = false; > - FileHandler fh = new FileHandler(fn, append); > + FileUtils.createRestrictedFile(new File(fn), true); > + FileHandler fh = new FileHandler(fn, false); > fh.setFormatter(new XMLFormatter()); > String logClassName = AppletLog.class.getName(); > logger = Logger.getLogger(logClassName); -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From asu at icedtea.classpath.org Fri Jan 21 13:40:28 2011 From: asu at icedtea.classpath.org (asu at icedtea.classpath.org) Date: Fri, 21 Jan 2011 21:40:28 +0000 Subject: /hg/icedtea-web: Make log file permissions owner accessible only. Message-ID: changeset a9e67985cb7a in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=a9e67985cb7a author: Andrew Su date: Fri Jan 21 16:42:18 2011 -0500 Make log file permissions owner accessible only. diffstat: 2 files changed, 10 insertions(+), 2 deletions(-) ChangeLog | 5 +++++ netx/net/sourceforge/jnlp/AppletLog.java | 7 +++++-- diffs (41 lines): diff -r c5b209388b54 -r a9e67985cb7a ChangeLog --- a/ChangeLog Thu Jan 20 14:54:27 2011 -0500 +++ b/ChangeLog Fri Jan 21 16:42:18 2011 -0500 @@ -1,3 +1,8 @@ 2011-01-20 Andrew Su +2011-01-20 Andrew Su + + * netx/net/sourceforge/jnlp/AppletLog.java: Restrict log files to + owner accessible only. + 2011-01-20 Andrew Su Removing dead/commented/unused code. diff -r c5b209388b54 -r a9e67985cb7a netx/net/sourceforge/jnlp/AppletLog.java --- a/netx/net/sourceforge/jnlp/AppletLog.java Thu Jan 20 14:54:27 2011 -0500 +++ b/netx/net/sourceforge/jnlp/AppletLog.java Fri Jan 21 16:42:18 2011 -0500 @@ -1,11 +1,14 @@ package net.sourceforge.jnlp; package net.sourceforge.jnlp; import java.io.ByteArrayOutputStream; +import java.io.File; import java.io.PrintStream; import java.util.logging.FileHandler; import java.util.logging.Level; import java.util.logging.Logger; import java.util.logging.XMLFormatter; + +import net.sourceforge.jnlp.util.FileUtils; /** * This class writes log information to file. @@ -20,8 +23,8 @@ class AppletLog extends Log { // If logging is enabled, we create logger. if (enableLogging) { String fn = icedteaLogDir + "plugin" + java.lang.System.currentTimeMillis() + ".log"; - boolean append = false; - FileHandler fh = new FileHandler(fn, append); + FileUtils.createRestrictedFile(new File(fn), true); + FileHandler fh = new FileHandler(fn, false); fh.setFormatter(new XMLFormatter()); String logClassName = AppletLog.class.getName(); logger = Logger.getLogger(logClassName); From mjw at icedtea.classpath.org Fri Jan 21 13:53:58 2011 From: mjw at icedtea.classpath.org (mjw at icedtea.classpath.org) Date: Fri, 21 Jan 2011 21:53:58 +0000 Subject: /hg/icedtea6: * configure.ac (--with-llvm-config): Handle yes/no. Message-ID: changeset 52a48baed3cf in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=52a48baed3cf author: Mark Wielaard date: Fri Jan 21 22:53:33 2011 +0100 * configure.ac (--with-llvm-config): Handle yes/no. diffstat: 2 files changed, 5 insertions(+), 1 deletion(-) ChangeLog | 4 ++++ configure.ac | 2 +- diffs (23 lines): diff -r f3aee1b5e567 -r 52a48baed3cf ChangeLog --- a/ChangeLog Thu Jan 20 16:33:23 2011 +0100 +++ b/ChangeLog Fri Jan 21 22:53:33 2011 +0100 @@ -1,3 +1,7 @@ 2011-01-20 Pavel Tisnovsky + + * configure.ac (--with-llvm-config): Handle yes/no. + 2011-01-20 Pavel Tisnovsky * patches/icedtea-jtreg-international-fonts.patch: diff -r f3aee1b5e567 -r 52a48baed3cf configure.ac --- a/configure.ac Thu Jan 20 16:33:23 2011 +0100 +++ b/configure.ac Fri Jan 21 22:53:33 2011 +0100 @@ -398,7 +398,7 @@ AC_ARG_WITH([llvm-config], [AS_HELP_STRING([--with-llvm-config], [llvm-config binary (default is llvm-config)])], [ - if test "x${withval}" != x; then + if test "x${withval}" != x && test "x${withval}" != xyes && test "x${withval}" != xno; then if which ${withval} >/dev/null 2>&1 && ${withval} --version >/dev/null 2>&1; then LLVM_CONFIG=${withval} else From mjw at icedtea.classpath.org Fri Jan 21 13:55:56 2011 From: mjw at icedtea.classpath.org (mjw at icedtea.classpath.org) Date: Fri, 21 Jan 2011 21:55:56 +0000 Subject: /hg/icedtea: * configure.ac (--with-llvm-config): Handle yes/no. Message-ID: changeset ce49b3019799 in /hg/icedtea details: http://icedtea.classpath.org/hg/icedtea?cmd=changeset;node=ce49b3019799 author: Mark Wielaard date: Fri Jan 21 22:53:33 2011 +0100 * configure.ac (--with-llvm-config): Handle yes/no. diffstat: 2 files changed, 5 insertions(+), 1 deletion(-) ChangeLog | 4 ++++ configure.ac | 2 +- diffs (23 lines): diff -r da307731d8d2 -r ce49b3019799 ChangeLog --- a/ChangeLog Thu Oct 14 13:25:44 2010 +0200 +++ b/ChangeLog Fri Jan 21 22:53:33 2011 +0100 @@ -1,3 +1,7 @@ 2011-11-21 Matthias Klose + + * configure.ac (--with-llvm-config): Handle yes/no. + 2011-11-21 Matthias Klose * configure.ac: New option --with-llvm-config. diff -r da307731d8d2 -r ce49b3019799 configure.ac --- a/configure.ac Thu Oct 14 13:25:44 2010 +0200 +++ b/configure.ac Fri Jan 21 22:53:33 2011 +0100 @@ -395,7 +395,7 @@ AC_ARG_WITH([llvm-config], [AS_HELP_STRING([--with-llvm-config], [llvm-config binary (default is llvm-config)])], [ - if test "x${withval}" != x; then + if test "x${withval}" != x && test "x${withval}" != xyes && test "x${withval}" != xno; then if which ${withval} >/dev/null 2>&1 && ${withval} --version >/dev/null 2>&1; then LLVM_CONFIG=${withval} else From dbhole at redhat.com Fri Jan 21 14:40:39 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Fri, 21 Jan 2011 17:40:39 -0500 Subject: [icedtea-web] RFE: Fix for broken JRE dir install In-Reply-To: <20110121204649.GB21893@rivendell.middle-earth.co.uk> References: <20110120235619.GA22586@redhat.com> <20110121002225.GD4611@rivendell.middle-earth.co.uk> <20110121003724.GD22586@redhat.com> <20110121004614.GG4611@rivendell.middle-earth.co.uk> <20110121011017.GF22586@redhat.com> <20110121013228.GI4611@rivendell.middle-earth.co.uk> <20110121025333.GA24487@redhat.com> <20110121133540.GC13935@rivendell.middle-earth.co.uk> <20110121151327.GA10878@redhat.com> <20110121204649.GB21893@rivendell.middle-earth.co.uk> Message-ID: <20110121224039.GA3954@redhat.com> * Dr Andrew John Hughes [2011-01-21 15:46]: > On 10:13 Fri 21 Jan , Deepak Bhole wrote: > > * Dr Andrew John Hughes [2011-01-21 08:35]: > > > > > [I'm going to reply to http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011835.html > here too, as we have two concurrent discussions going on here and it's > about time we did a join() ;-)] > > By 'break everything else', I meant that you break installation where the > root is not java.home. As I've said previously, the user is going to specify > something like --prefix=/blah and you're going to blatantly ignore that and > use something else. > Ah, fair enough. I agree, this change should definitely not go in HEAD as it is very reliant on the prefix being a JDK/JRE dir. > I don't see why the JDK needs to be relocatable. If you move installed system > files and directories around, it's likely that things will break. If I move > /lib/libc.so.6 into /var/tmp, should I be surprised that something goes wrong? > I don't see why were bending over backwards to allow for this. > Well it is not bending over as much as trying to avoid a 'here is an add-on component, but it breaks relocatability, something the JDK has supported for ages' scenario. > I guess we're talking about flexibility from two different angles here. From > a FOSS perspective, users generally expect to be able to choose where an application > is installed using the standard autotools machinery. Your patch would break this. > From the 'application living in its own little directory hierarchy' idea favoured > by many proprietary applications, or ones with such heritage like the JDK, flexibility > is "I can unpack it anywhere, but I can't break apart this homogenous blob of stuff". > > I would have thought that distros generally were strong proponents of the former approach, > while you seem to be advocating the latter. Maybe you need to explain more clearly what > you need and why, because you seem to be doing something more convoluted than just wanting > to work with the jre-image as opposed to j2sdk-image. > > > > > The previous logic was: > > > > "Install to JDK|JRE bin/; check if jre/bin exists; link there if so" > > > > No it says install in the $(bindir) specified by the user as expected. > It then supports the unusual case of jre/bin existing (wouldn't work in /usr > for example), and adds a link into it. > > > This is incorrect because the _file_ should be in jre/bin > > Why should it? What if it doesn't exist? > > > and it must > > because of the way installations work with packages. > > Please explain. > The RPM build mechanism works as follows (excluding the minor details): Build IcedTea Pushd to j2sdk-image Break off jre/ + misc. stuff into a java-1.6.0-openjdk package Take the bin/ (i.e. j2sdk-image/bin), lib/ etc. and put it into java-1.6.0-openjdk-devel package, etc. Now, consider a scenario where the user has only java-1.6.0-openjdk installed. Their system contains /usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/ which has: $ /usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/ jre And that is it. If I were to install an icedtea-web package now, it needs to go into jre/* and work fully from there only. If jre/bin/javaws were to be a link, I would be forced to install ../../bin/javaws (i.e. create a /usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/bin and put it there) which is not a good thing for it to be doing since that dir should really be created by the -devel package. This brings up an interesting point though.. what happens in the case where the user installs -devel later .. there wont be a symlink in JDK_HOME/bin ... I guess with rpm we will have to bite the bullet and put the executables in jre/bin only. > >RPM for example builds the whole tree, and divides it into subpackages. In such a case, > > if RPM were to split off JRE and install it, JRE/bin will have a dangling symlink. > > Why is this relevant to IcedTea-Web? This is a separate package which should depend > on the openjdk package already being installed. > > If you want the behaviour you're asking for, why not just using ${java.home}/jre as your > prefix? > It is not RPM that is the issue. The issue is that icedtea-web only needs the jre to run. To that end, it should be installable in a jre directory and work. The fact that we put things in JDK_HOME/bin is a secondary concern. The way things are now, JDK_HOME/bin is a primary concern and jre/bin (where links are made) is secondary. > > > > The new logic > > > > "Install to JDK/JRE bin; check if there is a JRE/bin; if yes, move the > > actual file to it, and link from JDK/bin; else leave it alone" > > > > That might be what you meant, but it's not what your patch says: > > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > + ln -sf $(DESTDIR)$(prefix)/jre/bin/javaws $(DESTDIR)$(bindir)/javaws ; \ > > fi > > If jre/bin exists and JRE_DIR_PREFIX is thus jre/, this does: > > 1. Installs javaws in $(prefix)/jre/bin > 2. Tries to _copy_ $(prefix)/bin/javaws (which doesn't exist) into $(prefix)/jre/bin where it was already installed to > 3. Links $(prefix)/jre/bin/javaws to $(prefix)/bin/javaws > > I think what you actually intended was just 1 & 3. > > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > + ln -sf $(DESTDIR)$(prefix)/jre/bin/javaws $(DESTDIR)$(bindir)/javaws ; \ > fi > > If jre/bin doesn't exist, the symlink will not be created and the binary will have already been installed in $(bindir) > as $(JRE_DIR_PREFIX) is empty, giving $(prefix)/bin which is equal to $(bindir) by default. > Doh! You are right, that is a bug in my patch. Good catch! I agree with your correction -- it is what I meant to do (with one minor change -- the target would be ../jre/bin/.. i.e. it would be relative instead of absolute, which is another thing I missed). Cheers, Deepak > > This guarantees that the actual file will be in jre/bin, and should the > > prefix have been a JDK tree, a link will be created from JDK_BIN/bin to > > jre/bin/. > > > > Deepak > > > > > > Thanks, > > > > Deepak > > > > > > > > > > > diff -r 43212217e9c0 Makefile.am > > > > --- a/Makefile.am Wed Dec 15 10:17:51 2010 -0500 > > > > +++ b/Makefile.am Thu Jan 20 21:51:05 2011 -0500 > > > > @@ -102,37 +102,29 @@ > > > > clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs > > > > > > > > install-exec-local: > > > > - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) > > > > + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > > > > if ENABLE_PLUGIN > > > > - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ > > > > + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ > > > > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) > > > > - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > > > + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > > > endif > > > > - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > > > > - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > > > > + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > > > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > > > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > > > - fi ; \ > > > > - if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > > > > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > > > - fi ; \ > > > > + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > > > + ln -sf $(DESTDIR)$(prefix)/jre/bin/javaws $(DESTDIR)$(bindir)/javaws ; \ > > > > fi > > > > - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > > > > - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > > > > + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > > > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > > > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > > > - fi ; \ > > > > - if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > > > > - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > > > > - fi ; \ > > > > + cp -a $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > > > > + ln -sf $(DESTDIR)$(prefix)/jre/bin/itweb-settings $(DESTDIR)$(bindir)/itweb-settings ; \ > > > > fi > > > > > > > > install-data-local: > > > > ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 > > > > ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 > > > > - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib > > > > + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > > > if ENABLE_DOCS > > > > ${mkinstalldirs} $(DESTDIR)$(htmldir) > > > > (cd ${abs_top_builddir}/docs/netx; \ > > > > @@ -150,23 +142,25 @@ > > > > endif > > > > > > > > uninstall-local: > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar > > > > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > > > > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > > > > - rm -f $(DESTDIR)$(bindir)/javaws > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/javaws > > > > + if [ -L $(DESTDIR)$(prefix)/bin/javaws ] ; then \ > > > > + rm -f $(DESTDIR)$(prefix)/bin/javaws ; \ > > > > fi > > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > > > > - rm -f $(DESTDIR)$(bindir)/itweb-settings > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/itweb-settings > > > > + if [ -L $(DESTDIR)$(prefix)/bin/itweb-settings ] ; then \ > > > > + rm -f $(DESTDIR)$(prefix)/bin/itweb-settings ; \ > > > > fi > > > > - rm -rf $(DESTDIR)$(htmldir) > > > > + rm -rf $(DESTDIR)$(htmldir)/* > > > > + if [ -d $(DESTDIR)$(htmldir) ] ; then \ > > > > + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ > > > > + fi > > > > > > > > # Plugin > > > > > > > > @@ -349,7 +343,7 @@ > > > > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > > > > mkdir -p $(NETX_DIR)/launcher && \ > > > > $(CC) $(LAUNCHER_FLAGS) \ > > > > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > > > > + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ > > > > -DPROGNAME='"javaws"' -c -o $@ $< > > > > > > > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > > > > diff -r 43212217e9c0 configure.ac > > > > --- a/configure.ac Wed Dec 15 10:17:51 2010 -0500 > > > > +++ b/configure.ac Thu Jan 20 21:51:05 2011 -0500 > > > > @@ -78,4 +78,12 @@ > > > > IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) > > > > IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE > > > > > > > > +# Set JRE prefix based on whether to-level prefix is a JDK dir or a JRE dir > > > > +if test -d ${prefix}/jre ; then > > > > + JRE_DIR_PREFIX="/jre" ; > > > > +else > > > > + JRE_DIR_PREFIX="" ; > > > > +fi ; > > > > +AC_SUBST([JRE_DIR_PREFIX]) > > > > + > > > > AC_OUTPUT > > > > diff -r 43212217e9c0 netx/net/sourceforge/jnlp/Launcher.java > > > > --- a/netx/net/sourceforge/jnlp/Launcher.java Wed Dec 15 10:17:51 2010 -0500 > > > > +++ b/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 21:51:05 2011 -0500 > > > > @@ -330,7 +330,12 @@ > > > > List commands = new LinkedList(); > > > > > > > > // this property is set by the javaws launcher to point to the javaws binary > > > > - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); > > > > + String pathToWebstartBinary = System.getProperty("java.home") + > > > > + File.separatorChar + > > > > + "bin" + > > > > + File.separatorChar + > > > > + "javaws"; > > > > + > > > > commands.add(pathToWebstartBinary); > > > > // use -Jargument format to pass arguments to the JVM through the launcher > > > > for (String arg : vmArgs) { > > > > > > > > > -- > > > Andrew :) > > > > > > Free Java Software Engineer > > > Red Hat, Inc. (http://www.redhat.com) > > > > > > Support Free Java! > > > Contribute to GNU Classpath and IcedTea > > > http://www.gnu.org/software/classpath > > > http://icedtea.classpath.org > > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 > > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Fri Jan 21 17:23:26 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Sat, 22 Jan 2011 01:23:26 +0000 Subject: [icedtea-web] RFE: Fix for broken JRE dir install In-Reply-To: <20110121224039.GA3954@redhat.com> References: <20110121002225.GD4611@rivendell.middle-earth.co.uk> <20110121003724.GD22586@redhat.com> <20110121004614.GG4611@rivendell.middle-earth.co.uk> <20110121011017.GF22586@redhat.com> <20110121013228.GI4611@rivendell.middle-earth.co.uk> <20110121025333.GA24487@redhat.com> <20110121133540.GC13935@rivendell.middle-earth.co.uk> <20110121151327.GA10878@redhat.com> <20110121204649.GB21893@rivendell.middle-earth.co.uk> <20110121224039.GA3954@redhat.com> Message-ID: <20110122012326.GG21893@rivendell.middle-earth.co.uk> On 17:40 Fri 21 Jan , Deepak Bhole wrote: > * Dr Andrew John Hughes [2011-01-21 15:46]: snip... > > > > Please explain. > > > > The RPM build mechanism works as follows (excluding the minor details): > Build IcedTea > Pushd to j2sdk-image > Break off jre/ + misc. stuff into a java-1.6.0-openjdk package > Take the bin/ (i.e. j2sdk-image/bin), lib/ etc. and put it into > java-1.6.0-openjdk-devel package, etc. > > Now, consider a scenario where the user has only java-1.6.0-openjdk > installed. Their system contains > /usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/ which has: > > $ /usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/ > jre > > And that is it. > > If I were to install an icedtea-web package now, it needs to go into > jre/* and work fully from there only. If jre/bin/javaws were to be a > link, I would be forced to install ../../bin/javaws (i.e. create a > /usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/bin and put it there) > which is not a good thing for it to be doing since that dir should > really be created by the -devel package. > > This brings up an interesting point though.. what happens in the case > where the user installs -devel later .. there wont be a symlink in > JDK_HOME/bin ... I guess with rpm we will have to bite the bullet and > put the executables in jre/bin only. > So sounds like the RPM build doesn't actually need jre support at all. You could just use jre as the prefix. If you REALLY need the symlink, you could hack it into the openjdk package (if -e jre/bin/javaws create symlink). All this stuff really needs to go away though so that IcedTea-Web works like a normal application. I'd also love the JDK itself to work like a normal application, but that's far more work ;-) > > >RPM for example builds the whole tree, and divides it into subpackages. In such a case, > > > if RPM were to split off JRE and install it, JRE/bin will have a dangling symlink. > > > > Why is this relevant to IcedTea-Web? This is a separate package which should depend > > on the openjdk package already being installed. > > > > If you want the behaviour you're asking for, why not just using ${java.home}/jre as your > > prefix? > > > > It is not RPM that is the issue. The issue is that icedtea-web only > needs the jre to run. To that end, it should be installable in a jre > directory and work. The fact that we put things in JDK_HOME/bin is a > secondary concern. The way things are now, JDK_HOME/bin is a primary > concern and jre/bin (where links are made) is secondary. > IcedTea-Web does not 'put things in JDK_HOME/bin'. It puts them in ${bindir} which defaults to ${prefix}/bin. That's only equal to JDK_HOME/bin if ${prefix} is set to JDK_HOME. For a general application, ${bindir} is the primary location. That said, I support adding the $(JRE_DIR_PREFIX) hack to IcedTea-Web 1.0 as I said before. You just need to do in the patch what you say in the mail ;-) > > > > > > The new logic > > > > > > "Install to JDK/JRE bin; check if there is a JRE/bin; if yes, move the > > > actual file to it, and link from JDK/bin; else leave it alone" > > > > > > > That might be what you meant, but it's not what your patch says: > > > > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > + ln -sf $(DESTDIR)$(prefix)/jre/bin/javaws $(DESTDIR)$(bindir)/javaws ; \ > > > fi > > > > If jre/bin exists and JRE_DIR_PREFIX is thus jre/, this does: > > > > 1. Installs javaws in $(prefix)/jre/bin > > 2. Tries to _copy_ $(prefix)/bin/javaws (which doesn't exist) into $(prefix)/jre/bin where it was already installed to > > 3. Links $(prefix)/jre/bin/javaws to $(prefix)/bin/javaws > > > > I think what you actually intended was just 1 & 3. > > > > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > + ln -sf $(DESTDIR)$(prefix)/jre/bin/javaws $(DESTDIR)$(bindir)/javaws ; \ > > fi > > > > If jre/bin doesn't exist, the symlink will not be created and the binary will have already been installed in $(bindir) > > as $(JRE_DIR_PREFIX) is empty, giving $(prefix)/bin which is equal to $(bindir) by default. > > > > Doh! You are right, that is a bug in my patch. Good catch! I agree with > your correction -- it is what I meant to do Yeah, now you see why I was confused! (with one minor change -- > the target would be ../jre/bin/.. i.e. it would be relative instead of > absolute, which is another thing I missed). > I don't get this bit; can you give me an example of what you mean? > Cheers, > Deepak > > > > This guarantees that the actual file will be in jre/bin, and should the > > > prefix have been a JDK tree, a link will be created from JDK_BIN/bin to > > > jre/bin/. > > > > > > Deepak > > > > > > > > Thanks, > > > > > Deepak > > > > > > > > > > > > > > diff -r 43212217e9c0 Makefile.am > > > > > --- a/Makefile.am Wed Dec 15 10:17:51 2010 -0500 > > > > > +++ b/Makefile.am Thu Jan 20 21:51:05 2011 -0500 > > > > > @@ -102,37 +102,29 @@ > > > > > clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs > > > > > > > > > > install-exec-local: > > > > > - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) > > > > > + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > > > > > if ENABLE_PLUGIN > > > > > - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ > > > > > + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ > > > > > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) > > > > > - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > > > > + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > > > > endif > > > > > - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > > > > > - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > > > > > + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > > > > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > > > > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > > > > - fi ; \ > > > > > - if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > > > > > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > > > > - fi ; \ > > > > > + cp -a $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > > > > + ln -sf $(DESTDIR)$(prefix)/jre/bin/javaws $(DESTDIR)$(bindir)/javaws ; \ > > > > > fi > > > > > - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > > > > > - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > > > > > + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > > > > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > > > > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > > > > - fi ; \ > > > > > - if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > > > > > - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > > > > > - fi ; \ > > > > > + cp -a $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > > > > > + ln -sf $(DESTDIR)$(prefix)/jre/bin/itweb-settings $(DESTDIR)$(bindir)/itweb-settings ; \ > > > > > fi > > > > > > > > > > install-data-local: > > > > > ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 > > > > > ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 > > > > > - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib > > > > > + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > > > > if ENABLE_DOCS > > > > > ${mkinstalldirs} $(DESTDIR)$(htmldir) > > > > > (cd ${abs_top_builddir}/docs/netx; \ > > > > > @@ -150,23 +142,25 @@ > > > > > endif > > > > > > > > > > uninstall-local: > > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar > > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp > > > > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar > > > > > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > > > > > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > > > > > - rm -f $(DESTDIR)$(bindir)/javaws > > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/javaws > > > > > + if [ -L $(DESTDIR)$(prefix)/bin/javaws ] ; then \ > > > > > + rm -f $(DESTDIR)$(prefix)/bin/javaws ; \ > > > > > fi > > > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > > > > > - rm -f $(DESTDIR)$(bindir)/itweb-settings > > > > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > > > > - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > > > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/itweb-settings > > > > > + if [ -L $(DESTDIR)$(prefix)/bin/itweb-settings ] ; then \ > > > > > + rm -f $(DESTDIR)$(prefix)/bin/itweb-settings ; \ > > > > > fi > > > > > - rm -rf $(DESTDIR)$(htmldir) > > > > > + rm -rf $(DESTDIR)$(htmldir)/* > > > > > + if [ -d $(DESTDIR)$(htmldir) ] ; then \ > > > > > + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ > > > > > + fi > > > > > > > > > > # Plugin > > > > > > > > > > @@ -349,7 +343,7 @@ > > > > > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > > > > > mkdir -p $(NETX_DIR)/launcher && \ > > > > > $(CC) $(LAUNCHER_FLAGS) \ > > > > > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > > > > > + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ > > > > > -DPROGNAME='"javaws"' -c -o $@ $< > > > > > > > > > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > > > > > diff -r 43212217e9c0 configure.ac > > > > > --- a/configure.ac Wed Dec 15 10:17:51 2010 -0500 > > > > > +++ b/configure.ac Thu Jan 20 21:51:05 2011 -0500 > > > > > @@ -78,4 +78,12 @@ > > > > > IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) > > > > > IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE > > > > > > > > > > +# Set JRE prefix based on whether to-level prefix is a JDK dir or a JRE dir > > > > > +if test -d ${prefix}/jre ; then > > > > > + JRE_DIR_PREFIX="/jre" ; > > > > > +else > > > > > + JRE_DIR_PREFIX="" ; > > > > > +fi ; > > > > > +AC_SUBST([JRE_DIR_PREFIX]) > > > > > + > > > > > AC_OUTPUT > > > > > diff -r 43212217e9c0 netx/net/sourceforge/jnlp/Launcher.java > > > > > --- a/netx/net/sourceforge/jnlp/Launcher.java Wed Dec 15 10:17:51 2010 -0500 > > > > > +++ b/netx/net/sourceforge/jnlp/Launcher.java Thu Jan 20 21:51:05 2011 -0500 > > > > > @@ -330,7 +330,12 @@ > > > > > List commands = new LinkedList(); > > > > > > > > > > // this property is set by the javaws launcher to point to the javaws binary > > > > > - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); > > > > > + String pathToWebstartBinary = System.getProperty("java.home") + > > > > > + File.separatorChar + > > > > > + "bin" + > > > > > + File.separatorChar + > > > > > + "javaws"; > > > > > + > > > > > commands.add(pathToWebstartBinary); > > > > > // use -Jargument format to pass arguments to the JVM through the launcher > > > > > for (String arg : vmArgs) { > > > > > > > > > > > > -- > > > > Andrew :) > > > > > > > > Free Java Software Engineer > > > > Red Hat, Inc. (http://www.redhat.com) > > > > > > > > Support Free Java! > > > > Contribute to GNU Classpath and IcedTea > > > > http://www.gnu.org/software/classpath > > > > http://icedtea.classpath.org > > > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 > > > > -- > > Andrew :) > > > > Free Java Software Engineer > > Red Hat, Inc. (http://www.redhat.com) > > > > Support Free Java! > > Contribute to GNU Classpath and IcedTea > > http://www.gnu.org/software/classpath > > http://icedtea.classpath.org > > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From andrew at icedtea.classpath.org Fri Jan 21 18:44:53 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Sat, 22 Jan 2011 02:44:53 +0000 Subject: /hg/icedtea6: 32 new changesets Message-ID: changeset 09bbaad21267 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=09bbaad21267 author: Andrew John Hughes date: Wed Jul 07 22:35:59 2010 +0100 S6961732: Remove patch; applied upstream. 2010-07-07 Andrew John Hughes * patches/openjdk/6961732.patch: Dropped, applied upstream. * Makefile.am: Remove above patch. changeset ef57bbbe54da in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=ef57bbbe54da author: Andrew John Hughes date: Sun Jul 11 20:00:49 2010 +0100 Merge changeset 6085d4c7d5ce in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=6085d4c7d5ce author: Andrew John Hughes date: Wed Jul 28 11:17:13 2010 +0100 Merge changeset 999fec26cf9f in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=999fec26cf9f author: Andrew John Hughes date: Wed Jul 28 13:08:03 2010 +0100 Regenerate icedtea-jtreg-jrunscript.patch due to 50002bfcff96. 2010-07-26 Andrew John Hughes * patches/icedtea-jtreg-jrunscript.patch: Regenerate after 50002bfcff96 from dcubed being added to OpenJDK6. changeset 274608924880 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=274608924880 author: Andrew John Hughes date: Thu Aug 12 19:04:54 2010 +0100 Drop patch for 6678385; applied upstream. 2010-08-12 Andrew John Hughes * patches/openjdk/6678385-window_movement_crasher.patch: Dropped, applied upstream. * Makefile.am: Remove above patch. changeset cbec424f470f in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=cbec424f470f author: Andrew John Hughes date: Thu Aug 12 19:07:43 2010 +0100 Merge changeset 2113816251fb in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=2113816251fb author: Andrew John Hughes date: Thu Aug 12 21:13:14 2010 +0100 2010-08-12 Andrew John Hughes * patches/openjdk/4356282-opentype.patch, * patches/openjdk/6795060-icu_crash.patch, * patches/openjdk/6954424-opentype_javadoc.patch: Dropped, applied upstream. * Makefile.am: Remove above patches. changeset 4ccee81e878c in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=4ccee81e878c author: Andrew John Hughes date: Sun Sep 05 20:25:14 2010 +0100 Merge changeset 4d346d8d7d27 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=4d346d8d7d27 author: Andrew John Hughes date: Mon Sep 06 13:16:57 2010 +0100 Update JAXP tarball. Drop patch for 6438179, as applied upstream. Drop portions of 6951319 applied upstream. 2010-09-05 Andrew John Hughes * patches/openjdk/6438179-systray_check.patch: Dropped, applied upstream. * Makefile.am: Drop above patch and those brought back by merge. * patches/openjdk/6951319-sparc_build_fixes.patch: Remove upstreamed parts. changeset d70236972367 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=d70236972367 author: Andrew John Hughes date: Thu Sep 23 21:11:08 2010 +0100 Merge changeset 0452a3386f4f in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=0452a3386f4f author: Andrew John Hughes date: Fri Sep 24 00:12:54 2010 +0100 Drop upstreamed patches: 6969395, 6985992, 6721088. 2010-09-23 Andrew John Hughes * patches/icedtea-awt-window-size.patch, * patches/openjdk/6969395-net_bugs.patch, * patches/openjdk/6985992-test_6933784.patch: Dropped; upstreamed. * Makefile.am: Remove above patches. changeset 48bb2e5953e4 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=48bb2e5953e4 author: Andrew John Hughes date: Wed Sep 29 20:42:58 2010 +0100 Merge changeset 9cbb40c2b1bc in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=9cbb40c2b1bc author: Andrew John Hughes date: Thu Sep 30 10:35:41 2010 +0100 Merge changeset ab947d12cf61 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=ab947d12cf61 author: Andrew John Hughes date: Thu Sep 30 11:53:10 2010 +0100 Merge changeset da3370139f63 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=da3370139f63 author: Andrew John Hughes date: Mon Oct 18 21:32:54 2010 +0100 Merge changeset 5bc57773f41d in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=5bc57773f41d author: Andrew John Hughes date: Tue Oct 19 00:15:10 2010 +0100 Handle move to hs19 upstream, dropping Shark. Drop TimerQueue patch applied upstream. 2010-10-18 Andrew John Hughes * patches/hotspot/hs19/alpha-fixes.patch, * patches/hotspot/hs19/gcc-suffix.patch, * patches/hotspot/hs19/params-cast-size_t.patch, * patches/hotspot/hs19/print_lsb_release.patch, * patches/hotspot/hs19/update-bootclasspath.patch: Move to patches. hs19 is now the only option. * patches/hotspot/original/alpha-fixes.patch, * patches/hotspot/original/gcc-suffix.patch, * patches/hotspot/original/params-cast-size_t.patch, * patches/hotspot/original/print_lsb_release.patch, * patches/hotspot/original/update-bootclasspath.patch: Dropped; upstream moved from hs17 to hs19. * patches/icedtea-shark-build.patch: Applied upstream by Gary Benson. * patches/security/20101012/6623943.patch: Applied upstream by Omair Majid. * shark/hotspot/make/linux/makefiles/shark.make, * shark/hotspot/src/cpu/zero/vm/shark_globals_zero.hpp, * shark/hotspot/src/share/vm/includeDB_shark, * shark/hotspot/src/share/vm/shark/llvmHeaders.hpp, * shark/hotspot/src/share/vm/shark/llvmValue.hpp, * shark/hotspot/src/share/vm/shark/sharkBlock.cpp, * shark/hotspot/src/share/vm/shark/sharkBlock.hpp, * shark/hotspot/src/share/vm/shark/sharkBuilder.cpp, * shark/hotspot/src/share/vm/shark/sharkBuilder.hpp, * shark/hotspot/src/share/vm/shark/sharkCacheDecache.cpp, * shark/hotspot/src/share/vm/shark/sharkCacheDecache.hpp, * shark/hotspot/src/share/vm/shark/sharkCodeBuffer.hpp, * shark/hotspot/src/share/vm/shark/sharkCompiler.cpp, * shark/hotspot/src/share/vm/shark/sharkCompiler.hpp, * shark/hotspot/src/share/vm/shark/sharkConstant.cpp, * shark/hotspot/src/share/vm/shark/sharkConstant.hpp, * shark/hotspot/src/share/vm/shark/sharkContext.cpp, * shark/hotspot/src/share/vm/shark/sharkContext.hpp, * shark/hotspot/src/share/vm/shark/sharkEntry.hpp, * shark/hotspot/src/share/vm/shark/sharkFunction.cpp, * shark/hotspot/src/share/vm/shark/sharkFunction.hpp, * shark/hotspot/src/share/vm/shark/sharkInliner.cpp, * shark/hotspot/src/share/vm/shark/sharkInliner.hpp, * shark/hotspot/src/share/vm/shark/sharkIntrinsics.cpp, * shark/hotspot/src/share/vm/shark/sharkIntrinsics.hpp, * shark/hotspot/src/share/vm/shark/sharkInvariants.cpp, * shark/hotspot/src/share/vm/shark/sharkInvariants.hpp, * shark/hotspot/src/share/vm/shark/sharkMemoryManager.cpp, * shark/hotspot/src/share/vm/shark/sharkMemoryManager.hpp, * shark/hotspot/src/share/vm/shark/sharkNativeWrapper.cpp, * shark/hotspot/src/share/vm/shark/sharkNativeWrapper.hpp, * shark/hotspot/src/share/vm/shark/sharkRuntime.cpp, * shark/hotspot/src/share/vm/shark/sharkRuntime.hpp, * shark/hotspot/src/share/vm/shark/sharkStack.cpp, * shark/hotspot/src/share/vm/shark/sharkStack.hpp, * shark/hotspot/src/share/vm/shark/sharkState.cpp, * shark/hotspot/src/share/vm/shark/sharkState.hpp, * shark/hotspot/src/share/vm/shark/sharkStateScanner.cpp, * shark/hotspot/src/share/vm/shark/sharkStateScanner.hpp, * shark/hotspot/src/share/vm/shark/sharkTopLevelBlock.cpp, * shark/hotspot/src/share/vm/shark/sharkTopLevelBlock.hpp, * shark/hotspot/src/share/vm/shark/sharkType.hpp, * shark/hotspot/src/share/vm/shark/sharkValue.cpp, * shark/hotspot/src/share/vm/shark/sharkValue.hpp, * shark/hotspot/src/share/vm/shark/shark_globals.cpp, * shark/hotspot/src/share/vm/shark/shark_globals.hpp: Shark is in HotSpot 19. * Makefile.am: (ICEDTEA_PATCHES): Remove $(HSBUILD) special casing. Remove conditional !WITH_ALT_HSBUILD patches. (ports): Drop !WITH_ALT_HSBUILD block. (clean-ports): Likewise. * hotspot.map: Remove hs19. * patches/alpha-fixes.patch, * patches/gcc-suffix.patch, * patches/params-cast-size_t.patch, * patches/print_lsb_release.patch, * patches/update-bootclasspath.patch: The hs19 patches moved above. * acinclude.m4: (AC_CHECK_WITH_HOTSPOT_BUILD): Default to original. changeset 7d44885fc5aa in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=7d44885fc5aa author: Andrew John Hughes date: Tue Oct 19 14:28:59 2010 +0100 Drop security patches now they are available upstream. 2010-10-19 Andrew John Hughes * patches/security/20101012/6559775.patch, * patches/security/20101012/6622002.patch, * patches/security/20101012/6891766.patch, * patches/security/20101012/6914943.patch, * patches/security/20101012/6925710.patch, * patches/security/20101012/6938813.patch, * patches/security/20101012/6952017.patch, * patches/security/20101012/6952603.patch, * patches/security/20101012/6957564.patch, * patches/security/20101012/6958060.patch, * patches/security/20101012/6961084.patch, * patches/security/20101012/6963023.patch, * patches/security/20101012/6963285.patch, * patches/security/20101012/6963489.patch, * patches/security/20101012/6966692.patch, * patches/security/20101012/6981426.patch, * patches/security/20101012/6990437.patch: Dropped; available upstream. * Makefile.am: Drop above patches. * patches/icedtea-lcms.patch: Rejigged against upstream security patch. changeset 60d2b331f239 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=60d2b331f239 author: Andrew John Hughes date: Thu Oct 21 12:54:55 2010 +0100 Merge changeset 74298fcf2df8 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=74298fcf2df8 author: Andrew John Hughes date: Wed Nov 10 00:24:07 2010 +0000 Merge changeset 20166bbb476b in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=20166bbb476b author: Andrew John Hughes date: Wed Nov 10 12:47:47 2010 +0000 Drop upstreamed patches. 2010-11-09 Andrew John Hughes * patches/6703377-freetypescaler.patch, * patches/openjdk/6853592-badwindow-warning-fix.patch: Drop patches applied upstream. * Makefile.am: Drop above patches. changeset e0a9977e6bf1 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=e0a9977e6bf1 author: Andrew John Hughes date: Fri Nov 12 14:45:50 2010 +0000 Merge changeset 3a9808d594ef in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=3a9808d594ef author: Andrew John Hughes date: Fri Nov 12 16:32:05 2010 +0000 Add back freetypescaler patch, remove bigdecimal patches which are upstream. 2010-11-12 Andrew John Hughes * patches/openjdk/6622432-bigdecimal_performance.patch, * patches/openjdk/6850606-bigdecimal_regression.patch, * patches/openjdk/6876282-bigdecimal_divide.patch: Removed, upstream. * Makefile.am: Add patch below. * patches/6703377-freetypescaler.patch: Added back, not upstream (this is NOT 6703377, but an addendum to it). changeset 6246db42e88c in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=6246db42e88c author: Andrew John Hughes date: Sun Nov 14 13:53:05 2010 +0000 Merge changeset a25c22543a4c in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=a25c22543a4c author: Andrew John Hughes date: Fri Jan 07 21:43:31 2011 +0000 Merge changeset f7bd517ec204 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=f7bd517ec204 author: Andrew John Hughes date: Sat Jan 08 02:38:52 2011 +0000 Drop upstreamed patches and fix Direct3D patch broken by Oracle copyright updates. 2011-01-07 Andrew John Hughes * patches/jtreg-TestXEmbedServer-fix.patch, * patches/openjdk/6668231-ssl_cert.patch, * patches/openjdk/6687968-pngimagereader_mem_leak.patch, * patches/openjdk/6795356-proxylazyvalue-leak.patch, * patches/openjdk/6941936-broken-pipe.patch, * patches/openjdk/6943219-failure-in-linux.patch, * patches/openjdk/6951319-sparc_build_fixes.patch, * patches/openjdk/6963870-swing_npe.patch, * patches/openjdk/6979979-gtk_font_size_rounding.patch, * patches/openjdk/6994130-ppc_fix.patch: Drop upstreamed patches. * Makefile.am: Updated with above. * patches/openjdk/6725214-direct3d-01.patch: Recreated due to copyright header changes by Oracle. changeset 3c63d5967d08 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=3c63d5967d08 author: Andrew John Hughes date: Sun Jan 09 00:46:45 2011 +0000 Merge changeset 52c2b4ff95ed in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=52c2b4ff95ed author: Andrew John Hughes date: Mon Jan 10 21:26:50 2011 +0000 Remove upstreamed patches: 6541476, 6782079 and 7002666. 2011-01-10 Andrew John Hughes * patches/openjdk/6541476-png-iTXt-chunk.patch, * patches/openjdk/6782079-png_metadata_oom.patch, * patches/openjdk/7002666-eclipse_cdt_oops_crash.patch: Drop upstreamed patches. * Makefile.am: Remove above patches. changeset b645d7e86c18 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=b645d7e86c18 author: Andrew John Hughes date: Mon Jan 10 23:47:02 2011 +0000 Bump to b21. 2011-01-10 Andrew John Hughes * Makefile.am: (OPENJDK_VERSION): Bump to b21. changeset 8fbbbe4af6bc in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=8fbbbe4af6bc author: Andrew John Hughes date: Thu Jan 13 09:57:38 2011 +0000 Remove upstreamed patch 6980392 2011-01-10 Andrew John Hughes * patches/openjdk/6980392-fix_test6581734.patch: Remove upstreamed patch. * Makefile.am: Drop above patch. changeset b68332db2560 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=b68332db2560 author: Andrew John Hughes date: Fri Jan 14 13:58:40 2011 +0000 Drop jtreg-DeleteFont.patch due to backport of 7009828 regression fix. 2011-01-13 Andrew John Hughes * patches/jtreg-DeleteFont.patch: Drop patch. No longer needed due to backport of 7009828 upstream. * Makefile.am: Drop above. changeset eff8a2ddd8c0 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=eff8a2ddd8c0 author: Andrew John Hughes date: Sat Jan 22 01:06:20 2011 +0000 Merge changeset 743a3ac9f201 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=743a3ac9f201 author: Andrew John Hughes date: Sat Jan 22 02:32:01 2011 +0000 Use b21 tarball. 2011-01-22 Andrew John Hughes * Makefile.am: Use b21 tarball. diffstat: 348 files changed, 98013 insertions(+), 93866 deletions(-) .hgignore | 1 .hgtags | 1 ChangeLog | 2522 HACKING | 1 INSTALL | 373 Makefile.am | 870 NEWS | 1546 README | 116 THANKYOU | 1 acinclude.m4 | 419 arm_port/hotspot/src/cpu/zero/vm/asm_helper.cpp | 583 arm_port/hotspot/src/cpu/zero/vm/bytecodes_arm.def | 7695 + arm_port/hotspot/src/cpu/zero/vm/cppInterpreter_arm.S | 6336 + arm_port/hotspot/src/cpu/zero/vm/thumb2.cpp | 7456 + arm_port/hotspot/tools/mkbc.c | 607 configure.ac | 67 extra/net/sourceforge/jnlp/about/HTMLPanel.java | 59 extra/net/sourceforge/jnlp/about/Main.java | 135 extra/net/sourceforge/jnlp/about/resources/about.html | 28 extra/net/sourceforge/jnlp/about/resources/applications.html | 36 extra/net/sourceforge/jnlp/about/resources/notes.html | 82 javaws.desktop | 11 netx/javax/jnlp/BasicService.java | 13 netx/javax/jnlp/ClipboardService.java | 11 netx/javax/jnlp/DownloadService.java | 25 netx/javax/jnlp/DownloadServiceListener.java | 13 netx/javax/jnlp/ExtendedService.java | 51 netx/javax/jnlp/ExtensionInstallerService.java | 22 netx/javax/jnlp/FileContents.java | 18 netx/javax/jnlp/FileOpenService.java | 11 netx/javax/jnlp/FileSaveService.java | 11 netx/javax/jnlp/JNLPRandomAccessFile.java | 46 netx/javax/jnlp/PersistenceService.java | 18 netx/javax/jnlp/PrintService.java | 13 netx/javax/jnlp/ServiceManager.java | 54 netx/javax/jnlp/ServiceManagerStub.java | 11 netx/javax/jnlp/SingleInstanceListener.java | 35 netx/javax/jnlp/SingleInstanceService.java | 46 netx/javax/jnlp/UnavailableServiceException.java | 16 netx/net/sourceforge/jnlp/AppletDesc.java | 125 netx/net/sourceforge/jnlp/ApplicationDesc.java | 76 netx/net/sourceforge/jnlp/AssociationDesc.java | 56 netx/net/sourceforge/jnlp/ComponentDesc.java | 43 netx/net/sourceforge/jnlp/DefaultLaunchHandler.java | 114 netx/net/sourceforge/jnlp/ExtensionDesc.java | 145 netx/net/sourceforge/jnlp/IconDesc.java | 138 netx/net/sourceforge/jnlp/InformationDesc.java | 268 netx/net/sourceforge/jnlp/InstallerDesc.java | 54 netx/net/sourceforge/jnlp/JARDesc.java | 144 netx/net/sourceforge/jnlp/JNLPFile.java | 623 netx/net/sourceforge/jnlp/JNLPSplashScreen.java | 93 netx/net/sourceforge/jnlp/JREDesc.java | 167 netx/net/sourceforge/jnlp/LaunchException.java | 190 netx/net/sourceforge/jnlp/LaunchHandler.java | 68 netx/net/sourceforge/jnlp/Launcher.java | 786 netx/net/sourceforge/jnlp/MenuDesc.java | 38 netx/net/sourceforge/jnlp/NetxPanel.java | 147 netx/net/sourceforge/jnlp/Node.java | 147 netx/net/sourceforge/jnlp/PackageDesc.java | 105 netx/net/sourceforge/jnlp/ParseException.java | 94 netx/net/sourceforge/jnlp/Parser.java | 1202 netx/net/sourceforge/jnlp/PluginBridge.java | 253 netx/net/sourceforge/jnlp/PropertyDesc.java | 66 netx/net/sourceforge/jnlp/RelatedContentDesc.java | 93 netx/net/sourceforge/jnlp/ResourcesDesc.java | 231 netx/net/sourceforge/jnlp/SecurityDesc.java | 194 netx/net/sourceforge/jnlp/ShortcutDesc.java | 70 netx/net/sourceforge/jnlp/StreamEater.java | 45 netx/net/sourceforge/jnlp/Version.java | 354 netx/net/sourceforge/jnlp/cache/CacheEntry.java | 174 netx/net/sourceforge/jnlp/cache/CacheUtil.java | 381 netx/net/sourceforge/jnlp/cache/DefaultDownloadIndicator.java | 321 netx/net/sourceforge/jnlp/cache/DownloadIndicator.java | 92 netx/net/sourceforge/jnlp/cache/Resource.java | 271 netx/net/sourceforge/jnlp/cache/ResourceTracker.java | 1051 netx/net/sourceforge/jnlp/cache/UpdatePolicy.java | 90 netx/net/sourceforge/jnlp/cache/package.html | 28 netx/net/sourceforge/jnlp/event/ApplicationEvent.java | 57 netx/net/sourceforge/jnlp/event/ApplicationListener.java | 38 netx/net/sourceforge/jnlp/event/DownloadEvent.java | 72 netx/net/sourceforge/jnlp/event/DownloadListener.java | 51 netx/net/sourceforge/jnlp/event/package.html | 28 netx/net/sourceforge/jnlp/package.html | 30 netx/net/sourceforge/jnlp/resources/Manifest.mf | 6 netx/net/sourceforge/jnlp/resources/Messages.properties | 174 netx/net/sourceforge/jnlp/resources/about.jnlp | 20 netx/net/sourceforge/jnlp/resources/default.jnlp | 20 netx/net/sourceforge/jnlp/runtime/AppThreadGroup.java | 68 netx/net/sourceforge/jnlp/runtime/AppletAudioClip.java | 109 netx/net/sourceforge/jnlp/runtime/AppletEnvironment.java | 354 netx/net/sourceforge/jnlp/runtime/AppletInstance.java | 139 netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java | 282 netx/net/sourceforge/jnlp/runtime/Boot.java | 451 netx/net/sourceforge/jnlp/runtime/Boot13.java | 103 netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java | 1091 netx/net/sourceforge/jnlp/runtime/JNLPPolicy.java | 105 netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java | 559 netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java | 604 netx/net/sourceforge/jnlp/runtime/package.html | 29 netx/net/sourceforge/jnlp/security/AccessWarningPane.java | 215 netx/net/sourceforge/jnlp/security/AppletWarningPane.java | 121 netx/net/sourceforge/jnlp/security/CertVerifier.java | 92 netx/net/sourceforge/jnlp/security/CertWarningPane.java | 269 netx/net/sourceforge/jnlp/security/CertsInfoPane.java | 340 netx/net/sourceforge/jnlp/security/HttpsCertVerifier.java | 238 netx/net/sourceforge/jnlp/security/MoreInfoPane.java | 127 netx/net/sourceforge/jnlp/security/SecurityDialogUI.java | 204 netx/net/sourceforge/jnlp/security/SecurityUtil.java | 285 netx/net/sourceforge/jnlp/security/SecurityWarningDialog.java | 430 netx/net/sourceforge/jnlp/security/SingleCertInfoPane.java | 78 netx/net/sourceforge/jnlp/security/VariableX509TrustManager.java | 286 netx/net/sourceforge/jnlp/security/viewer/CertificatePane.java | 350 netx/net/sourceforge/jnlp/security/viewer/CertificateViewer.java | 148 netx/net/sourceforge/jnlp/services/ExtendedSingleInstanceService.java | 49 netx/net/sourceforge/jnlp/services/InstanceExistsException.java | 35 netx/net/sourceforge/jnlp/services/ServiceUtil.java | 276 netx/net/sourceforge/jnlp/services/SingleInstanceLock.java | 194 netx/net/sourceforge/jnlp/services/XBasicService.java | 234 netx/net/sourceforge/jnlp/services/XClipboardService.java | 81 netx/net/sourceforge/jnlp/services/XDownloadService.java | 181 netx/net/sourceforge/jnlp/services/XExtendedService.java | 54 netx/net/sourceforge/jnlp/services/XExtensionInstallerService.java | 123 netx/net/sourceforge/jnlp/services/XFileContents.java | 123 netx/net/sourceforge/jnlp/services/XFileOpenService.java | 113 netx/net/sourceforge/jnlp/services/XFileSaveService.java | 140 netx/net/sourceforge/jnlp/services/XJNLPRandomAccessFile.java | 208 netx/net/sourceforge/jnlp/services/XPersistenceService.java | 179 netx/net/sourceforge/jnlp/services/XPrintService.java | 123 netx/net/sourceforge/jnlp/services/XServiceManagerStub.java | 108 netx/net/sourceforge/jnlp/services/XSingleInstanceService.java | 236 netx/net/sourceforge/jnlp/services/package.html | 29 netx/net/sourceforge/jnlp/tools/CharacterEncoder.java | 354 netx/net/sourceforge/jnlp/tools/HexDumpEncoder.java | 120 netx/net/sourceforge/jnlp/tools/JarRunner.java | 15 netx/net/sourceforge/jnlp/tools/JarSigner.java | 545 netx/net/sourceforge/jnlp/tools/JarSignerResources.java | 212 netx/net/sourceforge/jnlp/tools/KeyStoreUtil.java | 69 netx/net/sourceforge/jnlp/tools/KeyTool.java | 461 netx/net/sourceforge/jnlp/util/FileUtils.java | 71 netx/net/sourceforge/jnlp/util/PropertiesFile.java | 148 netx/net/sourceforge/jnlp/util/Reflect.java | 148 netx/net/sourceforge/jnlp/util/WeakList.java | 128 netx/net/sourceforge/jnlp/util/XDesktopEntry.java | 213 netx/net/sourceforge/nanoxml/XMLElement.java | 1334 netx/net/sourceforge/nanoxml/XMLParseException.java | 130 overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/UnixNativeDispatcher.c | 37 patches/661505-jpeg.patch | 16 patches/6703377-freetypescaler.patch | 11 patches/alpha-fixes.patch | 21 patches/applet_hole.patch | 117 patches/cacao/arm-arch-defines.patch | 18 patches/cacao/version-parsing.patch | 11 patches/ecj/cp40188-opengl.patch | 92 patches/ecj/icedtea-hotspot.patch | 60 patches/ecj/needs-6.patch | 24 patches/ecj/no-test_gamma.patch | 46 patches/extensions/liveconnect-dist.patch | 76 patches/extensions/liveconnect.patch | 87 patches/extensions/netx-dist.patch | 86 patches/extensions/netx-umask.patch | 164 patches/extensions/netx.patch | 137 patches/f14-fonts.patch | 677 patches/fonts-gentoo.patch | 406 patches/fonts-rhel.patch | 457 patches/gcc-suffix.patch | 31 patches/ia64-fix.patch | 30 patches/icedtea-alpha-fixes.patch | 31 patches/icedtea-awt-window-size.patch | 67 patches/icedtea-gcc-suffix-hotspot.patch | 25 patches/icedtea-jtreg-OpenGLContextInit.patch | 46 patches/icedtea-jtreg-international-fonts.patch | 214 patches/icedtea-jtreg-jrunscript.patch | 12 patches/icedtea-lcms.patch | 25 patches/icedtea-override-redirect-metacity.patch | 11 patches/icedtea-policy-evaluation.patch | 35 patches/icedtea-print-lsb-release.patch | 48 patches/icedtea-rhino.patch | 10 patches/icedtea-shark-build.patch | 16 patches/icedtea-sparc64-linux.patch | 18 patches/icedtea-timerqueue.patch | 18 patches/icedtea-too-many-args.patch | 46 patches/ipv4-mapped-ipv6-addresses.patch | 171 patches/jtreg-6929067-fix.patch | 51 patches/jtreg-T6638712-fix.patch | 30 patches/jtreg-T6650759m-fix.patch | 6 patches/jtreg-WindowWithWarningTest.patch | 50 patches/jtreg-international-fonts-styles.patch | 280 patches/no-test_gamma.patch | 46 patches/numa_on_early_glibc.patch | 46 patches/openjdk/6307603-xrender-01.patch | 9013 + patches/openjdk/6510892-httpserver_test.patch | 122 patches/openjdk/6638712-wildcard_types.patch | 563 patches/openjdk/6642612-filechooser_button_sizes.patch | 67 patches/openjdk/6650759-missing_inference.patch | 884 patches/openjdk/6725214-direct3d-01.patch |49189 ++++++++++ patches/openjdk/6755274-glgetstring-crash.patch | 56 patches/openjdk/6791612-opengl-jni-fix.patch | 27 patches/openjdk/6800846-printing-quality.patch | 144 patches/openjdk/6961633-xrender-02.patch | 44 patches/openjdk/6961732.patch | 45 patches/openjdk/6967436-6976265-6967434-pisces.patch | 6076 + patches/openjdk/6967533-pre_epoch.patch | 57 patches/openjdk/6984543-onscreen_rendering_resize_test.patch | 30 patches/openjdk/6997495-test_correction_6857159.patch | 21 patches/openjdk/7003777-bad-html-entity-parse.patch | 80 patches/params-cast-size_t.patch | 109 patches/print_lsb_release.patch | 49 patches/rendering-engine-tests.patch | 375 patches/security/20100330/hotspot/original/6626217.patch | 180 patches/systemtap-alloc-size-workaround.patch | 17 patches/systemtap.patch | 33 patches/update-bootclasspath.patch | 13 patches/xrender-gc-cleanup.patch | 12 patches/xrender/icedtea-000.patch | 426 patches/xrender/icedtea-001.patch | 5320 - patches/xrender/icedtea-002.patch | 5199 - patches/xrender/icedtea-003.patch | 78 patches/xrender/icedtea-004.patch | 86 patches/xrender/icedtea-005.patch | 18 patches/xrender/icedtea-006.patch | 295 patches/xrender/icedtea-007.patch | 1143 patches/xrender/icedtea-008.patch | 131 patches/xrender/icedtea-009.patch | 170 plugin/icedteanp/IcedTeaJavaRequestProcessor.cc | 1392 plugin/icedteanp/IcedTeaJavaRequestProcessor.h | 233 plugin/icedteanp/IcedTeaNPPlugin.cc | 2418 plugin/icedteanp/IcedTeaNPPlugin.h | 134 plugin/icedteanp/IcedTeaPluginRequestProcessor.cc | 986 plugin/icedteanp/IcedTeaPluginRequestProcessor.h | 146 plugin/icedteanp/IcedTeaPluginUtils.cc | 1047 plugin/icedteanp/IcedTeaPluginUtils.h | 346 plugin/icedteanp/IcedTeaRunnable.cc | 75 plugin/icedteanp/IcedTeaRunnable.h | 104 plugin/icedteanp/IcedTeaScriptablePluginObject.cc | 897 plugin/icedteanp/IcedTeaScriptablePluginObject.h | 212 plugin/icedteanp/java/netscape/javascript/JSException.java | 140 plugin/icedteanp/java/netscape/javascript/JSObject.java | 297 plugin/icedteanp/java/netscape/javascript/JSObjectCreatePermission.java | 47 plugin/icedteanp/java/netscape/javascript/JSProxy.java | 58 plugin/icedteanp/java/netscape/javascript/JSRunnable.java | 72 plugin/icedteanp/java/netscape/javascript/JSUtil.java | 59 plugin/icedteanp/java/sun/applet/AppletSecurityContextManager.java | 71 plugin/icedteanp/java/sun/applet/GetMemberPluginCallRequest.java | 63 plugin/icedteanp/java/sun/applet/GetWindowPluginCallRequest.java | 65 plugin/icedteanp/java/sun/applet/JavaConsole.java | 365 plugin/icedteanp/java/sun/applet/MethodOverloadResolver.java | 696 plugin/icedteanp/java/sun/applet/PasswordAuthenticationDialog.java | 241 plugin/icedteanp/java/sun/applet/PluginAppletSecurityContext.java | 1505 plugin/icedteanp/java/sun/applet/PluginAppletViewer.java | 2186 plugin/icedteanp/java/sun/applet/PluginCallRequest.java | 89 plugin/icedteanp/java/sun/applet/PluginCallRequestFactory.java | 61 plugin/icedteanp/java/sun/applet/PluginClassLoader.java | 51 plugin/icedteanp/java/sun/applet/PluginCookieInfoRequest.java | 74 plugin/icedteanp/java/sun/applet/PluginCookieManager.java | 88 plugin/icedteanp/java/sun/applet/PluginDebug.java | 51 plugin/icedteanp/java/sun/applet/PluginException.java | 53 plugin/icedteanp/java/sun/applet/PluginMain.java | 327 plugin/icedteanp/java/sun/applet/PluginMessageConsumer.java | 294 plugin/icedteanp/java/sun/applet/PluginMessageHandlerWorker.java | 143 plugin/icedteanp/java/sun/applet/PluginObjectStore.java | 132 plugin/icedteanp/java/sun/applet/PluginProxyInfoRequest.java | 81 plugin/icedteanp/java/sun/applet/PluginProxySelector.java | 195 plugin/icedteanp/java/sun/applet/PluginStreamHandler.java | 454 plugin/icedteanp/java/sun/applet/RequestQueue.java | 77 plugin/icedteanp/java/sun/applet/TestEnv.java | 172 plugin/icedteanp/java/sun/applet/VoidPluginCallRequest.java | 54 plugin/tests/LiveConnect/DummyObject.java | 15 plugin/tests/LiveConnect/OverloadTestHelper1.java | 1 plugin/tests/LiveConnect/OverloadTestHelper2.java | 1 plugin/tests/LiveConnect/OverloadTestHelper3.java | 1 plugin/tests/LiveConnect/PluginTest.java | 710 plugin/tests/LiveConnect/build | 18 plugin/tests/LiveConnect/common.js | 219 plugin/tests/LiveConnect/index.html | 91 plugin/tests/LiveConnect/jjs_eval_test.js | 57 plugin/tests/LiveConnect/jjs_func_parameters_tests.js | 107 plugin/tests/LiveConnect/jjs_func_rettype_tests.js | 61 plugin/tests/LiveConnect/jjs_get_tests.js | 114 plugin/tests/LiveConnect/jjs_set_tests.js | 314 plugin/tests/LiveConnect/jsj_func_overload_tests.js | 181 plugin/tests/LiveConnect/jsj_func_parameters_tests.js | 216 plugin/tests/LiveConnect/jsj_func_rettype_tests.js | 262 plugin/tests/LiveConnect/jsj_get_tests.js | 260 plugin/tests/LiveConnect/jsj_set_tests.js | 318 plugin/tests/LiveConnect/jsj_type_casting_tests.js | 825 plugin/tests/LiveConnect/jsj_type_conversion_tests.js | 825 ports/hotspot/make/linux/makefiles/shark.make | 32 ports/hotspot/src/cpu/zero/vm/asm_helper.cpp | 583 ports/hotspot/src/cpu/zero/vm/bytecodes_arm.def | 7695 - ports/hotspot/src/cpu/zero/vm/cppInterpreter_arm.S | 6336 - ports/hotspot/src/cpu/zero/vm/shark_globals_zero.hpp | 62 ports/hotspot/src/cpu/zero/vm/thumb2.cpp | 7456 - ports/hotspot/src/share/vm/includeDB_shark | 369 ports/hotspot/src/share/vm/shark/llvmHeaders.hpp | 69 ports/hotspot/src/share/vm/shark/llvmValue.hpp | 62 ports/hotspot/src/share/vm/shark/sharkBlock.cpp | 1260 ports/hotspot/src/share/vm/shark/sharkBlock.hpp | 281 ports/hotspot/src/share/vm/shark/sharkBuilder.cpp | 585 ports/hotspot/src/share/vm/shark/sharkBuilder.hpp | 209 ports/hotspot/src/share/vm/shark/sharkCacheDecache.cpp | 257 ports/hotspot/src/share/vm/shark/sharkCacheDecache.hpp | 417 ports/hotspot/src/share/vm/shark/sharkCodeBuffer.hpp | 87 ports/hotspot/src/share/vm/shark/sharkCompiler.cpp | 340 ports/hotspot/src/share/vm/shark/sharkCompiler.hpp | 119 ports/hotspot/src/share/vm/shark/sharkConstant.cpp | 128 ports/hotspot/src/share/vm/shark/sharkConstant.hpp | 64 ports/hotspot/src/share/vm/shark/sharkContext.cpp | 180 ports/hotspot/src/share/vm/shark/sharkContext.hpp | 187 ports/hotspot/src/share/vm/shark/sharkEntry.hpp | 58 ports/hotspot/src/share/vm/shark/sharkFunction.cpp | 188 ports/hotspot/src/share/vm/shark/sharkFunction.hpp | 111 ports/hotspot/src/share/vm/shark/sharkInliner.cpp | 749 ports/hotspot/src/share/vm/shark/sharkInliner.hpp | 32 ports/hotspot/src/share/vm/shark/sharkIntrinsics.cpp | 277 ports/hotspot/src/share/vm/shark/sharkIntrinsics.hpp | 54 ports/hotspot/src/share/vm/shark/sharkInvariants.cpp | 37 ports/hotspot/src/share/vm/shark/sharkInvariants.hpp | 167 ports/hotspot/src/share/vm/shark/sharkMemoryManager.cpp | 116 ports/hotspot/src/share/vm/shark/sharkMemoryManager.hpp | 88 ports/hotspot/src/share/vm/shark/sharkNativeWrapper.cpp | 352 ports/hotspot/src/share/vm/shark/sharkNativeWrapper.hpp | 182 ports/hotspot/src/share/vm/shark/sharkRuntime.cpp | 251 ports/hotspot/src/share/vm/shark/sharkRuntime.hpp | 83 ports/hotspot/src/share/vm/shark/sharkStack.cpp | 263 ports/hotspot/src/share/vm/shark/sharkStack.hpp | 290 ports/hotspot/src/share/vm/shark/sharkState.cpp | 389 ports/hotspot/src/share/vm/shark/sharkState.hpp | 188 ports/hotspot/src/share/vm/shark/sharkStateScanner.cpp | 99 ports/hotspot/src/share/vm/shark/sharkStateScanner.hpp | 75 ports/hotspot/src/share/vm/shark/sharkTopLevelBlock.cpp | 1995 ports/hotspot/src/share/vm/shark/sharkTopLevelBlock.hpp | 430 ports/hotspot/src/share/vm/shark/sharkType.hpp | 112 ports/hotspot/src/share/vm/shark/sharkValue.cpp | 260 ports/hotspot/src/share/vm/shark/sharkValue.hpp | 332 ports/hotspot/src/share/vm/shark/shark_globals.cpp | 29 ports/hotspot/src/share/vm/shark/shark_globals.hpp | 54 ports/hotspot/tools/mkbc.c | 607 pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioDataLine.java | 29 pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioLine.java | 6 pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLine.java | 36 pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioTargetDataLine.java | 83 tapset/hotspot.stp.in | 2 test/jtreg/README | 6 test/jtreg/com/sun/javatest/regtest/Action.java | 20 test/jtreg/com/sun/javatest/regtest/CompileAction.java | 142 test/jtreg/com/sun/javatest/regtest/Path.java | 164 test/jtreg/com/sun/javatest/regtest/RegressionScript.java | 15 test/jtreg/com/sun/javatest/regtest/RegressionSecurityManager.java | 2 diffs (truncated from 194924 to 500 lines): diff -r aecac87c5af7 -r 743a3ac9f201 .hgignore --- a/.hgignore Tue Jul 06 18:46:18 2010 +0100 +++ b/.hgignore Sat Jan 22 02:32:01 2011 +0000 @@ -8,6 +8,7 @@ netbeans netbeans visualvm bootstrap +build debian lib tools diff -r aecac87c5af7 -r 743a3ac9f201 .hgtags --- a/.hgtags Tue Jul 06 18:46:18 2010 +0100 +++ b/.hgtags Sat Jan 22 02:32:01 2011 +0000 @@ -18,3 +18,4 @@ 9420faca6468e1c75e9bfa73b31246ba0b73a77d 9420faca6468e1c75e9bfa73b31246ba0b73a77d icedtea-1.6-branchpoint 8826d5735e2ca97ecdb35e7c977785d3e5b99556 icedtea-1.7-branchpoint 9420faca6468e1c75e9bfa73b31246ba0b73a77d icedtea6-1.8-branchpoint +cb463b94b82da269ea089c481ed5e39700525a8a icedtea6-1.9-branchpoint diff -r aecac87c5af7 -r 743a3ac9f201 ChangeLog --- a/ChangeLog Tue Jul 06 18:46:18 2010 +0100 +++ b/ChangeLog Sat Jan 22 02:32:01 2011 +0000 @@ -1,3 +1,2440 @@ 2010-07-06 Andrew John Hughes + + * Makefile.am: + Use b21 tarball. + +2011-01-21 Mark Wielaard + + * configure.ac (--with-llvm-config): Handle yes/no. + +2011-01-20 Pavel Tisnovsky + + * patches/icedtea-jtreg-international-fonts.patch: + Added copyright info and translated string originally encoded + in UTF-8 into string using Unicode escape notation in + regression test InternationalFontsRendering.java + +2011-01-18 Pavel Tisnovsky + + * Makefile.am: Apply patch. + * patches/jtreg-international-fonts-styles.patch: + Added new font regression test - InternationalFontsStyles + +2011-01-17 Omair Majid + + * Makefile.am (ICEDTEA_PATCHES): Add new patch. + * patches/openjdk/6642612-filechooser_button_sizes.patch: New file. + +2011-01-13 Andrew John Hughes + + * patches/jtreg-DeleteFont.patch: + Drop patch. No longer needed due to backport + of 7009828 upstream. + * Makefile.am: Drop above. + +2011-01-13 Andrew John Hughes + + * patches/openjdk/6980392-fix_test6581734.patch: + Remove upstreamed patch. + * Makefile.am: Drop above patch. + +2011-01-10 Andrew John Hughes + + * Makefile.am: + (OPENJDK_VERSION): Bump to b21. + +2011-01-10 Andrew John Hughes + + * patches/openjdk/6541476-png-iTXt-chunk.patch, + * patches/openjdk/6782079-png_metadata_oom.patch, + * patches/openjdk/7002666-eclipse_cdt_oops_crash.patch: + Drop upstreamed patches. + * Makefile.am: + Remove above patches. + +2011-01-07 Andrew John Hughes + + * patches/jtreg-TestXEmbedServer-fix.patch: + Moved to... + * Makefile.am: + Fix path to above patch. Only apply jtreg-6929067-fix.patch + when building hs19. + * patches/openjdk/6560348-jtreg-TestXEmbedServer-fix.patch: + ... OpenJDK patch with appropriate bug ID. + +2011-01-07 Andrew John Hughes + + * patches/jtreg-TestXEmbedServer-fix.patch, + * patches/openjdk/6668231-ssl_cert.patch, + * patches/openjdk/6687968-pngimagereader_mem_leak.patch, + * patches/openjdk/6795356-proxylazyvalue-leak.patch, + * patches/openjdk/6941936-broken-pipe.patch, + * patches/openjdk/6943219-failure-in-linux.patch, + * patches/openjdk/6951319-sparc_build_fixes.patch, + * patches/openjdk/6963870-swing_npe.patch, + * patches/openjdk/6979979-gtk_font_size_rounding.patch, + * patches/openjdk/6994130-ppc_fix.patch: + Drop upstreamed patches. + * Makefile.am: Updated with above. + * patches/openjdk/6725214-direct3d-01.patch: + Recreated due to copyright header changes by Oracle. + +2011-01-04 Denis Lila + + Fixed RH661505. + * NEWS: Updated with fix. + * Makefile.am: Apply patch. + * patches/661506-jpeg.patch: New file. Bug fix. + +2011-01-04 Deepak Bhole + + Backport S6687968, S6541476, S6782079 + * Makefile.am: Add missing "\" to the patch list, update to include + new patches. + * NEWS: Updated. + * patches/openjdk/6687968-pngimagereader_mem_leak.patch: Backport to allow + S6541476 fix to apply cleanly. + * patches/openjdk/6541476-png-iTXt-chunk.patch: Backport to fix iTXt chunk + handling for png images. Also addresses RH665355. + * patches/openjdk/6782079-png_metadata_oom.patch: Backport to fix + potential OOM error when reading metadata on truncated pngs. + +2010-12-31 Mark Wielaard + + * Makefile.am (ICEDTEA_PATCHES): Add missing backslash. + +2010-12-22 Jiri Vanek + + * NEWS: Updated with rh.bugzilas. + * patches/fonts-rhel.patch:repaired rhel 6 fonts configuration. + +2010-12-21 Denis Lila + + Backport S6800846. + * NEWS: Updated with fixes. + * Makefile.am: Apply patch. + * patches/openjdk/6800846-printing-quality.patch: New file. Backport + of S6795356, and fix for RH662230. + +2010-12-17 Denis Lila + Pavel Tisnovsky + + * patches/rendering-engine-tests.patch: + Improved the tests by using the rendering engine explicitly. + +2010-12-16 Pavel Tisnovsky + + * Makefile.am: Add new patch. + * patches/jtreg-TestXEmbedServer-fix.patch: + Testcase correction - the test should also work on Gnome with upper + panel displayed. + +2010-12-14 Denis Lila , Pavel Tisnovsky + + * Makefile.am: Add new patch. + * patches/rendering-engine-tests.patch: + Added new regression test used to check rendering engine behaviour. + +2010-12-13 Denis Lila + + Backport S6795356. + * NEWS: Updated with fixes. + * Makefile.am: Apply patch. + * patches/openjdk/6795356-proxylazyvalue-leak.patch: New file. Backport + of S6795356, and fix for S7004655 and PR590. + +2010-12-10 Omair Majid + + Backport S6979979. + * NEWS: Updated with fix. + * Makefile.am: Apply patch. + * patches/openjdk/6979979-gtk_font_size_rounding.patch: New file. Backport + of S6979979. + +2010-12-08 Pavel Tisnovsky + + * Makefile.am: Add new patch. + * patches/jtreg-6929067-fix.patch: + Testcase correction - now the test works correctly also on x86_64 and + other platforms. + +2010-12-07 Pavel Tisnovsky + + * Makefile.am: + (ICEDTEA_PATCHES): Updated. + * patches/openjdk/6941936-broken-pipe.patch: + * patches/openjdk/6943219-failure-in-linux.patch: + Backport of regression test fix. + +2010-12-06 Denis Lila + + * Makefile.am: + Changed patch name. + * patches/openjdk/647674-bad-html-entity-parse.patch: Removed. + * patches/openjdk/7003777-bad-html-entity-parse.patch: A rename + of the removed patch. + * NEWS: updated with the correct patch names. + +2010-12-06 Denis Lila + + * Makefile.am: + Added patch. + * patches/openjdk/647674-bad-html-entity-parse.patch: + Fixed issue where the parsing of tokens such as "&xyz" in html + documents would insert "&xyz;" in the document. + +2010-12-06 Pavel Tisnovsky + + * Makefile.am: + (ICEDTEA_PATCHES): Updated. + * patches/jtreg-T6650759m-fix.patch: + Regression test fix - corrected .out file used for + check messages generated by java compiler. + +2010-12-01 Andrew John Hughes + + * patches/applet_hole.patch: + Add generic types to Hashtable to stop warnings + when building icedtea-web. + +2010-12-02 Pavel Tisnovsky + + * test/jtreg/com/sun/javatest/regtest/CompileAction.java: + Removed printing of unnecessary messages from JTreg harness. + +2010-12-01 Andrew John Hughes + + * Makefile.am: Apply 7002666 to both hs17 + and hs19. + +2010-12-01 Andrew John Hughes + + * patches/disable-default-compoops.patch: Removed. + * Makefile.am: Replace disable compressed oops workaround + with proper fix for 7002666. + * patches/openjdk/7002666-eclipse_cdt_oops_crash.patch: + Backport of 7002666: Eclipse CDT projects crash with + compressed oops + * NEWS: Updated. + +2010-12-01 Matthias Klose + + * patches/icedtea-sparc64-linux.patch: Remove obsolete chunk. + +2010-11-30 Pavel Tisnovsky + + * Makefile.am: + (ICEDTEA_PATCHES): Updated. + * patches/jtreg-T6638712-fix.patch: + Regression test fix - compilation results are checked against + correct .out files. + +2010-11-29 Pavel Tisnovsky + + * Makefile.am: + (ICEDTEA_PATCHES): Updated. + * patches/jtreg-WindowWithWarningTest.patch: + Regression test fix - setup of SecurityManager to + run this test as regular applet but with AWT robot enabled. + +2010-11-29 Matthias Klose + + * patches/hotspot/hs19/ia64-fix.patch: Reapply chunk from + patches/zero/6896043.patch. + +2010-11-29 Matthias Klose + + * patches/hotspot/hs19/params-cast-size_t.patch: Update for hs19. + +2010-11-24 Andrew John Hughes + + Final plugin & NetX cleanup. + * patches/extensions/netx-umask.patch: + Dropped. NetX is no longer in IcedTea6 + and IcedTea-Web uses java to do the same thing. + * patches/extensions/netx.patch: + Remove javaws binary and javax.jnlp documentation + production; the requisite classes no longer exist. + Move rest to applet_hole.patch. + * Makefile.am: + (ICEDTEA_PATCHES): Updated. + * NEWS: Move NetX and plugin sections for 1.10 + to IcedTea-Web. + * patches/applet_hole.patch: Remainder of netx.patch + which makes AppletViewerPanel accessible. + +2010-11-24 Andrew John Hughes + + * NEWS: Add 1.7.6, 1.8.3 and 1.9.2 releases. + +2010-11-23 Pavel Tisnovsky + + * test/jtreg/README: + Updated. + * test/jtreg/com/sun/javatest/regtest/Path.java: + * test/jtreg/com/sun/javatest/regtest/Action.java: + * test/jtreg/com/sun/javatest/regtest/CompileAction.java: + * test/jtreg/com/sun/javatest/regtest/RegressionScript.java: + * test/jtreg/com/sun/javatest/regtest/RegressionSecurityManager.java: + Corrected JTreg harness - this tool now accepts "process" flag for + "compile" tag and also correctly sets properties during "compile" + phase. + +2010-11-22 Matthias Klose + + * Makefile.am (stamps/add-zero.stamp): Add shark alias when building + zero with shark support on hotspot archs. + +2010-11-19 Andrew John Hughes + + * Makefile.am: Add new patch. + * patches/xrender-gc-cleanup.patch: + Fix memory leak in XRender pipeline. + +2010-11-19 Andrew John Hughes + + * Makefile.am: + Add download-cacao alias. + (CACAO_BASE_URL): Switch to using IcedTea + server for CACAO drops too. + (CACAO_URL): Likewise. + +2010-11-15 Pavel Tisnovsky + + * Makefile.am: Add patch. + * patches/jtreg-DeleteFont.patch: + Testcase correction - the test now ignores directory created by HS. + +2010-11-12 Andrew John Hughes + + * Makefile.am: + (clean-local): Add clean-fonts. + (.PHONY): Likewise. + (clean-fonts): Remove fonts.stamp. + +2010-11-12 Andrew John Hughes + + * patches/openjdk/6622432-bigdecimal_performance.patch, + * patches/openjdk/6850606-bigdecimal_regression.patch, + * patches/openjdk/6876282-bigdecimal_divide.patch: + Removed, upstream. + * Makefile.am: Add patch below. + * patches/6703377-freetypescaler.patch: + Added back, not upstream (this is NOT 6703377, but + an addendum to it). + +2010-11-11 Stefan Ring + + * Makefile.am: Upgrade CACAO version, use .tar.gz archive + +2010-11-09 Andrew John Hughes + + * patches/6703377-freetypescaler.patch, + * patches/openjdk/6853592-badwindow-warning-fix.patch: + Drop patches applied upstream. + * Makefile.am: Drop above patches. + +2010-11-11 Stefan Ring + + * patches/cacao/arm-arch-defines.patch: + Adapted to new Boehm GC version. + +2010-11-11 Pavel Tisnovsky + + * Makefile.am: Add new patch. + * patches/openjdk/6980392-fix_test6581734.patch: + Testcase correction - added missing right bracket. + +2010-11-10 Andrew John Hughes + + * Makefile.am: Remove additional whitespace. + +2010-11-10 Andrew John Hughes + + RH647737 + Disable compressed oops in hs19. + * Makefile.am: Add new patch. + * patches/disable-default-compoops.patch: + New patch to turn off compressed oops by default. + +2010-11-10 Jiri Vanek + + * Makefile.am: + (FONTCONFIG_PATH): Added path to fontconfig files. + (ICEDTEA_PATCHES): Add f14-fonts.patch. + (fonts): Added cloning of fontconfig.Fedora + to Fedora.12,11,10,9. + (patch-fsg): Depend on fonts.stamp. + * patches/f14-fonts.patch + Updated font configurations for Fedora 9-14 + Add additional fontconfig files to Makefile. + +2010-11-10 Andrew John Hughes + + * Makefile.am: Add BigDecimal/Integer performance + improvement patches. + * patches/openjdk/6622432-bigdecimal_performance.patch, + * patches/openjdk/6850606-bigdecimal_regression.patch, + * patches/openjdk/6876282-bigdecimal_divide.patch: + Added. + +2010-11-09 Andrew John Hughes + + * Makefile.am: + (JAXWS_DROP_URL): Switch to IcedTea server. + (JAXP_DROP_URL): Likewise. + (JAF_DROP_URL): Likewise. + +2010-11-08 Pavel Tisnovsky + + * Makefile.am: Add patch. + * patches/openjdk/6997495-test_correction_6857159.patch: + Testcase correction, now the regression test Test6857159 should + not timeout on most machines. + +2010-11-05 Denis Lila + + * Makefile.am: + Apply backported patch. + * patches/openjdk/6967436-6976265-6967434-pisces.patch: + Backport of the openjdk7 rendering engine, which fixes + various bugs and includes performance improvements. + +2010-11-05 Andrew John Hughes + + * hotspot.map: + Switch back to master now changes have been + pushed through (same content, different tree). + +2010-11-03 Dan Hor??k + + * patches/hotspot/hs19/params-cast-size_t.patch: + Add additional fixes for S390. + +2010-11-02 Andrew John Hughes + + * hotspot.map: Update md5sum for new + HotSpot. + +2010-11-02 Andrew John Hughes + + * Makefile.am: + (replace-hotspot): Don't hardcode 'master' + as the top-level directory, extract it + from the url. + * hotspot.map: Move to latest hs19 (currently + only on baseline tree) + +2010-11-02 Pavel Tisnovsky + + * Makefile.am: + * patches/icedtea-jtreg-international-fonts.patch: + Added new regression test + patches/icedtea-jtreg-international-fonts.patch + for checking if all non-Latin fonts are installed + and properly configured. + +2010-10-22 Andrew John Hughes + + * Makefile.am: Add new patch for hs19 + builds only. + * NEWS: Mention fix. + * patches/openjdk/6994130-ppc_fix.patch: + Fix build on PPC machines (thanks to Gary + Benson). + +2010-10-22 Andrew John Hughes + + * acinclude.m4: + (FIND_JAVAC): Don't fail if $JAVAC is empty, + ecj.jar can be used. + (FIND_ECJ_JAR): Check additional Gentoo locations. + Fail only if both $JAVAC is empty and ECJ_JAR is no. + +2010-10-20 Andrew John Hughes + + * INSTALL: Clarify HotSpot build documentation. + * acinclude.m4: + (AC_CHECK_WITH_HOTSPOT_BUILD): Don't abuse + DEFAULT_BUILD. Introduce ORIGINAL_BUILD to + represent the ORIGINAL BUILD and use that in + the conditional and for --without-hotspot-build. + Use DEFAULT_BUILD only for when the option is + not specified. + +2010-10-19 Andrew John Hughes + + * patches/security/20101012/6559775.patch, + * patches/security/20101012/6622002.patch, + * patches/security/20101012/6891766.patch, + * patches/security/20101012/6914943.patch, + * patches/security/20101012/6925710.patch, + * patches/security/20101012/6938813.patch, + * patches/security/20101012/6952017.patch, + * patches/security/20101012/6952603.patch, + * patches/security/20101012/6957564.patch, + * patches/security/20101012/6958060.patch, + * patches/security/20101012/6961084.patch, From andrew at icedtea.classpath.org Fri Jan 21 19:49:03 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Sat, 22 Jan 2011 03:49:03 +0000 Subject: /hg/icedtea6-hg: 7 new changesets Message-ID: changeset 974192ac0471 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=974192ac0471 author: Omair Majid date: Mon Jan 17 16:51:25 2011 -0500 Backport S6642612: JFileChooser's approve buttons should be the same size (GTK) 2011-01-17 Omair Majid * Makefile.am (ICEDTEA_PATCHES): Add new patch. * patches/openjdk/6642612-filechooser_button_sizes.patch: New file. changeset 477489da7897 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=477489da7897 author: ptisnovs date: Tue Jan 18 16:45:33 2011 +0100 Added new regression test InternationalFontsStyles.java. changeset f3aee1b5e567 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=f3aee1b5e567 author: ptisnovs date: Thu Jan 20 16:33:23 2011 +0100 Added copyright info and translated string originally encoded in UTF-8 into string using Unicode escape notation in regression test InternationalFontsRendering.java changeset 52a48baed3cf in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=52a48baed3cf author: Mark Wielaard date: Fri Jan 21 22:53:33 2011 +0100 * configure.ac (--with-llvm-config): Handle yes/no. changeset eff8a2ddd8c0 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=eff8a2ddd8c0 author: Andrew John Hughes date: Sat Jan 22 01:06:20 2011 +0000 Merge changeset 743a3ac9f201 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=743a3ac9f201 author: Andrew John Hughes date: Sat Jan 22 02:32:01 2011 +0000 Use b21 tarball. 2011-01-22 Andrew John Hughes * Makefile.am: Use b21 tarball. changeset 6ce6dfbaebe5 in /hg/icedtea6-hg details: http://icedtea.classpath.org/hg/icedtea6-hg?cmd=changeset;node=6ce6dfbaebe5 author: Andrew John Hughes date: Sat Jan 22 03:48:53 2011 +0000 2011-01-22 Andrew John Hughes * Makefile.am: Bump to b22. diffstat: 122 files changed, 1423 insertions(+), 32031 deletions(-) ChangeLog | 250 Makefile.am | 120 NEWS | 2 acinclude.m4 | 4 configure.ac | 2 hotspot.map | 2 patches/alpha-fixes.patch | 21 patches/gcc-suffix.patch | 31 patches/hotspot/hs19/alpha-fixes.patch | 21 patches/hotspot/hs19/gcc-suffix.patch | 31 patches/hotspot/hs19/ia64-fix.patch | 30 patches/hotspot/hs19/params-cast-size_t.patch | 295 patches/hotspot/hs19/print_lsb_release.patch | 49 patches/hotspot/hs19/update-bootclasspath.patch | 13 patches/hotspot/original/alpha-fixes.patch | 31 patches/hotspot/original/gcc-suffix.patch | 25 patches/hotspot/original/params-cast-size_t.patch | 274 patches/hotspot/original/print_lsb_release.patch | 48 patches/hotspot/original/update-bootclasspath.patch | 13 patches/ia64-fix.patch | 30 patches/icedtea-jtreg-international-fonts.patch | 39 patches/icedtea-jtreg-jrunscript.patch | 12 patches/icedtea-lcms.patch | 25 patches/icedtea-shark-build.patch | 16 patches/jtreg-DeleteFont.patch | 20 patches/jtreg-international-fonts-styles.patch | 280 patches/openjdk/4356282-opentype.patch | 227 patches/openjdk/6438179-systray_check.patch | 92 patches/openjdk/6541476-png-iTXt-chunk.patch | 549 - patches/openjdk/6560348-jtreg-TestXEmbedServer-fix.patch | 25 patches/openjdk/6622432-bigdecimal_performance.patch | 4211 -------------- patches/openjdk/6642612-filechooser_button_sizes.patch | 67 patches/openjdk/6668231-ssl_cert.patch | 306 - patches/openjdk/6678385-window_movement_crasher.patch | 1241 ---- patches/openjdk/6687968-pngimagereader_mem_leak.patch | 126 patches/openjdk/6721088-awt_window_size.patch | 67 patches/openjdk/6725214-direct3d-01.patch | 667 +- patches/openjdk/6782079-png_metadata_oom.patch | 4122 ------------- patches/openjdk/6795060-icu_crash.patch | 95 patches/openjdk/6795356-proxylazyvalue-leak.patch | 320 - patches/openjdk/6850606-bigdecimal_regression.patch | 144 patches/openjdk/6853592-badwindow-warning-fix.patch | 16 patches/openjdk/6876282-bigdecimal_divide.patch | 89 patches/openjdk/6941936-broken-pipe.patch | 438 - patches/openjdk/6943219-failure-in-linux.patch | 73 patches/openjdk/6951319-sparc_build_fixes.patch | 642 -- patches/openjdk/6954424-opentype_javadoc.patch | 23 patches/openjdk/6961732-negative_leading.patch | 45 patches/openjdk/6963870-swing_npe.patch | 99 patches/openjdk/6969395-net_bugs.patch | 461 - patches/openjdk/6979979-gtk_font_size_rounding.patch | 57 patches/openjdk/6980392-fix_test6581734.patch | 21 patches/openjdk/6985992-test_6933784.patch | 43 patches/openjdk/6994130-ppc_fix.patch | 11 patches/openjdk/7002666-eclipse_cdt_oops_crash.patch | 79 patches/params-cast-size_t.patch | 295 patches/print_lsb_release.patch | 49 patches/security/20101012/6559775.patch | 317 - patches/security/20101012/6622002.patch | 64 patches/security/20101012/6623943.patch | 138 patches/security/20101012/6891766.patch | 1147 --- patches/security/20101012/6914943.patch | 2129 ------- patches/security/20101012/6925710.patch | 198 patches/security/20101012/6938813.patch | 196 patches/security/20101012/6952017.patch | 50 patches/security/20101012/6952603.patch | 38 patches/security/20101012/6957564.patch | 77 patches/security/20101012/6958060.patch | 15 patches/security/20101012/6961084.patch | 325 - patches/security/20101012/6963023.patch | 95 patches/security/20101012/6963285.patch | 20 patches/security/20101012/6963489.patch | 31 patches/security/20101012/6966692.patch | 91 patches/security/20101012/6981426.patch | 24 patches/security/20101012/6990437.patch | 116 patches/update-bootclasspath.patch | 13 shark/hotspot/make/linux/makefiles/shark.make | 32 shark/hotspot/src/cpu/zero/vm/shark_globals_zero.hpp | 62 shark/hotspot/src/share/vm/includeDB_shark | 369 - shark/hotspot/src/share/vm/shark/llvmHeaders.hpp | 82 shark/hotspot/src/share/vm/shark/llvmValue.hpp | 62 shark/hotspot/src/share/vm/shark/sharkBlock.cpp | 1260 ---- shark/hotspot/src/share/vm/shark/sharkBlock.hpp | 281 shark/hotspot/src/share/vm/shark/sharkBuilder.cpp | 591 - shark/hotspot/src/share/vm/shark/sharkBuilder.hpp | 209 shark/hotspot/src/share/vm/shark/sharkCacheDecache.cpp | 259 shark/hotspot/src/share/vm/shark/sharkCacheDecache.hpp | 417 - shark/hotspot/src/share/vm/shark/sharkCodeBuffer.hpp | 87 shark/hotspot/src/share/vm/shark/sharkCompiler.cpp | 340 - shark/hotspot/src/share/vm/shark/sharkCompiler.hpp | 119 shark/hotspot/src/share/vm/shark/sharkConstant.cpp | 128 shark/hotspot/src/share/vm/shark/sharkConstant.hpp | 64 shark/hotspot/src/share/vm/shark/sharkContext.cpp | 180 shark/hotspot/src/share/vm/shark/sharkContext.hpp | 187 shark/hotspot/src/share/vm/shark/sharkEntry.hpp | 58 shark/hotspot/src/share/vm/shark/sharkFunction.cpp | 188 shark/hotspot/src/share/vm/shark/sharkFunction.hpp | 111 shark/hotspot/src/share/vm/shark/sharkInliner.cpp | 749 -- shark/hotspot/src/share/vm/shark/sharkInliner.hpp | 32 shark/hotspot/src/share/vm/shark/sharkIntrinsics.cpp | 277 shark/hotspot/src/share/vm/shark/sharkIntrinsics.hpp | 54 shark/hotspot/src/share/vm/shark/sharkInvariants.cpp | 37 shark/hotspot/src/share/vm/shark/sharkInvariants.hpp | 167 shark/hotspot/src/share/vm/shark/sharkMemoryManager.cpp | 116 shark/hotspot/src/share/vm/shark/sharkMemoryManager.hpp | 88 shark/hotspot/src/share/vm/shark/sharkNativeWrapper.cpp | 352 - shark/hotspot/src/share/vm/shark/sharkNativeWrapper.hpp | 182 shark/hotspot/src/share/vm/shark/sharkRuntime.cpp | 251 shark/hotspot/src/share/vm/shark/sharkRuntime.hpp | 83 shark/hotspot/src/share/vm/shark/sharkStack.cpp | 263 shark/hotspot/src/share/vm/shark/sharkStack.hpp | 290 shark/hotspot/src/share/vm/shark/sharkState.cpp | 389 - shark/hotspot/src/share/vm/shark/sharkState.hpp | 188 shark/hotspot/src/share/vm/shark/sharkStateScanner.cpp | 99 shark/hotspot/src/share/vm/shark/sharkStateScanner.hpp | 75 shark/hotspot/src/share/vm/shark/sharkTopLevelBlock.cpp | 1991 ------ shark/hotspot/src/share/vm/shark/sharkTopLevelBlock.hpp | 430 - shark/hotspot/src/share/vm/shark/sharkType.hpp | 112 shark/hotspot/src/share/vm/shark/sharkValue.cpp | 260 shark/hotspot/src/share/vm/shark/sharkValue.hpp | 332 - shark/hotspot/src/share/vm/shark/shark_globals.cpp | 29 shark/hotspot/src/share/vm/shark/shark_globals.hpp | 54 diffs (truncated from 35653 to 500 lines): diff -r fd09f4a3b767 -r 6ce6dfbaebe5 ChangeLog --- a/ChangeLog Sun Jan 09 00:43:01 2011 +0000 +++ b/ChangeLog Sat Jan 22 03:48:53 2011 +0000 @@ -1,3 +1,62 @@ 2011-01-07 Andrew John Hughes + + * Makefile.am: + Bump to b22. + +2011-01-22 Andrew John Hughes + + * Makefile.am: + Use b21 tarball. + +2011-01-21 Mark Wielaard + + * configure.ac (--with-llvm-config): Handle yes/no. + +2011-01-20 Pavel Tisnovsky + + * patches/icedtea-jtreg-international-fonts.patch: + Added copyright info and translated string originally encoded + in UTF-8 into string using Unicode escape notation in + regression test InternationalFontsRendering.java + +2011-01-18 Pavel Tisnovsky + + * Makefile.am: Apply patch. + * patches/jtreg-international-fonts-styles.patch: + Added new font regression test - InternationalFontsStyles + +2011-01-17 Omair Majid + + * Makefile.am (ICEDTEA_PATCHES): Add new patch. + * patches/openjdk/6642612-filechooser_button_sizes.patch: New file. + +2011-01-13 Andrew John Hughes + + * patches/jtreg-DeleteFont.patch: + Drop patch. No longer needed due to backport + of 7009828 upstream. + * Makefile.am: Drop above. + +2011-01-13 Andrew John Hughes + + * patches/openjdk/6980392-fix_test6581734.patch: + Remove upstreamed patch. + * Makefile.am: Drop above patch. + +2011-01-10 Andrew John Hughes + + * Makefile.am: + (OPENJDK_VERSION): Bump to b21. + +2011-01-10 Andrew John Hughes + + * patches/openjdk/6541476-png-iTXt-chunk.patch, + * patches/openjdk/6782079-png_metadata_oom.patch, + * patches/openjdk/7002666-eclipse_cdt_oops_crash.patch: + Drop upstreamed patches. + * Makefile.am: + Remove above patches. + 2011-01-07 Andrew John Hughes * patches/jtreg-TestXEmbedServer-fix.patch: @@ -7,6 +66,23 @@ 2011-01-07 Andrew John Hughes + + * patches/jtreg-TestXEmbedServer-fix.patch, + * patches/openjdk/6668231-ssl_cert.patch, + * patches/openjdk/6687968-pngimagereader_mem_leak.patch, + * patches/openjdk/6795356-proxylazyvalue-leak.patch, + * patches/openjdk/6941936-broken-pipe.patch, + * patches/openjdk/6943219-failure-in-linux.patch, + * patches/openjdk/6951319-sparc_build_fixes.patch, + * patches/openjdk/6963870-swing_npe.patch, + * patches/openjdk/6979979-gtk_font_size_rounding.patch, + * patches/openjdk/6994130-ppc_fix.patch: + Drop upstreamed patches. + * Makefile.am: Updated with above. + * patches/openjdk/6725214-direct3d-01.patch: + Recreated due to copyright header changes by Oracle. 2011-01-04 Denis Lila @@ -241,9 +317,27 @@ 2010-11-12 Andrew John Hughes + + * patches/openjdk/6622432-bigdecimal_performance.patch, + * patches/openjdk/6850606-bigdecimal_regression.patch, + * patches/openjdk/6876282-bigdecimal_divide.patch: + Removed, upstream. + * Makefile.am: Add patch below. + * patches/6703377-freetypescaler.patch: + Added back, not upstream (this is NOT 6703377, but + an addendum to it). + 2010-11-11 Stefan Ring * Makefile.am: Upgrade CACAO version, use .tar.gz archive + +2010-11-09 Andrew John Hughes + + * patches/6703377-freetypescaler.patch, + * patches/openjdk/6853592-badwindow-warning-fix.patch: + Drop patches applied upstream. + * Makefile.am: Drop above patches. 2010-11-11 Stefan Ring @@ -372,6 +466,110 @@ 2010-10-20 Andrew John Hughes + + * patches/security/20101012/6559775.patch, + * patches/security/20101012/6622002.patch, + * patches/security/20101012/6891766.patch, + * patches/security/20101012/6914943.patch, + * patches/security/20101012/6925710.patch, + * patches/security/20101012/6938813.patch, + * patches/security/20101012/6952017.patch, + * patches/security/20101012/6952603.patch, + * patches/security/20101012/6957564.patch, + * patches/security/20101012/6958060.patch, + * patches/security/20101012/6961084.patch, + * patches/security/20101012/6963023.patch, + * patches/security/20101012/6963285.patch, + * patches/security/20101012/6963489.patch, + * patches/security/20101012/6966692.patch, + * patches/security/20101012/6981426.patch, + * patches/security/20101012/6990437.patch: + Dropped; available upstream. + * Makefile.am: Drop above patches. + * patches/icedtea-lcms.patch: Rejigged against + upstream security patch. + +2010-10-18 Andrew John Hughes + + * patches/hotspot/hs19/alpha-fixes.patch, + * patches/hotspot/hs19/gcc-suffix.patch, + * patches/hotspot/hs19/params-cast-size_t.patch, + * patches/hotspot/hs19/print_lsb_release.patch, + * patches/hotspot/hs19/update-bootclasspath.patch: + Move to patches. hs19 is now the only option. + * patches/hotspot/original/alpha-fixes.patch, + * patches/hotspot/original/gcc-suffix.patch, + * patches/hotspot/original/params-cast-size_t.patch, + * patches/hotspot/original/print_lsb_release.patch, + * patches/hotspot/original/update-bootclasspath.patch: + Dropped; upstream moved from hs17 to hs19. + * patches/icedtea-shark-build.patch: + Applied upstream by Gary Benson. + * patches/security/20101012/6623943.patch: + Applied upstream by Omair Majid. + * shark/hotspot/make/linux/makefiles/shark.make, + * shark/hotspot/src/cpu/zero/vm/shark_globals_zero.hpp, + * shark/hotspot/src/share/vm/includeDB_shark, + * shark/hotspot/src/share/vm/shark/llvmHeaders.hpp, + * shark/hotspot/src/share/vm/shark/llvmValue.hpp, + * shark/hotspot/src/share/vm/shark/sharkBlock.cpp, + * shark/hotspot/src/share/vm/shark/sharkBlock.hpp, + * shark/hotspot/src/share/vm/shark/sharkBuilder.cpp, + * shark/hotspot/src/share/vm/shark/sharkBuilder.hpp, + * shark/hotspot/src/share/vm/shark/sharkCacheDecache.cpp, + * shark/hotspot/src/share/vm/shark/sharkCacheDecache.hpp, + * shark/hotspot/src/share/vm/shark/sharkCodeBuffer.hpp, + * shark/hotspot/src/share/vm/shark/sharkCompiler.cpp, + * shark/hotspot/src/share/vm/shark/sharkCompiler.hpp, + * shark/hotspot/src/share/vm/shark/sharkConstant.cpp, + * shark/hotspot/src/share/vm/shark/sharkConstant.hpp, + * shark/hotspot/src/share/vm/shark/sharkContext.cpp, + * shark/hotspot/src/share/vm/shark/sharkContext.hpp, + * shark/hotspot/src/share/vm/shark/sharkEntry.hpp, + * shark/hotspot/src/share/vm/shark/sharkFunction.cpp, + * shark/hotspot/src/share/vm/shark/sharkFunction.hpp, + * shark/hotspot/src/share/vm/shark/sharkInliner.cpp, + * shark/hotspot/src/share/vm/shark/sharkInliner.hpp, + * shark/hotspot/src/share/vm/shark/sharkIntrinsics.cpp, + * shark/hotspot/src/share/vm/shark/sharkIntrinsics.hpp, + * shark/hotspot/src/share/vm/shark/sharkInvariants.cpp, + * shark/hotspot/src/share/vm/shark/sharkInvariants.hpp, + * shark/hotspot/src/share/vm/shark/sharkMemoryManager.cpp, + * shark/hotspot/src/share/vm/shark/sharkMemoryManager.hpp, + * shark/hotspot/src/share/vm/shark/sharkNativeWrapper.cpp, + * shark/hotspot/src/share/vm/shark/sharkNativeWrapper.hpp, + * shark/hotspot/src/share/vm/shark/sharkRuntime.cpp, + * shark/hotspot/src/share/vm/shark/sharkRuntime.hpp, + * shark/hotspot/src/share/vm/shark/sharkStack.cpp, + * shark/hotspot/src/share/vm/shark/sharkStack.hpp, + * shark/hotspot/src/share/vm/shark/sharkState.cpp, + * shark/hotspot/src/share/vm/shark/sharkState.hpp, + * shark/hotspot/src/share/vm/shark/sharkStateScanner.cpp, + * shark/hotspot/src/share/vm/shark/sharkStateScanner.hpp, + * shark/hotspot/src/share/vm/shark/sharkTopLevelBlock.cpp, + * shark/hotspot/src/share/vm/shark/sharkTopLevelBlock.hpp, + * shark/hotspot/src/share/vm/shark/sharkType.hpp, + * shark/hotspot/src/share/vm/shark/sharkValue.cpp, + * shark/hotspot/src/share/vm/shark/sharkValue.hpp, + * shark/hotspot/src/share/vm/shark/shark_globals.cpp, + * shark/hotspot/src/share/vm/shark/shark_globals.hpp: + Shark is in HotSpot 19. + * Makefile.am: + (ICEDTEA_PATCHES): Remove $(HSBUILD) special casing. + Remove conditional !WITH_ALT_HSBUILD patches. + (ports): Drop !WITH_ALT_HSBUILD block. + (clean-ports): Likewise. + * hotspot.map: Remove hs19. + * patches/alpha-fixes.patch, + * patches/gcc-suffix.patch, + * patches/params-cast-size_t.patch, + * patches/print_lsb_release.patch, + * patches/update-bootclasspath.patch: + The hs19 patches moved above. + * acinclude.m4: + (AC_CHECK_WITH_HOTSPOT_BUILD): Default to original. 2010-10-19 Andrew John Hughes @@ -657,7 +855,6 @@ 2010-10-19 Andrew John Hughes + + * patches/icedtea-awt-window-size.patch, + * patches/openjdk/6969395-net_bugs.patch, + * patches/openjdk/6985992-test_6933784.patch: + Dropped; upstreamed. + * Makefile.am: Remove above patches. 2010-09-23 Andrew John Hughes @@ -1259,6 +1464,15 @@ 2010-09-07 Andrew John Hughes + + * patches/openjdk/6438179-systray_check.patch: + Dropped, applied upstream. + * Makefile.am: Drop above patch and those brought + back by merge. Update JAXP tarball. + * patches/openjdk/6951319-sparc_build_fixes.patch: + Remove upstreamed parts. + 2010-09-03 Pavel Tisnovsky * Makefile.am: Fixed indentation, changes spaces to tab. @@ -1308,7 +1522,7 @@ 2010-08-27 Deepak Bhole - * Makefile.am: + * Makefile.am: Add patch. * patches/opengl-jni-fix.patch: Fixed missing JNI link to native function OGLContext.getOGLIdString() which causes @@ -1395,6 +1609,22 @@ 2010-08-13 Andrew John Hughes + + * patches/openjdk/4356282-opentype.patch, + * patches/openjdk/6795060-icu_crash.patch, + * patches/openjdk/6954424-opentype_javadoc.patch: + Dropped, applied upstream. + * Makefile.am: + Remove above patches. + +2010-08-12 Andrew John Hughes + + * patches/openjdk/6678385-window_movement_crasher.patch: + Dropped, applied upstream. + * Makefile.am: + Remove above patch. 2010-08-09 Omair Majid @@ -1436,7 +1666,7 @@ 2010-08-09 Deepak Bhole @@ -1748,6 +1978,12 @@ 2010-07-28 Matthias Klose * NEWS: Add 1.8.1 entry. + +2010-07-26 Andrew John Hughes + + * patches/icedtea-jtreg-jrunscript.patch: + Regenerate after 50002bfcff96 from dcubed being + added to OpenJDK6. 2010-07-26 Andrew John Hughes @@ -2197,6 +2433,12 @@ 2010-07-08 Andrew John Hughes + + * patches/openjdk/6961732.patch: + Dropped, applied upstream. + * Makefile.am: Remove above patch. 2010-07-06 Andrew John Hughes @@ -10490,7 +10732,7 @@ 2009-04-07 Omair Majid - * patches/icedtea-jtreg-jrunscript.patch: New patch. Replaces + * patches/icedtea-jtreg-jrunscript.patch: New patch. Replaces jrunscriptTest.sh with a java version that isnt picky about int vs double changes. * Makefile.am (ICEDTEA_PATCHES): Apply the above. diff -r fd09f4a3b767 -r 6ce6dfbaebe5 Makefile.am --- a/Makefile.am Sun Jan 09 00:43:01 2011 +0000 +++ b/Makefile.am Sat Jan 22 03:48:53 2011 +0000 @@ -1,8 +1,8 @@ # Dependencies -OPENJDK_DATE = 21_jun_2010 -OPENJDK_MD5SUM = 0b36adbf67e4f261e1b827ed4be4f447 -OPENJDK_VERSION = b20 +OPENJDK_DATE = 20_jan_2011 +OPENJDK_MD5SUM = 595125cd17441122074a4fe0f78c0252 +OPENJDK_VERSION = b22 OPENJDK_URL = http://download.java.net/openjdk/jdk6/promoted/$(OPENJDK_VERSION)/ CACAO_VERSION = 6a5eda011e49 @@ -18,8 +18,8 @@ JAF_DROP_ZIP = jdk6-jaf-b20.zip JAF_DROP_ZIP = jdk6-jaf-b20.zip JAF_DROP_SHA256SUM = 78c7b5c9d6271e88ee46abadd018a61f1e9645f8936cc8df1617e5f4f5074012 JAXP_DROP_URL = http://icedtea.classpath.org/download/drops -JAXP_DROP_ZIP = jdk6-jaxp-b20.zip -JAXP_DROP_SHA256SUM = d097627d4059d488c5a09d4e33cec275a193d4d8bc0fea8ef4f1337170904156 +JAXP_DROP_ZIP = jaxp-1_4_4.zip +JAXP_DROP_SHA256SUM = 10b203bec5b7d3dd8f515a9e098f80abc316faf977bcc220b56efe3dc6e9e5e9 OPENJDK_HG_URL = http://hg.openjdk.java.net/jdk6/jdk6 @@ -174,27 +174,7 @@ REWRITER_SRCS = $(abs_top_srcdir)/rewrit ICEDTEA_FSG_PATCHES = -BROKEN = - -SECURITY_PATCHES = \ - patches/security/20101012/6891766.patch \ - patches/security/20101012/6925710.patch \ - patches/security/20101012/6938813.patch \ - patches/security/20101012/6957564.patch \ - patches/security/20101012/6958060.patch \ - patches/security/20101012/6963023.patch \ - patches/security/20101012/6963489.patch \ - patches/security/20101012/6966692.patch \ - patches/security/20101012/6914943.patch \ - patches/security/20101012/6559775.patch \ - patches/security/20101012/6622002.patch \ - patches/security/20101012/6623943.patch \ - patches/security/20101012/6952017.patch \ - patches/security/20101012/6952603.patch \ - patches/security/20101012/6961084.patch \ - patches/security/20101012/6963285.patch \ - patches/security/20101012/6981426.patch \ - patches/security/20101012/6990437.patch +SECURITY_PATCHES = ICEDTEA_PATCHES = \ $(SECURITY_PATCHES) \ @@ -211,7 +191,7 @@ ICEDTEA_PATCHES = \ patches/icedtea-headers.patch \ patches/icedtea-headers-hotspot.patch \ patches/icedtea-gcc-suffix.patch \ - patches/hotspot/$(HSBUILD)/gcc-suffix.patch \ + patches/gcc-suffix.patch \ patches/icedtea-bytebuffer-compact.patch \ patches/memory-limits.patch \ patches/icedtea-sunsrc.patch \ @@ -219,18 +199,18 @@ ICEDTEA_PATCHES = \ patches/icedtea-javafiles.patch \ patches/icedtea-jvmtiEnv.patch \ patches/icedtea-lcms.patch \ - patches/hotspot/$(HSBUILD)/print_lsb_release.patch \ + patches/print_lsb_release.patch \ patches/icedtea-jpegclasses.patch \ patches/icedtea-uname.patch \ patches/icedtea-freetypeversion.patch \ patches/icedtea-nomotif-6706121.patch \ patches/icedtea-nomotif.patch \ patches/icedtea-nomotif-mtoolkit.patch \ - patches/hotspot/$(HSBUILD)/alpha-fixes.patch \ + patches/alpha-fixes.patch \ patches/icedtea-alt-jar.patch \ patches/icedtea-jdk-use-ssize_t.patch \ patches/icedtea-use-idx_t.patch \ - patches/hotspot/$(HSBUILD)/params-cast-size_t.patch \ + patches/params-cast-size_t.patch \ patches/icedtea-clean-crypto.patch \ patches/icedtea-arch.patch \ patches/icedtea-lc_ctype.patch \ @@ -246,7 +226,6 @@ ICEDTEA_PATCHES = \ patches/icedtea-sparc-ptracefix.patch \ patches/icedtea-sparc-trapsfix.patch \ patches/icedtea-demo-swingapplet.patch \ - patches/openjdk/6721088-awt_window_size.patch \ patches/icedtea-jtreg-6592792.patch \ patches/icedtea-s390-noinline.patch \ patches/icedtea-jtreg-dnd.patch \ @@ -262,78 +241,40 @@ ICEDTEA_PATCHES = \ patches/icedtea-parisc.patch \ patches/icedtea-sh4-support.patch \ patches/icedtea-policy-evaluation.patch \ - patches/hotspot/$(HSBUILD)/update-bootclasspath.patch \ + patches/update-bootclasspath.patch \ patches/libpng.patch \ patches/applet_hole.patch \ patches/icedtea-jtreg-httpTest.patch \ patches/arm.patch \ - patches/openjdk/6678385-window_movement_crasher.patch \ - patches/openjdk/6961732-negative_leading.patch \ patches/debug-dir.patch \ patches/no-sync.patch \ patches/icedtea-override-redirect-metacity.patch \ - patches/openjdk/6963870-swing_npe.patch \ - patches/openjdk/6668231-ssl_cert.patch \ patches/openjdk/6967533-pre_epoch.patch \ patches/fonts-rhel.patch \ patches/fonts-gentoo.patch \ patches/ipv4-mapped-ipv6-addresses.patch \ - patches/openjdk/6795060-icu_crash.patch \ - patches/openjdk/4356282-opentype.patch \ - patches/openjdk/6954424-opentype_javadoc.patch \ - patches/openjdk/6438179-systray_check.patch \ patches/icedtea-too-many-args.patch \ patches/icedtea-jtreg-OpenGLContextInit.patch \ - patches/openjdk/6969395-net_bugs.patch \ patches/openjdk/6510892-httpserver_test.patch \ patches/openjdk/6638712-wildcard_types.patch \ patches/openjdk/6650759-missing_inference.patch \ patches/numa_on_early_glibc.patch \ - patches/icedtea-shark-build.patch \ - patches/openjdk/6985992-test_6933784.patch \ - patches/openjdk/6853592-badwindow-warning-fix.patch \ - patches/6703377-freetypescaler.patch \ patches/icedtea-jtreg-international-fonts.patch \ patches/openjdk/6967436-6976265-6967434-pisces.patch \ patches/openjdk/6997495-test_correction_6857159.patch \ - patches/openjdk/6622432-bigdecimal_performance.patch \ - patches/openjdk/6850606-bigdecimal_regression.patch \ - patches/openjdk/6876282-bigdecimal_divide.patch \ patches/f14-fonts.patch \ - patches/jtreg-DeleteFont.patch \ patches/jtreg-WindowWithWarningTest.patch \ patches/jtreg-T6638712-fix.patch \ - patches/openjdk/7002666-eclipse_cdt_oops_crash.patch \ patches/jtreg-T6650759m-fix.patch \ patches/openjdk/7003777-bad-html-entity-parse.patch \ - patches/openjdk/6941936-broken-pipe.patch \ - patches/openjdk/6943219-failure-in-linux.patch \ - patches/openjdk/6979979-gtk_font_size_rounding.patch \ - patches/openjdk/6795356-proxylazyvalue-leak.patch \ + patches/jtreg-6929067-fix.patch \ patches/rendering-engine-tests.patch \ - patches/openjdk/6560348-jtreg-TestXEmbedServer-fix.patch \ patches/openjdk/6800846-printing-quality.patch \ - patches/openjdk/6687968-pngimagereader_mem_leak.patch \ - patches/openjdk/6541476-png-iTXt-chunk.patch \ - patches/openjdk/6782079-png_metadata_oom.patch \ - patches/661505-jpeg.patch - From bugzilla-daemon at icedtea.classpath.org Sat Jan 22 01:49:03 2011 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Sat, 22 Jan 2011 09:49:03 +0000 Subject: [Bug 528] Crash with nvidia and xorg opengl when running netbeans Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=528 follettoonip at gmail.com changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |follettoonip at gmail.com ------- Comment #9 from follettoonip at gmail.com 2011-01-22 09:49 ------- I'm on gentoo too. with nvidia opengl implementation, icedtea as jvm and cairo-1.8.10 it used to work. since I've upgraded cairo for gnome-2.32 either I use oracle's jdk or use xorg-x11 opengl implementation. Even icedtea7 gives the same problem If oracle one is working shouldn't this be an openjdk issue? -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From mark at klomp.org Sat Jan 22 11:52:49 2011 From: mark at klomp.org (Mark Wielaard) Date: Sat, 22 Jan 2011 20:52:49 +0100 (CET) Subject: FYI: Fix for missing backslash in ICEDTEA_PATCHES list Message-ID: <54017.80.101.103.228.1295725969.squirrel@gnu.wildebeest.org> Hi, I am checking this in, it fixes an obvious missing backslash, preventing some patches from getting applied. 2010-01-22 Mark Wielaard * Makefile.am (ICEDTEA_PATCHES): Add missing backslash. Cheers, Mark diff -r 743a3ac9f201 -r d850506bcaac Makefile.am --- a/Makefile.am Sat Jan 22 02:32:01 2011 +0000 +++ b/Makefile.am Sat Jan 22 20:39:36 2011 +0100 @@ -272,7 +272,7 @@ patches/openjdk/6800846-printing-quality.patch \ patches/661505-jpeg.patch \ patches/6703377-freetypescaler.patch \ - patches/ia64-fix.patch + patches/ia64-fix.patch \ patches/openjdk/6642612-filechooser_button_sizes.patch \ patches/jtreg-international-fonts-styles.patch From mjw at icedtea.classpath.org Sat Jan 22 11:55:58 2011 From: mjw at icedtea.classpath.org (mjw at icedtea.classpath.org) Date: Sat, 22 Jan 2011 19:55:58 +0000 Subject: /hg/icedtea6: * Makefile.am (ICEDTEA_PATCHES): Add missing backs... Message-ID: changeset d850506bcaac in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=d850506bcaac author: Mark Wielaard date: Sat Jan 22 20:39:36 2011 +0100 * Makefile.am (ICEDTEA_PATCHES): Add missing backslash. diffstat: 2 files changed, 5 insertions(+), 1 deletion(-) ChangeLog | 4 ++++ Makefile.am | 2 +- diffs (23 lines): diff -r 743a3ac9f201 -r d850506bcaac ChangeLog --- a/ChangeLog Sat Jan 22 02:32:01 2011 +0000 +++ b/ChangeLog Sat Jan 22 20:39:36 2011 +0100 @@ -1,3 +1,7 @@ 2011-01-22 Andrew John Hughes + + * Makefile.am (ICEDTEA_PATCHES): Add missing backslash. + 2011-01-22 Andrew John Hughes * Makefile.am: diff -r 743a3ac9f201 -r d850506bcaac Makefile.am --- a/Makefile.am Sat Jan 22 02:32:01 2011 +0000 +++ b/Makefile.am Sat Jan 22 20:39:36 2011 +0100 @@ -272,7 +272,7 @@ ICEDTEA_PATCHES = \ patches/openjdk/6800846-printing-quality.patch \ patches/661505-jpeg.patch \ patches/6703377-freetypescaler.patch \ - patches/ia64-fix.patch + patches/ia64-fix.patch \ patches/openjdk/6642612-filechooser_button_sizes.patch \ patches/jtreg-international-fonts-styles.patch From mark at klomp.org Sat Jan 22 13:14:00 2011 From: mark at klomp.org (Mark Wielaard) Date: Sat, 22 Jan 2011 22:14:00 +0100 (CET) Subject: FYI use run-xvfb for tests if no display set Message-ID: <41195.80.101.103.228.1295730840.squirrel@gnu.wildebeest.org> Hi, This patch makes it so that if DISPLAY isn't set and configure detected run-xvfb is installed the make check-jdk tests are run under run-xvfb. This will make it so that on autobuilders the gui tests will run "normally" even when they don't have any display as long as they have Xvfb server installed. Nothing changes for normal setups if DISPLAY is set, or run-xvfb isn't installed. 2010-01-22 Mark Wielaard * configure.ac: Add xvfb-run AC_CHECK_PROG. * Makefile.am (check-jdk): Use xvfb-run if available and DISPLAY not set. I'll commit this in icedtea6 and icedtea[7]. Cheers, Mark -------------- next part -------------- A non-text attachment was scrubbed... Name: xvfb.patch Type: text/x-diff Size: 1085 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110122/1854c87a/xvfb.patch From mjw at icedtea.classpath.org Sat Jan 22 13:19:24 2011 From: mjw at icedtea.classpath.org (mjw at icedtea.classpath.org) Date: Sat, 22 Jan 2011 21:19:24 +0000 Subject: /hg/icedtea6: Use xvfb-run if available and DISPLAY not set for ... Message-ID: changeset 6633b7a3a5db in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=6633b7a3a5db author: Mark Wielaard date: Sat Jan 22 21:47:34 2011 +0100 Use xvfb-run if available and DISPLAY not set for check-jdk. * configure.ac: Add xvfb-run AC_CHECK_PROG. * Makefile.am (check-jdk): Use xvfb-run if available and DISPLAY not set. diffstat: 3 files changed, 15 insertions(+) ChangeLog | 6 ++++++ Makefile.am | 5 +++++ configure.ac | 4 ++++ diffs (42 lines): diff -r d850506bcaac -r 6633b7a3a5db ChangeLog --- a/ChangeLog Sat Jan 22 20:39:36 2011 +0100 +++ b/ChangeLog Sat Jan 22 21:47:34 2011 +0100 @@ -1,3 +1,9 @@ 2010-01-22 Mark Wielaard + + * configure.ac: Add xvfb-run AC_CHECK_PROG. + * Makefile.am (check-jdk): Use xvfb-run if available and DISPLAY + not set. + 2010-01-22 Mark Wielaard * Makefile.am (ICEDTEA_PATCHES): Add missing backslash. diff -r d850506bcaac -r 6633b7a3a5db Makefile.am --- a/Makefile.am Sat Jan 22 20:39:36 2011 +0100 +++ b/Makefile.am Sat Jan 22 21:47:34 2011 +0100 @@ -1898,6 +1898,11 @@ check-langtools: stamps/jtreg.stamp check-jdk: stamps/jtreg.stamp mkdir -p test/jdk/JTwork test/jdk/JTreport + if test "x$${DISPLAY}" = "x"; then XVFB_RUN="@XVFB_RUN_CMD@"; fi; \ + if test "x$${DISPLAY}" = "x" && test "x$${XVFB_RUN}" = "x"; then \ + echo "WARNING: DISPLAY not set and xvfb-run not found"; \ + fi; \ + $${XVFB_RUN} \ $(BOOT_DIR)/bin/java -jar test/jtreg.jar -v1 -a -ignore:quiet \ -w:test/jdk/JTwork -r:test/jdk/JTreport \ $${ICEDTEA_JTREG_OTHERVM:--samevm} \ diff -r d850506bcaac -r 6633b7a3a5db configure.ac --- a/configure.ac Sat Jan 22 20:39:36 2011 +0100 +++ b/configure.ac Sat Jan 22 21:47:34 2011 +0100 @@ -52,6 +52,10 @@ IT_CP_SUPPORTS_REFLINK IT_CP_SUPPORTS_REFLINK IT_CAN_HARDLINK_TO_SOURCE_TREE IT_CHECK_FOR_PAX + +# Use xvfb-run if found to run gui tests (check-jdk). +AC_CHECK_PROG(XVFB_RUN_CMD, xvfb-run, [xvfb-run -a -e xvfb-errors], []) +AC_SUBST(XVFB_RUN_CMD) AC_MSG_CHECKING([for an Ant home directory]) AC_ARG_WITH([ant-home], From mjw at icedtea.classpath.org Sat Jan 22 13:20:24 2011 From: mjw at icedtea.classpath.org (mjw at icedtea.classpath.org) Date: Sat, 22 Jan 2011 21:20:24 +0000 Subject: /hg/icedtea: Use xvfb-run if available and DISPLAY not set for c... Message-ID: changeset 5cdaab119e8a in /hg/icedtea details: http://icedtea.classpath.org/hg/icedtea?cmd=changeset;node=5cdaab119e8a author: Mark Wielaard date: Sat Jan 22 21:47:34 2011 +0100 Use xvfb-run if available and DISPLAY not set for check-jdk. * configure.ac: Add xvfb-run AC_CHECK_PROG. * Makefile.am (check-jdk): Use xvfb-run if available and DISPLAY not set. diffstat: 3 files changed, 15 insertions(+) ChangeLog | 6 ++++++ Makefile.am | 5 +++++ configure.ac | 4 ++++ diffs (42 lines): diff -r ce49b3019799 -r 5cdaab119e8a ChangeLog --- a/ChangeLog Fri Jan 21 22:53:33 2011 +0100 +++ b/ChangeLog Sat Jan 22 21:47:34 2011 +0100 @@ -1,3 +1,9 @@ 2011-01-21 Mark Wielaard + + * configure.ac: Add xvfb-run AC_CHECK_PROG. + * Makefile.am (check-jdk): Use xvfb-run if available and DISPLAY + not set. + 2011-01-21 Mark Wielaard * configure.ac (--with-llvm-config): Handle yes/no. diff -r ce49b3019799 -r 5cdaab119e8a Makefile.am --- a/Makefile.am Fri Jan 21 22:53:33 2011 +0100 +++ b/Makefile.am Sat Jan 22 21:47:34 2011 +0100 @@ -2216,6 +2216,11 @@ if WITH_CACAO if WITH_CACAO CACAO_EXCLUDE="-exclude:$(abs_top_srcdir)/test/jtreg/excludelist.jdk.cacao.jtx" endif + if test "x$${DISPLAY}" = "x"; then XVFB_RUN="@XVFB_RUN_CMD@"; fi; \ + if test "x$${DISPLAY}" = "x" && test "x$${XVFB_RUN}" = "x"; then \ + echo "WARNING: DISPLAY not set and xvfb-run not found"; \ + fi; \ + $${XVFB_RUN} \ $(BOOT_DIR)/bin/java -jar test/jtreg.jar -v1 -a -ignore:quiet \ -w:test/jdk/JTwork -r:test/jdk/JTreport \ $${ICEDTEA_JTREG_OTHERVM:--samevm} \ diff -r ce49b3019799 -r 5cdaab119e8a configure.ac --- a/configure.ac Fri Jan 21 22:53:33 2011 +0100 +++ b/configure.ac Sat Jan 22 21:47:34 2011 +0100 @@ -54,6 +54,10 @@ IT_DISABLE_HOTSPOT_TESTS IT_DISABLE_HOTSPOT_TESTS IT_DISABLE_LANGTOOLS_TESTS IT_DISABLE_JDK_TESTS + +# Use xvfb-run if found to run gui tests (check-jdk). +AC_CHECK_PROG(XVFB_RUN_CMD, xvfb-run, [xvfb-run -a -e xvfb-errors], []) +AC_SUBST(XVFB_RUN_CMD) AC_MSG_CHECKING([whether to build the browser plugin]) AC_ARG_ENABLE([plugin], From ahughes at redhat.com Sun Jan 23 12:16:38 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Sun, 23 Jan 2011 20:16:38 +0000 Subject: b21 supported, 1.10 branching soon Message-ID: <20110123201638.GH21893@rivendell.middle-earth.co.uk> I updated IcedTea6 from icedtea6-hg on Friday to support the newly released b21 tarball. Before branching, I'd like to add the backports of: changeset: 462:549dfa49e693 user: anthony date: Thu Mar 20 11:09:16 2008 +0300 summary: 4993545: NativeInLightFixer adds asynchronousity changeset: 463:3abc86f5cab7 user: anthony date: Tue Mar 18 14:20:28 2008 +0300 summary: 6637796: setBounds doesn't enlarge Component changeset: 464:3a891fe451fe user: anthony date: Tue Mar 18 14:10:28 2008 +0300 summary: 6607660: java.awt.Container.getMouseEventTargetImpl should be invoked while holding the TreeLock changeset: 465:738bb9ec85cd user: ant date: Tue Apr 08 13:32:30 2008 +0400 summary: 6607170: Focus not set by requestFocus changeset: 466:721c0fb7ec7a user: dav date: Sat Dec 11 00:46:32 2010 +0000 summary: 6616323: consider benefits of replacing a component array with other collection from the awt.Container class changeset: 467:5ac3f07670e4 user: anthony date: Sat Dec 11 00:50:54 2010 +0000 summary: 6682046: Mixing code does not always recalculate shapes correctly when resizing components changeset: 469:060a22749a35 user: anthony date: Wed Feb 04 11:58:13 2009 +0300 summary: 6797195: Forward-port enhancements for hw/lw mixing from 6u12 to 7 changeset: 470:c0c42b7626ef user: tdv date: Tue Jan 11 19:06:38 2011 +0000 summary: 6725214: D3D: forward-port the new pipeline from 6u10 changeset: 471:2c0f0d20739e user: art date: Mon Jan 17 20:08:26 2011 +0000 summary: 6633275: Need to support shaped/translucent windows changeset: 472:6edb34496a04 user: anthony date: Wed Jan 19 23:49:10 2011 +0000 summary: 6693253: Security Warning appearance requires enhancements changeset: 473:38ce98051b78 tag: tip user: andrew date: Tue Dec 14 13:51:07 2010 +0000 summary: 6444769: java/awt/Insets/WindowWithWarningTest/WindowWithWarningTest.html fails I've been working on, as discussed in the thread http://mail.openjdk.java.net/pipermail/jdk6-dev/2010-December/002126.html [Note that 6725214 is already done, and will just be rejigged to work with these new backports] I then plan to do the rename needed to drop the useless 'icedtea-' prefix from patches as mentioned a few times, then create the 1.10 branch. Is there anything else anyone has planned for 1.10? Speak now. Current news looks like this: * Upgrade to HotSpot 19 as default. * NetX and the plugin moved to the IcedTea-Web project with a separate release cycle. * Shark provided upstream rather than as part of IcedTea. * The option --with-openjdk becomes --with-jdk-home and --disable-bootstrap * Backports - S4356282, RH525870: RFE: T2K should be used to rasterize CID/CFF fonts - S6954424: Support OpenType/CFF fonts in JDK 7 - S6438179: XToolkit.isTraySupported() result has nothing to do with the system tray - S6638712: Inference with wildcard types causes selection of inapplicable method - S6650759: Inference of formal type parameter (unused in formal parameters) is not performed - S6991430, PR579: Zero PowerPC fix. - S6967436, RH597227: lines longer than 2^15 can fill window. - S6967433: dashed lines broken when using scaling transforms. - S6976265: No STROKE_CONTROL - S6967434, PR450, RH530642: Round joins/caps of scaled up lines have poor quality. - S7002666: Eclipse CDT projects crash with compressed oops - S6979979, RH508185: Rounding error in font sizes selected by the GTK Look and Feel - S6795356: Leak caused by javax.swing.UIDefaults.ProxyLazyValue.acc - S6800846, RH662230: Printing quality degraded with Java 6 compared to 5.0, index out of bounds exception. - S6687968: PNGImageReader leaks native memory through an Inflater - S6541476, RH665355: PNG imageio plugin incorrectly handles iTXt chunk - S6782079: PNG: reading metadata may cause OOM on truncated images - RH661505: JPEGs with sRGB IEC61966-2.1 color profiles have wrong colors - S6642612: JFileChooser's approve buttons should be the same size (GTK) * Bug fixes - S7003777, RH647674: JTextPane produces incorrect content after parsing the html text - S7004655, PR590: Unable to activate (click) checkboxes in jtable - RH647157,RH582455: Update fontconfig files for rhel 6 and I'll merge in the b21 additions (http://blogs.sun.com/darcy/resource/OpenJDK_6/openjdk6-b21-changes-summary.html) on Monday. [The current NEWS file lists security updates which have already gone out, and the list above also probably includes some. I'll do a check on Monday]. Thanks, -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at icedtea.classpath.org Mon Jan 24 07:14:36 2011 From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org) Date: Mon, 24 Jan 2011 15:14:36 +0000 Subject: /hg/release/icedtea-web-1.0: Update NEWS format Message-ID: changeset a1ed62aa5f98 in /hg/release/icedtea-web-1.0 details: http://icedtea.classpath.org/hg/release/icedtea-web-1.0?cmd=changeset;node=a1ed62aa5f98 author: Omair Majid date: Mon Jan 24 10:13:01 2011 -0500 Update NEWS format 2011-01-24 Omair Majid * NEWS: Change format again. diffstat: 2 files changed, 29 insertions(+), 23 deletions(-) ChangeLog | 4 ++++ NEWS | 48 +++++++++++++++++++++++++----------------------- diffs (73 lines): diff -r bafc58e4df46 -r a1ed62aa5f98 ChangeLog --- a/ChangeLog Thu Jan 20 12:09:09 2011 -0500 +++ b/ChangeLog Mon Jan 24 10:13:01 2011 -0500 @@ -1,3 +1,7 @@ 2011-01-20 Omair Majid + + * NEWS: Change format again. + 2011-01-20 Omair Majid * NEWS: Change to a new format to emphasize new features as well as diff -r bafc58e4df46 -r a1ed62aa5f98 NEWS --- a/NEWS Thu Jan 20 12:09:09 2011 -0500 +++ b/NEWS Mon Jan 24 10:13:01 2011 -0500 @@ -8,7 +8,7 @@ GX - http://bugs.gentoo.org/show_bug.cg CVE-XXXX-YYYY: http://www.cve.mitre.org/cgi-bin/cvename.cgi?name=XXXX-YYYY -New in release 1.0 (2010-XX-XX): +New in release 1.0 (2011-XX-XX): * Initial release of IcedTea-Web * Security updates @@ -21,25 +21,27 @@ New in release 1.0 (2010-XX-XX): - Static proxies are now supported using the deployment.properties file - User prompts can now be configured using the deployment.properties - Applications and applets can now have a Look and Feel different from rest of IcedTea-Web -* Minor improvements and fixes - - common: Clean up native directories on exit - - common: Cached files with special characters in filenames are now handled correctly - - common: Interfaces javax.jnlp.IntegrationService and javax.jnlp.DownloadService2 are now available - - javaws: PR592: NetX can create invalid desktop entry files - - javaws: Add a new option -Xclearcache - - javaws: Removed option -umask - - javaws: Applications with non-public main classes are now supported. - - javaws: JNLP files containing as well as will now work - - javaws: The javaws.desktop file now points explicitly to NetX's javaws binary - - plugin: PR542: Plugin fails with NPE on http://www.openprocessing.org/visuals/iframe.php?visualID=2615 - - plugin: PR552: Support for FreeBSD's pthread implementation - - plugin: PR554: System.err writes content two times - - plugin: PR556: Applet initialization code is prone to race conditions - - plugin: PR557: Applet opens in a separate window if tab is closed when the applet loads - - plugin: PR565: UIDefaults.getUI fails with jgoodies:looks 2.3.1 - - plugin: PR593: Increment of invalidated iterator in IcedTeaPluginUtils (patch from barbara.xxx1975 at libero.it) - - plugin: PR597: Entities are parsed incorrectly in PARAM tag in applet plugin - - plugin: PR619: Improper finalization by the plugin can crash the browser - - plugin: RH665104: OpenJDK Firefox Java plugin loses a cookie - - plugin: JNLP files referenced in the applet tag are now parsed to detect applet properties - - plugin: Applets are now double-buffered to eliminate flicker in ones that do heavy drawing +* Common improvements and fixes + - Clean up native directories on exit + - Cached files with special characters in filenames are now handled correctly + - Interfaces javax.jnlp.IntegrationService and javax.jnlp.DownloadService2 are now available +* Javaws improvments and fixes + - PR592: NetX can create invalid desktop entry files + - Add a new option -Xclearcache + - Removed option -umask + - Applications with non-public main classes are now supported. + - JNLP files containing as well as will now work + - The javaws.desktop file now points explicitly to NetX's javaws binary +* Plugin improvements and fixes + - PR542: Plugin fails with NPE on http://www.openprocessing.org/visuals/iframe.php?visualID=2615 + - PR552: Support for FreeBSD's pthread implementation + - PR554: System.err writes content two times + - PR556: Applet initialization code is prone to race conditions + - PR557: Applet opens in a separate window if tab is closed when the applet loads + - PR565: UIDefaults.getUI fails with jgoodies:looks 2.3.1 + - PR593: Increment of invalidated iterator in IcedTeaPluginUtils (patch from barbara.xxx1975 at libero.it) + - PR597: Entities are parsed incorrectly in PARAM tag in applet plugin + - PR619: Improper finalization by the plugin can crash the browser + - RH665104: OpenJDK Firefox Java plugin loses a cookie + - JNLP files referenced in the applet tag are now parsed to detect applet properties + - Applets are now double-buffered to eliminate flicker in ones that do heavy drawing From omajid at redhat.com Mon Jan 24 07:15:24 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 24 Jan 2011 10:15:24 -0500 Subject: [icedtea-web] RFC: Update NEWS file In-Reply-To: <20110121160002.GF13935@rivendell.middle-earth.co.uk> References: <4CF7BCE0.8080800@redhat.com> <20110120163325.GB18293@redhat.com> <20110121003829.GF4611@rivendell.middle-earth.co.uk> <4D39A269.5090104@redhat.com> <20110121160002.GF13935@rivendell.middle-earth.co.uk> Message-ID: <4D3D978C.7000806@redhat.com> On 01/21/2011 11:00 AM, Dr Andrew John Hughes wrote: >>> Please don't apply as is. >>> >> I pushed the changeset before I saw this response. If you like, I can >> rollback. >> >>> The common, javaws and plugin headers look ugly and will break the NEWS generation I do for release. >>> Please use: >>> >>> * Common Minor Improvements and Fixes >>> * Java Web Start Minor Improvements and Fixes >>> * Plugin Minor Improvements and Fixes >>> >>> as headers instead. >> >> I will do that in a new commit. Sorry about the mess :( >> > > Yes, just apply the changes to fix that section. Thanks. > Done Cheers, Omair From omajid at icedtea.classpath.org Mon Jan 24 07:21:32 2011 From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org) Date: Mon, 24 Jan 2011 15:21:32 +0000 Subject: /hg/icedtea-web: When exiting on failure, use appropriate exit code Message-ID: changeset 804cd535d907 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=804cd535d907 author: Omair Majid date: Mon Jan 24 10:20:57 2011 -0500 When exiting on failure, use appropriate exit code 2011-01-24 Omair Majid * netx/net/sourceforge/jnlp/Launcher.java: Exit with error code * netx/net/sourceforge/jnlp/NetxPanel.java: Likewise. diffstat: 3 files changed, 7 insertions(+), 2 deletions(-) ChangeLog | 5 +++++ netx/net/sourceforge/jnlp/Launcher.java | 2 +- netx/net/sourceforge/jnlp/NetxPanel.java | 2 +- diffs (36 lines): diff -r a9e67985cb7a -r 804cd535d907 ChangeLog --- a/ChangeLog Fri Jan 21 16:42:18 2011 -0500 +++ b/ChangeLog Mon Jan 24 10:20:57 2011 -0500 @@ -1,3 +1,8 @@ 2011-01-20 Andrew Su +2011-01-24 Omair Majid + + * netx/net/sourceforge/jnlp/Launcher.java: Exit with error code + * netx/net/sourceforge/jnlp/NetxPanel.java: Likewise. + 2011-01-20 Andrew Su * netx/net/sourceforge/jnlp/AppletLog.java: Restrict log files to diff -r a9e67985cb7a -r 804cd535d907 netx/net/sourceforge/jnlp/Launcher.java --- a/netx/net/sourceforge/jnlp/Launcher.java Fri Jan 21 16:42:18 2011 -0500 +++ b/netx/net/sourceforge/jnlp/Launcher.java Mon Jan 24 10:20:57 2011 -0500 @@ -834,7 +834,7 @@ public class Launcher { exception = ex; // Exit if we can't launch the application. if (exitOnFailure) - System.exit(0); + System.exit(1); } } diff -r a9e67985cb7a -r 804cd535d907 netx/net/sourceforge/jnlp/NetxPanel.java --- a/netx/net/sourceforge/jnlp/NetxPanel.java Fri Jan 21 16:42:18 2011 -0500 +++ b/netx/net/sourceforge/jnlp/NetxPanel.java Mon Jan 24 10:20:57 2011 -0500 @@ -104,7 +104,7 @@ public class NetxPanel extends AppletVie // Assume user has indicated he does not trust the // applet. if (exitOnFailure) - System.exit(0); + System.exit(1); } applet = appInst.getApplet(); From omajid at redhat.com Mon Jan 24 07:22:27 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 24 Jan 2011 10:22:27 -0500 Subject: [icedtea-web] RFC: exit with error code on failures In-Reply-To: <20110119210520.GB16826@rivendell.middle-earth.co.uk> References: <4D375059.4060501@redhat.com> <20110119210520.GB16826@rivendell.middle-earth.co.uk> Message-ID: <4D3D9933.4030906@redhat.com> On 01/19/2011 04:05 PM, Dr Andrew John Hughes wrote: > On 15:58 Wed 19 Jan , Omair Majid wrote: >> The attached patch makes netx (and plugin) exit with an error code other >> than 0 on an error. netx already exits with appropriate error code in >> some cases (for example, if the input JNLP file is malformed), but not >> if running the downloaded program fails. > > Sounds good to me. > Thanks for the review. I have pushed it to head. Cheers, Omair From doko at ubuntu.com Mon Jan 24 07:47:44 2011 From: doko at ubuntu.com (Matthias Klose) Date: Mon, 24 Jan 2011 16:47:44 +0100 Subject: FYI use run-xvfb for tests if no display set In-Reply-To: <41195.80.101.103.228.1295730840.squirrel@gnu.wildebeest.org> References: <41195.80.101.103.228.1295730840.squirrel@gnu.wildebeest.org> Message-ID: <4D3D9F20.4010807@ubuntu.com> On 22.01.2011 22:14, Mark Wielaard wrote: > Hi, > > This patch makes it so that if DISPLAY isn't set and configure > detected run-xvfb is installed the make check-jdk tests are run > under run-xvfb. This will make it so that on autobuilders the gui > tests will run "normally" even when they don't have any display > as long as they have Xvfb server installed. Nothing changes for > normal setups if DISPLAY is set, or run-xvfb isn't installed. > > 2010-01-22 Mark Wielaard > > * configure.ac: Add xvfb-run AC_CHECK_PROG. > * Makefile.am (check-jdk): Use xvfb-run if available and DISPLAY > not set. > > I'll commit this in icedtea6 and icedtea[7]. Please add a configure option to explicitly enable it. The reason is that I already run it, and starting it twice breaks it, and I do not want to use your version because it doesn't start a window manager which is needed for some tests. But starting a window manager is again "complicated". When using twm, you'll have to make sure that the placement of windows is automatic, when starting metacity, it might be necessary to start it with a dbus-session, and so on ... Not sure if you want to add all this to the configury. Matthias From mark at klomp.org Mon Jan 24 07:58:24 2011 From: mark at klomp.org (Mark Wielaard) Date: Mon, 24 Jan 2011 16:58:24 +0100 Subject: FYI use run-xvfb for tests if no display set In-Reply-To: <4D3D9F20.4010807@ubuntu.com> References: <41195.80.101.103.228.1295730840.squirrel@gnu.wildebeest.org> <4D3D9F20.4010807@ubuntu.com> Message-ID: <1295884704.2852.29.camel@springer.wildebeest.org> Hi Matthias, On Mon, 2011-01-24 at 16:47 +0100, Matthias Klose wrote: > On 22.01.2011 22:14, Mark Wielaard wrote: > > 2010-01-22 Mark Wielaard > > > > * configure.ac: Add xvfb-run AC_CHECK_PROG. > > * Makefile.am (check-jdk): Use xvfb-run if available and DISPLAY > > not set. > > > > I'll commit this in icedtea6 and icedtea[7]. > > Please add a configure option to explicitly enable it. The reason is that I > already run it, and starting it twice breaks it If you want to explicitly enable it you will have to unset DISPLAY. It shouldn't activate if you are already using xvfb-run since it checks to see if DISPLAY is set. Could you show me how it breaks in your setup? > and I do not want to use your > version because it doesn't start a window manager which is needed for some > tests. But starting a window manager is again "complicated". When using twm, > you'll have to make sure that the placement of windows is automatic, when > starting metacity, it might be necessary to start it with a dbus-session, and so > on ... Not sure if you want to add all this to the configury. Actually, that would be nice to have. Could you post an example of how you run it? Thanks, Mark From omajid at redhat.com Mon Jan 24 08:07:36 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 24 Jan 2011 11:07:36 -0500 Subject: [icedtea-web] RFC: add support in netx for using proxy settings from browser In-Reply-To: <4D151ED4.70102@redhat.com> References: <4D127CEB.9010508@redhat.com> <20101223004028.GM17229@rivendell.middle-earth.co.uk> <4D15033A.402@redhat.com> <4D151ED4.70102@redhat.com> Message-ID: <4D3DA3C8.7060104@redhat.com> On 12/24/2010 05:29 PM, Omair Majid wrote: > On 12/24/2010 03:31 PM, Omair Majid wrote: >> On 12/22/2010 07:40 PM, Dr Andrew John Hughes wrote: >>> On 17:34 Wed 22 Dec , Omair Majid wrote: >>>> Hi, >>>> >>>> The attached patch makes netx (not plugin) behave correctly (or at >>>> least >>>> slightly better) when deployment.proxy.type is set to 3 (for >>>> PROXY_TYPE_BROWSER). >>>> >>>> With this patch, netx will parse the firefox preferences file to figure >>>> out the browser's settings and use that when trying to figure out the >>>> proxy to use for accessing a given URI. >>>> >>> >>> I think there could be better handling if the profiles.ini does not >>> exist. >>> AFAICS, it would print out a stack trace. We should handle that much >>> more >>> gracefully. It's not really an exceptional event that the user hasn't >>> used Firefox before, but something we should account for. >>> >> Good point. I will post an updated patch to address this issue. >> > > This updated patch takes care of it. If the preferences file (or the > profiles file) do not exist (or are damaged), BROWSER_PROXY_TYPE_NONE is > assumed and the user is notified: > Unable to use Firefox's proxy settings. Using "DIRECT" as proxy type. > Ping. Any comments on the patch? Thanks, Omair From ahughes at redhat.com Mon Jan 24 09:21:48 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Mon, 24 Jan 2011 17:21:48 +0000 Subject: [icedtea-web] RFC: add support in netx for using proxy settings from browser In-Reply-To: <4D151ED4.70102@redhat.com> References: <4D127CEB.9010508@redhat.com> <20101223004028.GM17229@rivendell.middle-earth.co.uk> <4D15033A.402@redhat.com> <4D151ED4.70102@redhat.com> Message-ID: <20110124172148.GA17602@rivendell.middle-earth.co.uk> On 17:29 Fri 24 Dec , Omair Majid wrote: > On 12/24/2010 03:31 PM, Omair Majid wrote: > > On 12/22/2010 07:40 PM, Dr Andrew John Hughes wrote: > >> On 17:34 Wed 22 Dec , Omair Majid wrote: > >>> Hi, > >>> > >>> The attached patch makes netx (not plugin) behave correctly (or at least > >>> slightly better) when deployment.proxy.type is set to 3 (for > >>> PROXY_TYPE_BROWSER). > >>> > >>> With this patch, netx will parse the firefox preferences file to figure > >>> out the browser's settings and use that when trying to figure out the > >>> proxy to use for accessing a given URI. > >>> > >> > >> I think there could be better handling if the profiles.ini does not > >> exist. > >> AFAICS, it would print out a stack trace. We should handle that much more > >> gracefully. It's not really an exceptional event that the user hasn't > >> used Firefox before, but something we should account for. > >> > > Good point. I will post an updated patch to address this issue. > > > > This updated patch takes care of it. If the preferences file (or the > profiles file) do not exist (or are damaged), BROWSER_PROXY_TYPE_NONE is > assumed and the user is notified: > Unable to use Firefox's proxy settings. Using "DIRECT" as proxy type. > Ok. Further comments inline. > snip... > > Cheers, > Omair > diff -r 7ddab63cf8fe netx/net/sourceforge/jnlp/browser/BrowserAwareProxySelector.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/browser/BrowserAwareProxySelector.java Fri Dec 24 17:19:09 2010 -0500 > @@ -0,0 +1,229 @@ > +/* BrowserAwareProxySelector.java > + Copyright (C) 2010 Red Hat, Inc. > + > +This file is part of IcedTea. > + > +IcedTea is free software; you can redistribute it and/or > +modify it under the terms of the GNU General Public License as published by > +the Free Software Foundation, version 2. > + > +IcedTea is distributed in the hope that it will be useful, > +but WITHOUT ANY WARRANTY; without even the implied warranty of > +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > +General Public License for more details. > + > +You should have received a copy of the GNU General Public License > +along with IcedTea; see the file COPYING. If not, write to > +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA > +02110-1301 USA. > + > +Linking this library statically or dynamically with other modules is > +making a combined work based on this library. Thus, the terms and > +conditions of the GNU General Public License cover the whole > +combination. > + > +As a special exception, the copyright holders of this library give you > +permission to link this library with independent modules to produce an > +executable, regardless of the license terms of these independent > +modules, and to copy and distribute the resulting executable under > +terms of your choice, provided that you also meet, for each linked > +independent module, the terms and conditions of the license of that > +module. An independent module is a module which is not derived from > +or based on this library. If you modify this library, you may extend > +this exception to your version of the library, but you are not > +obligated to do so. If you do not wish to do so, delete this > +exception statement from your version. > +*/ > +package net.sourceforge.jnlp.browser; > + > +import static net.sourceforge.jnlp.runtime.Translator.R; > + > +import java.io.File; > +import java.io.IOException; > +import java.net.InetSocketAddress; > +import java.net.MalformedURLException; > +import java.net.Proxy; > +import java.net.SocketAddress; > +import java.net.URI; > +import java.net.URL; > +import java.net.Proxy.Type; > +import java.util.ArrayList; > +import java.util.Arrays; > +import java.util.List; > +import java.util.Map; > + > +import net.sourceforge.jnlp.runtime.JNLPProxySelector; > +import net.sourceforge.jnlp.runtime.JNLPRuntime; > + > +/** > + * A ProxySelector which can read proxy settings from a browser's > + * configuration and use that. > + * > + * @see JNLPProxySelector > + */ > +public class BrowserAwareProxySelector extends JNLPProxySelector { > + > + /* firefox's constants */ > + public static final int BROWSER_PROXY_TYPE_NONE = 0; > + public static final int BROWSER_PROXY_TYPE_NONE2 = 3; > + /** use gconf, WPAD and then env (and possibly others)*/ > + public static final int BROWSER_PROXY_TYPE_AUTO = 4; > + /** use env variables */ > + public static final int BROWSER_PROXY_TYPE_SYSTEM = 5; > + public static final int BROWSER_PROXY_TYPE_MANUAL = 1; > + public static final int BROWSER_PROXY_TYPE_PAC = 2; > + Is there a reason the integer values are out of order here? > + private int browserProxyType = BROWSER_PROXY_TYPE_NONE; > + private URL browserAutoConfigUrl; > + private Boolean browserUseSameProxy; > + private String browserHttpProxyHost; > + private int browserHttpProxyPort; > + private String browserHttpsProxyHost; > + private int browserHttpsProxyPort; > + private String browserFtpProxyHost; > + private int browserFtpProxyPort; > + private String browserSocks4ProxyHost; > + private int browserSocks4ProxyPort; > + > + /** > + * Create a new instance of this class, reading configuration fropm the browser > + */ > + public BrowserAwareProxySelector() { > + super(); > + initFromBrowserConfig(); > + } > + > + /** > + * Initialize configuration by reading preferences from the browser (firefox) > + */ > + private void initFromBrowserConfig() { > + > + try { > + File preferencesFile = FirefoxPreferencesFinder.find(); > + if (preferencesFile == null) { > + System.out.println(R("RProxyFirefoxNotFound")); > + browserProxyType = PROXY_TYPE_NONE; > + return; > + } Should the output not be to err rather than out (as in the method below)? > + FirefoxPreferencesParser parser = new FirefoxPreferencesParser(preferencesFile); > + parser.parse(); > + Map prefs = parser.getPreferences(); > + > + String type = prefs.get("network.proxy.type"); > + if (type != null) { > + browserProxyType = Integer.valueOf(type); > + } else { > + browserProxyType = BROWSER_PROXY_TYPE_AUTO; > + } > + > + try { > + browserAutoConfigUrl = new URL(prefs.get("network.proxy.autoconfig_url")); > + } catch (MalformedURLException e) { > + e.printStackTrace(); > + } > + > + browserUseSameProxy = Boolean.valueOf(prefs.get("network.proxy.share_proxy_settings")); > + > + browserHttpProxyHost = prefs.get("network.proxy.http"); > + browserHttpProxyPort = Integer.valueOf(prefs.get("network.proxy.http_port")); > + browserHttpsProxyHost = prefs.get("network.proxy.ssl"); > + browserHttpsProxyPort = Integer.valueOf(prefs.get("network.proxy.ssl_port")); > + browserFtpProxyHost = prefs.get("network.proxy.ftp"); > + browserFtpProxyPort = Integer.valueOf(prefs.get("network.proxy.ftp_port")); > + browserSocks4ProxyHost = prefs.get("networking.proxy.socks"); > + browserSocks4ProxyPort = Integer.valueOf(prefs.get("network.proxy.socks_port")); > + > + } catch (IOException e) { > + e.printStackTrace(); > + System.out.println(R("RProxyFirefoxNotFound")); Likewise. Could FirefoxPreferencesFinder not throw a FileNotFoundException (or whatever is appropriate for the other cases) rather than returning null, so the same logic could be used for both? > + browserProxyType = PROXY_TYPE_NONE; > + } > + } > + > + /** > + * The main entry point for {@link BrowserAwareProxySelector}. Based on > + * the browser settings, determines proxy information for a given URI. > + *

> + * The appropriate proxy may be determined by reading static information > + * from the browser's preferences file, or it may be computed dynamically, > + * by, for example, running javascript code. > + */ > + @Override > + protected List getFromBrowser(URI uri) { > + List proxies = new ArrayList(); > + > + switch (browserProxyType) { > + case BROWSER_PROXY_TYPE_PAC: > + proxies.addAll(getFromBrowserPAC(uri)); > + break; > + case BROWSER_PROXY_TYPE_MANUAL: > + proxies.addAll(getFromBrowserConfiguration(uri)); > + break; > + case BROWSER_PROXY_TYPE_NONE: > + proxies.add(Proxy.NO_PROXY); > + break; > + case BROWSER_PROXY_TYPE_AUTO: > + // firefox will do a whole lot of stuff to automagically > + // figure out the right settings. gconf, WPAD, and ENV are used. > + // https://bugzilla.mozilla.org/show_bug.cgi?id=66057#c32 > + case BROWSER_PROXY_TYPE_SYSTEM: > + // means use $http_proxy, $ftp_proxy etc. Is this a TODO or is this case really empty? > + default: > + System.err.println(R("RProxyFirefoxOptionNotImplemented")); > + proxies.add(Proxy.NO_PROXY); Maybe the error should include the value of browserProxyType? > + } > + > + if (JNLPRuntime.isDebug()) { > + System.out.println("Browser selected proxies: " + proxies.toString()); > + } > + > + return proxies; > + } > + > + /** > + * Get an appropriate proxy for a given URI using a PAC specified in the > + * browser. > + */ > + private List getFromBrowserPAC(URI uri) { > + System.err.println(R("RPRoxyPacNotImplemented")); > + return Arrays.asList(new Proxy[] { Proxy.NO_PROXY }); > + } > + > + /** > + * Get an appropriate proxy for the given URI using static information from > + * the browser's preferences file. > + */ > + private List getFromBrowserConfiguration(URI uri) { > + List proxies = new ArrayList(); > + > + String scheme = uri.getScheme(); > + > + if (browserUseSameProxy) { > + SocketAddress sa = new InetSocketAddress(browserHttpProxyHost, browserHttpProxyPort); > + Proxy proxy; > + if (scheme.equals("socket")) { > + proxy = new Proxy(Type.SOCKS, sa); > + } else { > + proxy = new Proxy(Type.HTTP, sa); > + } > + proxies.add(proxy); > + } else if (scheme.equals("http")) { > + SocketAddress sa = new InetSocketAddress(browserHttpProxyHost, browserHttpProxyPort); > + proxies.add(new Proxy(Type.HTTP, sa)); > + } else if (scheme.equals("https")) { > + SocketAddress sa = new InetSocketAddress(browserHttpsProxyHost, browserHttpsProxyPort); > + proxies.add(new Proxy(Type.HTTP, sa)); Do you not need to do something different for HTTPS? Or is that handled elsewhere? > + } else if (scheme.equals("ftp")) { > + SocketAddress sa = new InetSocketAddress(browserFtpProxyHost, browserFtpProxyPort); > + proxies.add(new Proxy(Type.HTTP, sa)); > + } else if (scheme.equals("socket")) { > + SocketAddress sa = new InetSocketAddress(browserSocks4ProxyHost, browserSocks4ProxyPort); > + proxies.add(new Proxy(Type.SOCKS, sa)); > + } else { > + proxies.add(Proxy.NO_PROXY); > + } > + > + return proxies; > + } > + > +} > diff -r 7ddab63cf8fe netx/net/sourceforge/jnlp/browser/FirefoxPreferencesFinder.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/browser/FirefoxPreferencesFinder.java Fri Dec 24 17:19:09 2010 -0500 > @@ -0,0 +1,137 @@ > +/* FirefoxPreferencesFinder.java > + Copyright (C) 2010 Red Hat, Inc. > + > +This file is part of IcedTea. > + > +IcedTea is free software; you can redistribute it and/or > +modify it under the terms of the GNU General Public License as published by > +the Free Software Foundation, version 2. > + > +IcedTea is distributed in the hope that it will be useful, > +but WITHOUT ANY WARRANTY; without even the implied warranty of > +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > +General Public License for more details. > + > +You should have received a copy of the GNU General Public License > +along with IcedTea; see the file COPYING. If not, write to > +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA > +02110-1301 USA. > + > +Linking this library statically or dynamically with other modules is > +making a combined work based on this library. Thus, the terms and > +conditions of the GNU General Public License cover the whole > +combination. > + > +As a special exception, the copyright holders of this library give you > +permission to link this library with independent modules to produce an > +executable, regardless of the license terms of these independent > +modules, and to copy and distribute the resulting executable under > +terms of your choice, provided that you also meet, for each linked > +independent module, the terms and conditions of the license of that > +module. An independent module is a module which is not derived from > +or based on this library. If you modify this library, you may extend > +this exception to your version of the library, but you are not > +obligated to do so. If you do not wish to do so, delete this > +exception statement from your version. > +*/ > + > +package net.sourceforge.jnlp.browser; > + > +import java.io.BufferedReader; > +import java.io.File; > +import java.io.FileReader; > +import java.io.IOException; > +import java.util.ArrayList; > +import java.util.List; > + > +import net.sourceforge.jnlp.runtime.JNLPRuntime; > + > +/** > + * Finds the file corresponding to firefox's (default) preferences file > + */ > +public class FirefoxPreferencesFinder { > + > + /** > + * Returns a file object representing firefox's preferences file > + * > + * @return a File object representing the preferences file or null if the > + * preferences file or the profiles.ini (which contains the location of > + * the preferences file) files do not exist. > + * @throws IOException if an exception occurs while trying to identify the > + * location of the preferences file. > + */ > + public static File find() throws IOException { > + > + String configPath = System.getProperty("user.home") + File.separator + ".mozilla" > + + File.separator + "firefox" + File.separator; > + > + String profilesPath = configPath + "profiles.ini"; > + > + if (!(new File(profilesPath).isFile())) { > + return null; > + } > + > + if (JNLPRuntime.isDebug()) { > + System.out.println("Using firefox's profiles file: " + profilesPath); > + } > + BufferedReader reader = new BufferedReader(new FileReader(profilesPath)); > + > + List linesInSection = new ArrayList(); > + boolean foundDefaultSection = false; > + > + /* > + * The profiles.ini file is an ini file. This is a quick hack to read > + * it. It is very likely to break given anything strange. > + */ > + > + // find the section with an entry Default=1 > + while (true) { > + String line = reader.readLine(); > + if (line == null) { > + break; > + } > + > + line = line.trim(); > + if (line.startsWith("[") && line.endsWith("]")) { > + if (foundDefaultSection) { > + break; > + } > + // new section > + linesInSection = new ArrayList(); > + } else { > + linesInSection.add(line); > + int equalSignPos = line.indexOf('='); > + if (equalSignPos > 0) { > + String key = line.substring(0, equalSignPos).trim(); > + String value = line.substring(equalSignPos+1).trim(); > + if (key.toLowerCase().equals("default") && value.equals("1")) { > + foundDefaultSection = true; > + } > + } > + } > + > + } > + > + if (!foundDefaultSection) { > + return null; > + } > + > + String path = null; > + for (String line : linesInSection) { > + if (line.startsWith("Path=")) { > + path = line.substring("Path=".length()); > + } > + } > + > + if (path == null) { > + return null; > + } else { > + String fullPath = configPath + path + File.separator + "prefs.js"; > + if (JNLPRuntime.isDebug()) { > + System.out.println("Found preferences file: " + fullPath); > + } > + return new File(fullPath); > + } > + } > + > +} > diff -r 7ddab63cf8fe netx/net/sourceforge/jnlp/browser/FirefoxPreferencesParser.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/browser/FirefoxPreferencesParser.java Fri Dec 24 17:19:09 2010 -0500 > @@ -0,0 +1,152 @@ > +/* FirefoxPreferencesParser.java > + Copyright (C) 2010 Red Hat, Inc. > + > +This file is part of IcedTea. > + > +IcedTea is free software; you can redistribute it and/or > +modify it under the terms of the GNU General Public License as published by > +the Free Software Foundation, version 2. > + > +IcedTea is distributed in the hope that it will be useful, > +but WITHOUT ANY WARRANTY; without even the implied warranty of > +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > +General Public License for more details. > + > +You should have received a copy of the GNU General Public License > +along with IcedTea; see the file COPYING. If not, write to > +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA > +02110-1301 USA. > + > +Linking this library statically or dynamically with other modules is > +making a combined work based on this library. Thus, the terms and > +conditions of the GNU General Public License cover the whole > +combination. > + > +As a special exception, the copyright holders of this library give you > +permission to link this library with independent modules to produce an > +executable, regardless of the license terms of these independent > +modules, and to copy and distribute the resulting executable under > +terms of your choice, provided that you also meet, for each linked > +independent module, the terms and conditions of the license of that > +module. An independent module is a module which is not derived from > +or based on this library. If you modify this library, you may extend > +this exception to your version of the library, but you are not > +obligated to do so. If you do not wish to do so, delete this > +exception statement from your version. > +*/ > + > +package net.sourceforge.jnlp.browser; > + > +import java.io.BufferedReader; > +import java.io.File; > +import java.io.FileReader; > +import java.io.IOException; > +import java.util.HashMap; > +import java.util.Map; > + > +/** > + * A parser for Firefox's preferences file. It can 'parse' Firefox's > + * preferences file and expose the prefrences in a simple to use format. > + *

> + * Sample usage: > + *

> + * FirefoxPreferencesParser p = new FirefoxPreferencesParser(prefsFile);
> + * p.parse();
> + * Map<String,String> prefs = p.getPreferences();
> + * System.out.println("blink allowed: " + prefs.get("browser.blink_allowed"));
> + * 
> + */ > +public final class FirefoxPreferencesParser { > + > + File prefsFile = null; > + Map prefs = null; > + > + /** > + * Creates a new FirefoxPreferencesParser > + * @param preferencesFile > + */ > + public FirefoxPreferencesParser(File preferencesFile) { > + prefsFile = preferencesFile; > + } > + > + /** > + * Parse the prefernces file > + * @throws IOException if an exception ocurrs while reading the > + * preferences file. > + */ > + public void parse() throws IOException { > + /* > + * The Firefox preference file is actually in javascript. It does seem > + * to be nicely formatted, so it should be possible to hack reading it. > + * The correct way of course is to use a javascript library and extract > + * the user_pref object > + */ > + prefs = new HashMap(); > + > + BufferedReader reader = new BufferedReader(new FileReader(prefsFile)); > + > + while (true) { > + String line = reader.readLine(); > + // end of stream > + if (line == null) { > + break; > + } > + > + line = line.trim(); > + if (line.startsWith("user_pref")) { > + > + /* > + * each line is of the form: user_pref("key",value); where value > + * can be a string in double quotes or an integer or float or > + * boolean > + */ > + > + boolean foundKey = false; > + boolean foundValue = false; > + > + // extract everything inside user_pref( and ); > + String pref = line.substring("user_pref(".length(), line.length() - 2); > + // key and value are separated by a , > + int firstCommaPos = pref.indexOf(','); > + if (firstCommaPos >= 1) { > + String key = pref.substring(0, firstCommaPos).trim(); > + if (key.startsWith("\"") && key.endsWith("\"")) { > + key = key.substring(1, key.length() - 1); > + if (key.trim().length() > 0) { > + foundKey = true; > + } > + } > + > + if (pref.length() > firstCommaPos + 1) { > + String value = pref.substring(firstCommaPos + 1).trim(); > + if (value.startsWith("\"") && value.endsWith("\"")) { > + value = value.substring(1, value.length() - 1).trim(); > + } > + foundValue = true; > + > + if (foundKey && foundValue) { > + // System.out.println("added (\"" + key + "\", \"" + value + "\")"); > + prefs.put(key, value); > + } > + } > + } > + } > + } > + System.out.println("Read " + prefs.size() + " entries from Firefox's preferences"); System.err? > + > + } > + > + /** > + * Get the firefox preferences as a map (key,value pair). Note that > + * all values (including integers and booleans) are stored as a string, so > + * conversion to an appropriate type may be required. > + * > + * @return a map containing firefox' preferences > + */ > + public Map getPreferences() { > + HashMap newMap = new HashMap(); > + newMap.putAll(prefs); > + return newMap; > + } > + > +} > diff -r 7ddab63cf8fe netx/net/sourceforge/jnlp/resources/Messages.properties > --- a/netx/net/sourceforge/jnlp/resources/Messages.properties Tue Dec 21 16:48:12 2010 -0500 > +++ b/netx/net/sourceforge/jnlp/resources/Messages.properties Fri Dec 24 17:19:09 2010 -0500 > @@ -141,6 +141,9 @@ > RUnexpected=Unexpected {0} at {1} > RConfigurationError=Fatal error while reading the configuration > RConfigurationFatal=ERROR: a fatal error has occurred while loading configuration. Perhaps a global configuration was required but could not be found > +RPRoxyPacNotImplemented=Using Proxy Auto Config (PAC) files is not supported yet. > +RProxyFirefoxNotFound=Unable to use Firefox's proxy settings. Using "DIRECT" as proxy type. > +RProxyFirefoxOptionNotImplemented=Some browser proxy options are not supported yet > > # Boot options, message should be shorter than this ----------------> > BOUsage=javaws [-run-options] > diff -r 7ddab63cf8fe netx/net/sourceforge/jnlp/runtime/JNLPProxySelector.java > --- a/netx/net/sourceforge/jnlp/runtime/JNLPProxySelector.java Tue Dec 21 16:48:12 2010 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/JNLPProxySelector.java Fri Dec 24 17:19:09 2010 -0500 > @@ -16,6 +16,7 @@ > > package net.sourceforge.jnlp.runtime; > > +import static net.sourceforge.jnlp.runtime.Translator.R; > import java.io.IOException; > import java.net.InetAddress; > import java.net.InetSocketAddress; > @@ -40,7 +41,7 @@ > * > * @see java.net.ProxySelector > */ > -public class JNLPProxySelector extends ProxySelector { > +public abstract class JNLPProxySelector extends ProxySelector { > > public static final int PROXY_TYPE_UNKNOWN = -1; > public static final int PROXY_TYPE_NONE = 0; > @@ -336,10 +337,7 @@ > if (autoConfigUrl == null) { > return Arrays.asList(new Proxy[] { Proxy.NO_PROXY }); > } > - // TODO implement this by reading and using the PAC file > - if (JNLPRuntime.isDebug()) { > - System.err.println("WARNING: Using a Proxy Auto Config file is not implemented yet"); > - } > + System.err.println(R("RPRoxyPacNotImplemented")); I'd leave the TODO in place. > > return Arrays.asList(new Proxy[] { Proxy.NO_PROXY }); > } > @@ -350,13 +348,7 @@ > * @param uri the uri to get proxies for > * @return a list of proxies > */ > - protected List getFromBrowser(URI uri) { > - // TODO implement this by parsing mozilla config > - if (JNLPRuntime.isDebug()) { > - System.err.println("WARNING: Using proxy settings from the browser is not implemented yet"); > - } > + protected abstract List getFromBrowser(URI uri); > > - return Arrays.asList(new Proxy[] { Proxy.NO_PROXY }); > - } > > } > diff -r 7ddab63cf8fe netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java > --- a/netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java Tue Dec 21 16:48:12 2010 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java Fri Dec 24 17:19:09 2010 -0500 > @@ -35,6 +35,7 @@ > import javax.swing.text.html.parser.ParserDelegator; > > import net.sourceforge.jnlp.*; > +import net.sourceforge.jnlp.browser.BrowserAwareProxySelector; > import net.sourceforge.jnlp.cache.*; > import net.sourceforge.jnlp.config.DeploymentConfiguration; > import net.sourceforge.jnlp.security.JNLPAuthenticator; > @@ -218,7 +219,7 @@ > > // plug in a custom authenticator and proxy selector > Authenticator.setDefault(new JNLPAuthenticator()); > - ProxySelector.setDefault(new JNLPProxySelector()); > + ProxySelector.setDefault(new BrowserAwareProxySelector()); > > initialized = true; > -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at redhat.com Mon Jan 24 11:49:15 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 24 Jan 2011 14:49:15 -0500 Subject: Request to backport 6736649 and 6797139 In-Reply-To: <20110118235603.GI14019@rivendell.middle-earth.co.uk> References: <4D30CFB1.6050705@redhat.com> <20110117141006.GA13471@rivendell.middle-earth.co.uk> <4D3454D9.7040200@redhat.com> <20110117170055.GD13471@rivendell.middle-earth.co.uk> <4D348843.2060602@redhat.com> <20110117185548.GJ13471@rivendell.middle-earth.co.uk> <4D349889.80701@redhat.com> <20110117200053.GL13471@rivendell.middle-earth.co.uk> <4D36058E.3080209@redhat.com> <20110118235603.GI14019@rivendell.middle-earth.co.uk> Message-ID: <4D3DD7BB.3000005@redhat.com> On 01/18/2011 06:56 PM, Dr Andrew John Hughes wrote: > On 16:26 Tue 18 Jan , Omair Majid wrote: >>>>>>>>> On 17:35 Fri 14 Jan , Omair Majid wrote: >>>>>>>>>> I would like to backport the following two changesets to openjdk6: >>>>>>>>>> >>>>>>>>>> changeset: 624:e78c2f17a606 >>>>>>>>>> user: mlapshin >>>>>>>>>> date: Tue Aug 26 12:16:23 2008 +0400 >>>>>>>>>> summary: 6736649: >>>>>>>>>> test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on >>>>>>>>>> Linux >>>>>>>>>> >>>>>>>>>> changeset: 1637:281fbd82a971 >>>>>>>>>> user: alexp >>>>>>>>>> date: Wed Sep 02 17:47:19 2009 +0400 >>>>>>>>>> summary: 6797139: JButton title is truncating for some strings >>>>>>>>>> irrespective of preferred size. >>>>>>>>>> >> >> changeset: 1738:9d78c3d9def2 >> user: alexp >> date: Mon Sep 21 17:58:09 2009 +0400 >> summary: 6883341: SWAT: jdk7-b72 swat build(2009-09-17) threw >> exceptions when running Java2D demo by clicking Paint ta >> >> This changeset gets rid of the StringIndexOutOfBoundsException (by >> effectively reverting the exception changes). >> > > Ok, so I guess I spotted it quicker than them ;-) > > Please backport this one as well. > Done. Please see the attached patch. >>>>> Do the new tests pass? They should be fixed to use the newer Oracle copyright notices. >>>>> Updated the copyright headers. >>>> >>>> Sorry, but I forgot to run the tests. I will fix the copyrights, run the >>>> tests and post the results. I can confirm that the patch does fix the >>>> issue pointed out in the bug report at >>>> https://bugzilla.redhat.com/show_bug.cgi?id=661610 >>>> >>> >>> This sounds a good reason to backport. >>> >>> I'll await the results. >> >> I can confirm that the new tests pass. However, I also discovered that >> swing programs using JMenus crash, so I didnt attempt to run all the tests. >> >> I will post an updated patch soon. >> And here is the updated patch. I ran the jtreg tests and found no related failures. I also ran netbeans using this build and nothing seemed broken. Ok to commit? Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: icedtea6-jbutton-truncation.patch Type: text/x-patch Size: 35053 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110124/9a4f0642/icedtea6-jbutton-truncation.patch From ahughes at redhat.com Mon Jan 24 12:09:14 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Mon, 24 Jan 2011 20:09:14 +0000 Subject: Request to backport 6736649 and 6797139 In-Reply-To: <4D3DD7BB.3000005@redhat.com> References: <20110117141006.GA13471@rivendell.middle-earth.co.uk> <4D3454D9.7040200@redhat.com> <20110117170055.GD13471@rivendell.middle-earth.co.uk> <4D348843.2060602@redhat.com> <20110117185548.GJ13471@rivendell.middle-earth.co.uk> <4D349889.80701@redhat.com> <20110117200053.GL13471@rivendell.middle-earth.co.uk> <4D36058E.3080209@redhat.com> <20110118235603.GI14019@rivendell.middle-earth.co.uk> <4D3DD7BB.3000005@redhat.com> Message-ID: <20110124200914.GG17602@rivendell.middle-earth.co.uk> On 14:49 Mon 24 Jan , Omair Majid wrote: > On 01/18/2011 06:56 PM, Dr Andrew John Hughes wrote: > > On 16:26 Tue 18 Jan , Omair Majid wrote: > >>>>>>>>> On 17:35 Fri 14 Jan , Omair Majid wrote: > >>>>>>>>>> I would like to backport the following two changesets to openjdk6: > >>>>>>>>>> > >>>>>>>>>> changeset: 624:e78c2f17a606 > >>>>>>>>>> user: mlapshin > >>>>>>>>>> date: Tue Aug 26 12:16:23 2008 +0400 > >>>>>>>>>> summary: 6736649: > >>>>>>>>>> test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on > >>>>>>>>>> Linux > >>>>>>>>>> > >>>>>>>>>> changeset: 1637:281fbd82a971 > >>>>>>>>>> user: alexp > >>>>>>>>>> date: Wed Sep 02 17:47:19 2009 +0400 > >>>>>>>>>> summary: 6797139: JButton title is truncating for some strings > >>>>>>>>>> irrespective of preferred size. > >>>>>>>>>> > >> > >> changeset: 1738:9d78c3d9def2 > >> user: alexp > >> date: Mon Sep 21 17:58:09 2009 +0400 > >> summary: 6883341: SWAT: jdk7-b72 swat build(2009-09-17) threw > >> exceptions when running Java2D demo by clicking Paint ta > >> > >> This changeset gets rid of the StringIndexOutOfBoundsException (by > >> effectively reverting the exception changes). > >> > > > > Ok, so I guess I spotted it quicker than them ;-) > > > > Please backport this one as well. > > > > Done. Please see the attached patch. > > >>>>> Do the new tests pass? They should be fixed to use the newer Oracle copyright notices. > >>>>> > > Updated the copyright headers. > Thanks. Sorry for insisting on this, but they will to upstream them, so better to do it early. > >>>> > >>>> Sorry, but I forgot to run the tests. I will fix the copyrights, run the > >>>> tests and post the results. I can confirm that the patch does fix the > >>>> issue pointed out in the bug report at > >>>> https://bugzilla.redhat.com/show_bug.cgi?id=661610 > >>>> > >>> > >>> This sounds a good reason to backport. > >>> > >>> I'll await the results. > >> > >> I can confirm that the new tests pass. However, I also discovered that > >> swing programs using JMenus crash, so I didnt attempt to run all the tests. > >> > >> I will post an updated patch soon. > >> > > And here is the updated patch. I ran the jtreg tests and found no > related failures. I also ran netbeans using this build and nothing > seemed broken. > Great. The question about tests was more for interest than a case of "we'll only allow this in if they pass", as the best place to fix such failures is with the changes committed and easily accessible for all. > Ok to commit? > Sure. > Cheers, > Omair > diff -r 6633b7a3a5db Makefile.am > --- a/Makefile.am Sat Jan 22 21:47:34 2011 +0100 > +++ b/Makefile.am Mon Jan 24 14:44:59 2011 -0500 > @@ -274,7 +274,10 @@ > patches/6703377-freetypescaler.patch \ > patches/ia64-fix.patch \ > patches/openjdk/6642612-filechooser_button_sizes.patch \ > - patches/jtreg-international-fonts-styles.patch > + patches/jtreg-international-fonts-styles.patch \ > + patches/openjdk/6736649-text_bearings.patch \ > + patches/openjdk/6797139-jbutton_truncation.patch \ > + patches/openjdk/6883341-text_bearing_exception.patch > > if WITH_RHINO > ICEDTEA_PATCHES += \ > diff -r 6633b7a3a5db patches/openjdk/6736649-text_bearings.patch > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/patches/openjdk/6736649-text_bearings.patch Mon Jan 24 14:44:59 2011 -0500 > @@ -0,0 +1,112 @@ > +# HG changeset patch > +# User mlapshin > +# Date 1219738583 -14400 > +# Node ID e78c2f17a60646b8198279b2f676712094b833a0 > +# Parent c9d407ab230941d41025428b25bc5d787cf7c18f > +6736649: test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on Linux > +Summary: Now text bearings are taken into account when labelRect width is calculated > +Reviewed-by: alexp > + > +diff -r c9d407ab2309 -r e78c2f17a606 src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java > +--- openjdk/jdk/src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java Tue Aug 12 17:59:58 2008 -0700 > ++++ openjdk/jdk/src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java Tue Aug 26 12:16:23 2008 +0400 > +@@ -136,7 +136,7 @@ > + > + // accRect > + if (!getAccText().equals("")) { > +- getAccSize().setWidth(accGu.computeStringWidth(getAccContext(), > ++ getAccSize().setWidth(accGu.computeStringWidth(getAccContext(), > + getAccFontMetrics().getFont(), getAccFontMetrics(), > + getAccText())); > + getAccSize().setHeight(getAccFontMetrics().getHeight()); > +@@ -195,6 +195,7 @@ > + getHorizontalAlignment(), getVerticalAlignment(), > + getHorizontalTextPosition(), getVerticalTextPosition(), > + getViewRect(), iconRect, textRect, getGap()); > ++ textRect.width += getLeftTextExtraWidth() + getRightTextExtraWidth(); > + Rectangle labelRect = iconRect.union(textRect); > + getLabelSize().setHeight(labelRect.height); > + getLabelSize().setWidth(labelRect.width); > +diff -r c9d407ab2309 -r e78c2f17a606 src/share/classes/sun/swing/MenuItemLayoutHelper.java > +--- openjdk/jdk/src/share/classes/sun/swing/MenuItemLayoutHelper.java Tue Aug 12 17:59:58 2008 -0700 > ++++ openjdk/jdk/src/share/classes/sun/swing/MenuItemLayoutHelper.java Tue Aug 26 12:16:23 2008 +0400 > +@@ -83,6 +83,9 @@ > + private int afterCheckIconGap; > + private int minTextOffset; > + > ++ private int leftTextExtraWidth; > ++ private int rightTextExtraWidth; > ++ > + private Rectangle viewRect; > + > + private RectSize iconSize; > +@@ -143,6 +146,7 @@ > + this.checkSize = new RectSize(); > + this.arrowSize = new RectSize(); > + this.labelSize = new RectSize(); > ++ calcExtraWidths(); > + calcWidthsAndHeights(); > + setOriginalWidths(); > + calcMaxWidths(); > +@@ -151,6 +155,29 @@ > + calcMaxTextOffset(viewRect); > + } > + > ++ private void calcExtraWidths() { > ++ leftTextExtraWidth = getLeftExtraWidth(text); > ++ rightTextExtraWidth = getRightExtraWidth(text); > ++ } > ++ > ++ private int getLeftExtraWidth(String str) { > ++ int lsb = SwingUtilities2.getLeftSideBearing(mi, fm, str); > ++ if (lsb < 0) { > ++ return -lsb; > ++ } else { > ++ return 0; > ++ } > ++ } > ++ > ++ private int getRightExtraWidth(String str) { > ++ int rsb = SwingUtilities2.getRightSideBearing(mi, fm, str); > ++ if (rsb > 0) { > ++ return rsb; > ++ } else { > ++ return 0; > ++ } > ++ } > ++ > + private void setOriginalWidths() { > + iconSize.origWidth = iconSize.width; > + textSize.origWidth = textSize.width; > +@@ -286,6 +313,7 @@ > + verticalAlignment, horizontalAlignment, > + verticalTextPosition, horizontalTextPosition, > + viewRect, iconRect, textRect, gap); > ++ textRect.width += leftTextExtraWidth + rightTextExtraWidth; > + Rectangle labelRect = iconRect.union(textRect); > + labelSize.height = labelRect.height; > + labelSize.width = labelRect.width; > +@@ -727,7 +755,7 @@ > + } > + } > + > +- /** > ++ /** > + * Sets Y coordinates of text and icon > + * taking into account the vertical alignment > + */ > +@@ -1089,6 +1117,14 @@ > + this.labelSize = labelSize; > + } > + > ++ public int getLeftTextExtraWidth() { > ++ return leftTextExtraWidth; > ++ } > ++ > ++ public int getRightTextExtraWidth() { > ++ return rightTextExtraWidth; > ++ } > ++ > + /** > + * Returns false if the component is a JMenu and it is a top > + * level menu (on the menubar). > diff -r 6633b7a3a5db patches/openjdk/6797139-jbutton_truncation.patch > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/patches/openjdk/6797139-jbutton_truncation.patch Mon Jan 24 14:44:59 2011 -0500 > @@ -0,0 +1,610 @@ > +# HG changeset patch > +# User alexp > +# Date 1251899239 -14400 > +# Node ID 281fbd82a971f05fcf6f2c31cfe7db7ef74909e9 > +# Parent 935814bd43a62d1b2c6871f0298c5b59fbf54428 > +6797139: JButton title is truncating for some strings irrespective of preferred size. > +Reviewed-by: peterz > + > +diff -r 935814bd43a6 -r 281fbd82a971 src/share/classes/javax/swing/SwingUtilities.java > +--- openjdk/jdk/src/share/classes/javax/swing/SwingUtilities.java Tue Sep 01 18:51:15 2009 +0400 > ++++ openjdk/jdk/src/share/classes/javax/swing/SwingUtilities.java Wed Sep 02 17:47:19 2009 +0400 > +@@ -999,24 +999,20 @@ > + textR.height = (int) v.getPreferredSpan(View.Y_AXIS); > + } else { > + textR.width = SwingUtilities2.stringWidth(c, fm, text); > +- > +- // Take into account the left and right side bearings. > +- // This gives more space than it is actually needed, > +- // but there are two reasons: > +- // 1. If we set the width to the actual bounds, > +- // all callers would have to account for the bearings > +- // themselves. NOTE: all pref size calculations don't do it. > +- // 2. You can do a drawString at the returned location > +- // and the text won't be clipped. > + lsb = SwingUtilities2.getLeftSideBearing(c, fm, text); > + if (lsb < 0) { > ++ // If lsb is negative, add it to the width and later > ++ // adjust the x location. This gives more space than is > ++ // actually needed. > ++ // This is done like this for two reasons: > ++ // 1. If we set the width to the actual bounds all > ++ // callers would have to account for negative lsb > ++ // (pref size calculations ONLY look at width of > ++ // textR) > ++ // 2. You can do a drawString at the returned location > ++ // and the text won't be clipped. > + textR.width -= lsb; > + } > +- rsb = SwingUtilities2.getRightSideBearing(c, fm, text); > +- if (rsb > 0) { > +- textR.width += rsb; > +- } > +- > + if (textR.width > availTextWidth) { > + text = SwingUtilities2.clipString(c, fm, text, > + availTextWidth); > +diff -r 935814bd43a6 -r 281fbd82a971 src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java > +--- openjdk/jdk/src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java Tue Sep 01 18:51:15 2009 +0400 > ++++ openjdk/jdk/src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java Wed Sep 02 17:47:19 2009 +0400 > +@@ -195,7 +195,7 @@ > + getHorizontalAlignment(), getVerticalAlignment(), > + getHorizontalTextPosition(), getVerticalTextPosition(), > + getViewRect(), iconRect, textRect, getGap()); > +- textRect.width += getLeftTextExtraWidth() + getRightTextExtraWidth(); > ++ textRect.width += getLeftTextExtraWidth(); > + Rectangle labelRect = iconRect.union(textRect); > + getLabelSize().setHeight(labelRect.height); > + getLabelSize().setWidth(labelRect.width); > +diff -r 935814bd43a6 -r 281fbd82a971 src/share/classes/sun/swing/MenuItemLayoutHelper.java > +--- openjdk/jdk/src/share/classes/sun/swing/MenuItemLayoutHelper.java Tue Sep 01 18:51:15 2009 +0400 > ++++ openjdk/jdk/src/share/classes/sun/swing/MenuItemLayoutHelper.java Wed Sep 02 17:47:19 2009 +0400 > +@@ -84,7 +84,6 @@ > + private int minTextOffset; > + > + private int leftTextExtraWidth; > +- private int rightTextExtraWidth; > + > + private Rectangle viewRect; > + > +@@ -157,7 +156,6 @@ > + > + private void calcExtraWidths() { > + leftTextExtraWidth = getLeftExtraWidth(text); > +- rightTextExtraWidth = getRightExtraWidth(text); > + } > + > + private int getLeftExtraWidth(String str) { > +@@ -169,15 +167,6 @@ > + } > + } > + > +- private int getRightExtraWidth(String str) { > +- int rsb = SwingUtilities2.getRightSideBearing(mi, fm, str); > +- if (rsb > 0) { > +- return rsb; > +- } else { > +- return 0; > +- } > +- } > +- > + private void setOriginalWidths() { > + iconSize.origWidth = iconSize.width; > + textSize.origWidth = textSize.width; > +@@ -313,7 +302,7 @@ > + verticalAlignment, horizontalAlignment, > + verticalTextPosition, horizontalTextPosition, > + viewRect, iconRect, textRect, gap); > +- textRect.width += leftTextExtraWidth + rightTextExtraWidth; > ++ textRect.width += leftTextExtraWidth; > + Rectangle labelRect = iconRect.union(textRect); > + labelSize.height = labelRect.height; > + labelSize.width = labelRect.width; > +@@ -1121,10 +1110,6 @@ > + return leftTextExtraWidth; > + } > + > +- public int getRightTextExtraWidth() { > +- return rightTextExtraWidth; > +- } > +- > + /** > + * Returns false if the component is a JMenu and it is a top > + * level menu (on the menubar). > +diff -r 935814bd43a6 -r 281fbd82a971 src/share/classes/sun/swing/SwingUtilities2.java > +--- openjdk/jdk/src/share/classes/sun/swing/SwingUtilities2.java Tue Sep 01 18:51:15 2009 +0400 > ++++ openjdk/jdk/src/share/classes/sun/swing/SwingUtilities2.java Wed Sep 02 17:47:19 2009 +0400 > +@@ -27,7 +27,6 @@ > + > + import java.security.*; > + import java.lang.reflect.*; > +-import java.lang.ref.SoftReference; > + import java.awt.*; > + import static java.awt.RenderingHints.*; > + import java.awt.event.*; > +@@ -78,17 +77,23 @@ > + public static final Object LAF_STATE_KEY = > + new StringBuffer("LookAndFeel State"); > + > +- // Most of applications use 10 or less fonts simultaneously > +- private static final int STRONG_BEARING_CACHE_SIZE = 10; > +- // Strong cache for the left and right side bearings > +- // for STRONG_BEARING_CACHE_SIZE most recently used fonts. > +- private static BearingCacheEntry[] strongBearingCache = > +- new BearingCacheEntry[STRONG_BEARING_CACHE_SIZE]; > +- // Next index to insert an entry into the strong bearing cache > +- private static int strongBearingCacheNextIndex = 0; > +- // Soft cache for the left and right side bearings > +- private static Set> softBearingCache = > +- new HashSet>(); > ++ // Maintain a cache of CACHE_SIZE fonts and the left side bearing > ++ // of the characters falling into the range MIN_CHAR_INDEX to > ++ // MAX_CHAR_INDEX. The values in fontCache are created as needed. > ++ private static LSBCacheEntry[] fontCache; > ++ // Windows defines 6 font desktop properties, we will therefore only > ++ // cache the metrics for 6 fonts. > ++ private static final int CACHE_SIZE = 6; > ++ // nextIndex in fontCache to insert a font into. > ++ private static int nextIndex; > ++ // LSBCacheEntry used to search in fontCache to see if we already > ++ // have an entry for a particular font > ++ private static LSBCacheEntry searchKey; > ++ > ++ // getLeftSideBearing will consult all characters that fall in the > ++ // range MIN_CHAR_INDEX to MAX_CHAR_INDEX. > ++ private static final int MIN_CHAR_INDEX = (int)'W'; > ++ private static final int MAX_CHAR_INDEX = (int)'W' + 1; > + > + public static final FontRenderContext DEFAULT_FRC = > + new FontRenderContext(null, false, false); > +@@ -183,6 +188,10 @@ > + private static final Object charsBufferLock = new Object(); > + private static char[] charsBuffer = new char[CHAR_BUFFER_SIZE]; > + > ++ static { > ++ fontCache = new LSBCacheEntry[CACHE_SIZE]; > ++ } > ++ > + /** > + * checks whether TextLayout is required to handle characters. > + * > +@@ -226,7 +235,9 @@ > + > + /** > + * Returns the left side bearing of the first character of string. The > +- * left side bearing is calculated from the passed in FontMetrics. > ++ * left side bearing is calculated from the passed in > ++ * FontMetrics. If the passed in String is less than one > ++ * character, this will throw a StringIndexOutOfBoundsException exception. > + * > + * @param c JComponent that will display the string > + * @param fm FontMetrics used to measure the String width > +@@ -234,14 +245,11 @@ > + */ > + public static int getLeftSideBearing(JComponent c, FontMetrics fm, > + String string) { > +- if ((string == null) || (string.length() == 0)) { > +- return 0; > +- } > + return getLeftSideBearing(c, fm, string.charAt(0)); > + } > + > + /** > +- * Returns the left side bearing of the specified character. The > ++ * Returns the left side bearing of the first character of string. The > + * left side bearing is calculated from the passed in FontMetrics. > + * > + * @param c JComponent that will display the string > +@@ -250,105 +258,37 @@ > + */ > + public static int getLeftSideBearing(JComponent c, FontMetrics fm, > + char firstChar) { > +- return getBearing(c, fm, firstChar, true); > +- } > ++ int charIndex = (int) firstChar; > ++ if (charIndex < MAX_CHAR_INDEX && charIndex >= MIN_CHAR_INDEX) { > ++ byte[] lsbs = null; > + > +- /** > +- * Returns the right side bearing of the last character of string. The > +- * right side bearing is calculated from the passed in FontMetrics. > +- * > +- * @param c JComponent that will display the string > +- * @param fm FontMetrics used to measure the String width > +- * @param string String to get the right side bearing for. > +- */ > +- public static int getRightSideBearing(JComponent c, FontMetrics fm, > +- String string) { > +- if ((string == null) || (string.length() == 0)) { > +- return 0; > +- } > +- return getRightSideBearing(c, fm, string.charAt(string.length() - 1)); > +- } > +- > +- /** > +- * Returns the right side bearing of the specified character. The > +- * right side bearing is calculated from the passed in FontMetrics. > +- * > +- * @param c JComponent that will display the string > +- * @param fm FontMetrics used to measure the String width > +- * @param lastChar Character to get the right side bearing for. > +- */ > +- public static int getRightSideBearing(JComponent c, FontMetrics fm, > +- char lastChar) { > +- return getBearing(c, fm, lastChar, false); > +- } > +- > +- /* Calculates the left and right side bearing for a character. > +- * Strongly caches bearings for STRONG_BEARING_CACHE_SIZE > +- * most recently used Fonts and softly caches as many as GC allows. > +- */ > +- private static int getBearing(JComponent comp, FontMetrics fm, char c, > +- boolean isLeftBearing) { > +- if (fm == null) { > +- if (comp == null) { > +- return 0; > +- } else { > +- fm = comp.getFontMetrics(comp.getFont()); > +- } > +- } > +- synchronized (SwingUtilities2.class) { > +- BearingCacheEntry entry = null; > +- BearingCacheEntry searchKey = new BearingCacheEntry(fm); > +- // See if we already have an entry in the strong cache > +- for (BearingCacheEntry cacheEntry : strongBearingCache) { > +- if (searchKey.equals(cacheEntry)) { > +- entry = cacheEntry; > +- break; > ++ FontRenderContext frc = getFontRenderContext(c, fm); > ++ Font font = fm.getFont(); > ++ synchronized (SwingUtilities2.class) { > ++ LSBCacheEntry entry = null; > ++ if (searchKey == null) { > ++ searchKey = new LSBCacheEntry(frc, font); > ++ } else { > ++ searchKey.reset(frc, font); > + } > +- } > +- // See if we already have an entry in the soft cache > +- if (entry == null) { > +- Iterator> iter = > +- softBearingCache.iterator(); > +- while (iter.hasNext()) { > +- BearingCacheEntry cacheEntry = iter.next().get(); > +- if (cacheEntry == null) { > +- // Remove discarded soft reference from the cache > +- iter.remove(); > +- continue; > +- } > ++ // See if we already have an entry for this pair > ++ for (LSBCacheEntry cacheEntry : fontCache) { > + if (searchKey.equals(cacheEntry)) { > + entry = cacheEntry; > +- putEntryInStrongCache(entry); > + break; > + } > + } > ++ if (entry == null) { > ++ // No entry for this pair, add it. > ++ entry = searchKey; > ++ fontCache[nextIndex] = searchKey; > ++ searchKey = null; > ++ nextIndex = (nextIndex + 1) % CACHE_SIZE; > ++ } > ++ return entry.getLeftSideBearing(firstChar); > + } > +- if (entry == null) { > +- // No entry, add it > +- entry = searchKey; > +- cacheEntry(entry); > +- } > +- return (isLeftBearing) > +- ? entry.getLeftSideBearing(c) > +- : entry.getRightSideBearing(c); > + } > +- } > +- > +- private synchronized static void cacheEntry(BearingCacheEntry entry) { > +- // Move the oldest entry from the strong cache into the soft cache > +- BearingCacheEntry oldestEntry = > +- strongBearingCache[strongBearingCacheNextIndex]; > +- if (oldestEntry != null) { > +- softBearingCache.add(new SoftReference(oldestEntry)); > +- } > +- // Put entry in the strong cache > +- putEntryInStrongCache(entry); > +- } > +- > +- private synchronized static void putEntryInStrongCache(BearingCacheEntry entry) { > +- strongBearingCache[strongBearingCacheNextIndex] = entry; > +- strongBearingCacheNextIndex = (strongBearingCacheNextIndex + 1) > +- % STRONG_BEARING_CACHE_SIZE; > ++ return 0; > + } > + > + /** > +@@ -1063,99 +1003,72 @@ > + } > + > + /** > +- * BearingCacheEntry is used to cache left and right character bearings > +- * for a particular Font and FontRenderContext. > ++ * LSBCacheEntry is used to cache the left side bearing (lsb) for > ++ * a particular Font and FontRenderContext. > ++ * This only caches characters that fall in the range > ++ * MIN_CHAR_INDEX to MAX_CHAR_INDEX. > + */ > +- private static class BearingCacheEntry { > +- private FontMetrics fontMetrics; > ++ private static class LSBCacheEntry { > ++ // Used to indicate a particular entry in lsb has not been set. > ++ private static final byte UNSET = Byte.MAX_VALUE; > ++ // Used in creating a GlyphVector to get the lsb > ++ private static final char[] oneChar = new char[1]; > ++ > ++ private byte[] lsbCache; > + private Font font; > + private FontRenderContext frc; > +- private Map cache; > +- // Used for the creation of a GlyphVector > +- private static final char[] oneChar = new char[1]; > + > +- public BearingCacheEntry(FontMetrics fontMetrics) { > +- this.fontMetrics = fontMetrics; > +- this.font = fontMetrics.getFont(); > +- this.frc = fontMetrics.getFontRenderContext(); > +- this.cache = new HashMap(); > +- assert (font != null && frc != null); > ++ > ++ public LSBCacheEntry(FontRenderContext frc, Font font) { > ++ lsbCache = new byte[MAX_CHAR_INDEX - MIN_CHAR_INDEX]; > ++ reset(frc, font); > ++ > ++ } > ++ > ++ public void reset(FontRenderContext frc, Font font) { > ++ this.font = font; > ++ this.frc = frc; > ++ for (int counter = lsbCache.length - 1; counter >= 0; counter--) { > ++ lsbCache[counter] = UNSET; > ++ } > + } > + > + public int getLeftSideBearing(char aChar) { > +- Short bearing = cache.get(aChar); > +- if (bearing == null) { > +- bearing = calcBearing(aChar); > +- cache.put(aChar, bearing); > ++ int index = aChar - MIN_CHAR_INDEX; > ++ assert (index >= 0 && index < (MAX_CHAR_INDEX - MIN_CHAR_INDEX)); > ++ byte lsb = lsbCache[index]; > ++ if (lsb == UNSET) { > ++ oneChar[0] = aChar; > ++ GlyphVector gv = font.createGlyphVector(frc, oneChar); > ++ lsb = (byte) gv.getGlyphPixelBounds(0, frc, 0f, 0f).x; > ++ if (lsb < 0) { > ++ /* HRGB/HBGR LCD glyph images will always have a pixel > ++ * on the left used in colour fringe reduction. > ++ * Text rendering positions this correctly but here > ++ * we are using the glyph image to adjust that position > ++ * so must account for it. > ++ */ > ++ Object aaHint = frc.getAntiAliasingHint(); > ++ if (aaHint == VALUE_TEXT_ANTIALIAS_LCD_HRGB || > ++ aaHint == VALUE_TEXT_ANTIALIAS_LCD_HBGR) { > ++ lsb++; > ++ } > ++ } > ++ lsbCache[index] = lsb; > + } > +- return ((0xFF00 & bearing) >>> 8) - 127; > +- } > ++ return lsb; > + > +- public int getRightSideBearing(char aChar) { > +- Short bearing = cache.get(aChar); > +- if (bearing == null) { > +- bearing = calcBearing(aChar); > +- cache.put(aChar, bearing); > +- } > +- return (0xFF & bearing) - 127; > +- } > + > +- /* Calculates left and right side bearings for a character. > +- * Makes an assumption that bearing is a value between -127 and +127. > +- * Stores LSB and RSB as single two-byte number (short): > +- * LSB is the high byte, RSB is the low byte. > +- */ > +- private short calcBearing(char aChar) { > +- oneChar[0] = aChar; > +- GlyphVector gv = font.createGlyphVector(frc, oneChar); > +- Rectangle pixelBounds = gv.getGlyphPixelBounds(0, frc, 0f, 0f); > +- > +- // Get bearings > +- int lsb = pixelBounds.x; > +- int rsb = pixelBounds.width - fontMetrics.charWidth(aChar); > +- > +- /* HRGB/HBGR LCD glyph images will always have a pixel > +- * on the left and a pixel on the right > +- * used in colour fringe reduction. > +- * Text rendering positions this correctly but here > +- * we are using the glyph image to adjust that position > +- * so must account for it. > +- */ > +- if (lsb < 0) { > +- Object aaHint = frc.getAntiAliasingHint(); > +- if (aaHint == VALUE_TEXT_ANTIALIAS_LCD_HRGB || > +- aaHint == VALUE_TEXT_ANTIALIAS_LCD_HBGR) { > +- lsb++; > +- } > +- } > +- if (rsb > 0) { > +- Object aaHint = frc.getAntiAliasingHint(); > +- if (aaHint == VALUE_TEXT_ANTIALIAS_LCD_HRGB || > +- aaHint == VALUE_TEXT_ANTIALIAS_LCD_HBGR) { > +- rsb--; > +- } > +- } > +- > +- // Make sure that LSB and RSB are valid (see 6472972) > +- if (lsb < -127 || lsb > 127) { > +- lsb = 0; > +- } > +- if (rsb < -127 || rsb > 127) { > +- rsb = 0; > +- } > +- > +- int bearing = ((lsb + 127) << 8) + (rsb + 127); > +- return (short)bearing; > + } > + > + public boolean equals(Object entry) { > + if (entry == this) { > + return true; > + } > +- if (!(entry instanceof BearingCacheEntry)) { > ++ if (!(entry instanceof LSBCacheEntry)) { > + return false; > + } > +- BearingCacheEntry oEntry = (BearingCacheEntry)entry; > ++ LSBCacheEntry oEntry = (LSBCacheEntry) entry; > + return (font.equals(oEntry.font) && > + frc.equals(oEntry.frc)); > + } > +@@ -1172,7 +1085,6 @@ > + } > + } > + > +- > + /* > + * here goes the fix for 4856343 [Problem with applet interaction > + * with system selection clipboard] > +@@ -1181,36 +1093,34 @@ > + * are to be performed > + */ > + > +- > + /** > +- * checks the security permissions for accessing system clipboard > +- * > +- * for untrusted context (see isTrustedContext) checks the > +- * permissions for the current event being handled > +- * > +- */ > +- public static boolean canAccessSystemClipboard() { > +- boolean canAccess = false; > +- if (!GraphicsEnvironment.isHeadless()) { > +- SecurityManager sm = System.getSecurityManager(); > +- if (sm == null) { > +- canAccess = true; > +- } else { > +- try { > +- sm.checkSystemClipboardAccess(); > +- canAccess = true; > +- } catch (SecurityException e) { > +- } > +- if (canAccess && ! isTrustedContext()) { > +- canAccess = canCurrentEventAccessSystemClipboard(true); > +- } > +- } > +- } > +- return canAccess; > +- } > +- > ++ * checks the security permissions for accessing system clipboard > ++ * > ++ * for untrusted context (see isTrustedContext) checks the > ++ * permissions for the current event being handled > ++ * > ++ */ > ++ public static boolean canAccessSystemClipboard() { > ++ boolean canAccess = false; > ++ if (!GraphicsEnvironment.isHeadless()) { > ++ SecurityManager sm = System.getSecurityManager(); > ++ if (sm == null) { > ++ canAccess = true; > ++ } else { > ++ try { > ++ sm.checkSystemClipboardAccess(); > ++ canAccess = true; > ++ } catch (SecurityException e) { > ++ } > ++ if (canAccess && ! isTrustedContext()) { > ++ canAccess = canCurrentEventAccessSystemClipboard(true); > ++ } > ++ } > ++ } > ++ return canAccess; > ++ } > + /** > +- * Returns true if EventQueue.getCurrentEvent() has the permissions to > ++ * Returns true if EventQueue.getCurrentEvent() has the permissions to > + * access the system clipboard > + */ > + public static boolean canCurrentEventAccessSystemClipboard() { > +diff -r 935814bd43a6 -r 281fbd82a971 test/javax/swing/SwingUtilities/6797139/bug6797139.java > +--- /dev/null Thu Jan 01 00:00:00 1970 +0000 > ++++ openjdk/jdk/test/javax/swing/SwingUtilities/6797139/bug6797139.java Wed Sep 02 17:47:19 2009 +0400 > +@@ -0,0 +1,62 @@ > ++/* > ++ * Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved. > ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. > ++ * > ++ * This code is free software; you can redistribute it and/or modify it > ++ * under the terms of the GNU General Public License version 2 only, as > ++ * published by the Free Software Foundation. > ++ * > ++ * This code is distributed in the hope that it will be useful, but WITHOUT > ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or > ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License > ++ * version 2 for more details (a copy is included in the LICENSE file that > ++ * accompanied this code). > ++ * > ++ * You should have received a copy of the GNU General Public License version > ++ * 2 along with this work; if not, write to the Free Software Foundation, > ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. > ++ * > ++ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA > ++ * or visit www.oracle.com if you need additional information or have any > ++ * questions. > ++ */ > ++ > ++/* @test > ++ * > ++ * @bug 6797139 > ++ * @author Alexander Potochkin > ++ * @summary tests that JButton's text is not incorrectly truncated > ++ */ > ++import javax.swing.*; > ++import javax.swing.plaf.basic.BasicButtonUI; > ++import java.awt.*; > ++import java.awt.image.BufferedImage; > ++ > ++public class bug6797139 { > ++ > ++ private static void createGui() { > ++ JButton b = new JButton("Probably"); > ++ b.setUI(new BasicButtonUI() { > ++ protected void paintText(Graphics g, AbstractButton b, Rectangle textRect, String text) { > ++ super.paintText(g, b, textRect, text); > ++ if (text.endsWith("...")) { > ++ throw new RuntimeException("Text is truncated!"); > ++ } > ++ } > ++ }); > ++ b.setSize(b.getPreferredSize()); > ++ BufferedImage image = new BufferedImage(b.getWidth(), b.getHeight(), > ++ BufferedImage.TYPE_INT_ARGB); > ++ Graphics g = image.getGraphics(); > ++ b.paint(g); > ++ g.dispose(); > ++ } > ++ > ++ public static void main(String[] args) throws Exception { > ++ SwingUtilities.invokeAndWait(new Runnable() { > ++ public void run() { > ++ createGui(); > ++ } > ++ }); > ++ } > ++} > diff -r 6633b7a3a5db patches/openjdk/6883341-text_bearing_exception.patch > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/patches/openjdk/6883341-text_bearing_exception.patch Mon Jan 24 14:44:59 2011 -0500 > @@ -0,0 +1,89 @@ > +changeset: 1738:9d78c3d9def2 > +user: alexp > +date: Mon Sep 21 17:58:09 2009 +0400 > +summary: 6883341: SWAT: jdk7-b72 swat build(2009-09-17) threw exceptions when running Java2D demo by clicking Paint ta > + > +diff -r fa71ca7a3655 -r 9d78c3d9def2 src/share/classes/sun/swing/SwingUtilities2.java > +--- openjdk/jdk/src/share/classes/sun/swing/SwingUtilities2.java Mon Sep 21 01:26:57 2009 -0700 > ++++ openjdk/jdk/src/share/classes/sun/swing/SwingUtilities2.java Mon Sep 21 17:58:09 2009 +0400 > +@@ -250,15 +250,23 @@ > + * Returns the left side bearing of the first character of string. The > + * left side bearing is calculated from the passed in > + * FontMetrics. If the passed in String is less than one > +- * character, this will throw a StringIndexOutOfBoundsException exception. > ++ * character {@code 0} is returned. > + * > + * @param c JComponent that will display the string > + * @param fm FontMetrics used to measure the String width > + * @param string String to get the left side bearing for. > ++ * @throws NullPointerException if {@code string} is {@code null} > ++ * > ++ * @return the left side bearing of the first character of string > ++ * or {@code 0} if the string is empty > + */ > + public static int getLeftSideBearing(JComponent c, FontMetrics fm, > + String string) { > +- return getLeftSideBearing(c, fm, string.charAt(0)); > ++ int res = 0; > ++ if (!string.isEmpty()) { > ++ res = getLeftSideBearing(c, fm, string.charAt(0)); > ++ } > ++ return res; > + } > + > + /** > +diff -r fa71ca7a3655 -r 9d78c3d9def2 test/javax/swing/JMenuItem/6883341/bug6883341.java > +--- /dev/null Thu Jan 01 00:00:00 1970 +0000 > ++++ openjdk/jdk/test/javax/swing/JMenuItem/6883341/bug6883341.java Mon Sep 21 17:58:09 2009 +0400 > +@@ -0,0 +1,50 @@ > ++/* > ++ * Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved. > ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. > ++ * > ++ * This code is free software; you can redistribute it and/or modify it > ++ * under the terms of the GNU General Public License version 2 only, as > ++ * published by the Free Software Foundation. > ++ * > ++ * This code is distributed in the hope that it will be useful, but WITHOUT > ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or > ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License > ++ * version 2 for more details (a copy is included in the LICENSE file that > ++ * accompanied this code). > ++ * > ++ * You should have received a copy of the GNU General Public License version > ++ * 2 along with this work; if not, write to the Free Software Foundation, > ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. > ++ * > ++ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA > ++ * or visit www.oracle.com if you need additional information or have any > ++ * questions. > ++ */ > ++ > ++ /* > ++ * @test > ++ * @bug 6883341 > ++ * @summary Checks that menu items with no text don't throw an exception > ++ * @author Alexander Potochkin > ++ * @run main bug6883341 > ++ */ > ++ > ++import javax.swing.*; > ++ > ++public class bug6883341 { > ++ > ++ private static void createGui() { > ++ JPopupMenu menu = new JPopupMenu(); > ++ menu.add(new JMenuItem()); > ++ menu.setVisible(true); > ++ menu.setVisible(false); > ++ } > ++ > ++ public static void main(String[] args) throws Exception { > ++ SwingUtilities.invokeAndWait(new Runnable() { > ++ public void run() { > ++ bug6883341.createGui(); > ++ } > ++ }); > ++ } > ++} > + -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at redhat.com Mon Jan 24 12:58:03 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 24 Jan 2011 15:58:03 -0500 Subject: [icedtea-web] RFC: remove default.jnlp Message-ID: <4D3DE7DB.1030904@redhat.com> Hi, The attached patch removes default.jnlp from icedtea-web. This seems to be a copy of about.jnlp (About.jnlp gets invoked on javaws -about), but is completely unused. Ok to remove? Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: remove-default-jnlp.patch Type: text/x-patch Size: 848 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110124/d4ded0cb/remove-default-jnlp.patch From andrew at icedtea.classpath.org Mon Jan 24 13:02:40 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Mon, 24 Jan 2011 21:02:40 +0000 Subject: /hg/icedtea6: 3 new changesets Message-ID: changeset 6818a5e1f330 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=6818a5e1f330 author: Andrew John Hughes date: Mon Jan 24 20:55:14 2011 +0000 Update NEWS with b21 updates. 2011-01-22 Andrew John Hughes * NEWS: Update 1.10 with b21 changes. Remove changes in b21 from list of backports. changeset 75cceb14e80b in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=75cceb14e80b author: Andrew John Hughes date: Mon Jan 24 20:59:22 2011 +0000 Update NEWS with release announcements for 1.9.3, 1.7.7, 1.8.4 and 1.9.4. 2011-01-24 Andrew John Hughes * NEWS: Add 1.9.3, 1.9.4, 1.7.7 and 1.8.4 NEWS entries. changeset f4e6e86ca869 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=f4e6e86ca869 author: Andrew John Hughes date: Mon Jan 24 21:02:28 2011 +0000 Fix NEWS positioning and naming of RH661505 JPEG fix. 2011-01-24 Andrew John Hughes * patches/661505-jpeg.patch: Move to... * Makefile.am: Add rh prefix to jpeg fix. * NEWS: Move jpeg fix to Bug Fixes as not a backport. * patches/rh661505-jpeg.patch: ... here. diffstat: 5 files changed, 473 insertions(+), 57 deletions(-) ChangeLog | 20 + Makefile.am | 2 NEWS | 476 +++++++++++++++++++++++++++++++++++++++---- patches/661505-jpeg.patch | 16 - patches/rh661505-jpeg.patch | 16 + diffs (truncated from 577 to 500 lines): diff -r 6633b7a3a5db -r f4e6e86ca869 ChangeLog --- a/ChangeLog Sat Jan 22 21:47:34 2011 +0100 +++ b/ChangeLog Mon Jan 24 21:02:28 2011 +0000 @@ -1,3 +1,23 @@ 2010-01-22 Mark Wielaard + + * patches/661505-jpeg.patch: + Move to... + * Makefile.am: Add rh prefix to jpeg fix. + * NEWS: Move jpeg fix to Bug Fixes as not + a backport. + * patches/rh661505-jpeg.patch: + ... here. + +2011-01-24 Andrew John Hughes + + * NEWS: Add 1.9.3, 1.9.4, 1.7.7 and 1.8.4 + NEWS entries. + +2011-01-24 Andrew John Hughes + + * NEWS: Update 1.10 with b21 changes. + Remove changes in b21 from list of backports. + 2010-01-22 Mark Wielaard * configure.ac: Add xvfb-run AC_CHECK_PROG. diff -r 6633b7a3a5db -r f4e6e86ca869 Makefile.am --- a/Makefile.am Sat Jan 22 21:47:34 2011 +0100 +++ b/Makefile.am Mon Jan 24 21:02:28 2011 +0000 @@ -270,7 +270,7 @@ ICEDTEA_PATCHES = \ patches/jtreg-6929067-fix.patch \ patches/rendering-engine-tests.patch \ patches/openjdk/6800846-printing-quality.patch \ - patches/661505-jpeg.patch \ + patches/rh661505-jpeg.patch \ patches/6703377-freetypescaler.patch \ patches/ia64-fix.patch \ patches/openjdk/6642612-filechooser_button_sizes.patch \ diff -r 6633b7a3a5db -r f4e6e86ca869 NEWS --- a/NEWS Sat Jan 22 21:47:34 2011 +0100 +++ b/NEWS Mon Jan 24 21:02:28 2011 +0000 @@ -8,58 +8,454 @@ GX - http://bugs.gentoo.org/show_bug.cg CVE-XXXX-YYYY: http://www.cve.mitre.org/cgi-bin/cvename.cgi?name=XXXX-YYYY -New in release 1.10 (2010-XX-XX): +New in release 1.10 (2011-XX-XX): -* Upgrade to HotSpot 19 as default. * NetX and the plugin moved to the IcedTea-Web project with a separate release cycle. * Shark provided upstream rather than as part of IcedTea. * The option --with-openjdk becomes --with-jdk-home and --disable-bootstrap +* Import of OpenJDK6 b21 including upgrade to HotSpot 19 + - S6961870: More rebranding fixes for templates/gpl-*-header files + - S6976186: Shark build system changes + - S6962318: Update copyright year + - S7008723: Remove binary plugs creation and use from openjdk + - S6962318: Update copyright year + - S6891766: Vulnerabilities in use of reflection in CORBA + - S6962318: Update copyright year + - S7008723: Remove binary plugs creation and use from openjdk + - S6962318: Update copyright year + - S6962193: Rebrand some Zero files + - S6980711: HotSpot assembler_sparc changes needed for GNU/Linux on SPARC build + - S6910182: CMS: assert(_cursor[j] == _survivor_plab_array[j].end(),"Ctl pt invariant") + - S6914050: jvm assertion "guard pages must be in use" in -Xcomp mode + - S6933402: RFE: Improve PrintSafepointStatistics output to track cleanup time + - S6932536: JSR 292 modified JDK MethodHandlesTest fails on x86_64 + - S6932270: Allow Java's ELF symtab reader to use separate debuginfo files + - S6919934: JSR 292 needs to support x86 C1 + - S6932496: c1: deoptimization of jsr subroutine fails on sparcv9 + - S6934089: Zero 32-bit/64kb page fix + - S6934494: JSR 292 MethodHandles adapters should be generated into their own CodeBlob + - S6935466: new CodeCache flushing code is not guarded by the flag + - S6934966: JSR 292 add C1 logic for saved SP over MethodHandle calls + - S6935535: String.indexOf() returns incorrect result on x86 with SSE4.2 + - S6930043: C2: SIGSEGV in javasoft.sqe.tests.lang.arr017.arr01702.arr01702.loop_forw(II)I + - S6932091: JSR 292 x86 code cleanup + - S4396719: Mark Sweep stack overflow on deeply nested Object arrays + - S6755988: G1: assert(new_obj != 0 || ... "should be forwarded") + - S6921710: G1: assert(new_finger >= _finger && new_finger < _region_limit,"invariant") + - S6935839: excessive marking stack growth during full gcs + - S6935821: G1: threads created during marking do not active their SATB queues + - S6936366: Fork HS17 to HS18 - renumber Major and build numbers of JVM + - S6940419: Bump the HS18 build number to 02 + - S6929067: Stack guard pages should be removed when thread is detached + - S6934758: Expose the break down of clean up task time during safepoint. + - S6923488: 4/4 need minor tweaks to HotSpot build for Cygwin + - S6935224: Adding new DTrace probes to work with Palantir + - S6936168: Recent fix for unmapping stack guard pages doesn't close /proc/self/maps + - S6938185: 3/4 6923488 breaks Windows command shell builds + - S6926979: should simplify catch_inline_exception + - S6939180: Zero locking fix + - S6939731: JSR 292 Zero build fix after 6934494 + - S6939845: zero needs fallback path in C++ interpreter for platform dependent fast bytecodes + - S6936709: AsyncGetCallTrace doesn't handle inexact stack walking properly + - S6939804: ciConstant::print() prints incorrect bool value + - S6892265: System.arraycopy unable to reference elements beyond Integer.MAX_VALUE bytes + - S6894807: No ClassCastException for HashAttributeSet constructors if run with -Xcomp + - S6626217: Fixed loader constraint array handling + - S6932480: Fix crash in CompilerThread/Parser. Unloaded array klass? + - S6938627: Make temporary directory use property java.io.tmpdir when specified + - S6937160: G1: should observe GCTimeRatio + - S6677708: G1: re-enable parallel RSet updating and scanning + - S6940310: G1: MT-unsafe calls to CM::region_stack_push() / CM::region_stack_pop() + - S6909756: G1: guarantee(G1CollectedHeap::heap()->mark_in_progress(),"Precondition.") + - S6940894: G1: assert(new_obj != 0 || ... "should be forwarded") for compaction tests + - S6940520: CodeCache::scavenge_root_nmethods_do must fix oop relocations + - S6940677: Use 64 bytes chunk copy for arraycopy on Sparc + - S6940701: Don't align loops in stubs for Niagara sparc + - S6940733: allocate non static oop fields in super and sub classes together + - S6940726: Use BIS instruction for allocation prefetch on Sparc + - S6941529: SharedRuntime::raw_exception_handler_for_return_address must reset thread MethodHandle flag + - S6942223: c1 64 bit fixes + - S6944398: Bump the HS18 build number to 03 + - S6938026: C2 compiler fails in Node::rematerialize()const + - S6939930: exception unwind changes in 6919934 hurts compilation speed + - S6941224: Improved stack overflow handling for Zero + - S6944028: 6940701 broke Zero + - S6944473: 6941224 misses new files + - S6944503: Improved Zero crash dump + - S6945219: minor SA fixes + - S6858496: Clear all SoftReferences before an out-of-memory due to GC overhead limit. + - S6937142: G1: improvements to debugging output (S-M) + - S6943926: G1: Integer overflow during heap region verification + - S6939027: G1: assertion failure during the concurrent phase of cleanup + - S6942253: G1: replace G1ParallelGCAllocBufferSize with YoungPLABSize and OldPLABSize + - S6897143: Stress test crashes during HeapInspection using ParallelGC. + - S6819061: G1: eliminate serial Other times that are proportional to the collection set length + - S6871109: G1: remove the concept of the scan only prefix + - S6946040: add intrinsic for short and char reverseBytes + - S6943485: JVMTI always on capabilities change code generation too much + - S6946892: c1 shouldn't sign-extend to upper 32bits on x64 + - S6946056: assert((intptr_t) sp()<=(intptr_t) result,"result must>=than stack pointer"), frame_x86.cpp:295 + - S6888953: some calls to function-like macros are missing semicolons + - S6888954: argument formatting for assert() and friends + - S6948636: Bump the HS18 build number to 04 + - S6950438: Add 6u18 and 6u20 release values explicitly to jprt.properties file + - S6951190: assert(!klass_is_exact(),"only non-exact klass") while building JDK + - S6944822: Fix for 6938627 exposes problem with hard-coded buffer sizes + - S6935118: UseCompressedOops modification in methodOopDesc::sort_methods() causes JCK timeout + - S6949118: jvm.dll shows the company name as Sun Microsystems + - S6829193: JSR 292 needs to support SPARC + - S6948602: Disable use of SSE4.2 in String.indexOf intrinsic until 6942326 is fixed + - S6939182: Zero JNI handles fix + - S6943304: remove tagged stack interpreter + - S6939134: JSR 292 adjustments to method handle invocation + - S6939196: method handle signatures off the boot class path get linkage errors + - S6949423: remove tagged stack interpreter for Zero + - S6949830: 6939134 broke Zero + - S6950178: Zero stack improvements + - S6950617: Zero/Shark interface updates + - S6951784: Zero deoptimizer changes + - S6948537: CMS: BOT walkers observe out-of-thin-air zeros on sun4v sparc/CMT + - S6919638: CMS: ExplicitGCInvokesConcurrent misinteracts with gc locker + - S6951188: CMS: move PromotionInfo into its own file + - S6951923: some uses of fatal1 were missed by 6888954 + - S6931180: Migration to recent versions of MS Platform SDK + - S6951582: Build problems on win64 + - S6952178: Fork HS18 to HS19 - renumber Major and build numbers of JVM + - S6745217: jmap assertion failure + - S6951686: Using large pages on Linux prevents zero based compressed oops + - S6950075: nmethod sweeper should operate concurrently + - S6953267: assert in EA code with -XX:+StressReflectiveCode + - S6953539: after 6892658 c1 reports that it doesn't inline StringBuffer.append + - S6953576: bottom_type for matched AddPNodes doesn't always agree with ideal + - S6937111: Restore optimization for Phi of AddP (6552204) + - S6921317: (partial) G1: assert(top() == bottom() || zfs == Allocated,"Region must be empty, or we must be setting it to + - S6948539: CMS+UseCompressedOops: placement of cms_free bit interferes with promoted object link + - S6951319: enable solaris builds using Sun Studio 12 update 1 + - S6953483: Typo related to ReduceInitialCardMarks leaves concurrent collectors vulnerable to heap corruption + - S6953952: collectedHeap.cpp should use #ifdef _LP64 not LP64 + - S6911922: JVM must throw VerifyError for jsr or jsr_w opcodes in class file v.51+ + - S6693236: A class file whose version number is greater than to 50.0 must be verified using the typechecker + - S6953588: hotspot\src\share\vm\interpreter\bytecodes.cpp doesn't compile with VS2010 on AMD64 + - S6956513: Bump the HS19 build number to 02 + - S6941466: Oracle rebranding changes for Hotspot repositories + - S6951083: oops and relocations should part of nmethod not CodeBlob + - S6930772: JSR 292 needs to support SPARC C1 + - S6939207: refactor constant pool index processing + - S6934104: JSR 292 needs to support SPARC C2 + - S6490487: java support on 64 bit solaris x86 machines is broken. + - S6956164: nightly regressions from 6939207 + - S6916623: Align object to 16 bytes to use Compressed Oops with java heap up to 64Gb + - S6955349: C1: Make G1 barriers work with x64 + - S6957004: MethodComparator uses the wrong CP index accessor + - S6957080: MethodComparator needs stress testing + - S6954029: Improve implicit null check generation with compressed oops + - S6957882: nsk/sajdi tests failed with NullPointerException + - S6956931: assert(SafepointSynchronize::is_at_safepoint()) failed: must be executed at a safepoint + - S6930994: Code cache is full warning should be visible in product + - S6958254: -XX:+VerifyOops is broken on x86 + - S6958292: C1: Enable parallel compilation + - S6958485: fix for 6879921 was insufficient + - S6930553: classfile format checker allows invalid method descriptor in CONSTANT_NameAndType_info in some cases + - S6852873: Reduce safepoint cleanup time + - S6941378: G1: change default value of G1UseFixedWindowMMUTracker to true + - S6956472: test/runtime/6888954/vmerrors.sh uses ksh-specific syntax + - S6953058: G1: A bigapp crashes with SIGSEGV in compiled code + - S6939203: JSR 292 needs method handle constants + - S6730276: JDI_REGRESSION tests fail with "Error: count must be non-zero" error on x86 + - S6960865: ldc of unloaded class throws an assert in ciTypeFlow + - S6960550: Missing semicolon in Zero + - S6952176: Remove debug flag from adlc makefile for 6Update trains + - S6959430: Make sure raw loads have control edge + - S6949307: G1: raise a vm error, do not core dump, if target pause time and target interval are inconsistent + - S6946048: G1: improvements to +PrintGCDetails output + - S6952853: SIGSEGV with UseAdaptiveGCBoundary on 64b linux running jvm2008 + - S6956958: assert(is_clean() || is_call_to_compiled() || is_call_to_interpreted() || is_optimized() || is_megam + - S6656830: assert((*p)->is_oop(),"expected an oop while scanning weak refs") + - S6962980: C1: stub area should take into account method handle deopt stub + - S6947341: JVM Crash running Oracle ATG CRMDemo + - S6964479: widen normalization of small int and long values should be symmetric + - S6677629: PhaseIterGVN::subsume_node() should call hash_delete() and add_users_to_worklist() + - S6964774: Adjust optimization flags setting + - S6939019: Source code adjustments for parfait compilation of hotspot + - S6888573: class data sharing does not always disable large pages + - S6965671: fatal error: acquiring lock JNIGlobalHandle_lock/16 out of order with lock CodeCache_lock/1 + - S6966411: escape.cpp:450 assert(base->Opcode() == Op_ConP + - S6957084: simplify TaskQueue overflow handling + - S6964164: MonitorInUseLists leak of contended objects + - S6967423: Hotspot support for modules image + - S6965184: possible races in make_not_entrant_or_zombie + - S6958668: repeated uncommon trapping for new of klass which is being initialized + - S6968385: malformed xml in sweeper logging + - S6968646: JVM crashes with SIGFPE during startup + - S6968368: SIGSEGV in the BCEscapeAnalyzer::copy_dependencies + - S6968336: VM crash guarantee(!nm->is_zombie()) failed: cannot lock a zombie method + - S6958458: Bump the HS19 build number to 03 + - S6961079: Build JDK7 for 64 bit Windows using free Windows 7.1 SDK 64 bit compilers + - S6964882: 32 bit JDK does not build on 64 bit Windows platforms + - S6966252: Bump the HS19 build number to 04 + - S6962569: assembler_sparc.cpp:1969: assert(false) failed: error + - S6944166: G1: explicit GCs are not always handled correctly + - S6964498: JSR 292 invokedynamic sites need local bootstrap methods + - S6969574: invokedynamic call sites deoptimize instead of executing + - S6970566: runThese fails with SIGSEGV + - S6962947: shared TaskQueue statistics + - S6956639: G1: assert(cached_ptr != card_ptr) failed: shouldn't be, concurrentG1Refine.cpp:307 + - S6649594: Intermittent IOExceptions during dynamic attach on linux and solaris + - S6964170: Verifier crashes + - S6888526: Linux getCurrentThreadCpuTime is drastically slower than Windows + - S6958465: Sparc aten build24.0: openjdk-7.ea-b96 failed Error: Formal argument ... requires an lvalue + - S6953477: Increase portability and flexibility of building Hotspot + - S6969569: assert(is_static() && is_constant()) failed: illegal call to constant_value() + - S6973308: Missing zero length check before repne scas in check_klass_subtype_slow_path() + - S6973963: SEGV in ciBlock::start_bci() with EA + - S6974682: CTW: assert(target != NULL) failed: must not be null + - S6975049: nsk/regression/b4287029 crashes with -Xss64 on solaris-i586 + - S6975078: assert(allocated_on_res_area() || allocated_on_C_heap() || allocated_on_arena() + - S6975027: use of movptr to set length of array + - S6975855: don't emit deopt MH handler in C1 if not required + - S6976186: integrate Shark HotSpot changes + - S6973329: C2 with Zero based COOP produces code with broken anti-dependency on x86 + - S6378314: Bad warning message when agent library not found. local directory is not searched. + - S6581734: CMS Old Gen's collection usage is zero after GC which is incorrect + - S6814437: G1: remove the _new_refs array + - S6962589: remove breadth first scanning code from parallel gc + - S6963209: G1: remove the concept of abandoned pauses + - S6930581: G1: assert(ParallelGCThreads > 1 || n_yielded() == _hrrs->occupied(),"Should have yielded all the .. + - S6966222: G1: simplify TaskQueue overflow handling + - S6970376: ParNew: shared TaskQueue statistics + - S6973570: OrderAccess::storestore() scales poorly on multi-socket x64 and sparc: cache-line ping-ponging + - S6976378: ParNew: stats are printed unconditionally in debug builds + - S6973381: Bump the HS19 build number to 05 + - S6977051: Bump the HS19 build number to 06 + - S6977952: Test: Sync missing tests from hs16.3 to hs17.x + - S6948538: CMS: BOT walkers can fall into object allocation and initialization cracks + - S6959014: G1: assert(minimum_desired_capacity <= maximum_desired_capacity) failed: sanity check + - S6974928: G1: sometimes humongous objects are allocated in young regions + - S6975964: G1: print out a more descriptive message for evacuation failure when +PrintGCDetails is set + - S6977970: CMS: concurrentMarkSweepGeneration.cpp:7947 assert(addr <= _limit) failed: sweep invariant + - S6977924: Changes for 6975078 produce build error with certain gcc versions + - S6978726: Bump the HS19 build number to 07 + - S6974176: ShouldNotReachHere, instanceKlass.cpp:1426 + - S6975006: assert(check.is_deoptimized_frame()) failed: missed deopt + - S6976372: # assert(_owner == Thread::current()) failed: invariant + - S6977640: Zero and Shark fixes + - S6978249: spill between cpu and fpu registers when those moves are fast + - S6978533: CMS: Elide BOT update asserts until 6977974 is fixed correctly + - S6978889: Remove premature change of build number to Hotspot 19 Build 07 + - S6978915: Remove Mercurial tags for Hotspot 19 Build 06 + - S6987149: Fix incorrect Oracle copyright header in make/templates files + - S4809552: Optimize Arrays.fill(...) + - S6976400: "Meet Not Symmetric" + - S6980978: assert(mt == t->xmeet(this)) failed: meet not commutative + - S6981431: IdealKit should support I_O projections + - S6969586: OptimizeStringConcat: SIGSEGV in LoadNode::Value() + - S6980262: Memory leak when exception is thrown in static initializer + - S6981773: incorrect fill value with OptimizeFill + - S6896381: CTW fails share/vm/ci/bcEscapeAnalyzer.cpp:99, assert(_stack_height < _max_stack,"stack overflow") + - S6978641: Fix for 6929067 introduces additional overhead in thread creation/termination paths + - S6982370: SIGBUS in jbyte_fill + - S6982488: Bump the HS19 build number to 07 for 6Updates + - S6982533: Crash in ~StubRoutines::jbyte_fill with AggressiveOpts enabled + - S6983013: Change the HS_MINOR version to 6 for the 6Update train + - S6984346: Remove development code in type.hpp + - S6984368: Large default heap size does not allow to use zero based compressed oops + - S6942092: Loader-constraint test is failing + - S6984979: OptimizeFill misses some cases with an odd memory graph + - S6975210: java.lang.VerifyError in some of JCK tests + - S6985396: Bump the HS19 build number to 08 + - S6982489: Update Hotspot 19 to use jdk6u21p as the default JPRT release target + - S6423256: GC stacks should use a better data structure + - S6942771: SEGV in ParScanThreadState::take_from_overflow_stack + - S6982537: Crash in Node*step_through_mergemem + - S6986028: assert(_base == Int) failed: Not an Int in CmpINode::sub + - S6916062: assert(_inserts <= _insert_limit,"hash table overflow") in NodeHash::hash_insert + - S6988678: fatal error deadlock handling was unintentionally disabled + - S6965815: OptimizeStringConcat: assert(!q->is_MergeMem()) failed with specjbb2000 + - S6988018: dtrace/hotspot/MethodInvocation/MethodInvocation002 crashes with client compiler + - S6966589: hs16-b08 causes java.lang.StackOverflowError + - S6990124: supplemental fix for 6361589 + - S6980792: Crash "exception happened outside interpreter, nmethods and vtable stubs (1)" + - S6990756: Bump the HS19 build number to 09 + - S6994130: Zero PowerPC fix + - S7002666: eclipse CDT projects crash with compressed oops + - S6980392: TEST_BUG: gc/6581734/Test6581734.java has typo + - S7009828: Fix for 6938627 breaks visualvm monitoring when -Djava.io.tmpdir is defined + - S6960333: Add make level ALLOW_DOWNLOADS=true option + - S6981408: Upgrade jaxp to 1.4.4 + - S7002248: Update urls for jaxp and jaxws source downloads + - S6962318: Update copyright year + - S7008723: Remove binary plugs creation and use from openjdk + - S6962318: Update copyright year + - S6960333: Add make level ALLOW_DOWNLOADS=true option + - S7002248: Update urls for jaxp and jaxws source downloads + - S6962318: Update copyright year + - S7008723: Remove binary plugs creation and use from openjdk + - S6962318: Update copyright year + - S6948909: Jarsigner removes MANIFEST.MF info for badly packages jar's + - S6954621: small error in 6948909 fix + - S6961732: FontMetrics.getLeading() may be negative in freetype-based OpenJDK builds. + - S6939022: Source code adjustments for parfait compilation + - S6933622: Duplicate class files in rt.jar and charsets.jar + - S6895003: JarReorder is not excluding a requested file. + - S6942989: 2/2 Memory leak of java.lang.ref.WeakReference objects + - S4356282, RH525870: RFE: T2K should be used to rasterize CID/CFF fonts + - S6687968: PNGImageReader leaks native memory through an Inflater. + - S6969395: TEST_BUG: Tests in java/net sun/net problems + - S6941287: 4/4 jrunscriptTest.sh test does not work right under Cygwin + - S6962804: 4/4 ShellScaffold tests can fail without a specific reason + - S6964018: 3/4 AnonLoggerWeakRefLeak and LoggerWeakRefLeak can fail in JPRT + - S6971847: 4/4 jmap '-histo:live' option is necessary for proper leak detection + - S6795060: VM crash on Linux in ICU layout library when processing \u0DDD (Sinhalese) + - S6954424: Support OpenType/CFF fonts in JDK 7 + - S6918573: sun.security.pkcs11.P11RSACipher.finalize() is a scalability blocker + - S6591117: Poor preformance of PKCS#11 security provider compared to Sun default provider + - S6837847: PKCS#11 A SecureRandom and a serialization error following installation of 1.5.0_18 + - S6695485: SignedObject constructor throws ProviderException if it's called using provider "SunPKCS11-Solaris" + - S6678385: Random java.lang.StackOverflowError from various JDKs + - S6438179: XToolkit.isTraySupported() result has nothing to do with the system tray + - S6633613: (str) StringCoding optimizations to avoid unnecessary array copies with Charset arg + - S6675802: Regression: heavyweight popups cause SecurityExceptions in applets + - S6691503: Malicious applet can show always-on-top popup menu which has whole screen size + - S6632959: swing html parser doesn't know € or › + - S6721088: Bad window size calculation after using pack() + - S6949710: 3/3 the GC'able nature of Logging objects needs to be made brutally clear + - S6623943: javax.swing.TimerQueue's thread occasionally fails to start + - S6976186: Shark build system changes + - S6914943: Implement final TLS renegotiation fix + - S6957564: Disclosure of DNS server IP address + - S6958060: Malformed AP-REQ crashes acceptor side + - S6925710: IndexColorModel.finalize can be made to double free + - S6963285: Crash in ICU Opentype layout engine due to mismatch in character counts + - S6963023: ZDI-CAN-809: Sun JRE JPEGImageWriter.writeImage Remote Code Execution Vulnerability + - S6926623: Thread clone issues + - S6963489: ZDI-CAN-803: Sun JRE ICC Profile Device Information Tag Remote Code Execution Vulnerability + - S6952603: NetworkInterface reveals local network address to untrusted code + - S6952017: HttpURLConnection chunked encoding issue (Http request splitting) + - S6974093: Thread.clone should NOT invoke addUnstarted on started threads + - S6980004: limit HTTP request cookie headers in HttpURLConnection + - S6961084: limit setting of some request headers in HttpURLConnection + - S6981426: limit use of TRACE method in HttpURLConnection + - S6622002: UIDefault.ProxyLazyValue has unsafe reflection usage + - S6559775: Race allows defaultReadObject to be invoked instead of readFields during deserialization + - S6966692: defaultReadObject can set a field multiple times + - S6990437: Update with correct copyright info for source and test files from SSR10_02 fixes + - S6993206: Removing non-functional tests. + - S6979979, RH508185: Rounding error in font sizes selected by the GTK Look and Feel + - S6795356, PR590: Leak caused by javax.swing.UIDefaults.ProxyLazyValue.acc + - S6853592: VM test nsk.regression.b4261880 fails with "X Error of failed request: BadWindow" inconsistently. + - S6950553: Applet: IE process crash in OLE32.DLL when playing a sound + - S6622432: RFE: Performance improvements to java.math.BigDecimal + - S6850606: Regression from JDK 1.6.0_12 + - S6876282: BigDecimal's divide(BigDecimal bd, RoundingFormat r) produces incorrect result + - S6963720: typo in ServerHandshaker.java + - S6962318: Update copyright year + - S7008723: Remove binary plugs creation and use from openjdk + - S6962318: Update copyright year + - S6941936: Broken pipe error of test case DNSIdentities.java + - S6943219: test/sun/security/ssl/sun/net/www/protocol/https/HttpsURLConnection/DNSIdentities.java fail in linux + - S6560348: PIT : java/awt/xembed/server/RunTestXEmbed.java fails + - S6668231: Presence of a critical subjectAltName causes JSSE's SunX509 to fail trusted checks + - S6963870: NPE in CompoundBorder.getInsets() + - S6541476: PNG imageio plugin incorrectly handles iTXt chunk + - S6782079: PNG: reading metadata may cause OOM on truncated images. + - S6877961: langtools build should allow more options when running jtreg + - S6724551: Use Queues instead of Lists to link compiler phases + - S6726015: JavaCompiler: replace desugarLater by compileStates + - S6734819: Javac performs flows analysis on already translated classes + - S6956638: JavacTask.generate does not generate all required files + - S6724327: eliminate use of shell tests for simple golden file tests + - S6962540: langtools Makefile sets DEV_NULL incorrectly + - S6420151: need to improve byfile compile policy to eliminate footprint issues + - S6813059: replace use of JavaCompiler.errorCount with shouldContinue + - S6595666: fix -Werror + - S6795365: NetBeans projects in langtools repository are not NB6.5-friendly + - S6962236: backport JavacFileManager fixes from 7 to 6-open + - S6410637: Make decision on deprecated methods in DefaultFileManager and BaseFileObject. + - S6419701: DefaultFileManager clean up: URI.create + - S6483788: DefaultFileManager.ZipFileObject.toUri() fails to escape space characters + - S6501502: JSR 199: FileObject.toUri should return file:///c:/ or file:/c:/ not file://c:/ + - S6508981: cleanup file separator handling in JavacFileManager + - S6625520: javac handles missing entries on classpath badly + - S6705935: javac reports path name of entry in ZipFileIndex incorectly + - S6705945: com.sun.tools.javac.zip files do not have valid copyright + - S6714364: refactor javac File handling code into new javac.file package + - S6714365: refactor JavacFileManager to move nested classes to top level + - S6743107: clean up use of static caches in file manager + - S6794582: javadoc should read files using a FileManager + - S6832154: refactor Paths to be just a utility class for JavacFileManager + - S6838467: JSR199 FileObjects don't obey general contract of equals. + - S6877206: JavaFileObject.toUri returns bogus URI (win) + - S6877223: tests @ignored because of issues with File.toURI on Windows + - S6885123: JavaFileObject getName issues + - S6907660: stupid typo in ZipFileIndex guarantees NPE + - S6930076: "null" can incorrectly appear in error message compiler.err.error.reading.file + - S6889255: javac MethodSymbol throws NPE if ClassReader does not read parameter names correctly + - S7008723: Remove binary plugs creation and use from openjdk + - S6962318: Update copyright year + - S7008433: Minor copyright changes +* Backports + - S6800846, RH662230: Printing quality degraded with Java 6 compared to 5.0, index out of bounds exception. + - S6642612: JFileChooser's approve buttons should be the same size (GTK) +* Bug fixes + - RH647157, RH582455: Update fontconfig files for rhel 6 + - RH661505: JPEGs with sRGB IEC61966-2.1 color profiles have wrong colors + +New in release 1.9.4 (2011-01-18): + * Security updates - - S6914943, CVE-2009-3555: TLS: MITM attacks via session renegotiation - - S6559775, CVE-2010-3568: OpenJDK Deserialization Race condition - - S6891766, CVE-2010-3554: OpenJDK corba reflection vulnerabilities - - S6925710, CVE-2010-3562: OpenJDK IndexColorModel double-free - - S6938813, CVE-2010-3557: OpenJDK Swing mutable static - - S6957564, CVE-2010-3548: OpenJDK DNS server IP address information leak - - S6958060, CVE-2010-3564: OpenJDK kerberos vulnerability - - S6963023, CVE-2010-3565: OpenJDK JPEG writeImage remote code execution - - S6963489, CVE-2010-3566: OpenJDK ICC Profile remote code execution - - S6966692, CVE-2010-3569: OpenJDK Serialization inconsistencies - - S6622002, CVE-2010-3553: UIDefault.ProxyLazyValue has unsafe reflection usage - - S6623943: javax.swing.TimerQueue's thread occasionally fails to start - - S6925672, CVE-2010-3561: Privileged ServerSocket.accept allows receiving connections from any host - - S6952017, CVE-2010-3549: HttpURLConnection chunked encoding issue (Http request splitting) - - S6952603, CVE-2010-3551: NetworkInterface reveals local network address to untrusted code - - S6961084, CVE-2010-3541: limit setting of some request headers in HttpURLConnection - - S6963285, CVE-2010-3567: Crash in ICU Opentype layout engine due to mismatch in character counts - - S6980004, CVE-2010-3573: limit HTTP request cookie headers in HttpURLConnection - - S6981426, CVE-2010-3574: limit use of TRACE method in HttpURLConnection - - S6990437: Update with correct copyright info for source and test files from SSR10_02 fixes + - RH663680, CVE-2010-4351: IcedTea JNLP SecurityManager bypass * Backports - - S4356282, RH525870: RFE: T2K should be used to rasterize CID/CFF fonts - - S6954424: Support OpenType/CFF fonts in JDK 7 - - S6438179: XToolkit.isTraySupported() result has nothing to do with the system tray - - S6638712: Inference with wildcard types causes selection of inapplicable method - - S6650759: Inference of formal type parameter (unused in formal parameters) is not performed - - S6991430, PR579: Zero PowerPC fix. + - S4356282: RFE: JDK should support OpenType/CFF fonts + - S6954424, RH525870: Support OpenType/CFF fonts in JDK 7 + - S6795356, PR590: Leak caused by javax.swing.UIDefaults.ProxyLazyValue.acc - S6967436, RH597227: lines longer than 2^15 can fill window. - S6967433: dashed lines broken when using scaling transforms. - S6976265: No STROKE_CONTROL - S6967434, PR450, RH530642: Round joins/caps of scaled up lines have poor quality. + - S6438179, RH569121: XToolkit.isTraySupported() result has nothing to do with the system tray +* Fixes + - S7003777, RH647674: JTextPane produces incorrect content after parsing the html text + +New in release 1.8.4 (2011-01-18): + +* Security updates + - RH663680, CVE-2010-4351: IcedTea JNLP SecurityManager bypass +* Backports + - S6438179, RH569121: XToolkit.isTraySupported() result has nothing to do with the system tray + - S4356282: RFE: JDK should support OpenType/CFF fonts + - S6954424, RH525870: Support OpenType/CFF fonts in JDK 7 + - S6795356, PR590: Leak caused by javax.swing.UIDefaults.ProxyLazyValue.acc + - S6967436, RH597227: lines longer than 2^15 can fill window. + - S6967433: dashed lines broken when using scaling transforms. + - S6976265: No STROKE_CONTROL + - S6967434, PR450, RH530642: Round joins/caps of scaled up lines have poor quality. +* Fixes: + - S7003777, RH647674: JTextPane produces incorrect content after parsing the html text + +New in release 1.7.7 (2011-01-18): From andrew at icedtea.classpath.org Mon Jan 24 13:10:03 2011 From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org) Date: Mon, 24 Jan 2011 21:10:03 +0000 Subject: /hg/icedtea6: Add unlisted backports. Message-ID: changeset 7f4514093373 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=7f4514093373 author: Andrew John Hughes date: Mon Jan 24 21:09:58 2011 +0000 Add unlisted backports. 2011-01-24 Andrew John Hughes * NEWS: Add unlisted backports. diffstat: 2 files changed, 7 insertions(+) ChangeLog | 4 ++++ NEWS | 3 +++ diffs (31 lines): diff -r f4e6e86ca869 -r 7f4514093373 ChangeLog --- a/ChangeLog Mon Jan 24 21:02:28 2011 +0000 +++ b/ChangeLog Mon Jan 24 21:09:58 2011 +0000 @@ -1,3 +1,7 @@ 2011-01-24 Andrew John Hughes + + * NEWS: Add unlisted backports. + 2011-01-24 Andrew John Hughes * patches/661505-jpeg.patch: diff -r f4e6e86ca869 -r 7f4514093373 NEWS --- a/NEWS Mon Jan 24 21:02:28 2011 +0000 +++ b/NEWS Mon Jan 24 21:09:58 2011 +0000 @@ -397,6 +397,8 @@ New in release 1.10 (2011-XX-XX): * Backports - S6800846, RH662230: Printing quality degraded with Java 6 compared to 5.0, index out of bounds exception. - S6642612: JFileChooser's approve buttons should be the same size (GTK) + - S6984543: Test sun/java2d/DirectX/OnScreenRenderingResizeTest fails on GNOME + - S6997495: correction of regression test compiler/6857159/Test6857159 * Bug fixes - RH647157, RH582455: Update fontconfig files for rhel 6 - RH661505: JPEGs with sRGB IEC61966-2.1 color profiles have wrong colors @@ -1711,6 +1713,7 @@ New in release 1.9 (2010-09-07): - S6969395: Synchronization of HttpServlet regression test with OpenJDK7 - S6510892: com/sun/net/httpserver/bugs/B6361557.java fails - S6307603: [X11] Use RENDER extension for complex operations done in software + - S6961633: gui applications cause a jvm crash on windows - S6668231: Presence of a critical subjectAltName causes JSSE's SunX509 to fail trusted checks - S6678385: Random java.lang.StackOverflowError from various JDKs - S6725214: D3D: forward-port the new pipeline from 6u10 From ahughes at redhat.com Mon Jan 24 13:25:04 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Mon, 24 Jan 2011 21:25:04 +0000 Subject: [icedtea-web] RFC: remove default.jnlp In-Reply-To: <4D3DE7DB.1030904@redhat.com> References: <4D3DE7DB.1030904@redhat.com> Message-ID: <20110124212504.GI17602@rivendell.middle-earth.co.uk> On 15:58 Mon 24 Jan , Omair Majid wrote: > Hi, > > The attached patch removes default.jnlp from icedtea-web. This seems to > be a copy of about.jnlp (About.jnlp gets invoked on javaws -about), but > is completely unused. Ok to remove? > > Cheers, > Omair Does the name have any special significance? Have you checked it isn't loaded or something if you don't specify a JNLP file? On the subject of about.jnlp, can someone please update it so recent work is credited? It currently gives all credit to Jon Maxwell and Joshua Sumali. > diff -r 925f97c584a8 netx/net/sourceforge/jnlp/resources/default.jnlp > --- a/netx/net/sourceforge/jnlp/resources/default.jnlp Tue Jan 18 12:07:45 2011 -0500 > +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 > @@ -1,20 +0,0 @@ > - > - > - > - About window for NetX > - NetX > - > - Displays information about NetX > - > - > - > - > - > - > - > - > - > - > - > - > - -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at icedtea.classpath.org Mon Jan 24 13:31:53 2011 From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org) Date: Mon, 24 Jan 2011 21:31:53 +0000 Subject: /hg/icedtea6: Backport S6736649, S6797139 and S6883341 to fix te... Message-ID: changeset c78edcdba40f in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=c78edcdba40f author: Omair Majid date: Mon Jan 24 16:30:51 2011 -0500 Backport S6736649, S6797139 and S6883341 to fix text being truncated in some swing controls 2011-01-24 Omair Majid NEWS: Update with the 3 backports * Makefile.am (ICEDTEA_PATCHES): Add the patches * patches/openjdk/6736649-text_bearings.patch: New file. * patches/openjdk/6797139-jbutton_truncation.patch: Likewise. * patches/openjdk/6883341-text_bearing_exception.patch: Likewise. diffstat: 6 files changed, 829 insertions(+), 1 deletion(-) ChangeLog | 8 Makefile.am | 5 NEWS | 3 patches/openjdk/6736649-text_bearings.patch | 112 +++ patches/openjdk/6797139-jbutton_truncation.patch | 610 ++++++++++++++++++ patches/openjdk/6883341-text_bearing_exception.patch | 92 ++ diffs (truncated from 869 to 500 lines): diff -r 7f4514093373 -r c78edcdba40f ChangeLog --- a/ChangeLog Mon Jan 24 21:09:58 2011 +0000 +++ b/ChangeLog Mon Jan 24 16:30:51 2011 -0500 @@ -1,3 +1,11 @@ 2011-01-24 Andrew John Hughes + + * NEWS: Update with the 3 backports + * Makefile.am (ICEDTEA_PATCHES): Add the patches + * patches/openjdk/6736649-text_bearings.patch: New file. + * patches/openjdk/6797139-jbutton_truncation.patch: Likewise. + * patches/openjdk/6883341-text_bearing_exception.patch: Likewise. + 2011-01-24 Andrew John Hughes * NEWS: Add unlisted backports. diff -r 7f4514093373 -r c78edcdba40f Makefile.am --- a/Makefile.am Mon Jan 24 21:09:58 2011 +0000 +++ b/Makefile.am Mon Jan 24 16:30:51 2011 -0500 @@ -274,7 +274,10 @@ ICEDTEA_PATCHES = \ patches/6703377-freetypescaler.patch \ patches/ia64-fix.patch \ patches/openjdk/6642612-filechooser_button_sizes.patch \ - patches/jtreg-international-fonts-styles.patch + patches/jtreg-international-fonts-styles.patch \ + patches/openjdk/6736649-text_bearings.patch \ + patches/openjdk/6797139-jbutton_truncation.patch \ + patches/openjdk/6883341-text_bearing_exception.patch if WITH_RHINO ICEDTEA_PATCHES += \ diff -r 7f4514093373 -r c78edcdba40f NEWS --- a/NEWS Mon Jan 24 21:09:58 2011 +0000 +++ b/NEWS Mon Jan 24 16:30:51 2011 -0500 @@ -399,6 +399,9 @@ New in release 1.10 (2011-XX-XX): - S6642612: JFileChooser's approve buttons should be the same size (GTK) - S6984543: Test sun/java2d/DirectX/OnScreenRenderingResizeTest fails on GNOME - S6997495: correction of regression test compiler/6857159/Test6857159 + - S6736649: test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on Linux + - S6797139: JButton title is truncating for some strings irrespective of preferred size. + - S6883341: SWAT: jdk7-b72 swat build(2009-09-17) threw exceptions when running Java2D demo by clicking Paint ta * Bug fixes - RH647157, RH582455: Update fontconfig files for rhel 6 - RH661505: JPEGs with sRGB IEC61966-2.1 color profiles have wrong colors diff -r 7f4514093373 -r c78edcdba40f patches/openjdk/6736649-text_bearings.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/openjdk/6736649-text_bearings.patch Mon Jan 24 16:30:51 2011 -0500 @@ -0,0 +1,112 @@ +# HG changeset patch +# User mlapshin +# Date 1219738583 -14400 +# Node ID e78c2f17a60646b8198279b2f676712094b833a0 +# Parent c9d407ab230941d41025428b25bc5d787cf7c18f +6736649: test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on Linux +Summary: Now text bearings are taken into account when labelRect width is calculated +Reviewed-by: alexp + +diff -r c9d407ab2309 -r e78c2f17a606 src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java +--- openjdk/jdk/src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java Tue Aug 12 17:59:58 2008 -0700 ++++ openjdk/jdk/src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java Tue Aug 26 12:16:23 2008 +0400 +@@ -136,7 +136,7 @@ + + // accRect + if (!getAccText().equals("")) { +- getAccSize().setWidth(accGu.computeStringWidth(getAccContext(), ++ getAccSize().setWidth(accGu.computeStringWidth(getAccContext(), + getAccFontMetrics().getFont(), getAccFontMetrics(), + getAccText())); + getAccSize().setHeight(getAccFontMetrics().getHeight()); +@@ -195,6 +195,7 @@ + getHorizontalAlignment(), getVerticalAlignment(), + getHorizontalTextPosition(), getVerticalTextPosition(), + getViewRect(), iconRect, textRect, getGap()); ++ textRect.width += getLeftTextExtraWidth() + getRightTextExtraWidth(); + Rectangle labelRect = iconRect.union(textRect); + getLabelSize().setHeight(labelRect.height); + getLabelSize().setWidth(labelRect.width); +diff -r c9d407ab2309 -r e78c2f17a606 src/share/classes/sun/swing/MenuItemLayoutHelper.java +--- openjdk/jdk/src/share/classes/sun/swing/MenuItemLayoutHelper.java Tue Aug 12 17:59:58 2008 -0700 ++++ openjdk/jdk/src/share/classes/sun/swing/MenuItemLayoutHelper.java Tue Aug 26 12:16:23 2008 +0400 +@@ -83,6 +83,9 @@ + private int afterCheckIconGap; + private int minTextOffset; + ++ private int leftTextExtraWidth; ++ private int rightTextExtraWidth; ++ + private Rectangle viewRect; + + private RectSize iconSize; +@@ -143,6 +146,7 @@ + this.checkSize = new RectSize(); + this.arrowSize = new RectSize(); + this.labelSize = new RectSize(); ++ calcExtraWidths(); + calcWidthsAndHeights(); + setOriginalWidths(); + calcMaxWidths(); +@@ -151,6 +155,29 @@ + calcMaxTextOffset(viewRect); + } + ++ private void calcExtraWidths() { ++ leftTextExtraWidth = getLeftExtraWidth(text); ++ rightTextExtraWidth = getRightExtraWidth(text); ++ } ++ ++ private int getLeftExtraWidth(String str) { ++ int lsb = SwingUtilities2.getLeftSideBearing(mi, fm, str); ++ if (lsb < 0) { ++ return -lsb; ++ } else { ++ return 0; ++ } ++ } ++ ++ private int getRightExtraWidth(String str) { ++ int rsb = SwingUtilities2.getRightSideBearing(mi, fm, str); ++ if (rsb > 0) { ++ return rsb; ++ } else { ++ return 0; ++ } ++ } ++ + private void setOriginalWidths() { + iconSize.origWidth = iconSize.width; + textSize.origWidth = textSize.width; +@@ -286,6 +313,7 @@ + verticalAlignment, horizontalAlignment, + verticalTextPosition, horizontalTextPosition, + viewRect, iconRect, textRect, gap); ++ textRect.width += leftTextExtraWidth + rightTextExtraWidth; + Rectangle labelRect = iconRect.union(textRect); + labelSize.height = labelRect.height; + labelSize.width = labelRect.width; +@@ -727,7 +755,7 @@ + } + } + +- /** ++ /** + * Sets Y coordinates of text and icon + * taking into account the vertical alignment + */ +@@ -1089,6 +1117,14 @@ + this.labelSize = labelSize; + } + ++ public int getLeftTextExtraWidth() { ++ return leftTextExtraWidth; ++ } ++ ++ public int getRightTextExtraWidth() { ++ return rightTextExtraWidth; ++ } ++ + /** + * Returns false if the component is a JMenu and it is a top + * level menu (on the menubar). diff -r 7f4514093373 -r c78edcdba40f patches/openjdk/6797139-jbutton_truncation.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/openjdk/6797139-jbutton_truncation.patch Mon Jan 24 16:30:51 2011 -0500 @@ -0,0 +1,610 @@ +# HG changeset patch +# User alexp +# Date 1251899239 -14400 +# Node ID 281fbd82a971f05fcf6f2c31cfe7db7ef74909e9 +# Parent 935814bd43a62d1b2c6871f0298c5b59fbf54428 +6797139: JButton title is truncating for some strings irrespective of preferred size. +Reviewed-by: peterz + +diff -r 935814bd43a6 -r 281fbd82a971 src/share/classes/javax/swing/SwingUtilities.java +--- openjdk/jdk/src/share/classes/javax/swing/SwingUtilities.java Tue Sep 01 18:51:15 2009 +0400 ++++ openjdk/jdk/src/share/classes/javax/swing/SwingUtilities.java Wed Sep 02 17:47:19 2009 +0400 +@@ -999,24 +999,20 @@ + textR.height = (int) v.getPreferredSpan(View.Y_AXIS); + } else { + textR.width = SwingUtilities2.stringWidth(c, fm, text); +- +- // Take into account the left and right side bearings. +- // This gives more space than it is actually needed, +- // but there are two reasons: +- // 1. If we set the width to the actual bounds, +- // all callers would have to account for the bearings +- // themselves. NOTE: all pref size calculations don't do it. +- // 2. You can do a drawString at the returned location +- // and the text won't be clipped. + lsb = SwingUtilities2.getLeftSideBearing(c, fm, text); + if (lsb < 0) { ++ // If lsb is negative, add it to the width and later ++ // adjust the x location. This gives more space than is ++ // actually needed. ++ // This is done like this for two reasons: ++ // 1. If we set the width to the actual bounds all ++ // callers would have to account for negative lsb ++ // (pref size calculations ONLY look at width of ++ // textR) ++ // 2. You can do a drawString at the returned location ++ // and the text won't be clipped. + textR.width -= lsb; + } +- rsb = SwingUtilities2.getRightSideBearing(c, fm, text); +- if (rsb > 0) { +- textR.width += rsb; +- } +- + if (textR.width > availTextWidth) { + text = SwingUtilities2.clipString(c, fm, text, + availTextWidth); +diff -r 935814bd43a6 -r 281fbd82a971 src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java +--- openjdk/jdk/src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java Tue Sep 01 18:51:15 2009 +0400 ++++ openjdk/jdk/src/share/classes/javax/swing/plaf/synth/SynthMenuItemLayoutHelper.java Wed Sep 02 17:47:19 2009 +0400 +@@ -195,7 +195,7 @@ + getHorizontalAlignment(), getVerticalAlignment(), + getHorizontalTextPosition(), getVerticalTextPosition(), + getViewRect(), iconRect, textRect, getGap()); +- textRect.width += getLeftTextExtraWidth() + getRightTextExtraWidth(); ++ textRect.width += getLeftTextExtraWidth(); + Rectangle labelRect = iconRect.union(textRect); + getLabelSize().setHeight(labelRect.height); + getLabelSize().setWidth(labelRect.width); +diff -r 935814bd43a6 -r 281fbd82a971 src/share/classes/sun/swing/MenuItemLayoutHelper.java +--- openjdk/jdk/src/share/classes/sun/swing/MenuItemLayoutHelper.java Tue Sep 01 18:51:15 2009 +0400 ++++ openjdk/jdk/src/share/classes/sun/swing/MenuItemLayoutHelper.java Wed Sep 02 17:47:19 2009 +0400 +@@ -84,7 +84,6 @@ + private int minTextOffset; + + private int leftTextExtraWidth; +- private int rightTextExtraWidth; + + private Rectangle viewRect; + +@@ -157,7 +156,6 @@ + + private void calcExtraWidths() { + leftTextExtraWidth = getLeftExtraWidth(text); +- rightTextExtraWidth = getRightExtraWidth(text); + } + + private int getLeftExtraWidth(String str) { +@@ -169,15 +167,6 @@ + } + } + +- private int getRightExtraWidth(String str) { +- int rsb = SwingUtilities2.getRightSideBearing(mi, fm, str); +- if (rsb > 0) { +- return rsb; +- } else { +- return 0; +- } +- } +- + private void setOriginalWidths() { + iconSize.origWidth = iconSize.width; + textSize.origWidth = textSize.width; +@@ -313,7 +302,7 @@ + verticalAlignment, horizontalAlignment, + verticalTextPosition, horizontalTextPosition, + viewRect, iconRect, textRect, gap); +- textRect.width += leftTextExtraWidth + rightTextExtraWidth; ++ textRect.width += leftTextExtraWidth; + Rectangle labelRect = iconRect.union(textRect); + labelSize.height = labelRect.height; + labelSize.width = labelRect.width; +@@ -1121,10 +1110,6 @@ + return leftTextExtraWidth; + } + +- public int getRightTextExtraWidth() { +- return rightTextExtraWidth; +- } +- + /** + * Returns false if the component is a JMenu and it is a top + * level menu (on the menubar). +diff -r 935814bd43a6 -r 281fbd82a971 src/share/classes/sun/swing/SwingUtilities2.java +--- openjdk/jdk/src/share/classes/sun/swing/SwingUtilities2.java Tue Sep 01 18:51:15 2009 +0400 ++++ openjdk/jdk/src/share/classes/sun/swing/SwingUtilities2.java Wed Sep 02 17:47:19 2009 +0400 +@@ -27,7 +27,6 @@ + + import java.security.*; + import java.lang.reflect.*; +-import java.lang.ref.SoftReference; + import java.awt.*; + import static java.awt.RenderingHints.*; + import java.awt.event.*; +@@ -78,17 +77,23 @@ + public static final Object LAF_STATE_KEY = + new StringBuffer("LookAndFeel State"); + +- // Most of applications use 10 or less fonts simultaneously +- private static final int STRONG_BEARING_CACHE_SIZE = 10; +- // Strong cache for the left and right side bearings +- // for STRONG_BEARING_CACHE_SIZE most recently used fonts. +- private static BearingCacheEntry[] strongBearingCache = +- new BearingCacheEntry[STRONG_BEARING_CACHE_SIZE]; +- // Next index to insert an entry into the strong bearing cache +- private static int strongBearingCacheNextIndex = 0; +- // Soft cache for the left and right side bearings +- private static Set> softBearingCache = +- new HashSet>(); ++ // Maintain a cache of CACHE_SIZE fonts and the left side bearing ++ // of the characters falling into the range MIN_CHAR_INDEX to ++ // MAX_CHAR_INDEX. The values in fontCache are created as needed. ++ private static LSBCacheEntry[] fontCache; ++ // Windows defines 6 font desktop properties, we will therefore only ++ // cache the metrics for 6 fonts. ++ private static final int CACHE_SIZE = 6; ++ // nextIndex in fontCache to insert a font into. ++ private static int nextIndex; ++ // LSBCacheEntry used to search in fontCache to see if we already ++ // have an entry for a particular font ++ private static LSBCacheEntry searchKey; ++ ++ // getLeftSideBearing will consult all characters that fall in the ++ // range MIN_CHAR_INDEX to MAX_CHAR_INDEX. ++ private static final int MIN_CHAR_INDEX = (int)'W'; ++ private static final int MAX_CHAR_INDEX = (int)'W' + 1; + + public static final FontRenderContext DEFAULT_FRC = + new FontRenderContext(null, false, false); +@@ -183,6 +188,10 @@ + private static final Object charsBufferLock = new Object(); + private static char[] charsBuffer = new char[CHAR_BUFFER_SIZE]; + ++ static { ++ fontCache = new LSBCacheEntry[CACHE_SIZE]; ++ } ++ + /** + * checks whether TextLayout is required to handle characters. + * +@@ -226,7 +235,9 @@ + + /** + * Returns the left side bearing of the first character of string. The +- * left side bearing is calculated from the passed in FontMetrics. ++ * left side bearing is calculated from the passed in ++ * FontMetrics. If the passed in String is less than one ++ * character, this will throw a StringIndexOutOfBoundsException exception. + * + * @param c JComponent that will display the string + * @param fm FontMetrics used to measure the String width +@@ -234,14 +245,11 @@ + */ + public static int getLeftSideBearing(JComponent c, FontMetrics fm, + String string) { +- if ((string == null) || (string.length() == 0)) { +- return 0; +- } + return getLeftSideBearing(c, fm, string.charAt(0)); + } + + /** +- * Returns the left side bearing of the specified character. The ++ * Returns the left side bearing of the first character of string. The + * left side bearing is calculated from the passed in FontMetrics. + * + * @param c JComponent that will display the string +@@ -250,105 +258,37 @@ + */ + public static int getLeftSideBearing(JComponent c, FontMetrics fm, + char firstChar) { +- return getBearing(c, fm, firstChar, true); +- } ++ int charIndex = (int) firstChar; ++ if (charIndex < MAX_CHAR_INDEX && charIndex >= MIN_CHAR_INDEX) { ++ byte[] lsbs = null; + +- /** +- * Returns the right side bearing of the last character of string. The +- * right side bearing is calculated from the passed in FontMetrics. +- * +- * @param c JComponent that will display the string +- * @param fm FontMetrics used to measure the String width +- * @param string String to get the right side bearing for. +- */ +- public static int getRightSideBearing(JComponent c, FontMetrics fm, +- String string) { +- if ((string == null) || (string.length() == 0)) { +- return 0; +- } +- return getRightSideBearing(c, fm, string.charAt(string.length() - 1)); +- } +- +- /** +- * Returns the right side bearing of the specified character. The +- * right side bearing is calculated from the passed in FontMetrics. +- * +- * @param c JComponent that will display the string +- * @param fm FontMetrics used to measure the String width +- * @param lastChar Character to get the right side bearing for. +- */ +- public static int getRightSideBearing(JComponent c, FontMetrics fm, +- char lastChar) { +- return getBearing(c, fm, lastChar, false); +- } +- +- /* Calculates the left and right side bearing for a character. +- * Strongly caches bearings for STRONG_BEARING_CACHE_SIZE +- * most recently used Fonts and softly caches as many as GC allows. +- */ +- private static int getBearing(JComponent comp, FontMetrics fm, char c, +- boolean isLeftBearing) { +- if (fm == null) { +- if (comp == null) { +- return 0; +- } else { +- fm = comp.getFontMetrics(comp.getFont()); +- } +- } +- synchronized (SwingUtilities2.class) { +- BearingCacheEntry entry = null; +- BearingCacheEntry searchKey = new BearingCacheEntry(fm); +- // See if we already have an entry in the strong cache +- for (BearingCacheEntry cacheEntry : strongBearingCache) { +- if (searchKey.equals(cacheEntry)) { +- entry = cacheEntry; +- break; ++ FontRenderContext frc = getFontRenderContext(c, fm); ++ Font font = fm.getFont(); ++ synchronized (SwingUtilities2.class) { ++ LSBCacheEntry entry = null; ++ if (searchKey == null) { ++ searchKey = new LSBCacheEntry(frc, font); ++ } else { ++ searchKey.reset(frc, font); + } +- } +- // See if we already have an entry in the soft cache +- if (entry == null) { +- Iterator> iter = +- softBearingCache.iterator(); +- while (iter.hasNext()) { +- BearingCacheEntry cacheEntry = iter.next().get(); +- if (cacheEntry == null) { +- // Remove discarded soft reference from the cache +- iter.remove(); +- continue; +- } ++ // See if we already have an entry for this pair ++ for (LSBCacheEntry cacheEntry : fontCache) { + if (searchKey.equals(cacheEntry)) { + entry = cacheEntry; +- putEntryInStrongCache(entry); + break; + } + } ++ if (entry == null) { ++ // No entry for this pair, add it. ++ entry = searchKey; ++ fontCache[nextIndex] = searchKey; ++ searchKey = null; ++ nextIndex = (nextIndex + 1) % CACHE_SIZE; ++ } ++ return entry.getLeftSideBearing(firstChar); + } +- if (entry == null) { +- // No entry, add it +- entry = searchKey; +- cacheEntry(entry); +- } +- return (isLeftBearing) +- ? entry.getLeftSideBearing(c) +- : entry.getRightSideBearing(c); + } +- } +- +- private synchronized static void cacheEntry(BearingCacheEntry entry) { +- // Move the oldest entry from the strong cache into the soft cache +- BearingCacheEntry oldestEntry = +- strongBearingCache[strongBearingCacheNextIndex]; +- if (oldestEntry != null) { +- softBearingCache.add(new SoftReference(oldestEntry)); +- } +- // Put entry in the strong cache +- putEntryInStrongCache(entry); +- } +- +- private synchronized static void putEntryInStrongCache(BearingCacheEntry entry) { +- strongBearingCache[strongBearingCacheNextIndex] = entry; +- strongBearingCacheNextIndex = (strongBearingCacheNextIndex + 1) +- % STRONG_BEARING_CACHE_SIZE; ++ return 0; + } + + /** +@@ -1063,99 +1003,72 @@ + } + + /** +- * BearingCacheEntry is used to cache left and right character bearings +- * for a particular Font and FontRenderContext. ++ * LSBCacheEntry is used to cache the left side bearing (lsb) for ++ * a particular Font and FontRenderContext. ++ * This only caches characters that fall in the range ++ * MIN_CHAR_INDEX to MAX_CHAR_INDEX. + */ +- private static class BearingCacheEntry { From drazzib at drazzib.com Mon Jan 24 13:32:58 2011 From: drazzib at drazzib.com (Damien Raude-Morvan) Date: Mon, 24 Jan 2011 22:32:58 +0100 Subject: [icedtea] Patch for OpenJDK7 b126 support Message-ID: <201101242233.04697.drazzib@drazzib.com> Hi, I've started working on updating icedtea hg to latest b126 drops from OpenJDK. You can find my current diff here : http://people.debian.org/~drazzib/icedtea-update-b126.patch Is there someone willing to review this work and maybe merge this to icedtea hg repository ? As this is my first contribution to Icedtea, feel free to blame me (or point me to the right documentation :) Regards, -- Damien -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 836 bytes Desc: This is a digitally signed message part. Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110124/52cd081c/attachment.bin From omajid at redhat.com Mon Jan 24 13:34:05 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 24 Jan 2011 16:34:05 -0500 Subject: Request to backport 6736649 and 6797139 In-Reply-To: <20110124200914.GG17602@rivendell.middle-earth.co.uk> References: <20110117141006.GA13471@rivendell.middle-earth.co.uk> <4D3454D9.7040200@redhat.com> <20110117170055.GD13471@rivendell.middle-earth.co.uk> <4D348843.2060602@redhat.com> <20110117185548.GJ13471@rivendell.middle-earth.co.uk> <4D349889.80701@redhat.com> <20110117200053.GL13471@rivendell.middle-earth.co.uk> <4D36058E.3080209@redhat.com> <20110118235603.GI14019@rivendell.middle-earth.co.uk> <4D3DD7BB.3000005@redhat.com> <20110124200914.GG17602@rivendell.middle-earth.co.uk> Message-ID: <4D3DF04D.5090405@redhat.com> On 01/24/2011 03:09 PM, Dr Andrew John Hughes wrote: > On 14:49 Mon 24 Jan , Omair Majid wrote: >> On 01/18/2011 06:56 PM, Dr Andrew John Hughes wrote: >>> On 16:26 Tue 18 Jan , Omair Majid wrote: >>>>>>>>>>> On 17:35 Fri 14 Jan , Omair Majid wrote: >>>>>>>>>>>> I would like to backport the following two changesets to openjdk6: >>>>>>>>>>>> >>>>>>>>>>>> changeset: 624:e78c2f17a606 >>>>>>>>>>>> user: mlapshin >>>>>>>>>>>> date: Tue Aug 26 12:16:23 2008 +0400 >>>>>>>>>>>> summary: 6736649: >>>>>>>>>>>> test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on >>>>>>>>>>>> Linux >>>>>>>>>>>> >>>>>>>>>>>> changeset: 1637:281fbd82a971 >>>>>>>>>>>> user: alexp >>>>>>>>>>>> date: Wed Sep 02 17:47:19 2009 +0400 >>>>>>>>>>>> summary: 6797139: JButton title is truncating for some strings >>>>>>>>>>>> irrespective of preferred size. >>>>>>>>>>>> >>>> >>>> changeset: 1738:9d78c3d9def2 >>>> user: alexp >>>> date: Mon Sep 21 17:58:09 2009 +0400 >>>> summary: 6883341: SWAT: jdk7-b72 swat build(2009-09-17) threw >>>> exceptions when running Java2D demo by clicking Paint ta >>>> >>>> This changeset gets rid of the StringIndexOutOfBoundsException (by >>>> effectively reverting the exception changes). >>>> >>> >>> Ok, so I guess I spotted it quicker than them ;-) >>> >>> Please backport this one as well. >>> >> >> Done. Please see the attached patch. >> >>>>>>> Do the new tests pass? They should be fixed to use the newer Oracle copyright notices. >>>>>>> >> >> Updated the copyright headers. >> > > Thanks. Sorry for insisting on this, but they will to upstream them, so better > to do it early. > That's true. It will make the backport to openjdk6 a little easier. >>>>>> >>>>>> Sorry, but I forgot to run the tests. I will fix the copyrights, run the >>>>>> tests and post the results. I can confirm that the patch does fix the >>>>>> issue pointed out in the bug report at >>>>>> https://bugzilla.redhat.com/show_bug.cgi?id=661610 >>>>>> >>>>> >>>>> This sounds a good reason to backport. >>>>> >>>>> I'll await the results. >>>> >>>> I can confirm that the new tests pass. However, I also discovered that >>>> swing programs using JMenus crash, so I didnt attempt to run all the tests. >>>> >>>> I will post an updated patch soon. >>>> >> >> And here is the updated patch. I ran the jtreg tests and found no >> related failures. I also ran netbeans using this build and nothing >> seemed broken. >> > > Great. The question about tests was more for interest than a case of "we'll only > allow this in if they pass", as the best place to fix such failures is with the changes > committed and easily accessible for all. > >> Ok to commit? >> > > Sure. > Thanks again for the extensive review! I have pushed this as changeset c78edcdba40f to icedtea6. Cheers, Omair From omajid at redhat.com Mon Jan 24 13:55:44 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 24 Jan 2011 16:55:44 -0500 Subject: [icedtea-web] RFC: remove default.jnlp In-Reply-To: <20110124212504.GI17602@rivendell.middle-earth.co.uk> References: <4D3DE7DB.1030904@redhat.com> <20110124212504.GI17602@rivendell.middle-earth.co.uk> Message-ID: <4D3DF560.1060501@redhat.com> On 01/24/2011 04:25 PM, Dr Andrew John Hughes wrote: > On 15:58 Mon 24 Jan , Omair Majid wrote: >> The attached patch removes default.jnlp from icedtea-web. This seems to >> be a copy of about.jnlp (About.jnlp gets invoked on javaws -about), but >> is completely unused. Ok to remove? >> > > Does the name have any special significance? Have you checked it isn't loaded > or something if you don't specify a JNLP file? > That's what I thought at first. Running javaws with no-args prints out the help message. I grepped the entire source and default.jnlp does not appear anywhere. Digging into it's history, here is what I found: icedtea6 changeset bd6babe8221f [1], which introduced the about.jnlp file, also changed the uses of default.jnlp to about.jnlp (the relevant changes are in rt/net/sourceforge/jnlp/runtime/Boot.java). The changeset should also have deleted default.jnlp. > On the subject of about.jnlp, can someone please update it so recent work is credited? > It currently gives all credit to Jon Maxwell and Joshua Sumali. > I can take a look at it. Updating the in-repository copy should not be too hard, but about.jnlp is actually run from the classpath servers, and I do not have permission to edit icedtea.classpath.org:/var/www/netx. Cheers, Omair [1] http://icedtea.classpath.org/hg/icedtea6/rev/bd6babe8221f From omajid at redhat.com Mon Jan 24 14:57:02 2011 From: omajid at redhat.com (Omair Majid) Date: Mon, 24 Jan 2011 17:57:02 -0500 Subject: [icedtea-web] RFC: add support in netx for using proxy settings from browser In-Reply-To: <20110124172148.GA17602@rivendell.middle-earth.co.uk> References: <4D127CEB.9010508@redhat.com> <20101223004028.GM17229@rivendell.middle-earth.co.uk> <4D15033A.402@redhat.com> <4D151ED4.70102@redhat.com> <20110124172148.GA17602@rivendell.middle-earth.co.uk> Message-ID: <4D3E03BE.4010500@redhat.com> On 01/24/2011 12:21 PM, Dr Andrew John Hughes wrote: > On 17:29 Fri 24 Dec , Omair Majid wrote: >> On 12/24/2010 03:31 PM, Omair Majid wrote: >>> On 12/22/2010 07:40 PM, Dr Andrew John Hughes wrote: >>>> On 17:34 Wed 22 Dec , Omair Majid wrote: >>>>> Hi, >>>>> >>>>> The attached patch makes netx (not plugin) behave correctly (or at least >>>>> slightly better) when deployment.proxy.type is set to 3 (for >>>>> PROXY_TYPE_BROWSER). >>>>> >>>>> With this patch, netx will parse the firefox preferences file to figure >>>>> out the browser's settings and use that when trying to figure out the >>>>> proxy to use for accessing a given URI. >>>>> >>>> >>>> I think there could be better handling if the profiles.ini does not >>>> exist. >>>> AFAICS, it would print out a stack trace. We should handle that much more >>>> gracefully. It's not really an exceptional event that the user hasn't >>>> used Firefox before, but something we should account for. >>>> >>> Good point. I will post an updated patch to address this issue. >>> >> >> This updated patch takes care of it. If the preferences file (or the >> profiles file) do not exist (or are damaged), BROWSER_PROXY_TYPE_NONE is >> assumed and the user is notified: >> Unable to use Firefox's proxy settings. Using "DIRECT" as proxy type. >> > > Ok. Further comments inline. > > >> diff -r 7ddab63cf8fe netx/net/sourceforge/jnlp/browser/BrowserAwareProxySelector.java >> --- /dev/null Thu Jan 01 00:00:00 1970 +0000 >> +++ b/netx/net/sourceforge/jnlp/browser/BrowserAwareProxySelector.java Fri Dec 24 17:19:09 2010 -0500 >> +public class BrowserAwareProxySelector extends JNLPProxySelector { >> + >> + /* firefox's constants */ >> + public static final int BROWSER_PROXY_TYPE_NONE = 0; >> + public static final int BROWSER_PROXY_TYPE_NONE2 = 3; >> + /** use gconf, WPAD and then env (and possibly others)*/ >> + public static final int BROWSER_PROXY_TYPE_AUTO = 4; >> + /** use env variables */ >> + public static final int BROWSER_PROXY_TYPE_SYSTEM = 5; >> + public static final int BROWSER_PROXY_TYPE_MANUAL = 1; >> + public static final int BROWSER_PROXY_TYPE_PAC = 2; >> + > > Is there a reason the integer values are out of order here? > Not that I know of. It must have been a mistake. Fixed. >> + /** >> + * Initialize configuration by reading preferences from the browser (firefox) >> + */ >> + private void initFromBrowserConfig() { >> + >> + try { >> + File preferencesFile = FirefoxPreferencesFinder.find(); >> + if (preferencesFile == null) { >> + System.out.println(R("RProxyFirefoxNotFound")); >> + browserProxyType = PROXY_TYPE_NONE; >> + return; >> + } > > Should the output not be to err rather than out (as in the method below)? Fixed. > >> + FirefoxPreferencesParser parser = new FirefoxPreferencesParser(preferencesFile); >> + parser.parse(); >> + Map prefs = parser.getPreferences(); >> + >> + String type = prefs.get("network.proxy.type"); >> + if (type != null) { >> + browserProxyType = Integer.valueOf(type); >> + } else { >> + browserProxyType = BROWSER_PROXY_TYPE_AUTO; >> + } >> + >> + try { >> + browserAutoConfigUrl = new URL(prefs.get("network.proxy.autoconfig_url")); >> + } catch (MalformedURLException e) { >> + e.printStackTrace(); >> + } >> + >> + browserUseSameProxy = Boolean.valueOf(prefs.get("network.proxy.share_proxy_settings")); >> + >> + browserHttpProxyHost = prefs.get("network.proxy.http"); >> + browserHttpProxyPort = Integer.valueOf(prefs.get("network.proxy.http_port")); >> + browserHttpsProxyHost = prefs.get("network.proxy.ssl"); >> + browserHttpsProxyPort = Integer.valueOf(prefs.get("network.proxy.ssl_port")); >> + browserFtpProxyHost = prefs.get("network.proxy.ftp"); >> + browserFtpProxyPort = Integer.valueOf(prefs.get("network.proxy.ftp_port")); >> + browserSocks4ProxyHost = prefs.get("networking.proxy.socks"); >> + browserSocks4ProxyPort = Integer.valueOf(prefs.get("network.proxy.socks_port")); >> + >> + } catch (IOException e) { >> + e.printStackTrace(); >> + System.out.println(R("RProxyFirefoxNotFound")); > > Likewise. > Fixed. > Could FirefoxPreferencesFinder not throw a FileNotFoundException (or > whatever is appropriate for the other cases) rather than returning > null, so the same logic could be used for both? > Good point. Done. >> + /** >> + * The main entry point for {@link BrowserAwareProxySelector}. Based on >> + * the browser settings, determines proxy information for a given URI. >> + *

>> + * The appropriate proxy may be determined by reading static information >> + * from the browser's preferences file, or it may be computed dynamically, >> + * by, for example, running javascript code. >> + */ >> + @Override >> + protected List getFromBrowser(URI uri) { >> + List proxies = new ArrayList(); >> + >> + switch (browserProxyType) { >> + case BROWSER_PROXY_TYPE_PAC: >> + proxies.addAll(getFromBrowserPAC(uri)); >> + break; >> + case BROWSER_PROXY_TYPE_MANUAL: >> + proxies.addAll(getFromBrowserConfiguration(uri)); >> + break; >> + case BROWSER_PROXY_TYPE_NONE: >> + proxies.add(Proxy.NO_PROXY); >> + break; >> + case BROWSER_PROXY_TYPE_AUTO: >> + // firefox will do a whole lot of stuff to automagically >> + // figure out the right settings. gconf, WPAD, and ENV are used. >> + // https://bugzilla.mozilla.org/show_bug.cgi?id=66057#c32 >> + case BROWSER_PROXY_TYPE_SYSTEM: >> + // means use $http_proxy, $ftp_proxy etc. > > Is this a TODO or is this case really empty? > Definitely a TODO. I thought the error message in the fall-through case (next-line) made it clear. I have made it more explicit. >> + default: >> + System.err.println(R("RProxyFirefoxOptionNotImplemented")); >> + proxies.add(Proxy.NO_PROXY); > > Maybe the error should include the value of browserProxyType? > Done. It now prints a rough description and the value of browserProxyType. >> + /** >> + * Get an appropriate proxy for the given URI using static information from >> + * the browser's preferences file. >> + */ >> + private List getFromBrowserConfiguration(URI uri) { >> + List proxies = new ArrayList(); >> + >> + String scheme = uri.getScheme(); >> + >> + if (browserUseSameProxy) { >> + SocketAddress sa = new InetSocketAddress(browserHttpProxyHost, browserHttpProxyPort); >> + Proxy proxy; >> + if (scheme.equals("socket")) { >> + proxy = new Proxy(Type.SOCKS, sa); >> + } else { >> + proxy = new Proxy(Type.HTTP, sa); >> + } >> + proxies.add(proxy); >> + } else if (scheme.equals("http")) { >> + SocketAddress sa = new InetSocketAddress(browserHttpProxyHost, browserHttpProxyPort); >> + proxies.add(new Proxy(Type.HTTP, sa)); >> + } else if (scheme.equals("https")) { >> + SocketAddress sa = new InetSocketAddress(browserHttpsProxyHost, browserHttpsProxyPort); >> + proxies.add(new Proxy(Type.HTTP, sa)); > > Do you not need to do something different for HTTPS? Or is that handled elsewhere? > Are you referring to Type.HTTP? There are only 3 Types defined: DIRECT, HTTP and SOCKS. Type.HTTP is for http, https and ftp. >> + } else if (scheme.equals("ftp")) { >> + SocketAddress sa = new InetSocketAddress(browserFtpProxyHost, browserFtpProxyPort); >> + proxies.add(new Proxy(Type.HTTP, sa)); >> + } else if (scheme.equals("socket")) { >> + SocketAddress sa = new InetSocketAddress(browserSocks4ProxyHost, browserSocks4ProxyPort); >> + proxies.add(new Proxy(Type.SOCKS, sa)); >> + } else { >> + proxies.add(Proxy.NO_PROXY); >> + } >> + >> + return proxies; >> + } >> + >> +} >> diff -r 7ddab63cf8fe netx/net/sourceforge/jnlp/browser/FirefoxPreferencesParser.java >> --- /dev/null Thu Jan 01 00:00:00 1970 +0000 >> +++ b/netx/net/sourceforge/jnlp/browser/FirefoxPreferencesParser.java Fri Dec 24 17:19:09 2010 -0500 >> @@ -0,0 +1,152 @@ >> +/* FirefoxPreferencesParser.java >> + Copyright (C) 2010 Red Hat, Inc. >> + >> +This file is part of IcedTea. >> + >> +IcedTea is free software; you can redistribute it and/or >> +modify it under the terms of the GNU General Public License as published by >> +the Free Software Foundation, version 2. >> + >> +IcedTea is distributed in the hope that it will be useful, >> +but WITHOUT ANY WARRANTY; without even the implied warranty of >> +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU >> +General Public License for more details. >> + >> +You should have received a copy of the GNU General Public License >> +along with IcedTea; see the file COPYING. If not, write to >> +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA >> +02110-1301 USA. >> + >> +Linking this library statically or dynamically with other modules is >> +making a combined work based on this library. Thus, the terms and >> +conditions of the GNU General Public License cover the whole >> +combination. >> + >> +As a special exception, the copyright holders of this library give you >> +permission to link this library with independent modules to produce an >> +executable, regardless of the license terms of these independent >> +modules, and to copy and distribute the resulting executable under >> +terms of your choice, provided that you also meet, for each linked >> +independent module, the terms and conditions of the license of that >> +module. An independent module is a module which is not derived from >> +or based on this library. If you modify this library, you may extend >> +this exception to your version of the library, but you are not >> +obligated to do so. If you do not wish to do so, delete this >> +exception statement from your version. >> +*/ >> + >> +package net.sourceforge.jnlp.browser; >> + >> +import java.io.BufferedReader; >> +import java.io.File; >> +import java.io.FileReader; >> +import java.io.IOException; >> +import java.util.HashMap; >> +import java.util.Map; >> + >> +/** >> + * A parser for Firefox's preferences file. It can 'parse' Firefox's >> + * preferences file and expose the prefrences in a simple to use format. >> + *

>> + * Sample usage: >> + *

>> + * FirefoxPreferencesParser p = new FirefoxPreferencesParser(prefsFile);
>> + * p.parse();
>> + * Map<String,String> prefs = p.getPreferences();
>> + * System.out.println("blink allowed: " + prefs.get("browser.blink_allowed"));
>> + *
>> + */ >> +public final class FirefoxPreferencesParser { >> + >> + >> + /** >> + * Parse the prefernces file >> + * @throws IOException if an exception ocurrs while reading the >> + * preferences file. >> + */ >> + public void parse() throws IOException { >> + System.out.println("Read " + prefs.size() + " entries from Firefox's preferences"); > > System.err? > Whoops, this is meant for debugging only. I have wrapped it in a if (debug) block now. >> diff -r 7ddab63cf8fe netx/net/sourceforge/jnlp/resources/Messages.properties >> --- a/netx/net/sourceforge/jnlp/resources/Messages.properties Tue Dec 21 16:48:12 2010 -0500 >> +++ b/netx/net/sourceforge/jnlp/resources/Messages.properties Fri Dec 24 17:19:09 2010 -0500 >> @@ -141,6 +141,9 @@ >> RUnexpected=Unexpected {0} at {1} >> RConfigurationError=Fatal error while reading the configuration >> RConfigurationFatal=ERROR: a fatal error has occurred while loading configuration. Perhaps a global configuration was required but could not be found >> +RPRoxyPacNotImplemented=Using Proxy Auto Config (PAC) files is not supported yet. >> +RProxyFirefoxNotFound=Unable to use Firefox's proxy settings. Using "DIRECT" as proxy type. >> +RProxyFirefoxOptionNotImplemented=Some browser proxy options are not supported yet >> >> # Boot options, message should be shorter than this ----------------> >> BOUsage=javaws [-run-options] >> diff -r 7ddab63cf8fe netx/net/sourceforge/jnlp/runtime/JNLPProxySelector.java >> --- a/netx/net/sourceforge/jnlp/runtime/JNLPProxySelector.java Tue Dec 21 16:48:12 2010 -0500 >> +++ b/netx/net/sourceforge/jnlp/runtime/JNLPProxySelector.java Fri Dec 24 17:19:09 2010 -0500 >> @@ -336,10 +337,7 @@ >> if (autoConfigUrl == null) { >> return Arrays.asList(new Proxy[] { Proxy.NO_PROXY }); >> } >> - // TODO implement this by reading and using the PAC file >> - if (JNLPRuntime.isDebug()) { >> - System.err.println("WARNING: Using a Proxy Auto Config file is not implemented yet"); >> - } >> + System.err.println(R("RPRoxyPacNotImplemented")); > > I'd leave the TODO in place. > Fixed. Does this look okay? Any further suggestions for improvement? Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: firefox-integration-03.patch Type: text/x-patch Size: 25317 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110124/12828e10/firefox-integration-03.patch From ahughes at redhat.com Mon Jan 24 15:07:20 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Mon, 24 Jan 2011 23:07:20 +0000 Subject: [icedtea-web] RFC: remove default.jnlp In-Reply-To: <4D3DF560.1060501@redhat.com> References: <4D3DE7DB.1030904@redhat.com> <20110124212504.GI17602@rivendell.middle-earth.co.uk> <4D3DF560.1060501@redhat.com> Message-ID: <20110124230720.GJ17602@rivendell.middle-earth.co.uk> On 16:55 Mon 24 Jan , Omair Majid wrote: > On 01/24/2011 04:25 PM, Dr Andrew John Hughes wrote: > > On 15:58 Mon 24 Jan , Omair Majid wrote: > >> The attached patch removes default.jnlp from icedtea-web. This seems to > >> be a copy of about.jnlp (About.jnlp gets invoked on javaws -about), but > >> is completely unused. Ok to remove? > >> > > > > Does the name have any special significance? Have you checked it isn't loaded > > or something if you don't specify a JNLP file? > > > > That's what I thought at first. Running javaws with no-args prints out > the help message. I grepped the entire source and default.jnlp does not > appear anywhere. Digging into it's history, here is what I found: > icedtea6 changeset bd6babe8221f [1], which introduced the about.jnlp > file, also changed the uses of default.jnlp to about.jnlp (the relevant > changes are in rt/net/sourceforge/jnlp/runtime/Boot.java). The changeset > should also have deleted default.jnlp. > Ok, great, we can delete it then. > > On the subject of about.jnlp, can someone please update it so recent work is credited? > > It currently gives all credit to Jon Maxwell and Joshua Sumali. > > > > I can take a look at it. Updating the in-repository copy should not be > too hard, but about.jnlp is actually run from the classpath servers, and > I do not have permission to edit icedtea.classpath.org:/var/www/netx. > It seems I do, so I can update the server copy once the fix is in IcedTea-Web. > Cheers, > Omair > > [1] http://icedtea.classpath.org/hg/icedtea6/rev/bd6babe8221f -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Mon Jan 24 15:33:00 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Mon, 24 Jan 2011 23:33:00 +0000 Subject: [icedtea] Patch for OpenJDK7 b126 support In-Reply-To: <201101242233.04697.drazzib@drazzib.com> References: <201101242233.04697.drazzib@drazzib.com> Message-ID: <20110124233300.GK17602@rivendell.middle-earth.co.uk> On 22:32 Mon 24 Jan , Damien Raude-Morvan wrote: > Hi, > > I've started working on updating icedtea hg to latest b126 drops from OpenJDK. > You can find my current diff here : > http://people.debian.org/~drazzib/icedtea-update-b126.patch > Have you actually got it building? I haven't got the IcedTea forest building independently yet and the last pull I did was b124. What are you using to get b126? > Is there someone willing to review this work and maybe merge this to icedtea > hg repository ? > As this is my first contribution to Icedtea, feel free to blame me (or point me > to the right documentation :) > Few immediate comments from just reading the patch: * The changesets you move to don't appear to exist on my checkout of the IcedTea forest. What are these based on? * Please don't bump CACAO in the same patch. This should be done separately to minimise change. * Don't change the jaxp/jaxws/jaf URLs. They are set to use IcedTea as the Oracle servers have proved unreliable. I'll update the IcedTea server with these new ones. This is the first time I've seen them as I've been busy with 6. * Good catch with the plugin stuff, but again I'd do that in a separate patch. * The other changes look par for the course. You seem to be dropping icedtea-ssl.patch with no explanation though. Why is this? It looks like it possibly could be dropped. Are you doing a full bootstrap with gcj? I assume so from the ecj patch additions. > Regards, > -- > Damien Thanks, -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at icedtea.classpath.org Tue Jan 25 07:21:27 2011 From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org) Date: Tue, 25 Jan 2011 15:21:27 +0000 Subject: /hg/icedtea-web: Remove unused file default.jnlp Message-ID: changeset 64da2a80df88 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=64da2a80df88 author: Omair Majid date: Tue Jan 25 10:19:20 2011 -0500 Remove unused file default.jnlp 2011-01-25 Omair Majid * netx/net/sourceforge/jnlp/resources/default.jnlp: Remove. diffstat: 2 files changed, 4 insertions(+), 20 deletions(-) ChangeLog | 4 ++++ netx/net/sourceforge/jnlp/resources/default.jnlp | 20 -------------------- diffs (35 lines): diff -r 804cd535d907 -r 64da2a80df88 ChangeLog --- a/ChangeLog Mon Jan 24 10:20:57 2011 -0500 +++ b/ChangeLog Tue Jan 25 10:19:20 2011 -0500 @@ -1,3 +1,7 @@ 2011-01-24 Omair Majid + + * netx/net/sourceforge/jnlp/resources/default.jnlp: Remove. + 2011-01-24 Omair Majid * netx/net/sourceforge/jnlp/Launcher.java: Exit with error code diff -r 804cd535d907 -r 64da2a80df88 netx/net/sourceforge/jnlp/resources/default.jnlp --- a/netx/net/sourceforge/jnlp/resources/default.jnlp Mon Jan 24 10:20:57 2011 -0500 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,20 +0,0 @@ - - - - About window for NetX - NetX - - Displays information about NetX - - - - - - - - - - - - - From omajid at redhat.com Tue Jan 25 07:34:58 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 25 Jan 2011 10:34:58 -0500 Subject: [icedtea-web] RFC: remove default.jnlp In-Reply-To: <20110124230720.GJ17602@rivendell.middle-earth.co.uk> References: <4D3DE7DB.1030904@redhat.com> <20110124212504.GI17602@rivendell.middle-earth.co.uk> <4D3DF560.1060501@redhat.com> <20110124230720.GJ17602@rivendell.middle-earth.co.uk> Message-ID: <4D3EEDA2.8060802@redhat.com> On 01/24/2011 06:07 PM, Dr Andrew John Hughes wrote: > On 16:55 Mon 24 Jan , Omair Majid wrote: >> On 01/24/2011 04:25 PM, Dr Andrew John Hughes wrote: >>> On 15:58 Mon 24 Jan , Omair Majid wrote: >>>> The attached patch removes default.jnlp from icedtea-web. This seems to >>>> be a copy of about.jnlp (About.jnlp gets invoked on javaws -about), but >>>> is completely unused. Ok to remove? >>>> >>> >>> Does the name have any special significance? Have you checked it isn't loaded >>> or something if you don't specify a JNLP file? >>> >> >> That's what I thought at first. Running javaws with no-args prints out >> the help message. I grepped the entire source and default.jnlp does not >> appear anywhere. Digging into it's history, here is what I found: >> icedtea6 changeset bd6babe8221f [1], which introduced the about.jnlp >> file, also changed the uses of default.jnlp to about.jnlp (the relevant >> changes are in rt/net/sourceforge/jnlp/runtime/Boot.java). The changeset >> should also have deleted default.jnlp. >> > > Ok, great, we can delete it then. > Thanks for looking it over; I have pushed the changeset. >>> On the subject of about.jnlp, can someone please update it so recent work is credited? >>> It currently gives all credit to Jon Maxwell and Joshua Sumali. >>> >> >> I can take a look at it. Updating the in-repository copy should not be >> too hard, but about.jnlp is actually run from the classpath servers, and >> I do not have permission to edit icedtea.classpath.org:/var/www/netx. >> > > It seems I do, so I can update the server copy once the fix is in IcedTea-Web. > I have attached a patch to update the list in the about.jnlp as well as add Jon to AUTHORS. I would also like to update the release notes (in notes.html) and the versions used, but that's another patch. Ok to commit? Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: add-people-to-about.patch Type: text/x-patch Size: 1647 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110125/7e4d67a1/add-people-to-about.patch From omajid at redhat.com Tue Jan 25 08:09:50 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 25 Jan 2011 11:09:50 -0500 Subject: [icedtea-web] RFC: allow alternate means of finding browsers In-Reply-To: <4D235EE4.4040608@redhat.com> References: <4D12605D.3080501@redhat.com> <20101222204258.GE17229@rivendell.middle-earth.co.uk> <4D127864.3010302@redhat.com> <20101222232940.GK17229@rivendell.middle-earth.co.uk> <4D235EE4.4040608@redhat.com> Message-ID: <4D3EF5CE.4030804@redhat.com> On 01/04/2011 12:54 PM, Omair Majid wrote: > On 12/22/2010 06:29 PM, Dr Andrew John Hughes wrote: >> On 17:15 Wed 22 Dec , Omair Majid wrote: >>> On 12/22/2010 03:42 PM, Dr Andrew John Hughes wrote: >>>> On 15:32 Wed 22 Dec , Omair Majid wrote: >>>>> Hi, >>>>> >>>>> The attached patch allows netx to use a browser based on the >>>>> BROWSER env >>>>> variable or using xdg-open, as opposed to relying on user-supplied >>>>> browser command. >>>>> >>>>> A new configuration option deployment.browser.source is used to >>>>> determine where to find the browser. If it is set to "PATH" (the >>>>> default), the configuration option deployment.browser.path is used. If >>>>> deployment.browser.source is set to "ENV" then the $BROWSER >>>>> environment >>>>> variable is used. If deployment.browser.source is set to "XDG" then >>>>> the >>>>> program xdg-open is used to launch the browser. >>>>> >>>> >>>> I would make XDG the default so it works like other applications on >>>> the system >>>> (which I presume use either this or $BROWSER) if >>>> deployment.browser.path is not set. >>>> Then NetX automatically picks up the system browser rather than >>>> prompting. >>>> >>> >>> Ah, great idea! Should I keep support for using $BROWSER or remove that >>> too in favour of xdg-open? >>> >> >> Please keep it. I don't see how it does any harm. >> >> You might also want to consider the scenario that xdg-open is not >> available >> and fall back to $BROWSER then prompting if that is also empty. >> > > Done. > >>>> Shouldn't we do some basic sanity checks on the contents of getEnv? >>>> (And path too >>>> if we don't already) >>>> >>> >>> We should, and we dont do it for path either. Actually netx refers to >>> path as 'command' and that's how it deals with it too - it simply execs >>> "command url" to open the url. This allows a user to use a program name >>> (like firefox) instead of the entire path to it. So checking for >>> file/path existence makes this common case fail: >>> BROWSER=chromium-browser javaws foo.jnlp >>> (and similar for path). I dont see any simple way to check if the >>> command is valid - short of actually running the command. Do you have >>> any other sanity checks in mind? >> >> On *ix systems, you could run 'which command' and then execute the >> result of that >> instead. How well that works depends if we want to allow options to be >> specified >> to the binary. >> > > I am using the 'type' builtin to check if command is valid rather than > 'which' since the behaviour of 'type' is a POSIX standard, while 'which' > may or may not return an error code on failure. > >> I would at least check for things like \r and \n which would suggest >> something fishy to me. >> It doesn't immediately seem a huge issue as the netx binary is not >> privileged. >> > > Also done. > Ping. Any comments? Cheers, Omair From omajid at redhat.com Tue Jan 25 09:13:10 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 25 Jan 2011 12:13:10 -0500 Subject: [icedtea-web] RFC: pick up name and version from configure Message-ID: <4D3F04A6.2030200@redhat.com> Hi, The attached patch gets rid of the hardcoded names and version numbers in net. It makes netx pick up the right name and version form the configure script. Okay to commit? ChangeLog: 2011-01-25 Omair Majid * Makefile.am: Add FULL_VERSION. Make PLUGIN_VERSION use FULL_VERSION. ($(NETX_DIR)/netx.manifest): New target. Creates a manifest file containing package name and version for netx. (stamps/netx.stamp): Add manifest to jar. * netx/net/sourceforge/jnlp/runtime/Boot.java: Look up name and version from manifest. Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: name-version-from-configure.patch Type: text/x-patch Size: 2270 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110125/40e5df81/name-version-from-configure.patch From omajid at redhat.com Tue Jan 25 11:42:54 2011 From: omajid at redhat.com (Omair Majid) Date: Tue, 25 Jan 2011 14:42:54 -0500 Subject: [icedtea-web] RFC: PR618 - Can't install OpenDJ, JavaWebStart fails with Input stream is null error. Message-ID: <4D3F27BE.9060300@redhat.com> Hi, The attached patch fixes PR618. The issue is that jars marked as lazy are not currently searched for resources other than classes. So loading classes from lazy jars works, but loading anything else (zip files in the case of the bug report) fails. The attached patch fixes findResources to use lazy jars if needed. URLClassLoader invokes findResource() as a part of its getResource() implementation. Instead of duplicating the addition of lazy jars in getResource(), getResource() was removed, and findResource added instead. findResource() now delegates to findResources(), so there is only one place where an actual search for resources is performed. Any concerns or comments? Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: lazy-load-resources-02.patch Type: text/x-patch Size: 2423 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110125/121ccf83/lazy-load-resources-02.patch From drazzib at drazzib.com Tue Jan 25 15:37:50 2011 From: drazzib at drazzib.com (Damien Raude-Morvan) Date: Wed, 26 Jan 2011 00:37:50 +0100 Subject: [icedtea] Drop remaining bits of plugin checks Message-ID: <201101260037.57140.drazzib@drazzib.com> Hi, Here is a smaller patch to remove remaining check related to plugin code. 2011-01-26 Damien Raude-Morvan Remove NetX and the IcedTea plugin (drop remaining bits from acinclude.m4 and configure.ac) * acinclude.m4: (IT_CHECK_PLUGIN): Removed. (IT_CHECK_PLUGIN_DEPENDENCIES): Likewise. (IT_CHECK_XULRUNNER_VERSION): Likewise. * configure.ac: Don't call IT_CHECK_XULRUNNER_VERSION. If this is okay for you, feel free to commit. Cheers -- Damien -------------- next part -------------- A non-text attachment was scrubbed... Name: drop-remaining-bits-netx-plugin.patch Type: text/x-patch Size: 2864 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110126/8271744e/drop-remaining-bits-netx-plugin.patch -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 836 bytes Desc: This is a digitally signed message part. Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110126/8271744e/attachment.bin From dbhole at redhat.com Tue Jan 25 15:57:37 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Tue, 25 Jan 2011 18:57:37 -0500 Subject: [icedtea-web] RFE: Fix for broken JRE dir install In-Reply-To: <20110122012326.GG21893@rivendell.middle-earth.co.uk> References: <20110121003724.GD22586@redhat.com> <20110121004614.GG4611@rivendell.middle-earth.co.uk> <20110121011017.GF22586@redhat.com> <20110121013228.GI4611@rivendell.middle-earth.co.uk> <20110121025333.GA24487@redhat.com> <20110121133540.GC13935@rivendell.middle-earth.co.uk> <20110121151327.GA10878@redhat.com> <20110121204649.GB21893@rivendell.middle-earth.co.uk> <20110121224039.GA3954@redhat.com> <20110122012326.GG21893@rivendell.middle-earth.co.uk> Message-ID: <20110125235737.GA20834@redhat.com> * Dr Andrew John Hughes [2011-01-21 20:23]: > On 17:40 Fri 21 Jan , Deepak Bhole wrote: > > > > IcedTea-Web does not 'put things in JDK_HOME/bin'. It puts them in > ${bindir} which defaults to ${prefix}/bin. That's only equal to > JDK_HOME/bin if ${prefix} is set to JDK_HOME. For a general application, > ${bindir} is the primary location. > > That said, I support adding the $(JRE_DIR_PREFIX) hack to IcedTea-Web 1.0 > as I said before. You just need to do in the patch what you say in the mail ;-) > Having thought more about different RPM scenarios, I can see what you mean now. I was incorrectly understanding the install requirements earlier. I have updated the patch to remove the linking changes. Sorry for the unnecessary confusion. I did however update it to use relative symlinks i.e. something like: jre/bin/javaws -> ../../bin/javaws Rather than the current way which creates absolute links (and makes the tree un-relocatable). As with previous iterations of the patch, this would be for 1.0 only. ChangeLog: 2011-01-25 Deepak Bhole * Makefile.am ($(NETX_DIR)/launcher/%.o): Build javaws without the "-J-Djava.icedtea-web.bin=..." arg. (install-exec-local): Use new JRE_DIR_PREFIX variables rather than hardcoded '/jre' in pathname. Create relative links in jre/bin rather than absolute ones. (install-data-local): Use new JRE_DIR_PREFIX variables rather than hardcoded '/jre' in pathname. (uninstall-local): Same. Also, remove all parent dirs of $(htmldir) until a non-empty one is encountered. * configure.ac: Set JRE_DIR_PREFIX to jre/ if prefix is a JDK dir and set it to empty if prefix apears to be a JRE dir. * netx/net/sourceforge/jnlp/Launcher.java (launchExternal): Revert back to using java.home when selecting javaws binary to execute for fork. Cheers, Deepak -------------- next part -------------- diff -r 43212217e9c0 Makefile.am --- a/Makefile.am Wed Dec 15 10:17:51 2010 -0500 +++ b/Makefile.am Tue Jan 25 18:47:27 2011 -0500 @@ -102,37 +102,37 @@ clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs install-exec-local: - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) if ENABLE_PLUGIN - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar endif - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ fi ; \ if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ + ln -s ../../bin/javaws $(DESTDIR)$(prefix)/jre/bin ; \ fi ; \ fi - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ fi ; \ if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ + ln -s ../../bin/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ fi ; \ fi install-data-local: ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib if ENABLE_DOCS ${mkinstalldirs} $(DESTDIR)$(htmldir) (cd ${abs_top_builddir}/docs/netx; \ @@ -150,23 +150,25 @@ endif uninstall-local: - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 rm -f $(DESTDIR)$(bindir)/pluginappletviewer - rm -f $(DESTDIR)$(bindir)/javaws - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/javaws + if [ -L $(DESTDIR)$(prefix)/bin/javaws ] ; then \ + rm -f $(DESTDIR)$(prefix)/bin/javaws ; \ fi - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws - rm -f $(DESTDIR)$(bindir)/itweb-settings - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/itweb-settings + if [ -L $(DESTDIR)$(prefix)/bin/itweb-settings ] ; then \ + rm -f $(DESTDIR)$(prefix)/bin/itweb-settings ; \ fi - rm -rf $(DESTDIR)$(htmldir) + rm -rf $(DESTDIR)$(htmldir)/* + if [ -d $(DESTDIR)$(htmldir) ] ; then \ + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ + fi # Plugin @@ -349,7 +351,7 @@ $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c mkdir -p $(NETX_DIR)/launcher && \ $(CC) $(LAUNCHER_FLAGS) \ - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ -DPROGNAME='"javaws"' -c -o $@ $< $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c diff -r 43212217e9c0 configure.ac --- a/configure.ac Wed Dec 15 10:17:51 2010 -0500 +++ b/configure.ac Tue Jan 25 18:47:27 2011 -0500 @@ -78,4 +78,12 @@ IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE +# Set JRE prefix based on whether to-level prefix is a JDK dir or a JRE dir +if test -d ${prefix}/jre ; then + JRE_DIR_PREFIX="/jre" ; +else + JRE_DIR_PREFIX="" ; +fi ; +AC_SUBST([JRE_DIR_PREFIX]) + AC_OUTPUT diff -r 43212217e9c0 netx/net/sourceforge/jnlp/Launcher.java --- a/netx/net/sourceforge/jnlp/Launcher.java Wed Dec 15 10:17:51 2010 -0500 +++ b/netx/net/sourceforge/jnlp/Launcher.java Tue Jan 25 18:47:27 2011 -0500 @@ -330,7 +330,12 @@ List commands = new LinkedList(); // this property is set by the javaws launcher to point to the javaws binary - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); + String pathToWebstartBinary = System.getProperty("java.home") + + File.separatorChar + + "bin" + + File.separatorChar + + "javaws"; + commands.add(pathToWebstartBinary); // use -Jargument format to pass arguments to the JVM through the launcher for (String arg : vmArgs) { From ahughes at redhat.com Tue Jan 25 16:03:18 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Wed, 26 Jan 2011 00:03:18 +0000 Subject: [icedtea-web] RFC: PR618 - Can't install OpenDJ, JavaWebStart fails with Input stream is null error. In-Reply-To: <4D3F27BE.9060300@redhat.com> References: <4D3F27BE.9060300@redhat.com> Message-ID: <20110126000318.GF18564@rivendell.middle-earth.co.uk> On 14:42 Tue 25 Jan , Omair Majid wrote: > Hi, > > The attached patch fixes PR618. The issue is that jars marked as lazy > are not currently searched for resources other than classes. So loading > classes from lazy jars works, but loading anything else (zip files in > the case of the bug report) fails. > > The attached patch fixes findResources to use lazy jars if needed. > > URLClassLoader invokes findResource() as a part of its getResource() > implementation. Instead of duplicating the addition of lazy jars in > getResource(), getResource() was removed, and findResource added > instead. findResource() now delegates to findResources(), so there is > only one place where an actual search for resources is performed. > > Any concerns or comments? > > Cheers, > Omair > diff -r 64da2a80df88 netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java > --- a/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Tue Jan 25 10:19:20 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Tue Jan 25 14:42:07 2011 -0500 > @@ -39,6 +39,7 @@ > import java.util.LinkedList; > import java.util.List; > import java.util.Map; > +import java.util.NoSuchElementException; > import java.util.Random; > import java.util.TreeSet; > import java.util.Vector; > @@ -1086,27 +1087,42 @@ > * Finds the resource in this, the parent, or the extension > * class loaders. > */ > - public URL getResource(String name) { > - URL result = super.getResource(name); > - > - for (int i = 1; i < loaders.length; i++) > - if (result == null) > - result = loaders[i].getResource(name); > - > - return result; > + @Override > + public URL findResource(String name) { > + try { > + return findResources(name).nextElement(); > + } catch (NoSuchElementException e) { > + return null; > + } catch (IOException e) { > + return null; > + } Would it be more efficient to check if there are more elements first rather than throwing and catching an exception? > } > > /** > - * Finds the resource in this, the parent, or the extension > + * Finds the resources in this, the parent, or the extension > * class loaders. > */ > @Override > public Enumeration findResources(String name) throws IOException { > + > + List resources = findResourcesBySearching(name); > + > + // if not found, load all lazy resources; repeat search > + while (resources.size() == 0 && addNextResource() != null) { > + resources = findResourcesBySearching(name); > + } > + > + return Collections.enumeration(resources); > + } > + > + private List findResourcesBySearching(String name) throws IOException { > Vector resources = new Vector(); > > for (int i = 0; i < loaders.length; i++) { > Enumeration e; > - > + // TODO check if this will blow up or not > + // if loaders[1].getResource() is called, wont it call getResource() on > + // the original caller? infinite recursion? > if (loaders[i] == this) > e = super.findResources(name); > else > @@ -1116,7 +1132,7 @@ > resources.add(e.nextElement()); > } > > - return resources.elements(); > + return resources; > } Is findResources the only consumer of the resources collection? If so, it would be more efficient to use an ArrayList or LinkedList and avoid the implicit synchronisation of Vector. What is the reason for returning a List from findResourcesBySearching rather than just an Iterator/Enumeration? AFAICS, you just create an enumeration from it anyway and hasNext()/hasNextElement() would tell you if there are no entries. > > /** -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From drazzib at drazzib.com Tue Jan 25 16:14:51 2011 From: drazzib at drazzib.com (Damien Raude-Morvan) Date: Wed, 26 Jan 2011 01:14:51 +0100 Subject: [icedtea] Patch for OpenJDK7 b126 support In-Reply-To: <20110124233300.GK17602@rivendell.middle-earth.co.uk> References: <201101242233.04697.drazzib@drazzib.com> <20110124233300.GK17602@rivendell.middle-earth.co.uk> Message-ID: <201101260114.51515.drazzib@drazzib.com> Hi Andrew, Le mardi 25 janvier 2011 00:33:00, Dr Andrew John Hughes a ?crit : > Have you actually got it building? I haven't got the IcedTea forest > building independently yet and the last pull I did was b124. What are you > using to get b126? [...] > * The changesets you move to don't appear to exist on my checkout of the > IcedTea forest. What are these based on? Yes, I've successfuly build a b126 Icedtea+OpenJDK using patch I've send yesterday and using Debian toolkit for building [0] (ie. it just prepare configure options and apply some more patches). To get tarballs, I'm using OpenJDK7 forest [1] and a simple script to 1) obtain revision by parsing .hgtags and grep "b126" 2) wget ${JDK_URL}/${module}/archive/${rev}.tar.gz 3) compute sha256sum && update Makefile.am [0] https://code.launchpad.net/~drazzib/openjdk/openjdk7 [1] http://hg.openjdk.java.net/jdk7/jdk7 > * Please don't bump CACAO in the same patch. This should be done > separately to minimise change. Of course, I'll prepare another patch. > * Don't change the jaxp/jaxws/jaf URLs. They are set to use IcedTea as the > Oracle servers have proved unreliable. I'll update the IcedTea server > with these new ones. This is the first time I've seen them as I've been > busy with 6. Ok, fine for me. > * The other changes look par for the course. You seem to be > dropping icedtea-ssl.patch with no explanation though. Why is this? It > looks like it possibly could be dropped. Good catch, icedtea-ssl.patch is not needed anymore. Here is updated patch based on all your comments. > Are you doing a full bootstrap with gcj? I assume so from the ecj patch > additions. Yes, I'm doing a full bootstrap with ecj-gcj... But I doesn't seems a viable long term solution as more and more source code of OpenJDK is updated to diamond operator and others Project Coin stuff... Is there support for Java 7 planned in ECJ roadmap ? Regards, -- Damien -------------- next part -------------- A non-text attachment was scrubbed... Name: icedtea-b126.patch Type: text/x-patch Size: 178551 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110126/d84a06bb/icedtea-b126.patch From ahughes at redhat.com Tue Jan 25 18:25:02 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Wed, 26 Jan 2011 02:25:02 +0000 Subject: [icedtea] Patch for OpenJDK7 b126 support In-Reply-To: <201101260114.51515.drazzib@drazzib.com> References: <201101242233.04697.drazzib@drazzib.com> <20110124233300.GK17602@rivendell.middle-earth.co.uk> <201101260114.51515.drazzib@drazzib.com> Message-ID: <20110126022502.GH18564@rivendell.middle-earth.co.uk> On 01:14 Wed 26 Jan , Damien Raude-Morvan wrote: > Hi Andrew, > > Le mardi 25 janvier 2011 00:33:00, Dr Andrew John Hughes a ?crit : > > Have you actually got it building? I haven't got the IcedTea forest > > building independently yet and the last pull I did was b124. What are you > > using to get b126? > [...] > > * The changesets you move to don't appear to exist on my checkout of the > > IcedTea forest. What are these based on? > > Yes, I've successfuly build a b126 Icedtea+OpenJDK using patch I've send > yesterday and using Debian toolkit for building [0] (ie. it just prepare > configure options and apply some more patches). > > To get tarballs, I'm using OpenJDK7 forest [1] and a simple script to > 1) obtain revision by parsing .hgtags and grep "b126" > 2) wget ${JDK_URL}/${module}/archive/${rev}.tar.gz > 3) compute sha256sum && update Makefile.am > > [0] https://code.launchpad.net/~drazzib/openjdk/openjdk7 > [1] http://hg.openjdk.java.net/jdk7/jdk7 > We use http://hg.openjdk.java.net/icedtea/jdk7 as the basis for IcedTea7 as mentioned on http://icedtea.classpath.org/wiki/Main_Page > > * Please don't bump CACAO in the same patch. This should be done > > separately to minimise change. > > Of course, I'll prepare another patch. > > > * Don't change the jaxp/jaxws/jaf URLs. They are set to use IcedTea as the > > Oracle servers have proved unreliable. I'll update the IcedTea server > > with these new ones. This is the first time I've seen them as I've been > > busy with 6. > > Ok, fine for me. > > > * The other changes look par for the course. You seem to be > > dropping icedtea-ssl.patch with no explanation though. Why is this? It > > looks like it possibly could be dropped. > > Good catch, icedtea-ssl.patch is not needed anymore. > Here is updated patch based on all your comments. > > > Are you doing a full bootstrap with gcj? I assume so from the ecj patch > > additions. > > Yes, I'm doing a full bootstrap with ecj-gcj... But I doesn't seems a viable > long term solution as more and more source code of OpenJDK is updated to > diamond operator and others Project Coin stuff... Is there support for Java 7 > planned in ECJ roadmap ? > I think it already does support some of it, but we build 1.6 classes not 1.7. I think these additions to OpenJDK make it harder to bootstrap with no real value, and seem especially odd given most of the codebase still lacks 1.5 features (try removing -nowarn and see how much ecj spews out during the build). > Regards, > -- > Damien > diff -r e5b43d618ab5 -r 43fd56d0ce89 ChangeLog > --- a/ChangeLog Wed Jan 26 01:03:53 2011 +0100 > +++ b/ChangeLog Wed Jan 26 01:12:41 2011 +0100 > @@ -1,3 +1,46 @@ > +2011-01-26 Damien Raude-Morvan > + > + Bump to b126 openjdk7 drops. > + * Makefile.am: > + (OPENJDK_VERSION): Set to b126. > + (CORBA_CHANGESET): Updated. > + (HOTSPOT_CHANGESET): Likewise. > + (JAXP_CHANGESET): Likewise. > + (JAXWS_CHANGESET): Likewise. > + (JDK_CHANGESET): Likewise. > + (LANGTOOLS_CHANGESET): Likewise. > + (OPENJDK_CHANGESET): Likewise. > + (CORBA_SHA256SUM): Likewise. > + (HOTSPOT_SHA256SUM): Likewise. > + (JAXP_SHA256SUM): Likewise. > + (JAXWS_SHA256SUM): Likewise. > + (JDK_SHA256SUM): Likewise. > + (LANGTOOLS_SHA256SUM): Likewise. > + (OPENJDK_SHA256SUM): Likewise. > + (JAXWS_DROP_ZIP): Updated to 2.2. > + (JAXWS_DROP_SHA256SUM): Likewise. > + (JAXP_DROP_ZIP): Updated to 1.4.5-dev. > + (JAXP_DROP_SHA256SUM): Likewise. > + * patches/hotspot/default/icedtea-includedb.patch: Removed; > + includeDB completely dropped upstream. > + * patches/no-precompiled.patch: Removed; b126 now allow to set > + "USE_PRECOMPILED_HEADER=0" > + * patches/icedtea-ssl.patch: Removed; don't need to cast anymore and > + conflict with TLS 1.2 support now present upstream. > + * generated/java/nio/DirectByteBuffer.java: fix call to super constructor > + (drop last parameter) > + * patches/icedtea-freetypeversion.patch, patches/icedtea-javafiles.patch, > + patches/icedtea-lc_ctype.patch, patches/icedtea-signed-types.patch, > + patches/boot/ant-javac.patch, patches/boot/demos.patch, > + patches/boot/fontconfig.patch, patches/boot/revert-6941137.patch, > + patches/boot/revert-6973616.patch, patches/boot/xbootclasspath.patch, > + patches/hotspot/default/icedtea-gcc-suffix.patch, > + patches/hotspot/default/icedtea-sparc-trapsfix.patch, > + patches/hotspot/default/icedtea-text-relocations.patch, > + : all refreshed > + * patches/boot/ecj-diamond.patch, patches/boot/ecj-stringswitch.patch: > + many parts of JDK now use diamond operator and string switch > + > 2011-01-26 Damien Raude-Morvan > > Remove NetX and the IcedTea plugin (drop remaining bits from acinclude.m4 > diff -r e5b43d618ab5 -r 43fd56d0ce89 Makefile.am > --- a/Makefile.am Wed Jan 26 01:03:53 2011 +0100 > +++ b/Makefile.am Wed Jan 26 01:12:41 2011 +0100 > @@ -1,22 +1,22 @@ > # Dependencies > > -OPENJDK_VERSION = b117 > +OPENJDK_VERSION = b126 > > -CORBA_CHANGESET = 06146786b141 > -HOTSPOT_CHANGESET = 81685aa89446 > -JAXP_CHANGESET = 43658f98c582 > -JAXWS_CHANGESET = f3444af18aff > -JDK_CHANGESET = e7fc51780596 > -LANGTOOLS_CHANGESET = fdf1b74d3437 > -OPENJDK_CHANGESET = c94d1673451e > +CORBA_CHANGESET = d7532bcd3742 > +HOTSPOT_CHANGESET = 4c851c931d00 > +JAXP_CHANGESET = 2fde639439c1 > +JAXWS_CHANGESET = 6d772c5119d5 > +JDK_CHANGESET = 8361ef97a0f9 > +LANGTOOLS_CHANGESET = 438a8ad60f7a > +OPENJDK_CHANGESET = b566d4909056 > > -CORBA_SHA256SUM = 8d5a566e2d51d791d75f1ff25d5ae499317ec9391ed6bbc86eef483d15551d55 > -HOTSPOT_SHA256SUM = 7ca6831eb7505c21b8607c7cf8d12cb182fca21c3a40c4696db737d56d80e54b > -JAXP_SHA256SUM = e0aa77b166b30d4d4052110956da831c59c43e22f8d6feeac62a06775bb083b6 > -JAXWS_SHA256SUM = ff4124f3765ac5ebac5ecfd0391cb2a54857d80ac7f967f60630ce0879cfd1f4 > -JDK_SHA256SUM = 0a01f5c43c8ef895addbc6c75adf4046d200c7a0d95d8056fa4f127a1b87feec > -LANGTOOLS_SHA256SUM = d200c9bcf1c1805e0800a8cd8017e99ff6d12db14a1fcca8e9b67c59dc5ed448 > -OPENJDK_SHA256SUM = d7a3a531f0e064898e511f08f1127447b9171adce21ae4cecb3bca84b3f7b531 > +CORBA_SHA256SUM = ffaf9368d495dbfcbc0292c1ccd99b3c2137fa95708efc0938a03c4a20fb0f40 > +HOTSPOT_SHA256SUM = 2abfc0a8b7cd47f026ec0a28063150bd86db6807373509ee5a11c3010960bdaa > +JAXP_SHA256SUM = 7bb23aab37af6e0e9d9d5d0312b9982a46fbf65adbe0d5ca398d84da444e30dc > +JAXWS_SHA256SUM = 7dff2582a77bc4b76525e58feada7b86df9b2193a6bf53447b90b805483dea5a > +JDK_SHA256SUM = 815533a7b09e0e8c02a64a6a97a6a7b8bab8a95389d7ad6db3dcc7ad3005103f > +LANGTOOLS_SHA256SUM = 101b14691959b93e49844b95e5cb79622889b2fb7610090bb33fe037363bb3bc > +OPENJDK_SHA256SUM = 1973623b462a97e3a5dc6820493785e5f205e7f01b88e56939c53092623b6436 > > CACAO_VERSION = e321b101a9ee > CACAO_SHA256SUM = 46bc5b6212c199dc4a3dbebe6386fe15a8248625a5dffa17115aab394a298444 > @@ -25,14 +25,14 @@ > CACAO_SRC_ZIP = cacao-$(CACAO_VERSION).tar.bz2 > > JAXWS_DROP_URL = http://icedtea.classpath.org/download/drops > -JAXWS_DROP_ZIP = jdk7-jaxws2_2-2010_08_19.zip > -JAXWS_DROP_SHA256SUM = b8877aafbb15a348babcaee4ee372fb3e2ea0282f8fe93d306272fd24d7847de > +JAXWS_DROP_ZIP = jdk7-jaxws2_2_2-2010_12_14.zip > +JAXWS_DROP_SHA256SUM = ef3115dde8ed9a7129e65aab8b1499e11621e343559e6e5a8df9c4542848fb9b > JAF_DROP_URL = http://icedtea.classpath.org/download/drops > JAF_DROP_ZIP = jdk7-jaf-2010_08_19.zip > JAF_DROP_SHA256SUM = e6aefedfdbb4673e8019583d1344fb162b94e1b10382c362364dbbfd5889c09e > JAXP_DROP_URL = http://icedtea.classpath.org/download/drops > -JAXP_DROP_ZIP = jaxp-1_4_4.zip > -JAXP_DROP_SHA256SUM = 10b203bec5b7d3dd8f515a9e098f80abc316faf977bcc220b56efe3dc6e9e5e9 > +JAXP_DROP_ZIP = jaxp-1_4_5-dev.zip > +JAXP_DROP_SHA256SUM = 938cce9d3f0afaa5d076c62a2de081862102d10bfe04a0767122f2dff5bd975e > > ICEDTEA_HG_URL = http://hg.openjdk.java.net/icedtea/jdk7 > OPENJDK_HG_URL = http://hg.openjdk.java.net/jdk7/jdk7 > @@ -255,7 +255,6 @@ > > ICEDTEA_PATCHES = \ > patches/hotspot/$(HSBUILD)/icedtea-text-relocations.patch \ > - patches/icedtea-ssl.patch \ > patches/icedtea-rmi_amd64.patch \ > patches/icedtea-tools.patch \ > patches/icedtea-demos.patch \ > @@ -295,12 +294,10 @@ > patches/security/icedtea-6592792.patch \ > patches/security/icedtea-6733959.patch \ > patches/security/icedtea-6755943.patch \ > - patches/hotspot/$(HSBUILD)/icedtea-includedb.patch \ > patches/icedtea-demo-swingapplet.patch \ > patches/icedtea-jvmtiEnv.patch \ > patches/icedtea-disable-intree-ec.patch \ > patches/icedtea-sources.patch \ > - patches/no-precompiled.patch \ > patches/parisc.patch \ > patches/sh4-support.patch \ > patches/jtreg-httpTest.patch \ > diff -r e5b43d618ab5 -r 43fd56d0ce89 generated/java/nio/DirectByteBuffer.java > --- a/generated/java/nio/DirectByteBuffer.java Wed Jan 26 01:03:53 2011 +0100 > +++ b/generated/java/nio/DirectByteBuffer.java Wed Jan 26 01:12:41 2011 +0100 > @@ -114,7 +114,7 @@ > // > DirectByteBuffer(int cap) { // package-private > > - super(-1, 0, cap, cap, false); > + super(-1, 0, cap, cap); > int ps = Bits.pageSize(); > int size = cap + ps; > Bits.reserveMemory(size, cap); > @@ -144,7 +144,7 @@ > // Invoked only by JNI: NewDirectByteBuffer(void*, long) > // > private DirectByteBuffer(long addr, int cap) { > - super(-1, 0, cap, cap, false); > + super(-1, 0, cap, cap); > address = addr; > cleaner = null; > } > @@ -155,7 +155,7 @@ > // > protected DirectByteBuffer(int cap, long addr, Runnable unmapper) { > > - super(-1, 0, cap, cap, true); > + super(-1, 0, cap, cap); > address = addr; > viewedBuffer = null; > cleaner = Cleaner.create(this, unmapper); > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/boot/ant-javac.patch > --- a/patches/boot/ant-javac.patch Wed Jan 26 01:03:53 2011 +0100 > +++ b/patches/boot/ant-javac.patch Wed Jan 26 01:12:41 2011 +0100 > @@ -1,7 +1,6 @@ > -diff -Nru openjdk-boot.orig/jaxp/build.xml openjdk-boot/jaxp/build.xml > ---- openjdk-boot.orig/jaxp/build.xml 2009-12-04 15:29:13.000000000 +0000 > -+++ openjdk-boot/jaxp/build.xml 2009-12-14 22:57:23.000000000 +0000 > -@@ -122,7 +122,8 @@ > +--- openjdk-boot/jaxp/build.xml.orig > ++++ openjdk-boot/jaxp/build.xml > +@@ -131,7 +131,8 @@ > memoryMaximumSize="${javac.memoryMaximumSize}" > source="${javac.source}" > debug="${javac.debug}" > @@ -11,10 +10,9 @@ > > > > -diff -Nru openjdk-boot.orig/jaxws/build.xml openjdk-boot/jaxws/build.xml > ---- openjdk-boot.orig/jaxws/build.xml 2009-12-04 15:35:01.000000000 +0000 > -+++ openjdk-boot/jaxws/build.xml 2009-12-14 22:57:41.000000000 +0000 > -@@ -122,7 +122,8 @@ > +--- openjdk-boot/jaxws/build.xml.orig > ++++ openjdk-boot/jaxws/build.xml > +@@ -131,7 +131,8 @@ > memoryMaximumSize="${javac.memoryMaximumSize}" > source="${javac.source}" > debug="${javac.debug}" > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/boot/demos.patch > --- a/patches/boot/demos.patch Wed Jan 26 01:03:53 2011 +0100 > +++ b/patches/boot/demos.patch Wed Jan 26 01:12:41 2011 +0100 > @@ -21,12 +21,12 @@ > diff -Nru openjdk-boot.orig/jdk/make/Makefile openjdk-boot/jdk/make/Makefile > --- openjdk-boot.orig/jdk/make/Makefile 2010-04-28 22:05:26.000000000 +0100 > +++ openjdk-boot/jdk/make/Makefile 2010-05-04 13:23:57.000000000 +0100 > -@@ -242,7 +242,7 @@ > +@@ -241,7 +241,7 @@ > > SUBDIRS = tools java javax sun com > SUBDIRS_tools = launchers > -SUBDIRS_misc = org sunw jpda mkdemo mksample > +SUBDIRS_misc = org sunw jpda mksample > > - include $(BUILDDIR)/common/Subdirs.gmk > - > + # Alternate classes implementation > + ifndef OPENJDK > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/boot/ecj-diamond.patch > --- a/patches/boot/ecj-diamond.patch Wed Jan 26 01:03:53 2011 +0100 > +++ b/patches/boot/ecj-diamond.patch Wed Jan 26 01:12:41 2011 +0100 > @@ -1,6 +1,5 @@ > -diff -r 917976e88f76 src/share/classes/sun/nio/cs/AbstractCharsetProvider.java > ---- openjdk-boot.orig/jdk/src/share/classes/sun/nio/cs/AbstractCharsetProvider.java Mon Feb 22 15:16:55 2010 +0000 > -+++ openjdk-boot/jdk/src/share/classes/sun/nio/cs/AbstractCharsetProvider.java Mon Feb 22 16:55:24 2010 +0000 > +--- openjdk-boot/jdk/src/share/classes/sun/nio/cs/AbstractCharsetProvider.java.orig > ++++ openjdk-boot/jdk/src/share/classes/sun/nio/cs/AbstractCharsetProvider.java > @@ -49,22 +49,22 @@ > /* Maps canonical names to class names > */ > @@ -37,9 +36,8 @@ > } > > return new Iterator() { > -diff -r a9b4fde406d4 src/share/classes/sun/io/CharacterEncoding.java > ---- openjdk-boot.orig/jdk/src/share/classes/sun/io/CharacterEncoding.java Thu Feb 18 13:31:46 2010 -0800 > -+++ openjdk-boot/jdk/src/share/classes/sun/io/CharacterEncoding.java Wed Feb 24 11:10:05 2010 +0000 > +--- openjdk-boot/jdk/src/share/classes/sun/io/CharacterEncoding.java.orig > ++++ openjdk-boot/jdk/src/share/classes/sun/io/CharacterEncoding.java > @@ -54,7 +54,7 @@ > private static volatile boolean installedAll; > > @@ -49,9 +47,8 @@ > > aliasTable.put("us-ascii", "ASCII"); > aliasTable.put("ascii", "ASCII"); > -diff -r c1cee45daf4d src/share/classes/sun/net/www/protocol/http/AuthenticationInfo.java > ---- openjdk-boot.orig/jdk/src/share/classes/sun/net/www/protocol/http/AuthenticationInfo.java Wed Apr 28 22:15:05 2010 +0100 > -+++ openjdk-boot/jdk/src/share/classes/sun/net/www/protocol/http/AuthenticationInfo.java Tue May 04 18:21:07 2010 +0100 > +--- openjdk-boot/jdk/src/share/classes/sun/net/www/protocol/http/AuthenticationInfo.java.orig > ++++ openjdk-boot/jdk/src/share/classes/sun/net/www/protocol/http/AuthenticationInfo.java > @@ -111,7 +111,7 @@ > * at the same time, then all but the first will block until > * the first completes its authentication. > @@ -61,9 +58,8 @@ > > /* check if a request for this destination is in progress > * return false immediately if not. Otherwise block until > -diff -r c1cee45daf4d src/share/classes/sun/security/provider/JavaKeyStore.java > ---- openjdk-boot.orig/jdk/src/share/classes/sun/security/provider/JavaKeyStore.java Wed Apr 28 22:15:05 2010 +0100 > -+++ openjdk-boot/jdk/src/share/classes/sun/security/provider/JavaKeyStore.java Wed May 05 11:35:35 2010 +0100 > +--- openjdk-boot/jdk/src/share/classes/sun/security/provider/JavaKeyStore.java.orig > ++++ openjdk-boot/jdk/src/share/classes/sun/security/provider/JavaKeyStore.java > @@ -683,7 +683,7 @@ > // Read the certificate chain > int numOfCerts = dis.readInt(); > @@ -73,9 +69,8 @@ > numOfCerts > 10 ? 10 : numOfCerts); > for (int j = 0; j < numOfCerts; j++) { > if (xVersion == 2) { > -diff -Nru openjdk-boot.orig/jdk/src/solaris/classes/sun/net/dns/ResolverConfigurationImpl.java openjdk-boot/jdk/src/solaris/classes/sun/net/dns/ResolverConfigurationImpl.java > ---- openjdk-boot.orig/jdk/src/solaris/classes/sun/net/dns/ResolverConfigurationImpl.java 2010-09-01 22:07:18.059282202 +0100 > -+++ openjdk-boot/jdk/src/solaris/classes/sun/net/dns/ResolverConfigurationImpl.java 2010-09-01 22:07:50.032515630 +0100 > +--- openjdk-boot/jdk/src/solaris/classes/sun/net/dns/ResolverConfigurationImpl.java.orig > ++++ openjdk-boot/jdk/src/solaris/classes/sun/net/dns/ResolverConfigurationImpl.java > @@ -60,7 +60,7 @@ > int maxperkeyword, > int maxkeywords) > @@ -94,9 +89,8 @@ > String domain = fallbackDomain0(); > if (domain != null && domain.length() > 0) { > sl.add(domain); > -diff -r a094068f4c7b src/share/classes/sun/net/spi/nameservice/dns/DNSNameService.java > ---- openjdk-boot.orig/jdk/src/share/classes/sun/net/spi/nameservice/dns/DNSNameService.java Fri Aug 27 19:01:53 2010 +0100 > -+++ openjdk-boot/jdk/src/share/classes/sun/net/spi/nameservice/dns/DNSNameService.java Mon Sep 06 17:03:29 2010 +0100 > +--- openjdk-boot/jdk/src/share/classes/sun/net/spi/nameservice/dns/DNSNameService.java.orig > ++++ openjdk-boot/jdk/src/share/classes/sun/net/spi/nameservice/dns/DNSNameService.java > @@ -52,7 +52,7 @@ > > // Per-thread soft cache of the last temporary context > @@ -124,9 +118,8 @@ > Attributes attrs; > > // do the query > -diff -r a094068f4c7b src/solaris/classes/sun/nio/cs/ext/CompoundTextSupport.java > ---- openjdk-boot.orig/jdk/src/solaris/classes/sun/nio/cs/ext/CompoundTextSupport.java Fri Aug 27 19:01:53 2010 +0100 > -+++ openjdk-boot/jdk/src/solaris/classes/sun/nio/cs/ext/CompoundTextSupport.java Mon Sep 06 18:44:51 2010 +0100 > +--- openjdk-boot/jdk/src/solaris/classes/sun/nio/cs/ext/CompoundTextSupport.java.orig > ++++ openjdk-boot/jdk/src/solaris/classes/sun/nio/cs/ext/CompoundTextSupport.java > @@ -153,12 +153,12 @@ > > static { > @@ -144,10 +137,9 @@ > > if (!(isEncodingSupported("US-ASCII") && > isEncodingSupported("ISO-8859-1"))) > -diff -r a094068f4c7b src/share/classes/com/sun/jndi/dns/DnsContextFactory.java > ---- openjdk-boot.orig/jdk/src/share/classes/com/sun/jndi/dns/DnsContextFactory.java Fri Aug 27 19:01:53 2010 +0100 > -+++ openjdk-boot/jdk/src/share/classes/com/sun/jndi/dns/DnsContextFactory.java Mon Sep 06 18:50:12 2010 +0100 > -@@ -132,7 +132,7 @@ > +--- openjdk-boot/jdk/src/share/classes/com/sun/jndi/dns/DnsContextFactory.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/jndi/dns/DnsContextFactory.java > +@@ -135,7 +135,7 @@ > throw new ConfigurationException("DNS pseudo-URL required"); > } > > @@ -156,23 +148,22 @@ > > for (int i = 0; i < urls.length; i++) { > String server = urls[i].getHost(); > -diff -r 240d4d3f2db7 src/share/classes/com/sun/java/util/jar/pack/Attribute.java > ---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/Attribute.java Tue Sep 14 17:29:58 2010 +0100 > -+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Attribute.java Wed Sep 15 00:00:17 2010 +0100 > -@@ -96,9 +96,9 @@ > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Attribute.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Attribute.java > +@@ -104,9 +104,9 @@ > + return this.def.compareTo(that.def); > } > > - private static final byte[] noBytes = {}; > - private static final Map, List> canonLists = new HashMap<>(); > - private static final Map attributes = new HashMap<>(); > - private static final Map standardDefs = new HashMap<>(); > -+ private static final Map, List> canonLists = new HashMap,List>(); > ++ private static final Map, List> canonLists = new HashMap, List>(); > + private static final Map attributes = new HashMap(); > + private static final Map standardDefs = new HashMap(); > > // Canonicalized lists of trivial attrs (Deprecated, etc.) > // are used by trimToSize, in order to reduce footprint > -@@ -108,7 +108,7 @@ > +@@ -116,7 +116,7 @@ > synchronized (canonLists) { > List cl = canonLists.get(al); > if (cl == null) { > @@ -181,7 +172,7 @@ > cl.addAll(al); > cl = Collections.unmodifiableList(cl); > canonLists.put(al, cl); > -@@ -329,9 +329,9 @@ > +@@ -337,9 +337,9 @@ > > public void addAttribute(Attribute a) { > if (attributes == null) > @@ -193,7 +184,7 @@ > attributes.add(a); > } > > -@@ -339,7 +339,7 @@ > +@@ -347,7 +347,7 @@ > if (attributes == null) return null; > if (!attributes.contains(a)) return null; > if (!(attributes instanceof ArrayList)) > @@ -202,46 +193,45 @@ > attributes.remove(a); > return a; > } > -@@ -824,7 +824,7 @@ > +@@ -838,7 +838,7 @@ > */ > static //private > Layout.Element[] tokenizeLayout(Layout self, int curCble, String layout) { > -- ArrayList col = new ArrayList<>(layout.length()); > -+ ArrayList col = new ArrayList(layout.length()); > +- List col = new ArrayList<>(layout.length()); > ++ List col = new ArrayList(layout.length()); > tokenizeLayout(self, curCble, layout, col); > Layout.Element[] res = new Layout.Element[col.size()]; > col.toArray(res); > -@@ -889,7 +889,7 @@ > +@@ -903,7 +903,7 @@ > case 'T': // union: 'T' any_int union_case* '(' ')' '[' body ']' > kind = EK_UN; > i = tokenizeSInt(e, layout, i); > -- ArrayList cases = new ArrayList<>(); > -+ ArrayList cases = new ArrayList(); > +- List cases = new ArrayList<>(); > ++ List cases = new ArrayList(); > for (;;) { > // Keep parsing cases until we hit the default case. > if (layout.charAt(i++) != '(') > -@@ -1043,7 +1043,7 @@ > +@@ -1057,7 +1057,7 @@ > } > static //private > String[] splitBodies(String layout) { > -- ArrayList bodies = new ArrayList<>(); > -+ ArrayList bodies = new ArrayList(); > +- List bodies = new ArrayList<>(); > ++ List bodies = new ArrayList(); > // Parse several independent layout bodies: "[foo][bar]...[baz]" > for (int i = 0; i < layout.length(); i++) { > if (layout.charAt(i++) != '[') > -diff -r 240d4d3f2db7 src/share/classes/com/sun/java/util/jar/pack/ConstantPool.java > ---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/ConstantPool.java Tue Sep 14 17:29:58 2010 +0100 > -+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/ConstantPool.java Wed Sep 15 00:00:17 2010 +0100 > -@@ -909,7 +909,7 @@ > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/ConstantPool.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/ConstantPool.java > +@@ -919,7 +919,7 @@ > public static > Index[] partition(Index ix, int[] keys) { > // %%% Should move this into class Index. > -- ArrayList> parts = new ArrayList<>(); > -+ ArrayList> parts = new ArrayList>(); > +- List> parts = new ArrayList<>(); > ++ List> parts = new ArrayList>(); > Entry[] cpMap = ix.cpMap; > assert(keys.length == cpMap.length); > for (int i = 0; i < keys.length; i++) { > -@@ -920,7 +920,7 @@ > +@@ -930,7 +930,7 @@ > } > List part = parts.get(key); > if (part == null) { > @@ -250,19 +240,27 @@ > } > part.add(cpMap[i]); > } > -diff -r 240d4d3f2db7 src/share/classes/com/sun/java/util/jar/pack/Package.java > ---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/Package.java Tue Sep 14 17:29:58 2010 +0100 > -+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Package.java Wed Sep 15 00:00:17 2010 +0100 > -@@ -90,7 +90,7 @@ > +@@ -1137,7 +1137,7 @@ > + void completeReferencesIn(Set cpRefs, boolean flattenSigs) { > + cpRefs.remove(null); > + for (ListIterator work = > +- new ArrayList<>(cpRefs).listIterator(cpRefs.size()); > ++ new ArrayList(cpRefs).listIterator(cpRefs.size()); > + work.hasPrevious(); ) { > + Entry e = work.previous(); > + work.remove(); // pop stack > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Package.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Package.java > +@@ -112,7 +112,7 @@ > public static final Attribute.Layout attrSourceFileSpecial; > - public static final Map attrDefs; > + public static final Map attrDefs; > static { > -- HashMap ad = new HashMap<>(3); > -+ HashMap ad = new HashMap(3); > +- Map ad = new HashMap<>(3); > ++ Map ad = new HashMap(3); > attrCodeEmpty = Attribute.define(ad, ATTR_CONTEXT_METHOD, > "Code", "").layout(); > attrInnerClassesEmpty = Attribute.define(ad, ATTR_CONTEXT_CLASS, > -@@ -160,7 +160,7 @@ > +@@ -181,7 +181,7 @@ > } > } > > @@ -271,7 +269,16 @@ > > public List getClasses() { > return classes; > -@@ -271,7 +271,7 @@ > +@@ -264,7 +264,7 @@ > + if (olda == null) > + return; // no SourceFile attr. > + String obvious = getObviousSourceFile(); > +- List ref = new ArrayList<>(1); > ++ List ref = new ArrayList(1); > + olda.visitRefs(this, VRM_PACKAGE, ref); > + Utf8Entry sfName = (Utf8Entry) ref.get(0); > + Attribute a = olda; > +@@ -292,7 +292,7 @@ > if (a != olda) { > if (verbose > 2) > Utils.log.fine("recoding obvious SourceFile="+obvious); > @@ -280,25 +287,34 @@ > int where = newAttrs.indexOf(olda); > newAttrs.set(where, a); > setAttributes(newAttrs); > -@@ -320,7 +320,7 @@ > +@@ -322,7 +322,7 @@ > + } > + > + public void setInnerClasses(Collection ics) { > +- innerClasses = (ics == null) ? null : new ArrayList<>(ics); > ++ innerClasses = (ics == null) ? null : new ArrayList(ics); > + // Edit the attribute list, if necessary. > + Attribute a = getAttribute(attrInnerClassesEmpty); > + if (innerClasses != null && a == null) > +@@ -341,7 +341,7 @@ > * with that of Package.this.allInnerClasses. > */ > public List computeGloballyImpliedICs() { > -- HashSet cpRefs = new HashSet<>(); > -+ HashSet cpRefs = new HashSet(); > +- Set cpRefs = new HashSet<>(); > ++ Set cpRefs = new HashSet(); > { // This block temporarily displaces this.innerClasses. > ArrayList innerClassesSaved = innerClasses; > innerClasses = null; // ignore for the moment > -@@ -329,7 +329,7 @@ > +@@ -350,7 +350,7 @@ > } > ConstantPool.completeReferencesIn(cpRefs, true); > > -- HashSet icRefs = new HashSet<>(); > -+ HashSet icRefs = new HashSet(); > +- Set icRefs = new HashSet<>(); > ++ Set icRefs = new HashSet(); > for (Entry e : cpRefs) { > // Restrict cpRefs to InnerClasses entries only. > if (!(e instanceof ClassEntry)) continue; > -@@ -345,7 +345,7 @@ > +@@ -366,7 +366,7 @@ > // This loop is structured this way so as to accumulate > // entries into impliedICs in an order which reflects > // the order of allInnerClasses. > @@ -307,18 +323,18 @@ > for (InnerClass ic : allInnerClasses) { > // This one is locally relevant if it describes > // a member of the current class, or if the current > -@@ -388,8 +388,8 @@ > +@@ -409,8 +409,8 @@ > // Diff is A since I is empty. > } > // (I*A) is non-trivial > -- HashSet center = new HashSet<>(actualICs); > +- Set center = new HashSet<>(actualICs); > - center.retainAll(new HashSet<>(impliedICs)); > -+ HashSet center = new HashSet(actualICs); > ++ Set center = new HashSet(actualICs); > + center.retainAll(new HashSet(impliedICs)); > impliedICs.addAll(actualICs); > impliedICs.removeAll(center); > // Diff is now I^A = (I+A)-(I*A). > -@@ -518,7 +518,7 @@ > +@@ -539,7 +539,7 @@ > super(flags, descriptor); > assert(!descriptor.isMethod()); > if (fields == null) > @@ -327,7 +343,7 @@ > boolean added = fields.add(this); > assert(added); > order = fields.size(); > -@@ -543,7 +543,7 @@ > +@@ -564,7 +564,7 @@ > super(flags, descriptor); > assert(descriptor.isMethod()); > if (methods == null) > @@ -336,7 +352,7 @@ > boolean added = methods.add(this); > assert(added); > } > -@@ -713,14 +713,14 @@ > +@@ -732,14 +732,14 @@ > } > > // What non-class files are in this unit? > @@ -348,30 +364,30 @@ > } > > public List getClassStubs() { > -- ArrayList classStubs = new ArrayList<>(classes.size()); > -+ ArrayList classStubs = new ArrayList(classes.size()); > +- List classStubs = new ArrayList<>(classes.size()); > ++ List classStubs = new ArrayList(classes.size()); > for (Class cls : classes) { > assert(cls.file.isClassStub()); > classStubs.add(cls.file); > -@@ -839,7 +839,7 @@ > +@@ -859,7 +859,7 @@ > public InputStream getInputStream() { > InputStream in = new ByteArrayInputStream(append.toByteArray()); > - if (prepend.size() == 0) return in; > -- ArrayList isa = new ArrayList<>(prepend.size()+1); > -+ ArrayList isa = new ArrayList(prepend.size()+1); > + if (prepend.isEmpty()) return in; > +- List isa = new ArrayList<>(prepend.size()+1); > ++ List isa = new ArrayList(prepend.size()+1); > for (Iterator i = prepend.iterator(); i.hasNext(); ) { > byte[] bytes = (byte[]) i.next(); > isa.add(new ByteArrayInputStream(bytes)); > -@@ -876,7 +876,7 @@ > +@@ -896,7 +896,7 @@ > } > > // Is there a globally declared table of inner classes? > -- ArrayList allInnerClasses = new ArrayList<>(); > -+ ArrayList allInnerClasses = new ArrayList(); > - HashMap allInnerClassesByThis; > +- List allInnerClasses = new ArrayList<>(); > ++ List allInnerClasses = new ArrayList(); > + Map allInnerClassesByThis; > > public > -@@ -891,7 +891,7 @@ > +@@ -911,7 +911,7 @@ > allInnerClasses.addAll(ics); > > // Make an index: > @@ -380,30 +396,17 @@ > for (InnerClass ic : allInnerClasses) { > Object pic = allInnerClassesByThis.put(ic.thisClass, ic); > assert(pic == null); // caller must ensure key uniqueness! > -@@ -1288,7 +1288,7 @@ > +@@ -1307,7 +1307,7 @@ > > // Use this before writing the class files. > void ensureAllClassFiles() { > -- HashSet fileSet = new HashSet<>(files); > -+ HashSet fileSet = new HashSet(files); > +- Set fileSet = new HashSet<>(files); > ++ Set fileSet = new HashSet(files); > for (Class cls : classes) { > // Add to the end of ths list: > if (!fileSet.contains(cls.file)) > -diff -r 240d4d3f2db7 src/share/classes/com/sun/java/util/jar/pack/PackerImpl.java > ---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/PackerImpl.java Tue Sep 14 17:29:58 2010 +0100 > -+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PackerImpl.java Wed Sep 15 00:00:17 2010 +0100 > -@@ -599,7 +599,7 @@ > - > - List scanJar(JarFile jf) throws IOException { > - // Collect jar entries, preserving order. > -- List inFiles = new ArrayList<>(); > -+ List inFiles = new ArrayList(); > - for (JarEntry je : Collections.list(jf.entries())) { > - InFile inFile = new InFile(jf, je); > - assert(je.isDirectory() == inFile.name.endsWith("/")); > -diff -r 240d4d3f2db7 src/share/classes/com/sun/java/util/jar/pack/TLGlobals.java > ---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/TLGlobals.java Tue Sep 14 17:29:58 2010 +0100 > -+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/TLGlobals.java Wed Sep 15 00:00:17 2010 +0100 > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/TLGlobals.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/TLGlobals.java > @@ -58,12 +58,12 @@ > private final Map memberEntries; > > @@ -423,10 +426,9 @@ > props = new PropMap(); > } > > -diff -r 240d4d3f2db7 src/share/classes/com/sun/java/util/jar/pack/Utils.java > ---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/Utils.java Tue Sep 14 17:29:58 2010 +0100 > -+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Utils.java Wed Sep 15 00:00:17 2010 +0100 > -@@ -123,7 +123,7 @@ > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Utils.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Utils.java > +@@ -132,7 +132,7 @@ > // Keep a TLS point to the global data and environment. > // This makes it simpler to supply environmental options > // to the engine code, especially the native code. > @@ -435,49 +437,47 @@ > > // convenience methods to access the TL globals > static TLGlobals getTLGlobals() { > -diff -r 240d4d3f2db7 src/share/classes/com/sun/java/util/jar/pack/UnpackerImpl.java > ---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/UnpackerImpl.java Tue Sep 14 17:29:58 2010 +0100 > -+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/UnpackerImpl.java Wed Sep 15 14:34:26 2010 +0100 > -@@ -199,7 +199,7 @@ > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/UnpackerImpl.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/UnpackerImpl.java > +@@ -226,7 +226,7 @@ > props.setProperty(java.util.jar.Pack200.Unpacker.PROGRESS,"50"); > pkg.ensureAllClassFiles(); > // Now write out the files. > -- HashSet classesToWrite = new HashSet<>(pkg.getClasses()); > -+ HashSet classesToWrite = new HashSet(pkg.getClasses()); > - for (Iterator i = pkg.getFiles().iterator(); i.hasNext(); ) { > - Package.File file = (Package.File) i.next(); > +- Set classesToWrite = new HashSet<>(pkg.getClasses()); > ++ Set classesToWrite = new HashSet(pkg.getClasses()); > + for (Package.File file : pkg.getFiles()) { > String name = file.nameString; > -diff -r 240d4d3f2db7 src/share/classes/com/sun/java/util/jar/pack/Driver.java > ---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/Driver.java Tue Sep 14 17:29:58 2010 +0100 > -+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Driver.java Wed Sep 15 15:25:40 2010 +0100 > -@@ -38,7 +38,7 @@ > + JarEntry je = new JarEntry(Utils.getJarEntryName(name)); > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Driver.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Driver.java > +@@ -59,7 +59,7 @@ > ResourceBundle.getBundle("com.sun.java.util.jar.pack.DriverResource"); > > public static void main(String[] ava) throws IOException { > -- ArrayList av = new ArrayList<>(Arrays.asList(ava)); > -+ ArrayList av = new ArrayList(Arrays.asList(ava)); > +- List av = new ArrayList<>(Arrays.asList(ava)); > ++ List av = new ArrayList(Arrays.asList(ava)); > > boolean doPack = true; > boolean doUnpack = false; > -@@ -61,7 +61,7 @@ > +@@ -84,7 +84,7 @@ > } > > // Collect engine properties here: > -- HashMap engProps = new HashMap<>(); > -+ HashMap engProps = new HashMap(); > +- Map engProps = new HashMap<>(); > ++ Map engProps = new HashMap(); > engProps.put(verboseProp, System.getProperty(verboseProp)); > > String optionMap; > -@@ -75,7 +75,7 @@ > +@@ -98,7 +98,7 @@ > } > > // Collect argument properties here: > -- HashMap avProps = new HashMap<>(); > -+ HashMap avProps = new HashMap(); > +- Map avProps = new HashMap<>(); > ++ Map avProps = new HashMap(); > try { > for (;;) { > String state = parseCommandOptions(av, optionMap, avProps); > -@@ -494,7 +494,7 @@ > +@@ -525,7 +525,7 @@ > String resultString = null; > > // Convert options string into optLines dictionary. > @@ -486,3 +486,2633 @@ > loadOptmap: > for (String optline : options.split("\n")) { > String[] words = optline.split("\\p{Space}+"); > +--- openjdk-boot/jdk/src/share/classes/sun/security/krb5/internal/ktab/KeyTab.java.orig > ++++ openjdk-boot/jdk/src/share/classes/sun/security/krb5/internal/ktab/KeyTab.java > +@@ -436,7 +436,7 @@ > + int count = 0; > + > + // Remember the highest KVNO for each etype. Used for kvno == -2 > +- Map highest = new HashMap<>(); > ++ Map highest = new HashMap(); > + > + for (int i = entries.size()-1; i >= 0; i--) { > + KeyTabEntry e = entries.get(i); > +--- openjdk-boot/jdk/src/share/classes/java/util/zip/ZipFile.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/zip/ZipFile.java > +@@ -315,7 +315,7 @@ > + private static native void freeEntry(long jzfile, long jzentry); > + > + // the outstanding inputstreams that need to be closed. > +- private Set streams = new HashSet<>(); > ++ private Set streams = new HashSet(); > + > + /** > + * Returns an input stream for reading the contents of the specified > +@@ -545,7 +545,7 @@ > + > + if (streams.size() !=0) { > + Set copy = streams; > +- streams = new HashSet<>(); > ++ streams = new HashSet(); > + for (InputStream is: copy) > + is.close(); > + } > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PackerImpl.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PackerImpl.java > +@@ -183,8 +183,8 @@ > + final Map attrDefs; > + final Map attrCommands; > + { > +- Map lattrDefs = new HashMap<>(); > +- Map lattrCommands = new HashMap<>(); > ++ Map lattrDefs = new HashMap(); > ++ Map lattrCommands = new HashMap(); > + String[] keys = { > + Pack200.Packer.CLASS_ATTRIBUTE_PFX, > + Pack200.Packer.FIELD_ATTRIBUTE_PFX, > +@@ -593,7 +593,7 @@ > + assert(pkg.files.containsAll(pkg.getClassStubs())); > + // Order of stubs in file list must agree with classes. > + List res = pkg.files; > +- assert((res = new ArrayList<>(pkg.files)) > ++ assert((res = new ArrayList(pkg.files)) > + .retainAll(pkg.getClassStubs()) || true); > + assert(res.equals(pkg.getClassStubs())); > + } > +@@ -626,7 +626,7 @@ > + > + List scanJar(JarFile jf) throws IOException { > + // Collect jar entries, preserving order. > +- List inFiles = new ArrayList<>(); > ++ List inFiles = new ArrayList(); > + try { > + for (JarEntry je : Collections.list(jf.entries())) { > + InFile inFile = new InFile(jf, je); > +--- openjdk-boot/jdk/src/share/classes/java/dyn/Switcher.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/dyn/Switcher.java > +@@ -79,7 +79,7 @@ > + return MethodHandles.guardWithTest(this.mcsInvoker, target, fallback); > + } > + public static void invalidateAll(Switcher[] switchers) { > +- List mcss = new ArrayList<>(); > ++ List mcss = new ArrayList(); > + for (Switcher s : switchers) mcss.add(s.mcs); > + for (MutableCallSite mcs : mcss) mcs.setTarget(K_false); > + MutableCallSite.sync(mcss.toArray(new MutableCallSite[0])); > +--- openjdk-boot/jdk/src/share/classes/sun/launcher/LauncherHelper.java.orig > ++++ openjdk-boot/jdk/src/share/classes/sun/launcher/LauncherHelper.java > +@@ -170,7 +170,7 @@ > + private static void printProperties(PrintStream ostream) { > + Properties p = System.getProperties(); > + ostream.println(PROP_SETTINGS); > +- List sortedPropertyKeys = new ArrayList<>(); > ++ List sortedPropertyKeys = new ArrayList(); > + sortedPropertyKeys.addAll(p.stringPropertyNames()); > + Collections.sort(sortedPropertyKeys); > + for (String x : sortedPropertyKeys) { > +@@ -245,7 +245,7 @@ > + } > + // Locale does not implement Comparable so we convert it to String > + // and sort it for pretty printing. > +- Set sortedSet = new TreeSet<>(); > ++ Set sortedSet = new TreeSet(); > + for (Locale l : tlocales) { > + sortedSet.add(l.toString()); > + } > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/CodingChooser.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/CodingChooser.java > +@@ -743,9 +743,9 @@ > + // Steps 1/2/3 are interdependent, and may be iterated. > + // Steps 4 and 5 may be decided independently afterward. > + int[] LValuesCoded = PopulationCoding.LValuesCoded; > +- List bestFits = new ArrayList<>(); > +- List fullFits = new ArrayList<>(); > +- List longFits = new ArrayList<>(); > ++ List bestFits = new ArrayList(); > ++ List fullFits = new ArrayList(); > ++ List longFits = new ArrayList(); > + final int PACK_TO_MAX_S = 1; > + if (bestPopFVC <= 255) { > + bestFits.add(BandStructure.BYTE1); > +@@ -785,7 +785,7 @@ > + } > + } > + } > +- List allFits = new ArrayList<>(); > ++ List allFits = new ArrayList(); > + for (Iterator i = bestFits.iterator(), > + j = fullFits.iterator(), > + k = longFits.iterator(); > +@@ -1230,10 +1230,10 @@ > + Histogram hist = getValueHistogram(); > + int fVlen = stressLen(hist.getTotalLength()); > + if (fVlen == 0) return coding; > +- List popvals = new ArrayList<>(); > ++ List popvals = new ArrayList(); > + if (stress.nextBoolean()) { > + // Build the population from the value list. > +- Set popset = new HashSet<>(); > ++ Set popset = new HashSet(); > + for (int i = start; i < end; i++) { > + if (popset.add(values[i])) popvals.add(values[i]); > + } > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PackageReader.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PackageReader.java > +@@ -680,7 +680,7 @@ > + cp_Signature_classes.expectLength(getIntTotal(numSigClasses)); > + cp_Signature_classes.readFrom(in); > + cp_Signature_classes.setIndex(getCPIndex(CONSTANT_Class)); > +- utf8Signatures = new HashMap<>(); > ++ utf8Signatures = new HashMap(); > + for (int i = 0; i < cpMap.length; i++) { > + Utf8Entry formRef = (Utf8Entry) cp_Signature_form.getRef(); > + ClassEntry[] classRefs = new ClassEntry[numSigClasses[i]]; > +@@ -880,7 +880,7 @@ > + ic_name.expectLength(longICCount); > + ic_name.readFrom(in); > + ic_flags.resetForSecondPass(); > +- List icList = new ArrayList<>(numInnerClasses); > ++ List icList = new ArrayList(numInnerClasses); > + for (int i = 0; i < numInnerClasses; i++) { > + int flags = ic_flags.getInt(); > + boolean longForm = (flags & ACC_IC_LONG_FORM) != 0; > +@@ -922,7 +922,7 @@ > + > + void readLocalInnerClasses(Class cls) throws IOException { > + int nc = class_InnerClasses_N.getInt(); > +- List localICs = new ArrayList<>(nc); > ++ List localICs = new ArrayList(nc); > + for (int i = 0; i < nc; i++) { > + ClassEntry thisClass = (ClassEntry) class_InnerClasses_RC.getRef(); > + int flags = class_InnerClasses_F.getInt(); > +@@ -1011,7 +1011,7 @@ > + return -1; > + } > + > +- Comparator entryOutputOrder = new Comparator<>() { > ++ Comparator entryOutputOrder = new Comparator() { > + public int compare(Entry e0, Entry e1) { > + int k0 = getOutputIndex(e0); > + int k1 = getOutputIndex(e1); > +@@ -1050,7 +1050,7 @@ > + > + Entry[] reconstructLocalCPMap(Class cls) { > + Set ldcRefs = ldcRefMap.get(cls); > +- Set cpRefs = new HashSet<>(); > ++ Set cpRefs = new HashSet(); > + > + // look for constant pool entries: > + cls.visitRefs(VRM_CLASSIC, cpRefs); > +@@ -1155,7 +1155,7 @@ > + method_descr.expectLength(totalNM); > + if (verbose > 1) Utils.log.fine("expecting #fields="+totalNF+" and #methods="+totalNM+" in #classes="+numClasses); > + > +- List fields = new ArrayList<>(totalNF); > ++ List fields = new ArrayList(totalNF); > + field_descr.readFrom(in); > + for (int i = 0; i < classes.length; i++) { > + Class c = classes[i]; > +@@ -1171,7 +1171,7 @@ > + countAndReadAttrs(ATTR_CONTEXT_FIELD, fields); > + fields = null; // release to GC > + > +- List methods = new ArrayList<>(totalNM); > ++ List methods = new ArrayList(totalNM); > + method_descr.readFrom(in); > + for (int i = 0; i < classes.length; i++) { > + Class c = classes[i]; > +@@ -1194,10 +1194,10 @@ > + > + Code[] allCodes; > + List codesWithFlags; > +- Map> ldcRefMap = new HashMap<>(); > ++ Map> ldcRefMap = new HashMap>(); > + > + Code[] buildCodeAttrs(List methods) { > +- List codes = new ArrayList<>(methods.size()); > ++ List codes = new ArrayList(methods.size()); > + for (Class.Method m : methods) { > + if (m.getAttribute(attrCodeEmpty) != null) { > + m.code = new Code(m); > +@@ -1221,7 +1221,7 @@ > + boolean attrsOK = testBit(archiveOptions, AO_HAVE_ALL_CODE_FLAGS); > + code_headers.expectLength(allCodes.length); > + code_headers.readFrom(in); > +- List longCodes = new ArrayList<>(allCodes.length / 10); > ++ List longCodes = new ArrayList(allCodes.length / 10); > + for (int i = 0; i < allCodes.length; i++) { > + Code c = allCodes[i]; > + int sc = code_headers.getByte(); > +@@ -1460,7 +1460,7 @@ > + bits -= (1L< + nfa += 1; > + } > +- List ha = new ArrayList<>(nfa + noa); > ++ List ha = new ArrayList(nfa + noa); > + h.attributes = ha; > + bits = attrBits; // iterate again > + for (int ai = 0; bits != 0; ai++) { > +@@ -1584,7 +1584,7 @@ > + @SuppressWarnings("unchecked") > + void readAttrs(int ctype, Collection holders) throws IOException { > + // Decode band values into attributes. > +- Set sawDefs = new HashSet<>(); > ++ Set sawDefs = new HashSet(); > + ByteArrayOutputStream buf = new ByteArrayOutputStream(); > + for (Iterator i = holders.iterator(); i.hasNext(); ) { > + final Attribute.Holder h = (Attribute.Holder) i.next(); > +@@ -1788,7 +1788,7 @@ > + // scratch buffer for collecting code:: > + byte[] buf = new byte[1<<12]; > + // record of all switch opcodes (these are variable-length) > +- List allSwitchOps = new ArrayList<>(); > ++ List allSwitchOps = new ArrayList(); > + for (int k = 0; k < allCodes.length; k++) { > + Code c = allCodes[k]; > + scanOneMethod: > +@@ -1904,7 +1904,7 @@ > + > + Set ldcRefSet = ldcRefMap.get(curClass); > + if (ldcRefSet == null) > +- ldcRefMap.put(curClass, ldcRefSet = new HashSet<>()); > ++ ldcRefMap.put(curClass, ldcRefSet = new HashSet()); > + > + ClassEntry thisClass = curClass.thisClass; > + ClassEntry superClass = curClass.superClass; > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PackageWriter.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PackageWriter.java > +@@ -116,7 +116,7 @@ > + int[][] attrCounts; // count attr. occurences > + > + void setup() { > +- requiredEntries = new HashSet<>(); > ++ requiredEntries = new HashSet(); > + setArchiveOptions(); > + trimClassAttributes(); > + collectAttributeLayouts(); > +@@ -176,7 +176,7 @@ > + } > + } > + // Decide on default version number (majority rule). > +- Map verCounts = new HashMap<>(); > ++ Map verCounts = new HashMap(); > + int bestCount = 0; > + int bestVersion = -1; > + for (Class cls : pkg.classes) { > +@@ -723,7 +723,7 @@ > + @SuppressWarnings("unchecked") > + void collectAttributeLayouts() { > + maxFlags = new int[ATTR_CONTEXT_LIMIT]; > +- allLayouts = new FixedList<>(ATTR_CONTEXT_LIMIT); > ++ allLayouts = new FixedList>(ATTR_CONTEXT_LIMIT); > + for (int i = 0; i < ATTR_CONTEXT_LIMIT; i++) { > + allLayouts.set(i, new HashMap()); > + } > +@@ -768,7 +768,7 @@ > + } > + // Collect counts for both predefs. and custom defs. > + // Decide on custom, local attribute definitions. > +- backCountTable = new HashMap<>(); > ++ backCountTable = new HashMap(); > + attrCounts = new int[ATTR_CONTEXT_LIMIT][]; > + for (int i = 0; i < ATTR_CONTEXT_LIMIT; i++) { > + // Now the remaining defs in allLayouts[i] need attr. indexes. > +@@ -785,7 +785,7 @@ > + defMap.entrySet().toArray(layoutsAndCounts); > + // Sort by count, most frequent first. > + // Predefs. participate in this sort, though it does not matter. > +- Arrays.sort(layoutsAndCounts, new Comparator<>() { > ++ Arrays.sort(layoutsAndCounts, new Comparator() { > + public int compare(Object o0, Object o1) { > + Map.Entry e0 = (Map.Entry) o0; > + Map.Entry e1 = (Map.Entry) o1; > +@@ -883,7 +883,7 @@ > + > + @SuppressWarnings("unchecked") > + void writeAttrDefs() throws IOException { > +- List defList = new ArrayList<>(); > ++ List defList = new ArrayList(); > + for (int i = 0; i < ATTR_CONTEXT_LIMIT; i++) { > + int limit = attrDefs.get(i).size(); > + for (int j = 0; j < limit; j++) { > +@@ -995,7 +995,7 @@ > + void collectInnerClasses() { > + // Capture inner classes, removing them from individual classes. > + // Irregular inner classes must stay local, though. > +- Map allICMap = new HashMap<>(); > ++ Map allICMap = new HashMap(); > + // First, collect a consistent global set. > + for (Class cls : pkg.classes) { > + if (!cls.hasInnerClasses()) continue; > +--- openjdk-boot/jdk/src/share/classes/sun/util/logging/PlatformLogger.java.orig > ++++ openjdk-boot/jdk/src/share/classes/sun/util/logging/PlatformLogger.java > +@@ -113,7 +113,7 @@ > + > + // Table of known loggers. Maps names to PlatformLoggers. > + private static Map> loggers = > +- new HashMap<>(); > ++ new HashMap>(); > + > + /** > + * Returns a PlatformLogger of a given name. > +@@ -126,7 +126,7 @@ > + } > + if (log == null) { > + log = new PlatformLogger(name); > +- loggers.put(name, new WeakReference<>(log)); > ++ loggers.put(name, new WeakReference(log)); > + } > + return log; > + } > +@@ -488,7 +488,7 @@ > + */ > + static class JavaLogger extends LoggerProxy { > + private static final Map levelObjects = > +- new HashMap<>(); > ++ new HashMap(); > + > + static { > + if (LoggingSupport.isAvailable()) { > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/BandStructure.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/BandStructure.java > +@@ -257,7 +257,7 @@ > + assert(basicCodings[_meta_default] == null); > + assert(basicCodings[_meta_canon_min] != null); > + assert(basicCodings[_meta_canon_max] != null); > +- Map map = new HashMap<>(); > ++ Map map = new HashMap(); > + for (int i = 0; i < basicCodings.length; i++) { > + Coding c = basicCodings[i]; > + if (c == null) continue; > +@@ -1050,8 +1050,8 @@ > + > + // Bootstrap support for CPRefBands. These are needed to record > + // intended CP indexes, before the CP has been created. > +- private final List allKQBands = new ArrayList<>(); > +- private List needPredefIndex = new ArrayList<>(); > ++ private final List allKQBands = new ArrayList(); > ++ private List needPredefIndex = new ArrayList(); > + > + > + int encodeRef(Entry e, Index ix) { > +@@ -1686,7 +1686,7 @@ > + protected int attrClassFileVersionMask; > + > + // Mapping from Attribute.Layout to Band[] (layout element bands). > +- protected Map attrBandTable = new HashMap<>(); > ++ protected Map attrBandTable = new HashMap(); > + > + // Well-known attributes: > + protected final Attribute.Layout attrCodeEmpty; > +@@ -1695,16 +1695,16 @@ > + protected final Attribute.Layout attrConstantValue; > + > + // Mapping from Attribute.Layout to Integer (inverse of attrDefs) > +- Map attrIndexTable = new HashMap<>(); > ++ Map attrIndexTable = new HashMap(); > + > + // Mapping from attribute index (<32 are flag bits) to attributes. > + protected List> attrDefs = > +- new FixedList<>(ATTR_CONTEXT_LIMIT); > ++ new FixedList>(ATTR_CONTEXT_LIMIT); > + { > + for (int i = 0; i < ATTR_CONTEXT_LIMIT; i++) { > + assert(attrIndexLimit[i] == 0); > + attrIndexLimit[i] = 32; // just for the sake of predefs. > +- attrDefs.set(i, new ArrayList<>(Collections.nCopies( > ++ attrDefs.set(i, new ArrayList(Collections.nCopies( > + attrIndexLimit[i], (Attribute.Layout)null))); > + > + } > +@@ -1894,7 +1894,7 @@ > + > + protected List getPredefinedAttrs(int ctype) { > + assert(attrIndexLimit[ctype] != 0); > +- List res = new ArrayList<>(attrIndexLimit[ctype]); > ++ List res = new ArrayList(attrIndexLimit[ctype]); > + // Remove nulls and non-predefs. > + for (int ai = 0; ai < attrIndexLimit[ctype]; ai++) { > + if (testBit(attrDefSeen[ctype], 1L< +@@ -2518,7 +2518,7 @@ > + // DEBUG ONLY: Record something about the band order. > + boolean notePrevForAssert(Band b, Band p) { > + if (prevForAssertMap == null) > +- prevForAssertMap = new HashMap<>(); > ++ prevForAssertMap = new HashMap(); > + prevForAssertMap.put(b, p); > + return true; > + } > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PropMap.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PropMap.java > +@@ -48,8 +48,8 @@ > + */ > + > + final class PropMap implements SortedMap { > +- private final TreeMap theMap = new TreeMap<>();; > +- private final List listenerList = new ArrayList<>(1); > ++ private final TreeMap theMap = new TreeMap();; > ++ private final List listenerList = new ArrayList(1); > + > + void addListener(PropertyChangeListener listener) { > + listenerList.add(listener); > +@@ -144,7 +144,7 @@ > + } catch (IOException ignore) {} > + } > + > +- defaultProps = (new HashMap<>(props)); // shrink to fit > ++ defaultProps = (new HashMap(props)); // shrink to fit > + } > + > + PropMap() { > +@@ -180,7 +180,7 @@ > + // Get sequence of props for "prefix", and "prefix.*". > + List getProperties(String prefix) { > + Collection values = prefixMap(prefix).values(); > +- List res = new ArrayList<>(values.size()); > ++ List res = new ArrayList(values.size()); > + res.addAll(values); > + while (res.remove(null)); > + return res; > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Coding.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Coding.java > +@@ -402,7 +402,7 @@ > + private static Map codeMap; > + > + private static synchronized Coding of(int B, int H, int S, int del) { > +- if (codeMap == null) codeMap = new HashMap<>(); > ++ if (codeMap == null) codeMap = new HashMap(); > + Coding x0 = new Coding(B, H, S, del); > + Coding x1 = codeMap.get(x0); > + if (x1 == null) codeMap.put(x0, x1 = x0); > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PopulationCoding.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PopulationCoding.java > +@@ -309,7 +309,7 @@ > + // As each new value is added, we assert that the value > + // was not already in the set. > + Set uniqueValuesForDebug = null; > +- assert((uniqueValuesForDebug = new HashSet<>()) != null); > ++ assert((uniqueValuesForDebug = new HashSet()) != null); > + int fillp = 1; > + maxForDebug += fillp; > + int min = Integer.MIN_VALUE; // farthest from the center > +--- openjdk-boot/jdk/src/share/classes/java/io/DeleteOnExitHook.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/io/DeleteOnExitHook.java > +@@ -34,7 +34,7 @@ > + */ > + > + class DeleteOnExitHook { > +- private static LinkedHashSet files = new LinkedHashSet<>(); > ++ private static LinkedHashSet files = new LinkedHashSet(); > + static { > + // DeleteOnExitHook must be the last shutdown hook to be invoked. > + // Application shutdown hooks may add the first file to the > +@@ -71,7 +71,7 @@ > + files = null; > + } > + > +- ArrayList toBeDeleted = new ArrayList<>(theFiles); > ++ ArrayList toBeDeleted = new ArrayList(theFiles); > + > + // reverse the list to maintain previous jdk deletion order. > + // Last in first deleted. > +--- openjdk-boot/jdk/src/share/classes/java/io/File.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/io/File.java > +@@ -1067,7 +1067,7 @@ > + if ((names == null) || (filter == null)) { > + return names; > + } > +- List v = new ArrayList<>(); > ++ List v = new ArrayList(); > + for (int i = 0 ; i < names.length ; i++) { > + if (filter.accept(this, names[i])) { > + v.add(names[i]); > +@@ -1158,7 +1158,7 @@ > + public File[] listFiles(FilenameFilter filter) { > + String ss[] = list(); > + if (ss == null) return null; > +- ArrayList files = new ArrayList<>(); > ++ ArrayList files = new ArrayList(); > + for (String s : ss) > + if ((filter == null) || filter.accept(this, s)) > + files.add(new File(s, this)); > +@@ -1195,7 +1195,7 @@ > + public File[] listFiles(FileFilter filter) { > + String ss[] = list(); > + if (ss == null) return null; > +- ArrayList files = new ArrayList<>(); > ++ ArrayList files = new ArrayList(); > + for (String s : ss) { > + File f = new File(s, this); > + if ((filter == null) || filter.accept(f)) > +--- openjdk-boot/jdk/src/share/classes/java/io/FileInputStream.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/io/FileInputStream.java > +@@ -56,7 +56,7 @@ > + private volatile boolean closed = false; > + > + private static final ThreadLocal runningFinalize = > +- new ThreadLocal<>(); > ++ new ThreadLocal(); > + > + private static boolean isRunningFinalize() { > + Boolean val; > +--- openjdk-boot/jdk/src/share/classes/java/io/FileOutputStream.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/io/FileOutputStream.java > +@@ -69,7 +69,7 @@ > + private final Object closeLock = new Object(); > + private volatile boolean closed = false; > + private static final ThreadLocal runningFinalize = > +- new ThreadLocal<>(); > ++ new ThreadLocal(); > + > + private static boolean isRunningFinalize() { > + Boolean val; > +--- openjdk-boot/jdk/src/share/classes/java/io/FilePermission.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/io/FilePermission.java > +@@ -725,7 +725,7 @@ > + */ > + > + public FilePermissionCollection() { > +- perms = new ArrayList<>(); > ++ perms = new ArrayList(); > + } > + > + /** > +@@ -830,7 +830,7 @@ > + // Don't call out.defaultWriteObject() > + > + // Write out Vector > +- Vector permissions = new Vector<>(perms.size()); > ++ Vector permissions = new Vector(perms.size()); > + synchronized (this) { > + permissions.addAll(perms); > + } > +@@ -853,7 +853,7 @@ > + > + // Get the one we want > + Vector permissions = (Vector)gfields.get("permissions", null); > +- perms = new ArrayList<>(permissions.size()); > ++ perms = new ArrayList(permissions.size()); > + perms.addAll(permissions); > + } > + } > +--- openjdk-boot/jdk/src/share/classes/java/io/ObjectInputStream.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/io/ObjectInputStream.java > +@@ -213,7 +213,7 @@ > + > + /** table mapping primitive type names to corresponding class objects */ > + private static final HashMap> primClasses > +- = new HashMap<>(8, 1.0F); > ++ = new HashMap(8, 1.0F); > + static { > + primClasses.put("boolean", boolean.class); > + primClasses.put("byte", byte.class); > +@@ -229,11 +229,11 @@ > + private static class Caches { > + /** cache of subclass security audit results */ > + static final ConcurrentMap subclassAudits = > +- new ConcurrentHashMap<>(); > ++ new ConcurrentHashMap(); > + > + /** queue for WeakReferences to audited subclasses */ > + static final ReferenceQueue> subclassAuditsQueue = > +- new ReferenceQueue<>(); > ++ new ReferenceQueue(); > + } > + > + /** filter stream for handling block data conversion */ > +--- openjdk-boot/jdk/src/share/classes/java/io/ObjectOutputStream.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/io/ObjectOutputStream.java > +@@ -165,11 +165,11 @@ > + private static class Caches { > + /** cache of subclass security audit results */ > + static final ConcurrentMap subclassAudits = > +- new ConcurrentHashMap<>(); > ++ new ConcurrentHashMap(); > + > + /** queue for WeakReferences to audited subclasses */ > + static final ReferenceQueue> subclassAuditsQueue = > +- new ReferenceQueue<>(); > ++ new ReferenceQueue(); > + } > + > + /** filter stream for handling block data conversion */ > +@@ -2413,7 +2413,7 @@ > + private final List stack; > + > + DebugTraceInfoStack() { > +- stack = new ArrayList<>(); > ++ stack = new ArrayList(); > + } > + > + /** > +--- openjdk-boot/jdk/src/share/classes/java/io/ObjectStreamClass.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/io/ObjectStreamClass.java > +@@ -84,18 +84,18 @@ > + private static class Caches { > + /** cache mapping local classes -> descriptors */ > + static final ConcurrentMap> localDescs = > +- new ConcurrentHashMap<>(); > ++ new ConcurrentHashMap(); > + > + /** cache mapping field group/local desc pairs -> field reflectors */ > + static final ConcurrentMap> reflectors = > +- new ConcurrentHashMap<>(); > ++ new ConcurrentHashMap(); > + > + /** queue for WeakReferences to local classes */ > + private static final ReferenceQueue> localDescsQueue = > +- new ReferenceQueue<>(); > ++ new ReferenceQueue(); > + /** queue for WeakReferences to field reflectors keys */ > + private static final ReferenceQueue> reflectorsQueue = > +- new ReferenceQueue<>(); > ++ new ReferenceQueue(); > + } > + > + /** class associated with this descriptor (if any) */ > +@@ -290,7 +290,7 @@ > + EntryFuture future = null; > + if (entry == null) { > + EntryFuture newEntry = new EntryFuture(); > +- Reference newRef = new SoftReference<>(newEntry); > ++ Reference newRef = new SoftReference(newEntry); > + do { > + if (ref != null) { > + Caches.localDescs.remove(key, ref); > +@@ -329,7 +329,7 @@ > + entry = th; > + } > + if (future.set(entry)) { > +- Caches.localDescs.put(key, new SoftReference<>(entry)); > ++ Caches.localDescs.put(key, new SoftReference(entry)); > + } else { > + // nested lookup call already set future > + entry = future.get(); > +@@ -1130,7 +1130,7 @@ > + private ClassDataSlot[] getClassDataLayout0() > + throws InvalidClassException > + { > +- ArrayList slots = new ArrayList<>(); > ++ ArrayList slots = new ArrayList(); > + Class start = cl, end = cl; > + > + // locate closest non-serializable superclass > +@@ -1566,7 +1566,7 @@ > + > + ObjectStreamField[] boundFields = > + new ObjectStreamField[serialPersistentFields.length]; > +- Set fieldNames = new HashSet<>(serialPersistentFields.length); > ++ Set fieldNames = new HashSet(serialPersistentFields.length); > + > + for (int i = 0; i < serialPersistentFields.length; i++) { > + ObjectStreamField spf = serialPersistentFields[i]; > +@@ -1604,7 +1604,7 @@ > + */ > + private static ObjectStreamField[] getDefaultSerialFields(Class cl) { > + Field[] clFields = cl.getDeclaredFields(); > +- ArrayList list = new ArrayList<>(); > ++ ArrayList list = new ArrayList(); > + int mask = Modifier.STATIC | Modifier.TRANSIENT; > + > + for (int i = 0; i < clFields.length; i++) { > +@@ -1855,8 +1855,8 @@ > + writeKeys = new long[nfields]; > + offsets = new int[nfields]; > + typeCodes = new char[nfields]; > +- ArrayList> typeList = new ArrayList<>(); > +- Set usedKeys = new HashSet<>(); > ++ ArrayList> typeList = new ArrayList(); > ++ Set usedKeys = new HashSet(); > + > + > + for (int i = 0; i < nfields; i++) { > +@@ -2092,7 +2092,7 @@ > + EntryFuture future = null; > + if (entry == null) { > + EntryFuture newEntry = new EntryFuture(); > +- Reference newRef = new SoftReference<>(newEntry); > ++ Reference newRef = new SoftReference(newEntry); > + do { > + if (ref != null) { > + Caches.reflectors.remove(key, ref); > +@@ -2118,7 +2118,7 @@ > + entry = th; > + } > + future.set(entry); > +- Caches.reflectors.put(key, new SoftReference<>(entry)); > ++ Caches.reflectors.put(key, new SoftReference(entry)); > + } > + > + if (entry instanceof FieldReflector) { > +--- openjdk-boot/jdk/src/share/classes/java/lang/ApplicationShutdownHooks.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/lang/ApplicationShutdownHooks.java > +@@ -47,7 +47,7 @@ > + } > + } > + ); > +- hooks = new IdentityHashMap<>(); > ++ hooks = new IdentityHashMap(); > + } catch (IllegalStateException e) { > + // application shutdown hooks cannot be added if > + // shutdown is in progress. > +--- openjdk-boot/jdk/src/share/classes/java/lang/Class.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/lang/Class.java > +@@ -1306,7 +1306,7 @@ > + return java.security.AccessController.doPrivileged( > + new java.security.PrivilegedAction[]>() { > + public Class[] run() { > +- List> list = new ArrayList<>(); > ++ List> list = new ArrayList(); > + Class currentClass = Class.this; > + while (currentClass != null) { > + Class[] members = currentClass.getDeclaredClasses(); > +@@ -2306,9 +2306,9 @@ > + res = Reflection.filterFields(this, getDeclaredFields0(publicOnly)); > + if (useCaches) { > + if (publicOnly) { > +- declaredPublicFields = new SoftReference<>(res); > ++ declaredPublicFields = new SoftReference(res); > + } else { > +- declaredFields = new SoftReference<>(res); > ++ declaredFields = new SoftReference(res); > + } > + } > + return res; > +@@ -2330,9 +2330,9 @@ > + > + // No cached value available; compute value recursively. > + // Traverse in correct order for getField(). > +- List fields = new ArrayList<>(); > ++ List fields = new ArrayList(); > + if (traversedInterfaces == null) { > +- traversedInterfaces = new HashSet<>(); > ++ traversedInterfaces = new HashSet(); > + } > + > + // Local fields > +@@ -2358,7 +2358,7 @@ > + res = new Field[fields.size()]; > + fields.toArray(res); > + if (useCaches) { > +- publicFields = new SoftReference<>(res); > ++ publicFields = new SoftReference(res); > + } > + return res; > + } > +@@ -2403,9 +2403,9 @@ > + } > + if (useCaches) { > + if (publicOnly) { > +- publicConstructors = new SoftReference<>(res); > ++ publicConstructors = new SoftReference(res); > + } else { > +- declaredConstructors = new SoftReference<>(res); > ++ declaredConstructors = new SoftReference(res); > + } > + } > + return res; > +@@ -2440,9 +2440,9 @@ > + res = Reflection.filterMethods(this, getDeclaredMethods0(publicOnly)); > + if (useCaches) { > + if (publicOnly) { > +- declaredPublicMethods = new SoftReference<>(res); > ++ declaredPublicMethods = new SoftReference(res); > + } else { > +- declaredMethods = new SoftReference<>(res); > ++ declaredMethods = new SoftReference(res); > + } > + } > + return res; > +@@ -2598,7 +2598,7 @@ > + methods.compactAndTrim(); > + res = methods.getArray(); > + if (useCaches) { > +- publicMethods = new SoftReference<>(res); > ++ publicMethods = new SoftReference(res); > + } > + return res; > + } > +@@ -2977,7 +2977,7 @@ > + if (universe == null) > + throw new IllegalArgumentException( > + getName() + " is not an enum type"); > +- Map m = new HashMap<>(2 * universe.length); > ++ Map m = new HashMap(2 * universe.length); > + for (T constant : universe) > + m.put(((Enum)constant).name(), constant); > + enumConstantDirectory = m; > +@@ -3090,7 +3090,7 @@ > + if (superClass == null) { > + annotations = declaredAnnotations; > + } else { > +- annotations = new HashMap<>(); > ++ annotations = new HashMap(); > + superClass.initAnnotationsIfNecessary(); > + for (Map.Entry, Annotation> e : superClass.annotations.entrySet()) { > + Class annotationClass = e.getKey(); > +--- openjdk-boot/jdk/src/share/classes/java/lang/ClassLoader.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/lang/ClassLoader.java > +@@ -247,7 +247,7 @@ > + > + // The classes loaded by this class loader. The only purpose of this table > + // is to keep the classes from being GC'ed until the loader is GC'ed. > +- private final Vector> classes = new Vector<>(); > ++ private final Vector> classes = new Vector(); > + > + // The "default" domain. Set as the default ProtectionDomain on newly > + // created classes. > +@@ -266,7 +266,7 @@ > + // The packages defined in this class loader. Each package name is mapped > + // to its corresponding Package object. > + // @GuardedBy("itself") > +- private final HashMap packages = new HashMap<>(); > ++ private final HashMap packages = new HashMap(); > + > + private static Void checkCreateClassLoader() { > + SecurityManager security = System.getSecurityManager(); > +@@ -279,16 +279,16 @@ > + private ClassLoader(Void unused, ClassLoader parent) { > + this.parent = parent; > + if (ParallelLoaders.isRegistered(this.getClass())) { > +- parallelLockMap = new ConcurrentHashMap<>(); > +- package2certs = new ConcurrentHashMap<>(); > ++ parallelLockMap = new ConcurrentHashMap(); > ++ package2certs = new ConcurrentHashMap(); > + domains = > + Collections.synchronizedSet(new HashSet()); > + assertionLock = new Object(); > + } else { > + // no finer-grained lock; lock on the classloader instance > + parallelLockMap = null; > +- package2certs = new Hashtable<>(); > +- domains = new HashSet<>(); > ++ package2certs = new Hashtable(); > ++ domains = new HashSet(); > + assertionLock = this; > + } > + } > +@@ -1181,7 +1181,7 @@ > + } > + tmp[1] = findResources(name); > + > +- return new CompoundEnumeration<>(tmp); > ++ return new CompoundEnumeration(tmp); > + } > + > + /** > +@@ -1656,7 +1656,7 @@ > + protected Package[] getPackages() { > + Map map; > + synchronized (packages) { > +- map = new HashMap<>(packages); > ++ map = new HashMap(packages); > + } > + Package[] pkgs; > + if (parent != null) { > +@@ -1763,17 +1763,17 @@ > + } > + > + // All native library names we've loaded. > +- private static Vector loadedLibraryNames = new Vector<>(); > ++ private static Vector loadedLibraryNames = new Vector(); > + > + // Native libraries belonging to system classes. > + private static Vector systemNativeLibraries > +- = new Vector<>(); > ++ = new Vector(); > + > + // Native libraries associated with the class loader. > +- private Vector nativeLibraries = new Vector<>(); > ++ private Vector nativeLibraries = new Vector(); > + > + // native libraries being loaded/unloaded. > +- private static Stack nativeLibraryContext = new Stack<>(); > ++ private static Stack nativeLibraryContext = new Stack(); > + > + // The paths searched for libraries > + private static String usr_paths[]; > +@@ -2097,8 +2097,8 @@ > + * them to empty maps, effectively ignoring any present settings. > + */ > + synchronized (assertionLock) { > +- classAssertionStatus = new HashMap<>(); > +- packageAssertionStatus = new HashMap<>(); > ++ classAssertionStatus = new HashMap(); > ++ packageAssertionStatus = new HashMap(); > + defaultAssertionStatus = false; > + } > + } > +@@ -2160,8 +2160,8 @@ > + private void initializeJavaAssertionMaps() { > + // assert Thread.holdsLock(assertionLock); > + > +- classAssertionStatus = new HashMap<>(); > +- packageAssertionStatus = new HashMap<>(); > ++ classAssertionStatus = new HashMap(); > ++ packageAssertionStatus = new HashMap(); > + AssertionStatusDirectives directives = retrieveDirectives(); > + > + for(int i = 0; i < directives.classes.length; i++) > +--- openjdk-boot/jdk/src/share/classes/java/lang/String.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/lang/String.java > +@@ -2330,7 +2330,7 @@ > + int off = 0; > + int next = 0; > + boolean limited = limit > 0; > +- ArrayList list = new ArrayList<>(); > ++ ArrayList list = new ArrayList(); > + while ((next = indexOf(ch, off)) != -1) { > + if (!limited || list.size() < limit - 1) { > + list.add(substring(off, next)); > +--- openjdk-boot/jdk/src/share/classes/java/lang/StringCoding.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/lang/StringCoding.java > +@@ -53,9 +53,9 @@ > + > + /** The cached coders for each thread */ > + private final static ThreadLocal> decoder = > +- new ThreadLocal<>(); > ++ new ThreadLocal(); > + private final static ThreadLocal> encoder = > +- new ThreadLocal<>(); > ++ new ThreadLocal(); > + > + private static boolean warnUnsupportedCharset = true; > + > +@@ -67,7 +67,7 @@ > + } > + > + private static void set(ThreadLocal> tl, T ob) { > +- tl.set(new SoftReference<>(ob)); > ++ tl.set(new SoftReference(ob)); > + } > + > + // Trim the given byte array to the given length > +--- openjdk-boot/jdk/src/share/classes/java/lang/Thread.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/lang/Thread.java > +@@ -1642,7 +1642,7 @@ > + // Get a snapshot of the list of all threads > + Thread[] threads = getThreads(); > + StackTraceElement[][] traces = dumpThreads(threads); > +- Map m = new HashMap<>(threads.length); > ++ Map m = new HashMap(threads.length); > + for (int i = 0; i < threads.length; i++) { > + StackTraceElement[] stackTrace = traces[i]; > + if (stackTrace != null) { > +@@ -1663,11 +1663,11 @@ > + private static class Caches { > + /** cache of subclass security audit results */ > + static final ConcurrentMap subclassAudits = > +- new ConcurrentHashMap<>(); > ++ new ConcurrentHashMap(); > + > + /** queue for WeakReferences to audited subclasses */ > + static final ReferenceQueue> subclassAuditsQueue = > +- new ReferenceQueue<>(); > ++ new ReferenceQueue(); > + } > + > + /** > +--- openjdk-boot/jdk/src/share/classes/java/lang/management/ManagementFactory.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/lang/management/ManagementFactory.java > +@@ -794,7 +794,7 @@ > + */ > + public static List> getAllPlatformMXBeanInterfaces() { > + List> result = > +- new ArrayList<>(); > ++ new ArrayList(); > + for (PlatformComponent component: PlatformComponent.values()) { > + result.add(component.getMXBeanInterface()); > + } > +--- openjdk-boot/jdk/src/share/classes/java/lang/management/PlatformComponent.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/lang/management/PlatformComponent.java > +@@ -267,7 +267,7 @@ > + List getGcMXBeanList(Class gcMXBeanIntf) { > + List list = > + ManagementFactoryHelper.getGarbageCollectorMXBeans(); > +- List result = new ArrayList<>(list.size()); > ++ List result = new ArrayList(list.size()); > + for (GarbageCollectorMXBean m : list) { > + if (gcMXBeanIntf.isInstance(m)) { > + result.add(gcMXBeanIntf.cast(m)); > +@@ -330,7 +330,7 @@ > + } > + > + private static Set keyProperties(String... keyNames) { > +- Set set = new HashSet<>(); > ++ Set set = new HashSet(); > + set.add("type"); > + for (String s : keyNames) { > + set.add(s); > +@@ -364,7 +364,7 @@ > + List getMXBeans(MBeanServerConnection mbs, Class mxbeanInterface) > + throws java.io.IOException > + { > +- List result = new ArrayList<>(); > ++ List result = new ArrayList(); > + for (ObjectName on : getObjectNames(mbs)) { > + result.add(ManagementFactory. > + newPlatformMXBeanProxy(mbs, > +--- openjdk-boot/jdk/src/share/classes/java/lang/reflect/Proxy.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/lang/reflect/Proxy.java > +@@ -232,7 +232,7 @@ > + > + /** maps a class loader to the proxy class cache for that loader */ > + private static Map, Object>> loaderToCache > +- = new WeakHashMap<>(); > ++ = new WeakHashMap(); > + > + /** marks that a particular proxy class is currently being generated */ > + private static Object pendingGenerationMarker = new Object(); > +@@ -356,7 +356,7 @@ > + String[] interfaceNames = new String[interfaces.length]; > + > + // for detecting duplicates > +- Set> interfaceSet = new HashSet<>(); > ++ Set> interfaceSet = new HashSet(); > + > + for (int i = 0; i < interfaces.length; i++) { > + /* > +@@ -413,7 +413,7 @@ > + synchronized (loaderToCache) { > + cache = loaderToCache.get(loader); > + if (cache == null) { > +- cache = new HashMap<>(); > ++ cache = new HashMap(); > + loaderToCache.put(loader, cache); > + } > + /* > +--- openjdk-boot/jdk/src/share/classes/java/sql/DriverManager.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/sql/DriverManager.java > +@@ -364,7 +364,7 @@ > + * @return the list of JDBC Drivers loaded by the caller's class loader > + */ > + public static java.util.Enumeration getDrivers() { > +- java.util.Vector result = new java.util.Vector<>(); > ++ java.util.Vector result = new java.util.Vector(); > + java.util.Vector drivers = null; > + > + if (!initialized) { > +--- openjdk-boot/jdk/src/share/classes/java/util/Collections.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/Collections.java > +@@ -1035,7 +1035,7 @@ > + * @return an unmodifiable view of the specified collection. > + */ > + public static Collection unmodifiableCollection(Collection c) { > +- return new UnmodifiableCollection<>(c); > ++ return new UnmodifiableCollection(c); > + } > + > + /** > +@@ -1109,7 +1109,7 @@ > + * @return an unmodifiable view of the specified set. > + */ > + public static Set unmodifiableSet(Set s) { > +- return new UnmodifiableSet<>(s); > ++ return new UnmodifiableSet(s); > + } > + > + /** > +@@ -1141,7 +1141,7 @@ > + * @return an unmodifiable view of the specified sorted set. > + */ > + public static SortedSet unmodifiableSortedSet(SortedSet s) { > +- return new UnmodifiableSortedSet<>(s); > ++ return new UnmodifiableSortedSet(s); > + } > + > + /** > +@@ -1158,13 +1158,13 @@ > + public Comparator comparator() {return ss.comparator();} > + > + public SortedSet subSet(E fromElement, E toElement) { > +- return new UnmodifiableSortedSet<>(ss.subSet(fromElement,toElement)); > ++ return new UnmodifiableSortedSet(ss.subSet(fromElement,toElement)); > + } > + public SortedSet headSet(E toElement) { > +- return new UnmodifiableSortedSet<>(ss.headSet(toElement)); > ++ return new UnmodifiableSortedSet(ss.headSet(toElement)); > + } > + public SortedSet tailSet(E fromElement) { > +- return new UnmodifiableSortedSet<>(ss.tailSet(fromElement)); > ++ return new UnmodifiableSortedSet(ss.tailSet(fromElement)); > + } > + > + public E first() {return ss.first();} > +@@ -1188,8 +1188,8 @@ > + */ > + public static List unmodifiableList(List list) { > + return (list instanceof RandomAccess ? > +- new UnmodifiableRandomAccessList<>(list) : > +- new UnmodifiableList<>(list)); > ++ new UnmodifiableRandomAccessList(list) : > ++ new UnmodifiableList(list)); > + } > + > + /** > +@@ -1250,7 +1250,7 @@ > + } > + > + public List subList(int fromIndex, int toIndex) { > +- return new UnmodifiableList<>(list.subList(fromIndex, toIndex)); > ++ return new UnmodifiableList(list.subList(fromIndex, toIndex)); > + } > + > + /** > +@@ -1267,7 +1267,7 @@ > + */ > + private Object readResolve() { > + return (list instanceof RandomAccess > +- ? new UnmodifiableRandomAccessList<>(list) > ++ ? new UnmodifiableRandomAccessList(list) > + : this); > + } > + } > +@@ -1283,7 +1283,7 @@ > + } > + > + public List subList(int fromIndex, int toIndex) { > +- return new UnmodifiableRandomAccessList<>( > ++ return new UnmodifiableRandomAccessList( > + list.subList(fromIndex, toIndex)); > + } > + > +@@ -1296,7 +1296,7 @@ > + * deserialization. > + */ > + private Object writeReplace() { > +- return new UnmodifiableList<>(list); > ++ return new UnmodifiableList(list); > + } > + } > + > +@@ -1315,7 +1315,7 @@ > + * @return an unmodifiable view of the specified map. > + */ > + public static Map unmodifiableMap(Map m) { > +- return new UnmodifiableMap<>(m); > ++ return new UnmodifiableMap(m); > + } > + > + /** > +@@ -1363,7 +1363,7 @@ > + > + public Set> entrySet() { > + if (entrySet==null) > +- entrySet = new UnmodifiableEntrySet<>(m.entrySet()); > ++ entrySet = new UnmodifiableEntrySet(m.entrySet()); > + return entrySet; > + } > + > +@@ -1400,7 +1400,7 @@ > + return i.hasNext(); > + } > + public Map.Entry next() { > +- return new UnmodifiableEntry<>(i.next()); > ++ return new UnmodifiableEntry(i.next()); > + } > + public void remove() { > + throw new UnsupportedOperationException(); > +@@ -1411,7 +1411,7 @@ > + public Object[] toArray() { > + Object[] a = c.toArray(); > + for (int i=0; i +- a[i] = new UnmodifiableEntry<>((Map.Entry)a[i]); > ++ a[i] = new UnmodifiableEntry((Map.Entry)a[i]); > + return a; > + } > + > +@@ -1422,7 +1422,7 @@ > + Object[] arr = c.toArray(a.length==0 ? a : Arrays.copyOf(a, 0)); > + > + for (int i=0; i +- arr[i] = new UnmodifiableEntry<>((Map.Entry)arr[i]); > ++ arr[i] = new UnmodifiableEntry((Map.Entry)arr[i]); > + > + if (arr.length > a.length) > + return (T[])arr; > +@@ -1443,7 +1443,7 @@ > + if (!(o instanceof Map.Entry)) > + return false; > + return c.contains( > +- new UnmodifiableEntry<>((Map.Entry) o)); > ++ new UnmodifiableEntry((Map.Entry) o)); > + } > + > + /** > +@@ -1517,7 +1517,7 @@ > + * @return an unmodifiable view of the specified sorted map. > + */ > + public static SortedMap unmodifiableSortedMap(SortedMap m) { > +- return new UnmodifiableSortedMap<>(m); > ++ return new UnmodifiableSortedMap(m); > + } > + > + /** > +@@ -1535,13 +1535,13 @@ > + public Comparator comparator() {return sm.comparator();} > + > + public SortedMap subMap(K fromKey, K toKey) { > +- return new UnmodifiableSortedMap<>(sm.subMap(fromKey, toKey)); > ++ return new UnmodifiableSortedMap(sm.subMap(fromKey, toKey)); > + } > + public SortedMap headMap(K toKey) { > +- return new UnmodifiableSortedMap<>(sm.headMap(toKey)); > ++ return new UnmodifiableSortedMap(sm.headMap(toKey)); > + } > + public SortedMap tailMap(K fromKey) { > +- return new UnmodifiableSortedMap<>(sm.tailMap(fromKey)); > ++ return new UnmodifiableSortedMap(sm.tailMap(fromKey)); > + } > + > + public K firstKey() {return sm.firstKey();} > +@@ -1583,11 +1583,11 @@ > + * @return a synchronized view of the specified collection. > + */ > + public static Collection synchronizedCollection(Collection c) { > +- return new SynchronizedCollection<>(c); > ++ return new SynchronizedCollection(c); > + } > + > + static Collection synchronizedCollection(Collection c, Object mutex) { > +- return new SynchronizedCollection<>(c, mutex); > ++ return new SynchronizedCollection(c, mutex); > + } > + > + /** > +@@ -1686,11 +1686,11 @@ > + * @return a synchronized view of the specified set. > + */ > + public static Set synchronizedSet(Set s) { > +- return new SynchronizedSet<>(s); > ++ return new SynchronizedSet(s); > + } > + > + static Set synchronizedSet(Set s, Object mutex) { > +- return new SynchronizedSet<>(s, mutex); > ++ return new SynchronizedSet(s, mutex); > + } > + > + /** > +@@ -1754,7 +1754,7 @@ > + * @return a synchronized view of the specified sorted set. > + */ > + public static SortedSet synchronizedSortedSet(SortedSet s) { > +- return new SynchronizedSortedSet<>(s); > ++ return new SynchronizedSortedSet(s); > + } > + > + /** > +@@ -1783,18 +1783,18 @@ > + > + public SortedSet subSet(E fromElement, E toElement) { > + synchronized (mutex) { > +- return new SynchronizedSortedSet<>( > ++ return new SynchronizedSortedSet( > + ss.subSet(fromElement, toElement), mutex); > + } > + } > + public SortedSet headSet(E toElement) { > + synchronized (mutex) { > +- return new SynchronizedSortedSet<>(ss.headSet(toElement), mutex); > ++ return new SynchronizedSortedSet(ss.headSet(toElement), mutex); > + } > + } > + public SortedSet tailSet(E fromElement) { > + synchronized (mutex) { > +- return new SynchronizedSortedSet<>(ss.tailSet(fromElement),mutex); > ++ return new SynchronizedSortedSet(ss.tailSet(fromElement),mutex); > + } > + } > + > +@@ -1833,14 +1833,14 @@ > + */ > + public static List synchronizedList(List list) { > + return (list instanceof RandomAccess ? > +- new SynchronizedRandomAccessList<>(list) : > +- new SynchronizedList<>(list)); > ++ new SynchronizedRandomAccessList(list) : > ++ new SynchronizedList(list)); > + } > + > + static List synchronizedList(List list, Object mutex) { > + return (list instanceof RandomAccess ? > +- new SynchronizedRandomAccessList<>(list, mutex) : > +- new SynchronizedList<>(list, mutex)); > ++ new SynchronizedRandomAccessList(list, mutex) : > ++ new SynchronizedList(list, mutex)); > + } > + > + /** > +@@ -1903,7 +1903,7 @@ > + > + public List subList(int fromIndex, int toIndex) { > + synchronized (mutex) { > +- return new SynchronizedList<>(list.subList(fromIndex, toIndex), > ++ return new SynchronizedList(list.subList(fromIndex, toIndex), > + mutex); > + } > + } > +@@ -1922,7 +1922,7 @@ > + */ > + private Object readResolve() { > + return (list instanceof RandomAccess > +- ? new SynchronizedRandomAccessList<>(list) > ++ ? new SynchronizedRandomAccessList(list) > + : this); > + } > + } > +@@ -1944,7 +1944,7 @@ > + > + public List subList(int fromIndex, int toIndex) { > + synchronized (mutex) { > +- return new SynchronizedRandomAccessList<>( > ++ return new SynchronizedRandomAccessList( > + list.subList(fromIndex, toIndex), mutex); > + } > + } > +@@ -1958,7 +1958,7 @@ > + * deserialization. > + */ > + private Object writeReplace() { > +- return new SynchronizedList<>(list); > ++ return new SynchronizedList(list); > + } > + } > + > +@@ -1990,7 +1990,7 @@ > + * @return a synchronized view of the specified map. > + */ > + public static Map synchronizedMap(Map m) { > +- return new SynchronizedMap<>(m); > ++ return new SynchronizedMap(m); > + } > + > + /** > +@@ -2051,7 +2051,7 @@ > + public Set keySet() { > + synchronized (mutex) { > + if (keySet==null) > +- keySet = new SynchronizedSet<>(m.keySet(), mutex); > ++ keySet = new SynchronizedSet(m.keySet(), mutex); > + return keySet; > + } > + } > +@@ -2059,7 +2059,7 @@ > + public Set> entrySet() { > + synchronized (mutex) { > + if (entrySet==null) > +- entrySet = new SynchronizedSet<>(m.entrySet(), mutex); > ++ entrySet = new SynchronizedSet(m.entrySet(), mutex); > + return entrySet; > + } > + } > +@@ -2067,7 +2067,7 @@ > + public Collection values() { > + synchronized (mutex) { > + if (values==null) > +- values = new SynchronizedCollection<>(m.values(), mutex); > ++ values = new SynchronizedCollection(m.values(), mutex); > + return values; > + } > + } > +@@ -2129,7 +2129,7 @@ > + * @return a synchronized view of the specified sorted map. > + */ > + public static SortedMap synchronizedSortedMap(SortedMap m) { > +- return new SynchronizedSortedMap<>(m); > ++ return new SynchronizedSortedMap(m); > + } > + > + > +@@ -2159,18 +2159,18 @@ > + > + public SortedMap subMap(K fromKey, K toKey) { > + synchronized (mutex) { > +- return new SynchronizedSortedMap<>( > ++ return new SynchronizedSortedMap( > + sm.subMap(fromKey, toKey), mutex); > + } > + } > + public SortedMap headMap(K toKey) { > + synchronized (mutex) { > +- return new SynchronizedSortedMap<>(sm.headMap(toKey), mutex); > ++ return new SynchronizedSortedMap(sm.headMap(toKey), mutex); > + } > + } > + public SortedMap tailMap(K fromKey) { > + synchronized (mutex) { > +- return new SynchronizedSortedMap<>(sm.tailMap(fromKey),mutex); > ++ return new SynchronizedSortedMap(sm.tailMap(fromKey),mutex); > + } > + } > + > +@@ -2246,7 +2246,7 @@ > + */ > + public static Collection checkedCollection(Collection c, > + Class type) { > +- return new CheckedCollection<>(c, type); > ++ return new CheckedCollection(c, type); > + } > + > + @SuppressWarnings("unchecked") > +@@ -2378,7 +2378,7 @@ > + * @since 1.5 > + */ > + public static Set checkedSet(Set s, Class type) { > +- return new CheckedSet<>(s, type); > ++ return new CheckedSet(s, type); > + } > + > + /** > +@@ -2424,7 +2424,7 @@ > + */ > + public static SortedSet checkedSortedSet(SortedSet s, > + Class type) { > +- return new CheckedSortedSet<>(s, type); > ++ return new CheckedSortedSet(s, type); > + } > + > + /** > +@@ -2484,8 +2484,8 @@ > + */ > + public static List checkedList(List list, Class type) { > + return (list instanceof RandomAccess ? > +- new CheckedRandomAccessList<>(list, type) : > +- new CheckedList<>(list, type)); > ++ new CheckedRandomAccessList(list, type) : > ++ new CheckedList(list, type)); > + } > + > + /** > +@@ -2550,7 +2550,7 @@ > + } > + > + public List subList(int fromIndex, int toIndex) { > +- return new CheckedList<>(list.subList(fromIndex, toIndex), type); > ++ return new CheckedList(list.subList(fromIndex, toIndex), type); > + } > + } > + > +@@ -2567,7 +2567,7 @@ > + } > + > + public List subList(int fromIndex, int toIndex) { > +- return new CheckedRandomAccessList<>( > ++ return new CheckedRandomAccessList( > + list.subList(fromIndex, toIndex), type); > + } > + } > +@@ -2609,7 +2609,7 @@ > + public static Map checkedMap(Map m, > + Class keyType, > + Class valueType) { > +- return new CheckedMap<>(m, keyType, valueType); > ++ return new CheckedMap(m, keyType, valueType); > + } > + > + > +@@ -2677,14 +2677,14 @@ > + // - protection from malicious t > + // - correct behavior if t is a concurrent map > + Object[] entries = t.entrySet().toArray(); > +- List> checked = new ArrayList<>(entries.length); > ++ List> checked = new ArrayList(entries.length); > + for (Object o : entries) { > + Map.Entry e = (Map.Entry) o; > + Object k = e.getKey(); > + Object v = e.getValue(); > + typeCheck(k, v); > + checked.add( > +- new AbstractMap.SimpleImmutableEntry<>((K) k, (V) v)); > ++ new AbstractMap.SimpleImmutableEntry((K) k, (V) v)); > + } > + for (Map.Entry e : checked) > + m.put(e.getKey(), e.getValue()); > +@@ -2694,7 +2694,7 @@ > + > + public Set> entrySet() { > + if (entrySet==null) > +- entrySet = new CheckedEntrySet<>(m.entrySet(), valueType); > ++ entrySet = new CheckedEntrySet(m.entrySet(), valueType); > + return entrySet; > + } > + > +@@ -2809,7 +2809,7 @@ > + if (!(o instanceof Map.Entry)) > + return false; > + return s.remove(new AbstractMap.SimpleImmutableEntry > +- <>((Map.Entry)o)); > ++ ((Map.Entry)o)); > + } > + > + public boolean removeAll(Collection c) { > +@@ -2842,7 +2842,7 @@ > + > + static CheckedEntry checkedEntry(Map.Entry e, > + Class valueType) { > +- return new CheckedEntry<>(e, valueType); > ++ return new CheckedEntry(e, valueType); > + } > + > + /** > +@@ -2883,7 +2883,7 @@ > + if (!(o instanceof Map.Entry)) > + return false; > + return e.equals(new AbstractMap.SimpleImmutableEntry > +- <>((Map.Entry)o)); > ++ ((Map.Entry)o)); > + } > + } > + } > +@@ -2926,7 +2926,7 @@ > + public static SortedMap checkedSortedMap(SortedMap m, > + Class keyType, > + Class valueType) { > +- return new CheckedSortedMap<>(m, keyType, valueType); > ++ return new CheckedSortedMap(m, keyType, valueType); > + } > + > + /** > +@@ -2992,7 +2992,7 @@ > + > + private static class EmptyIterator implements Iterator { > + static final EmptyIterator EMPTY_ITERATOR > +- = new EmptyIterator<>(); > ++ = new EmptyIterator(); > + > + public boolean hasNext() { return false; } > + public E next() { throw new NoSuchElementException(); } > +@@ -3041,7 +3041,7 @@ > + implements ListIterator > + { > + static final EmptyListIterator EMPTY_ITERATOR > +- = new EmptyListIterator<>(); > ++ = new EmptyListIterator(); > + > + public boolean hasPrevious() { return false; } > + public E previous() { throw new NoSuchElementException(); } > +@@ -3077,7 +3077,7 @@ > + > + private static class EmptyEnumeration implements Enumeration { > + static final EmptyEnumeration EMPTY_ENUMERATION > +- = new EmptyEnumeration<>(); > ++ = new EmptyEnumeration(); > + > + public boolean hasMoreElements() { return false; } > + public E nextElement() { throw new NoSuchElementException(); } > +@@ -3089,7 +3089,7 @@ > + * @see #emptySet() > + */ > + @SuppressWarnings("unchecked") > +- public static final Set EMPTY_SET = new EmptySet<>(); > ++ public static final Set EMPTY_SET = new EmptySet(); > + > + /** > + * Returns the empty set (immutable). This set is serializable. > +@@ -3149,7 +3149,7 @@ > + * @see #emptyList() > + */ > + @SuppressWarnings("unchecked") > +- public static final List EMPTY_LIST = new EmptyList<>(); > ++ public static final List EMPTY_LIST = new EmptyList(); > + > + /** > + * Returns the empty list (immutable). This list is serializable. > +@@ -3223,7 +3223,7 @@ > + * @since 1.3 > + */ > + @SuppressWarnings("unchecked") > +- public static final Map EMPTY_MAP = new EmptyMap<>(); > ++ public static final Map EMPTY_MAP = new EmptyMap(); > + > + /** > + * Returns the empty map (immutable). This map is serializable. > +@@ -3285,7 +3285,7 @@ > + * @return an immutable set containing only the specified object. > + */ > + public static Set singleton(T o) { > +- return new SingletonSet<>(o); > ++ return new SingletonSet(o); > + } > + > + static Iterator singletonIterator(final E e) { > +@@ -3338,7 +3338,7 @@ > + * @since 1.3 > + */ > + public static List singletonList(T o) { > +- return new SingletonList<>(o); > ++ return new SingletonList(o); > + } > + > + /** > +@@ -3380,7 +3380,7 @@ > + * @since 1.3 > + */ > + public static Map singletonMap(K key, V value) { > +- return new SingletonMap<>(key, value); > ++ return new SingletonMap(key, value); > + } > + > + /** > +@@ -3422,7 +3422,7 @@ > + public Set> entrySet() { > + if (entrySet==null) > + entrySet = Collections.>singleton( > +- new SimpleImmutableEntry<>(k, v)); > ++ new SimpleImmutableEntry(k, v)); > + return entrySet; > + } > + > +@@ -3454,7 +3454,7 @@ > + public static List nCopies(int n, T o) { > + if (n < 0) > + throw new IllegalArgumentException("List length = " + n); > +- return new CopiesList<>(n, o); > ++ return new CopiesList(n, o); > + } > + > + /** > +@@ -3528,7 +3528,7 @@ > + if (fromIndex > toIndex) > + throw new IllegalArgumentException("fromIndex(" + fromIndex + > + ") > toIndex(" + toIndex + ")"); > +- return new CopiesList<>(toIndex - fromIndex, element); > ++ return new CopiesList(toIndex - fromIndex, element); > + } > + } > + > +@@ -3594,7 +3594,7 @@ > + if (cmp instanceof ReverseComparator2) > + return ((ReverseComparator2)cmp).cmp; > + > +- return new ReverseComparator2<>(cmp); > ++ return new ReverseComparator2(cmp); > + } > + > + /** > +@@ -3673,7 +3673,7 @@ > + * @see ArrayList > + */ > + public static ArrayList list(Enumeration e) { > +- ArrayList l = new ArrayList<>(); > ++ ArrayList l = new ArrayList(); > + while (e.hasMoreElements()) > + l.add(e.nextElement()); > + return l; > +@@ -3818,7 +3818,7 @@ > + * @since 1.6 > + */ > + public static Set newSetFromMap(Map map) { > +- return new SetFromMap<>(map); > ++ return new SetFromMap(map); > + } > + > + /** > +@@ -3882,7 +3882,7 @@ > + * @since 1.6 > + */ > + public static Queue asLifoQueue(Deque deque) { > +- return new AsLIFOQueue<>(deque); > ++ return new AsLIFOQueue(deque); > + } > + > + /** > +--- openjdk-boot/jdk/src/share/classes/java/util/Formatter.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/Formatter.java > +@@ -2490,7 +2490,7 @@ > + * Finds format specifiers in the format string. > + */ > + private FormatString[] parse(String s) { > +- ArrayList al = new ArrayList<>(); > ++ ArrayList al = new ArrayList(); > + Matcher m = fsPattern.matcher(s); > + for (int i = 0, len = s.length(); i < len; ) { > + if (m.find(i)) { > +--- openjdk-boot/jdk/src/share/classes/java/util/HashSet.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/HashSet.java > +@@ -100,7 +100,7 @@ > + * default initial capacity (16) and load factor (0.75). > + */ > + public HashSet() { > +- map = new HashMap<>(); > ++ map = new HashMap(); > + } > + > + /** > +@@ -113,7 +113,7 @@ > + * @throws NullPointerException if the specified collection is null > + */ > + public HashSet(Collection c) { > +- map = new HashMap<>(Math.max((int) (c.size()/.75f) + 1, 16)); > ++ map = new HashMap(Math.max((int) (c.size()/.75f) + 1, 16)); > + addAll(c); > + } > + > +@@ -127,7 +127,7 @@ > + * than zero, or if the load factor is nonpositive > + */ > + public HashSet(int initialCapacity, float loadFactor) { > +- map = new HashMap<>(initialCapacity, loadFactor); > ++ map = new HashMap(initialCapacity, loadFactor); > + } > + > + /** > +@@ -139,7 +139,7 @@ > + * than zero > + */ > + public HashSet(int initialCapacity) { > +- map = new HashMap<>(initialCapacity); > ++ map = new HashMap(initialCapacity); > + } > + > + /** > +@@ -156,7 +156,7 @@ > + * than zero, or if the load factor is nonpositive > + */ > + HashSet(int initialCapacity, float loadFactor, boolean dummy) { > +- map = new LinkedHashMap<>(initialCapacity, loadFactor); > ++ map = new LinkedHashMap(initialCapacity, loadFactor); > + } > + > + /** > +--- openjdk-boot/jdk/src/share/classes/java/util/JumboEnumSet.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/JumboEnumSet.java > +@@ -89,7 +89,7 @@ > + * @return an iterator over the elements contained in this set > + */ > + public Iterator iterator() { > +- return new EnumSetIterator<>(); > ++ return new EnumSetIterator(); > + } > + > + private class EnumSetIterator> implements Iterator { > +--- openjdk-boot/jdk/src/share/classes/java/util/PriorityQueue.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/PriorityQueue.java > +@@ -538,7 +538,7 @@ > + cursor--; > + else { > + if (forgetMeNot == null) > +- forgetMeNot = new ArrayDeque<>(); > ++ forgetMeNot = new ArrayDeque(); > + forgetMeNot.add(moved); > + } > + } else if (lastRetElt != null) { > +--- openjdk-boot/jdk/src/share/classes/java/util/Properties.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/Properties.java > +@@ -1011,7 +1011,7 @@ > + * @since 1.6 > + */ > + public Set stringPropertyNames() { > +- Hashtable h = new Hashtable<>(); > ++ Hashtable h = new Hashtable(); > + enumerateStringProperties(h); > + return h.keySet(); > + } > +--- openjdk-boot/jdk/src/share/classes/java/util/RegularEnumSet.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/RegularEnumSet.java > +@@ -71,7 +71,7 @@ > + * @return an iterator over the elements contained in this set > + */ > + public Iterator iterator() { > +- return new EnumSetIterator<>(); > ++ return new EnumSetIterator(); > + } > + > + private class EnumSetIterator> implements Iterator { > +--- openjdk-boot/jdk/src/share/classes/java/util/ServiceLoader.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/ServiceLoader.java > +@@ -191,7 +191,7 @@ > + private ClassLoader loader; > + > + // Cached providers, in instantiation order > +- private LinkedHashMap providers = new LinkedHashMap<>(); > ++ private LinkedHashMap providers = new LinkedHashMap(); > + > + // The current lazy-lookup iterator > + private LazyIterator lookupIterator; > +@@ -291,7 +291,7 @@ > + { > + InputStream in = null; > + BufferedReader r = null; > +- ArrayList names = new ArrayList<>(); > ++ ArrayList names = new ArrayList(); > + try { > + in = u.openStream(); > + r = new BufferedReader(new InputStreamReader(in, "utf-8")); > +@@ -463,7 +463,7 @@ > + public static ServiceLoader load(Class service, > + ClassLoader loader) > + { > +- return new ServiceLoader<>(service, loader); > ++ return new ServiceLoader(service, loader); > + } > + > + /** > +--- openjdk-boot/jdk/src/share/classes/java/util/TreeSet.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/TreeSet.java > +@@ -138,7 +138,7 @@ > + * ordering} of the elements will be used. > + */ > + public TreeSet(Comparator comparator) { > +- this(new TreeMap<>(comparator)); > ++ this(new TreeMap(comparator)); > + } > + > + /** > +@@ -195,7 +195,7 @@ > + * @since 1.6 > + */ > + public NavigableSet descendingSet() { > +- return new TreeSet<>(m.descendingMap()); > ++ return new TreeSet(m.descendingMap()); > + } > + > + /** > +@@ -322,7 +322,7 @@ > + */ > + public NavigableSet subSet(E fromElement, boolean fromInclusive, > + E toElement, boolean toInclusive) { > +- return new TreeSet<>(m.subMap(fromElement, fromInclusive, > ++ return new TreeSet(m.subMap(fromElement, fromInclusive, > + toElement, toInclusive)); > + } > + > +@@ -335,7 +335,7 @@ > + * @since 1.6 > + */ > + public NavigableSet headSet(E toElement, boolean inclusive) { > +- return new TreeSet<>(m.headMap(toElement, inclusive)); > ++ return new TreeSet(m.headMap(toElement, inclusive)); > + } > + > + /** > +@@ -347,7 +347,7 @@ > + * @since 1.6 > + */ > + public NavigableSet tailSet(E fromElement, boolean inclusive) { > +- return new TreeSet<>(m.tailMap(fromElement, inclusive)); > ++ return new TreeSet(m.tailMap(fromElement, inclusive)); > + } > + > + /** > +@@ -477,7 +477,7 @@ > + throw new InternalError(); > + } > + > +- clone.m = new TreeMap<>(m); > ++ clone.m = new TreeMap(m); > + return clone; > + } > + > +@@ -524,9 +524,9 @@ > + // Create backing TreeMap > + TreeMap tm; > + if (c==null) > +- tm = new TreeMap<>(); > ++ tm = new TreeMap(); > + else > +- tm = new TreeMap<>(c); > ++ tm = new TreeMap(c); > + m = tm; > + > + // Read in size > +--- openjdk-boot/jdk/src/share/classes/java/util/WeakHashMap.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/WeakHashMap.java > +@@ -171,7 +171,7 @@ > + /** > + * Reference queue for cleared WeakEntries > + */ > +- private final ReferenceQueue queue = new ReferenceQueue<>(); > ++ private final ReferenceQueue queue = new ReferenceQueue(); > + > + /** > + * The number of times this WeakHashMap has been structurally modified. > +@@ -439,7 +439,7 @@ > + > + modCount++; > + Entry e = tab[i]; > +- tab[i] = new Entry<>(k, value, queue, h, e); > ++ tab[i] = new Entry(k, value, queue, h, e); > + if (++size >= threshold) > + resize(tab.length * 2); > + return null; > +@@ -955,9 +955,9 @@ > + } > + > + private List> deepCopy() { > +- List> list = new ArrayList<>(size()); > ++ List> list = new ArrayList(size()); > + for (Map.Entry e : this) > +- list.add(new AbstractMap.SimpleEntry<>(e)); > ++ list.add(new AbstractMap.SimpleEntry(e)); > + return list; > + } > + > +--- openjdk-boot/jdk/src/share/classes/java/util/logging/FileHandler.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/logging/FileHandler.java > +@@ -127,7 +127,7 @@ > + private FileOutputStream lockStream; > + private File files[]; > + private static final int MAX_LOCKS = 100; > +- private static java.util.HashMap locks = new java.util.HashMap<>(); > ++ private static java.util.HashMap locks = new java.util.HashMap(); > + > + // A metered stream is a subclass of OutputStream that > + // (a) forwards all its output to a target stream > +--- openjdk-boot/jdk/src/share/classes/java/util/logging/Level.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/logging/Level.java > +@@ -59,7 +59,7 @@ > + */ > + > + public class Level implements java.io.Serializable { > +- private static java.util.ArrayList known = new java.util.ArrayList<>(); > ++ private static java.util.ArrayList known = new java.util.ArrayList(); > + private static String defaultBundle = "sun.util.logging.resources.logging"; > + > + /** > +--- openjdk-boot/jdk/src/share/classes/java/util/logging/LogManager.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/logging/LogManager.java > +@@ -156,7 +156,7 @@ > + private final static Level defaultLevel = Level.INFO; > + > + // Table of named Loggers that maps names to Loggers. > +- private Hashtable namedLoggers = new Hashtable<>(); > ++ private Hashtable namedLoggers = new Hashtable(); > + // Tree of named Loggers > + private LogNode root = new LogNode(null); > + private Logger rootLogger; > +@@ -421,7 +421,7 @@ > + // loggerRefQueue holds LoggerWeakRef objects for Logger objects > + // that have been GC'ed. > + private final ReferenceQueue loggerRefQueue > +- = new ReferenceQueue<>(); > ++ = new ReferenceQueue(); > + > + // Package-level inner class. > + // Helper class for managing WeakReferences to Logger objects. > +@@ -671,7 +671,7 @@ > + name = ""; > + } > + if (node.children == null) { > +- node.children = new HashMap<>(); > ++ node.children = new HashMap(); > + } > + LogNode child = node.children.get(head); > + if (child == null) { > +@@ -855,7 +855,7 @@ > + } > + hands = hands.trim(); > + int ix = 0; > +- Vector result = new Vector<>(); > ++ Vector result = new Vector(); > + while (ix < hands.length()) { > + int end = ix; > + while (end < hands.length()) { > +--- openjdk-boot/jdk/src/share/classes/java/util/logging/LogRecord.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/logging/LogRecord.java > +@@ -85,7 +85,7 @@ > + private static final AtomicInteger nextThreadId > + = new AtomicInteger(MIN_SEQUENTIAL_THREAD_ID); > + > +- private static final ThreadLocal threadIds = new ThreadLocal<>(); > ++ private static final ThreadLocal threadIds = new ThreadLocal(); > + > + /** > + * @serial Logging message level > +--- openjdk-boot/jdk/src/share/classes/java/util/logging/Logger.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/logging/Logger.java > +@@ -170,7 +170,7 @@ > + private LogManager manager; > + private String name; > + private final CopyOnWriteArrayList handlers = > +- new CopyOnWriteArrayList<>(); > ++ new CopyOnWriteArrayList(); > + private String resourceBundleName; > + private volatile boolean useParentHandlers = true; > + private volatile Filter filter; > +@@ -1420,13 +1420,13 @@ > + // Set our new parent. > + parent = newParent; > + if (parent.kids == null) { > +- parent.kids = new ArrayList<>(2); > ++ parent.kids = new ArrayList(2); > + } > + if (ref == null) { > + // we didn't have a previous parent > + ref = manager.new LoggerWeakRef(this); > + } > +- ref.setParentRef(new WeakReference<>(parent)); > ++ ref.setParentRef(new WeakReference(parent)); > + parent.kids.add(ref); > + > + // As a result of the reparenting, the effective level > +--- openjdk-boot/jdk/src/share/classes/java/util/logging/Logging.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/logging/Logging.java > +@@ -56,7 +56,7 @@ > + > + public List getLoggerNames() { > + Enumeration loggers = logManager.getLoggerNames(); > +- ArrayList array = new ArrayList<>(); > ++ ArrayList array = new ArrayList(); > + > + for (; loggers.hasMoreElements();) { > + array.add((String) loggers.nextElement()); > +--- openjdk-boot/jdk/src/share/classes/java/util/prefs/AbstractPreferences.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/prefs/AbstractPreferences.java > +@@ -155,7 +155,7 @@ > + * All known unremoved children of this node. (This "cache" is consulted > + * prior to calling childSpi() or getChild(). > + */ > +- private Map kidCache = new HashMap<>(); > ++ private Map kidCache = new HashMap(); > + > + /** > + * This field is used to keep track of whether or not this node has > +@@ -712,7 +712,7 @@ > + if (removed) > + throw new IllegalStateException("Node has been removed."); > + > +- Set s = new TreeSet<>(kidCache.keySet()); > ++ Set s = new TreeSet(kidCache.keySet()); > + for (String kid : childrenNamesSpi()) > + s.add(kid); > + return s.toArray(EMPTY_STRING_ARRAY); > +@@ -1441,7 +1441,7 @@ > + * event delivery from preference activity, greatly simplifying > + * locking and reducing opportunity for deadlock. > + */ > +- private static final List eventQueue = new LinkedList<>(); > ++ private static final List eventQueue = new LinkedList(); > + > + /** > + * These two classes are used to distinguish NodeChangeEvents on > +--- openjdk-boot/jdk/src/share/classes/java/util/regex/Pattern.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/regex/Pattern.java > +@@ -314,7 +314,7 @@ > + * Nothing, but quotes all characters until \E > + * \E > + * Nothing, but ends quoting started by \Q > +- * > ++ * > + * > + *   > + * Special constructs (named-capturing and non-capturing) > +@@ -1068,7 +1068,7 @@ > + public String[] split(CharSequence input, int limit) { > + int index = 0; > + boolean matchLimited = limit > 0; > +- ArrayList matchList = new ArrayList<>(); > ++ ArrayList matchList = new ArrayList(); > + Matcher m = matcher(input); > + > + // Add segments before each match found > +@@ -1566,7 +1566,7 @@ > + > + Map namedGroups() { > + if (namedGroups == null) > +- namedGroups = new HashMap<>(2); > ++ namedGroups = new HashMap(2); > + return namedGroups; > + } > + > +@@ -5309,7 +5309,7 @@ > + } > + > + private static final HashMap map > +- = new HashMap<>(); > ++ = new HashMap(); > + > + static { > + // Unicode character property aliases, defined in > +--- openjdk-boot/jdk/src/share/classes/java/util/zip/ZipOutputStream.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/zip/ZipOutputStream.java > +@@ -52,8 +52,8 @@ > + } > + > + private XEntry current; > +- private Vector xentries = new Vector<>(); > +- private HashSet names = new HashSet<>(); > ++ private Vector xentries = new Vector(); > ++ private HashSet names = new HashSet(); > + private CRC32 crc = new CRC32(); > + private long written = 0; > + private long locoff = 0; > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/ClassReader.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/ClassReader.java > +@@ -469,7 +469,7 @@ > + > + void readInnerClasses(Class cls) throws IOException { > + int nc = readUnsignedShort(); > +- ArrayList ics = new ArrayList<>(nc); > ++ ArrayList ics = new ArrayList(nc); > + for (int i = 0; i < nc; i++) { > + InnerClass ic = > + new InnerClass(readClassRef(), > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/FixedList.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/FixedList.java > +@@ -45,7 +45,7 @@ > + private final ArrayList flist; > + > + protected FixedList(int capacity) { > +- flist = new ArrayList<>(capacity); > ++ flist = new ArrayList(capacity); > + // initialize the list to null > + for (int i = 0 ; i < capacity ; i++) { > + flist.add(null); > +--- openjdk-boot/jdk/src/share/classes/java/lang/Character.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/lang/Character.java > +@@ -648,7 +648,7 @@ > + */ > + public static final class UnicodeBlock extends Subset { > + > +- private static Map map = new HashMap<>(256); > ++ private static Map map = new HashMap(256); > + > + /** > + * Creates a UnicodeBlock with the given identifier name. > +@@ -4177,7 +4177,7 @@ > + > + private static HashMap aliases; > + static { > +- aliases = new HashMap<>(128); > ++ aliases = new HashMap(128); > + aliases.put("ARAB", ARABIC); > + aliases.put("ARMI", IMPERIAL_ARAMAIC); > + aliases.put("ARMN", ARMENIAN); > +--- openjdk-boot/jdk/src/share/classes/java/lang/CharacterName.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/lang/CharacterName.java > +@@ -81,7 +81,7 @@ > + } while (cpOff < cpEnd); > + strPool = new byte[total - cpEnd]; > + dis.readFully(strPool); > +- refStrPool = new SoftReference<>(strPool); > ++ refStrPool = new SoftReference(strPool); > + } catch (Exception x) { > + throw new InternalError(x.getMessage()); > + } finally { > +--- openjdk-boot/jdk/src/share/classes/java/lang/Package.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/lang/Package.java > +@@ -588,13 +588,13 @@ > + } > + > + // The map of loaded system packages > +- private static Map pkgs = new HashMap<>(31); > ++ private static Map pkgs = new HashMap(31); > + > + // Maps each directory or zip file name to its corresponding url > +- private static Map urls = new HashMap<>(10); > ++ private static Map urls = new HashMap(10); > + > + // Maps each code source url for a jar file to its manifest > +- private static Map mans = new HashMap<>(10); > ++ private static Map mans = new HashMap(10); > + > + private static native String getSystemPackage0(String name); > + private static native String[] getSystemPackages0(); > +--- openjdk-boot/jdk/src/share/classes/java/lang/ProcessBuilder.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/lang/ProcessBuilder.java > +@@ -214,7 +214,7 @@ > + * @param command a string array containing the program and its arguments > + */ > + public ProcessBuilder(String... command) { > +- this.command = new ArrayList<>(command.length); > ++ this.command = new ArrayList(command.length); > + for (String arg : command) > + this.command.add(arg); > + } > +@@ -251,7 +251,7 @@ > + * @return this process builder > + */ > + public ProcessBuilder command(String... command) { > +- this.command = new ArrayList<>(command.length); > ++ this.command = new ArrayList(command.length); > + for (String arg : command) > + this.command.add(arg); > + return this; > +--- openjdk-boot/jdk/src/share/classes/java/lang/Throwable.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/lang/Throwable.java > +@@ -828,7 +828,7 @@ > + // Use the sentinel for a zero-length list > + suppressed = SUPPRESSED_SENTINEL; > + } else { // Copy Throwables to new list > +- suppressed = new ArrayList<>(1); > ++ suppressed = new ArrayList(1); > + for (Throwable t : suppressedExceptions) { > + // Enforce constraints on suppressed exceptions in > + // case of corrupt or malicious stream. > +@@ -911,7 +911,7 @@ > + return; > + > + if (suppressedExceptions == SUPPRESSED_SENTINEL) > +- suppressedExceptions = new ArrayList<>(1); > ++ suppressedExceptions = new ArrayList(1); > + > + assert suppressedExceptions != SUPPRESSED_SENTINEL; > + > +--- openjdk-boot/jdk/src/share/classes/java/lang/reflect/Constructor.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/lang/reflect/Constructor.java > +@@ -144,7 +144,7 @@ > + // which implicitly requires that new java.lang.reflect > + // objects be fabricated for each reflective call on Class > + // objects.) > +- Constructor res = new Constructor<>(clazz, > ++ Constructor res = new Constructor(clazz, > + parameterTypes, > + exceptionTypes, modifiers, slot, > + signature, > +--- openjdk-boot/jdk/src/share/classes/java/lang/reflect/ReflectAccess.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/lang/reflect/ReflectAccess.java > +@@ -84,7 +84,7 @@ > + byte[] annotations, > + byte[] parameterAnnotations) > + { > +- return new Constructor<>(declaringClass, > ++ return new Constructor(declaringClass, > + parameterTypes, > + checkedExceptions, > + modifiers, > +--- openjdk-boot/jdk/src/share/classes/java/util/AbstractList.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/AbstractList.java > +@@ -482,8 +482,8 @@ > + */ > + public List subList(int fromIndex, int toIndex) { > + return (this instanceof RandomAccess ? > +- new RandomAccessSubList<>(this, fromIndex, toIndex) : > +- new SubList<>(this, fromIndex, toIndex)); > ++ new RandomAccessSubList(this, fromIndex, toIndex) : > ++ new SubList(this, fromIndex, toIndex)); > + } > + > + // Comparison and hashing > +@@ -747,7 +747,7 @@ > + } > + > + public List subList(int fromIndex, int toIndex) { > +- return new SubList<>(this, fromIndex, toIndex); > ++ return new SubList(this, fromIndex, toIndex); > + } > + > + private void rangeCheck(int index) { > +@@ -776,6 +776,6 @@ > + } > + > + public List subList(int fromIndex, int toIndex) { > +- return new RandomAccessSubList<>(this, fromIndex, toIndex); > ++ return new RandomAccessSubList(this, fromIndex, toIndex); > + } > + } > +--- openjdk-boot/jdk/src/share/classes/java/util/Arrays.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/Arrays.java > +@@ -2824,7 +2824,7 @@ > + * @return a list view of the specified array > + */ > + public static List asList(T... a) { > +- return new ArrayList<>(a); > ++ return new ArrayList(a); > + } > + > + /** > +--- openjdk-boot/jdk/src/share/classes/java/util/EnumMap.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/EnumMap.java > +@@ -499,7 +499,7 @@ > + int j = 0; > + for (int i = 0; i < vals.length; i++) > + if (vals[i] != null) > +- a[j++] = new AbstractMap.SimpleEntry<>( > ++ a[j++] = new AbstractMap.SimpleEntry( > + keyUniverse[i], unmaskNull(vals[i])); > + return a; > + } > +--- openjdk-boot/jdk/src/share/classes/java/util/EnumSet.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/EnumSet.java > +@@ -110,9 +110,9 @@ > + throw new ClassCastException(elementType + " not an enum"); > + > + if (universe.length <= 64) > +- return new RegularEnumSet<>(elementType, universe); > ++ return new RegularEnumSet(elementType, universe); > + else > +- return new JumboEnumSet<>(elementType, universe); > ++ return new JumboEnumSet(elementType, universe); > + } > + > + /** > +@@ -430,7 +430,7 @@ > + } > + > + Object writeReplace() { > +- return new SerializationProxy<>(this); > ++ return new SerializationProxy(this); > + } > + > + // readObject method for the serialization proxy pattern > +--- openjdk-boot/jdk/src/share/classes/java/util/HashMap.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/HashMap.java > +@@ -763,7 +763,7 @@ > + */ > + void addEntry(int hash, K key, V value, int bucketIndex) { > + Entry e = table[bucketIndex]; > +- table[bucketIndex] = new Entry<>(hash, key, value, e); > ++ table[bucketIndex] = new Entry(hash, key, value, e); > + if (size++ >= threshold) > + resize(2 * table.length); > + } > +@@ -778,7 +778,7 @@ > + */ > + void createEntry(int hash, K key, V value, int bucketIndex) { > + Entry e = table[bucketIndex]; > +- table[bucketIndex] = new Entry<>(hash, key, value, e); > ++ table[bucketIndex] = new Entry(hash, key, value, e); > + size++; > + } > + > +--- openjdk-boot/jdk/src/share/classes/java/util/Hashtable.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/Hashtable.java > +@@ -455,7 +455,7 @@ > + > + // Creates the new entry. > + Entry e = tab[index]; > +- tab[index] = new Entry<>(hash, key, value, e); > ++ tab[index] = new Entry(hash, key, value, e); > + count++; > + return null; > + } > +@@ -579,7 +579,7 @@ > + if (count == 0) { > + return Collections.emptyEnumeration(); > + } else { > +- return new Enumerator<>(type, false); > ++ return new Enumerator(type, false); > + } > + } > + > +@@ -587,7 +587,7 @@ > + if (count == 0) { > + return Collections.emptyIterator(); > + } else { > +- return new Enumerator<>(type, true); > ++ return new Enumerator(type, true); > + } > + } > + > +@@ -929,7 +929,7 @@ > + } > + // Creates the new entry. > + Entry e = tab[index]; > +- tab[index] = new Entry<>(hash, key, value, e); > ++ tab[index] = new Entry(hash, key, value, e); > + count++; > + } > + > +@@ -950,7 +950,7 @@ > + } > + > + protected Object clone() { > +- return new Entry<>(hash, key, value, > ++ return new Entry(hash, key, value, > + (next==null ? null : (Entry) next.clone())); > + } > + > +--- openjdk-boot/jdk/src/share/classes/java/util/IdentityHashMap.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/IdentityHashMap.java > +@@ -1134,7 +1134,7 @@ > + Object[] result = new Object[size]; > + Iterator> it = iterator(); > + for (int i = 0; i < size; i++) > +- result[i] = new AbstractMap.SimpleEntry<>(it.next()); > ++ result[i] = new AbstractMap.SimpleEntry(it.next()); > + return result; > + } > + > +@@ -1146,7 +1146,7 @@ > + .newInstance(a.getClass().getComponentType(), size); > + Iterator> it = iterator(); > + for (int i = 0; i < size; i++) > +- a[i] = (T) new AbstractMap.SimpleEntry<>(it.next()); > ++ a[i] = (T) new AbstractMap.SimpleEntry(it.next()); > + if (a.length > size) > + a[size] = null; > + return a; > +--- openjdk-boot/jdk/src/share/classes/java/util/LinkedHashMap.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/LinkedHashMap.java > +@@ -237,7 +237,7 @@ > + * the chain. > + */ > + void init() { > +- header = new Entry<>(-1, null, null, null); > ++ header = new Entry(-1, null, null, null); > + header.before = header.after = header; > + } > + > +@@ -438,7 +438,7 @@ > + */ > + void createEntry(int hash, K key, V value, int bucketIndex) { > + HashMap.Entry old = table[bucketIndex]; > +- Entry e = new Entry<>(hash, key, value, old); > ++ Entry e = new Entry(hash, key, value, old); > + table[bucketIndex] = e; > + e.addBefore(header); > + size++; > +--- openjdk-boot/jdk/src/share/classes/java/util/LinkedList.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/LinkedList.java > +@@ -122,7 +122,7 @@ > + */ > + private void linkFirst(E e) { > + final Node f = first; > +- final Node newNode = new Node<>(null, e, f); > ++ final Node newNode = new Node(null, e, f); > + first = newNode; > + if (f == null) > + last = newNode; > +@@ -137,7 +137,7 @@ > + */ > + void linkLast(E e) { > + final Node l = last; > +- final Node newNode = new Node<>(l, e, null); > ++ final Node newNode = new Node(l, e, null); > + last = newNode; > + if (l == null) > + first = newNode; > +@@ -153,7 +153,7 @@ > + void linkBefore(E e, Node succ) { > + // assert succ != null; > + final Node pred = succ.prev; > +- final Node newNode = new Node<>(pred, e, succ); > ++ final Node newNode = new Node(pred, e, succ); > + succ.prev = newNode; > + if (pred == null) > + first = newNode; > +@@ -419,7 +419,7 @@ > + > + for (Object o : a) { > + @SuppressWarnings("unchecked") E e = (E) o; > +- Node newNode = new Node<>(pred, e, null); > ++ Node newNode = new Node(pred, e, null); > + if (pred == null) > + first = newNode; > + else > +--- openjdk-boot/jdk/src/share/classes/java/util/ListResourceBundle.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/ListResourceBundle.java > +@@ -187,7 +187,7 @@ > + return; > + > + Object[][] contents = getContents(); > +- HashMap temp = new HashMap<>(contents.length); > ++ HashMap temp = new HashMap(contents.length); > + for (int i = 0; i < contents.length; ++i) { > + // key must be non-null String, value must be non-null > + String key = (String) contents[i][0]; > +--- openjdk-boot/jdk/src/share/classes/java/util/TimSort.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/TimSort.java > +@@ -196,7 +196,7 @@ > + * extending short natural runs to minRun elements, and merging runs > + * to maintain stack invariant. > + */ > +- TimSort ts = new TimSort<>(a, c); > ++ TimSort ts = new TimSort(a, c); > + int minRun = minRunLength(nRemaining); > + do { > + // Identify next run > +--- openjdk-boot/jdk/src/share/classes/java/util/TreeMap.java.orig > ++++ openjdk-boot/jdk/src/share/classes/java/util/TreeMap.java > +@@ -533,7 +533,7 @@ > + // throw NullPointerException > + // > + // compare(key, key); // type check > +- root = new Entry<>(key, value, null); > ++ root = new Entry(key, value, null); > + size = 1; > + modCount++; > + return null; > +@@ -569,7 +569,7 @@ > + return t.setValue(value); > + } while (t != null); > + } > +- Entry e = new Entry<>(key, value, parent); > ++ Entry e = new Entry(key, value, parent); > + if (cmp < 0) > + parent.left = e; > + else > +@@ -1069,14 +1069,14 @@ > + } > + public NavigableSet subSet(E fromElement, boolean fromInclusive, > + E toElement, boolean toInclusive) { > +- return new KeySet<>(m.subMap(fromElement, fromInclusive, > ++ return new KeySet(m.subMap(fromElement, fromInclusive, > + toElement, toInclusive)); > + } > + public NavigableSet headSet(E toElement, boolean inclusive) { > +- return new KeySet<>(m.headMap(toElement, inclusive)); > ++ return new KeySet(m.headMap(toElement, inclusive)); > + } > + public NavigableSet tailSet(E fromElement, boolean inclusive) { > +- return new KeySet<>(m.tailMap(fromElement, inclusive)); > ++ return new KeySet(m.tailMap(fromElement, inclusive)); > + } > + public SortedSet subSet(E fromElement, E toElement) { > + return subSet(fromElement, true, toElement, false); > +@@ -1205,7 +1205,7 @@ > + */ > + static Map.Entry exportEntry(TreeMap.Entry e) { > + return (e == null) ? null : > +- new AbstractMap.SimpleImmutableEntry<>(e); > ++ new AbstractMap.SimpleImmutableEntry(e); > + } > + > + /** > +@@ -2406,7 +2406,7 @@ > + value = (defaultVal != null ? defaultVal : (V) str.readObject()); > + } > + > +- Entry middle = new Entry<>(key, value, null); > ++ Entry middle = new Entry(key, value, null); > + > + // color nodes in non-full bottommost level red > + if (level == redLevel) > +--- openjdk-boot/jdk/src/share/classes/sun/io/Converters.java.orig > ++++ openjdk-boot/jdk/src/share/classes/sun/io/Converters.java > +@@ -120,7 +120,7 @@ > + > + private static Class cache(int type, Object encoding, Class c) { > + SoftReference[] srs = classCache[type]; > +- srs[CACHE_SIZE - 1] = new SoftReference<>(new Object[] { c, encoding }); > ++ srs[CACHE_SIZE - 1] = new SoftReference(new Object[] { c, encoding }); > + moveToFront(srs, CACHE_SIZE - 1); > + return c; > + } > +--- openjdk-boot/jdk/src/solaris/classes/java/lang/ProcessEnvironment.java.orig > ++++ openjdk-boot/jdk/src/solaris/classes/java/lang/ProcessEnvironment.java > +@@ -68,7 +68,7 @@ > + // We cache the C environment. This means that subsequent calls > + // to putenv/setenv from C will not be visible from Java code. > + byte[][] environ = environ(); > +- theEnvironment = new HashMap<>(environ.length/2 + 3); > ++ theEnvironment = new HashMap(environ.length/2 + 3); > + // Read environment variables back to front, > + // so that earlier variables override later ones. > + for (int i = environ.length-1; i > 0; i-=2) > +--- openjdk-boot/jdk/src/solaris/classes/java/util/prefs/FileSystemPreferences.java.orig > ++++ openjdk-boot/jdk/src/solaris/classes/java/util/prefs/FileSystemPreferences.java > +@@ -354,7 +354,7 @@ > + * log against that map. The resulting map is then written back > + * to the disk. > + */ > +- final List changeLog = new ArrayList<>(); > ++ final List changeLog = new ArrayList(); > + > + /** > + * Represents a change to a preference. > +@@ -507,7 +507,7 @@ > + }); > + if (newNode) { > + // These 2 things guarantee node will get wrtten at next flush/sync > +- prefsCache = new TreeMap<>(); > ++ prefsCache = new TreeMap(); > + nodeCreate = new NodeCreate(); > + changeLog.add(nodeCreate); > + } > +@@ -550,7 +550,7 @@ > + loadCache(); > + } catch(Exception e) { > + // assert lastSyncTime == 0; > +- prefsCache = new TreeMap<>(); > ++ prefsCache = new TreeMap(); > + } > + } > + > +@@ -567,7 +567,7 @@ > + AccessController.doPrivileged( > + new PrivilegedExceptionAction() { > + public Void run() throws BackingStoreException { > +- Map m = new TreeMap<>(); > ++ Map m = new TreeMap(); > + long newLastSyncTime = 0; > + try { > + newLastSyncTime = prefsFile.lastModified(); > +@@ -581,7 +581,7 @@ > + prefsFile.renameTo( new File( > + prefsFile.getParentFile(), > + "IncorrectFormatPrefs.xml")); > +- m = new TreeMap<>(); > ++ m = new TreeMap(); > + } else if (e instanceof FileNotFoundException) { > + getLogger().warning("Prefs file removed in background " > + + prefsFile.getPath()); > +@@ -646,7 +646,7 @@ > + return AccessController.doPrivileged( > + new PrivilegedAction() { > + public String[] run() { > +- List result = new ArrayList<>(); > ++ List result = new ArrayList(); > + File[] dirContents = dir.listFiles(); > + if (dirContents != null) { > + for (int i = 0; i < dirContents.length; i++) > +@@ -794,7 +794,7 @@ > + } else if (lastSyncTime != 0 && !dir.exists()) { > + // This node was removed in the background. Playback any changes > + // against a virgin (empty) Map. > +- prefsCache = new TreeMap<>(); > ++ prefsCache = new TreeMap(); > + replayChanges(); > + } > + if (!changeLog.isEmpty()) { > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/boot/ecj-stringswitch.patch > --- a/patches/boot/ecj-stringswitch.patch Wed Jan 26 01:03:53 2011 +0100 > +++ b/patches/boot/ecj-stringswitch.patch Wed Jan 26 01:12:41 2011 +0100 > @@ -1,6 +1,5 @@ > -diff -r c981a387cd86 src/share/classes/com/sun/security/ntlm/NTLM.java > ---- openjdk-boot.orig/jdk/src/share/classes/com/sun/security/ntlm/NTLM.java Mon Nov 22 21:55:09 2010 +0000 > -+++ openjdk-boot/jdk/src/share/classes/com/sun/security/ntlm/NTLM.java Wed Nov 24 00:34:39 2010 +0000 > +--- openjdk-boot/jdk/src/share/classes/com/sun/security/ntlm/NTLM.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/security/ntlm/NTLM.java > @@ -64,17 +64,23 @@ > > protected NTLM(String version) throws NTLMException { > @@ -36,3 +35,161 @@ > try { > fac = SecretKeyFactory.getInstance ("DES"); > cipher = Cipher.getInstance ("DES/ECB/NoPadding"); > +--- openjdk-boot/jdk/src/share/classes/sun/security/util/DisabledAlgorithmConstraints.java.orig > ++++ openjdk-boot/jdk/src/share/classes/sun/security/util/DisabledAlgorithmConstraints.java > +@@ -383,18 +383,17 @@ > + GE; // ">=" > + > + static Operator of(String s) { > +- switch (s) { > +- case "==": > ++ if (s.equals("==")) { > + return EQ; > +- case "!=": > ++ } else if (s.equals("!=")) { > + return NE; > +- case "<": > ++ } else if (s.equals("<")) { > + return LT; > +- case "<=": > ++ } else if (s.equals("<=")) { > + return LE; > +- case ">": > ++ } else if (s.equals(">")) { > + return GT; > +- case ">=": > ++ } else if (s.equals(">=")) { > + return GE; > + } > + > +--- openjdk-boot/jdk/src/share/classes/sun/launcher/LauncherHelper.java.orig > ++++ openjdk-boot/jdk/src/share/classes/sun/launcher/LauncherHelper.java > +@@ -114,23 +114,18 @@ > + String optStr = (opts.length > 1 && opts[1] != null) > + ? opts[1].trim() > + : "all"; > +- switch (optStr) { > +- case "vm": > ++ if (optStr.equals("vm")) { > + printVmSettings(ostream, initialHeapSize, maxHeapSize, > + stackSize, isServer); > +- break; > +- case "properties": > ++ } else if (optStr.equals("properties")) { > + printProperties(ostream); > +- break; > +- case "locale": > ++ } else if (optStr.equals("locale")) { > + printLocale(ostream); > +- break; > +- default: > ++ } else { > + printVmSettings(ostream, initialHeapSize, maxHeapSize, > + stackSize, isServer); > + printProperties(ostream); > + printLocale(ostream); > +- break; > + } > + } > + > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Package.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Package.java > +@@ -1116,30 +1116,25 @@ > + // what is one of { Debug, Compile, Constant, Exceptions, InnerClasses } > + if (verbose > 0) > + Utils.log.info("Stripping "+what.toLowerCase()+" data and attributes..."); > +- switch (what) { > +- case "Debug": > ++ if (what.equals("Debug")) { > + strip("SourceFile"); > + strip("LineNumberTable"); > + strip("LocalVariableTable"); > + strip("LocalVariableTypeTable"); > +- break; > +- case "Compile": > ++ } else if (what.equals("Compile")) { > + // Keep the inner classes normally. > + // Although they have no effect on execution, > + // the Reflection API exposes them, and JCK checks them. > + // NO: // strip("InnerClasses"); > + strip("Deprecated"); > + strip("Synthetic"); > +- break; > +- case "Exceptions": > ++ } else if (what.equals("Exceptions")) { > + // Keep the exceptions normally. > + // Although they have no effect on execution, > + // the Reflection API exposes them, and JCK checks them. > + strip("Exceptions"); > +- break; > +- case "Constant": > ++ } else if (what.equals("Constant")) { > + stripConstantFields(); > +- break; > + } > + } > + > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/ClassReader.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/ClassReader.java > +@@ -351,16 +351,14 @@ > + Object lkey = Attribute.keyForLookup(ctype, name); > + String cmd = (String) attrCommands.get(lkey); > + if (cmd != null) { > +- switch (cmd) { > +- case "pass": > ++ if (cmd.equals("pass")) { > + String message1 = "passing attribute bitwise in " + h; > + throw new Attribute.FormatException(message1, ctype, name, cmd); > +- case "error": > ++ } else if (cmd.equals("error")) { > + String message2 = "attribute not allowed in " + h; > + throw new Attribute.FormatException(message2, ctype, name, cmd); > +- case "strip": > ++ } else if (cmd.equals("strip")) { > + skip(length, name + " attribute in " + h); > +- continue; > + } > + } > + } > +--- openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Driver.java.orig > ++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Driver.java > +@@ -71,15 +71,12 @@ > + { > + // Non-standard, undocumented "--unpack" switch enables unpack mode. > + String arg0 = av.isEmpty() ? "" : av.get(0); > +- switch (arg0) { > +- case "--pack": > ++ if (arg0.equals("--pack")) { > + av.remove(0); > +- break; > +- case "--unpack": > ++ } else if (arg0.equals("--unpack")) { > + av.remove(0); > + doPack = false; > + doUnpack = true; > +- break; > + } > + } > + > +@@ -180,17 +177,13 @@ > + // Deal with remaining non-engine properties: > + for (String opt : avProps.keySet()) { > + String val = avProps.get(opt); > +- switch (opt) { > +- case "--repack": > ++ if (opt.equals("--repack")) { > + doRepack = true; > +- break; > +- case "--no-gzip": > ++ } else if (opt.equals("--no-gzip")) { > + doZip = (val == null); > +- break; > +- case "--log-file=": > ++ } else if (opt.equals("--log-file=")) { > + logFile = val; > +- break; > +- default: > ++ } else { > + throw new InternalError(MessageFormat.format( > + RESOURCE.getString(DriverResource.BAD_OPTION), > + opt, avProps.get(opt))); > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/boot/fontconfig.patch > --- a/patches/boot/fontconfig.patch Wed Jan 26 01:03:53 2011 +0100 > +++ b/patches/boot/fontconfig.patch Wed Jan 26 01:12:41 2011 +0100 > @@ -1,7 +1,6 @@ > -diff -Nru openjdk-boot.orig/jdk/make/sun/awt/Makefile openjdk-boot/jdk/make/sun/awt/Makefile > ---- openjdk-boot.orig/jdk/make/sun/awt/Makefile 2010-03-02 18:01:28.000000000 +0000 > -+++ openjdk-boot/jdk/make/sun/awt/Makefile 2010-03-02 18:01:21.000000000 +0000 > -@@ -402,11 +402,9 @@ > +--- openjdk-boot/jdk/make/sun/awt/Makefile.orig > ++++ openjdk-boot/jdk/make/sun/awt/Makefile > +@@ -407,11 +407,9 @@ > > COMPILEFONTCONFIG_JARFILE = $(BUILDTOOLJARDIR)/compilefontconfig.jar > > @@ -9,7 +8,7 @@ > - $(COMPILEFONTCONFIG_JARFILE) > +$(LIBDIR)/%.bfc: $(GENSRCDIR)/fontconfig/%.bfc > $(prep-target) > -- $(BOOT_JAVA_CMD) -jar $(COMPILEFONTCONFIG_JARFILE) $< $@ > +- $(BOOT_JAVA_CMD) -jar $(COMPILEFONTCONFIG_JARFILE) $(COMPILEFONTCONFIG_FLAGS) $< $@ > - $(install-module-file) > + $(install-file) > $(call chmod-file, 444) > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/boot/revert-6941137.patch > --- a/patches/boot/revert-6941137.patch Wed Jan 26 01:03:53 2011 +0100 > +++ b/patches/boot/revert-6941137.patch Wed Jan 26 01:12:41 2011 +0100 > @@ -1,10 +1,9 @@ > -diff -r c981a387cd86 src/share/classes/sun/util/calendar/ZoneInfoFile.java > ---- openjdk-boot.orig/jdk/src/share/classes/sun/util/calendar/ZoneInfoFile.java Mon Nov 22 21:55:09 2010 +0000 > -+++ openjdk-boot/jdk/src/share/classes/sun/util/calendar/ZoneInfoFile.java Tue Nov 23 23:05:24 2010 +0000 > -@@ -486,7 +486,7 @@ > - String otherDir = getZoneInfoDir(homeDir); > - if (otherDir != null) > - zi = otherDir; > +--- openjdk-boot.orig/jdk/src/share/classes/sun/util/calendar/ZoneInfoFile.java > ++++ openjdk-boot/jdk/src/share/classes/sun/util/calendar/ZoneInfoFile.java > +@@ -479,7 +479,7 @@ > + String zi = System.getProperty("java.home") + > + File.separator + "lib" + File.separator + "zi"; > + try { > - zi = FileSystems.getDefault().getPath(zi).toRealPath(true).toString(); > + zi = new File(zi).getCanonicalPath(); > } catch(Exception e) { > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/boot/revert-6973616.patch > --- a/patches/boot/revert-6973616.patch Wed Jan 26 01:03:53 2011 +0100 > +++ b/patches/boot/revert-6973616.patch Wed Jan 26 01:12:41 2011 +0100 > @@ -1,12 +1,11 @@ > -diff -Nru openjdk-boot.orig/jdk/make/common/shared/Defs-versions.gmk openjdk-boot/jdk/make/common/shared/Defs-versions.gmk > ---- openjdk-boot.orig/jdk/make/common/shared/Defs-versions.gmk 2010-09-06 13:47:55.000000000 +0100 > -+++ openjdk-boot/jdk/make/common/shared/Defs-versions.gmk 2010-09-06 13:54:03.765973618 +0100 > -@@ -191,7 +191,7 @@ > +--- openjdk-boot/jdk/make/common/shared/Defs-versions.gmk.orig > ++++ openjdk-boot/jdk/make/common/shared/Defs-versions.gmk > +@@ -206,7 +206,7 @@ > > # Generic > REQUIRED_ANT_VER = 1.6.3 > -REQUIRED_BOOT_VER = 1.6 > +REQUIRED_BOOT_VER = 1.5 > REQUIRED_FREETYPE_VERSION = 2.2.1 > - REQUIRED_MAKE_VER = 3.78 > + REQUIRED_MAKE_VER = 3.81 > REQUIRED_UNZIP_VER = 5.12 > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/boot/xbootclasspath.patch > --- a/patches/boot/xbootclasspath.patch Wed Jan 26 01:03:53 2011 +0100 > +++ b/patches/boot/xbootclasspath.patch Wed Jan 26 01:12:41 2011 +0100 > @@ -1,6 +1,5 @@ > -diff -Nru openjdk.orig/corba/make/common/shared/Defs-java.gmk openjdk/corba/make/common/shared/Defs-java.gmk > ---- openjdk-boot.orig/corba/make/common/shared/Defs-java.gmk 2010-11-12 01:18:17.000000000 +0000 > -+++ openjdk-boot/corba/make/common/shared/Defs-java.gmk 2010-11-22 17:37:26.447519804 +0000 > +--- openjdk-boot/corba/make/common/shared/Defs-java.gmk.orig > ++++ openjdk-boot/corba/make/common/shared/Defs-java.gmk > @@ -131,26 +131,14 @@ > CLASS_VERSION = -target $(TARGET_CLASS_VERSION) > JAVACFLAGS += $(CLASS_VERSION) > @@ -33,9 +32,8 @@ > > # Override of what javac to use (see deploy workspace) > ifdef JAVAC > -diff -Nru openjdk.orig/jdk/make/common/shared/Defs-java.gmk openjdk/jdk/make/common/shared/Defs-java.gmk > ---- openjdk-boot.orig/jdk/make/common/shared/Defs-java.gmk 2010-11-22 17:32:24.000000000 +0000 > -+++ openjdk-boot/jdk/make/common/shared/Defs-java.gmk 2010-11-22 17:35:30.752202773 +0000 > +--- openjdk-boot/jdk/make/common/shared/Defs-java.gmk.orig > ++++ openjdk-boot/jdk/make/common/shared/Defs-java.gmk > @@ -136,7 +136,7 @@ > JAVACFLAGS += $(OTHER_JAVACFLAGS) > > @@ -57,7 +55,7 @@ > - "-Xbootclasspath/p:$(JAVAC_JAR)" \ > - -jar $(JAVAC_JAR) $(JAVACFLAGS) > - JAVAH_CMD = $(BOOT_JAVA_CMD) \ > -- "-Xbootclasspath/p:$(JAVAH_JAR)$(CLASSPATH_SEPARATOR)$(JAVADOC_JAR)$(CLASSPATH_SEPARATOR)$(JAVAC_JAR)" \ > +- "-Xbootclasspath/p:$(JAVAH_JAR)$(CLASSPATH_SEPARATOR)$(JAVAC_JAR)" \ > - -jar $(JAVAH_JAR) $(JAVAHFLAGS) > JAVADOC_CMD = $(BOOT_JAVA_CMD) \ > "-Xbootclasspath/p:$(JAVADOC_JAR)$(CLASSPATH_SEPARATOR)$(JAVAC_JAR)$(CLASSPATH_SEPARATOR)$(DOCLETS_JAR)" \ > @@ -73,9 +71,8 @@ > endif > > # Override of what javac to use (see deploy workspace) > -diff -Nru openjdk.orig/jdk/make/java/text/base/Makefile openjdk/jdk/make/java/text/base/Makefile > ---- openjdk-boot.orig/jdk/make/java/text/base/Makefile 2010-07-29 21:55:27.000000000 +0100 > -+++ openjdk-boot/jdk/make/java/text/base/Makefile 2010-11-22 17:35:30.768201571 +0000 > +--- openjdk-boot/jdk/make/java/text/base/Makefile.orig > ++++ openjdk-boot/jdk/make/java/text/base/Makefile > @@ -81,8 +81,8 @@ > -sourcepath $(TEXT_SRCDIR) \ > $(TEXT_SOURCES) > @@ -87,9 +84,8 @@ > -o $(TEXT_CLASSDIR) \ > -spec $(UNICODEDATA)/UnicodeData.txt > @$(java-vm-cleanup) > -diff -Nru openjdk.orig/jdk/make/sun/text/Makefile openjdk/jdk/make/sun/text/Makefile > ---- openjdk-boot.orig/jdk/make/sun/text/Makefile 2010-07-29 21:55:29.000000000 +0100 > -+++ openjdk-boot/jdk/make/sun/text/Makefile 2010-11-22 17:35:30.768201571 +0000 > +--- openjdk-boot/jdk/make/sun/text/Makefile.orig > ++++ openjdk-boot/jdk/make/sun/text/Makefile > @@ -86,8 +86,9 @@ > $(BOOT_JAVAC_CMD) -d $(TEXT_CLASSES) \ > -sourcepath $(TEXT_SRCDIR) \ > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/hotspot/default/icedtea-gcc-suffix.patch > --- a/patches/hotspot/default/icedtea-gcc-suffix.patch Wed Jan 26 01:03:53 2011 +0100 > +++ b/patches/hotspot/default/icedtea-gcc-suffix.patch Wed Jan 26 01:12:41 2011 +0100 > @@ -1,6 +1,5 @@ > -diff -Nru openjdk.orig/hotspot/agent/src/os/linux/Makefile openjdk/hotspot/agent/src/os/linux/Makefile > ---- openjdk.orig/hotspot/agent/src/os/linux/Makefile 2010-07-29 21:54:38.000000000 +0100 > -+++ openjdk/hotspot/agent/src/os/linux/Makefile 2010-08-31 17:54:44.523837437 +0100 > +--- openjdk/hotspot/agent/src/os/linux/Makefile.orig > ++++ openjdk/hotspot/agent/src/os/linux/Makefile > @@ -23,7 +23,7 @@ > # > > @@ -10,13 +9,12 @@ > > JAVAH = ${JAVA_HOME}/bin/javah > > -diff -Nru openjdk.orig/hotspot/make/linux/makefiles/gcc.make openjdk/hotspot/make/linux/makefiles/gcc.make > ---- openjdk.orig/hotspot/make/linux/makefiles/gcc.make 2010-08-31 17:24:48.000000000 +0100 > -+++ openjdk/hotspot/make/linux/makefiles/gcc.make 2010-08-31 17:55:09.288779769 +0100 > -@@ -26,11 +26,11 @@ > - # CC, CPP & AS > - > - ifdef ALT_COMPILER_PATH > +--- openjdk/hotspot/make/linux/makefiles/gcc.make.orig > ++++ openjdk/hotspot/make/linux/makefiles/gcc.make > +@@ -28,11 +28,11 @@ > + # When cross-compiling the ALT_COMPILER_PATH points > + # to the cross-compilation toolset > + ifdef CROSS_COMPILE_ARCH > -CPP = $(ALT_COMPILER_PATH)/g++ > -CC = $(ALT_COMPILER_PATH)/gcc > +CPP = $(ALT_COMPILER_PATH)/g++$(GCC_SUFFIX) > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/hotspot/default/icedtea-includedb.patch > --- a/patches/hotspot/default/icedtea-includedb.patch Wed Jan 26 01:03:53 2011 +0100 > +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 > @@ -1,12 +0,0 @@ > -diff -Nru openjdk.orig/hotspot/src/share/vm/gc_implementation/includeDB_gc_parallelScavenge openjdk/hotspot/src/share/vm/gc_implementation/includeDB_gc_parallelScavenge > ---- openjdk.orig/hotspot/src/share/vm/gc_implementation/includeDB_gc_parallelScavenge 2009-02-19 08:40:26.000000000 +0000 > -+++ openjdk/hotspot/src/share/vm/gc_implementation/includeDB_gc_parallelScavenge 2009-02-23 21:09:49.000000000 +0000 > -@@ -308,6 +308,8 @@ > - psPermGen.cpp psMarkSweepDecorator.hpp > - psPermGen.cpp psParallelCompact.hpp > - psPermGen.cpp psPermGen.hpp > -+psPermGen.cpp markOop.inline.hpp > -+psPermGen.cpp markSweep.inline.hpp > - > - psPermGen.hpp psOldGen.hpp > - > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/hotspot/default/icedtea-sparc-trapsfix.patch > --- a/patches/hotspot/default/icedtea-sparc-trapsfix.patch Wed Jan 26 01:03:53 2011 +0100 > +++ b/patches/hotspot/default/icedtea-sparc-trapsfix.patch Wed Jan 26 01:12:41 2011 +0100 > @@ -1,9 +1,8 @@ > -diff -Nru openjdk.orig/hotspot/src/os_cpu/linux_sparc/vm/assembler_linux_sparc.cpp openjdk/hotspot/src/os_cpu/linux_sparc/vm/assembler_linux_sparc.cpp > ---- openjdk.orig/hotspot/src/os_cpu/linux_sparc/vm/assembler_linux_sparc.cpp 2008-08-04 08:40:18.000000000 +0100 > -+++ openjdk/hotspot/src/os_cpu/linux_sparc/vm/assembler_linux_sparc.cpp 2008-08-09 01:29:51.000000000 +0100 > -@@ -25,7 +25,16 @@ > - #include "incls/_precompiled.incl" > - #include "incls/_assembler_linux_sparc.cpp.incl" > +--- openjdk/hotspot/src/os_cpu/linux_sparc/vm/assembler_linux_sparc.cpp.orig > ++++ openjdk/hotspot/src/os_cpu/linux_sparc/vm/assembler_linux_sparc.cpp > +@@ -28,7 +28,16 @@ > + #include "runtime/os.hpp" > + #include "runtime/threadLocalStorage.hpp" > > -#include > +/* Headers for 32bit sparc with a 32bit userland end up in asm/ > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/hotspot/default/icedtea-text-relocations.patch > --- a/patches/hotspot/default/icedtea-text-relocations.patch Wed Jan 26 01:03:53 2011 +0100 > +++ b/patches/hotspot/default/icedtea-text-relocations.patch Wed Jan 26 01:12:41 2011 +0100 > @@ -1,7 +1,6 @@ > -diff -Nru openjdk.orig/hotspot/make/linux/makefiles/gcc.make openjdk/hotspot/make/linux/makefiles/gcc.make > ---- openjdk.orig/hotspot/make/linux/makefiles/gcc.make 2008-07-17 08:40:27.000000000 +0100 > -+++ openjdk/hotspot/make/linux/makefiles/gcc.make 2008-07-21 23:10:50.000000000 +0100 > -@@ -46,7 +46,11 @@ > +--- openjdk/hotspot/make/linux/makefiles/gcc.make.orig > ++++ openjdk/hotspot/make/linux/makefiles/gcc.make > +@@ -58,7 +58,11 @@ > # Compiler flags > > # position-independent code > @@ -13,9 +12,9 @@ > > VM_PICFLAG/LIBJVM = $(PICFLAG) > VM_PICFLAG/AOUT = > ---- rules.make.orig 2008-12-12 11:23:31.000000000 -0500 > -+++ openjdk/hotspot/make/linux/makefiles/rules.make 2008-12-12 11:32:26.000000000 -0500 > -@@ -138,20 +138,10 @@ > +--- openjdk/hotspot/make/linux/makefiles/rules.make.orig > ++++ openjdk/hotspot/make/linux/makefiles/rules.make > +@@ -146,20 +146,10 @@ > include $(GAMMADIR)/make/pic.make > endif > > @@ -24,21 +23,21 @@ > %.o: %.cpp > @echo Compiling $< > $(QUIETLY) $(REMOVE_TARGET) > - $(QUIETLY) $(COMPILE.CC) -o $@ $< $(COMPILE_DONE) > + $(QUIETLY) $(COMPILE.CC) $(DEPFLAGS) -o $@ $< $(COMPILE_DONE) > -else > -%.o: %.cpp > - @echo Compiling $< > - $(QUIETLY) $(REMOVE_TARGET) > - $(QUIETLY) $(if $(findstring $@, $(NONPIC_OBJ_FILES)), \ > -- $(subst $(VM_PICFLAG), ,$(COMPILE.CC)) -o $@ $< $(COMPILE_DONE), \ > -- $(COMPILE.CC) -o $@ $< $(COMPILE_DONE)) > +- $(subst $(VM_PICFLAG), ,$(COMPILE.CC)) $(DEPFLAGS) -o $@ $< $(COMPILE_DONE), \ > +- $(COMPILE.CC) $(DEPFLAGS) -o $@ $< $(COMPILE_DONE)) > -endif > > %.o: %.s > @echo Assembling $< > ---- rules.make.orig 2008-12-12 11:42:55.000000000 -0500 > -+++ openjdk/hotspot/make/solaris/makefiles/rules.make 2008-12-12 11:44:01.000000000 -0500 > -@@ -138,20 +138,10 @@ > +--- openjdk/hotspot/make/solaris/makefiles/rules.make.orig > ++++ openjdk/hotspot/make/solaris/makefiles/rules.make > +@@ -146,20 +146,10 @@ > include $(GAMMADIR)/make/pic.make > endif > > @@ -47,14 +46,14 @@ > %.o: %.cpp > @echo Compiling $< > $(QUIETLY) $(REMOVE_TARGET) > - $(QUIETLY) $(COMPILE.CC) -o $@ $< $(COMPILE_DONE) > + $(QUIETLY) $(COMPILE.CC) $(DEPFLAGS) -o $@ $< $(COMPILE_DONE) > -else > -%.o: %.cpp > - @echo Compiling $< > - $(QUIETLY) $(REMOVE_TARGET) > - $(QUIETLY) $(if $(findstring $@, $(NONPIC_OBJ_FILES)), \ > -- $(subst $(VM_PICFLAG), ,$(COMPILE.CC)) -o $@ $< $(COMPILE_DONE), \ > -- $(COMPILE.CC) -o $@ $< $(COMPILE_DONE)) > +- $(subst $(VM_PICFLAG), ,$(COMPILE.CC)) $(DEPFLAGS) -o $@ $< $(COMPILE_DONE), \ > +- $(COMPILE.CC) $(DEPFLAGS) -o $@ $< $(COMPILE_DONE)) > -endif > > %.o: %.s > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/icedtea-freetypeversion.patch > --- a/patches/icedtea-freetypeversion.patch Wed Jan 26 01:03:53 2011 +0100 > +++ b/patches/icedtea-freetypeversion.patch Wed Jan 26 01:12:41 2011 +0100 > @@ -1,12 +1,11 @@ > -diff -Nru openjdk.orig/jdk/make/common/shared/Defs-versions.gmk openjdk/jdk/make/common/shared/Defs-versions.gmk > ---- openjdk.orig/jdk/make/common/shared/Defs-versions.gmk 2010-08-27 19:16:10.000000000 +0100 > -+++ openjdk/jdk/make/common/shared/Defs-versions.gmk 2010-08-31 19:07:12.239786010 +0100 > -@@ -192,7 +192,7 @@ > +--- openjdk/jdk/make/common/shared/Defs-versions.gmk.orig > ++++ openjdk/jdk/make/common/shared/Defs-versions.gmk > +@@ -207,7 +207,7 @@ > # Generic > REQUIRED_ANT_VER = 1.6.3 > REQUIRED_BOOT_VER = 1.6 > -REQUIRED_FREETYPE_VERSION = 2.3.0 > +REQUIRED_FREETYPE_VERSION = 2.2.1 > - REQUIRED_MAKE_VER = 3.78 > + REQUIRED_MAKE_VER = 3.81 > REQUIRED_UNZIP_VER = 5.12 > REQUIRED_ZIP_VER = 2.2 > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/icedtea-javafiles.patch > --- a/patches/icedtea-javafiles.patch Wed Jan 26 01:03:53 2011 +0100 > +++ b/patches/icedtea-javafiles.patch Wed Jan 26 01:12:41 2011 +0100 > @@ -1,6 +1,5 @@ > -diff -Nru openjdk.orig/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_encoding.jmk openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_encoding.jmk > ---- openjdk.orig/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_encoding.jmk 2010-07-29 21:54:09.000000000 +0100 > -+++ openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_encoding.jmk 2010-09-01 19:20:12.256298401 +0100 > +--- openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_encoding.jmk.orig > ++++ openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_encoding.jmk > @@ -62,7 +62,6 @@ > com/sun/corba/se/impl/encoding/TypeCodeInputStream.java \ > com/sun/corba/se/impl/encoding/TypeCodeOutputStream.java \ > @@ -12,9 +11,8 @@ > + com/sun/corba/se/impl/encoding/WrapperInputStream.java \ > + com/sun/corba/se/impl/encoding/IDLJavaSerializationInputStream.java \ > + com/sun/corba/se/impl/encoding/IDLJavaSerializationOutputStream.java > -diff -Nru openjdk.orig/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_ior.jmk openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_ior.jmk > ---- openjdk.orig/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_ior.jmk 2010-07-29 21:54:09.000000000 +0100 > -+++ openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_ior.jmk 2010-09-01 19:20:12.264297713 +0100 > +--- openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_ior.jmk.orig > ++++ openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_ior.jmk > @@ -66,4 +66,5 @@ > com/sun/corba/se/impl/ior/iiop/JavaSerializationComponent.java \ > com/sun/corba/se/impl/ior/iiop/MaxStreamFormatVersionComponentImpl.java \ > @@ -22,9 +20,8 @@ > - com/sun/corba/se/impl/ior/iiop/ORBTypeComponentImpl.java > + com/sun/corba/se/impl/ior/iiop/ORBTypeComponentImpl.java \ > + com/sun/corba/se/impl/ior/iiop/JavaSerializationComponent.java > -diff -Nru openjdk.orig/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_orbutil.jmk openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_orbutil.jmk > ---- openjdk.orig/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_orbutil.jmk 2010-07-29 21:54:09.000000000 +0100 > -+++ openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_orbutil.jmk 2010-09-01 19:20:12.264297713 +0100 > +--- openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_orbutil.jmk.orig > ++++ openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_orbutil.jmk > @@ -81,4 +81,5 @@ > com/sun/corba/se/impl/orbutil/graph/Node.java \ > com/sun/corba/se/impl/orbutil/graph/NodeData.java \ > @@ -32,9 +29,8 @@ > - com/sun/corba/se/impl/orbutil/graph/GraphImpl.java > + com/sun/corba/se/impl/orbutil/graph/GraphImpl.java \ > + com/sun/corba/se/impl/orbutil/GetPropertyAction.java > -diff -Nru openjdk.orig/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_protocol.jmk openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_protocol.jmk > ---- openjdk.orig/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_protocol.jmk 2010-07-29 21:54:09.000000000 +0100 > -+++ openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_protocol.jmk 2010-09-01 19:20:12.264297713 +0100 > +--- openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_protocol.jmk.orig > ++++ openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_impl_protocol.jmk > @@ -81,5 +81,5 @@ > com/sun/corba/se/impl/protocol/giopmsgheaders/RequestMessage_1_1.java \ > com/sun/corba/se/impl/protocol/giopmsgheaders/RequestMessage_1_2.java \ > @@ -43,9 +39,8 @@ > - > + com/sun/corba/se/impl/protocol/giopmsgheaders/TargetAddressHelper.java \ > + com/sun/corba/se/impl/protocol/giopmsgheaders/LocateReplyOrReplyMessage.java > -diff -Nru openjdk.orig/corba/make/com/sun/corba/minclude/com_sun_corba_se_spi_monitoring.jmk openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_spi_monitoring.jmk > ---- openjdk.orig/corba/make/com/sun/corba/minclude/com_sun_corba_se_spi_monitoring.jmk 2010-07-29 21:54:09.000000000 +0100 > -+++ openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_spi_monitoring.jmk 2010-09-01 19:20:12.264297713 +0100 > +--- openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_spi_monitoring.jmk.orig > ++++ openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_spi_monitoring.jmk > @@ -30,6 +30,7 @@ > com/sun/corba/se/spi/monitoring/StringMonitoredAttributeBase.java \ > com/sun/corba/se/spi/monitoring/LongMonitoredAttributeBase.java \ > @@ -54,9 +49,8 @@ > com/sun/corba/se/spi/monitoring/MonitoredAttributeInfo.java \ > com/sun/corba/se/spi/monitoring/MonitoredObject.java \ > com/sun/corba/se/spi/monitoring/MonitoredObjectFactory.java \ > -diff -Nru openjdk.orig/corba/make/com/sun/corba/minclude/com_sun_corba_se_spi_presentation_rmi.jmk openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_spi_presentation_rmi.jmk > ---- openjdk.orig/corba/make/com/sun/corba/minclude/com_sun_corba_se_spi_presentation_rmi.jmk 2010-07-29 21:54:09.000000000 +0100 > -+++ openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_spi_presentation_rmi.jmk 2010-09-01 19:20:12.264297713 +0100 > +--- openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_spi_presentation_rmi.jmk.orig > ++++ openjdk/corba/make/com/sun/corba/minclude/com_sun_corba_se_spi_presentation_rmi.jmk > @@ -29,5 +29,6 @@ > com/sun/corba/se/spi/presentation/rmi/IDLNameTranslator.java \ > com/sun/corba/se/spi/presentation/rmi/PresentationDefaults.java \ > @@ -64,9 +58,8 @@ > + com/sun/corba/se/spi/presentation/rmi/PresentationDefaults.java \ > com/sun/corba/se/spi/presentation/rmi/StubAdapter.java > > -diff -Nru openjdk.orig/jdk/make/java/java/FILES_java.gmk openjdk/jdk/make/java/java/FILES_java.gmk > ---- openjdk.orig/jdk/make/java/java/FILES_java.gmk 2010-07-29 21:55:26.000000000 +0100 > -+++ openjdk/jdk/make/java/java/FILES_java.gmk 2010-09-01 19:20:12.268297371 +0100 > +--- openjdk/jdk/make/java/java/FILES_java.gmk.orig > ++++ openjdk/jdk/make/java/java/FILES_java.gmk > @@ -29,6 +29,80 @@ > # will generate header files > # > @@ -148,9 +141,9 @@ > java/lang/Object.java \ > java/lang/AutoCloseable.java \ > java/lang/Class.java \ > -@@ -138,13 +212,6 @@ > - java/lang/Readable.java \ > +@@ -139,13 +213,6 @@ > java/lang/Override.java \ > + java/lang/SafeVarargs.java \ > java/lang/SuppressWarnings.java \ > - java/lang/ref/Reference.java \ > - java/lang/ref/SoftReference.java \ > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/icedtea-lc_ctype.patch > --- a/patches/icedtea-lc_ctype.patch Wed Jan 26 01:03:53 2011 +0100 > +++ b/patches/icedtea-lc_ctype.patch Wed Jan 26 01:12:41 2011 +0100 > @@ -1,31 +1,28 @@ > -diff -Nru openjdk.orig/jdk/src/solaris/native/java/lang/java_props_md.c openjdk/jdk/src/solaris/native/java/lang/java_props_md.c > ---- openjdk.orig/jdk/src/solaris/native/java/lang/java_props_md.c 2010-11-12 01:20:49.000000000 +0000 > -+++ openjdk/jdk/src/solaris/native/java/lang/java_props_md.c 2010-11-12 18:31:00.049493600 +0000 > -@@ -118,7 +118,7 @@ > - #endif > +--- openjdka/jdk/src/solaris/native/java/lang/java_props_md.c > ++++ openjdk/jdk/src/solaris/native/java/lang/java_props_md.c > +@@ -119,7 +119,7 @@ > > - static int ParseLocale(int cat, char ** std_language, char ** std_country, char ** std_variant, char ** std_encoding) { > + static int ParseLocale(int cat, char ** std_language, char ** std_script, > + char ** std_country, char ** std_variant, char ** std_encoding) { > - char temp[64]; > + char *temp; > char *language = NULL, *country = NULL, *variant = NULL, > *encoding = NULL; > char *p, encoding_variant[64]; > -@@ -162,6 +162,7 @@ > +@@ -162,7 +162,7 @@ > + * _.@ > * , , and are optional. > */ > - > +- > + temp = (char*) malloc(strlen(lc)+1); > strcpy(temp, lc); > > /* Parse the language, country, encoding, and variant from the > -@@ -282,6 +283,10 @@ > +@@ -301,6 +301,7 @@ > #endif > } > > -+ > -+ /* Free temp */ > -+ free(temp); > -+ > ++ free (temp); > return 1; > } > > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/icedtea-signed-types.patch > --- a/patches/icedtea-signed-types.patch Wed Jan 26 01:03:53 2011 +0100 > +++ b/patches/icedtea-signed-types.patch Wed Jan 26 01:12:41 2011 +0100 > @@ -1,7 +1,6 @@ > -diff -Nru openjdk.orig/hotspot/src/share/vm/asm/codeBuffer.hpp openjdk/hotspot/src/share/vm/asm/codeBuffer.hpp > ---- openjdk.orig/hotspot/src/share/vm/asm/codeBuffer.hpp 2008-05-27 21:18:54.000000000 +0100 > -+++ openjdk/hotspot/src/share/vm/asm/codeBuffer.hpp 2008-05-27 21:56:42.000000000 +0100 > -@@ -81,7 +81,7 @@ > +--- openjdk/hotspot/src/share/vm/asm/codeBuffer.hpp.orig > ++++ openjdk/hotspot/src/share/vm/asm/codeBuffer.hpp > +@@ -93,7 +93,7 @@ > address _locs_point; // last relocated position (grows upward) > bool _locs_own; // did I allocate the locs myself? > bool _frozen; // no more expansion of this section > @@ -10,22 +9,20 @@ > CodeBuffer* _outer; // enclosing CodeBuffer > > // (Note: _locs_point used to be called _last_reloc_offset.) > -diff -Nru openjdk.orig/hotspot/src/share/vm/utilities/ostream.cpp openjdk/hotspot/src/share/vm/utilities/ostream.cpp > ---- openjdk.orig/hotspot/src/share/vm/utilities/ostream.cpp 2008-05-27 21:18:54.000000000 +0100 > -+++ openjdk/hotspot/src/share/vm/utilities/ostream.cpp 2008-05-27 21:59:01.000000000 +0100 > -@@ -829,7 +829,7 @@ > +--- openjdk/hotspot/src/share/vm/utilities/ostream.cpp.orig > ++++ openjdk/hotspot/src/share/vm/utilities/ostream.cpp > +@@ -915,7 +915,7 @@ > server.sin_port = htons(port); > > server.sin_addr.s_addr = inet_addr(ip); > - if (server.sin_addr.s_addr == (uint32_t)-1) { > + if (server.sin_addr.s_addr == (in_addr_t)-1) { > - #ifdef _WINDOWS > - struct hostent* host = hpi::get_host_by_name((char*)ip); > - #else > -diff -r ca98ea212429 openjdk/hotspot/src/share/vm/ci/ciTypeFlow.cpp > ---- openjdk/hotspot/src/share/vm/ci/ciTypeFlow.cpp Fri Aug 08 16:06:52 2008 +0100 > -+++ openjdk/hotspot/src/share/vm/ci/ciTypeFlow.cpp Fri Aug 08 16:15:45 2008 +0100 > -@@ -388,7 +388,7 @@ const ciTypeFlow::StateVector* ciTypeFlo > + struct hostent* host = os::get_host_by_name((char*)ip); > + if (host != NULL) { > + memcpy(&server.sin_addr, host->h_addr_list[0], host->h_length); > +--- openjdk/hotspot/src/share/vm/ci/ciTypeFlow.cpp.orig > ++++ openjdk/hotspot/src/share/vm/ci/ciTypeFlow.cpp > +@@ -403,7 +403,7 @@ > // Set the rest of the locals to bottom. > Cell cell = state->next_cell(state->tos()); > state->set_stack_size(0); > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/icedtea-ssl.patch > --- a/patches/icedtea-ssl.patch Wed Jan 26 01:03:53 2011 +0100 > +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 > @@ -1,43 +0,0 @@ > ---- ../openjdkb23/openjdk/jdk/src/share/classes/sun/security/ssl/Handshaker.java 2007-10-30 04:38:10.000000000 -0400 > -+++ openjdk/jdk/src/share/classes/sun/security/ssl/Handshaker.java 2007-11-13 13:06:01.000000000 -0500 > -@@ -36,6 +36,7 @@ > - import java.security.PrivilegedExceptionAction; > - import java.security.PrivilegedActionException; > - import java.security.cert.X509Certificate; > -+import java.security.spec.AlgorithmParameterSpec; > - > - import javax.crypto.*; > - import javax.crypto.spec.*; > -@@ -688,8 +683,8 @@ > - SecretKey masterSecret; > - try { > - KeyGenerator kg = JsseJce.getKeyGenerator("SunTlsMasterSecret"); > -- kg.init(spec); > -- masterSecret = kg.generateKey(); > -+ kg.init((AlgorithmParameterSpec) spec); > -+ masterSecret = kg.generateKey(); > - } catch (GeneralSecurityException e) { > - // For RSA premaster secrets, do not signal a protocol error > - // due to the Bleichenbacher attack. See comments further down. > ---- ../openjdkb23/openjdk/jdk/src/share/classes/sun/security/ssl/RSAClientKeyExchange.java 2007-10-30 04:38:10.000000000 -0400 > -+++ openjdk/jdk/src/share/classes/sun/security/ssl/RSAClientKeyExchange.java 2007-11-13 13:06:42.000000000 -0500 > -@@ -36,6 +36,8 @@ > - import javax.net.ssl.*; > - > - import sun.security.internal.spec.TlsRsaPremasterSecretParameterSpec; > -+import java.security.spec.AlgorithmParameterSpec; > -+ > - > - /** > - * This is the client key exchange message (CLIENT --> SERVER) used with > -@@ -104,8 +106,8 @@ > - > - try { > - KeyGenerator kg = JsseJce.getKeyGenerator("SunTlsRsaPremasterSecret"); > -- kg.init(new TlsRsaPremasterSecretParameterSpec(major, minor)); > -- preMaster = kg.generateKey(); > -+ kg.init((AlgorithmParameterSpec) (new TlsRsaPremasterSecretParameterSpec(major, minor))); > -+ preMaster = kg.generateKey(); > - > - Cipher cipher = JsseJce.getCipher(JsseJce.CIPHER_RSA_PKCS1); > - cipher.init(Cipher.WRAP_MODE, publicKey, generator); > diff -r e5b43d618ab5 -r 43fd56d0ce89 patches/no-precompiled.patch > --- a/patches/no-precompiled.patch Wed Jan 26 01:03:53 2011 +0100 > +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 > @@ -1,35 +0,0 @@ > ---- openjdk/hotspot/make/linux/makefiles/gcc.make~ 2009-10-30 11:54:26.000000000 +0100 > -+++ openjdk/hotspot/make/linux/makefiles/gcc.make 2009-10-30 11:55:34.000000000 +0100 > -@@ -34,13 +34,14 @@ > - CC_VER_MAJOR := $(shell $(CC) -dumpversion | sed 's/egcs-//' | cut -d'.' -f1) > - CC_VER_MINOR := $(shell $(CC) -dumpversion | sed 's/egcs-//' | cut -d'.' -f2) > - > -+ifeq (,$(DISABLE_PRECOMPILED_HEADER)) > - # check for precompiled headers support > - ifneq "$(shell expr \( $(CC_VER_MAJOR) \> 3 \) \| \( \( $(CC_VER_MAJOR) = 3 \) \& \( $(CC_VER_MINOR) \>= 4 \) \))" "0" > - USE_PRECOMPILED_HEADER=1 > - PRECOMPILED_HEADER_DIR=. > - PRECOMPILED_HEADER=$(PRECOMPILED_HEADER_DIR)/incls/_precompiled.incl.gch > - endif > -- > -+endif > - > - #------------------------------------------------------------------------ > - # Compiler flags > ---- openjdk/hotspot/make/solaris/makefiles/gcc.make~ 2009-10-30 11:54:26.000000000 +0100 > -+++ openjdk/hotspot/make/solaris/makefiles/gcc.make 2009-10-30 11:56:05.000000000 +0100 > -@@ -45,12 +45,14 @@ > - $(shell $(CC) -dumpversion | sed 's/egcs-//' | cut -d'.' -f2) > - > - > -+ifeq (,$(DISABLE_PRECOMPILED_HEADER)) > - # check for precompiled headers support > - ifneq "$(shell expr \( $(CC_VER_MAJOR) \> 3 \) \| \( \( $(CC_VER_MAJOR) = 3 \) \& \( $(CC_VER_MINOR) \>= 4 \) \))" "0" > - USE_PRECOMPILED_HEADER=1 > - PRECOMPILED_HEADER_DIR=. > - PRECOMPILED_HEADER=$(PRECOMPILED_HEADER_DIR)/incls/_precompiled.incl.gch > - endif > -+endif > - > - > - #------------------------------------------------------------------------ -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From mark at klomp.org Wed Jan 26 04:51:41 2011 From: mark at klomp.org (Mark Wielaard) Date: Wed, 26 Jan 2011 13:51:41 +0100 Subject: [icedtea] Patch for OpenJDK7 b126 support In-Reply-To: <20110126022502.GH18564@rivendell.middle-earth.co.uk> References: <201101242233.04697.drazzib@drazzib.com> <20110124233300.GK17602@rivendell.middle-earth.co.uk> <201101260114.51515.drazzib@drazzib.com> <20110126022502.GH18564@rivendell.middle-earth.co.uk> Message-ID: <1296046301.2966.31.camel@springer.wildebeest.org> On Wed, 2011-01-26 at 02:25 +0000, Dr Andrew John Hughes wrote: > On 01:14 Wed 26 Jan , Damien Raude-Morvan wrote: > > Yes, I've successfuly build a b126 Icedtea+OpenJDK using patch I've send > > yesterday and using Debian toolkit for building [0] (ie. it just prepare > > configure options and apply some more patches). > > > > To get tarballs, I'm using OpenJDK7 forest [1] and a simple script to > > 1) obtain revision by parsing .hgtags and grep "b126" > > 2) wget ${JDK_URL}/${module}/archive/${rev}.tar.gz > > 3) compute sha256sum && update Makefile.am > > > > [0] https://code.launchpad.net/~drazzib/openjdk/openjdk7 > > [1] http://hg.openjdk.java.net/jdk7/jdk7 > > > > We use http://hg.openjdk.java.net/icedtea/jdk7 as the basis for IcedTea7 > as mentioned on http://icedtea.classpath.org/wiki/Main_Page I was thinking we maybe need a similar setup to icedtea6, which has icedtea6-hg for this purpose. Or am I missing something and is this "double redirection" of hg trees/forests easier to handle? Thanks, Mark From ahughes at redhat.com Wed Jan 26 05:15:25 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Wed, 26 Jan 2011 13:15:25 +0000 Subject: [icedtea] Patch for OpenJDK7 b126 support In-Reply-To: <1296046301.2966.31.camel@springer.wildebeest.org> References: <201101242233.04697.drazzib@drazzib.com> <20110124233300.GK17602@rivendell.middle-earth.co.uk> <201101260114.51515.drazzib@drazzib.com> <20110126022502.GH18564@rivendell.middle-earth.co.uk> <1296046301.2966.31.camel@springer.wildebeest.org> Message-ID: <20110126131525.GB21785@rivendell.middle-earth.co.uk> On 13:51 Wed 26 Jan , Mark Wielaard wrote: > On Wed, 2011-01-26 at 02:25 +0000, Dr Andrew John Hughes wrote: > > On 01:14 Wed 26 Jan , Damien Raude-Morvan wrote: > > > Yes, I've successfuly build a b126 Icedtea+OpenJDK using patch I've send > > > yesterday and using Debian toolkit for building [0] (ie. it just prepare > > > configure options and apply some more patches). > > > > > > To get tarballs, I'm using OpenJDK7 forest [1] and a simple script to > > > 1) obtain revision by parsing .hgtags and grep "b126" > > > 2) wget ${JDK_URL}/${module}/archive/${rev}.tar.gz > > > 3) compute sha256sum && update Makefile.am > > > > > > [0] https://code.launchpad.net/~drazzib/openjdk/openjdk7 > > > [1] http://hg.openjdk.java.net/jdk7/jdk7 > > > > > > > We use http://hg.openjdk.java.net/icedtea/jdk7 as the basis for IcedTea7 > > as mentioned on http://icedtea.classpath.org/wiki/Main_Page > > I was thinking we maybe need a similar setup to icedtea6, which has > icedtea6-hg for this purpose. Or am I missing something and is this > "double redirection" of hg trees/forests easier to handle? > At the moment, it's like comparing apples and oranges. The icedtea6 tree is based on a release tarball (currently b21) provided by Oracle. The space between such releases is often months (7 between b20 and b21). icedtea6-hg was created to work not against a tarball, but directly against the upstream forest (i.e. it should be built with --enable-hg or by pointing --with-openjdk-src-dir at an existing checkout). While IcedTea6 uses release n, icedtea6-hg tracks the development of release n+1. When release n+1 is finalised and released, the changesets from icedtea6-hg are pulled into icedtea6. icedtea6-hg also pulls regularly from icedtea6 to keep in sync with our changes. The point of this is that it makes it easier to support new releases. Rather than trying to make all the necessary changes on release, they are made as changesets go in (e.g. we upstream a patch so it is removed from icedtea6-hg). We've used this for the last couple of releases, and it seems to have resulted in a smoother transition to the new release. In contrast, 7 has a much more rapid release schedule. Releases occur on a weekly or bi-weekly basis, so rather than it being a case of us watching hg until new releases come out, we can't keep up with the releases (especially as 7 obviously has lower priority than work on 6). The IcedTea forest allows us to pull in a particular release, add any additional fixes we need to make things work (either from IcedTea or upstream trees) and stabilise on a particular point. We do this by using explicit changesets from the forest, whereas icedtea6-hg is meant to build against the live repository. When we ship a release of IcedTea7, it's against a known point and won't be broken by changes pushed by Oracle. In short, if we had either icedtea7 or a new tree, icedtea7-hg, tracking the jdk7 tree, it would be unmaintainable as it would break on at least a weekly basis. As things stabilise with 7, I expect it to shift to a process more like icedtea6/icedtea6-hg and for 8 to take over the current 7 model. Where I do hope 7 won't be like 6 is that we have much more active participation from Oracle developers. At present, we are still finding changesets over a year old that went into Oracle's proprietary JDK6 release but have never been backported to OpenJDK6. I hope that, for 7, Oracle will be much more active in maintaining it. > Thanks, > > Mark > Hope that helps, -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Wed Jan 26 11:02:21 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Wed, 26 Jan 2011 19:02:21 +0000 Subject: [icedtea-web] RFE: Fix for broken JRE dir install In-Reply-To: <20110125235737.GA20834@redhat.com> References: <20110121004614.GG4611@rivendell.middle-earth.co.uk> <20110121011017.GF22586@redhat.com> <20110121013228.GI4611@rivendell.middle-earth.co.uk> <20110121025333.GA24487@redhat.com> <20110121133540.GC13935@rivendell.middle-earth.co.uk> <20110121151327.GA10878@redhat.com> <20110121204649.GB21893@rivendell.middle-earth.co.uk> <20110121224039.GA3954@redhat.com> <20110122012326.GG21893@rivendell.middle-earth.co.uk> <20110125235737.GA20834@redhat.com> Message-ID: <20110126190220.GH21785@rivendell.middle-earth.co.uk> On 18:57 Tue 25 Jan , Deepak Bhole wrote: > * Dr Andrew John Hughes [2011-01-21 20:23]: > > On 17:40 Fri 21 Jan , Deepak Bhole wrote: > > > > > > > > IcedTea-Web does not 'put things in JDK_HOME/bin'. It puts them in > > ${bindir} which defaults to ${prefix}/bin. That's only equal to > > JDK_HOME/bin if ${prefix} is set to JDK_HOME. For a general application, > > ${bindir} is the primary location. > > > > That said, I support adding the $(JRE_DIR_PREFIX) hack to IcedTea-Web 1.0 > > as I said before. You just need to do in the patch what you say in the mail ;-) > > > > Having thought more about different RPM scenarios, I can see what you > mean now. I was incorrectly understanding the install requirements > earlier. I have updated the patch to remove the linking changes. Sorry > for the unnecessary confusion. > > I did however update it to use relative symlinks i.e. something like: > > jre/bin/javaws -> ../../bin/javaws > > Rather than the current way which creates absolute links (and makes the tree > un-relocatable). > To do this, > + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) should also be changed to create $(DESTDIR)$(prefix)/bin instead of $(DESTDIR)$(bindir). The patch below will break if $(bindir) != $(prefix)/bin. Clearly, this breaks the use of --bindir. > As with previous iterations of the patch, this would be for 1.0 only. > Indeed. For 1.1, it should install like a normal application and respect the user's configure settings without all this Java craziness. That will involve removing all these hardcoded jre/bin references altogether. > ChangeLog: > 2011-01-25 Deepak Bhole > > * Makefile.am > ($(NETX_DIR)/launcher/%.o): Build javaws without the > "-J-Djava.icedtea-web.bin=..." arg. > (install-exec-local): Use new JRE_DIR_PREFIX variables rather than > hardcoded '/jre' in pathname. Create relative links in jre/bin rather than > absolute ones. > (install-data-local): Use new JRE_DIR_PREFIX variables rather than > hardcoded '/jre' in pathname. > (uninstall-local): Same. Also, remove all parent dirs of $(htmldir) until > a non-empty one is encountered. > * configure.ac: Set JRE_DIR_PREFIX to jre/ if prefix is a JDK dir and set > it to empty if prefix apears to be a JRE dir. > * netx/net/sourceforge/jnlp/Launcher.java (launchExternal): Revert back to > using java.home when selecting javaws binary to execute for fork. > > > Cheers, > Deepak > diff -r 43212217e9c0 Makefile.am > --- a/Makefile.am Wed Dec 15 10:17:51 2010 -0500 > +++ b/Makefile.am Tue Jan 25 18:47:27 2011 -0500 > @@ -102,37 +102,37 @@ > clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs > > install-exec-local: > - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) > + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > if ENABLE_PLUGIN > - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ > + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) > - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > endif > - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > fi ; \ > if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > + ln -s ../../bin/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > fi ; \ > fi > - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > fi ; \ > if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > + ln -s ../../bin/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > fi ; \ > fi > > install-data-local: > ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 > ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 > - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib > + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > if ENABLE_DOCS > ${mkinstalldirs} $(DESTDIR)$(htmldir) > (cd ${abs_top_builddir}/docs/netx; \ > @@ -150,23 +150,25 @@ > endif > > uninstall-local: > - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar > - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > - rm -f $(DESTDIR)$(bindir)/javaws > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/javaws > + if [ -L $(DESTDIR)$(prefix)/bin/javaws ] ; then \ > + rm -f $(DESTDIR)$(prefix)/bin/javaws ; \ > fi > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > - rm -f $(DESTDIR)$(bindir)/itweb-settings > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/itweb-settings > + if [ -L $(DESTDIR)$(prefix)/bin/itweb-settings ] ; then \ > + rm -f $(DESTDIR)$(prefix)/bin/itweb-settings ; \ > fi > - rm -rf $(DESTDIR)$(htmldir) > + rm -rf $(DESTDIR)$(htmldir)/* > + if [ -d $(DESTDIR)$(htmldir) ] ; then \ > + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ > + fi > > # Plugin > > @@ -349,7 +351,7 @@ > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > mkdir -p $(NETX_DIR)/launcher && \ > $(CC) $(LAUNCHER_FLAGS) \ > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ > -DPROGNAME='"javaws"' -c -o $@ $< > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > diff -r 43212217e9c0 configure.ac > --- a/configure.ac Wed Dec 15 10:17:51 2010 -0500 > +++ b/configure.ac Tue Jan 25 18:47:27 2011 -0500 > @@ -78,4 +78,12 @@ > IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) > IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE > > +# Set JRE prefix based on whether to-level prefix is a JDK dir or a JRE dir > +if test -d ${prefix}/jre ; then > + JRE_DIR_PREFIX="/jre" ; > +else > + JRE_DIR_PREFIX="" ; > +fi ; > +AC_SUBST([JRE_DIR_PREFIX]) > + > AC_OUTPUT > diff -r 43212217e9c0 netx/net/sourceforge/jnlp/Launcher.java > --- a/netx/net/sourceforge/jnlp/Launcher.java Wed Dec 15 10:17:51 2010 -0500 > +++ b/netx/net/sourceforge/jnlp/Launcher.java Tue Jan 25 18:47:27 2011 -0500 > @@ -330,7 +330,12 @@ > List commands = new LinkedList(); > > // this property is set by the javaws launcher to point to the javaws binary > - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); > + String pathToWebstartBinary = System.getProperty("java.home") + > + File.separatorChar + > + "bin" + > + File.separatorChar + > + "javaws"; > + > commands.add(pathToWebstartBinary); > // use -Jargument format to pass arguments to the JVM through the launcher > for (String arg : vmArgs) { -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Wed Jan 26 11:44:09 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Wed, 26 Jan 2011 19:44:09 +0000 Subject: [icedtea-web] RFC: pick up name and version from configure In-Reply-To: <4D3F04A6.2030200@redhat.com> References: <4D3F04A6.2030200@redhat.com> Message-ID: <20110126194409.GI21785@rivendell.middle-earth.co.uk> On 12:13 Tue 25 Jan , Omair Majid wrote: > Hi, > > The attached patch gets rid of the hardcoded names and version numbers > in net. It makes netx pick up the right name and version form the > configure script. > > Okay to commit? > > ChangeLog: > 2011-01-25 Omair Majid > > * Makefile.am: Add FULL_VERSION. Make PLUGIN_VERSION use > FULL_VERSION. > ($(NETX_DIR)/netx.manifest): New target. Creates a manifest file > containing package name and version for netx. > (stamps/netx.stamp): Add manifest to jar. > * netx/net/sourceforge/jnlp/runtime/Boot.java: Look up name and > version from manifest. > > Cheers, > Omair I think it would be much cleaner to produce the manifest using autoconf's existing support for this rather than hacking stuff into the Makefile. You need to AC_SUBST FULL_VERSION and then add netx.manifest to AC_CONFIG_FILES. autoconf will do the rest. Make sure that the macros that set ICEDTEA_REVISION (IT_OBTAIN_HG_REVISIONS) and PKGVERSION (IT_GET_PKGVERSION) are run before FULL_VERSION is set. Something like the attached patch should do it. $ /home/andrew/projects/openjdk/icedtea-web/configure ... checking what version string to use... 1.1pre+r64da2a80df88 ... $ cat netx/netx.manifest Implementation-Title: icedtea-web Implementation-Version: 1.1pre+r64da2a80df88 $ /home/andrew/projects/openjdk/icedtea-web/configure --with-pkgversion=23 ... checking what version string to use... 1.1pre+r64da2a80df88 (23) ... $ cat netx/netx.manifest Implementation-Title: icedtea-web Implementation-Version: 1.1pre+r64da2a80df88 (23) The changes to Boot.java and the netx-dist target look fine. > diff -r 64da2a80df88 Makefile.am > --- a/Makefile.am Tue Jan 25 10:19:20 2011 -0500 > +++ b/Makefile.am Tue Jan 25 12:04:54 2011 -0500 > @@ -82,7 +82,8 @@ > -DEXPAND_CLASSPATH_WILDCARDS > LAUNCHER_LINK = -o $@ -pthread -Xlinker -O1 -Xlinker -z -Xlinker defs -L$(BOOT_DIR)/lib/$(INSTALL_ARCH_DIR) \ > -Wl,-soname=lib.so -Wl,-z -Wl,origin -Wl,--allow-shlib-undefined $(X11_CFLAGS) $(X11_LIBS) -ldl -lz > -PLUGIN_VERSION = IcedTea-Web $(PACKAGE_VERSION)$(ICEDTEA_REV)$(ICEDTEA_PKG) > +FULL_VERSION=$(PACKAGE_VERSION)$(ICEDTEA_REV)$(ICEDTEA_PKG) > +PLUGIN_VERSION = IcedTea-Web $(FULL_VERSION) > > EXTRA_DIST = $(top_srcdir)/netx $(top_srcdir)/plugin javaws.png javaws.desktop.in extra launcher \ > itweb-settings.desktop.in > @@ -298,10 +299,14 @@ > mkdir -p stamps > touch $@ > > -stamps/netx-dist.stamp: stamps/netx.stamp > +$(NETX_DIR)/netx.manifest: > + echo "Implementation-Title: $(PACKAGE_NAME)" > $@ && \ > + echo "Implementation-Version: $(FULL_VERSION)" >> $@ > + > +stamps/netx-dist.stamp: stamps/netx.stamp $(NETX_DIR)/netx.manifest > (cd $(NETX_DIR) ; \ > mkdir -p lib ; \ > - $(BOOT_DIR)/bin/jar cf lib/classes.jar javax/jnlp net ; \ > + $(BOOT_DIR)/bin/jar cfm lib/classes.jar netx.manifest javax/jnlp net ; \ > cp -pPR $(SRC_DIR_LINK) $(NETX_SRCDIR) src; \ > find src -type f -exec chmod 640 '{}' ';' -o -type d -exec chmod 750 '{}' ';'; \ > cd src ; \ > diff -r 64da2a80df88 netx/net/sourceforge/jnlp/runtime/Boot.java > --- a/netx/net/sourceforge/jnlp/runtime/Boot.java Tue Jan 25 10:19:20 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/Boot.java Tue Jan 25 12:04:54 2011 -0500 > @@ -58,11 +58,12 @@ > // todo: decide whether a spawned netx (external launch) > // should inherit the same options as this instance (store argv?) > > - private static final String version = "0.5"; > + private static final String name = Boot.class.getPackage().getImplementationTitle(); > + private static final String version = Boot.class.getPackage().getImplementationVersion(); > > /** the text to display before launching the about link */ > private static final String aboutMessage = "" > - + "netx v" + version + " - (C)2001-2003 Jon A. Maxwell (jmaxwell at users.sourceforge.net)\n" > + + name + " " + version > + "\n" > + R("BLaunchAbout"); > -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 -------------- next part -------------- diff -r 64da2a80df88 Makefile.am --- a/Makefile.am Tue Jan 25 10:19:20 2011 -0500 +++ b/Makefile.am Wed Jan 26 19:43:21 2011 +0000 @@ -54,13 +54,6 @@ SRC_DIR_LINK = $(REFLINK) endif -if HAS_ICEDTEA_REVISION -ICEDTEA_REV = +${ICEDTEA_REVISION} -endif -if HAS_PKGVERSION -ICEDTEA_PKG = $(EMPTY) (${PKGVERSION}) -endif - if ENABLE_DOCS JAVADOC_OPTS=-use -keywords -encoding UTF-8 -splitIndex \ -bottom ' Submit a bug or feature' @@ -82,7 +75,7 @@ -DEXPAND_CLASSPATH_WILDCARDS LAUNCHER_LINK = -o $@ -pthread -Xlinker -O1 -Xlinker -z -Xlinker defs -L$(BOOT_DIR)/lib/$(INSTALL_ARCH_DIR) \ -Wl,-soname=lib.so -Wl,-z -Wl,origin -Wl,--allow-shlib-undefined $(X11_CFLAGS) $(X11_LIBS) -ldl -lz -PLUGIN_VERSION = IcedTea-Web $(PACKAGE_VERSION)$(ICEDTEA_REV)$(ICEDTEA_PKG) +PLUGIN_VERSION = IcedTea-Web $(FULL_VERSION) EXTRA_DIST = $(top_srcdir)/netx $(top_srcdir)/plugin javaws.png javaws.desktop.in extra launcher \ itweb-settings.desktop.in diff -r 64da2a80df88 acinclude.m4 --- a/acinclude.m4 Tue Jan 25 10:19:20 2011 -0500 +++ b/acinclude.m4 Wed Jan 26 19:43:21 2011 +0000 @@ -667,3 +667,19 @@ fi AC_PROVIDE([$0])dnl ]) + +AC_DEFUN_ONCE([IT_SET_VERSION], +[ + AC_REQUIRE([IT_OBTAIN_HG_REVISIONS]) + AC_REQUIRE([IT_GET_PKGVERSION]) + AC_MSG_CHECKING([what version string to use]) + if test "x${ICEDTEA_REVISION}" != xnone; then + ICEDTEA_REV="+${ICEDTEA_REVISION}" + fi + if test "x${PKGVERSION}" != "xnone"; then + ICEDTEA_PKG=" (${PKGVERSION})" + fi + FULL_VERSION="${PACKAGE_VERSION}${ICEDTEA_REV}${ICEDTEA_PKG}" + AC_MSG_RESULT([${FULL_VERSION}]) + AC_SUBST([FULL_VERSION]) +]) diff -r 64da2a80df88 configure.ac --- a/configure.ac Tue Jan 25 10:19:20 2011 -0500 +++ b/configure.ac Wed Jan 26 19:43:21 2011 +0000 @@ -1,6 +1,6 @@ AC_INIT([icedtea-web],[1.1pre],[distro-pkg-dev at openjdk.java.net], [icedtea-web], [http://icedtea.classpath.org/wiki/IcedTea-Web]) AM_INIT_AUTOMAKE([1.9 tar-pax foreign]) -AC_CONFIG_FILES([Makefile]) +AC_CONFIG_FILES([Makefile netx/netx.manifest]) # Older automake doesn't generate these correctly abs_top_builddir=`pwd -P` @@ -35,8 +35,7 @@ IT_FIND_JAVADOC AC_CONFIG_FILES([javac], [chmod +x javac]) -IT_GET_PKGVERSION -IT_OBTAIN_HG_REVISIONS +IT_SET_VERSION IT_CHECK_XULRUNNER_VERSION AC_CHECK_LIB(z, main,, [AC_MSG_ERROR("zlib not found - try installing zlib-devel")]) diff -r 64da2a80df88 netx/netx.manifest.in --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/netx/netx.manifest.in Wed Jan 26 19:43:21 2011 +0000 @@ -0,0 +1,2 @@ +Implementation-Title: @PACKAGE_NAME@ +Implementation-Version: @FULL_VERSION@ From ahughes at redhat.com Wed Jan 26 11:46:13 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Wed, 26 Jan 2011 19:46:13 +0000 Subject: [icedtea-web] RFC: remove default.jnlp In-Reply-To: <4D3EEDA2.8060802@redhat.com> References: <4D3DE7DB.1030904@redhat.com> <20110124212504.GI17602@rivendell.middle-earth.co.uk> <4D3DF560.1060501@redhat.com> <20110124230720.GJ17602@rivendell.middle-earth.co.uk> <4D3EEDA2.8060802@redhat.com> Message-ID: <20110126194613.GJ21785@rivendell.middle-earth.co.uk> On 10:34 Tue 25 Jan , Omair Majid wrote: > On 01/24/2011 06:07 PM, Dr Andrew John Hughes wrote: > > On 16:55 Mon 24 Jan , Omair Majid wrote: > >> On 01/24/2011 04:25 PM, Dr Andrew John Hughes wrote: > >>> On 15:58 Mon 24 Jan , Omair Majid wrote: > >>>> The attached patch removes default.jnlp from icedtea-web. This seems to > >>>> be a copy of about.jnlp (About.jnlp gets invoked on javaws -about), but > >>>> is completely unused. Ok to remove? > >>>> > >>> > >>> Does the name have any special significance? Have you checked it isn't loaded > >>> or something if you don't specify a JNLP file? > >>> > >> > >> That's what I thought at first. Running javaws with no-args prints out > >> the help message. I grepped the entire source and default.jnlp does not > >> appear anywhere. Digging into it's history, here is what I found: > >> icedtea6 changeset bd6babe8221f [1], which introduced the about.jnlp > >> file, also changed the uses of default.jnlp to about.jnlp (the relevant > >> changes are in rt/net/sourceforge/jnlp/runtime/Boot.java). The changeset > >> should also have deleted default.jnlp. > >> > > > > Ok, great, we can delete it then. > > > > Thanks for looking it over; I have pushed the changeset. > > >>> On the subject of about.jnlp, can someone please update it so recent work is credited? > >>> It currently gives all credit to Jon Maxwell and Joshua Sumali. > >>> > >> > >> I can take a look at it. Updating the in-repository copy should not be > >> too hard, but about.jnlp is actually run from the classpath servers, and > >> I do not have permission to edit icedtea.classpath.org:/var/www/netx. > >> > > > > It seems I do, so I can update the server copy once the fix is in IcedTea-Web. > > > > I have attached a patch to update the list in the about.jnlp as well as > add Jon to AUTHORS. > > I would also like to update the release notes (in notes.html) and the > versions used, but that's another patch. > > Ok to commit? > > Cheers, > Omair Yes, looks good. > diff -r 804cd535d907 AUTHORS > --- a/AUTHORS Mon Jan 24 10:20:57 2011 -0500 > +++ b/AUTHORS Mon Jan 24 19:11:19 2011 -0500 > @@ -8,6 +8,7 @@ > Matthias Klose > Francis Kung > Omair Majid > +Jon A. Maxwell > Andrew Su > Joshua Sumali > Mark Wielaard > diff -r 804cd535d907 extra/net/sourceforge/jnlp/about/resources/notes.html > --- a/extra/net/sourceforge/jnlp/about/resources/notes.html Mon Jan 24 10:20:57 2011 -0500 > +++ b/extra/net/sourceforge/jnlp/about/resources/notes.html Mon Jan 24 19:11:19 2011 -0500 > @@ -21,10 +21,18 @@ > > >
> - Jon A. Maxwell
> - developer
> - Joshua Sumali
> - developer > + Lillian Angel
> + Deepak Bhole
> + Thomas Fitzsimmons
> + Andrew John Hughes
> + Matthias Klose
> + Francis Kung
> + Omair Majid
> + Jon A. Maxwell
> + Andrew Su
> + Joshua Sumali
> + Mark Wielaard
> + Man Lung Wong
>
> > -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From dbhole at redhat.com Wed Jan 26 11:47:09 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Wed, 26 Jan 2011 14:47:09 -0500 Subject: [icedtea-web] RFE: Fix for broken JRE dir install In-Reply-To: <20110126190220.GH21785@rivendell.middle-earth.co.uk> References: <20110121011017.GF22586@redhat.com> <20110121013228.GI4611@rivendell.middle-earth.co.uk> <20110121025333.GA24487@redhat.com> <20110121133540.GC13935@rivendell.middle-earth.co.uk> <20110121151327.GA10878@redhat.com> <20110121204649.GB21893@rivendell.middle-earth.co.uk> <20110121224039.GA3954@redhat.com> <20110122012326.GG21893@rivendell.middle-earth.co.uk> <20110125235737.GA20834@redhat.com> <20110126190220.GH21785@rivendell.middle-earth.co.uk> Message-ID: <20110126194709.GA3027@redhat.com> * Dr Andrew John Hughes [2011-01-26 14:02]: > On 18:57 Tue 25 Jan , Deepak Bhole wrote: > > * Dr Andrew John Hughes [2011-01-21 20:23]: > > > On 17:40 Fri 21 Jan , Deepak Bhole wrote: > > > > > > > > > > > > IcedTea-Web does not 'put things in JDK_HOME/bin'. It puts them in > > > ${bindir} which defaults to ${prefix}/bin. That's only equal to > > > JDK_HOME/bin if ${prefix} is set to JDK_HOME. For a general application, > > > ${bindir} is the primary location. > > > > > > That said, I support adding the $(JRE_DIR_PREFIX) hack to IcedTea-Web 1.0 > > > as I said before. You just need to do in the patch what you say in the mail ;-) > > > > > > > Having thought more about different RPM scenarios, I can see what you > > mean now. I was incorrectly understanding the install requirements > > earlier. I have updated the patch to remove the linking changes. Sorry > > for the unnecessary confusion. > > > > I did however update it to use relative symlinks i.e. something like: > > > > jre/bin/javaws -> ../../bin/javaws > > > > Rather than the current way which creates absolute links (and makes the tree > > un-relocatable). > > > > To do this, > > > + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > > should also be changed to create $(DESTDIR)$(prefix)/bin instead of $(DESTDIR)$(bindir). > The patch below will break if $(bindir) != $(prefix)/bin. > > Clearly, this breaks the use of --bindir. > Doh! Fixed in attached patch. Also fixed the ${INSTALL_PROGRAM} directives which were installing to $(DESTDIR)$(bindir). Cheers, Deepak -------------- next part -------------- diff -r 43212217e9c0 Makefile.am --- a/Makefile.am Wed Dec 15 10:17:51 2010 -0500 +++ b/Makefile.am Wed Jan 26 14:44:20 2011 -0500 @@ -102,37 +102,37 @@ clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs install-exec-local: - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) + ${mkinstalldirs} $(DESTDIR)$(prefix)/bin $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) if ENABLE_PLUGIN - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar endif - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)/bin if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ fi ; \ if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ + ln -s ../../bin/javaws $(DESTDIR)$(prefix)/jre/bin ; \ fi ; \ fi - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(prefix)/bin if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ fi ; \ if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ + ln -s ../../bin/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ fi ; \ fi install-data-local: ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib if ENABLE_DOCS ${mkinstalldirs} $(DESTDIR)$(htmldir) (cd ${abs_top_builddir}/docs/netx; \ @@ -150,23 +150,25 @@ endif uninstall-local: - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 rm -f $(DESTDIR)$(bindir)/pluginappletviewer - rm -f $(DESTDIR)$(bindir)/javaws - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/javaws + if [ -L $(DESTDIR)$(prefix)/bin/javaws ] ; then \ + rm -f $(DESTDIR)$(prefix)/bin/javaws ; \ fi - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws - rm -f $(DESTDIR)$(bindir)/itweb-settings - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/itweb-settings + if [ -L $(DESTDIR)$(prefix)/bin/itweb-settings ] ; then \ + rm -f $(DESTDIR)$(prefix)/bin/itweb-settings ; \ fi - rm -rf $(DESTDIR)$(htmldir) + rm -rf $(DESTDIR)$(htmldir)/* + if [ -d $(DESTDIR)$(htmldir) ] ; then \ + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ + fi # Plugin @@ -349,7 +351,7 @@ $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c mkdir -p $(NETX_DIR)/launcher && \ $(CC) $(LAUNCHER_FLAGS) \ - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ -DPROGNAME='"javaws"' -c -o $@ $< $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c diff -r 43212217e9c0 configure.ac --- a/configure.ac Wed Dec 15 10:17:51 2010 -0500 +++ b/configure.ac Wed Jan 26 14:44:20 2011 -0500 @@ -78,4 +78,12 @@ IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE +# Set JRE prefix based on whether to-level prefix is a JDK dir or a JRE dir +if test -d ${prefix}/jre ; then + JRE_DIR_PREFIX="/jre" ; +else + JRE_DIR_PREFIX="" ; +fi ; +AC_SUBST([JRE_DIR_PREFIX]) + AC_OUTPUT diff -r 43212217e9c0 netx/net/sourceforge/jnlp/Launcher.java --- a/netx/net/sourceforge/jnlp/Launcher.java Wed Dec 15 10:17:51 2010 -0500 +++ b/netx/net/sourceforge/jnlp/Launcher.java Wed Jan 26 14:44:20 2011 -0500 @@ -330,7 +330,12 @@ List commands = new LinkedList(); // this property is set by the javaws launcher to point to the javaws binary - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); + String pathToWebstartBinary = System.getProperty("java.home") + + File.separatorChar + + "bin" + + File.separatorChar + + "javaws"; + commands.add(pathToWebstartBinary); // use -Jargument format to pass arguments to the JVM through the launcher for (String arg : vmArgs) { From ahughes at redhat.com Wed Jan 26 11:56:14 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Wed, 26 Jan 2011 19:56:14 +0000 Subject: [icedtea-web] RFC: add support in netx for using proxy settings from browser In-Reply-To: <4D3E03BE.4010500@redhat.com> References: <4D127CEB.9010508@redhat.com> <20101223004028.GM17229@rivendell.middle-earth.co.uk> <4D15033A.402@redhat.com> <4D151ED4.70102@redhat.com> <20110124172148.GA17602@rivendell.middle-earth.co.uk> <4D3E03BE.4010500@redhat.com> Message-ID: <20110126195614.GK21785@rivendell.middle-earth.co.uk> On 17:57 Mon 24 Jan , Omair Majid wrote: > On 01/24/2011 12:21 PM, Dr Andrew John Hughes wrote: > > snip... > > Is this a TODO or is this case really empty? > > > > Definitely a TODO. I thought the error message in the fall-through case > (next-line) made it clear. I have made it more explicit. > Yeah, it will for the end user. The code comment was just unclear. snip... > > >> + /** > >> + * Get an appropriate proxy for the given URI using static information from > >> + * the browser's preferences file. > >> + */ > >> + private List getFromBrowserConfiguration(URI uri) { > >> + List proxies = new ArrayList(); > >> + > >> + String scheme = uri.getScheme(); > >> + > >> + if (browserUseSameProxy) { > >> + SocketAddress sa = new InetSocketAddress(browserHttpProxyHost, browserHttpProxyPort); > >> + Proxy proxy; > >> + if (scheme.equals("socket")) { > >> + proxy = new Proxy(Type.SOCKS, sa); > >> + } else { > >> + proxy = new Proxy(Type.HTTP, sa); > >> + } > >> + proxies.add(proxy); > >> + } else if (scheme.equals("http")) { > >> + SocketAddress sa = new InetSocketAddress(browserHttpProxyHost, browserHttpProxyPort); > >> + proxies.add(new Proxy(Type.HTTP, sa)); > >> + } else if (scheme.equals("https")) { > >> + SocketAddress sa = new InetSocketAddress(browserHttpsProxyHost, browserHttpsProxyPort); > >> + proxies.add(new Proxy(Type.HTTP, sa)); > > > > Do you not need to do something different for HTTPS? Or is that handled elsewhere? > > > > Are you referring to Type.HTTP? There are only 3 Types defined: DIRECT, > HTTP and SOCKS. Type.HTTP is for http, https and ftp. > Ok I'm just wondering how you distinguish between http, https and ftp in the proxies list? Presumably you don't need to. > > Does this look okay? Any further suggestions for improvement? > Looks ok now. Just check the indenting (mentioned inline below) on BrowserAwareProxySelector and it seems good to go. > Cheers, > Omair > diff -r 804cd535d907 netx/net/sourceforge/jnlp/browser/BrowserAwareProxySelector.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/browser/BrowserAwareProxySelector.java Mon Jan 24 17:55:58 2011 -0500 > @@ -0,0 +1,255 @@ > +/* BrowserAwareProxySelector.java > + Copyright (C) 2011 Red Hat, Inc. > + > +This file is part of IcedTea. > + > +IcedTea is free software; you can redistribute it and/or > +modify it under the terms of the GNU General Public License as published by > +the Free Software Foundation, version 2. > + > +IcedTea is distributed in the hope that it will be useful, > +but WITHOUT ANY WARRANTY; without even the implied warranty of > +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > +General Public License for more details. > + > +You should have received a copy of the GNU General Public License > +along with IcedTea; see the file COPYING. If not, write to > +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA > +02110-1301 USA. > + > +Linking this library statically or dynamically with other modules is > +making a combined work based on this library. Thus, the terms and > +conditions of the GNU General Public License cover the whole > +combination. > + > +As a special exception, the copyright holders of this library give you > +permission to link this library with independent modules to produce an > +executable, regardless of the license terms of these independent > +modules, and to copy and distribute the resulting executable under > +terms of your choice, provided that you also meet, for each linked > +independent module, the terms and conditions of the license of that > +module. An independent module is a module which is not derived from > +or based on this library. If you modify this library, you may extend > +this exception to your version of the library, but you are not > +obligated to do so. If you do not wish to do so, delete this > +exception statement from your version. > +*/ > +package net.sourceforge.jnlp.browser; > + > +import static net.sourceforge.jnlp.runtime.Translator.R; > + > +import java.io.File; > +import java.io.IOException; > +import java.net.InetSocketAddress; > +import java.net.MalformedURLException; > +import java.net.Proxy; > +import java.net.SocketAddress; > +import java.net.URI; > +import java.net.URL; > +import java.net.Proxy.Type; > +import java.util.ArrayList; > +import java.util.Arrays; > +import java.util.List; > +import java.util.Map; > + > +import net.sourceforge.jnlp.runtime.JNLPProxySelector; > +import net.sourceforge.jnlp.runtime.JNLPRuntime; > + > +/** > + * A ProxySelector which can read proxy settings from a browser's > + * configuration and use that. > + * > + * @see JNLPProxySelector > + */ > +public class BrowserAwareProxySelector extends JNLPProxySelector { > + > + /* firefox's constants */ > + public static final int BROWSER_PROXY_TYPE_NONE = 0; > + public static final int BROWSER_PROXY_TYPE_MANUAL = 1; > + public static final int BROWSER_PROXY_TYPE_PAC = 2; > + public static final int BROWSER_PROXY_TYPE_NONE2 = 3; > + /** use gconf, WPAD and then env (and possibly others)*/ > + public static final int BROWSER_PROXY_TYPE_AUTO = 4; > + /** use env variables */ > + public static final int BROWSER_PROXY_TYPE_SYSTEM = 5; > + > + private int browserProxyType = BROWSER_PROXY_TYPE_NONE; > + private URL browserAutoConfigUrl; > + private Boolean browserUseSameProxy; > + private String browserHttpProxyHost; > + private int browserHttpProxyPort; > + private String browserHttpsProxyHost; > + private int browserHttpsProxyPort; > + private String browserFtpProxyHost; > + private int browserFtpProxyPort; > + private String browserSocks4ProxyHost; > + private int browserSocks4ProxyPort; > + > + /** > + * Create a new instance of this class, reading configuration fropm the browser > + */ > + public BrowserAwareProxySelector() { > + super(); > + try { > + initFromBrowserConfig(); Indenting seems to have gone astray here. > + } catch (IOException e) { > + if (JNLPRuntime.isDebug()) { > + e.printStackTrace(); > + } > + System.err.println(R("RProxyFirefoxNotFound")); > + browserProxyType = PROXY_TYPE_NONE; > + } > + } > + > + /** > + * Initialize configuration by reading preferences from the browser (firefox) > + */ > + private void initFromBrowserConfig() throws IOException { > + > + File preferencesFile = FirefoxPreferencesFinder.find(); > + > + FirefoxPreferencesParser parser = new FirefoxPreferencesParser(preferencesFile); > + parser.parse(); > + Map prefs = parser.getPreferences(); > + > + String type = prefs.get("network.proxy.type"); > + if (type != null) { > + browserProxyType = Integer.valueOf(type); > + } else { > + browserProxyType = BROWSER_PROXY_TYPE_AUTO; > + } > + > + try { > + browserAutoConfigUrl = new URL(prefs.get("network.proxy.autoconfig_url")); > + } catch (MalformedURLException e) { > + e.printStackTrace(); > + } > + > + browserUseSameProxy = Boolean.valueOf(prefs.get("network.proxy.share_proxy_settings")); > + > + browserHttpProxyHost = prefs.get("network.proxy.http"); > + browserHttpProxyPort = stringToPort(prefs.get("network.proxy.http_port")); > + browserHttpsProxyHost = prefs.get("network.proxy.ssl"); > + browserHttpsProxyPort = stringToPort(prefs.get("network.proxy.ssl_port")); > + browserFtpProxyHost = prefs.get("network.proxy.ftp"); > + browserFtpProxyPort = stringToPort(prefs.get("network.proxy.ftp_port")); > + browserSocks4ProxyHost = prefs.get("networking.proxy.socks"); > + browserSocks4ProxyPort = stringToPort(prefs.get("network.proxy.socks_port")); > + } > + > + /** > + * Returns port inside a string. Unlike {@link Integer#valueOf(String)}, > + * it will not throw exceptions. > + * > + * @param string the string containing the integer to parse > + * @return the port inside the string, or Integer.MIN_VALUE > + */ > + private int stringToPort(String string) { > + try { > + return Integer.valueOf(string); > + } catch (NumberFormatException nfe) { > + return Integer.MIN_VALUE; > + } > + } > + > + /** > + * The main entry point for {@link BrowserAwareProxySelector}. Based on > + * the browser settings, determines proxy information for a given URI. > + *

> + * The appropriate proxy may be determined by reading static information > + * from the browser's preferences file, or it may be computed dynamically, > + * by, for example, running javascript code. > + */ > + @Override > + protected List getFromBrowser(URI uri) { > + List proxies = new ArrayList(); > + > + String optionDescription = null; > + > + switch (browserProxyType) { > + case BROWSER_PROXY_TYPE_PAC: > + proxies.addAll(getFromBrowserPAC(uri)); > + break; > + case BROWSER_PROXY_TYPE_MANUAL: > + proxies.addAll(getFromBrowserConfiguration(uri)); > + break; > + case BROWSER_PROXY_TYPE_NONE: > + proxies.add(Proxy.NO_PROXY); > + break; > + case BROWSER_PROXY_TYPE_AUTO: > + // firefox will do a whole lot of stuff to automagically > + // figure out the right settings. gconf, WPAD, and ENV are used. > + // https://bugzilla.mozilla.org/show_bug.cgi?id=66057#c32 > + // TODO this is probably not easy/quick to do. using libproxy might be > + // the simpler workaround > + if (optionDescription == null) { > + optionDescription = "Automatic"; > + } > + case BROWSER_PROXY_TYPE_SYSTEM: > + // means use $http_proxy, $ftp_proxy etc. > + // TODO implement env vars if possible > + if (optionDescription == null) { > + optionDescription = "System"; > + } > + default: > + if (optionDescription == null) { > + optionDescription = "Unknown"; > + } > + System.err.println(R("RProxyFirefoxOptionNotImplemented", browserProxyType, optionDescription)); > + proxies.add(Proxy.NO_PROXY); > + } Like this change :-) > + > + if (JNLPRuntime.isDebug()) { > + System.out.println("Browser selected proxies: " + proxies.toString()); > + } > + > + return proxies; > + } > + > + /** > + * Get an appropriate proxy for a given URI using a PAC specified in the > + * browser. > + */ > + private List getFromBrowserPAC(URI uri) { > + System.err.println(R("RPRoxyPacNotImplemented")); > + return Arrays.asList(new Proxy[] { Proxy.NO_PROXY }); > + } > + > + /** > + * Get an appropriate proxy for the given URI using static information from > + * the browser's preferences file. > + */ > + private List getFromBrowserConfiguration(URI uri) { > + List proxies = new ArrayList(); > + > + String scheme = uri.getScheme(); > + > + if (browserUseSameProxy) { > + SocketAddress sa = new InetSocketAddress(browserHttpProxyHost, browserHttpProxyPort); > + Proxy proxy; > + if (scheme.equals("socket")) { > + proxy = new Proxy(Type.SOCKS, sa); > + } else { > + proxy = new Proxy(Type.HTTP, sa); > + } > + proxies.add(proxy); > + } else if (scheme.equals("http")) { > + SocketAddress sa = new InetSocketAddress(browserHttpProxyHost, browserHttpProxyPort); > + proxies.add(new Proxy(Type.HTTP, sa)); > + } else if (scheme.equals("https")) { > + SocketAddress sa = new InetSocketAddress(browserHttpsProxyHost, browserHttpsProxyPort); > + proxies.add(new Proxy(Type.HTTP, sa)); > + } else if (scheme.equals("ftp")) { > + SocketAddress sa = new InetSocketAddress(browserFtpProxyHost, browserFtpProxyPort); > + proxies.add(new Proxy(Type.HTTP, sa)); > + } else if (scheme.equals("socket")) { > + SocketAddress sa = new InetSocketAddress(browserSocks4ProxyHost, browserSocks4ProxyPort); > + proxies.add(new Proxy(Type.SOCKS, sa)); > + } else { > + proxies.add(Proxy.NO_PROXY); > + } > + > + return proxies; > + } > + > +} > diff -r 804cd535d907 netx/net/sourceforge/jnlp/browser/FirefoxPreferencesFinder.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/browser/FirefoxPreferencesFinder.java Mon Jan 24 17:55:58 2011 -0500 > @@ -0,0 +1,137 @@ > +/* FirefoxPreferencesFinder.java > + Copyright (C) 2011 Red Hat, Inc. > + > +This file is part of IcedTea. > + > +IcedTea is free software; you can redistribute it and/or > +modify it under the terms of the GNU General Public License as published by > +the Free Software Foundation, version 2. > + > +IcedTea is distributed in the hope that it will be useful, > +but WITHOUT ANY WARRANTY; without even the implied warranty of > +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > +General Public License for more details. > + > +You should have received a copy of the GNU General Public License > +along with IcedTea; see the file COPYING. If not, write to > +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA > +02110-1301 USA. > + > +Linking this library statically or dynamically with other modules is > +making a combined work based on this library. Thus, the terms and > +conditions of the GNU General Public License cover the whole > +combination. > + > +As a special exception, the copyright holders of this library give you > +permission to link this library with independent modules to produce an > +executable, regardless of the license terms of these independent > +modules, and to copy and distribute the resulting executable under > +terms of your choice, provided that you also meet, for each linked > +independent module, the terms and conditions of the license of that > +module. An independent module is a module which is not derived from > +or based on this library. If you modify this library, you may extend > +this exception to your version of the library, but you are not > +obligated to do so. If you do not wish to do so, delete this > +exception statement from your version. > +*/ > + > +package net.sourceforge.jnlp.browser; > + > +import java.io.BufferedReader; > +import java.io.File; > +import java.io.FileNotFoundException; > +import java.io.FileReader; > +import java.io.IOException; > +import java.util.ArrayList; > +import java.util.List; > + > +import net.sourceforge.jnlp.runtime.JNLPRuntime; > + > +/** > + * Finds the file corresponding to firefox's (default) preferences file > + */ > +public class FirefoxPreferencesFinder { > + > + /** > + * Returns a file object representing firefox's preferences file > + * > + * @return a File object representing the preferences file. > + * @throws FileNotFoundException if the preferences file could not be found > + * @throws IOException if an exception occurs while trying to identify the > + * location of the preferences file. > + */ > + public static File find() throws IOException { > + > + String configPath = System.getProperty("user.home") + File.separator + ".mozilla" > + + File.separator + "firefox" + File.separator; > + > + String profilesPath = configPath + "profiles.ini"; > + > + if (!(new File(profilesPath).isFile())) { > + throw new FileNotFoundException(profilesPath); > + } > + > + if (JNLPRuntime.isDebug()) { > + System.out.println("Using firefox's profiles file: " + profilesPath); > + } > + BufferedReader reader = new BufferedReader(new FileReader(profilesPath)); > + > + List linesInSection = new ArrayList(); > + boolean foundDefaultSection = false; > + > + /* > + * The profiles.ini file is an ini file. This is a quick hack to read > + * it. It is very likely to break given anything strange. > + */ > + > + // find the section with an entry Default=1 > + while (true) { > + String line = reader.readLine(); > + if (line == null) { > + break; > + } > + > + line = line.trim(); > + if (line.startsWith("[") && line.endsWith("]")) { > + if (foundDefaultSection) { > + break; > + } > + // new section > + linesInSection = new ArrayList(); > + } else { > + linesInSection.add(line); > + int equalSignPos = line.indexOf('='); > + if (equalSignPos > 0) { > + String key = line.substring(0, equalSignPos).trim(); > + String value = line.substring(equalSignPos+1).trim(); > + if (key.toLowerCase().equals("default") && value.equals("1")) { > + foundDefaultSection = true; > + } > + } > + } > + > + } > + > + if (!foundDefaultSection) { > + throw new FileNotFoundException("preferences file"); > + } > + > + String path = null; > + for (String line : linesInSection) { > + if (line.startsWith("Path=")) { > + path = line.substring("Path=".length()); > + } > + } > + > + if (path == null) { > + throw new FileNotFoundException("preferences file"); > + } else { > + String fullPath = configPath + path + File.separator + "prefs.js"; > + if (JNLPRuntime.isDebug()) { > + System.out.println("Found preferences file: " + fullPath); > + } > + return new File(fullPath); > + } > + } > + > +} > diff -r 804cd535d907 netx/net/sourceforge/jnlp/browser/FirefoxPreferencesParser.java > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/net/sourceforge/jnlp/browser/FirefoxPreferencesParser.java Mon Jan 24 17:55:58 2011 -0500 > @@ -0,0 +1,155 @@ > +/* FirefoxPreferencesParser.java > + Copyright (C) 2011 Red Hat, Inc. > + > +This file is part of IcedTea. > + > +IcedTea is free software; you can redistribute it and/or > +modify it under the terms of the GNU General Public License as published by > +the Free Software Foundation, version 2. > + > +IcedTea is distributed in the hope that it will be useful, > +but WITHOUT ANY WARRANTY; without even the implied warranty of > +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > +General Public License for more details. > + > +You should have received a copy of the GNU General Public License > +along with IcedTea; see the file COPYING. If not, write to > +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA > +02110-1301 USA. > + > +Linking this library statically or dynamically with other modules is > +making a combined work based on this library. Thus, the terms and > +conditions of the GNU General Public License cover the whole > +combination. > + > +As a special exception, the copyright holders of this library give you > +permission to link this library with independent modules to produce an > +executable, regardless of the license terms of these independent > +modules, and to copy and distribute the resulting executable under > +terms of your choice, provided that you also meet, for each linked > +independent module, the terms and conditions of the license of that > +module. An independent module is a module which is not derived from > +or based on this library. If you modify this library, you may extend > +this exception to your version of the library, but you are not > +obligated to do so. If you do not wish to do so, delete this > +exception statement from your version. > +*/ > + > +package net.sourceforge.jnlp.browser; > + > +import java.io.BufferedReader; > +import java.io.File; > +import java.io.FileReader; > +import java.io.IOException; > +import java.util.HashMap; > +import java.util.Map; > + > +import net.sourceforge.jnlp.runtime.JNLPRuntime; > + > +/** > + * A parser for Firefox's preferences file. It can 'parse' Firefox's > + * preferences file and expose the prefrences in a simple to use format. > + *

> + * Sample usage: > + *

> + * FirefoxPreferencesParser p = new FirefoxPreferencesParser(prefsFile);
> + * p.parse();
> + * Map<String,String> prefs = p.getPreferences();
> + * System.out.println("blink allowed: " + prefs.get("browser.blink_allowed"));
> + * 
> + */ > +public final class FirefoxPreferencesParser { > + > + File prefsFile = null; > + Map prefs = null; > + > + /** > + * Creates a new FirefoxPreferencesParser > + * @param preferencesFile > + */ > + public FirefoxPreferencesParser(File preferencesFile) { > + prefsFile = preferencesFile; > + } > + > + /** > + * Parse the prefernces file > + * @throws IOException if an exception ocurrs while reading the > + * preferences file. > + */ > + public void parse() throws IOException { > + /* > + * The Firefox preference file is actually in javascript. It does seem > + * to be nicely formatted, so it should be possible to hack reading it. > + * The correct way of course is to use a javascript library and extract > + * the user_pref object > + */ > + prefs = new HashMap(); > + > + BufferedReader reader = new BufferedReader(new FileReader(prefsFile)); > + > + while (true) { > + String line = reader.readLine(); > + // end of stream > + if (line == null) { > + break; > + } > + > + line = line.trim(); > + if (line.startsWith("user_pref")) { > + > + /* > + * each line is of the form: user_pref("key",value); where value > + * can be a string in double quotes or an integer or float or > + * boolean > + */ > + > + boolean foundKey = false; > + boolean foundValue = false; > + > + // extract everything inside user_pref( and ); > + String pref = line.substring("user_pref(".length(), line.length() - 2); > + // key and value are separated by a , > + int firstCommaPos = pref.indexOf(','); > + if (firstCommaPos >= 1) { > + String key = pref.substring(0, firstCommaPos).trim(); > + if (key.startsWith("\"") && key.endsWith("\"")) { > + key = key.substring(1, key.length() - 1); > + if (key.trim().length() > 0) { > + foundKey = true; > + } > + } > + > + if (pref.length() > firstCommaPos + 1) { > + String value = pref.substring(firstCommaPos + 1).trim(); > + if (value.startsWith("\"") && value.endsWith("\"")) { > + value = value.substring(1, value.length() - 1).trim(); > + } > + foundValue = true; > + > + if (foundKey && foundValue) { > + // System.out.println("added (\"" + key + "\", \"" + value + "\")"); > + prefs.put(key, value); > + } > + } > + } > + } > + } > + if (JNLPRuntime.isDebug()) { > + System.out.println("Read " + prefs.size() + " entries from Firefox's preferences"); > + } > + } > + > + /** > + * Get the firefox preferences as a map (key,value pair). Note that > + * all values (including integers and booleans) are stored as a string, so > + * conversion to an appropriate type may be required. > + * > + * @return a map containing firefox' preferences > + */ > + public Map getPreferences() { > + HashMap newMap = new HashMap(); > + newMap.putAll(prefs); > + return newMap; > + } > + > +} > diff -r 804cd535d907 netx/net/sourceforge/jnlp/resources/Messages.properties > --- a/netx/net/sourceforge/jnlp/resources/Messages.properties Mon Jan 24 10:20:57 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/resources/Messages.properties Mon Jan 24 17:55:58 2011 -0500 > @@ -141,6 +141,9 @@ > RUnexpected=Unexpected {0} at {1} > RConfigurationError=Fatal error while reading the configuration > RConfigurationFatal=ERROR: a fatal error has occurred while loading configuration. Perhaps a global configuration was required but could not be found > +RPRoxyPacNotImplemented=Using Proxy Auto Config (PAC) files is not supported yet. > +RProxyFirefoxNotFound=Unable to use Firefox's proxy settings. Using "DIRECT" as proxy type. > +RProxyFirefoxOptionNotImplemented=Browser proxy option "{0}" ({1}) not supported yet. > > # Boot options, message should be shorter than this ----------------> > BOUsage=javaws [-run-options] > diff -r 804cd535d907 netx/net/sourceforge/jnlp/runtime/JNLPProxySelector.java > --- a/netx/net/sourceforge/jnlp/runtime/JNLPProxySelector.java Mon Jan 24 10:20:57 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/JNLPProxySelector.java Mon Jan 24 17:55:58 2011 -0500 > @@ -16,6 +16,7 @@ > > package net.sourceforge.jnlp.runtime; > > +import static net.sourceforge.jnlp.runtime.Translator.R; > import java.io.IOException; > import java.net.InetAddress; > import java.net.InetSocketAddress; > @@ -40,7 +41,7 @@ > * > * @see java.net.ProxySelector > */ > -public class JNLPProxySelector extends ProxySelector { > +public abstract class JNLPProxySelector extends ProxySelector { > > public static final int PROXY_TYPE_UNKNOWN = -1; > public static final int PROXY_TYPE_NONE = 0; > @@ -337,9 +338,7 @@ > return Arrays.asList(new Proxy[] { Proxy.NO_PROXY }); > } > // TODO implement this by reading and using the PAC file > - if (JNLPRuntime.isDebug()) { > - System.err.println("WARNING: Using a Proxy Auto Config file is not implemented yet"); > - } > + System.err.println(R("RPRoxyPacNotImplemented")); > > return Arrays.asList(new Proxy[] { Proxy.NO_PROXY }); > } > @@ -350,13 +349,7 @@ > * @param uri the uri to get proxies for > * @return a list of proxies > */ > - protected List getFromBrowser(URI uri) { > - // TODO implement this by parsing mozilla config > - if (JNLPRuntime.isDebug()) { > - System.err.println("WARNING: Using proxy settings from the browser is not implemented yet"); > - } > + protected abstract List getFromBrowser(URI uri); > > - return Arrays.asList(new Proxy[] { Proxy.NO_PROXY }); > - } > > } > diff -r 804cd535d907 netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java > --- a/netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java Mon Jan 24 10:20:57 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java Mon Jan 24 17:55:58 2011 -0500 > @@ -34,6 +34,7 @@ > import javax.swing.text.html.parser.ParserDelegator; > > import net.sourceforge.jnlp.*; > +import net.sourceforge.jnlp.browser.BrowserAwareProxySelector; > import net.sourceforge.jnlp.cache.*; > import net.sourceforge.jnlp.config.DeploymentConfiguration; > import net.sourceforge.jnlp.security.JNLPAuthenticator; > @@ -220,7 +221,7 @@ > > // plug in a custom authenticator and proxy selector > Authenticator.setDefault(new JNLPAuthenticator()); > - ProxySelector.setDefault(new JNLPProxySelector()); > + ProxySelector.setDefault(new BrowserAwareProxySelector()); > > initialized = true; > -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From ahughes at redhat.com Wed Jan 26 12:07:16 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Wed, 26 Jan 2011 20:07:16 +0000 Subject: [icedtea-web] RFE: Fix for broken JRE dir install In-Reply-To: <20110126194709.GA3027@redhat.com> References: <20110121013228.GI4611@rivendell.middle-earth.co.uk> <20110121025333.GA24487@redhat.com> <20110121133540.GC13935@rivendell.middle-earth.co.uk> <20110121151327.GA10878@redhat.com> <20110121204649.GB21893@rivendell.middle-earth.co.uk> <20110121224039.GA3954@redhat.com> <20110122012326.GG21893@rivendell.middle-earth.co.uk> <20110125235737.GA20834@redhat.com> <20110126190220.GH21785@rivendell.middle-earth.co.uk> <20110126194709.GA3027@redhat.com> Message-ID: <20110126200716.GL21785@rivendell.middle-earth.co.uk> On 14:47 Wed 26 Jan , Deepak Bhole wrote: > * Dr Andrew John Hughes [2011-01-26 14:02]: > > On 18:57 Tue 25 Jan , Deepak Bhole wrote: > > > * Dr Andrew John Hughes [2011-01-21 20:23]: > > > > On 17:40 Fri 21 Jan , Deepak Bhole wrote: > > > > > > > > > > > > > > > > IcedTea-Web does not 'put things in JDK_HOME/bin'. It puts them in > > > > ${bindir} which defaults to ${prefix}/bin. That's only equal to > > > > JDK_HOME/bin if ${prefix} is set to JDK_HOME. For a general application, > > > > ${bindir} is the primary location. > > > > > > > > That said, I support adding the $(JRE_DIR_PREFIX) hack to IcedTea-Web 1.0 > > > > as I said before. You just need to do in the patch what you say in the mail ;-) > > > > > > > > > > Having thought more about different RPM scenarios, I can see what you > > > mean now. I was incorrectly understanding the install requirements > > > earlier. I have updated the patch to remove the linking changes. Sorry > > > for the unnecessary confusion. > > > > > > I did however update it to use relative symlinks i.e. something like: > > > > > > jre/bin/javaws -> ../../bin/javaws > > > > > > Rather than the current way which creates absolute links (and makes the tree > > > un-relocatable). > > > > > > > To do this, > > > > > + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > > > > should also be changed to create $(DESTDIR)$(prefix)/bin instead of $(DESTDIR)$(bindir). > > The patch below will break if $(bindir) != $(prefix)/bin. > > > > Clearly, this breaks the use of --bindir. > > > > Doh! Fixed in attached patch. Also fixed the ${INSTALL_PROGRAM} > directives which were installing to $(DESTDIR)$(bindir). > I'm getting so confused by all this now I'd assumed that INSTALL_PROGRAM was using jre/bin as in the previous patches. I thought you wanted jre/bin to be the primary one, which would mean install to $(prefix)$(JRE_DIR_PREFIX)/bin and then symlinking $(prefix)/bin to it if $(JRE_DIR_PREFIX) is non-empty? i.e. ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin if [ "x$(JRE_DIR_PREFIX)" != "x" ] ; then \ if [ -L $(DESTDIR)$(prefix)/bin/javaws ] ; then \ rm -f $(DESTDIR)$(prefix)/bin/javaws ; \ fi ; \ if [ ! -e $(DESTDIR)$(prefix)/bin/javaws ] ; then \ ln -s ../jre/bin/javaws $(DESTDIR)$(prefix)/bin ; \ fi ; \ fi If we are installing in a JRE tree, JRE_DIR_PREFIX is empty so all that is executed is: ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)/bin If you're happy with /bin being the primary one, then the patch below is ok for 1.0. > Cheers, > Deepak > > diff -r 43212217e9c0 Makefile.am > --- a/Makefile.am Wed Dec 15 10:17:51 2010 -0500 > +++ b/Makefile.am Wed Jan 26 14:44:20 2011 -0500 > @@ -102,37 +102,37 @@ > clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs > > install-exec-local: > - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) > + ${mkinstalldirs} $(DESTDIR)$(prefix)/bin $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > if ENABLE_PLUGIN > - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ > + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) > - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > endif > - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)/bin > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > fi ; \ > if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > + ln -s ../../bin/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > fi ; \ > fi > - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(prefix)/bin > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > fi ; \ > if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > + ln -s ../../bin/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > fi ; \ > fi > > install-data-local: > ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 > ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 > - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib > + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > if ENABLE_DOCS > ${mkinstalldirs} $(DESTDIR)$(htmldir) > (cd ${abs_top_builddir}/docs/netx; \ > @@ -150,23 +150,25 @@ > endif > > uninstall-local: > - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar > - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > - rm -f $(DESTDIR)$(bindir)/javaws > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/javaws > + if [ -L $(DESTDIR)$(prefix)/bin/javaws ] ; then \ > + rm -f $(DESTDIR)$(prefix)/bin/javaws ; \ > fi > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > - rm -f $(DESTDIR)$(bindir)/itweb-settings > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/itweb-settings > + if [ -L $(DESTDIR)$(prefix)/bin/itweb-settings ] ; then \ > + rm -f $(DESTDIR)$(prefix)/bin/itweb-settings ; \ > fi > - rm -rf $(DESTDIR)$(htmldir) > + rm -rf $(DESTDIR)$(htmldir)/* > + if [ -d $(DESTDIR)$(htmldir) ] ; then \ > + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ > + fi > > # Plugin > > @@ -349,7 +351,7 @@ > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > mkdir -p $(NETX_DIR)/launcher && \ > $(CC) $(LAUNCHER_FLAGS) \ > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ > -DPROGNAME='"javaws"' -c -o $@ $< > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > diff -r 43212217e9c0 configure.ac > --- a/configure.ac Wed Dec 15 10:17:51 2010 -0500 > +++ b/configure.ac Wed Jan 26 14:44:20 2011 -0500 > @@ -78,4 +78,12 @@ > IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) > IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE > > +# Set JRE prefix based on whether to-level prefix is a JDK dir or a JRE dir > +if test -d ${prefix}/jre ; then > + JRE_DIR_PREFIX="/jre" ; > +else > + JRE_DIR_PREFIX="" ; > +fi ; > +AC_SUBST([JRE_DIR_PREFIX]) > + > AC_OUTPUT > diff -r 43212217e9c0 netx/net/sourceforge/jnlp/Launcher.java > --- a/netx/net/sourceforge/jnlp/Launcher.java Wed Dec 15 10:17:51 2010 -0500 > +++ b/netx/net/sourceforge/jnlp/Launcher.java Wed Jan 26 14:44:20 2011 -0500 > @@ -330,7 +330,12 @@ > List commands = new LinkedList(); > > // this property is set by the javaws launcher to point to the javaws binary > - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); > + String pathToWebstartBinary = System.getProperty("java.home") + > + File.separatorChar + > + "bin" + > + File.separatorChar + > + "javaws"; > + > commands.add(pathToWebstartBinary); > // use -Jargument format to pass arguments to the JVM through the launcher > for (String arg : vmArgs) { -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From dbhole at redhat.com Wed Jan 26 12:28:30 2011 From: dbhole at redhat.com (Deepak Bhole) Date: Wed, 26 Jan 2011 15:28:30 -0500 Subject: [icedtea-web] RFE: Fix for broken JRE dir install In-Reply-To: <20110126200716.GL21785@rivendell.middle-earth.co.uk> References: <20110121025333.GA24487@redhat.com> <20110121133540.GC13935@rivendell.middle-earth.co.uk> <20110121151327.GA10878@redhat.com> <20110121204649.GB21893@rivendell.middle-earth.co.uk> <20110121224039.GA3954@redhat.com> <20110122012326.GG21893@rivendell.middle-earth.co.uk> <20110125235737.GA20834@redhat.com> <20110126190220.GH21785@rivendell.middle-earth.co.uk> <20110126194709.GA3027@redhat.com> <20110126200716.GL21785@rivendell.middle-earth.co.uk> Message-ID: <20110126202830.GB3027@redhat.com> * Dr Andrew John Hughes [2011-01-26 15:07]: > On 14:47 Wed 26 Jan , Deepak Bhole wrote: > > * Dr Andrew John Hughes [2011-01-26 14:02]: > > > On 18:57 Tue 25 Jan , Deepak Bhole wrote: > > > > * Dr Andrew John Hughes [2011-01-21 20:23]: > > > > > On 17:40 Fri 21 Jan , Deepak Bhole wrote: > > > > > > > > > > > > > > > > > > > > IcedTea-Web does not 'put things in JDK_HOME/bin'. It puts them in > > > > > ${bindir} which defaults to ${prefix}/bin. That's only equal to > > > > > JDK_HOME/bin if ${prefix} is set to JDK_HOME. For a general application, > > > > > ${bindir} is the primary location. > > > > > > > > > > That said, I support adding the $(JRE_DIR_PREFIX) hack to IcedTea-Web 1.0 > > > > > as I said before. You just need to do in the patch what you say in the mail ;-) > > > > > > > > > > > > > Having thought more about different RPM scenarios, I can see what you > > > > mean now. I was incorrectly understanding the install requirements > > > > earlier. I have updated the patch to remove the linking changes. Sorry > > > > for the unnecessary confusion. > > > > > > > > I did however update it to use relative symlinks i.e. something like: > > > > > > > > jre/bin/javaws -> ../../bin/javaws > > > > > > > > Rather than the current way which creates absolute links (and makes the tree > > > > un-relocatable). > > > > > > > > > > To do this, > > > > > > > + ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > > > > > > should also be changed to create $(DESTDIR)$(prefix)/bin instead of $(DESTDIR)$(bindir). > > > The patch below will break if $(bindir) != $(prefix)/bin. > > > > > > Clearly, this breaks the use of --bindir. > > > > > > > Doh! Fixed in attached patch. Also fixed the ${INSTALL_PROGRAM} > > directives which were installing to $(DESTDIR)$(bindir). > > > > I'm getting so confused by all this now I'd assumed that INSTALL_PROGRAM was using jre/bin as in the previous patches. > I thought you wanted jre/bin to be the primary one, which would mean install to $(prefix)$(JRE_DIR_PREFIX)/bin and then > symlinking $(prefix)/bin to it if $(JRE_DIR_PREFIX) is non-empty? i.e. > > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin > if [ "x$(JRE_DIR_PREFIX)" != "x" ] ; then \ > if [ -L $(DESTDIR)$(prefix)/bin/javaws ] ; then \ > rm -f $(DESTDIR)$(prefix)/bin/javaws ; \ > fi ; \ > if [ ! -e $(DESTDIR)$(prefix)/bin/javaws ] ; then \ > ln -s ../jre/bin/javaws $(DESTDIR)$(prefix)/bin ; \ > fi ; \ > fi > > If we are installing in a JRE tree, JRE_DIR_PREFIX is empty so all that is executed is: > ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)/bin > > If you're happy with /bin being the primary one, then the patch below is ok for 1.0. > Yes, I am happy with /bin being the primary one now. I wanted jre/bin to be primary before for rpm install reasons but after more thought/testing, I don't think it is correct behaviour. The original behaviour of /bin being primary is correct IMO. Cheers, Deepak > > Cheers, > > Deepak > > > > > diff -r 43212217e9c0 Makefile.am > > --- a/Makefile.am Wed Dec 15 10:17:51 2010 -0500 > > +++ b/Makefile.am Wed Jan 26 14:44:20 2011 -0500 > > @@ -102,37 +102,37 @@ > > clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs > > > > install-exec-local: > > - ${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR) > > + ${mkinstalldirs} $(DESTDIR)$(prefix)/bin $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR) > > if ENABLE_PLUGIN > > - ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/ > > + ${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/ > > ${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir) > > - ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > + ${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > endif > > - ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar > > - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir) > > + ${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)/bin > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > fi ; \ > > if [ ! -e $(prefix)/jre/bin/javaws ] ; then \ > > - ln -s $(DESTDIR)$(bindir)/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > + ln -s ../../bin/javaws $(DESTDIR)$(prefix)/jre/bin ; \ > > fi ; \ > > fi > > - ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib > > - ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir) > > + ${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > + ${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(prefix)/bin > > if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \ > > if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > fi ; \ > > if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \ > > - ln -s $(DESTDIR)$(bindir)/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > > + ln -s ../../bin/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \ > > fi ; \ > > fi > > > > install-data-local: > > ${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1 > > ${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1 > > - ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib > > + ${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib > > if ENABLE_DOCS > > ${mkinstalldirs} $(DESTDIR)$(htmldir) > > (cd ${abs_top_builddir}/docs/netx; \ > > @@ -150,23 +150,25 @@ > > endif > > > > uninstall-local: > > - rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > - rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar > > - rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp > > - rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar > > rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1 > > rm -f $(DESTDIR)$(bindir)/pluginappletviewer > > - rm -f $(DESTDIR)$(bindir)/javaws > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \ > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \ > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/javaws > > + if [ -L $(DESTDIR)$(prefix)/bin/javaws ] ; then \ > > + rm -f $(DESTDIR)$(prefix)/bin/javaws ; \ > > fi > > - rm -f $(DESTDIR)$(prefix)/jre/bin/javaws > > - rm -f $(DESTDIR)$(bindir)/itweb-settings > > - if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \ > > - rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \ > > + rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/bin/itweb-settings > > + if [ -L $(DESTDIR)$(prefix)/bin/itweb-settings ] ; then \ > > + rm -f $(DESTDIR)$(prefix)/bin/itweb-settings ; \ > > fi > > - rm -rf $(DESTDIR)$(htmldir) > > + rm -rf $(DESTDIR)$(htmldir)/* > > + if [ -d $(DESTDIR)$(htmldir) ] ; then \ > > + rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \ > > + fi > > > > # Plugin > > > > @@ -349,7 +351,7 @@ > > $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c > > mkdir -p $(NETX_DIR)/launcher && \ > > $(CC) $(LAUNCHER_FLAGS) \ > > - -DJAVA_ARGS='{ "-J-ms8m", "-J-Djava.icedtea-web.bin=$(DESTDIR)$(bindir)/javaws", "net.sourceforge.jnlp.runtime.Boot", }' \ > > + -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot", }' \ > > -DPROGNAME='"javaws"' -c -o $@ $< > > > > $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c > > diff -r 43212217e9c0 configure.ac > > --- a/configure.ac Wed Dec 15 10:17:51 2010 -0500 > > +++ b/configure.ac Wed Jan 26 14:44:20 2011 -0500 > > @@ -78,4 +78,12 @@ > > IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef]) > > IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE > > > > +# Set JRE prefix based on whether to-level prefix is a JDK dir or a JRE dir > > +if test -d ${prefix}/jre ; then > > + JRE_DIR_PREFIX="/jre" ; > > +else > > + JRE_DIR_PREFIX="" ; > > +fi ; > > +AC_SUBST([JRE_DIR_PREFIX]) > > + > > AC_OUTPUT > > diff -r 43212217e9c0 netx/net/sourceforge/jnlp/Launcher.java > > --- a/netx/net/sourceforge/jnlp/Launcher.java Wed Dec 15 10:17:51 2010 -0500 > > +++ b/netx/net/sourceforge/jnlp/Launcher.java Wed Jan 26 14:44:20 2011 -0500 > > @@ -330,7 +330,12 @@ > > List commands = new LinkedList(); > > > > // this property is set by the javaws launcher to point to the javaws binary > > - String pathToWebstartBinary = System.getProperty("java.icedtea-web.bin"); > > + String pathToWebstartBinary = System.getProperty("java.home") + > > + File.separatorChar + > > + "bin" + > > + File.separatorChar + > > + "javaws"; > > + > > commands.add(pathToWebstartBinary); > > // use -Jargument format to pass arguments to the JVM through the launcher > > for (String arg : vmArgs) { > > > -- > Andrew :) > > Free Java Software Engineer > Red Hat, Inc. (http://www.redhat.com) > > Support Free Java! > Contribute to GNU Classpath and IcedTea > http://www.gnu.org/software/classpath > http://icedtea.classpath.org > PGP Key: 94EFD9D8 (http://subkeys.pgp.net) > Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at redhat.com Wed Jan 26 12:42:38 2011 From: omajid at redhat.com (Omair Majid) Date: Wed, 26 Jan 2011 15:42:38 -0500 Subject: [icedtea-web] RFC: add support for packEnabled and versionEnabled Message-ID: <4D40873E.7010502@redhat.com> Hi, The attached patch adds support for packEnabled and versionEnabled properties in JNLP files. This allows JNLP applications to use pack200 compression and versioned jars without requiring special server configuration/software. It also fixes bug RH669942. The patch adds a new class DownloadOptions which specify download options for jars (currently just version and pack200 support). Another new class ResourceUrlCreator is used to get a list of valid urls for a resource. ResourceTracker now uses ResourceUrlCreator to get the list of valid urls for downloading a jar and then tries to find the best one. initializeResource() and downloadResource() both use this url. downloadResource() has been modified to look at the file extension as well as the content-encoding when deciding whether a file is compressed or not. The patch is much bigger than I had expected it to be. It also affects core functionality - downloading jars. I would appreciate any comments and suggestions for improvements. Thanks, Omair [1] https://bugzilla.redhat.com/show_bug.cgi?id=669942 -------------- next part -------------- A non-text attachment was scrubbed... Name: 669942-add-pack-and-version-02.patch Type: text/x-patch Size: 24806 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110126/9ff68058/669942-add-pack-and-version-02.patch From omajid at redhat.com Wed Jan 26 12:45:19 2011 From: omajid at redhat.com (Omair Majid) Date: Wed, 26 Jan 2011 15:45:19 -0500 Subject: [icedtea-web] RFC: add support for packEnabled and versionEnabled In-Reply-To: <4D40873E.7010502@redhat.com> References: <4D40873E.7010502@redhat.com> Message-ID: <4D4087DF.3030303@redhat.com> On 01/26/2011 03:42 PM, Omair Majid wrote: > Hi, > > The attached patch adds support for packEnabled and versionEnabled > properties in JNLP files. This allows JNLP applications to use pack200 > compression and versioned jars without requiring special server > configuration/software. It also fixes bug RH669942. > More information about packEnabled and versionEnabled is available at http://download.oracle.com/javase/6/docs/technotes/guides/jweb/tools/pack200.html Cheers, Omair From omajid at redhat.com Wed Jan 26 13:44:40 2011 From: omajid at redhat.com (Omair Majid) Date: Wed, 26 Jan 2011 16:44:40 -0500 Subject: [icedtea-web] RFC: PR618 - Can't install OpenDJ, JavaWebStart fails with Input stream is null error. In-Reply-To: <20110126000318.GF18564@rivendell.middle-earth.co.uk> References: <4D3F27BE.9060300@redhat.com> <20110126000318.GF18564@rivendell.middle-earth.co.uk> Message-ID: <4D4095C8.4020603@redhat.com> On 01/25/2011 07:03 PM, Dr Andrew John Hughes wrote: > On 14:42 Tue 25 Jan , Omair Majid wrote: >> Hi, >> >> The attached patch fixes PR618. The issue is that jars marked as lazy >> are not currently searched for resources other than classes. So loading >> classes from lazy jars works, but loading anything else (zip files in >> the case of the bug report) fails. >> >> The attached patch fixes findResources to use lazy jars if needed. >> >> URLClassLoader invokes findResource() as a part of its getResource() >> implementation. Instead of duplicating the addition of lazy jars in >> getResource(), getResource() was removed, and findResource added >> instead. findResource() now delegates to findResources(), so there is >> only one place where an actual search for resources is performed. >> >> Any concerns or comments? >> > >> diff -r 64da2a80df88 netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java >> --- a/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Tue Jan 25 10:19:20 2011 -0500 >> +++ b/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Tue Jan 25 14:42:07 2011 -0500 >> @@ -1086,27 +1087,42 @@ >> * Finds the resource in this, the parent, or the extension >> * class loaders. >> */ >> - public URL getResource(String name) { >> - URL result = super.getResource(name); >> - >> - for (int i = 1; i< loaders.length; i++) >> - if (result == null) >> - result = loaders[i].getResource(name); >> - >> - return result; >> + @Override >> + public URL findResource(String name) { >> + try { >> + return findResources(name).nextElement(); >> + } catch (NoSuchElementException e) { >> + return null; >> + } catch (IOException e) { >> + return null; >> + } > > Would it be more efficient to check if there are more elements first > rather than throwing and catching an exception? > I am not sure about efficiency, but the attached patch fixes it. >> @@ -1116,7 +1132,7 @@ >> resources.add(e.nextElement()); >> } >> >> - return resources.elements(); >> + return resources; >> } > > Is findResources the only consumer of the resources collection? If so, it would be > more efficient to use an ArrayList or LinkedList and avoid the implicit synchronisation > of Vector. > Yup, findResources is the only method using it. I did not want to touch original code (at least code that worked), so I left the vector as it was. I have changed it now. > What is the reason for returning a List from findResourcesBySearching rather than just > an Iterator/Enumeration? AFAICS, you just create an enumeration from it anyway and > hasNext()/hasNextElement() would tell you if there are no entries. > Is using an Iterator/Enumeration better than using a List? I am not aware of the differences, and findResourcesBySearching() already creates a List that I can return. So I thought I would avoid creating an Enumeration based on it until necessary. The attached patch changes this bit too, though I am not sure I see the advantage. Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: lazy-load-resources-03.patch Type: text/x-patch Size: 2512 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110126/fcda073d/lazy-load-resources-03.patch From omajid at redhat.com Wed Jan 26 14:51:11 2011 From: omajid at redhat.com (Omair Majid) Date: Wed, 26 Jan 2011 17:51:11 -0500 Subject: [icedtea-web] RFC: pick up name and version from configure In-Reply-To: <20110126194409.GI21785@rivendell.middle-earth.co.uk> References: <4D3F04A6.2030200@redhat.com> <20110126194409.GI21785@rivendell.middle-earth.co.uk> Message-ID: <4D40A55F.3090804@redhat.com> On 01/26/2011 02:44 PM, Dr Andrew John Hughes wrote: > On 12:13 Tue 25 Jan , Omair Majid wrote: >> The attached patch gets rid of the hardcoded names and version numbers >> in net. It makes netx pick up the right name and version form the >> configure script. >> > > I think it would be much cleaner to produce the manifest using autoconf's existing support for this > rather than hacking stuff into the Makefile. You need to AC_SUBST FULL_VERSION and then add > netx.manifest to AC_CONFIG_FILES. autoconf will do the rest. Make sure that the macros that > set ICEDTEA_REVISION (IT_OBTAIN_HG_REVISIONS) and PKGVERSION (IT_GET_PKGVERSION) are run before > FULL_VERSION is set. Something like the attached patch should do it. > > $ /home/andrew/projects/openjdk/icedtea-web/configure > ... > checking what version string to use... 1.1pre+r64da2a80df88 > ... > $ cat netx/netx.manifest > Implementation-Title: icedtea-web > Implementation-Version: 1.1pre+r64da2a80df88 > > $ /home/andrew/projects/openjdk/icedtea-web/configure --with-pkgversion=23 > ... > checking what version string to use... 1.1pre+r64da2a80df88 (23) > ... > $ cat netx/netx.manifest > Implementation-Title: icedtea-web > Implementation-Version: 1.1pre+r64da2a80df88 (23) > That's a great idea. Thanks for creating a patch for this too! I only have one tiny concern: it creates a new dir named netx under the build tree instead of using netx.build. I read through autoconf docs and nothing that seems like a fix jumped out at me. Any ideas? > The changes to Boot.java and the netx-dist target look fine. > Thanks for looking it over. I am attaching the complete patch. Cheers, Omair -------------- next part -------------- A non-text attachment was scrubbed... Name: name-version-from-configure-02.patch Type: text/x-patch Size: 4128 bytes Desc: not available Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110126/a05d68fc/name-version-from-configure-02.patch From ahughes at redhat.com Wed Jan 26 16:27:12 2011 From: ahughes at redhat.com (Dr Andrew John Hughes) Date: Thu, 27 Jan 2011 00:27:12 +0000 Subject: [icedtea-web] RFC: pick up name and version from configure In-Reply-To: <4D40A55F.3090804@redhat.com> References: <4D3F04A6.2030200@redhat.com> <20110126194409.GI21785@rivendell.middle-earth.co.uk> <4D40A55F.3090804@redhat.com> Message-ID: <20110127002712.GR21785@rivendell.middle-earth.co.uk> On 17:51 Wed 26 Jan , Omair Majid wrote: > On 01/26/2011 02:44 PM, Dr Andrew John Hughes wrote: > > On 12:13 Tue 25 Jan , Omair Majid wrote: > >> The attached patch gets rid of the hardcoded names and version numbers > >> in net. It makes netx pick up the right name and version form the > >> configure script. > >> > > > > I think it would be much cleaner to produce the manifest using autoconf's existing support for this > > rather than hacking stuff into the Makefile. You need to AC_SUBST FULL_VERSION and then add > > netx.manifest to AC_CONFIG_FILES. autoconf will do the rest. Make sure that the macros that > > set ICEDTEA_REVISION (IT_OBTAIN_HG_REVISIONS) and PKGVERSION (IT_GET_PKGVERSION) are run before > > FULL_VERSION is set. Something like the attached patch should do it. > > > > $ /home/andrew/projects/openjdk/icedtea-web/configure > > ... > > checking what version string to use... 1.1pre+r64da2a80df88 > > ... > > $ cat netx/netx.manifest > > Implementation-Title: icedtea-web > > Implementation-Version: 1.1pre+r64da2a80df88 > > > > $ /home/andrew/projects/openjdk/icedtea-web/configure --with-pkgversion=23 > > ... > > checking what version string to use... 1.1pre+r64da2a80df88 (23) > > ... > > $ cat netx/netx.manifest > > Implementation-Title: icedtea-web > > Implementation-Version: 1.1pre+r64da2a80df88 (23) > > > > That's a great idea. Thanks for creating a patch for this too! I only > have one tiny concern: it creates a new dir named netx under the build > tree instead of using netx.build. I read through autoconf docs and > nothing that seems like a fix jumped out at me. Any ideas? > Good point. I'd just move it to the top-level i.e. netx.manifest instead of netx/netx.manifest. The .desktop files are already there (which incidentally should move to this system too). > > The changes to Boot.java and the netx-dist target look fine. > > > > Thanks for looking it over. I am attaching the complete patch. > > Cheers, > Omair > diff -r 64da2a80df88 Makefile.am > --- a/Makefile.am Tue Jan 25 10:19:20 2011 -0500 > +++ b/Makefile.am Wed Jan 26 17:37:28 2011 -0500 > @@ -54,13 +54,6 @@ > SRC_DIR_LINK = $(REFLINK) > endif > > -if HAS_ICEDTEA_REVISION > -ICEDTEA_REV = +${ICEDTEA_REVISION} > -endif > -if HAS_PKGVERSION > -ICEDTEA_PKG = $(EMPTY) (${PKGVERSION}) > -endif > - > if ENABLE_DOCS > JAVADOC_OPTS=-use -keywords -encoding UTF-8 -splitIndex \ > -bottom ' Submit a bug or feature' > @@ -82,7 +75,7 @@ > -DEXPAND_CLASSPATH_WILDCARDS > LAUNCHER_LINK = -o $@ -pthread -Xlinker -O1 -Xlinker -z -Xlinker defs -L$(BOOT_DIR)/lib/$(INSTALL_ARCH_DIR) \ > -Wl,-soname=lib.so -Wl,-z -Wl,origin -Wl,--allow-shlib-undefined $(X11_CFLAGS) $(X11_LIBS) -ldl -lz > -PLUGIN_VERSION = IcedTea-Web $(PACKAGE_VERSION)$(ICEDTEA_REV)$(ICEDTEA_PKG) > +PLUGIN_VERSION = IcedTea-Web $(FULL_VERSION) > > EXTRA_DIST = $(top_srcdir)/netx $(top_srcdir)/plugin javaws.png javaws.desktop.in extra launcher \ > itweb-settings.desktop.in > @@ -298,10 +291,11 @@ > mkdir -p stamps > touch $@ > > -stamps/netx-dist.stamp: stamps/netx.stamp > +stamps/netx-dist.stamp: stamps/netx.stamp $(abs_top_builddir)/netx/netx.manifest > (cd $(NETX_DIR) ; \ > mkdir -p lib ; \ > - $(BOOT_DIR)/bin/jar cf lib/classes.jar javax/jnlp net ; \ > + $(BOOT_DIR)/bin/jar cfm lib/classes.jar \ > + $(abs_top_builddir)/netx/netx.manifest javax/jnlp net ; \ > cp -pPR $(SRC_DIR_LINK) $(NETX_SRCDIR) src; \ > find src -type f -exec chmod 640 '{}' ';' -o -type d -exec chmod 750 '{}' ';'; \ > cd src ; \ > diff -r 64da2a80df88 acinclude.m4 > --- a/acinclude.m4 Tue Jan 25 10:19:20 2011 -0500 > +++ b/acinclude.m4 Wed Jan 26 17:37:28 2011 -0500 > @@ -667,3 +667,19 @@ > fi > AC_PROVIDE([$0])dnl > ]) > + > +AC_DEFUN_ONCE([IT_SET_VERSION], > +[ > + AC_REQUIRE([IT_OBTAIN_HG_REVISIONS]) > + AC_REQUIRE([IT_GET_PKGVERSION]) > + AC_MSG_CHECKING([what version string to use]) > + if test "x${ICEDTEA_REVISION}" != xnone; then > + ICEDTEA_REV="+${ICEDTEA_REVISION}" > + fi > + if test "x${PKGVERSION}" != "xnone"; then > + ICEDTEA_PKG=" (${PKGVERSION})" > + fi > + FULL_VERSION="${PACKAGE_VERSION}${ICEDTEA_REV}${ICEDTEA_PKG}" > + AC_MSG_RESULT([${FULL_VERSION}]) > + AC_SUBST([FULL_VERSION]) > +]) > diff -r 64da2a80df88 configure.ac > --- a/configure.ac Tue Jan 25 10:19:20 2011 -0500 > +++ b/configure.ac Wed Jan 26 17:37:28 2011 -0500 > @@ -1,6 +1,6 @@ > AC_INIT([icedtea-web],[1.1pre],[distro-pkg-dev at openjdk.java.net], [icedtea-web], [http://icedtea.classpath.org/wiki/IcedTea-Web]) > AM_INIT_AUTOMAKE([1.9 tar-pax foreign]) > -AC_CONFIG_FILES([Makefile]) > +AC_CONFIG_FILES([Makefile netx/netx.manifest]) > > # Older automake doesn't generate these correctly > abs_top_builddir=`pwd -P` > @@ -35,8 +35,7 @@ > IT_FIND_JAVADOC > AC_CONFIG_FILES([javac], [chmod +x javac]) > > -IT_GET_PKGVERSION > -IT_OBTAIN_HG_REVISIONS > +IT_SET_VERSION > IT_CHECK_XULRUNNER_VERSION > > AC_CHECK_LIB(z, main,, [AC_MSG_ERROR("zlib not found - try installing zlib-devel")]) > diff -r 64da2a80df88 netx/net/sourceforge/jnlp/runtime/Boot.java > --- a/netx/net/sourceforge/jnlp/runtime/Boot.java Tue Jan 25 10:19:20 2011 -0500 > +++ b/netx/net/sourceforge/jnlp/runtime/Boot.java Wed Jan 26 17:37:28 2011 -0500 > @@ -58,11 +58,12 @@ > // todo: decide whether a spawned netx (external launch) > // should inherit the same options as this instance (store argv?) > > - private static final String version = "0.5"; > + private static final String name = Boot.class.getPackage().getImplementationTitle(); > + private static final String version = Boot.class.getPackage().getImplementationVersion(); > > /** the text to display before launching the about link */ > private static final String aboutMessage = "" > - + "netx v" + version + " - (C)2001-2003 Jon A. Maxwell (jmaxwell at users.sourceforge.net)\n" > + + name + " " + version > + "\n" > + R("BLaunchAbout"); > > diff -r 64da2a80df88 netx/netx.manifest.in > --- /dev/null Thu Jan 01 00:00:00 1970 +0000 > +++ b/netx/netx.manifest.in Wed Jan 26 17:37:28 2011 -0500 > @@ -0,0 +1,2 @@ > +Implementation-Title: @PACKAGE_NAME@ > +Implementation-Version: @FULL_VERSION@ -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and IcedTea http://www.gnu.org/software/classpath http://icedtea.classpath.org PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From omajid at icedtea.classpath.org Thu Jan 27 07:02:27 2011 From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org) Date: Thu, 27 Jan 2011 15:02:27 +0000 Subject: /hg/icedtea-web: Update AUTHORS and update notes.html to include... Message-ID: changeset ffb35fab7eff in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=ffb35fab7eff author: Omair Majid date: Thu Jan 27 10:02:05 2011 -0500 Update AUTHORS and update notes.html to include all authors. 2011-01-27 Omair Majid * AUTHORS: Update to include Jon A Maxwell. * extra/net/sourceforge/jnlp/about/resources/notes.html: Include everyone from AUTHORS. diffstat: 3 files changed, 19 insertions(+), 4 deletions(-) AUTHORS | 1 + ChangeLog | 6 ++++++ extra/net/sourceforge/jnlp/about/resources/notes.html | 16 ++++++++++++---- diffs (50 lines): diff -r 64da2a80df88 -r ffb35fab7eff AUTHORS --- a/AUTHORS Tue Jan 25 10:19:20 2011 -0500 +++ b/AUTHORS Thu Jan 27 10:02:05 2011 -0500 @@ -8,6 +8,7 @@ Matthias Klose Matthias Klose Francis Kung Omair Majid +Jon A. Maxwell Andrew Su Joshua Sumali Mark Wielaard diff -r 64da2a80df88 -r ffb35fab7eff ChangeLog --- a/ChangeLog Tue Jan 25 10:19:20 2011 -0500 +++ b/ChangeLog Thu Jan 27 10:02:05 2011 -0500 @@ -1,3 +1,9 @@ 2011-01-25 Omair Majid + + * AUTHORS: Update to include Jon A Maxwell. + * extra/net/sourceforge/jnlp/about/resources/notes.html: Include everyone + from AUTHORS. + 2011-01-25 Omair Majid * netx/net/sourceforge/jnlp/resources/default.jnlp: Remove. diff -r 64da2a80df88 -r ffb35fab7eff extra/net/sourceforge/jnlp/about/resources/notes.html --- a/extra/net/sourceforge/jnlp/about/resources/notes.html Tue Jan 25 10:19:20 2011 -0500 +++ b/extra/net/sourceforge/jnlp/about/resources/notes.html Thu Jan 27 10:02:05 2011 -0500 @@ -21,10 +21,18 @@
- Jon A. Maxwell
- developer
- Joshua Sumali
- developer + Lillian Angel
+ Deepak Bhole
+ Thomas Fitzsimmons
+ Andrew John Hughes
+ Matthias Klose
+ Francis Kung
+ Omair Majid
+ Jon A. Maxwell
+ Andrew Su
+ Joshua Sumali
+ Mark Wielaard
+ Man Lung Wong
From omajid at redhat.com Thu Jan 27 07:41:12 2011 From: omajid at redhat.com (Omair Majid) Date: Thu, 27 Jan 2011 10:41:12 -0500 Subject: [icedtea-web] RFC: remove default.jnlp In-Reply-To: <20110126194613.GJ21785@rivendell.middle-earth.co.uk> References: <4D3DE7DB.1030904@redhat.com> <20110124212504.GI17602@rivendell.middle-earth.co.uk> <4D3DF560.1060501@redhat.com> <20110124230720.GJ17602@rivendell.middle-earth.co.uk> <4D3EEDA2.8060802@redhat.com> <20110126194613.GJ21785@rivendell.middle-earth.co.uk> Message-ID: <4D419218.9010405@redhat.com> On 01/26/2011 02:46 PM, Dr Andrew John Hughes wrote: > On 10:34 Tue 25 Jan , Omair Majid wrote: >> I have attached a patch to update the list in the about.jnlp as well as >> add Jon to AUTHORS. >> >> I would also like to update the release notes (in notes.html) and the >> versions used, but that's another patch. >> >> Ok to commit? >> > > Yes, looks good. Thanks for looking it over. I have pushed it as changeset ffb35fab7eff. Cheers, Omair From omajid at redhat.com Thu Jan 27 09:31:22 2011 From: omajid at redhat.com (Omair Majid) Date: Thu, 27 Jan 2011 12:31:22 -0500 Subject: [icedtea-web] RFC: add support in netx for using proxy settings from browser In-Reply-To: <20110126195614.GK21785@rivendell.middle-earth.co.uk> References: <4D127CEB.9010508@redhat.com> <20101223004028.GM17229@rivendell.middle-earth.co.uk> <4D15033A.402@redhat.com> <4D151ED4.70102@redhat.com> <20110124172148.GA17602@rivendell.middle-earth.co.uk> <4D3E03BE.4010500@redhat.com> <20110126195614.GK21785@rivendell.middle-earth.co.uk> Message-ID: <4D41ABEA.1030901@redhat.com> On 01/26/2011 02:56 PM, Dr Andrew John Hughes wrote: > On 17:57 Mon 24 Jan , Omair Majid wrote: >> On 01/24/2011 12:21 PM, Dr Andrew John Hughes wrote: >>> > > snip... > >>> Is this a TODO or is this case really empty? >>> >> >> Definitely a TODO. I thought the error message in the fall-through case >> (next-line) made it clear. I have made it more explicit. >> > > Yeah, it will for the end user. The code comment was just unclear. > > snip... >> >>>> + /** >>>> + * Get an appropriate proxy for the given URI using static information from >>>> + * the browser's preferences file. >>>> + */ >>>> + private List getFromBrowserConfiguration(URI uri) { >>>> + List proxies = new ArrayList(); >>>> + >>>> + String scheme = uri.getScheme(); >>>> + >>>> + if (browserUseSameProxy) { >>>> + SocketAddress sa = new InetSocketAddress(browserHttpProxyHost, browserHttpProxyPort); >>>> + Proxy proxy; >>>> + if (scheme.equals("socket")) { >>>> + proxy = new Proxy(Type.SOCKS, sa); >>>> + } else { >>>> + proxy = new Proxy(Type.HTTP, sa); >>>> + } >>>> + proxies.add(proxy); >>>> + } else if (scheme.equals("http")) { >>>> + SocketAddress sa = new InetSocketAddress(browserHttpProxyHost, browserHttpProxyPort); >>>> + proxies.add(new Proxy(Type.HTTP, sa)); >>>> + } else if (scheme.equals("https")) { >>>> + SocketAddress sa = new InetSocketAddress(browserHttpsProxyHost, browserHttpsProxyPort); >>>> + proxies.add(new Proxy(Type.HTTP, sa)); >>> >>> Do you not need to do something different for HTTPS? Or is that handled elsewhere? >>> >> >> Are you referring to Type.HTTP? There are only 3 Types defined: DIRECT, >> HTTP and SOCKS. Type.HTTP is for http, https and ftp. >> > > Ok I'm just wondering how you distinguish between http, https and ftp in the proxies list? Presumably > you don't need to. > Yeah, the java libraries take care of it. The ProxySelector is used by the networking bits to query what proxy should be used whenever initiating a new connection. They expect a Proxy object with the right type - Type.HTTP for ftp, http or https connections. For example, sun.net.www.protocol.ftp.FtpURLConnection.connect() will only use the proxy if Proxy.Type is HTTP. sun.net.www.protocol.https.HttpsClient.needsTunnelling() also uses a Proxy with Type HTTPS. >> >> Does this look okay? Any further suggestions for improvement? >> > > Looks ok now. Just check the indenting (mentioned inline below) on BrowserAwareProxySelector and it > seems good to go. > Fixed. Thanks for reviewing the patch! Cheers, Omair From omajid at icedtea.classpath.org Thu Jan 27 09:58:06 2011 From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org) Date: Thu, 27 Jan 2011 17:58:06 +0000 Subject: /hg/icedtea-web: Use Firefox's preferences to determine proxy se... Message-ID: changeset 712dd97dc800 in /hg/icedtea-web details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=712dd97dc800 author: Omair Majid date: Thu Jan 27 12:56:40 2011 -0500 Use Firefox's preferences to determine proxy settings for javaws This patch adds support for finding, parsing and using basic information from Firefox's preferences to determine the correct proxy to use for javaws. Only the preferences from Firefox's default profile are used. Support for PAC, System or Automatic settings is not yet implemented. 2011-01-27 Omair Majid * netx/net/sourceforge/jnlp/resources/Messages.properties: Add RPRoxyPacNotImplemented, RProxyFirefoxNotFound, and RProxyFirefoxOptionNotImplemented. * netx/net/sourceforge/jnlp/runtime/JNLPProxySelector.java: Make abstract. (getFromBrowser): Remove implementation; make abstract. * netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java (initialize): Set BrowserAwareProxySelector as the proxy selector. * netx/net/sourceforge/jnlp/browser/BrowserAwareProxySelector.java: New file. This class extends JNLPProxySelector and searches the browser's configuration to load additional proxy settings from. * netx/net/sourceforge/jnlp/browser/FirefoxPreferencesFinder.java: New file. This class looks into the browser configration to find the preferences file for the default firefox profile. * netx/net/sourceforge/jnlp/browser/FirefoxPreferencesParser.java: New file. Parses the browser's preferences and makes it available through a simpler interface. diffstat: 8 files changed, 579 insertions(+), 12 deletions(-) ChangeLog | 19 NEWS | 4 netx/net/sourceforge/jnlp/browser/BrowserAwareProxySelector.java | 255 ++++++++++ netx/net/sourceforge/jnlp/browser/FirefoxPreferencesFinder.java | 137 +++++ netx/net/sourceforge/jnlp/browser/FirefoxPreferencesParser.java | 155 ++++++ netx/net/sourceforge/jnlp/resources/Messages.properties | 3 netx/net/sourceforge/jnlp/runtime/JNLPProxySelector.java | 15 netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java | 3 diffs (truncated from 678 to 500 lines): diff -r ffb35fab7eff -r 712dd97dc800 ChangeLog --- a/ChangeLog Thu Jan 27 10:02:05 2011 -0500 +++ b/ChangeLog Thu Jan 27 12:56:40 2011 -0500 @@ -1,3 +1,22 @@ 2011-01-27 Omair Majid + + * netx/net/sourceforge/jnlp/resources/Messages.properties: Add + RPRoxyPacNotImplemented, RProxyFirefoxNotFound, and + RProxyFirefoxOptionNotImplemented. + * netx/net/sourceforge/jnlp/runtime/JNLPProxySelector.java: Make abstract. + (getFromBrowser): Remove implementation; make abstract. + * netx/net/sourceforge/jnlp/runtime/JNLPRuntime.java + (initialize): Set BrowserAwareProxySelector as the proxy selector. + * netx/net/sourceforge/jnlp/browser/BrowserAwareProxySelector.java: New + file. This class extends JNLPProxySelector and searches the browser's + configuration to load additional proxy settings from. + * netx/net/sourceforge/jnlp/browser/FirefoxPreferencesFinder.java: New + file. This class looks into the browser configration to find the + preferences file for the default firefox profile. + * netx/net/sourceforge/jnlp/browser/FirefoxPreferencesParser.java: New + file. Parses the browser's preferences and makes it available through a + simpler interface. + 2011-01-27 Omair Majid * AUTHORS: Update to include Jon A Maxwell. diff -r ffb35fab7eff -r 712dd97dc800 NEWS --- a/NEWS Thu Jan 27 10:02:05 2011 -0500 +++ b/NEWS Thu Jan 27 12:56:40 2011 -0500 @@ -7,6 +7,10 @@ GX - http://bugs.gentoo.org/show_bug.cg GX - http://bugs.gentoo.org/show_bug.cgi?id=X CVE-XXXX-YYYY: http://www.cve.mitre.org/cgi-bin/cvename.cgi?name=XXXX-YYYY + +New in release 1.1 (2011-XX-XX): +* NetX + - Use Firefox's proxy settings if possible New in release 1.0 (2010-XX-XX): diff -r ffb35fab7eff -r 712dd97dc800 netx/net/sourceforge/jnlp/browser/BrowserAwareProxySelector.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/netx/net/sourceforge/jnlp/browser/BrowserAwareProxySelector.java Thu Jan 27 12:56:40 2011 -0500 @@ -0,0 +1,255 @@ +/* BrowserAwareProxySelector.java + Copyright (C) 2011 Red Hat, Inc. + +This file is part of IcedTea. + +IcedTea is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License as published by +the Free Software Foundation, version 2. + +IcedTea is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +General Public License for more details. + +You should have received a copy of the GNU General Public License +along with IcedTea; see the file COPYING. If not, write to +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +02110-1301 USA. + +Linking this library statically or dynamically with other modules is +making a combined work based on this library. Thus, the terms and +conditions of the GNU General Public License cover the whole +combination. + +As a special exception, the copyright holders of this library give you +permission to link this library with independent modules to produce an +executable, regardless of the license terms of these independent +modules, and to copy and distribute the resulting executable under +terms of your choice, provided that you also meet, for each linked +independent module, the terms and conditions of the license of that +module. An independent module is a module which is not derived from +or based on this library. If you modify this library, you may extend +this exception to your version of the library, but you are not +obligated to do so. If you do not wish to do so, delete this +exception statement from your version. +*/ +package net.sourceforge.jnlp.browser; + +import static net.sourceforge.jnlp.runtime.Translator.R; + +import java.io.File; +import java.io.IOException; +import java.net.InetSocketAddress; +import java.net.MalformedURLException; +import java.net.Proxy; +import java.net.SocketAddress; +import java.net.URI; +import java.net.URL; +import java.net.Proxy.Type; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import java.util.Map; + +import net.sourceforge.jnlp.runtime.JNLPProxySelector; +import net.sourceforge.jnlp.runtime.JNLPRuntime; + +/** + * A ProxySelector which can read proxy settings from a browser's + * configuration and use that. + * + * @see JNLPProxySelector + */ +public class BrowserAwareProxySelector extends JNLPProxySelector { + + /* firefox's constants */ + public static final int BROWSER_PROXY_TYPE_NONE = 0; + public static final int BROWSER_PROXY_TYPE_MANUAL = 1; + public static final int BROWSER_PROXY_TYPE_PAC = 2; + public static final int BROWSER_PROXY_TYPE_NONE2 = 3; + /** use gconf, WPAD and then env (and possibly others)*/ + public static final int BROWSER_PROXY_TYPE_AUTO = 4; + /** use env variables */ + public static final int BROWSER_PROXY_TYPE_SYSTEM = 5; + + private int browserProxyType = BROWSER_PROXY_TYPE_NONE; + private URL browserAutoConfigUrl; + private Boolean browserUseSameProxy; + private String browserHttpProxyHost; + private int browserHttpProxyPort; + private String browserHttpsProxyHost; + private int browserHttpsProxyPort; + private String browserFtpProxyHost; + private int browserFtpProxyPort; + private String browserSocks4ProxyHost; + private int browserSocks4ProxyPort; + + /** + * Create a new instance of this class, reading configuration fropm the browser + */ + public BrowserAwareProxySelector() { + super(); + try { + initFromBrowserConfig(); + } catch (IOException e) { + if (JNLPRuntime.isDebug()) { + e.printStackTrace(); + } + System.err.println(R("RProxyFirefoxNotFound")); + browserProxyType = PROXY_TYPE_NONE; + } + } + + /** + * Initialize configuration by reading preferences from the browser (firefox) + */ + private void initFromBrowserConfig() throws IOException { + + File preferencesFile = FirefoxPreferencesFinder.find(); + + FirefoxPreferencesParser parser = new FirefoxPreferencesParser(preferencesFile); + parser.parse(); + Map prefs = parser.getPreferences(); + + String type = prefs.get("network.proxy.type"); + if (type != null) { + browserProxyType = Integer.valueOf(type); + } else { + browserProxyType = BROWSER_PROXY_TYPE_AUTO; + } + + try { + browserAutoConfigUrl = new URL(prefs.get("network.proxy.autoconfig_url")); + } catch (MalformedURLException e) { + e.printStackTrace(); + } + + browserUseSameProxy = Boolean.valueOf(prefs.get("network.proxy.share_proxy_settings")); + + browserHttpProxyHost = prefs.get("network.proxy.http"); + browserHttpProxyPort = stringToPort(prefs.get("network.proxy.http_port")); + browserHttpsProxyHost = prefs.get("network.proxy.ssl"); + browserHttpsProxyPort = stringToPort(prefs.get("network.proxy.ssl_port")); + browserFtpProxyHost = prefs.get("network.proxy.ftp"); + browserFtpProxyPort = stringToPort(prefs.get("network.proxy.ftp_port")); + browserSocks4ProxyHost = prefs.get("networking.proxy.socks"); + browserSocks4ProxyPort = stringToPort(prefs.get("network.proxy.socks_port")); + } + + /** + * Returns port inside a string. Unlike {@link Integer#valueOf(String)}, + * it will not throw exceptions. + * + * @param string the string containing the integer to parse + * @return the port inside the string, or Integer.MIN_VALUE + */ + private int stringToPort(String string) { + try { + return Integer.valueOf(string); + } catch (NumberFormatException nfe) { + return Integer.MIN_VALUE; + } + } + + /** + * The main entry point for {@link BrowserAwareProxySelector}. Based on + * the browser settings, determines proxy information for a given URI. + *

+ * The appropriate proxy may be determined by reading static information + * from the browser's preferences file, or it may be computed dynamically, + * by, for example, running javascript code. + */ + @Override + protected List getFromBrowser(URI uri) { + List proxies = new ArrayList(); + + String optionDescription = null; + + switch (browserProxyType) { + case BROWSER_PROXY_TYPE_PAC: + proxies.addAll(getFromBrowserPAC(uri)); + break; + case BROWSER_PROXY_TYPE_MANUAL: + proxies.addAll(getFromBrowserConfiguration(uri)); + break; + case BROWSER_PROXY_TYPE_NONE: + proxies.add(Proxy.NO_PROXY); + break; + case BROWSER_PROXY_TYPE_AUTO: + // firefox will do a whole lot of stuff to automagically + // figure out the right settings. gconf, WPAD, and ENV are used. + // https://bugzilla.mozilla.org/show_bug.cgi?id=66057#c32 + // TODO this is probably not easy/quick to do. using libproxy might be + // the simpler workaround + if (optionDescription == null) { + optionDescription = "Automatic"; + } + case BROWSER_PROXY_TYPE_SYSTEM: + // means use $http_proxy, $ftp_proxy etc. + // TODO implement env vars if possible + if (optionDescription == null) { + optionDescription = "System"; + } + default: + if (optionDescription == null) { + optionDescription = "Unknown"; + } + System.err.println(R("RProxyFirefoxOptionNotImplemented", browserProxyType, optionDescription)); + proxies.add(Proxy.NO_PROXY); + } + + if (JNLPRuntime.isDebug()) { + System.out.println("Browser selected proxies: " + proxies.toString()); + } + + return proxies; + } + + /** + * Get an appropriate proxy for a given URI using a PAC specified in the + * browser. + */ + private List getFromBrowserPAC(URI uri) { + System.err.println(R("RPRoxyPacNotImplemented")); + return Arrays.asList(new Proxy[] { Proxy.NO_PROXY }); + } + + /** + * Get an appropriate proxy for the given URI using static information from + * the browser's preferences file. + */ + private List getFromBrowserConfiguration(URI uri) { + List proxies = new ArrayList(); + + String scheme = uri.getScheme(); + + if (browserUseSameProxy) { + SocketAddress sa = new InetSocketAddress(browserHttpProxyHost, browserHttpProxyPort); + Proxy proxy; + if (scheme.equals("socket")) { + proxy = new Proxy(Type.SOCKS, sa); + } else { + proxy = new Proxy(Type.HTTP, sa); + } + proxies.add(proxy); + } else if (scheme.equals("http")) { + SocketAddress sa = new InetSocketAddress(browserHttpProxyHost, browserHttpProxyPort); + proxies.add(new Proxy(Type.HTTP, sa)); + } else if (scheme.equals("https")) { + SocketAddress sa = new InetSocketAddress(browserHttpsProxyHost, browserHttpsProxyPort); + proxies.add(new Proxy(Type.HTTP, sa)); + } else if (scheme.equals("ftp")) { + SocketAddress sa = new InetSocketAddress(browserFtpProxyHost, browserFtpProxyPort); + proxies.add(new Proxy(Type.HTTP, sa)); + } else if (scheme.equals("socket")) { + SocketAddress sa = new InetSocketAddress(browserSocks4ProxyHost, browserSocks4ProxyPort); + proxies.add(new Proxy(Type.SOCKS, sa)); + } else { + proxies.add(Proxy.NO_PROXY); + } + + return proxies; + } + +} diff -r ffb35fab7eff -r 712dd97dc800 netx/net/sourceforge/jnlp/browser/FirefoxPreferencesFinder.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/netx/net/sourceforge/jnlp/browser/FirefoxPreferencesFinder.java Thu Jan 27 12:56:40 2011 -0500 @@ -0,0 +1,137 @@ +/* FirefoxPreferencesFinder.java + Copyright (C) 2011 Red Hat, Inc. + +This file is part of IcedTea. + +IcedTea is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License as published by +the Free Software Foundation, version 2. + +IcedTea is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +General Public License for more details. + +You should have received a copy of the GNU General Public License +along with IcedTea; see the file COPYING. If not, write to +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +02110-1301 USA. + +Linking this library statically or dynamically with other modules is +making a combined work based on this library. Thus, the terms and +conditions of the GNU General Public License cover the whole +combination. + +As a special exception, the copyright holders of this library give you +permission to link this library with independent modules to produce an +executable, regardless of the license terms of these independent +modules, and to copy and distribute the resulting executable under +terms of your choice, provided that you also meet, for each linked +independent module, the terms and conditions of the license of that +module. An independent module is a module which is not derived from +or based on this library. If you modify this library, you may extend +this exception to your version of the library, but you are not +obligated to do so. If you do not wish to do so, delete this +exception statement from your version. +*/ + +package net.sourceforge.jnlp.browser; + +import java.io.BufferedReader; +import java.io.File; +import java.io.FileNotFoundException; +import java.io.FileReader; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +import net.sourceforge.jnlp.runtime.JNLPRuntime; + +/** + * Finds the file corresponding to firefox's (default) preferences file + */ +public class FirefoxPreferencesFinder { + + /** + * Returns a file object representing firefox's preferences file + * + * @return a File object representing the preferences file. + * @throws FileNotFoundException if the preferences file could not be found + * @throws IOException if an exception occurs while trying to identify the + * location of the preferences file. + */ + public static File find() throws IOException { + + String configPath = System.getProperty("user.home") + File.separator + ".mozilla" + + File.separator + "firefox" + File.separator; + + String profilesPath = configPath + "profiles.ini"; + + if (!(new File(profilesPath).isFile())) { + throw new FileNotFoundException(profilesPath); + } + + if (JNLPRuntime.isDebug()) { + System.out.println("Using firefox's profiles file: " + profilesPath); + } + BufferedReader reader = new BufferedReader(new FileReader(profilesPath)); + + List linesInSection = new ArrayList(); + boolean foundDefaultSection = false; + + /* + * The profiles.ini file is an ini file. This is a quick hack to read + * it. It is very likely to break given anything strange. + */ + + // find the section with an entry Default=1 + while (true) { + String line = reader.readLine(); + if (line == null) { + break; + } + + line = line.trim(); + if (line.startsWith("[") && line.endsWith("]")) { + if (foundDefaultSection) { + break; + } + // new section + linesInSection = new ArrayList(); + } else { + linesInSection.add(line); + int equalSignPos = line.indexOf('='); + if (equalSignPos > 0) { + String key = line.substring(0, equalSignPos).trim(); + String value = line.substring(equalSignPos+1).trim(); + if (key.toLowerCase().equals("default") && value.equals("1")) { + foundDefaultSection = true; + } + } + } + + } + + if (!foundDefaultSection) { + throw new FileNotFoundException("preferences file"); + } + + String path = null; + for (String line : linesInSection) { + if (line.startsWith("Path=")) { + path = line.substring("Path=".length()); + } + } + + if (path == null) { + throw new FileNotFoundException("preferences file"); + } else { + String fullPath = configPath + path + File.separator + "prefs.js"; + if (JNLPRuntime.isDebug()) { + System.out.println("Found preferences file: " + fullPath); + } + return new File(fullPath); + } + } + +} diff -r ffb35fab7eff -r 712dd97dc800 netx/net/sourceforge/jnlp/browser/FirefoxPreferencesParser.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/netx/net/sourceforge/jnlp/browser/FirefoxPreferencesParser.java Thu Jan 27 12:56:40 2011 -0500 @@ -0,0 +1,155 @@ +/* FirefoxPreferencesParser.java + Copyright (C) 2011 Red Hat, Inc. + +This file is part of IcedTea. + +IcedTea is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License as published by +the Free Software Foundation, version 2. + +IcedTea is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +General Public License for more details. + +You should have received a copy of the GNU General Public License +along with IcedTea; see the file COPYING. If not, write to +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +02110-1301 USA. + +Linking this library statically or dynamically with other modules is +making a combined work based on this library. Thus, the terms and +conditions of the GNU General Public License cover the whole +combination. + +As a special exception, the copyright holders of this library give you +permission to link this library with independent modules to produce an +executable, regardless of the license terms of these independent +modules, and to copy and distribute the resulting executable under +terms of your choice, provided that you also meet, for each linked +independent module, the terms and conditions of the license of that +module. An independent module is a module which is not derived from +or based on this library. If you modify this library, you may extend +this exception to your version of the library, but you are not +obligated to do so. If you do not wish to do so, delete this +exception statement from your version. +*/ + +package net.sourceforge.jnlp.browser; + +import java.io.BufferedReader; +import java.io.File; +import java.io.FileReader; +import java.io.IOException; +import java.util.HashMap; +import java.util.Map; + +import net.sourceforge.jnlp.runtime.JNLPRuntime; + +/** + * A parser for Firefox's preferences file. It can 'parse' Firefox's + * preferences file and expose the prefrences in a simple to use format. + *

+ * Sample usage: + *

+ * FirefoxPreferencesParser p = new FirefoxPreferencesParser(prefsFile);
+ * p.parse();


From omajid at redhat.com  Thu Jan 27 10:11:06 2011
From: omajid at redhat.com (Omair Majid)
Date: Thu, 27 Jan 2011 13:11:06 -0500
Subject: [icedtea-web] RFC: pick up name and version from configure
In-Reply-To: <20110127002712.GR21785@rivendell.middle-earth.co.uk>
References: <4D3F04A6.2030200@redhat.com>
	<20110126194409.GI21785@rivendell.middle-earth.co.uk>
	<4D40A55F.3090804@redhat.com>
	<20110127002712.GR21785@rivendell.middle-earth.co.uk>
Message-ID: <4D41B53A.9070205@redhat.com>

On 01/26/2011 07:27 PM, Dr Andrew John Hughes wrote:
> On 17:51 Wed 26 Jan     , Omair Majid wrote:
>> On 01/26/2011 02:44 PM, Dr Andrew John Hughes wrote:
>>> On 12:13 Tue 25 Jan     , Omair Majid wrote:
>>>> The attached patch gets rid of the hardcoded names and version numbers
>>>> in net. It makes netx pick up the right name and version form the
>>>> configure script.
>>>>
>>>
>>> I think it would be much cleaner to produce the manifest using autoconf's existing support for this
>>> rather than hacking stuff into the Makefile.  You need to AC_SUBST FULL_VERSION and then add
>>> netx.manifest to AC_CONFIG_FILES.  autoconf will do the rest.  Make sure that the macros that
>>> set ICEDTEA_REVISION (IT_OBTAIN_HG_REVISIONS) and PKGVERSION (IT_GET_PKGVERSION) are run before
>>> FULL_VERSION is set.  Something like the attached patch should do it.
>>>
>>> $ /home/andrew/projects/openjdk/icedtea-web/configure
>>> ...
>>> checking what version string to use... 1.1pre+r64da2a80df88
>>> ...
>>> $ cat netx/netx.manifest
>>> Implementation-Title: icedtea-web
>>> Implementation-Version: 1.1pre+r64da2a80df88
>>>
>>> $ /home/andrew/projects/openjdk/icedtea-web/configure --with-pkgversion=23
>>> ...
>>> checking what version string to use... 1.1pre+r64da2a80df88 (23)
>>> ...
>>> $ cat netx/netx.manifest
>>> Implementation-Title: icedtea-web
>>> Implementation-Version: 1.1pre+r64da2a80df88 (23)
>>>
>>
>> That's a great idea. Thanks for creating a patch for this too! I only
>> have one tiny concern: it creates a new dir named netx under the build
>> tree instead of using netx.build. I read through autoconf docs and
>> nothing that seems like a fix jumped out at me. Any ideas?
>>
>
> Good point.  I'd just move it to the top-level i.e. netx.manifest instead of
> netx/netx.manifest.  The .desktop files are already there (which incidentally
> should move to this system too).
>

Done. I am attaching the updated patch. Ok to commit?

Cheers,
Omair

-------------- next part --------------
A non-text attachment was scrubbed...
Name: name-version-from-configure-03.patch
Type: text/x-patch
Size: 4103 bytes
Desc: not available
Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110127/78ab8993/name-version-from-configure-03.patch 

From omajid at redhat.com  Thu Jan 27 13:50:26 2011
From: omajid at redhat.com (Omair Majid)
Date: Thu, 27 Jan 2011 16:50:26 -0500
Subject: [icedtea-web] RFC: pick up name and version from configure
In-Reply-To: <20110127002712.GR21785@rivendell.middle-earth.co.uk>
References: <4D3F04A6.2030200@redhat.com>
	<20110126194409.GI21785@rivendell.middle-earth.co.uk>
	<4D40A55F.3090804@redhat.com>
	<20110127002712.GR21785@rivendell.middle-earth.co.uk>
Message-ID: <4D41E8A2.2010101@redhat.com>

On 01/26/2011 07:27 PM, Dr Andrew John Hughes wrote:
>> On 01/26/2011 02:44 PM, Dr Andrew John Hughes wrote:
>>> I think it would be much cleaner to produce the manifest using
>>> autoconf's existing support for this rather than hacking stuff
>>> into the Makefile.  You need to AC_SUBST FULL_VERSION and then
>>> add netx.manifest to AC_CONFIG_FILES.  autoconf will do the rest.
>>> Make sure that the macros that set ICEDTEA_REVISION
>>> (IT_OBTAIN_HG_REVISIONS) and PKGVERSION (IT_GET_PKGVERSION) are
>>> run before FULL_VERSION is set.  Something like the attached
>>> patch should do it.
>>>
> The .desktop files are already there (which incidentally should move
> to this system too).
>

The only substitution performed in the desktop-related *.in files
relates to adding @bindir@/$executable_name in it. The automake manual
discourages [1] [2] depending on the installation path in the configure
stage. It instead recommends that snippets be used to generate the
output file from the .in file during make. This is what we already do.
Is there a good reason why we should move the desktop files to the
AC_CONFIG_FILES system? I am sure I am missing something quite obvious here.

Thanks,
Omair

[1] 
http://www.gnu.org/software/autoconf/manual/html_node/Installation-Directory-Variables.html#Installation-Directory-Variables
[2] 
http://www.gnu.org/software/autoconf/manual/html_node/Defining-Directories.html#Defining-Directories


From ahughes at redhat.com  Thu Jan 27 13:56:45 2011
From: ahughes at redhat.com (Dr Andrew John Hughes)
Date: Thu, 27 Jan 2011 21:56:45 +0000
Subject: [icedtea-web] RFC: pick up name and version from configure
In-Reply-To: <4D41B53A.9070205@redhat.com>
References: <4D3F04A6.2030200@redhat.com>
	<20110126194409.GI21785@rivendell.middle-earth.co.uk>
	<4D40A55F.3090804@redhat.com>
	<20110127002712.GR21785@rivendell.middle-earth.co.uk>
	<4D41B53A.9070205@redhat.com>
Message-ID: <20110127215645.GE24866@rivendell.middle-earth.co.uk>

On 13:11 Thu 27 Jan     , Omair Majid wrote:
> On 01/26/2011 07:27 PM, Dr Andrew John Hughes wrote:
> > On 17:51 Wed 26 Jan     , Omair Majid wrote:
> >> On 01/26/2011 02:44 PM, Dr Andrew John Hughes wrote:
> >>> On 12:13 Tue 25 Jan     , Omair Majid wrote:
> >>>> The attached patch gets rid of the hardcoded names and version numbers
> >>>> in net. It makes netx pick up the right name and version form the
> >>>> configure script.
> >>>>
> >>>
> >>> I think it would be much cleaner to produce the manifest using autoconf's existing support for this
> >>> rather than hacking stuff into the Makefile.  You need to AC_SUBST FULL_VERSION and then add
> >>> netx.manifest to AC_CONFIG_FILES.  autoconf will do the rest.  Make sure that the macros that
> >>> set ICEDTEA_REVISION (IT_OBTAIN_HG_REVISIONS) and PKGVERSION (IT_GET_PKGVERSION) are run before
> >>> FULL_VERSION is set.  Something like the attached patch should do it.
> >>>
> >>> $ /home/andrew/projects/openjdk/icedtea-web/configure
> >>> ...
> >>> checking what version string to use... 1.1pre+r64da2a80df88
> >>> ...
> >>> $ cat netx/netx.manifest
> >>> Implementation-Title: icedtea-web
> >>> Implementation-Version: 1.1pre+r64da2a80df88
> >>>
> >>> $ /home/andrew/projects/openjdk/icedtea-web/configure --with-pkgversion=23
> >>> ...
> >>> checking what version string to use... 1.1pre+r64da2a80df88 (23)
> >>> ...
> >>> $ cat netx/netx.manifest
> >>> Implementation-Title: icedtea-web
> >>> Implementation-Version: 1.1pre+r64da2a80df88 (23)
> >>>
> >>
> >> That's a great idea. Thanks for creating a patch for this too! I only
> >> have one tiny concern: it creates a new dir named netx under the build
> >> tree instead of using netx.build. I read through autoconf docs and
> >> nothing that seems like a fix jumped out at me. Any ideas?
> >>
> >
> > Good point.  I'd just move it to the top-level i.e. netx.manifest instead of
> > netx/netx.manifest.  The .desktop files are already there (which incidentally
> > should move to this system too).
> >
> 
> Done. I am attaching the updated patch. Ok to commit?
> 

Yes, looks fine.  Please commit.

> Cheers,
> Omair
> 

> diff -r 712dd97dc800 Makefile.am
> --- a/Makefile.am	Thu Jan 27 12:56:40 2011 -0500
> +++ b/Makefile.am	Thu Jan 27 13:10:29 2011 -0500
> @@ -54,13 +54,6 @@
>    SRC_DIR_LINK = $(REFLINK)
>  endif
>  
> -if HAS_ICEDTEA_REVISION
> -ICEDTEA_REV = +${ICEDTEA_REVISION}
> -endif
> -if HAS_PKGVERSION
> -ICEDTEA_PKG = $(EMPTY) (${PKGVERSION})
> -endif
> -
>  if ENABLE_DOCS
>  JAVADOC_OPTS=-use -keywords -encoding UTF-8 -splitIndex \
>   -bottom ' Submit a bug or feature'
> @@ -82,7 +75,7 @@
>  	-DEXPAND_CLASSPATH_WILDCARDS
>  LAUNCHER_LINK = -o $@ -pthread -Xlinker -O1 -Xlinker -z -Xlinker defs -L$(BOOT_DIR)/lib/$(INSTALL_ARCH_DIR) \
>  	-Wl,-soname=lib.so -Wl,-z -Wl,origin -Wl,--allow-shlib-undefined $(X11_CFLAGS) $(X11_LIBS) -ldl -lz
> -PLUGIN_VERSION = IcedTea-Web $(PACKAGE_VERSION)$(ICEDTEA_REV)$(ICEDTEA_PKG)
> +PLUGIN_VERSION = IcedTea-Web $(FULL_VERSION)
>  
>  EXTRA_DIST = $(top_srcdir)/netx $(top_srcdir)/plugin javaws.png javaws.desktop.in extra launcher \
>   itweb-settings.desktop.in
> @@ -298,10 +291,11 @@
>  	mkdir -p stamps
>  	touch $@
>  
> -stamps/netx-dist.stamp: stamps/netx.stamp
> +stamps/netx-dist.stamp: stamps/netx.stamp $(abs_top_builddir)/netx.manifest
>  	(cd $(NETX_DIR) ; \
>  	 mkdir -p lib ; \
> -	 $(BOOT_DIR)/bin/jar cf lib/classes.jar javax/jnlp net ; \
> +	 $(BOOT_DIR)/bin/jar cfm lib/classes.jar \
> +	  $(abs_top_builddir)/netx.manifest javax/jnlp net ; \
>  	 cp -pPR $(SRC_DIR_LINK) $(NETX_SRCDIR) src; \
>  	 find src -type f -exec chmod 640 '{}' ';' -o -type d -exec chmod 750 '{}' ';'; \
>  	 cd src ; \
> diff -r 712dd97dc800 acinclude.m4
> --- a/acinclude.m4	Thu Jan 27 12:56:40 2011 -0500
> +++ b/acinclude.m4	Thu Jan 27 13:10:29 2011 -0500
> @@ -667,3 +667,19 @@
>  fi
>  AC_PROVIDE([$0])dnl
>  ])
> +
> +AC_DEFUN_ONCE([IT_SET_VERSION],
> +[
> +  AC_REQUIRE([IT_OBTAIN_HG_REVISIONS])
> +  AC_REQUIRE([IT_GET_PKGVERSION])
> +  AC_MSG_CHECKING([what version string to use])
> +  if test "x${ICEDTEA_REVISION}" != xnone; then
> +    ICEDTEA_REV="+${ICEDTEA_REVISION}"
> +  fi
> +  if test "x${PKGVERSION}" != "xnone"; then
> +    ICEDTEA_PKG=" (${PKGVERSION})"
> +  fi
> +  FULL_VERSION="${PACKAGE_VERSION}${ICEDTEA_REV}${ICEDTEA_PKG}"
> +  AC_MSG_RESULT([${FULL_VERSION}])
> +  AC_SUBST([FULL_VERSION])
> +])
> diff -r 712dd97dc800 configure.ac
> --- a/configure.ac	Thu Jan 27 12:56:40 2011 -0500
> +++ b/configure.ac	Thu Jan 27 13:10:29 2011 -0500
> @@ -1,6 +1,6 @@
>  AC_INIT([icedtea-web],[1.1pre],[distro-pkg-dev at openjdk.java.net], [icedtea-web], [http://icedtea.classpath.org/wiki/IcedTea-Web])
>  AM_INIT_AUTOMAKE([1.9 tar-pax foreign])
> -AC_CONFIG_FILES([Makefile])
> +AC_CONFIG_FILES([Makefile netx.manifest])
>  
>  # Older automake doesn't generate these correctly
>  abs_top_builddir=`pwd -P`
> @@ -35,8 +35,7 @@
>  IT_FIND_JAVADOC
>  AC_CONFIG_FILES([javac], [chmod +x javac])
>  
> -IT_GET_PKGVERSION
> -IT_OBTAIN_HG_REVISIONS
> +IT_SET_VERSION
>  IT_CHECK_XULRUNNER_VERSION
>  
>  AC_CHECK_LIB(z, main,, [AC_MSG_ERROR("zlib not found - try installing zlib-devel")])
> diff -r 712dd97dc800 netx.manifest.in
> --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
> +++ b/netx.manifest.in	Thu Jan 27 13:10:29 2011 -0500
> @@ -0,0 +1,2 @@
> +Implementation-Title: @PACKAGE_NAME@
> +Implementation-Version: @FULL_VERSION@
> diff -r 712dd97dc800 netx/net/sourceforge/jnlp/runtime/Boot.java
> --- a/netx/net/sourceforge/jnlp/runtime/Boot.java	Thu Jan 27 12:56:40 2011 -0500
> +++ b/netx/net/sourceforge/jnlp/runtime/Boot.java	Thu Jan 27 13:10:29 2011 -0500
> @@ -58,11 +58,12 @@
>      // todo: decide whether a spawned netx (external launch)
>      // should inherit the same options as this instance (store argv?)
>  
> -    private static final String version = "0.5";
> +    private static final String name = Boot.class.getPackage().getImplementationTitle();
> +    private static final String version = Boot.class.getPackage().getImplementationVersion();
>  
>      /** the text to display before launching the about link */
>      private static final String aboutMessage = ""
> -            + "netx v" + version + " - (C)2001-2003 Jon A. Maxwell (jmaxwell at users.sourceforge.net)\n"
> +            + name + " " + version
>              + "\n"
>              + R("BLaunchAbout");
>  


-- 
Andrew :)

Free Java Software Engineer
Red Hat, Inc. (http://www.redhat.com)

Support Free Java!
Contribute to GNU Classpath and IcedTea
http://www.gnu.org/software/classpath
http://icedtea.classpath.org
PGP Key: 94EFD9D8 (http://subkeys.pgp.net)
Fingerprint = F8EF F1EA 401E 2E60 15FA  7927 142C 2591 94EF D9D8


From ahughes at redhat.com  Thu Jan 27 13:57:52 2011
From: ahughes at redhat.com (Dr Andrew John Hughes)
Date: Thu, 27 Jan 2011 21:57:52 +0000
Subject: [icedtea-web] RFC: pick up name and version from configure
In-Reply-To: <4D41E8A2.2010101@redhat.com>
References: <4D3F04A6.2030200@redhat.com>
	<20110126194409.GI21785@rivendell.middle-earth.co.uk>
	<4D40A55F.3090804@redhat.com>
	<20110127002712.GR21785@rivendell.middle-earth.co.uk>
	<4D41E8A2.2010101@redhat.com>
Message-ID: <20110127215752.GF24866@rivendell.middle-earth.co.uk>

On 16:50 Thu 27 Jan     , Omair Majid wrote:
> On 01/26/2011 07:27 PM, Dr Andrew John Hughes wrote:
> >> On 01/26/2011 02:44 PM, Dr Andrew John Hughes wrote:
> >>> I think it would be much cleaner to produce the manifest using
> >>> autoconf's existing support for this rather than hacking stuff
> >>> into the Makefile.  You need to AC_SUBST FULL_VERSION and then
> >>> add netx.manifest to AC_CONFIG_FILES.  autoconf will do the rest.
> >>> Make sure that the macros that set ICEDTEA_REVISION
> >>> (IT_OBTAIN_HG_REVISIONS) and PKGVERSION (IT_GET_PKGVERSION) are
> >>> run before FULL_VERSION is set.  Something like the attached
> >>> patch should do it.
> >>>
> > The .desktop files are already there (which incidentally should move
> > to this system too).
> >
> 
> The only substitution performed in the desktop-related *.in files
> relates to adding @bindir@/$executable_name in it. The automake manual
> discourages [1] [2] depending on the installation path in the configure
> stage. It instead recommends that snippets be used to generate the
> output file from the .in file during make. This is what we already do.
> Is there a good reason why we should move the desktop files to the
> AC_CONFIG_FILES system? I am sure I am missing something quite obvious here.
> 

Nah, I just thought it might be more maintainable with the sed statements.
But if automake recommends doing it as we do now, it's fine as is.

> Thanks,
> Omair
> 
> [1] 
> http://www.gnu.org/software/autoconf/manual/html_node/Installation-Directory-Variables.html#Installation-Directory-Variables
> [2] 
> http://www.gnu.org/software/autoconf/manual/html_node/Defining-Directories.html#Defining-Directories

-- 
Andrew :)

Free Java Software Engineer
Red Hat, Inc. (http://www.redhat.com)

Support Free Java!
Contribute to GNU Classpath and IcedTea
http://www.gnu.org/software/classpath
http://icedtea.classpath.org
PGP Key: 94EFD9D8 (http://subkeys.pgp.net)
Fingerprint = F8EF F1EA 401E 2E60 15FA  7927 142C 2591 94EF D9D8


From omajid at icedtea.classpath.org  Fri Jan 28 08:42:04 2011
From: omajid at icedtea.classpath.org (omajid at icedtea.classpath.org)
Date: Fri, 28 Jan 2011 16:42:04 +0000
Subject: /hg/icedtea-web: Use name and version as defined in configure.ac...
Message-ID: 

changeset 43c8a57314af in /hg/icedtea-web
details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=43c8a57314af
author: Omair Majid 
date: Fri Jan 28 11:41:23 2011 -0500

	Use name and version as defined in configure.ac instead of
	hardcoding it in Boot.java

	Use PACKAGE_NAME and FULL_VERSION as defined during build time
	rather than hardcoding them in net.sourceforge.jnlp.runtime.Boot.
	Generate a manifest file at build time, and define Implementation-
	Title and Implementation-Version to PACKAGE_NAME and FULL_VERSION.
	Use these values from the manifest file when displaying project name
	and version, rather than hardcoding "netx" and 0.5.

	2011-01-28 Omair Majid 

	 * Makefile.am: Move ICEDTEA_REV, ICEDTEA_PKG to acinclude.m4.
	Use FULL_VERSION. (stamps/netx-dist.stamp): Depend on
	netx.manifest. Use this file as the jar file manifest.
	    * acinclude.m4 (IT_SET_VERSION): New macro. Defines FULL_VERSION.
	    * configure.ac: Add netx.manifest to AC_CONFIG_FILES. Invoke
	IT_SET_VERSION.
	    * netx.manifest.in: New file.
	    * netx/net/sourceforge/jnlp/runtime/Boot.java: Set name and version
	using information from the manifest file.


diffstat:

6 files changed, 40 insertions(+), 15 deletions(-)
ChangeLog                                   |   13 +++++++++++++
Makefile.am                                 |   14 ++++----------
acinclude.m4                                |   16 ++++++++++++++++
configure.ac                                |    5 ++---
netx.manifest.in                            |    2 ++
netx/net/sourceforge/jnlp/runtime/Boot.java |    5 +++--

diffs (128 lines):

diff -r 712dd97dc800 -r 43c8a57314af ChangeLog
--- a/ChangeLog	Thu Jan 27 12:56:40 2011 -0500
+++ b/ChangeLog	Fri Jan 28 11:41:23 2011 -0500
@@ -1,3 +1,16 @@ 2011-01-27  Omair Majid  
+
+	* Makefile.am: Move ICEDTEA_REV, ICEDTEA_PKG to acinclude.m4. Use
+	FULL_VERSION.
+	(stamps/netx-dist.stamp): Depend on netx.manifest. Use this file as the
+	jar file manifest.
+	* acinclude.m4 (IT_SET_VERSION): New macro. Defines FULL_VERSION.
+	* configure.ac: Add netx.manifest to AC_CONFIG_FILES. Invoke
+	IT_SET_VERSION.
+	* netx.manifest.in: New file.
+	* netx/net/sourceforge/jnlp/runtime/Boot.java: Set name and version using
+	information from the manifest file.
+
 2011-01-27  Omair Majid  
 
 	* netx/net/sourceforge/jnlp/resources/Messages.properties: Add
diff -r 712dd97dc800 -r 43c8a57314af Makefile.am
--- a/Makefile.am	Thu Jan 27 12:56:40 2011 -0500
+++ b/Makefile.am	Fri Jan 28 11:41:23 2011 -0500
@@ -54,13 +54,6 @@ else
   SRC_DIR_LINK = $(REFLINK)
 endif
 
-if HAS_ICEDTEA_REVISION
-ICEDTEA_REV = +${ICEDTEA_REVISION}
-endif
-if HAS_PKGVERSION
-ICEDTEA_PKG = $(EMPTY) (${PKGVERSION})
-endif
-
 if ENABLE_DOCS
 JAVADOC_OPTS=-use -keywords -encoding UTF-8 -splitIndex \
  -bottom ' Submit a bug or feature'
@@ -82,7 +75,7 @@ LAUNCHER_FLAGS = -O2 -fno-strict-aliasin
 	-DEXPAND_CLASSPATH_WILDCARDS
 LAUNCHER_LINK = -o $@ -pthread -Xlinker -O1 -Xlinker -z -Xlinker defs -L$(BOOT_DIR)/lib/$(INSTALL_ARCH_DIR) \
 	-Wl,-soname=lib.so -Wl,-z -Wl,origin -Wl,--allow-shlib-undefined $(X11_CFLAGS) $(X11_LIBS) -ldl -lz
-PLUGIN_VERSION = IcedTea-Web $(PACKAGE_VERSION)$(ICEDTEA_REV)$(ICEDTEA_PKG)
+PLUGIN_VERSION = IcedTea-Web $(FULL_VERSION)
 
 EXTRA_DIST = $(top_srcdir)/netx $(top_srcdir)/plugin javaws.png javaws.desktop.in extra launcher \
  itweb-settings.desktop.in
@@ -298,10 +291,11 @@ stamps/netx.stamp: netx-source-files.txt
 	mkdir -p stamps
 	touch $@
 
-stamps/netx-dist.stamp: stamps/netx.stamp
+stamps/netx-dist.stamp: stamps/netx.stamp $(abs_top_builddir)/netx.manifest
 	(cd $(NETX_DIR) ; \
 	 mkdir -p lib ; \
-	 $(BOOT_DIR)/bin/jar cf lib/classes.jar javax/jnlp net ; \
+	 $(BOOT_DIR)/bin/jar cfm lib/classes.jar \
+	  $(abs_top_builddir)/netx.manifest javax/jnlp net ; \
 	 cp -pPR $(SRC_DIR_LINK) $(NETX_SRCDIR) src; \
 	 find src -type f -exec chmod 640 '{}' ';' -o -type d -exec chmod 750 '{}' ';'; \
 	 cd src ; \
diff -r 712dd97dc800 -r 43c8a57314af acinclude.m4
--- a/acinclude.m4	Thu Jan 27 12:56:40 2011 -0500
+++ b/acinclude.m4	Fri Jan 28 11:41:23 2011 -0500
@@ -667,3 +667,19 @@ fi
 fi
 AC_PROVIDE([$0])dnl
 ])
+
+AC_DEFUN_ONCE([IT_SET_VERSION],
+[
+  AC_REQUIRE([IT_OBTAIN_HG_REVISIONS])
+  AC_REQUIRE([IT_GET_PKGVERSION])
+  AC_MSG_CHECKING([what version string to use])
+  if test "x${ICEDTEA_REVISION}" != xnone; then
+    ICEDTEA_REV="+${ICEDTEA_REVISION}"
+  fi
+  if test "x${PKGVERSION}" != "xnone"; then
+    ICEDTEA_PKG=" (${PKGVERSION})"
+  fi
+  FULL_VERSION="${PACKAGE_VERSION}${ICEDTEA_REV}${ICEDTEA_PKG}"
+  AC_MSG_RESULT([${FULL_VERSION}])
+  AC_SUBST([FULL_VERSION])
+])
diff -r 712dd97dc800 -r 43c8a57314af configure.ac
--- a/configure.ac	Thu Jan 27 12:56:40 2011 -0500
+++ b/configure.ac	Fri Jan 28 11:41:23 2011 -0500
@@ -1,6 +1,6 @@ AC_INIT([icedtea-web],[1.1pre],[distro-p
 AC_INIT([icedtea-web],[1.1pre],[distro-pkg-dev at openjdk.java.net], [icedtea-web], [http://icedtea.classpath.org/wiki/IcedTea-Web])
 AM_INIT_AUTOMAKE([1.9 tar-pax foreign])
-AC_CONFIG_FILES([Makefile])
+AC_CONFIG_FILES([Makefile netx.manifest])
 
 # Older automake doesn't generate these correctly
 abs_top_builddir=`pwd -P`
@@ -35,8 +35,7 @@ IT_FIND_JAVADOC
 IT_FIND_JAVADOC
 AC_CONFIG_FILES([javac], [chmod +x javac])
 
-IT_GET_PKGVERSION
-IT_OBTAIN_HG_REVISIONS
+IT_SET_VERSION
 IT_CHECK_XULRUNNER_VERSION
 
 AC_CHECK_LIB(z, main,, [AC_MSG_ERROR("zlib not found - try installing zlib-devel")])
diff -r 712dd97dc800 -r 43c8a57314af netx.manifest.in
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/netx.manifest.in	Fri Jan 28 11:41:23 2011 -0500
@@ -0,0 +1,2 @@
+Implementation-Title: @PACKAGE_NAME@
+Implementation-Version: @FULL_VERSION@
diff -r 712dd97dc800 -r 43c8a57314af netx/net/sourceforge/jnlp/runtime/Boot.java
--- a/netx/net/sourceforge/jnlp/runtime/Boot.java	Thu Jan 27 12:56:40 2011 -0500
+++ b/netx/net/sourceforge/jnlp/runtime/Boot.java	Fri Jan 28 11:41:23 2011 -0500
@@ -58,11 +58,12 @@ public final class Boot implements Privi
     // todo: decide whether a spawned netx (external launch)
     // should inherit the same options as this instance (store argv?)
 
-    private static final String version = "0.5";
+    private static final String name = Boot.class.getPackage().getImplementationTitle();
+    private static final String version = Boot.class.getPackage().getImplementationVersion();
 
     /** the text to display before launching the about link */
     private static final String aboutMessage = ""
-            + "netx v" + version + " - (C)2001-2003 Jon A. Maxwell (jmaxwell at users.sourceforge.net)\n"
+            + name + " " + version
             + "\n"
             + R("BLaunchAbout");
 


From omajid at redhat.com  Fri Jan 28 08:44:24 2011
From: omajid at redhat.com (Omair Majid)
Date: Fri, 28 Jan 2011 11:44:24 -0500
Subject: [icedtea-web] RFC: pick up name and version from configure
In-Reply-To: <20110127215645.GE24866@rivendell.middle-earth.co.uk>
References: <4D3F04A6.2030200@redhat.com>
	<20110126194409.GI21785@rivendell.middle-earth.co.uk>
	<4D40A55F.3090804@redhat.com>
	<20110127002712.GR21785@rivendell.middle-earth.co.uk>
	<4D41B53A.9070205@redhat.com>
	<20110127215645.GE24866@rivendell.middle-earth.co.uk>
Message-ID: <4D42F268.7030703@redhat.com>

On 01/27/2011 04:56 PM, Dr Andrew John Hughes wrote:
> On 13:11 Thu 27 Jan     , Omair Majid wrote:
>> On 01/26/2011 07:27 PM, Dr Andrew John Hughes wrote:
>>> On 17:51 Wed 26 Jan     , Omair Majid wrote:
>>>> On 01/26/2011 02:44 PM, Dr Andrew John Hughes wrote:
>>>>> On 12:13 Tue 25 Jan     , Omair Majid wrote:
>>>>>> The attached patch gets rid of the hardcoded names and version numbers
>>>>>> in net. It makes netx pick up the right name and version form the
>>>>>> configure script.
>>>>>>
>>>>>
>>>>> I think it would be much cleaner to produce the manifest using autoconf's existing support for this
>>>>> rather than hacking stuff into the Makefile.  You need to AC_SUBST FULL_VERSION and then add
>>>>> netx.manifest to AC_CONFIG_FILES.  autoconf will do the rest.  Make sure that the macros that
>>>>> set ICEDTEA_REVISION (IT_OBTAIN_HG_REVISIONS) and PKGVERSION (IT_GET_PKGVERSION) are run before
>>>>> FULL_VERSION is set.  Something like the attached patch should do it.
>>>>>
>>>>> $ /home/andrew/projects/openjdk/icedtea-web/configure
>>>>> ...
>>>>> checking what version string to use... 1.1pre+r64da2a80df88
>>>>> ...
>>>>> $ cat netx/netx.manifest
>>>>> Implementation-Title: icedtea-web
>>>>> Implementation-Version: 1.1pre+r64da2a80df88
>>>>>
>>>>> $ /home/andrew/projects/openjdk/icedtea-web/configure --with-pkgversion=23
>>>>> ...
>>>>> checking what version string to use... 1.1pre+r64da2a80df88 (23)
>>>>> ...
>>>>> $ cat netx/netx.manifest
>>>>> Implementation-Title: icedtea-web
>>>>> Implementation-Version: 1.1pre+r64da2a80df88 (23)
>>>>>
>>>>
>>>> That's a great idea. Thanks for creating a patch for this too! I only
>>>> have one tiny concern: it creates a new dir named netx under the build
>>>> tree instead of using netx.build. I read through autoconf docs and
>>>> nothing that seems like a fix jumped out at me. Any ideas?
>>>>
>>>
>>> Good point.  I'd just move it to the top-level i.e. netx.manifest instead of
>>> netx/netx.manifest.  The .desktop files are already there (which incidentally
>>> should move to this system too).
>>>
>>
>> Done. I am attaching the updated patch. Ok to commit?
>>
>
> Yes, looks fine.  Please commit.
>

Thanks for the review. I have pushed this as changeset 43c8a57314af.

Cheers,
Omair


From dbhole at icedtea.classpath.org  Fri Jan 28 12:51:03 2011
From: dbhole at icedtea.classpath.org (dbhole at icedtea.classpath.org)
Date: Fri, 28 Jan 2011 20:51:03 +0000
Subject: /hg/release/icedtea-web-1.0: 2 new changesets
Message-ID: 

changeset ef24043734ee in /hg/release/icedtea-web-1.0
details: http://icedtea.classpath.org/hg/release/icedtea-web-1.0?cmd=changeset;node=ef24043734ee
author: Omair Majid 
date: Wed Dec 15 10:17:51 2010 -0500

	add symlinks under JDK_HOME/jre/bin and make javaws work without
	them too

	2010-12-15 Omair Majid 

	 * Makefile.am (install-exec-local): Install plugin.jar as
	data. If $(prefix)/jre/bin exists, then install symlinks to real
	javaws and itweb-settings binaries under it.
	($(NETX_DIR)/launcher/%.o): Set system property java.icedtea-web.bin
	to point to the installed location of the javaws binary.
	    * netx/net/sourceforge/jnlp/Launcher.java (launchExternal): Use the
	system property java.icedtea-web.bin to locate javaws binary.


changeset e84432bca9a3 in /hg/release/icedtea-web-1.0
details: http://icedtea.classpath.org/hg/release/icedtea-web-1.0?cmd=changeset;node=e84432bca9a3
author: Deepak Bhole 
date: Fri Jan 28 15:51:03 2011 -0500

	Fixed installation problems that occur when the prefix is a jre dir.


diffstat:

4 files changed, 82 insertions(+), 18 deletions(-)
ChangeLog                               |   28 ++++++++++++++
Makefile.am                             |   62 ++++++++++++++++++++++---------
configure.ac                            |    8 ++++
netx/net/sourceforge/jnlp/Launcher.java |    2 +

diffs (163 lines):

diff -r a1ed62aa5f98 -r e84432bca9a3 ChangeLog
--- a/ChangeLog	Mon Jan 24 10:13:01 2011 -0500
+++ b/ChangeLog	Fri Jan 28 15:51:03 2011 -0500
@@ -1,3 +1,31 @@ 2011-01-24  Omair Majid  
+
+	* Makefile.am
+	($(NETX_DIR)/launcher/%.o): Build javaws without the
+	"-J-Djava.icedtea-web.bin=..." arg. 
+	(install-exec-local): Use new JRE_DIR_PREFIX variables rather than
+	hardcoded '/jre' in pathname. Create relative links in jre/bin rather than
+	absolute ones.
+	(install-data-local): Use new JRE_DIR_PREFIX variables rather than
+	hardcoded '/jre' in pathname.
+	(uninstall-local): Same. Also, remove all parent dirs of $(htmldir) until 
+	a non-empty one is encountered.
+	* configure.ac: Set JRE_DIR_PREFIX to jre/ if prefix is a JDK dir and set 
+	it to empty if prefix apears to be a JRE dir.
+	* netx/net/sourceforge/jnlp/Launcher.java (launchExternal): Revert back to
+	using java.home when selecting javaws binary to execute for fork.
+
+2010-12-15  Omair Majid  
+
+	* Makefile.am
+	(install-exec-local): Install plugin.jar as data. If $(prefix)/jre/bin
+	exists, then install symlinks to real javaws and itweb-settings binaries
+	under it.
+	($(NETX_DIR)/launcher/%.o): Set system property java.icedtea-web.bin to
+	point to the installed location of the javaws binary.
+	* netx/net/sourceforge/jnlp/Launcher.java (launchExternal): Use the system
+	property java.icedtea-web.bin to locate javaws binary.
+
 2011-01-24  Omair Majid  
 
 	* NEWS: Change format again.
diff -r a1ed62aa5f98 -r e84432bca9a3 Makefile.am
--- a/Makefile.am	Mon Jan 24 10:13:01 2011 -0500
+++ b/Makefile.am	Fri Jan 28 15:51:03 2011 -0500
@@ -102,21 +102,37 @@ clean-local: clean-netx clean-plugin cle
  clean-bootstrap-directory clean-native-ecj clean-desktop-files clean-netx-docs clean-docs clean-plugin-docs
 
 install-exec-local:
-	${mkinstalldirs} $(DESTDIR)$(bindir) $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)
+	${mkinstalldirs} $(DESTDIR)$(prefix)/bin $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)
 if ENABLE_PLUGIN
-	${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/
+	${INSTALL_PROGRAM} $(PLUGIN_DIR)/IcedTeaPlugin.so $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/
 	${INSTALL_PROGRAM} $(PLUGIN_DIR)/launcher/pluginappletviewer $(DESTDIR)$(bindir)
-	${INSTALL_PROGRAM} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/plugin.jar
+	${INSTALL_DATA} $(abs_top_builddir)/liveconnect/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar
 endif
-	${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)/jre/lib/netx.jar
-	${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(bindir)
-	${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)/jre/lib
-	${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(bindir)
+	${INSTALL_DATA} $(NETX_DIR)/lib/classes.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar
+	${INSTALL_PROGRAM} $(NETX_DIR)/launcher/javaws $(DESTDIR)$(prefix)/bin
+	if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \
+	  if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \
+	    rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \
+	  fi ; \
+	  if [ ! -e $(prefix)/jre/bin/javaws ] ; then \
+	    ln -s ../../bin/javaws $(DESTDIR)$(prefix)/jre/bin ; \
+	  fi ; \
+	fi
+	${INSTALL_DATA} extra-lib/about.jar $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib
+	${INSTALL_PROGRAM} $(NETX_DIR)/launcher/controlpanel/itweb-settings $(DESTDIR)$(prefix)/bin
+	if [ -d $(DESTDIR)$(prefix)/jre/bin ] ; then \
+	  if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \
+	    rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \
+	  fi ; \
+	  if [ ! -e $(prefix)/jre/bin/itweb-settings ] ; then \
+	    ln -s ../../bin/itweb-settings $(DESTDIR)$(prefix)/jre/bin ; \
+	  fi ; \
+	fi
 
 install-data-local:
 	${mkinstalldirs} -d $(DESTDIR)$(prefix)/man/man1
 	${INSTALL_DATA} $(NETX_SRCDIR)/javaws.1 $(DESTDIR)$(prefix)/man/man1
-	${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)/jre/lib
+	${INSTALL_DATA} $(NETX_RESOURCE_DIR)/about.jnlp $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib
 if ENABLE_DOCS
 	${mkinstalldirs} $(DESTDIR)$(htmldir)
 	(cd ${abs_top_builddir}/docs/netx; \
@@ -134,16 +150,25 @@ endif
 endif
 
 uninstall-local:
-	rm -f $(DESTDIR)$(prefix)/jre/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so
-	rm -f $(DESTDIR)$(prefix)/jre/lib/plugin.jar
-	rm -f $(DESTDIR)$(prefix)/jre/lib/netx.jar
-	rm -f $(DESTDIR)$(prefix)/jre/lib/about.jnlp
-	rm -f $(DESTDIR)$(prefix)/jre/lib/about.jar
+	rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/$(INSTALL_ARCH_DIR)/IcedTeaPlugin.so
+	rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/plugin.jar
+	rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/netx.jar
+	rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jnlp
+	rm -f $(DESTDIR)$(prefix)$(JRE_DIR_PREFIX)/lib/about.jar
 	rm -f $(DESTDIR)$(prefix)/man/man1/javaws.1
 	rm -f $(DESTDIR)$(bindir)/pluginappletviewer
-	rm -f $(DESTDIR)$(bindir)/javaws
-	rm -f $(DESTDIR)$(bindir)/itweb-settings
-	rm -rf $(DESTDIR)$(htmldir)
+	rm -f $(DESTDIR)$(prefix)/bin/javaws
+	if [ -L $(DESTDIR)$(prefix)/jre/bin/javaws ] ; then \
+	  rm -f $(DESTDIR)$(prefix)/jre/bin/javaws ; \
+	fi
+	rm -f $(DESTDIR)$(prefix)/bin/itweb-settings
+	if [ -L $(DESTDIR)$(prefix)/jre/bin/itweb-settings ] ; then \
+	  rm -f $(DESTDIR)$(prefix)/jre/bin/itweb-settings ; \
+	fi
+	rm -rf $(DESTDIR)$(htmldir)/*
+	if [ -d $(DESTDIR)$(htmldir) ] ; then \
+	  rmdir -p --ignore-fail-on-non-empty $(DESTDIR)$(htmldir) ; \
+	fi
 
 # Plugin
 
@@ -325,8 +350,9 @@ extra-lib/about.jar: stamps/extra-class-
 
 $(NETX_DIR)/launcher/%.o: $(LAUNCHER_SRCDIR)/%.c
 	mkdir -p $(NETX_DIR)/launcher && \
-	$(CC) $(LAUNCHER_FLAGS) -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot",  }' -DPROGNAME='"javaws"' \
-	-c -o $@ $<
+	$(CC) $(LAUNCHER_FLAGS) \
+	  -DJAVA_ARGS='{ "-J-ms8m", "net.sourceforge.jnlp.runtime.Boot",  }' \
+	  -DPROGNAME='"javaws"' -c -o $@ $<
 
 $(NETX_DIR)/launcher/controlpanel/%.o: $(LAUNCHER_SRCDIR)/%.c
 	mkdir -p $(NETX_DIR)/launcher/controlpanel && \
diff -r a1ed62aa5f98 -r e84432bca9a3 configure.ac
--- a/configure.ac	Mon Jan 24 10:13:01 2011 -0500
+++ b/configure.ac	Fri Jan 28 15:51:03 2011 -0500
@@ -78,4 +78,12 @@ IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAG
 IT_CHECK_FOR_CLASS(SUN_APPLET_APPLETIMAGEREF, [sun.applet.AppletImageRef])
 IT_CHECK_FOR_APPLETVIEWERPANEL_HOLE
 
+# Set JRE prefix based on whether to-level prefix is a JDK dir or a JRE dir
+if test -d ${prefix}/jre ; then 
+    JRE_DIR_PREFIX="/jre" ; 
+else
+    JRE_DIR_PREFIX="" ;     
+fi ;
+AC_SUBST([JRE_DIR_PREFIX])
+
 AC_OUTPUT
diff -r a1ed62aa5f98 -r e84432bca9a3 netx/net/sourceforge/jnlp/Launcher.java
--- a/netx/net/sourceforge/jnlp/Launcher.java	Mon Jan 24 10:13:01 2011 -0500
+++ b/netx/net/sourceforge/jnlp/Launcher.java	Fri Jan 28 15:51:03 2011 -0500
@@ -329,11 +329,13 @@ public class Launcher {
 
             List commands = new LinkedList();
 
+            // this property is set by the javaws launcher to point to the javaws binary
             String pathToWebstartBinary = System.getProperty("java.home") +
                                       File.separatorChar +
                                       "bin" +
                                       File.separatorChar +
                                       "javaws";
+
             commands.add(pathToWebstartBinary);
             // use -Jargument format to pass arguments to the JVM through the launcher
             for (String arg : vmArgs) {


From denisl at openscg.com  Sat Jan 29 12:36:38 2011
From: denisl at openscg.com (Lussier, Denis)
Date: Sat, 29 Jan 2011 12:36:38 -0800
Subject: /hg/icedtea6: 3 new changesets
In-Reply-To: 
References: 
Message-ID: 

Hi Guys,

I'm trying to build OpenSCG's one-click Linux 32 and 64-bit installers for
OpenJDK6 Build 21 this weekend.  I wanted to include Visual VM in this
release and I figured this would be a good time to finally switch over to
using icedtea6 as my base.    When I build the icedtea6-1.9.4 source tarball
it seems to use openjdk build 20.  What do y'all recommend?

--Denis Lussier
  http://openscg.org



On Mon, Jan 24, 2011 at 1:02 PM,  wrote:

> changeset 6818a5e1f330 in /hg/icedtea6
> details:
> http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=6818a5e1f330
> author: Andrew John Hughes 
> date: Mon Jan 24 20:55:14 2011 +0000
>
>        Update NEWS with b21 updates.
>
>        2011-01-22 Andrew John Hughes 
>
>         * NEWS: Update 1.10 with b21 changes. Remove changes
>        in b21 from list of backports.
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110129/5681044d/attachment.html 

From andrew at icedtea.classpath.org  Sat Jan 29 16:45:35 2011
From: andrew at icedtea.classpath.org (andrew at icedtea.classpath.org)
Date: Sun, 30 Jan 2011 00:45:35 +0000
Subject: /hg/icedtea6: Provide support for building with HotSpot 20.
Message-ID: 

changeset cd6310f10fab in /hg/icedtea6
details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=cd6310f10fab
author: Andrew John Hughes 
date: Sun Jan 30 00:45:18 2011 +0000

	Provide support for building with HotSpot 20.

	2011-01-29 Andrew John Hughes 

	 * patches/gcc-suffix.patch,
		* patches/ia64-fix.patch: Split into original and hs20
	versions.
		* patches/icedtea-no-precompiled.patch: Apply to original
	only.
		* patches/icedtea-sparc-buildfixes.patch,
		* patches/icedtea-text-relocations.patch,
		* patches/icedtea-too-many-args.patch,
		* patches/params-cast-size_t.patch: Split into original and
	hs20 versions.
		* INSTALL: Document new status (original as default,
	hs20 as alternative).
		* Makefile.am: (ICEDTEA_PATCHES): Updated with changes listed.
	(replace-hotspot): Use ${HSBUILD} instead of hardcoded hs19.
		* NEWS: List availability of hs20.
		* acinclude.m4: (AC_CHECK_WITH_HOTSPOT_BUILD): Provide hs20 as
	alternate build.
		* hotspot.map: Add hs20.
		* patches/arm.patch: Split bytecodes_zero.hpp changes into original
	and hs20 versions.
		* patches/hotspot/hs20/arm.patch, hs20 version of
	bytecodes_zero.hpp changes.
		* patches/hotspot/hs20/gcc-suffix.patch,
		* patches/hotspot/hs20/ia64-fix.patch,
		* patches/hotspot/hs20/params-cast-size_t.patch,
		* patches/hotspot/hs20/sparc-buildfixes.patch: hs20 version of
	patches.
		* patches/hotspot/hs20/systemtap.patch: hs20 version of
	dtrace.hpp changes.
		* patches/hotspot/hs20/text-relocations.patch: hs20 versions
	of patch.
		* patches/hotspot/original/arm.patch: original version of
	bytecodes_zero.hpp changes.
		* patches/hotspot/original/gcc-suffix.patch,
		* patches/hotspot/original/ia64-fix.patch: original versions
	of patches moved from patches directory.
		* patches/hotspot/original/no-precompiled-headers.patch: Only
	for original; USE_PRECOMPILED_HEADER=0 provides the same in
	hs20.
		* patches/hotspot/original/params-cast-size_t.patch,
		* patches/hotspot/original/sparc-buildfixes.patch: original
	versions of patches moved from patches directory.
		* patches/hotspot/original/systemtap.patch: original version
	of dtrace.hpp changes.
		* patches/hotspot/original/text-relocations.patch,
		* patches/hotspot/original/too-many-args.patch: original
	versions of patches moved from patches directory.
		* patches/systemtap.patch: Split dtrace.hpp changes into
	original and hs20 versions.


diffstat:

31 files changed, 1328 insertions(+), 704 deletions(-)
ChangeLog                                             |   54 +++
INSTALL                                               |   16 
Makefile.am                                           |   24 -
NEWS                                                  |    1 
acinclude.m4                                          |    2 
hotspot.map                                           |    1 
patches/arm.patch                                     |   55 ---
patches/gcc-suffix.patch                              |   31 -
patches/hotspot/hs20/arm.patch                        |   57 +++
patches/hotspot/hs20/gcc-suffix.patch                 |   31 +
patches/hotspot/hs20/ia64-fix.patch                   |   15 
patches/hotspot/hs20/params-cast-size_t.patch         |  270 +++++++++++++++
patches/hotspot/hs20/sparc-buildfixes.patch           |   26 +
patches/hotspot/hs20/systemtap.patch                  |  100 +++++
patches/hotspot/hs20/text-relocations.patch           |   63 +++
patches/hotspot/original/arm.patch                    |   55 +++
patches/hotspot/original/gcc-suffix.patch             |   31 +
patches/hotspot/original/ia64-fix.patch               |   30 +
patches/hotspot/original/no-precompiled-headers.patch |   35 ++
patches/hotspot/original/params-cast-size_t.patch     |  295 +++++++++++++++++
patches/hotspot/original/sparc-buildfixes.patch       |   35 ++
patches/hotspot/original/systemtap.patch              |   98 +++++
patches/hotspot/original/text-relocations.patch       |   61 +++
patches/hotspot/original/too-many-args.patch          |   46 ++
patches/ia64-fix.patch                                |   30 -
patches/icedtea-no-precompiled.patch                  |   35 --
patches/icedtea-sparc-buildfixes.patch                |   35 --
patches/icedtea-text-relocations.patch                |   61 ---
patches/icedtea-too-many-args.patch                   |   46 --
patches/params-cast-size_t.patch                      |  295 -----------------
patches/systemtap.patch                               |   98 -----

diffs (truncated from 2278 to 500 lines):

diff -r c78edcdba40f -r cd6310f10fab ChangeLog
--- a/ChangeLog	Mon Jan 24 16:30:51 2011 -0500
+++ b/ChangeLog	Sun Jan 30 00:45:18 2011 +0000
@@ -1,3 +1,57 @@ 2011-01-24  Omair Majid  
+
+	* patches/gcc-suffix.patch,
+	* patches/ia64-fix.patch:
+	Split into original and hs20 versions.
+	* patches/icedtea-no-precompiled.patch:
+	Apply to original only.
+	* patches/icedtea-sparc-buildfixes.patch,
+	* patches/icedtea-text-relocations.patch,
+	* patches/icedtea-too-many-args.patch,
+	* patches/params-cast-size_t.patch:
+	Split into original and hs20 versions.
+	* INSTALL:
+	Document new status (original as default,
+	hs20 as alternative).
+	* Makefile.am:
+	(ICEDTEA_PATCHES): Updated with changes listed.
+	(replace-hotspot): Use ${HSBUILD} instead of hardcoded hs19.
+	* NEWS: List availability of hs20.
+	* acinclude.m4:
+	(AC_CHECK_WITH_HOTSPOT_BUILD): Provide hs20 as alternate build.
+	* hotspot.map: Add hs20.
+	* patches/arm.patch: Split bytecodes_zero.hpp changes into original
+	and hs20 versions.
+	* patches/hotspot/hs20/arm.patch,
+	hs20 version of bytecodes_zero.hpp changes.
+	* patches/hotspot/hs20/gcc-suffix.patch,
+	* patches/hotspot/hs20/ia64-fix.patch,
+	* patches/hotspot/hs20/params-cast-size_t.patch,
+	* patches/hotspot/hs20/sparc-buildfixes.patch:
+	hs20 version of patches.
+	* patches/hotspot/hs20/systemtap.patch:
+	hs20 version of dtrace.hpp changes.
+	* patches/hotspot/hs20/text-relocations.patch:
+	hs20 versions of patch.
+	* patches/hotspot/original/arm.patch:
+	original version of bytecodes_zero.hpp changes.
+	* patches/hotspot/original/gcc-suffix.patch,
+	* patches/hotspot/original/ia64-fix.patch:
+	original versions of patches moved from patches directory.
+	* patches/hotspot/original/no-precompiled-headers.patch:
+	Only for original; USE_PRECOMPILED_HEADER=0 provides the
+	same in hs20.
+	* patches/hotspot/original/params-cast-size_t.patch,
+	* patches/hotspot/original/sparc-buildfixes.patch:
+	original versions of patches moved from patches directory.
+	* patches/hotspot/original/systemtap.patch:
+	original version of dtrace.hpp changes.
+	* patches/hotspot/original/text-relocations.patch,
+	* patches/hotspot/original/too-many-args.patch:
+	original versions of patches moved from patches directory.
+	* patches/systemtap.patch:
+	Split dtrace.hpp changes into original and hs20 versions.
+
 2011-01-24  Omair Majid  
 
 	* NEWS: Update with the 3 backports
diff -r c78edcdba40f -r cd6310f10fab INSTALL
--- a/INSTALL	Mon Jan 24 16:30:51 2011 -0500
+++ b/INSTALL	Sun Jan 30 00:45:18 2011 +0000
@@ -165,7 +165,7 @@ These are documented fully in the releva
 * --enable-cacao: Replace HotSpot with the CACAO VM.
 * --enable-shark: Build the Shark LLVM-based JIT.
 * --enable-zero: Build the zero assembler port on x86/x86_64/sparc platforms.
-* --with-hotspot-build: The HotSpot to use, defaulting to 'hs19'.
+* --with-hotspot-build: The HotSpot to use, defaulting to 'original'.
 * --with-rhino: Include Javascript support using Rhino.
 * --with-additional-vms=vm-list: Additional VMs to build using the system described
   below.
@@ -301,16 +301,16 @@ download stage and just verifies that th
 download stage and just verifies that the zip's MD5 sum matches that
 of the requested build.
 
-At present, IcedTea6 supports the 'original' HotSpot 17 provided as
-part of the upstream tarball and HotSpot 19 ('hs19') from the stable
-hs19 tree at http://hg.openjdk.java.net/hsx/hsx19/master.  The default
-is 'hs19'; passing --with-hotspot-build=original to configure will
-revert to the version of hs17 provided in b20.  Note that the norm. is
+At present, IcedTea6 supports the 'original' HotSpot 19 provided as
+part of the upstream tarball and HotSpot 20 ('hs20') from the stable
+hs20 tree at http://hg.openjdk.java.net/hsx/hsx20/baseline.  The default
+is 'original'; passing --with-hotspot-build=hs20 to configure will
+use the version of hs20 specified in hotspot.map.  Note that the norm. is
 for up to one alternate (non-default) build to be supported and just
 passing --with-hotspot-build (equivalent to --with-hotspot-build=yes)
-will always provide the alternate build (currently hs19).  Conversely,
+will always provide the alternate build (currently hs20).  Conversely,
 passing --with-hotspot-build=no provides the original build (currently
-hs17).
+hs19).
 
 Javascript Support
 ==================
diff -r c78edcdba40f -r cd6310f10fab Makefile.am
--- a/Makefile.am	Mon Jan 24 16:30:51 2011 -0500
+++ b/Makefile.am	Sun Jan 30 00:45:18 2011 +0000
@@ -183,7 +183,7 @@ ICEDTEA_PATCHES = \
 	patches/icedtea-lucene-crash.patch \
 	patches/icedtea-version.patch \
 	patches/icedtea-version-hotspot.patch \
-	patches/icedtea-text-relocations.patch \
+	patches/hotspot/$(HSBUILD)/text-relocations.patch \
 	patches/icedtea-ssl.patch \
 	patches/icedtea-rmi_amd64.patch \
 	patches/icedtea-tools.patch \
@@ -191,7 +191,7 @@ ICEDTEA_PATCHES = \
 	patches/icedtea-headers.patch \
 	patches/icedtea-headers-hotspot.patch \
 	patches/icedtea-gcc-suffix.patch \
-	patches/gcc-suffix.patch \
+	patches/hotspot/$(HSBUILD)/gcc-suffix.patch \
 	patches/icedtea-bytebuffer-compact.patch \
 	patches/memory-limits.patch \
 	patches/icedtea-sunsrc.patch \
@@ -210,7 +210,7 @@ ICEDTEA_PATCHES = \
 	patches/icedtea-alt-jar.patch \
 	patches/icedtea-jdk-use-ssize_t.patch \
 	patches/icedtea-use-idx_t.patch \
-	patches/params-cast-size_t.patch \
+	patches/hotspot/$(HSBUILD)/params-cast-size_t.patch \
 	patches/icedtea-clean-crypto.patch \
 	patches/icedtea-arch.patch \
 	patches/icedtea-lc_ctype.patch \
@@ -221,7 +221,7 @@ ICEDTEA_PATCHES = \
 	patches/icedtea-testenv.patch \
 	patches/icedtea-samejvm-safe.patch \
 	patches/icedtea-pr261.patch \
-	patches/icedtea-sparc-buildfixes.patch \
+	patches/hotspot/$(HSBUILD)/sparc-buildfixes.patch \
 	patches/icedtea-sparc64-linux.patch \
 	patches/icedtea-sparc-ptracefix.patch \
 	patches/icedtea-sparc-trapsfix.patch \
@@ -237,7 +237,6 @@ ICEDTEA_PATCHES = \
 	patches/icedtea-disable-cc-incompatible-sanity-checks.patch \
 	patches/icedtea-explicit-target-arch.patch \
 	patches/icedtea-gcc-stack-markings.patch \
-	patches/icedtea-no-precompiled.patch \
 	patches/icedtea-parisc.patch \
 	patches/icedtea-sh4-support.patch \
 	patches/icedtea-policy-evaluation.patch \
@@ -246,6 +245,7 @@ ICEDTEA_PATCHES = \
 	patches/applet_hole.patch \
 	patches/icedtea-jtreg-httpTest.patch \
 	patches/arm.patch \
+	patches/hotspot/$(HSBUILD)/arm.patch \
 	patches/debug-dir.patch \
 	patches/no-sync.patch \
 	patches/icedtea-override-redirect-metacity.patch \
@@ -253,7 +253,6 @@ ICEDTEA_PATCHES = \
 	patches/fonts-rhel.patch \
 	patches/fonts-gentoo.patch \
 	patches/ipv4-mapped-ipv6-addresses.patch \
-	patches/icedtea-too-many-args.patch \
 	patches/icedtea-jtreg-OpenGLContextInit.patch \
 	patches/openjdk/6510892-httpserver_test.patch \
 	patches/openjdk/6638712-wildcard_types.patch \
@@ -261,7 +260,6 @@ ICEDTEA_PATCHES = \
 	patches/numa_on_early_glibc.patch \
 	patches/icedtea-jtreg-international-fonts.patch \
 	patches/openjdk/6967436-6976265-6967434-pisces.patch \
-	patches/openjdk/6997495-test_correction_6857159.patch \
 	patches/f14-fonts.patch \
 	patches/jtreg-WindowWithWarningTest.patch \
 	patches/jtreg-T6638712-fix.patch \
@@ -272,12 +270,19 @@ ICEDTEA_PATCHES = \
 	patches/openjdk/6800846-printing-quality.patch \
 	patches/rh661505-jpeg.patch \
 	patches/6703377-freetypescaler.patch \
-	patches/ia64-fix.patch \
+	patches/hotspot/$(HSBUILD)/ia64-fix.patch \
 	patches/openjdk/6642612-filechooser_button_sizes.patch \
 	patches/jtreg-international-fonts-styles.patch \
 	patches/openjdk/6736649-text_bearings.patch \
 	patches/openjdk/6797139-jbutton_truncation.patch \
 	patches/openjdk/6883341-text_bearing_exception.patch
+
+if !WITH_ALT_HSBUILD
+ICEDTEA_PATCHES += \
+	patches/hotspot/$(HSBUILD)/no-precompiled-headers.patch \
+	patches/hotspot/$(HSBUILD)/too-many-args.patch \
+	patches/openjdk/6997495-test_correction_6857159.patch
+endif
 
 if WITH_RHINO
 ICEDTEA_PATCHES += \
@@ -319,6 +324,7 @@ endif
 
 if ENABLE_SYSTEMTAP
 ICEDTEA_PATCHES += patches/systemtap.patch \
+	patches/hotspot/$(HSBUILD)/systemtap.patch \
 	patches/systemtap-gcc-4.5.patch \
 	patches/systemtap-alloc-size-workaround.patch
 endif
@@ -845,7 +851,7 @@ if WITH_ALT_HSBUILD
 	  then \
 	    $(TAR) xf $(HOTSPOT_SRC_ZIP) ; \
 	    dir=$$($(AWK) 'version==$$1 {print gensub(/.*\/([^/]*)$$/,"\\1","g",$$2)}' \
-	      version=hs19 $(abs_top_srcdir)/hotspot.map) ; \
+	      version=$(HSBUILD) $(abs_top_srcdir)/hotspot.map) ; \
 	    chmod -R ug+w $$dir-* ; \
 	    mv $$dir-$$($(AWK) 'version==$$1 {print $$3}' version=$(HSBUILD) \
 	      $(abs_top_srcdir)/hotspot.map) openjdk/hotspot ; \
diff -r c78edcdba40f -r cd6310f10fab NEWS
--- a/NEWS	Mon Jan 24 16:30:51 2011 -0500
+++ b/NEWS	Sun Jan 30 00:45:18 2011 +0000
@@ -14,6 +14,7 @@ New in release 1.10 (2011-XX-XX):
   release cycle.
 * Shark provided upstream rather than as part of IcedTea.
 * The option --with-openjdk becomes --with-jdk-home and --disable-bootstrap
+* Support for building with HotSpot 20 from its stable tree
 * Import of OpenJDK6 b21 including upgrade to HotSpot 19
   - S6961870: More rebranding fixes for templates/gpl-*-header files
   - S6976186: Shark build system changes
diff -r c78edcdba40f -r cd6310f10fab acinclude.m4
--- a/acinclude.m4	Mon Jan 24 16:30:51 2011 -0500
+++ b/acinclude.m4	Sun Jan 30 00:45:18 2011 +0000
@@ -917,7 +917,7 @@ AC_DEFUN([AC_CHECK_WITH_HOTSPOT_BUILD],
 AC_DEFUN([AC_CHECK_WITH_HOTSPOT_BUILD],
 [
   ORIGINAL_BUILD="original"
-  ALTERNATE_BUILD="original"
+  ALTERNATE_BUILD="hs20"
   DEFAULT_BUILD=${ORIGINAL_BUILD}
   AC_MSG_CHECKING([which HotSpot build to use])
   AC_ARG_WITH([hotspot-build],
diff -r c78edcdba40f -r cd6310f10fab hotspot.map
--- a/hotspot.map	Mon Jan 24 16:30:51 2011 -0500
+++ b/hotspot.map	Sun Jan 30 00:45:18 2011 +0000
@@ -1,1 +1,2 @@
 # version url changeset md5sum
+hs20 http://hg.openjdk.java.net/hsx/hsx20/baseline 6aa467001334 236fa9a7fdb01339184378bb35e42e34
diff -r c78edcdba40f -r cd6310f10fab patches/arm.patch
--- a/patches/arm.patch	Mon Jan 24 16:30:51 2011 -0500
+++ b/patches/arm.patch	Sun Jan 30 00:45:18 2011 +0000
@@ -112,61 +112,6 @@ diff -Nru openjdk.orig/hotspot/src/cpu/z
 +
 +#endif // HOTSPOT_ASM
  }
-diff -Nru openjdk.orig/hotspot/src/cpu/zero/vm/bytecodes_zero.hpp openjdk/hotspot/src/cpu/zero/vm/bytecodes_zero.hpp
---- openjdk.orig/hotspot/src/cpu/zero/vm/bytecodes_zero.hpp	2010-05-28 11:10:30.000000000 +0100
-+++ openjdk/hotspot/src/cpu/zero/vm/bytecodes_zero.hpp	2010-06-17 17:28:49.000000000 +0100
-@@ -1,6 +1,7 @@
- /*
-  * Copyright (c) 1997, 2007, Oracle and/or its affiliates. All rights reserved.
-  * Copyright 2009 Red Hat, Inc.
-+ * Copyright 2009 Edward Nevill
-  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-  *
-  * This code is free software; you can redistribute it and/or modify it
-@@ -23,4 +24,42 @@
-  *
-  */
- 
--// This file is intentionally empty
-+#ifdef HOTSPOT_ASM
-+#define _iaccess_0      ((Bytecodes::Code)0xdb)
-+#define _iaccess_1      ((Bytecodes::Code)0xdc)
-+#define _iaccess_2      ((Bytecodes::Code)0xdd)
-+#define _iaccess_3      ((Bytecodes::Code)0xde)
-+
-+#define _invokeresolved         ((Bytecodes::Code)0xdf)
-+#define _invokespecialresolved  ((Bytecodes::Code)0xe0)
-+#define _invokestaticresolved   ((Bytecodes::Code)0xe1)
-+
-+#define _iload_iload    ((Bytecodes::Code)0xe3)
-+#define _iload_iload_N  ((Bytecodes::Code)0xe4)
-+
-+#define _dmac           ((Bytecodes::Code)0xe6)
-+
-+        _iload_0_iconst_N       ,       // 231
-+        _iload_1_iconst_N       ,       // 232
-+        _iload_2_iconst_N       ,       // 233
-+        _iload_3_iconst_N       ,       // 234
-+        _iload_iconst_N         ,       // 235
-+        _iadd_istore_N          ,       // 236
-+        _isub_istore_N          ,       // 237
-+        _iand_istore_N          ,       // 238
-+        _ior_istore_N           ,       // 239
-+        _ixor_istore_N          ,       // 240
-+        _iadd_u4store           ,       // 241
-+        _isub_u4store           ,       // 242
-+        _iand_u4store           ,       // 243
-+        _ior_u4store            ,       // 244
-+        _ixor_u4store           ,       // 245
-+        _iload_0_iload          ,       // 246
-+        _iload_1_iload          ,       // 247
-+        _iload_2_iload          ,       // 248
-+        _iload_3_iload          ,       // 249
-+        _iload_0_iload_N        ,       // 250
-+        _iload_1_iload_N        ,       // 251
-+        _iload_2_iload_N        ,       // 252
-+        _iload_3_iload_N        ,       // 253
-+#endif // HOTSPOT_ASM
 diff -Nru openjdk.orig/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp openjdk/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp
 --- openjdk.orig/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp	2010-06-16 14:11:07.000000000 +0100
 +++ openjdk/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp	2010-06-17 17:30:02.000000000 +0100
diff -r c78edcdba40f -r cd6310f10fab patches/gcc-suffix.patch
--- a/patches/gcc-suffix.patch	Mon Jan 24 16:30:51 2011 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,31 +0,0 @@
-diff -Nru openjdk.orig/hotspot/agent/src/os/linux/Makefile openjdk/hotspot/agent/src/os/linux/Makefile
---- openjdk.orig/hotspot/agent/src/os/linux/Makefile	2010-09-01 01:23:45.000000000 +0100
-+++ openjdk/hotspot/agent/src/os/linux/Makefile	2010-09-19 14:09:17.907131214 +0100
-@@ -23,7 +23,7 @@
- #
- 
- ARCH := $(shell if ([ `uname -m` = "ia64" ])  ; then echo ia64 ; elif ([ `uname -m` = "x86_64" ]) ; then echo amd64; elif ([ `uname -m` = "sparc64" ]) ; then echo sparc; else echo i386 ; fi )
--GCC      = gcc
-+GCC      = gcc$(GCC_SUFFIX)
- 
- JAVAH    = ${JAVA_HOME}/bin/javah
- 
-diff -Nru openjdk.orig/hotspot/make/linux/makefiles/gcc.make openjdk/hotspot/make/linux/makefiles/gcc.make
---- openjdk.orig/hotspot/make/linux/makefiles/gcc.make	2010-09-19 14:07:15.000000000 +0100
-+++ openjdk/hotspot/make/linux/makefiles/gcc.make	2010-09-19 14:09:58.015272246 +0100
-@@ -26,11 +26,11 @@
- # CC, CPP & AS
- 
- ifdef ALT_COMPILER_PATH
--CPP = $(ALT_COMPILER_PATH)/g++
--CC  = $(ALT_COMPILER_PATH)/gcc
-+CPP = $(ALT_COMPILER_PATH)/g++$(GCC_SUFFIX)
-+CC  = $(ALT_COMPILER_PATH)/gcc$(GCC_SUFFIX)
- else
--CPP = g++
--CC  = gcc
-+CPP = g++$(GCC_SUFFIX)
-+CC  = gcc$(GCC_SUFFIX)
- endif
- 
- AS  = $(CC) -c
diff -r c78edcdba40f -r cd6310f10fab patches/hotspot/hs20/arm.patch
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/hotspot/hs20/arm.patch	Sun Jan 30 00:45:18 2011 +0000
@@ -0,0 +1,57 @@
+diff -Nru openjdk.orig/hotspot/src/cpu/zero/vm/bytecodes_zero.hpp openjdk/hotspot/src/cpu/zero/vm/bytecodes_zero.hpp
+--- openjdk.orig/hotspot/src/cpu/zero/vm/bytecodes_zero.hpp	2011-01-25 22:57:24.000000000 +0000
++++ openjdk/hotspot/src/cpu/zero/vm/bytecodes_zero.hpp	2011-01-28 01:46:18.769782690 +0000
+@@ -1,6 +1,7 @@
+ /*
+  * Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved.
+  * Copyright 2009 Red Hat, Inc.
++ * Copyright 2009 Edward Nevill
+  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+  *
+  * This code is free software; you can redistribute it and/or modify it
+@@ -26,6 +27,44 @@
+ #ifndef CPU_ZERO_VM_BYTECODES_ZERO_HPP
+ #define CPU_ZERO_VM_BYTECODES_ZERO_HPP
+ 
+-// This file is intentionally empty
++#ifdef HOTSPOT_ASM
++#define _iaccess_0      ((Bytecodes::Code)0xdb)
++#define _iaccess_1      ((Bytecodes::Code)0xdc)
++#define _iaccess_2      ((Bytecodes::Code)0xdd)
++#define _iaccess_3      ((Bytecodes::Code)0xde)
++
++#define _invokeresolved         ((Bytecodes::Code)0xdf)
++#define _invokespecialresolved  ((Bytecodes::Code)0xe0)
++#define _invokestaticresolved   ((Bytecodes::Code)0xe1)
++
++#define _iload_iload    ((Bytecodes::Code)0xe3)
++#define _iload_iload_N  ((Bytecodes::Code)0xe4)
++
++#define _dmac           ((Bytecodes::Code)0xe6)
++
++        _iload_0_iconst_N       ,       // 231
++        _iload_1_iconst_N       ,       // 232
++        _iload_2_iconst_N       ,       // 233
++        _iload_3_iconst_N       ,       // 234
++        _iload_iconst_N         ,       // 235
++        _iadd_istore_N          ,       // 236
++        _isub_istore_N          ,       // 237
++        _iand_istore_N          ,       // 238
++        _ior_istore_N           ,       // 239
++        _ixor_istore_N          ,       // 240
++        _iadd_u4store           ,       // 241
++        _isub_u4store           ,       // 242
++        _iand_u4store           ,       // 243
++        _ior_u4store            ,       // 244
++        _ixor_u4store           ,       // 245
++        _iload_0_iload          ,       // 246
++        _iload_1_iload          ,       // 247
++        _iload_2_iload          ,       // 248
++        _iload_3_iload          ,       // 249
++        _iload_0_iload_N        ,       // 250
++        _iload_1_iload_N        ,       // 251
++        _iload_2_iload_N        ,       // 252
++        _iload_3_iload_N        ,       // 253
++#endif // HOTSPOT_ASM
+ 
+ #endif // CPU_ZERO_VM_BYTECODES_ZERO_HPP
diff -r c78edcdba40f -r cd6310f10fab patches/hotspot/hs20/gcc-suffix.patch
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/hotspot/hs20/gcc-suffix.patch	Sun Jan 30 00:45:18 2011 +0000
@@ -0,0 +1,31 @@
+diff -Nru openjdk.orig/hotspot/agent/src/os/linux/Makefile openjdk/hotspot/agent/src/os/linux/Makefile
+--- openjdk.orig/hotspot/agent/src/os/linux/Makefile	2011-01-25 22:57:24.000000000 +0000
++++ openjdk/hotspot/agent/src/os/linux/Makefile	2011-01-28 00:43:20.632487152 +0000
+@@ -23,7 +23,7 @@
+ #
+ 
+ ARCH := $(shell if ([ `uname -m` = "ia64" ])  ; then echo ia64 ; elif ([ `uname -m` = "x86_64" ]) ; then echo amd64; elif ([ `uname -m` = "sparc64" ]) ; then echo sparc; else echo i386 ; fi )
+-GCC      = gcc
++GCC      = gcc$(GCC_SUFFIX)
+ 
+ JAVAH    = ${JAVA_HOME}/bin/javah
+ 
+diff -Nru openjdk.orig/hotspot/make/linux/makefiles/gcc.make openjdk/hotspot/make/linux/makefiles/gcc.make
+--- openjdk.orig/hotspot/make/linux/makefiles/gcc.make	2011-01-28 00:35:53.000000000 +0000
++++ openjdk/hotspot/make/linux/makefiles/gcc.make	2011-01-28 00:43:56.676866099 +0000
+@@ -28,11 +28,11 @@
+ # When cross-compiling the ALT_COMPILER_PATH points
+ # to the cross-compilation toolset
+ ifdef CROSS_COMPILE_ARCH
+-CPP = $(ALT_COMPILER_PATH)/g++
+-CC  = $(ALT_COMPILER_PATH)/gcc
++CPP = $(ALT_COMPILER_PATH)/g++$(GCC_SUFFIX)
++CC  = $(ALT_COMPILER_PATH)/gcc$(GCC_SUFFIX)
+ else
+-CPP = g++
+-CC  = gcc
++CPP = g++$(GCC_SUFFIX)
++CC  = gcc$(GCC_SUFFIX)
+ endif
+ 
+ AS  = $(CC) -c
diff -r c78edcdba40f -r cd6310f10fab patches/hotspot/hs20/ia64-fix.patch
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/hotspot/hs20/ia64-fix.patch	Sun Jan 30 00:45:18 2011 +0000
@@ -0,0 +1,15 @@
+--- openjdk/hotspot/src/share/vm/opto/connode.cpp~	2010-10-08 20:29:24.000000000 +0000
++++ openjdk/hotspot/src/share/vm/opto/connode.cpp	2010-11-29 07:57:22.000000000 +0000
+@@ -712,12 +712,7 @@
+   if( t == Type::TOP ) return Type::TOP;
+   if( t == Type::FLOAT ) return Type::DOUBLE;
+   const TypeF *tf = t->is_float_constant();
+-#ifndef IA64
+   return TypeD::make( (double)tf->getf() );
+-#else
+-  float x = tf->getf();
+-  return TypeD::make( (x == 0.0f) ? (double)x : (double)x + ia64_double_zero );
+-#endif
+ }
+ 
+ //=============================================================================
diff -r c78edcdba40f -r cd6310f10fab patches/hotspot/hs20/params-cast-size_t.patch
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/hotspot/hs20/params-cast-size_t.patch	Sun Jan 30 00:45:18 2011 +0000
@@ -0,0 +1,270 @@
+diff -Nru openjdk.orig/hotspot/src/share/vm/gc_implementation/concurrentMarkSweep/compactibleFreeListSpace.cpp openjdk/hotspot/src/share/vm/gc_implementation/concurrentMarkSweep/compactibleFreeListSpace.cpp
+--- openjdk.orig/hotspot/src/share/vm/gc_implementation/concurrentMarkSweep/compactibleFreeListSpace.cpp	2011-01-25 22:57:24.000000000 +0000
++++ openjdk/hotspot/src/share/vm/gc_implementation/concurrentMarkSweep/compactibleFreeListSpace.cpp	2011-01-28 01:06:11.887088930 +0000
+@@ -2645,7 +2645,7 @@
+   if (ResizeOldPLAB && CMSOldPLABResizeQuicker) {
+     size_t multiple = _num_blocks[word_sz]/(CMSOldPLABToleranceFactor*CMSOldPLABNumRefills*n_blks);
+     n_blks +=  CMSOldPLABReactivityFactor*multiple*n_blks;
+-    n_blks = MIN2(n_blks, CMSOldPLABMax);
++    n_blks = MIN2(n_blks, (size_t)CMSOldPLABMax);
+   }
+   assert(n_blks > 0, "Error");
+   _cfls->par_get_chunk_of_blocks(word_sz, n_blks, fl);
+diff -Nru openjdk.orig/hotspot/src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp openjdk/hotspot/src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp
+--- openjdk.orig/hotspot/src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp	2011-01-25 22:57:24.000000000 +0000
++++ openjdk/hotspot/src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp	2011-01-28 01:06:11.891088974 +0000
+@@ -955,7 +955,7 @@
+   if (free_percentage < desired_free_percentage) {
+     size_t desired_capacity = (size_t)(used() / ((double) 1 - desired_free_percentage));
+     assert(desired_capacity >= capacity(), "invalid expansion size");
+-    expand_bytes = MAX2(desired_capacity - capacity(), MinHeapDeltaBytes);
++    expand_bytes = MAX2((long unsigned int) (desired_capacity - capacity()), (long unsigned int) MinHeapDeltaBytes);
+   }
+   if (expand_bytes > 0) {
+     if (PrintGCDetails && Verbose) {
+@@ -6238,7 +6238,7 @@
+     HeapWord* curAddr = _markBitMap.startWord();
+     while (curAddr < _markBitMap.endWord()) {
+       size_t remaining  = pointer_delta(_markBitMap.endWord(), curAddr);
+-      MemRegion chunk(curAddr, MIN2(CMSBitMapYieldQuantum, remaining));
++      MemRegion chunk(curAddr, MIN2((size_t) CMSBitMapYieldQuantum, remaining));
+       _markBitMap.clear_large_range(chunk);
+       if (ConcurrentMarkSweepThread::should_yield() &&
+           !foregroundGCIsActive() &&
+@@ -6533,7 +6533,7 @@
+     return;
+   }
+   // Double capacity if possible
+-  size_t new_capacity = MIN2(_capacity*2, MarkStackSizeMax);
++  size_t new_capacity = MIN2((size_t) (_capacity*2), (size_t) MarkStackSizeMax);
+   // Do not give up existing stack until we have managed to
+   // get the double capacity that we desired.
+   ReservedSpace rs(ReservedSpace::allocation_align_size_up(
+diff -Nru openjdk.orig/hotspot/src/share/vm/gc_implementation/g1/concurrentMark.cpp openjdk/hotspot/src/share/vm/gc_implementation/g1/concurrentMark.cpp
+--- openjdk.orig/hotspot/src/share/vm/gc_implementation/g1/concurrentMark.cpp	2011-01-28 00:50:00.000000000 +0000
++++ openjdk/hotspot/src/share/vm/gc_implementation/g1/concurrentMark.cpp	2011-01-28 01:06:11.891088974 +0000
+@@ -471,7 +471,7 @@


From gnu_andrew at member.fsf.org  Sat Jan 29 17:18:53 2011
From: gnu_andrew at member.fsf.org (Dr Andrew John Hughes)
Date: Sun, 30 Jan 2011 01:18:53 +0000
Subject: /hg/icedtea6: 3 new changesets
In-Reply-To: 
References: 
	
Message-ID: 

On 29 January 2011 20:36, Lussier, Denis  wrote:
> Hi Guys,
> I'm trying to build OpenSCG's one-click Linux 32 and 64-bit installers for
> OpenJDK6 Build 21 this weekend. ?I wanted to include Visual VM in this
> release and I figured this would be a good time to finally switch over to
> using icedtea6 as my base. ? ?When I build the icedtea6-1.9.4 source tarball
> it seems to use openjdk build 20. ?What do y'all recommend?
> --Denis Lussier
> ??http://openscg.org
>

The stable 1.9 series uses b20 but includes many additional patches,
including some items upstreamed in b21 and some which have yet to be
upstreamed.

Build 21 will be used by the upcoming 1.10 release which will happen
in mid-February, but it will contain neither VisualVM nor the plugin
and WebStart support.

VisualVM support is in the separate VisualVM harness project and has
been since IcedTea6 1.9.

The plugin & NetX support will shortly appear in the first release of
the IcedTea-Web project.

See the IcedTea wiki for more details: http://icedtea.classpath.org/wiki

>
> On Mon, Jan 24, 2011 at 1:02 PM,  wrote:
>>
>> changeset 6818a5e1f330 in /hg/icedtea6
>> details:
>> http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=6818a5e1f330
>> author: Andrew John Hughes 
>> date: Mon Jan 24 20:55:14 2011 +0000
>>
>> ? ? ? ?Update NEWS with b21 updates.
>>
>> ? ? ? ?2011-01-22 Andrew John Hughes 
>>
>> ? ? ? ? * NEWS: Update 1.10 with b21 changes. Remove changes
>> ? ? ? ?in b21 from list of backports.
>>
>>
>



-- 
Andrew :-)

Free Java Software Engineer
Red Hat, Inc. (http://www.redhat.com)

Support Free Java!
Contribute to GNU Classpath and the OpenJDK
http://www.gnu.org/software/classpath
http://openjdk.java.net

PGP Key: 94EFD9D8 (http://subkeys.pgp.net)
Fingerprint: F8EF F1EA 401E 2E60 15FA? 7927 142C 2591 94EF D9D8


From bugzilla-daemon at icedtea.classpath.org  Sun Jan 30 10:55:03 2011
From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org)
Date: Sun, 30 Jan 2011 18:55:03 +0000
Subject: [Bug 595] ExceptionInInitializerError/AccessControlException in
	AppletAudioClip.play()
Message-ID: 

http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=595





------- Comment #4 from Paul-Ebermann at gmx.de  2011-01-30 18:55 -------
This seems to be an Ubuntu specific bug. Here is the entry in Launchpad:
https://bugs.launchpad.net/ubuntu/+source/openjdk-6/+bug/525883

(Thanks for the help.)


-- 
Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.


From bugzilla-daemon at icedtea.classpath.org  Sun Jan 30 12:22:25 2011
From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org)
Date: Sun, 30 Jan 2011 20:22:25 +0000
Subject: [Bug 595] ExceptionInInitializerError/AccessControlException in
	AppletAudioClip.play()
Message-ID: 

http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=595





------- Comment #5 from sadan.yuval at gmail.com  2011-01-30 20:22 -------
I'm receiving a similar problem while trying to use the MIDI synthesizer. It
happens on Firefox and Chromium.

What I have to make new here, is that when I run firefox from the terminal
('firefox &') it works perfectly. That trick doesn't work in Chromioum.

I'll attach the code. Here is the stack trace:
java.security.AccessControlException: access denied
(java.lang.RuntimePermission loadLibrary.pulse-java) at
java.security.AccessControlContext.checkPermission(AccessControlContext.java:342)
at java.security.AccessController.checkPermission(AccessController.java:553) at
java.lang.SecurityManager.checkPermission(SecurityManager.java:549) at
net.sourceforge.jnlp.runtime.JNLPSecurityManager.checkPermission(JNLPSecurityManager.java:250)
at java.lang.SecurityManager.checkLink(SecurityManager.java:835) at
java.lang.Runtime.loadLibrary0(Runtime.java:834) at
java.lang.System.loadLibrary(System.java:1047) at
org.classpath.icedtea.pulseaudio.SecurityWrapper$1.run(SecurityWrapper.java:18)
at
org.classpath.icedtea.pulseaudio.SecurityWrapper$1.run(SecurityWrapper.java:15)
at java.security.AccessController.doPrivileged(Native Method) at
org.classpath.icedtea.pulseaudio.SecurityWrapper.loadNativeLibrary(SecurityWrapper.java:24)
at org.classpath.icedtea.pulseaudio.EventLoop.(EventLoop.java:105) at
org.classpath.icedtea.pulseaudio.PulseAudioMixer.openImpl(PulseAudioMixer.java:654)
at
org.classpath.icedtea.pulseaudio.PulseAudioMixer.openLocal(PulseAudioMixer.java:588)
at
org.classpath.icedtea.pulseaudio.PulseAudioMixer.openLocal(PulseAudioMixer.java:584)
at
org.classpath.icedtea.pulseaudio.PulseAudioMixer.open(PulseAudioMixer.java:579)
at
org.classpath.icedtea.pulseaudio.PulseAudioDataLine.open(PulseAudioDataLine.java:95)
at
org.classpath.icedtea.pulseaudio.PulseAudioSourceDataLine.open(PulseAudioSourceDataLine.java:75)
at com.sun.media.sound.SoftSynthesizer.open(SoftSynthesizer.java:1077) at
com.sun.media.sound.SoftSynthesizer.open(SoftSynthesizer.java:1036) at
MidiServerApplet.playSound(MidiServerApplet.java:19) at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:616) at
sun.applet.PluginAppletSecurityContext$4.run(PluginAppletSecurityContext.java:699)
at java.security.AccessController.doPrivileged(Native Method) at
sun.applet.PluginAppletSecurityContext.handleMessage(PluginAppletSecurityContext.java:696)
at
sun.applet.AppletSecurityContextManager.handleMessage(AppletSecurityContextManager.java:69)
at sun.applet.PluginStreamHandler.handleMessage(PluginStreamHandler.java:273)
at
sun.applet.PluginMessageHandlerWorker.run(PluginMessageHandlerWorker.java:82)
java.lang.ExceptionInInitializerError at
org.classpath.icedtea.pulseaudio.PulseAudioMixer.openImpl(PulseAudioMixer.java:654)
at
org.classpath.icedtea.pulseaudio.PulseAudioMixer.openLocal(PulseAudioMixer.java:588)
at
org.classpath.icedtea.pulseaudio.PulseAudioMixer.openLocal(PulseAudioMixer.java:584)
at
org.classpath.icedtea.pulseaudio.PulseAudioMixer.open(PulseAudioMixer.java:579)
at
org.classpath.icedtea.pulseaudio.PulseAudioDataLine.open(PulseAudioDataLine.java:95)
at
org.classpath.icedtea.pulseaudio.PulseAudioSourceDataLine.open(PulseAudioSourceDataLine.java:75)
at com.sun.media.sound.SoftSynthesizer.open(SoftSynthesizer.java:1077) at
com.sun.media.sound.SoftSynthesizer.open(SoftSynthesizer.java:1036) at
MidiServerApplet.playSound(MidiServerApplet.java:19) at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:616) at
sun.applet.PluginAppletSecurityContext$4.run(PluginAppletSecurityContext.java:699)
at java.security.AccessController.doPrivileged(Native Method) at
sun.applet.PluginAppletSecurityContext.handleMessage(PluginAppletSecurityContext.java:696)
at
sun.applet.AppletSecurityContextManager.handleMessage(AppletSecurityContextManager.java:69)
at sun.applet.PluginStreamHandler.handleMessage(PluginStreamHandler.java:273)
at
sun.applet.PluginMessageHandlerWorker.run(PluginMessageHandlerWorker.java:82) 
Caused by: java.security.AccessControlException: access denied
(java.lang.RuntimePermission loadLibrary.pulse-java) at
java.security.AccessControlContext.checkPermission(AccessControlContext.java:342)
at java.security.AccessController.checkPermission(AccessController.java:553) at
java.lang.SecurityManager.checkPermission(SecurityManager.java:549) at
net.sourceforge.jnlp.runtime.JNLPSecurityManager.checkPermission(JNLPSecurityManager.java:250)
at java.lang.SecurityManager.checkLink(SecurityManager.java:835) at
java.lang.Runtime.loadLibrary0(Runtime.java:834) at
java.lang.System.loadLibrary(System.java:1047) at
org.classpath.icedtea.pulseaudio.SecurityWrapper$1.run(SecurityWrapper.java:18)
at
org.classpath.icedtea.pulseaudio.SecurityWrapper$1.run(SecurityWrapper.java:15)
at java.security.AccessController.doPrivileged(Native Method) at
org.classpath.icedtea.pulseaudio.SecurityWrapper.loadNativeLibrary(SecurityWrapper.java:24)
at org.classpath.icedtea.pulseaudio.EventLoop.(EventLoop.java:105) ...
19 more 

I'm relatively new to Linux and to Java. 
I'm running Ubuntu 10.04, Firefox 3.6.13, Chromium 8.0.552.237 (70801)


-- 
Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.


From bugzilla-daemon at icedtea.classpath.org  Sun Jan 30 12:49:12 2011
From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org)
Date: Sun, 30 Jan 2011 20:49:12 +0000
Subject: [Bug 595] ExceptionInInitializerError/AccessControlException in
	AppletAudioClip.play()
Message-ID: 

http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=595





------- Comment #6 from sadan.yuval at gmail.com  2011-01-30 20:49 -------
I'm receiving a similar problem while trying to use the MIDI synthesizer. It
happens on Firefox and Chromium.

What I have to make new here, is that when I run firefox from the terminal
('firefox &') it works perfectly. That trick doesn't work in Chromioum.

I'll attach the test case. Here is the stack trace:
=== 


java.lang.ExceptionInInitializerError
        at
org.classpath.icedtea.pulseaudio.PulseAudioMixer.openImpl(PulseAudioMixer.java:654)
        at
org.classpath.icedtea.pulseaudio.PulseAudioMixer.openLocal(PulseAudioMixer.java:588)
        at
org.classpath.icedtea.pulseaudio.PulseAudioMixer.openLocal(PulseAudioMixer.java:584)
        at
org.classpath.icedtea.pulseaudio.PulseAudioMixer.open(PulseAudioMixer.java:579)
        at
org.classpath.icedtea.pulseaudio.PulseAudioDataLine.open(PulseAudioDataLine.java:95)
        at
org.classpath.icedtea.pulseaudio.PulseAudioSourceDataLine.open(PulseAudioSourceDataLine.java:75)
        at com.sun.media.sound.SoftSynthesizer.open(SoftSynthesizer.java:1077)
        at com.sun.media.sound.SoftSynthesizer.open(SoftSynthesizer.java:1036)
        at MidiServerApplet.playSound(MidiServerApplet.java:27)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:616)
        at
sun.applet.PluginAppletSecurityContext$4.run(PluginAppletSecurityContext.java:699)
        at java.security.AccessController.doPrivileged(Native Method)
        at
sun.applet.PluginAppletSecurityContext.handleMessage(PluginAppletSecurityContext.java:696)
        at
sun.applet.AppletSecurityContextManager.handleMessage(AppletSecurityContextManager.java:69)
        at
sun.applet.PluginStreamHandler.handleMessage(PluginStreamHandler.java:273)
        at
sun.applet.PluginMessageHandlerWorker.run(PluginMessageHandlerWorker.java:82)
Caused by: java.security.AccessControlException: access denied
(java.lang.RuntimePermission loadLibrary.pulse-java)
        at
java.security.AccessControlContext.checkPermission(AccessControlContext.java:342)
        at
java.security.AccessController.checkPermission(AccessController.java:553)
        at java.lang.SecurityManager.checkPermission(SecurityManager.java:549)
        at
net.sourceforge.jnlp.runtime.JNLPSecurityManager.checkPermission(JNLPSecurityManager.java:250)
        at java.lang.SecurityManager.checkLink(SecurityManager.java:835)
        at java.lang.Runtime.loadLibrary0(Runtime.java:834)
        at java.lang.System.loadLibrary(System.java:1047)
        at
org.classpath.icedtea.pulseaudio.SecurityWrapper$1.run(SecurityWrapper.java:18)
        at
org.classpath.icedtea.pulseaudio.SecurityWrapper$1.run(SecurityWrapper.java:15)
        at java.security.AccessController.doPrivileged(Native Method)
        at
org.classpath.icedtea.pulseaudio.SecurityWrapper.loadNativeLibrary(SecurityWrapper.java:24)
        at org.classpath.icedtea.pulseaudio.EventLoop.(EventLoop.java:105)
        at
org.classpath.icedtea.pulseaudio.PulseAudioMixer.openImpl(PulseAudioMixer.java:654)
        at
org.classpath.icedtea.pulseaudio.PulseAudioMixer.openLocal(PulseAudioMixer.java:588)
        at
org.classpath.icedtea.pulseaudio.PulseAudioMixer.openLocal(PulseAudioMixer.java:584)
        at
org.classpath.icedtea.pulseaudio.PulseAudioMixer.open(PulseAudioMixer.java:579)
        at
org.classpath.icedtea.pulseaudio.PulseAudioDataLine.open(PulseAudioDataLine.java:95)
        at
org.classpath.icedtea.pulseaudio.PulseAudioSourceDataLine.open(PulseAudioSourceDataLine.java:75)
        at com.sun.media.sound.SoftSynthesizer.open(SoftSynthesizer.java:1077)
        at com.sun.media.sound.SoftSynthesizer.open(SoftSynthesizer.java:1036)
        at MidiServerApplet.playSound(MidiServerApplet.java:27)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:616)
        at
sun.applet.PluginAppletSecurityContext$4.run(PluginAppletSecurityContext.java:699)
        at java.security.AccessController.doPrivileged(Native Method)
        at
sun.applet.PluginAppletSecurityContext.handleMessage(PluginAppletSecurityContext.java:696)
        at
sun.applet.AppletSecurityContextManager.handleMessage(AppletSecurityContextManager.java:69)
        at
sun.applet.PluginStreamHandler.handleMessage(PluginStreamHandler.java:273)
        at
sun.applet.PluginMessageHandlerWorker.run(PluginMessageHandlerWorker.java:82)


===

I'm relatively new to Linux and to Java. 
I'm running Ubuntu 10.04, Firefox 3.6.13, Chromium 8.0.552.237 (70801)
Here are the Java system properties:
java.version = 1.6.0_20
java.vendor = Sun Microsystems Inc.
java.vendor.url = http://java.sun.com/
java.vm.version = 19.0-b09
java.vm.vendor = Sun Microsystems Inc.
java.vm.name = OpenJDK Server VM


-- 
Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.


From bugzilla-daemon at icedtea.classpath.org  Sun Jan 30 12:52:18 2011
From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org)
Date: Sun, 30 Jan 2011 20:52:18 +0000
Subject: [Bug 595] ExceptionInInitializerError/AccessControlException in
	AppletAudioClip.play()
Message-ID: 

http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=595





------- Comment #7 from sadan.yuval at gmail.com  2011-01-30 20:52 -------
Created an attachment (id=455)
 --> (http://icedtea.classpath.org/bugzilla/attachment.cgi?id=455&action=view)
Simple Java applet creating a MIDI synthesizer; fails due to bug #595

It works perfectly when I run it in firefox through the terminal window.


-- 
Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.


From bugzilla-daemon at icedtea.classpath.org  Mon Jan 31 03:20:58 2011
From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org)
Date: Mon, 31 Jan 2011 11:20:58 +0000
Subject: [Bug 623] New: sweethome3d is slow with icedtea compared to sun-jdk
Message-ID: 

http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=623

           Summary: sweethome3d is slow with icedtea compared to sun-jdk
           Product: IcedTea
           Version: 6-1.9.4
          Platform: all
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: IcedTea6
        AssignedTo: unassigned at icedtea.classpath.org
        ReportedBy: fordfrog at gentoo.org


yesterday i worked with sweethome3d app (http://www.sweethome3d.com/) and i
noticed it's significantly slow when using icedtea compared to sun-jdk. i was
using dev-java/icedtea-6.1.9.4 and dev-java/sun-jdk-1.6.0.23. i just tried
dev-java/icedtea-7.1.13 and it's close to the same speed as sun-jdk. i'm using
gentoo linux distribution, amd64 system (core i7). here are use flags i have
turned on for icedtea6:

USE="doc examples hs19 javascript nio2 nsplugin nss systemtap webstart xrender
-cacao -debug -pulseaudio -zero".

for icedtea7 i have these use flags:

USE="doc examples javascript nsplugin systemtap xrender -cacao -debug
-pulseaudio -zero"

there is also another thing that is weird, and that is that on app startup, on
sun-jdk splash screen is displayed whereas on icedtea )both 6 and 7) no
splashscreen is displayed. i am not sure if this is a bug too or it's a
"feature".


-- 
Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.


From bugzilla-daemon at icedtea.classpath.org  Mon Jan 31 07:01:20 2011
From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org)
Date: Mon, 31 Jan 2011 15:01:20 +0000
Subject: [Bug 623] sweethome3d is slow with icedtea compared to sun-jdk
Message-ID: 

http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=623


dbhole at redhat.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at icedtea.classpath|omajid at redhat.com
                   |.org                        |




-- 
Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
You are the assignee for the bug, or are watching the assignee.


From ptisnovs at redhat.com  Mon Jan 31 08:46:31 2011
From: ptisnovs at redhat.com (Pavel Tisnovsky)
Date: Mon, 31 Jan 2011 17:46:31 +0100
Subject: Reviewer needed - two new regression tests for checking PNG reader
	behaviour
Message-ID: <4D46E767.1030006@redhat.com>

Hi all,

can anybody please review two new regression tests I'd like to add to
IcedTea6 HEAD? These tests check if PNG reader could read correct PNG
files and if _proper_ exception is generated when PNG reader is about to
read broken PNGs.

The test PNG images were obtained from the page
http://www.schaik.com/pngsuite/pngsuite.html with Willem van Schaik's
approval (we already discussed about this issue in this thread
http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011637.html).

What is included in attachment:

[hg_export] - hg export generated from recent IcedTea6 HEAD, but it
doesn't contain binary PNG images

[overlays.tar.gz] - new binary PNG files which are stored in overlay
directory

These two new tests were checked using recent IcedTea6 HEAD in RHEL.

Thank you in advance,
Pavel
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: hg_export
Url: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110131/3355a87b/hg_export.ksh 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: overlays.tar.gz
Type: application/x-gzip
Size: 75685 bytes
Desc: not available
Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110131/3355a87b/overlays.tar.gz 

From ptisnovs at redhat.com  Mon Jan 31 09:49:33 2011
From: ptisnovs at redhat.com (Pavel Tisnovsky)
Date: Mon, 31 Jan 2011 18:49:33 +0100
Subject: Reviewer needed - two new regression tests for checking PNG reader
	behaviour
In-Reply-To: <20110131173215.GD18251@rivendell.middle-earth.co.uk>
References: <4D46E767.1030006@redhat.com>
	<20110131173215.GD18251@rivendell.middle-earth.co.uk>
Message-ID: <4D46F62D.4060203@redhat.com>

Dr Andrew John Hughes wrote:
> On 17:46 Mon 31 Jan     , Pavel Tisnovsky wrote:
> 
> Looks good.  Do you plan to post these for inclusion in OpenJDK7?

Hi Andrew,

I'll try of course, but I'm not sure if Willem van Schaik's permission
to use his PNG images will be appropriate for OpenJDK licence policy :-)

Pavel


From ahughes at redhat.com  Mon Jan 31 09:32:15 2011
From: ahughes at redhat.com (Dr Andrew John Hughes)
Date: Mon, 31 Jan 2011 17:32:15 +0000
Subject: Reviewer needed - two new regression tests for checking PNG
	reader behaviour
In-Reply-To: <4D46E767.1030006@redhat.com>
References: <4D46E767.1030006@redhat.com>
Message-ID: <20110131173215.GD18251@rivendell.middle-earth.co.uk>

On 17:46 Mon 31 Jan     , Pavel Tisnovsky wrote:
> Hi all,
> 
> can anybody please review two new regression tests I'd like to add to
> IcedTea6 HEAD? These tests check if PNG reader could read correct PNG
> files and if _proper_ exception is generated when PNG reader is about to
> read broken PNGs.
> 
> The test PNG images were obtained from the page
> http://www.schaik.com/pngsuite/pngsuite.html with Willem van Schaik's
> approval (we already discussed about this issue in this thread
> http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-January/011637.html).
> 
> What is included in attachment:
> 
> [hg_export] - hg export generated from recent IcedTea6 HEAD, but it
> doesn't contain binary PNG images
> 
> [overlays.tar.gz] - new binary PNG files which are stored in overlay
> directory
> 
> These two new tests were checked using recent IcedTea6 HEAD in RHEL.
> 
> Thank you in advance,
> Pavel

Looks good.  Do you plan to post these for inclusion in OpenJDK7?

> # HG changeset patch
> # User ptisnovs
> # Date 1296491845 -3600
> # Node ID a2c2cc977b0744c78ec9731843f76222851a6842
> # Parent  cd6310f10fab37935f88da1814957f10d850bc25
> Added two new regression test to check proper PNG reader behaviour.
> 
> diff -r cd6310f10fab -r a2c2cc977b07 ChangeLog
> --- a/ChangeLog	Sun Jan 30 00:45:18 2011 +0000
> +++ b/ChangeLog	Mon Jan 31 17:37:25 2011 +0100
> @@ -1,3 +1,9 @@
> +2011-01-31  Pavel Tisnovsky  
> +
> +	* patches/jtreg-png-reader.patch:
> +	Added two new regression tests which check correct behaviour of PNG
> +	reader.
> +
>  2011-01-29  Andrew John Hughes  
>  
>  	* patches/gcc-suffix.patch,
> diff -r cd6310f10fab -r a2c2cc977b07 Makefile.am
> --- a/Makefile.am	Sun Jan 30 00:45:18 2011 +0000
> +++ b/Makefile.am	Mon Jan 31 17:37:25 2011 +0100
> @@ -275,7 +275,8 @@
>  	patches/jtreg-international-fonts-styles.patch \
>  	patches/openjdk/6736649-text_bearings.patch \
>  	patches/openjdk/6797139-jbutton_truncation.patch \
> -	patches/openjdk/6883341-text_bearing_exception.patch
> +	patches/openjdk/6883341-text_bearing_exception.patch \
> +	patches/jtreg-png-reader.patch
>  
>  if !WITH_ALT_HSBUILD
>  ICEDTEA_PATCHES += \
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/broken_images/x00n0g01.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/broken_images/x00n0g01.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/broken_images/xcrn0g04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/broken_images/xcrn0g04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/broken_images/xlfn0g04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/broken_images/xlfn0g04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi0g01.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi0g01.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi0g02.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi0g02.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi0g04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi0g04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi0g08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi0g08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi0g16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi0g16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi2c16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi2c16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi3p01.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi3p01.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi3p02.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi3p02.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi3p08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi3p08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi4a08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi4a08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi4a16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi4a16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi6a08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi6a08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi6a16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basi6a16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn0g01.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn0g01.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn0g02.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn0g02.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn0g04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn0g04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn0g08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn0g08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn0g16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn0g16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn2c16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn2c16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn3p01.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn3p01.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn3p02.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn3p02.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn3p08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn3p08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn4a08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn4a08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn4a16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn4a16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn6a08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn6a08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn6a16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/basn6a16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/bgai4a08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/bgai4a08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/bgai4a16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/bgai4a16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/bgan6a08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/bgan6a08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/bgan6a16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/bgan6a16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/bgbn4a08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/bgbn4a08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/bggn4a16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/bggn4a16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/bgwn6a08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/bgwn6a08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/bgyn6a16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/bgyn6a16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ccwn2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ccwn2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ccwn3p08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ccwn3p08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cdfn2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cdfn2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cdhn2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cdhn2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cdsn2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cdsn2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cdun2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cdun2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ch1n3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ch1n3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ch2n3p08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ch2n3p08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cm0n0g04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cm0n0g04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cm7n0g04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cm7n0g04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cm9n0g04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cm9n0g04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cs3n2c16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cs3n2c16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cs3n3p08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cs3n3p08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cs5n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cs5n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cs5n3p08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cs5n3p08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cs8n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cs8n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cs8n3p08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/cs8n3p08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ct0n0g04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ct0n0g04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ct1n0g04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ct1n0g04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ctzn0g04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ctzn0g04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f00n0g08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f00n0g08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f00n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f00n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f01n0g08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f01n0g08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f01n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f01n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f02n0g08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f02n0g08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f02n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f02n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f03n0g08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f03n0g08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f03n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f03n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f04n0g08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f04n0g08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f04n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/f04n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g03n0g16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g03n0g16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g03n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g03n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g03n3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g03n3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g04n0g16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g04n0g16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g04n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g04n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g04n3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g04n3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g05n0g16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g05n0g16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g05n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g05n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g05n3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g05n3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g07n0g16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g07n0g16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g07n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g07n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g07n3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g07n3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g10n0g16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g10n0g16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g10n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g10n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g10n3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g10n3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g25n0g16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g25n0g16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g25n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g25n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g25n3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/g25n3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/oi1n0g16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/oi1n0g16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/oi1n2c16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/oi1n2c16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/oi2n0g16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/oi2n0g16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/oi2n2c16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/oi2n2c16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/oi4n0g16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/oi4n0g16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/oi4n2c16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/oi4n2c16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/oi9n0g16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/oi9n0g16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/oi9n2c16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/oi9n2c16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/pngsuite_logo.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/pngsuite_logo.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/pp0n2c16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/pp0n2c16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/pp0n6a08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/pp0n6a08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ps1n0g08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ps1n0g08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ps1n2c16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ps1n2c16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ps2n0g08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ps2n0g08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ps2n2c16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/ps2n2c16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s01i3p01.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s01i3p01.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s01n3p01.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s01n3p01.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s02i3p01.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s02i3p01.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s02n3p01.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s02n3p01.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s03i3p01.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s03i3p01.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s03n3p01.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s03n3p01.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s04i3p01.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s04i3p01.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s04n3p01.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s04n3p01.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s05i3p02.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s05i3p02.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s05n3p02.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s05n3p02.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s06i3p02.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s06i3p02.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s06n3p02.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s06n3p02.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s07i3p02.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s07i3p02.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s07n3p02.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s07n3p02.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s08i3p02.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s08i3p02.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s08n3p02.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s08n3p02.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s09i3p02.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s09i3p02.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s09n3p02.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s09n3p02.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s32i3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s32i3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s32n3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s32n3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s33i3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s33i3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s33n3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s33n3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s34i3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s34i3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s34n3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s34n3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s35i3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s35i3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s35n3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s35n3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s36i3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s36i3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s36n3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s36n3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s37i3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s37i3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s37n3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s37n3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s38i3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s38i3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s38n3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s38n3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s39i3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s39i3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s39n3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s39n3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s40i3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s40i3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s40n3p04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/s40n3p04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbbn1g04.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbbn1g04.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbbn2c16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbbn2c16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbbn3p08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbbn3p08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbgn2c16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbgn2c16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbgn3p08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbgn3p08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbrn2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbrn2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbwn1g16.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbwn1g16.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbwn3p08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbwn3p08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbyn3p08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tbyn3p08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tp0n1g08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tp0n1g08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tp0n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tp0n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tp0n3p08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tp0n3p08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tp1n3p08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/tp1n3p08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/z00n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/z00n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/z03n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/z03n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/z06n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/z06n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/z09n2c08.png
> Binary file overlays/openjdk/jdk/test/javax/imageio/plugins/png/PngReader/good_images/z09n2c08.png has changed
> diff -r cd6310f10fab -r a2c2cc977b07 patches/jtreg-png-reader.patch
> --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
> +++ b/patches/jtreg-png-reader.patch	Mon Jan 31 17:37:25 2011 +0100
> @@ -0,0 +1,976 @@
> +diff -Nu old/AbstractImageProcessor.java PngReader/AbstractImageProcessor.java
> +--- openjdk/jdk/test/javax/imageio/plugins/png/PngReader/AbstractImageProcessor.java	1970-01-01 01:00:00.000000000 +0100
> ++++ openjdk-old/jdk/test/javax/imageio/plugins/png/PngReader/AbstractImageProcessor.java	2011-01-31 13:59:40.976990000 +0100
> +@@ -0,0 +1,316 @@
> ++/*
> ++ * Copyright 2011 Red Hat, Inc. All Rights Reserved.
> ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
> ++ *
> ++ * This code is free software; you can redistribute it and/or modify it
> ++ * under the terms of the GNU General Public License version 2 only, as
> ++ * published by the Free Software Foundation.
> ++ *
> ++ * This code is distributed in the hope that it will be useful, but WITHOUT
> ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
> ++ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
> ++ * version 2 for more details (a copy is included in the LICENSE file that
> ++ * accompanied this code).
> ++ *
> ++ * You should have received a copy of the GNU General Public License version
> ++ * 2 along with this work; if not, write to the Free Software Foundation,
> ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
> ++ */
> ++
> ++
> ++import java.awt.image.BufferedImage;
> ++import java.awt.image.RenderedImage;
> ++import java.io.File;
> ++import java.io.IOException;
> ++import java.util.Arrays;
> ++import java.util.HashMap;
> ++import java.util.Map;
> ++
> ++import javax.imageio.IIOImage;
> ++import javax.imageio.ImageIO;
> ++import javax.imageio.ImageReader;
> ++import javax.imageio.stream.ImageInputStream;
> ++
> ++/**
> ++ * Abstract class containing only one visible method named run. This method
> ++ * tries to read all images from given directory and then check if no exception
> ++ * is thrown during image reading or if expected exception is really thrown.
> ++ * 
> ++ * This method also prints basic information for each image. Names of files
> ++ * containing images are based on schema proposed by Willem van Schaik, such
> ++ * files are included in PNGSUITE. For more information about the images
> ++ * please see file pngsuite.doc or look at page:
> ++ * http://www.schaik.com/pngsuite/pngsuite.html
> ++ * 
> ++ * @author Pavel Tisnovsky
> ++ */
> ++public class AbstractImageProcessor {
> ++
> ++    // maps used for decoding image attributes from file name
> ++    static final Map testTypes = new HashMap();
> ++    static final Map colorTypes = new HashMap();
> ++
> ++    static {
> ++        // Background tests
> ++        testTypes.put("bga", "alpha no");
> ++        testTypes.put("bgw", "alpha white");
> ++        testTypes.put("bgg", "alpha gray");
> ++        testTypes.put("bgb", "alpha black");
> ++        testTypes.put("bgy", "alpha yellow");
> ++
> ++        // Gamma tests
> ++        testTypes.put("g03", "0.35:2.8");
> ++        testTypes.put("g04", "0.45:2.2 (PC)");
> ++        testTypes.put("g05", "0.55:1.8 (Mac)");
> ++        testTypes.put("g07", "0.70:1.4");
> ++        testTypes.put("g10", "1.00:1.0 (NeXT)");
> ++        testTypes.put("g25", "2.50:0.4");
> ++
> ++        // Transparency tests
> ++        testTypes.put("tp0", "not transparent for reference");
> ++        testTypes.put("tp1", "transparent, but no background chunk");
> ++        testTypes.put("tbw", "transparent + white background");
> ++        testTypes.put("tbg", "transparent + gray background");
> ++        testTypes.put("tbb", "transparent + black background");
> ++        testTypes.put("tby", "transparent + yellow background");
> ++        testTypes.put("tbr", "transparent + red background");
> ++
> ++        // Filtering tests
> ++        testTypes.put("f00", "no");
> ++        testTypes.put("f01", "sub");
> ++        testTypes.put("f02", "up");
> ++        testTypes.put("f03", "average");
> ++        testTypes.put("f04", "paeth");
> ++
> ++        // Additional palette tests
> ++        testTypes.put("pp", "normal palette chunk");
> ++        testTypes.put("ps", "suggested palette chunk");
> ++
> ++        // Chunk ordering tests
> ++        testTypes.put("oi1", "mother image with 1 idat-chunk");
> ++        testTypes.put("oi2", "image with 2 idat-chunks");
> ++        testTypes.put("oi4", "image with 4 unequal sized idat-chunks");
> ++        testTypes.put("oi9", "all idat-chunks of length one");
> ++
> ++        // Auxiliary chunks tests
> ++        testTypes.put("cs3", "3 significant bits");
> ++        testTypes.put("cs5", "5 significant bits");
> ++        testTypes.put("cs8", "8 significant bits (reference)");
> ++        testTypes.put("cdf", "physical pixel dimensions, 8x32 flat pixels");
> ++        testTypes.put("cdh", "physical pixel dimensions, 32x8 high pixels");
> ++        testTypes.put("cds", "physical pixel dimensions, 8x8 square pixels");
> ++        testTypes.put("cdu", "physical pixel dimensions, with unit-specifier");
> ++        testTypes.put("ccw", "primary chromaticities and white point");
> ++        testTypes.put("ch1", "histogram 15 colors");
> ++        testTypes.put("ch2", "histogram 256 colors");
> ++        testTypes.put("cm7", "modification time, 01-jan-1970");
> ++        testTypes.put("cm9", "modification time, 31-dec-1999");
> ++        testTypes.put("cm0", "modification time, 01-jan-2000");
> ++        testTypes.put("ct0", "no textual data");
> ++        testTypes.put("ct1", "with textual data");
> ++        testTypes.put("ctz", "with compressed textual data");
> ++
> ++        // Corrupted images
> ++        testTypes.put("x00", "empty IDAT chunk");
> ++        testTypes.put("xcr", "added cr bytes");
> ++        testTypes.put("xlf", "added lf bytes");
> ++        testTypes.put("xc0", "color type 0");
> ++        testTypes.put("xc9", "color type 9");
> ++        testTypes.put("xd0", "bit-depth 0");
> ++        testTypes.put("xd3", "bit-depth 3");
> ++        testTypes.put("xd9", "bit-depth 99");
> ++        testTypes.put("xcs", "incorrect IDAT checksum");
> ++
> ++        // Color types
> ++        colorTypes.put("0g", "grayscale");
> ++        colorTypes.put("1g", "grayscale");
> ++        colorTypes.put("2c", "RGB color");
> ++        colorTypes.put("3p", "palette");
> ++        colorTypes.put("4a", "grayscale + alpha");
> ++        colorTypes.put("6a", "RGB color + alpha");
> ++    }
> ++
> ++    /**
> ++     * This method tries to read external file containing raster image using
> ++     * ImageReader. When the image file is corrupted or does not contains any
> ++     * data, exception is thrown.
> ++     *
> ++     * @param file path to image file
> ++     * @return RenderedImage extracted from given file
> ++     * @throws ImageReadException thrown in case image file is corrupted
> ++     */
> ++    protected RenderedImage readRenderedImage(File file) throws ImageReadException, Exception {
> ++        try {
> ++            ImageInputStream imageInputStream = ImageIO.createImageInputStream(file);
> ++            ImageReader imageReader = ImageIO.getImageReaders(imageInputStream).next();
> ++            imageReader.setInput(imageInputStream);
> ++            IIOImage image = imageReader.readAll(0, null);
> ++            return image.getRenderedImage();
> ++        }
> ++        catch (IOException e) {
> ++            //e.printStackTrace();
> ++            throw new ImageReadException(file.getName());
> ++        }
> ++    }
> ++
> ++    /**
> ++     * This method tries to read external file containing raster image using
> ++     * method ImageIO.read(). Because this method returns null if no registered
> ++     * ImageReader claims to be able to read the resulting stream, we need to
> ++     * cope with this.
> ++     * 
> ++     * @param file file path to image file
> ++     * @return BufferedImage extracted from given file
> ++     * @throws ImageReadException thrown in case image file is corrupted
> ++     */
> ++    protected BufferedImage readBufferedImage(File file) throws ImageReadException {
> ++        try {
> ++            BufferedImage bufferedImage = ImageIO.read(file);
> ++            // this is mandatory as we need to throw an exception when
> ++            // ImageIO.read() returns null!
> ++            if (bufferedImage == null) {
> ++                throw new ImageReadException(file.getName());
> ++            }
> ++            bufferedImage.toString();
> ++            return bufferedImage;
> ++        }
> ++        catch (IOException e) {
> ++            //e.printStackTrace();
> ++            throw new ImageReadException(file.getName());
> ++        }
> ++    }
> ++
> ++    /**
> ++     * This method extract various informations from name of image.
> ++     *
> ++     * @param fileName
> ++     * @return text containing basic info about image
> ++     */
> ++    private String getImageInfoFromFileName(String fileName) {
> ++        String testType = resolveTestType(fileName.substring(0, 3));
> ++        String interlaced = resolveInterlaced(fileName.charAt(3));
> ++        String colorType = fileName.substring(4, 6);
> ++        String bitDepth = fileName.substring(6, 8);
> ++        colorType = resolveColorType(fileName.substring(4, 6));
> ++        return String.format("test type:   %s\ninterlace:   %s\ncolor type:  %s\ncolor depth: %s",
> ++                testType, interlaced, colorType, bitDepth);
> ++    }
> ++
> ++    private String resolveTestType(String str) {
> ++        if ("bas".equals(str)) {
> ++            return "basic test";
> ++        }
> ++        switch (str.charAt(0)) {
> ++        case 'b':
> ++            return namedTestType("background", str, "background");
> ++        case 'c':
> ++            return namedTestType("auxiliary chunks", str);
> ++        case 'f':
> ++            return namedTestType("filtering", str, "filtering");
> ++        case 'g':
> ++            return gammaTest(str);
> ++        case 'o':
> ++            return namedTestType("chunk ordering", str);
> ++        case 'p':
> ++            return namedTestType("additional palette", str.substring(0, 2));
> ++        case 's':
> ++            return sizeTest(str);
> ++        case 't':
> ++            return namedTestType("transparency", str);
> ++        case 'x':
> ++            return namedTestType("corrupted image", str);
> ++        case 'z':
> ++            return compressionLevelTest(str);
> ++        default:
> ++            return "unknown " + str;
> ++        }
> ++    }
> ++
> ++    @SuppressWarnings("boxing")
> ++    private String sizeTest(String str) {
> ++        int size = Integer.parseInt(str.substring(1, 3));
> ++        String suffix = size > 1 ? "s" : "";
> ++        return String.format("size test for image of size %dx%s pixel%s", size, size, suffix);
> ++    }
> ++
> ++    private String namedTestType(String name, String str) {
> ++        return namedTestType(name, str, "");
> ++    }
> ++
> ++    private String namedTestType(String name, String str, String suffix) {
> ++        if (testTypes.containsKey(str)) {
> ++            return name + " test: " + testTypes.get(str) + " " + suffix;
> ++        }
> ++        return "unknown " + name + " test: " + str;
> ++    }
> ++
> ++    private String compressionLevelTest(String str) {
> ++        return "zlib test for compression level " + str.charAt(2);
> ++    }
> ++
> ++    private String gammaTest(String str) {
> ++        if (testTypes.containsKey(str)) {
> ++            String[] vals = testTypes.get(str).split(":");
> ++            return "gamma test: file-gamma = " + vals[0] + ", for display with gamma = " + vals[1];
> ++        }
> ++        return "unknown gamma test: " + str;
> ++    }
> ++
> ++    private String resolveColorType(String str) {
> ++        if (colorTypes.containsKey(str)) {
> ++            return colorTypes.get(str);
> ++        }
> ++        return "unknown! " + str;
> ++    }
> ++
> ++    private String resolveInterlaced(char ch) {
> ++        return ch == 'i' ? "interlaced" : "non-interlaced";
> ++    }
> ++
> ++    /**
> ++     * This method tries to read all images from given directory and then
> ++     * check if no exception is thrown (expectException==false) or if
> ++     * only expected exception is thrown (expectException==true).
> ++     *
> ++     * @param imageDirectoryName directory containing images
> ++     * @param expectException if IOException is expected to be thrown
> ++     *                        (ie the images are broken)
> ++     */
> ++    protected void run(String imageDirectoryName, boolean expectException) {
> ++        File imageDir = new File(System.getProperty("test.src", "."), imageDirectoryName);
> ++        String[] imageNames = imageDir.list();
> ++        Arrays.sort(imageNames);
> ++        int errors = 0;
> ++        for (String imageName : imageNames) {
> ++            File imageFile = new File(imageDir, imageName);
> ++            System.out.println("\nChecking image: " + imageFile.getAbsolutePath());
> ++            System.out.println(getImageInfoFromFileName(imageName));
> ++            try {
> ++                readBufferedImage(imageFile);
> ++                readRenderedImage(imageFile);
> ++                if (expectException) {
> ++                    errors++;
> ++                    System.out.println("Exception not thrown as expected!");
> ++                }
> ++            }
> ++            catch (ImageReadException e) {
> ++                if (!expectException) {
> ++                    errors++;
> ++                    System.out.println("Exception thrown where not expected!");
> ++                }
> ++                else {
> ++                    System.out.println("Exception thrown as expected");
> ++                }
> ++            }
> ++            catch (Exception e) {
> ++                errors++;
> ++                System.out.println("Unexpected exception! ");
> ++                e.printStackTrace();
> ++            }
> ++        }
> ++        if (errors > 0) {
> ++            throw new RuntimeException("Error processing " + errors + " images");
> ++        }
> ++    }
> ++
> ++}
> +diff -Nu old/BrokenPngImageProcessor.java PngReader/BrokenPngImageProcessor.java
> +--- openjdk/jdk/test/javax/imageio/plugins/png/PngReader/BrokenPngImageProcessor.java	1970-01-01 01:00:00.000000000 +0100
> ++++ openjdk-old/jdk/test/javax/imageio/plugins/png/PngReader/BrokenPngImageProcessor.java	2011-01-31 13:59:40.976990000 +0100
> +@@ -0,0 +1,36 @@
> ++/*
> ++ * Copyright 2011 Red Hat, Inc. All Rights Reserved.
> ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
> ++ *
> ++ * This code is free software; you can redistribute it and/or modify it
> ++ * under the terms of the GNU General Public License version 2 only, as
> ++ * published by the Free Software Foundation.
> ++ *
> ++ * This code is distributed in the hope that it will be useful, but WITHOUT
> ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
> ++ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
> ++ * version 2 for more details (a copy is included in the LICENSE file that
> ++ * accompanied this code).
> ++ *
> ++ * You should have received a copy of the GNU General Public License version
> ++ * 2 along with this work; if not, write to the Free Software Foundation,
> ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
> ++ */
> ++
> ++
> ++/**
> ++ * @test
> ++ * @summary This test checks if the ImageIO subsystem throws proper exception if
> ++ *          broken PNG image is to be read.
> ++ * 
> ++ * @author Pavel Tisnovsky
> ++ * 
> ++ */
> ++public class BrokenPngImageProcessor extends AbstractImageProcessor {
> ++    private static final String IMAGE_DIR = "broken_images";
> ++    private static final boolean EXPECT_EXCEPTION = true;
> ++
> ++    public static void main(String args[]) {
> ++        new BrokenPngImageProcessor().run(IMAGE_DIR, EXPECT_EXCEPTION);
> ++    }
> ++}
> +diff -Nu old/GoodPngImageProcessor.java PngReader/GoodPngImageProcessor.java
> +--- openjdk/jdk/test/javax/imageio/plugins/png/PngReader/GoodPngImageProcessor.java	1970-01-01 01:00:00.000000000 +0100
> ++++ openjdk-old/jdk/test/javax/imageio/plugins/png/PngReader/GoodPngImageProcessor.java	2011-01-31 13:59:40.976990000 +0100
> +@@ -0,0 +1,36 @@
> ++/*
> ++ * Copyright 2011 Red Hat, Inc. All Rights Reserved.
> ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
> ++ *
> ++ * This code is free software; you can redistribute it and/or modify it
> ++ * under the terms of the GNU General Public License version 2 only, as
> ++ * published by the Free Software Foundation.
> ++ *
> ++ * This code is distributed in the hope that it will be useful, but WITHOUT
> ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
> ++ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
> ++ * version 2 for more details (a copy is included in the LICENSE file that
> ++ * accompanied this code).
> ++ *
> ++ * You should have received a copy of the GNU General Public License version
> ++ * 2 along with this work; if not, write to the Free Software Foundation,
> ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
> ++ */
> ++
> ++
> ++/**
> ++ * @test
> ++ * @summary This test check if the ImageIO subsystem is able to process various
> ++ *          types of PNG images which are known to have valid format.
> ++ * 
> ++ * @author Pavel Tisnovsky
> ++ * 
> ++ */
> ++public class GoodPngImageProcessor extends AbstractImageProcessor {
> ++    private static final String IMAGE_DIR = "good_images";
> ++    private static final boolean EXPECT_EXCEPTION = false;
> ++
> ++    public static void main(String args[]) {
> ++        new GoodPngImageProcessor().run(IMAGE_DIR, EXPECT_EXCEPTION);
> ++    }
> ++}
> +diff -Nu old/ImageReadException.java PngReader/ImageReadException.java
> +--- openjdk/jdk/test/javax/imageio/plugins/png/PngReader/ImageReadException.java	1970-01-01 01:00:00.000000000 +0100
> ++++ openjdk-old/jdk/test/javax/imageio/plugins/png/PngReader/ImageReadException.java	2011-01-31 13:59:40.976990000 +0100
> +@@ -0,0 +1,48 @@
> ++/*
> ++ * Copyright 2011 Red Hat, Inc. All Rights Reserved.
> ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
> ++ *
> ++ * This code is free software; you can redistribute it and/or modify it
> ++ * under the terms of the GNU General Public License version 2 only, as
> ++ * published by the Free Software Foundation.
> ++ *
> ++ * This code is distributed in the hope that it will be useful, but WITHOUT
> ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
> ++ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
> ++ * version 2 for more details (a copy is included in the LICENSE file that
> ++ * accompanied this code).
> ++ *
> ++ * You should have received a copy of the GNU General Public License version
> ++ * 2 along with this work; if not, write to the Free Software Foundation,
> ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
> ++ */
> ++
> ++
> ++public class ImageReadException extends Exception {
> ++
> ++    private String fileName;
> ++
> ++    /**
> ++     * Generated serial version UID
> ++     */
> ++    private static final long serialVersionUID = 4418111891788280159L;
> ++
> ++    public ImageReadException(String fileName) {
> ++        this.setFileName(fileName);
> ++    }
> ++
> ++    /**
> ++     * @param fileName the fileName to set
> ++     */
> ++    public void setFileName(String fileName) {
> ++        this.fileName = fileName;
> ++    }
> ++
> ++    /**
> ++     * @return the fileName
> ++     */
> ++    public String getFileName() {
> ++        return this.fileName;
> ++    }
> ++
> ++}
> +diff -Nu old/pngsuite.doc PngReader/pngsuite.doc
> +--- openjdk/jdk/test/javax/imageio/plugins/png/PngReader/pngsuite.doc	1970-01-01 01:00:00.000000000 +0100
> ++++ openjdk-old/jdk/test/javax/imageio/plugins/png/PngReader/pngsuite.doc	2011-01-31 13:59:40.976990000 +0100
> +@@ -0,0 +1,520 @@
> ++        PNGSUITE
> ++----------------
> ++
> ++        testset for PNG-(de)coders
> ++        created by Willem van Schaik
> ++------------------------------------
> ++
> ++This is a collection of graphics images created to test the png applications
> ++like viewers, converters and editors. All (as far as that is possible)
> ++formats supported by the PNG standard are represented.
> ++
> ++
> ++1.      INTRODUCTION
> ++--------------------
> ++
> ++1.1     PNG capabilities
> ++------------------------
> ++
> ++Supported color-types are:
> ++
> ++        -   grayscale
> ++        -   grayscale + alpha-channel
> ++        -   color palettes
> ++        -   rgb
> ++        -   rgb + alpha-channel
> ++
> ++Allowed bitdepths are depending on the color-type, but are in the range
> ++of 1-bit (grayscale, which is b&w) upto 16-bits.
> ++
> ++Special features are:
> ++
> ++        -   interlacing (Adam-7)
> ++        -   gamma-support
> ++        -   transparency (a poor-man's alpha solution)
> ++
> ++
> ++1.2     File naming
> ++-------------------
> ++
> ++Where possible, the testfiles are 32x32 bits icons. This results in a still
> ++reasonable size of the suite even with a large number of tests. The name
> ++of each test-file reflects thetype in the following way:
> ++
> ++        g04i2c08.png
> ++        || |||+---- bit-depth
> ++        || ||+----- color-type (descriptive)
> ++        || |+------ color-type (numerical)
> ++        || +------- interlaced or non-interlaced
> ++        |+--------- parameter of test (in this case gamma-value)
> ++        +---------- test feature (in this case gamma)
> ++
> ++
> ++1.3     PNG formats
> ++-------------------
> ++
> ++color-type:
> ++        0g          -   grayscale
> ++        2c          -   rgb color
> ++        3p          -   paletted
> ++        4a          -   grayscale + alpha channel
> ++        6a          -   rgb color + alpha channel
> ++
> ++bit-depth:
> ++        01          -   with color-type 0, 3
> ++        02          -   with color-type 0, 3
> ++        04          -   with color-type 0, 3
> ++        08          -   with color-type 0, 2, 3, 4, 6
> ++        16          -   with color-type 0, 2, 4, 6
> ++
> ++interlacing:
> ++        n           -   non-interlaced
> ++        i           -   interlaced
> ++
> ++
> ++2.      THE TESTS
> ++-----------------
> ++
> ++2.1     Sizes
> ++-------------
> ++
> ++These tests are there to check if your software handles pictures well, with
> ++picture sizes that are not a multiple of 8. This is particularly important
> ++with Adam-7 type interlacing. In the same way these tests check if pictures
> ++size 1x1 and similar are ok.
> ++
> ++        s01         -   1x1 pixel picture
> ++        s02         -   2x2 pixel picture
> ++        s03         -   3x3 pixel picture
> ++        s04         -   4x4 pixel picture
> ++        s05         -   5x5 pixel picture
> ++        s06         -   6x6 pixel picture
> ++        s07         -   7x7 pixel picture
> ++        s08         -   8x8 pixel picture
> ++        s09         -   9x9 pixel picture
> ++        s32         -   32x32 pixel picture
> ++        s33         -   33x33 pixel picture
> ++        s34         -   34x34 pixel picture
> ++        s35         -   35x35 pixel picture
> ++        s36         -   36x36 pixel picture
> ++        s37         -   37x37 pixel picture
> ++        s38         -   38x38 pixel picture
> ++        s39         -   39x39 pixel picture
> ++        s40         -   40x40 pixel picture
> ++
> ++
> ++2.2     Background
> ++------------------
> ++
> ++When the PNG file contains a background chunck, this should be used for
> ++pictures with alpha-channel or pictures with a transparency chunck. For
> ++pictures without this background-chunk, but with alpha, this testset
> ++assumes a black background.
> ++
> ++For the images in this test, the left-side should be 100% the background
> ++color, where moving to the right the color should gradually become the
> ++image pattern.
> ++
> ++        bga         -   alpha + no background
> ++        bgw         -   alpha + white background
> ++        bgg         -   alpha + gray background
> ++        bgb         -   alpha + black background
> ++        bgy         -   alpha + yellow background
> ++
> ++
> ++2.3     Transparency
> ++--------------------
> ++
> ++Transparency should be used together with a background chunk. To test the
> ++combination of the two the latter 4 tests are there. How to handle pictures
> ++with transparancy, but without a background, opinions can differ. Here we
> ++use black, but especially in the case of paletted images, the normal color
> ++would maybe even be better.
> ++
> ++        tp0         -   not transparent for reference
> ++        tp1         -   transparent, but no background chunk
> ++        tbw         -   transparent + white background
> ++        tbg         -   transparent + gray background
> ++        tbb         -   transparent + black background
> ++        tby         -   transparent + yellow background
> ++
> ++
> ++2.4     Gamma
> ++-------------
> ++
> ++To test if your viewer handles gamma-correction, 6 testfiles are available.
> ++They contain corrected color-ramps and a corresponding gamma-chunk with the
> ++file-gamma value. These are created in such a way that when the viewer does
> ++the gamma correction right, all 6 should be displayed identical.
> ++
> ++If they are different, probably the gamma correction is omitted. In that
> ++case, have a look at the two right coloumns in the 6 pictures. The image
> ++where those two look the same (when looked from far) reflects the gamma of
> ++your system. However, because of the limited size of the image, you should
> ++do more elaborate tests to determine your display gamma.
> ++
> ++        g03         -   file-gamma = 0.35, for display with gamma = 2.8
> ++        g04         -   file-gamma = 0.45, for display with gamma = 2.2 (PC)
> ++        g05         -   file-gamma = 0.55, for display with gamma = 1.8 (Mac)
> ++        g07         -   file-gamma = 0.70, for display with gamma = 1.4
> ++        g10         -   file-gamma = 1.00, for display with gamma = 1.0 (NeXT)
> ++        g25         -   file-gamma = 2.50, for display with gamma = 0.4
> ++
> ++
> ++2.5     Filtering
> ++-----------------
> ++
> ++PNG uses file-filtering, for optimal compression. Normally the type is of
> ++filtering is adjusted to the contents of the picture, but here each file
> ++has the same picture, with a different filtering.
> ++
> ++        f0          -   no filtering
> ++        f1          -   sub filtering
> ++        f2          -   up filtering
> ++        f3          -   average filtering
> ++        f4          -   paeth filtering
> ++
> ++
> ++2.6     Additional palettes
> ++---------------------------
> ++
> ++Besides the normal use of paletted images, palette chunks can in combination
> ++with true-color (and other) images also be used to select color lookup-tables
> ++when the video system is of limited capabilities. The suggested palette chunk
> ++is specially created for this purpose.
> ++
> ++        pp          -   normal palette chunk
> ++        ps          -   suggested palette chunk
> ++
> ++
> ++2.7     Ancillary chunks (under construction)
> ++------------------------
> ++
> ++To test the correct decoding of ancillary chunks, these test-files contain
> ++one or more examples of these chunkcs. Depending on the type of chunk, a
> ++number of typical values are selected to test. Unluckily, the testset can
> ++not contain all combinations, because that would be an endless set.
> ++
> ++The significant bits are used in files with the next higher bit-depth. They
> ++indicate howmany bits are valid.
> ++
> ++        cs3         -   3 significant bits
> ++        cs5         -   5 significant bits
> ++        cs8         -   8 significant bits (reference)
> ++        cs3         -   13 significant bits
> ++
> ++For the physical pixel dimensions, the result of each decoding should be
> ++a sqare picture. The first (cdf) image is an example of flat (horizontal)
> ++pixels, where the pHYS chunk (x is 1 per unit, y = 4 per unit) must take
> ++care of the correction. The second is just the other way round. The last
> ++example uses the unit specifier, for 1000 pixels per meter. This should
> ++result in a picture of 3.2 cm square.
> ++
> ++        cdf         -   physical pixel dimensions, 8x32 flat pixels
> ++        cdh         -   physical pixel dimensions, 32x8 high pixels
> ++        cds         -   physical pixel dimensions, 8x8 square pixels
> ++        cdu         -   physical pixel dimensions, with unit-specifier
> ++
> ++        ccw         -   primary chromaticities and white point
> ++
> ++        ch1         -   histogram 15 colors
> ++        ch2         -   histogram 256 colors
> ++
> ++        cm7         -   modification time, 01-jan-1970
> ++        cm9         -   modification time, 31-dec-1999
> ++        cm0         -   modification time, 01-jan-2000
> ++
> ++In the textual chunk, a number of the standard, and some non-standard
> ++text items are included.
> ++
> ++        ct0         -   no textual data
> ++        ct1         -   with textual data
> ++        ctz         -   with compressed textual data
> ++
> ++
> ++2.8     Chunk ordering (still under construction)
> ++----------------------
> ++
> ++These testfiles will test the obligatory ordering relations between various
> ++chunk types (not yet) as well as the number of data chunks used for the image.
> ++
> ++        oi1         -   mother image with 1 idat-chunk
> ++        oi2         -   image with 2 idat-chunks
> ++        oi4         -   image with 4 unequal sized idat-chunks
> ++        oi9         -   all idat-chunks of length one
> ++
> ++
> ++2.9     Compression level
> ++-------------------------
> ++
> ++Here you will find a set of images compressed by zlib, ranging from level 0 
> ++for no compression at maximum speed upto level 9 for maximum compression.
> ++
> ++        z00         -   zlib compression level 0 - none
> ++        z03         -   zlib compression level 3
> ++        z06         -   zlib compression level 6 - default
> ++        z09         -   zlib compression level 9 - maximum
> ++
> ++
> ++2.10     Corrupted files (under construction)
> ++-----------------------
> ++
> ++All these files are illegal. When decoding they should generate appropriate
> ++error-messages.
> ++
> ++        x00         -   empty IDAT chunk
> ++        xcr         -   added cr bytes
> ++        xlf         -   added lf bytes
> ++        xc0         -   color type 0
> ++        xc9         -   color type 9
> ++        xd0         -   bit-depth 0
> ++        xd3         -   bit-depth 3
> ++        xd9         -   bit-depth 99
> ++        xcs         -   incorrect IDAT checksum
> ++
> ++
> ++3.      TEST FILES
> ++------------------
> ++
> ++For each of the tests listed above, one or more test-files are created. A
> ++selection is made (for each test) for the color-type and bitdepth to be used
> ++for the tests. Further for a number of tests, both a non-interlaced as well
> ++as an interlaced version is available.
> ++
> ++
> ++3.1     Basic format test files (non-interlaced)
> ++------------------------------------------------
> ++
> ++        basn0g01    -   black & white
> ++        basn0g02    -   2 bit (4 level) grayscale
> ++        basn0g04    -   4 bit (16 level) grayscale
> ++        basn0g08    -   8 bit (256 level) grayscale
> ++        basn0g16    -   16 bit (64k level) grayscale
> ++        basn2c08    -   3x8 bits rgb color
> ++        basn2c16    -   3x16 bits rgb color
> ++        basn3p01    -   1 bit (2 color) paletted
> ++        basn3p02    -   2 bit (4 color) paletted
> ++        basn3p04    -   4 bit (16 color) paletted
> ++        basn3p08    -   8 bit (256 color) paletted
> ++        basn4a08    -   8 bit grayscale + 8 bit alpha-channel
> ++        basn4a16    -   16 bit grayscale + 16 bit alpha-channel
> ++        basn6a08    -   3x8 bits rgb color + 8 bit alpha-channel
> ++        basn6a16    -   3x16 bits rgb color + 16 bit alpha-channel
> ++
> ++
> ++3.2     Basic format test files (Adam-7 interlaced)
> ++---------------------------------------------------
> ++
> ++        basi0g01    -   black & white
> ++        basi0g02    -   2 bit (4 level) grayscale
> ++        basi0g04    -   4 bit (16 level) grayscale
> ++        basi0g08    -   8 bit (256 level) grayscale
> ++        basi0g16    -   16 bit (64k level) grayscale
> ++        basi2c08    -   3x8 bits rgb color
> ++        basi2c16    -   3x16 bits rgb color
> ++        basi3p01    -   1 bit (2 color) paletted
> ++        basi3p02    -   2 bit (4 color) paletted
> ++        basi3p04    -   4 bit (16 color) paletted
> ++        basi3p08    -   8 bit (256 color) paletted
> ++        basi4a08    -   8 bit grayscale + 8 bit alpha-channel
> ++        basi4a16    -   16 bit grayscale + 16 bit alpha-channel
> ++        basi6a08    -   3x8 bits rgb color + 8 bit alpha-channel
> ++        basi6a16    -   3x16 bits rgb color + 16 bit alpha-channel
> ++
> ++
> ++3.3     Sizes test files
> ++-----------------------
> ++
> ++        s01n3p01    -   1x1 paletted file, no interlacing
> ++        s02n3p01    -   2x2 paletted file, no interlacing
> ++        s03n3p01    -   3x3 paletted file, no interlacing
> ++        s04n3p01    -   4x4 paletted file, no interlacing
> ++        s05n3p02    -   5x5 paletted file, no interlacing
> ++        s06n3p02    -   6x6 paletted file, no interlacing
> ++        s07n3p02    -   7x7 paletted file, no interlacing
> ++        s08n3p02    -   8x8 paletted file, no interlacing
> ++        s09n3p02    -   9x9 paletted file, no interlacing
> ++        s32n3p04    -   32x32 paletted file, no interlacing
> ++        s33n3p04    -   33x33 paletted file, no interlacing
> ++        s34n3p04    -   34x34 paletted file, no interlacing
> ++        s35n3p04    -   35x35 paletted file, no interlacing
> ++        s36n3p04    -   36x36 paletted file, no interlacing
> ++        s37n3p04    -   37x37 paletted file, no interlacing
> ++        s38n3p04    -   38x38 paletted file, no interlacing
> ++        s39n3p04    -   39x39 paletted file, no interlacing
> ++        s40n3p04    -   40x40 paletted file, no interlacing
> ++
> ++        s01i3p01    -   1x1 paletted file, interlaced
> ++        s02i3p01    -   2x2 paletted file, interlaced
> ++        s03i3p01    -   3x3 paletted file, interlaced
> ++        s04i3p01    -   4x4 paletted file, interlaced
> ++        s05i3p02    -   5x5 paletted file, interlaced
> ++        s06i3p02    -   6x6 paletted file, interlaced
> ++        s07i3p02    -   7x7 paletted file, interlaced
> ++        s08i3p02    -   8x8 paletted file, interlaced
> ++        s09i3p02    -   9x9 paletted file, interlaced
> ++        s32i3p04    -   32x32 paletted file, interlaced
> ++        s33i3p04    -   33x33 paletted file, interlaced
> ++        s34i3p04    -   34x34 paletted file, interlaced
> ++        s35i3p04    -   35x35 paletted file, interlaced
> ++        s36i3p04    -   36x36 paletted file, interlaced
> ++        s37i3p04    -   37x37 paletted file, interlaced
> ++        s38i3p04    -   38x38 paletted file, interlaced
> ++        s39i3p04    -   39x39 paletted file, interlaced
> ++        s40i3p04    -   40x40 paletted file, interlaced
> ++
> ++
> ++3.4     Background test files (with alpha)
> ++------------------------------------------
> ++
> ++        bgai4a08    -   8 bit grayscale, alpha, no background chunk, interlaced
> ++        bgai4a16    -   16 bit grayscale, alpha, no background chunk, interlaced
> ++        bgan6a08    -   3x8 bits rgb color, alpha, no background chunk
> ++        bgan6a16    -   3x16 bits rgb color, alpha, no background chunk
> ++
> ++        bgbn4a08    -   8 bit grayscale, alpha, black background chunk
> ++        bggn4a16    -   16 bit grayscale, alpha, gray background chunk
> ++        bgwn6a08    -   3x8 bits rgb color, alpha, white background chunk
> ++        bgyn6a16    -   3x16 bits rgb color, alpha, yellow background chunk
> ++
> ++
> ++3.5     Transparency (and background) test files
> ++------------------------------------------------
> ++
> ++        tp0n1g08    -   not transparent for reference (logo on gray)
> ++        tbbn1g04    -   transparent, black background chunk
> ++        tbwn1g16    -   transparent, white background chunk
> ++        tp0n2c08    -   not transparent for reference (logo on gray)
> ++        tbrn2c08    -   transparent, red background chunk
> ++        tbgn2c16    -   transparent, green background chunk
> ++        tbbn2c16    -   transparent, blue background chunk
> ++        tp0n3p08    -   not transparent for reference (logo on gray)
> ++        tp1n3p08    -   transparent, but no background chunk
> ++        tbbn3p08    -   transparent, black background chunk
> ++        tbgn3p08    -   transparent, light-gray background chunk
> ++        tbwn3p08    -   transparent, white background chunk
> ++        tbyn3p08    -   transparent, yellow background chunk
> ++
> ++
> ++3.6     Gamma test files
> ++------------------------
> ++
> ++        g03n0g16    -   grayscale, file-gamma = 0.35
> ++        g04n0g16    -   grayscale, file-gamma = 0.45
> ++        g05n0g16    -   grayscale, file-gamma = 0.55
> ++        g07n0g16    -   grayscale, file-gamma = 0.70
> ++        g10n0g16    -   grayscale, file-gamma = 1.00
> ++        g25n0g16    -   grayscale, file-gamma = 2.50
> ++        g03n2c08    -   color, file-gamma = 0.35
> ++        g04n2c08    -   color, file-gamma = 0.45
> ++        g05n2c08    -   color, file-gamma = 0.55
> ++        g07n2c08    -   color, file-gamma = 0.70
> ++        g10n2c08    -   color, file-gamma = 1.00
> ++        g25n2c08    -   color, file-gamma = 2.50
> ++        g03n3p04    -   paletted, file-gamma = 0.35
> ++        g04n3p04    -   paletted, file-gamma = 0.45
> ++        g05n3p04    -   paletted, file-gamma = 0.55
> ++        g07n3p04    -   paletted, file-gamma = 0.70
> ++        g10n3p04    -   paletted, file-gamma = 1.00
> ++        g25n3p04    -   paletted, file-gamma = 2.50
> ++
> ++
> ++3.7     Filtering test files
> ++----------------------------
> ++
> ++        f00n0g08    -   grayscale, no interlacing, filter-type 0
> ++        f01n0g08    -   grayscale, no interlacing, filter-type 1
> ++        f02n0g08    -   grayscale, no interlacing, filter-type 2
> ++        f03n0g08    -   grayscale, no interlacing, filter-type 3
> ++        f04n0g08    -   grayscale, no interlacing, filter-type 4
> ++        f00n2c08    -   color, no interlacing, filter-type 0
> ++        f01n2c08    -   color, no interlacing, filter-type 1
> ++        f02n2c08    -   color, no interlacing, filter-type 2
> ++        f03n2c08    -   color, no interlacing, filter-type 3
> ++        f04n2c08    -   color, no interlacing, filter-type 4
> ++
> ++
> ++3.8     Additional palette chunk test files
> ++-------------------------------------------
> ++
> ++        pp0n2c16    -   six-cube palette-chunk in true-color image
> ++        pp0n6a08    -   six-cube palette-chunk in true-color+alpha image
> ++        ps1n0g08    -   six-cube suggested palette (1 byte) in grayscale image
> ++        ps1n2c16    -   six-cube suggested palette (1 byte) in true-color image
> ++        ps2n0g08    -   six-cube suggested palette (2 bytes) in grayscale image
> ++        ps2n2c16    -   six-cube suggested palette (2 bytes) in true-color image
> ++
> ++
> ++3.9     Ancillary chunks test files
> ++-----------------------------------
> ++
> ++        cs5n2c08    -   color, 5 significant bits
> ++        cs8n2c08    -   color, 8 significant bits (reference)
> ++        cs3n2c16    -   color, 13 significant bits
> ++        cs3n3p08    -   paletted, 3 significant bits
> ++        cs5n3p08    -   paletted, 5 significant bits
> ++        cs8n3p08    -   paletted, 8 significant bits (reference)
> ++
> ++        cdfn2c08    -   physical pixel dimensions, 8x32 flat pixels
> ++        cdhn2c08    -   physical pixel dimensions, 32x8 high pixels
> ++        cdsn2c08    -   physical pixel dimensions, 8x8 square pixels
> ++        cdun2c08    -   physical pixel dimensions, 1000 pixels per 1 meter
> ++
> ++        ccwn2c08    -   chroma chunk w:0.3127,0.3290 r:0.64,0.33 g:0.30,0.60 b:0.15,0.06
> ++        ccwn3p08    -   chroma chunk w:0.3127,0.3290 r:0.64,0.33 g:0.30,0.60 b:0.15,0.06
> ++
> ++        ch1n3p04    -   histogram 15 colors
> ++        ch2n3p08    -   histogram 256 colors
> ++
> ++        cm7n0g04    -   modification time, 01-jan-1970 00:00:00
> ++        cm9n0g04    -   modification time, 31-dec-1999 23:59:59
> ++        cm0n0g04    -   modification time, 01-jan-2000 12:34:56
> ++
> ++        ct0n0g04    -   no textual data
> ++        ct1n0g04    -   with textual data
> ++        ctzn0g04    -   with compressed textual data
> ++
> ++
> ++
> ++3.10    Chunk ordering
> ++----------------------
> ++
> ++        oi1n0g16    -   grayscale mother image with 1 idat-chunk
> ++        oi2n0g16    -   grayscale image with 2 idat-chunks
> ++        oi4n0g16    -   grayscale image with 4 unequal sized idat-chunks
> ++        oi9n0g16    -   grayscale image with all idat-chunks length one
> ++        oi1n2c16    -   color mother image with 1 idat-chunk
> ++        oi2n2c16    -   color image with 2 idat-chunks
> ++        oi4n2c16    -   color image with 4 unequal sized idat-chunks
> ++        oi9n2c16    -   color image with all idat-chunks length one
> ++
> ++
> ++
> ++3.11    Compression level
> ++-------------------------
> ++
> ++        z00n2c08    -   color, no interlacing, compression level 0 (none)
> ++        z03n2c08    -   color, no interlacing, compression level 3
> ++        z06n2c08    -   color, no interlacing, compression level 6 (default)
> ++        z09n2c08    -   color, no interlacing, compression level 9 (maximum)
> ++
> ++
> ++
> ++3.12     Currupted files
> ++-----------------------
> ++
> ++        x00n0g01    -   empty 0x0 grayscale file
> ++        xcrn0g04    -   added cr bytes
> ++        xlfn0g04    -   added lf bytes
> ++        xc0n0c08    -   color type 0
> ++        xc9n0c08    -   color type 9
> ++        xd0n2c00    -   bit-depth 0
> ++        xd3n2c03    -   bit-depth 3
> ++        xd9n2c99    -   bit-depth 99
> ++        xcsn2c08    -   incorrect IDAT checksum
> ++
> ++
> ++--------
> ++    (c) Willem van Schaik
> ++        willem at schaik.com
> ++        Singapore, October 1996



-- 
Andrew :)

Free Java Software Engineer
Red Hat, Inc. (http://www.redhat.com)

Support Free Java!
Contribute to GNU Classpath and IcedTea
http://www.gnu.org/software/classpath
http://icedtea.classpath.org
PGP Key: 94EFD9D8 (http://subkeys.pgp.net)
Fingerprint = F8EF F1EA 401E 2E60 15FA  7927 142C 2591 94EF D9D8


From dlila at redhat.com  Mon Jan 31 15:32:32 2011
From: dlila at redhat.com (Denis Lila)
Date: Mon, 31 Jan 2011 18:32:32 -0500 (EST)
Subject: CubicCurve2D backports - review
In-Reply-To: <667167320.606502.1296516446494.JavaMail.root@zmail04.collab.prod.int.phx2.redhat.com>
Message-ID: <2067109601.606552.1296516752508.JavaMail.root@zmail04.collab.prod.int.phx2.redhat.com>

Hi.

I'd like to backport the three attached patches.


hg diff:

diff -r cd6310f10fab ChangeLog
--- a/ChangeLog	Sun Jan 30 00:45:18 2011 +0000
+++ b/ChangeLog	Mon Jan 31 13:28:19 2011 -0500
@@ -1,3 +1,11 @@
+2011-01-31  Denis Lila 
+
+	* NEWS: Update with the 3 backports
+	* Makefile.am (ICEDTEA_PATCHES): Add the patches
+	* patches/openjdk/4493128-CubicCurve2D.patch: New file.
+	* patches/openjdk/4645692-CubicCurve2D.solveCubic.patch: Likewise.
+	* patches/openjdk/4724552-CubicCurve2D.patch: Likewise.
+
 2011-01-29  Andrew John Hughes  
 
 	* patches/gcc-suffix.patch,
diff -r cd6310f10fab Makefile.am
--- a/Makefile.am	Sun Jan 30 00:45:18 2011 +0000
+++ b/Makefile.am	Mon Jan 31 13:28:19 2011 -0500
@@ -275,7 +275,10 @@
 	patches/jtreg-international-fonts-styles.patch \
 	patches/openjdk/6736649-text_bearings.patch \
 	patches/openjdk/6797139-jbutton_truncation.patch \
-	patches/openjdk/6883341-text_bearing_exception.patch
+	patches/openjdk/6883341-text_bearing_exception.patch \
+	patches/openjdk/4724552-CubicCurve2D.patch \
+	patches/openjdk/4493128-CubicCurve2D.patch \
+	patches/openjdk/4645692-CubicCurve2D.solveCubic.patch
 
 if !WITH_ALT_HSBUILD
 ICEDTEA_PATCHES += \
diff -r cd6310f10fab NEWS
--- a/NEWS	Sun Jan 30 00:45:18 2011 +0000
+++ b/NEWS	Mon Jan 31 13:28:19 2011 -0500
@@ -403,6 +403,9 @@
   - S6736649: test/closed/javax/swing/JMenuItem/6458123/ManualBug6458123.java fails on Linux
   - S6797139: JButton title is truncating for some strings irrespective of preferred size.
   - S6883341: SWAT: jdk7-b72 swat build(2009-09-17) threw exceptions when running Java2D demo by clicking Paint ta
+  - S4493128: CubicCurve2D intersects method fails
+  - S4724552: CubicCurve2D.contains(Rectangle2D) returns true when only partially contained.
+  - S4645692: solveCubic does not return all solutions.
 * Bug fixes
   - RH647157, RH582455: Update fontconfig files for rhel 6
   - RH661505: JPEGs with sRGB IEC61966-2.1 color profiles have wrong colors

...(and here should be the diff of the patches, but those are attached).

Thank you,
Denis.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 4493128-CubicCurve2D.patch
Type: text/x-patch
Size: 9745 bytes
Desc: not available
Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110131/60547535/4493128-CubicCurve2D.patch 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 4645692-CubicCurve2D.solveCubic.patch
Type: text/x-patch
Size: 22668 bytes
Desc: not available
Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110131/60547535/4645692-CubicCurve2D.solveCubic.patch 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 4724552-CubicCurve2D.patch
Type: text/x-patch
Size: 2343 bytes
Desc: not available
Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110131/60547535/4724552-CubicCurve2D.patch 

From denisl at openscg.com  Mon Jan 31 17:37:16 2011
From: denisl at openscg.com (Lussier, Denis)
Date: Mon, 31 Jan 2011 17:37:16 -0800
Subject: OpenSCG OpenJDK 6 Build 21 Plans
Message-ID: 

Thanks Andrew, the below is most helpful.   Seems like the right thing for
OpenSCG to do is to await IcedTea 1.10 for our cross-platform OpenJDK 6
Build 21 Linux installers.   We will also be integrating in VisualVM (via
the IcedTea Harness) & WebStart/Browser support (via IcedTea-Web).

In the meantime, I am working on getting VisualVM integrated into our Win32
and new Win64 installers.

--Luss
  http://openscg.org

PS  I still want to get IcedTea-Web working on Windoze, but as per the
above, I am learning to crawl before I try to run.  :-)


On Sat, Jan 29, 2011 at 5:18 PM, Dr Andrew John Hughes <
gnu_andrew at member.fsf.org> wrote:

>
> The stable 1.9 series uses b20 but includes many additional patches,
> including some items upstreamed in b21 and some which have yet to be
> upstreamed.
>
> Build 21 will be used by the upcoming 1.10 release which will happen
> in mid-February, but it will contain neither VisualVM nor the plugin
> and WebStart support.
>
> VisualVM support is in the separate VisualVM harness project and has
> been since IcedTea6 1.9.
>
> The plugin & NetX support will shortly appear in the first release of
> the IcedTea-Web project.
>
> See the IcedTea wiki for more details: http://icedtea.classpath.org/wiki
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20110131/3f1254f8/attachment.html