----
-
-diff --git a/eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT WebKit/gtk/org/eclipse/swt/browser/WebKit.java b/eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT WebKit/gtk/org/eclipse/swt/browser/WebKit.java
-index f987f90..8ee66d8 100644
---- "a/eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT WebKit/gtk/org/eclipse/swt/browser/WebKit.java"
-+++ "b/eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT WebKit/gtk/org/eclipse/swt/browser/WebKit.java"
-@@ -1758,17 +1758,16 @@
- OS.g_error_free(gerrorRes[0]);
- retObj.returnValue = (String) "";
- } else {
-- long /*int*/ GString;
-- GString = OS.g_string_new_len(guchar_data, gsize_len[0]); //(Str + len) -> (null terminated str)
-- String text = Converter.cCharPtrToJavaString(OS.GString_str(GString), false);
-- OS.g_string_free(GString, 1);
-- retObj.returnValue = (String) text;
-+ int len = (int) gsize_len[0];
-+ byte[] buffer = new byte [len];
-+ C.memmove (buffer, guchar_data, len);
-+ String text = Converter.byteToStringViaHeuristic(buffer);
-+ retObj.returnValue = text;
- }
-
- retObj.callbackFinished = true;
- Display.getCurrent().wake();
- }
--
- /**
- * You should check 'retObj.swtAsyncTimeout' after making a call to this.
- */
-diff --git a/eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/internal/Converter.java b/eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/internal/Converter.java
-index d0ca067..1e5c67e 100644
---- "a/eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/internal/Converter.java"
-+++ "b/eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/internal/Converter.java"
-@@ -11,33 +11,105 @@
- package org.eclipse.swt.internal;
-
-
-+import java.io.*;
-+import java.nio.*;
-+import java.nio.charset.*;
-+
- import org.eclipse.swt.internal.gtk.*;
-
- /**
-+ * About this class:
-+ * #################
- * This class implements the conversions between unicode characters
-- * and the platform supported representation for characters.
-- *
-+ * and the platform supported representation for characters.
-+ *
- * Note that, unicode characters which can not be found in the platform
- * encoding will be converted to an arbitrary platform specific character.
- *
-- * Note:
-- * Regular JNI String conversion usually uses a modified UTF-8, see:
-- * https://en.wikipedia.org/wiki/UTF-8#Modified_UTF-8
-- * And in JNI, normally (env*)->GetStringUTFChars(..) is used to convert a javaString into a C string. See:
-- * http://docs.oracle.com/javase/8/docs/technotes/guides/jni/spec/functions.html#GetStringUTFChars
-+ * This class is tested via: org.eclipse.swt.tests.gtk.Test_GtkTextEncoding
-+ *
-+ * About JNI & string conversion:
-+ * #############################
-+ * - Regular JNI String conversion usually uses a modified UTF-8, see: https://en.wikipedia.org/wiki/UTF-8#Modified_UTF-8
-+ * - And in JNI, normally (env*)->GetStringUTFChars(..) is used to convert a javaString into a C string.
-+ * See: http://docs.oracle.com/javase/8/docs/technotes/guides/jni/spec/functions.html#GetStringUTFChars
-+ *
- * However, the modified UTF-8 only works well with C system functions as it doesn't contain embedded nulls
- * and is null terminated.
-+ *
- * But because the modified UTF-8 only supports up to 3 bytes (and not up to 4 as regular UTF-8), characters
- * that require 4 bytes (e.g emojos) are not translated properly from Java to C.
-- * To work around this issue, we convert the Java string to a byte array on the Java side manually and then
-- * pass it to C. See:
-- * http://stackoverflow.com/questions/32205446/getting-true-utf-8-characters-in-java-jni
-+ *
-+ * To work around this issue, we convert the Java string to a byte array on the Java side manually and then pass it to C.
-+ * See: http://stackoverflow.com/questions/32205446/getting-true-utf-8-characters-in-java-jni
- *
- * Note:
- * Java uses UTF-16 Wide characters internally to represent a string.
- * C uses UTF-8 Multibyte characters (null terminated) to represent a string.
- *
-- *
-+ * About encoding on Linux/Gtk & it's relevance to SWT:
-+ * ####################################################
-+ *
-+ * UTF-* = variable length encoding.
-+ *
-+ * UTF-8 = minimum is 8 bits, max is 6 bytes, but rarely goes beyond 4 bytes. Gtk & most of web uses this.
-+ * UTF-16 = minimum is 16 bits. Java's string are stored this way.
-+ * UTF-16 can be
-+ * Big Endian : 65 = 00000000 01000001 # Human friendly, reads left to right.
-+ * Little Endian : 65 = 01000001 00000000 # Intel x86 and also AMD64 / x86-64 series of processors use the little-endian [1]
-+ * # i.e, we in SWT often have to deal with UTF-16 LE
-+ * Some terminology:
-+ * - "Code point" is the numerical value of unicode character.
-+ * - All of UTF-* have the same letter to code-point mapping,
-+ * but UTF-8/16/32 have different "back-ends".
-+ *
-+ * Illustration:
-+ * (char) = (code point) = (back end).
-+ * A = 65 = 01000001 UTF-8
-+ * = 00000000 01000001 UTF-16 BE
-+ * = 01000001 00000000 UTF-16 LE
-+ *
-+ * - Byte Order Marks (BOM) are a few bytes at the start of a *file* indicating which endianess is used.
-+ * Problem: Gtk/webkit often don't give us BOM's.
-+ * (further reading *3)
-+ *
-+ * - We can reliably encode character to a backend (A -> UTF-8/16), but the other way round is
-+ * guess work since byte order marks are often missing and UTF-16 bits are technically valid UTF-8.
-+ * (see Converter.heuristic for details).
-+ * We could improve our heuristic by using something like http://jchardet.sourceforge.net/.
-+ *
-+ * - Glib has some conversion functions:
-+ * g_utf16_to_utf8
-+ * g_utf8_to_utf16
-+ *
-+ * - So does java: (e.g null terminated UTF-8)
-+ * ("myString" + '\0').getBytes(StandardCharsets.UTF-8)
-+ *
-+ * - I suggest using Java functions where possible to avoid memory leaks.
-+ * (Yes, they happen and are big-pain-in-the-ass to find https://bugs.eclipse.org/bugs/show_bug.cgi?id=533995)
-+ *
-+ *
-+ * Learning about encoding:
-+ * #########################
-+ * I suggest the following 3 videos to understand ASCII/UTF-8/UTF-16[LE|BE]/UTF-32 encoding:
-+ * Overview: https://www.youtube.com/watch?v=MijmeoH9LT4
-+ * Details:
-+ * Part-1: https://www.youtube.com/watch?v=B1Sf1IhA0j4
-+ * Part-2: https://www.youtube.com/watch?v=-oYfv794R9s
-+ * Part-3: https://www.youtube.com/watch?v=vLBtrd9Ar28
-+ *
-+ * Also read all of this:
-+ * http://kunststube.net/encoding/
-+ * and this:
-+ * https://www.joelonsoftware.com/2003/10/08/the-absolute-minimum-every-software-developer-absolutely-positively-must-know-about-unicode-and-character-sets-no-excuses/
-+ *
-+ * And lastly, good utf-8 reference: https://en.wikipedia.org/wiki/UTF-8#Description
-+ *
-+ * You should now be a master of encoding. I wish you luck on your journey.
-+ *
-+ * [1] https://en.wikipedia.org/wiki/Endianness
-+ * [2] https://en.wikipedia.org/wiki/Byte_order_mark
-+ * [3] BOM's: http://unicode.org/faq/utf_bom.html#BOM
- */
- public final class Converter {
- public static final byte [] NullByteArray = new byte [1];
-@@ -182,4 +254,127 @@
- return result [0];
- }
-
-+/**
-+ * Given a byte array with unknown encoding, try to decode it via (relatively simple) heuristic.
-+ * This is useful when we're not provided the encoding by OS/library.
-+ *
-+ * Current implementation only supports standard java charsets but can be extended as needed.
-+ * This method could be improved by using http://jchardet.sourceforge.net/
-+ *
-+ * Run time is O(a * n) where a is a constant that varies depending on the size of input n, but roughly 1-20)
-+ *
-+ * @param bytes raw bits from the OS.
-+ * @return String based on the most pop
-+ */
-+public static String byteToStringViaHeuristic(byte [] bytes) {
-+ /*
-+ * Technical notes:
-+ * - Given a sequence of bytes, UTF-8 and UTF-16 cannot determined deterministically (1*).
-+ * - However, UTF-16 has a lot of null bytes when code points are mostly in the 0-255 range (using only 2nd byte),
-+ * a byte sequence with many null bytes is likely UTF-16.
-+ * - Valid UTF-8 technically can contain null bytes, but it's rare.
-+ *
-+ * Some times it can get confused if it receives two non-null bytes. e.g Ё = (UTF-16 [01,04])
-+ * It can either mean a valid set of UTF-8 characters or a single UTF-16 character.
-+ * This issue typically only occurs for very short sequences 1-5 characters of very special characters).
-+ * Improving the heuristic for such corner cases is complicated. We'd have to implement a mechanism
-+ * that would be aware of character frequencies and assign a score to the probability of each mapping.
-+ *
-+ * [1] https://softwareengineering.stackexchange.com/questions/187169/how-to-detect-the-encoding-of-a-file
-+ */
-+ // Base cases
-+ if ((bytes.length == 0) ||
-+ (bytes.length == 1 && bytes[0] == 0)) {
-+ return "";
-+ }
-+
-+ // Test if it's valid UTF-8.
-+ // Note, ASCII is a subset of UTF-8.
-+ try {
-+ CharsetDecoder charDecoder = StandardCharsets.UTF_8.newDecoder();
-+ charDecoder.onMalformedInput(CodingErrorAction.REPORT);
-+ charDecoder.onUnmappableCharacter(CodingErrorAction.REPORT);
-+ String text = charDecoder.decode(ByteBuffer.wrap(bytes)).toString();
-+
-+ // No exception thrown means that we have valid UTF-8 "bit string". However, valid UTF-8 bit string doesn't mean it's the corect decoding.
-+ // We have assert correctness via an educated guess
-+ boolean probablyUTF8 = true;
-+
-+ {
-+ // Problem 1: It might be UTF-16 since at the binary level UTF-16 can be valid UTF-8. (null is a valid utf-8 character).
-+ // Solution: Count nulls to try to guess if it's UTF-16.
-+ // Verified via
-+ // org.eclipse.swt.tests.gtk.Test_GtkConverter.test_HeuristicUTF16_letters()
-+ // org.eclipse.swt.tests.gtk.Test_GtkConverter.test_HeuristicUTF16_letter()
-+ double nullBytePercentageForUtf16 = 0.01; // if more than this % null bytes, then it's probably utf-16.
-+ int nullCount = 0;
-+ for (byte b : bytes) {
-+ if (b == 0)
-+ nullCount++;
-+ }
-+ double nullPercentage = (double) nullCount / (double) bytes.length;
-+ if (nullPercentage > nullBytePercentageForUtf16) {
-+ probablyUTF8 = false;
-+ }
-+ }
-+
-+ // Problem 2: Valid UTF-8 bit string can map to invalid code points (i.e undefined unicode)
-+ // Solution 2: verify that every character is a valid code point.
-+ if (probablyUTF8) {
-+ char [] chars = text.toCharArray();
-+
-+ for (int i = 0; i < chars.length; i++) {
-+ int codePoint = Character.codePointAt(chars, i);
-+ if (!Character.isValidCodePoint(codePoint)) {
-+ probablyUTF8 = false;
-+ break;
-+ }
-+ }
-+ }
-+
-+ // Problem 3: Short 2-byte sequences are very ambiguous.
-+ // E.g Unicode Hyphen U+2010 '‐' ( which btw different from the ascii U+002D '-' Hyphen-Minus)
-+ // can be miss-understood as 16 (Synchronous Idle) & 32 (Space).
-+ // Solution: Unless we have two valid alphabet characters, it's probably a single utf-16 character.
-+ // However, this leads to the problem that single non-alphabetic unicode characters are not recognized correctly.
-+ // Below code is left in case recognizing alphabetic characters is of higher priority than exotic unicode once.
-+// if (probablyUTF8) {
-+// if (bytes.length == 2) {
-+// char [] chars = text.toCharArray();
-+// for (int i = 0; i < chars.length; i++) {
-+// int codePoint = Character.codePointAt(chars, i);
-+// if (!Character.isAlphabetic(codePoint)) {
-+// probablyUTF8 = false;
-+// break;
-+// }
-+// }
-+// }
-+// }
-+
-+ if (!probablyUTF8) {
-+ return new String (bytes, StandardCharsets.UTF_16LE);
-+ } else {
-+ return text;
-+ }
-+ } catch (CharacterCodingException e) {
-+ }
-+
-+ // Invalid UTF-8. Try other character sets.
-+ Charset [] commonWebCharSets = new Charset[] {StandardCharsets.UTF_16LE, StandardCharsets.ISO_8859_1, StandardCharsets.UTF_16BE, StandardCharsets.UTF_16};
-+ for (Charset setToTry : commonWebCharSets) {
-+ try {
-+ CharsetDecoder charDecoder = setToTry.newDecoder();
-+ charDecoder.onMalformedInput(CodingErrorAction.REPORT);
-+ charDecoder.onUnmappableCharacter(CodingErrorAction.REPORT);
-+ return charDecoder.decode(ByteBuffer.wrap(bytes)).toString();
-+ } catch (CharacterCodingException e) {}
-+ }
-+
-+ // Could not determine encoding.
-+ // Return error string with stack trace to help users determine which function lead to a failed decoding.
-+ StringWriter sw = new StringWriter();
-+ new Throwable("").printStackTrace(new PrintWriter(sw));
-+ return "SWT: Failed to decode byte buffer. Encoding is not ASCII/UTF-8/UTF-16[LE|BE|BOM]/ISO_8859_1. Stack trace:\n" + sw.toString();
-+}
-+
- }
-diff --git a/eclipse.platform.swt/tests/org.eclipse.swt.tests.gtk/JUnit Tests/org/eclipse/swt/tests/gtk/AllGTKTests.java b/eclipse.platform.swt/tests/org.eclipse.swt.tests.gtk/JUnit Tests/org/eclipse/swt/tests/gtk/AllGTKTests.java
-index 73fb65a..6be5e22 100644
---- "a/eclipse.platform.swt/tests/org.eclipse.swt.tests.gtk/JUnit Tests/org/eclipse/swt/tests/gtk/AllGTKTests.java"
-+++ "b/eclipse.platform.swt/tests/org.eclipse.swt.tests.gtk/JUnit Tests/org/eclipse/swt/tests/gtk/AllGTKTests.java"
-@@ -14,6 +14,7 @@
- */
- package org.eclipse.swt.tests.gtk;
-
-+import org.junit.runner.JUnitCore;
- import org.junit.runner.RunWith;
- import org.junit.runners.Suite;
-
-@@ -21,12 +22,13 @@
- @RunWith(Suite.class)
- @Suite.SuiteClasses({
- // Test.class be added here.
-+ Test_GtkConverter.class
- })
-
- public class AllGTKTests {
-
- public static void main(String[] args) {
--// JUnitCore.main(AllGTKTests.class.getName()); // Enable once a test is added.
-+ JUnitCore.main(AllGTKTests.class.getName()); // Enable once a test is added.
- }
-
- }
-diff --git a/eclipse.platform.swt/tests/org.eclipse.swt.tests.gtk/JUnit Tests/org/eclipse/swt/tests/gtk/Test_GtkConverter.java b/eclipse.platform.swt/tests/org.eclipse.swt.tests.gtk/JUnit Tests/org/eclipse/swt/tests/gtk/Test_GtkConverter.java
-new file mode 100644
-index 0000000..509ec2a
---- /dev/null
-+++ "b/eclipse.platform.swt/tests/org.eclipse.swt.tests.gtk/JUnit Tests/org/eclipse/swt/tests/gtk/Test_GtkConverter.java"
-@@ -0,0 +1,146 @@
-+package org.eclipse.swt.tests.gtk;
-+
-+import static org.junit.Assert.fail;
-+
-+import java.nio.charset.StandardCharsets;
-+
-+import org.eclipse.swt.internal.Converter;
-+import org.junit.Ignore;
-+import org.junit.Test;
-+
-+/**
-+ * Good source for UTF-8 code points for testing:
-+ * https://en.wikipedia.org/wiki/List_of_Unicode_characters
-+ *
-+ * We care about Ascii, UTF-8 (as it's used by glib/gtk much) and UTF-16LE (as it's used by java/intel/amd architecture).
-+ */
-+public class Test_GtkConverter {
-+
-+ static final String emptyStr = "";
-+
-+ static final String asciiLetterA = "A"; // = 65 // Note, UTF-8 is backwards compatible with Ascii
-+ static final String dollarSign = "$"; // =36
-+
-+ static final String asciiLetters = "ABCabc"; // 65(A), 66, 67 97(a), 98, 99
-+
-+ // Anything above 127 translates to 2 bytes in utf-8. See: https://en.wikipedia.org/wiki/UTF-8#Description
-+ static final String codePoint174 = "®"; // U+00AE Registered sign.
-+ static final String unicodeCharactersLowCodePoints = "®ÖöėŊ‐"; // bigger than 127, but not many bytes.
-+ static final String unicodeCharactersHighCodePoints = "▇░▙▚▧▫♂☢⛔"; //2000+ code points.
-+
-+ @Test
-+ public void test_HeuristicASCII_letterA() {
-+ helper_testHeuristic(asciiLetterA.getBytes(StandardCharsets.US_ASCII), asciiLetterA); // A = 65
-+ }
-+ @Test
-+ public void test_HeuristicASCII_dollarSign() {
-+ helper_testHeuristic(dollarSign.getBytes(StandardCharsets.US_ASCII), dollarSign); // $ = 36
-+ }
-+
-+ @Test
-+ public void test_Heuristic_null() {
-+ helper_testHeuristic(new byte[] {0}, emptyStr); // simulate null terminator.
-+ }
-+
-+ @Test
-+ public void test_HeuristicASCII_emptyString() {
-+ helper_testHeuristic(emptyStr.getBytes(StandardCharsets.US_ASCII), emptyStr); // "" -> [] (empty byte array)
-+ }
-+
-+ @Test
-+ public void test_HeuristicUTF8_null() {
-+ helper_testHeuristic(emptyStr.getBytes(StandardCharsets.UTF_8), emptyStr);
-+ }
-+
-+ @Test
-+ public void test_HeuristicUTF16LE_null() {
-+ helper_testHeuristic(emptyStr.getBytes(StandardCharsets.UTF_16LE), emptyStr);
-+ }
-+
-+ @Test
-+ public void test_HeuristicASCII_letters() {
-+ helper_testHeuristic(asciiLetters.getBytes(StandardCharsets.US_ASCII), asciiLetters);
-+ }
-+
-+ @Test
-+ public void test_HeuristicUTF8_letterUnder127() {
-+ helper_testHeuristic(asciiLetterA.getBytes(StandardCharsets.UTF_8), asciiLetterA);
-+ }
-+
-+ @Test
-+ public void test_HeuristicUTF8_letterOver127() {
-+ helper_testHeuristic(codePoint174.getBytes(StandardCharsets.UTF_8), codePoint174);
-+ }
-+
-+
-+ @Test
-+ public void test_HeuristicUTF8_letterSpecial() {
-+ helper_testHeuristic("Ё".getBytes(StandardCharsets.UTF_8), "Ё");
-+ }
-+
-+ @Test
-+ public void test_HeuristicUTF8_LowCodePoints() {
-+ helper_testHeuristic(unicodeCharactersLowCodePoints.getBytes(StandardCharsets.UTF_8), unicodeCharactersLowCodePoints);
-+ }
-+
-+ @Test
-+ public void test_HeuristicUTF8_HighCodePoints() {
-+ byte [] testBytes = unicodeCharactersHighCodePoints.getBytes(StandardCharsets.UTF_8);
-+ helper_testHeuristic(testBytes, unicodeCharactersHighCodePoints);
-+ }
-+
-+
-+ @Test
-+ public void test_HeuristicUTF16_Asciiletter() {
-+ helper_testHeuristic(asciiLetterA.getBytes(StandardCharsets.UTF_16LE), asciiLetterA);
-+ }
-+
-+ @Test
-+ public void test_HeuristicUTF16_AsciiLetters() {
-+ helper_testHeuristic(asciiLetters.getBytes(StandardCharsets.UTF_16LE), asciiLetters);
-+ }
-+
-+ @Test
-+ public void test_HeuristicUTF16_letter() {
-+ String testValue = "®"; // 174
-+ byte [] testBytes = testValue.getBytes(StandardCharsets.UTF_16LE);
-+ helper_testHeuristic(testBytes, testValue);
-+ }
-+
-+ @Test
-+ public void test_HeuristicUTF16_letters() {
-+ helper_testHeuristic(unicodeCharactersLowCodePoints.getBytes(StandardCharsets.UTF_16LE), unicodeCharactersLowCodePoints);
-+ }
-+
-+ @Test
-+ public void test_HeuristicUTF16_LotsOfLetters() {
-+ byte [] testBytes = unicodeCharactersHighCodePoints.getBytes(StandardCharsets.UTF_16LE);
-+ helper_testHeuristic(testBytes, unicodeCharactersHighCodePoints);
-+ }
-+
-+ /**
-+ * There are a few unicode characters that are ambiguous if they are decoded on their own,
-+ * as they can translate to either two valid UTF-8 characters or a single valid UTF-16LE character.
-+ *
-+ * e.g 'Ё'. (but there are others).
-+ *
-+ * The heuristic is better is better if there are 2+ characters, e.g HЁLLO WORLD.
-+ *
-+ * This test is documented, but is currently known to fail.
-+ *
-+ */
-+ @Ignore
-+ @Test
-+ public void test_Heuristic_specialSingleCases() {
-+ byte [] testBytes = "Ё".getBytes(StandardCharsets.UTF_16LE);
-+ helper_testHeuristic(testBytes, "Ё");
-+ }
-+
-+ private void helper_testHeuristic(byte[] testBytes, String expected) {
-+ String result = Converter.byteToStringViaHeuristic(testBytes);
-+ if (!expected.equals(result)) {
-+ fail();
-+ }
-+ }
-+
-+}
-diff --git a/eclipse.platform.swt/tests/org.eclipse.swt.tests.gtk/ManualTests/org/eclipse/swt/tests/gtk/snippets/Bug535392_getText.java b/eclipse.platform.swt/tests/org.eclipse.swt.tests.gtk/ManualTests/org/eclipse/swt/tests/gtk/snippets/Bug535392_getText.java
-new file mode 100644
-index 0000000..4275991
---- /dev/null
-+++ "b/eclipse.platform.swt/tests/org.eclipse.swt.tests.gtk/ManualTests/org/eclipse/swt/tests/gtk/snippets/Bug535392_getText.java"
-@@ -0,0 +1,109 @@
-+package org.eclipse.swt.tests.gtk.snippets;
-+
-+import java.util.concurrent.atomic.AtomicBoolean;
-+
-+import org.eclipse.swt.SWT;
-+import org.eclipse.swt.browser.Browser;
-+import org.eclipse.swt.browser.ProgressAdapter;
-+import org.eclipse.swt.browser.ProgressEvent;
-+import org.eclipse.swt.layout.GridData;
-+import org.eclipse.swt.layout.GridLayout;
-+import org.eclipse.swt.widgets.Display;
-+import org.eclipse.swt.widgets.Shell;
-+
-+
-+public class Bug535392_getText {
-+ static int run = 1;
-+ public static void main(String[] args) {
-+ Display display = new Display();
-+ Shell shell = new Shell(display);
-+ shell.setSize(400, 400);
-+ shell.setLayout(new GridLayout(2, false));
-+ Browser browser = new Browser(shell, SWT.BORDER);
-+ browser.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true, 2, 1));
-+ shell.open();
-+
-+ // Most of below work, but a few single unicode characters are miss-understood. Heuristic works better with many characters.
-+ // https://en.wikipedia.org/wiki/List_of_Unicode_characters
-+ testValue(display, shell, browser, "-", true); // working, regular ascii '-'
-+ testValue(display, shell, browser, "‐", true); // BROKEN, (single char read as UTF-8 instead of UTF-16).
-+ testValue(display, shell, browser, "ABC", true); // 65 66 67
-+ testValue(display, shell, browser, "A®A", true); // U+00AE ® 0174 ® Registered sign 0110
-+ testValue(display, shell, browser, "A¢A", true); // U+00BF ¿ 0191 ¿ Inverted Question Mark 0127
-+ testValue(display, shell, browser, "ABCüDü", true); // U+00FC ü 0252 ü Latin Small Letter U with diaeresis 0188
-+ testValue(display, shell, browser, "AӛB", true); // U+04DB ӛ Cyrillic Small Letter Schwa with diaeresis 0620
-+ testValue(display, shell, browser, "Ё", true); // BROKEN. (single char read as UTF-8 instead of UTF-16). U+04DB ӛ Cyrillic Small Letter Schwa with diaeresis 0620
-+
-+ if (run == 0) {
-+ for (int i = 0; i < 100000; i++) {
-+ final String testStr = new String(new char [] {'A', (char) i});
-+ testValue(display, shell, browser, testStr, i, true);
-+
-+ }
-+ }
-+
-+ testValue(display, shell, browser, "SYNOPSIS\n" +
-+ " find [-H] [-L] [-P] [-D debugopts] [-Olevel] [starting-point...] [expression]\n" +
-+ "\n" +
-+ "DESCRIPTION\n" +
-+ " This manual page documents the GNU version of find. GNU find searches the directory tree rooted at each given starting-point by evaluating the given expression from left to right, according to the rules of precedence (see sec‐\n" +
-+ " tion OPERATORS), until the outcome is known (the left hand side is false for and operations, true for or), at which point find moves on to the next file name. If no starting-point is specified, `.' is assumed.\n" +
-+ "\n" +
-+ " If you are using find in an environment where security is important (for example if you are using it to search directories that are writable by other users), you should read the \"Security Considerations\" chapter of the findu‐\n" +
-+ " tils documentation, which is called Finding Files and comes with findutils. That document also includes a lot more detail and discussion than this manual page, so you may find it a more useful source of information.\n" +
-+ "\n" +
-+ "OPTIONS\n" +
-+ " The -H, -L and -P options control the treatment of symbolic links. Command-line arguments following these are taken to be names of files or directories to be examined, up to the first argument that begins with `-', or the\n" +
-+ " argument `(' or `!'. That argument and any following arguments are taken to be the expression describing what is to be searched for. If no paths are given, the current directory is used. If no expression is given, the\n" +
-+ " expression -print is used (but you should probably consider using -print0 instead, anyway).\n" +
-+ "\n" +
-+ " This manual page talks about `options' within the expression list. These options control the behaviour of find but are specified immediately after the last path name. The five `real' options -H, -L, -P, -D and -O must appear\n" +
-+ " before the first path name, if at all. A double dash -- can also be used to signal that any remaining arguments are not options (though ensuring that all start points begin with either `./' or `/' is generally safer if you use\n" +
-+ " wildcards in the list of start points).", true);
-+
-+
-+
-+
-+ display.dispose();
-+ }
-+
-+
-+ private static void testValue(Display display, Shell shell, Browser browser, String testStr, boolean autoTest) {
-+ testValue(display, shell, browser, testStr, 0, autoTest);
-+ }
-+
-+ // I think this is broken for values above 127 :-/.
-+ private static void testValue(Display display, Shell shell, Browser browser, String testStr, int testID, boolean autoTest) {
-+ AtomicBoolean testFinished = new AtomicBoolean(false);
-+ browser.setText(testStr);
-+
-+ ProgressAdapter completionTester = new ProgressAdapter() {
-+ @Override
-+ public void completed(ProgressEvent event) {
-+ Browser browser = (Browser) event.widget;
-+ String returnedStr = browser.getText();
-+ if (testStr.equals(returnedStr)) {
-+ System.out.println("(PASS): testStr/returnedStr: " + testStr + "/" + returnedStr + " Test id:" + testID);
-+ } else {
-+ System.err.println("(FAIL): testStr/returnedStr: " + testStr + "/" + returnedStr + " Test id:" + testID);
-+ }
-+ testFinished.set(true);
-+ }
-+ };
-+
-+ browser.addProgressListener(completionTester);
-+
-+ if (autoTest) {
-+ while (!shell.isDisposed() && !testFinished.get()) {
-+ display.readAndDispatch();
-+ }
-+ browser.removeProgressListener(completionTester);
-+ } else {
-+ while (!shell.isDisposed()) {
-+ if (!display.readAndDispatch()) {
-+ display.sleep();
-+ }
-+ }
-+ }
-+ }
-+}
diff --git a/eclipse-debug-symbols.patch b/eclipse-debug-symbols.patch
index f1259a6..ab7d324 100644
--- a/eclipse-debug-symbols.patch
+++ b/eclipse-debug-symbols.patch
@@ -1,29 +1,15 @@
---- eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/make_linux.mak.orig 2014-03-12 10:43:26.000000000 +0000
-+++ eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/make_linux.mak 2014-03-12 14:36:44.130938292 +0000
-@@ -98,7 +98,7 @@
- WEBKIT_OBJECTS = swt.o webkitgtk.o webkitgtk_structs.o webkitgtk_stats.o webkitgtk_custom.o
- GLX_OBJECTS = swt.o glx.o glx_structs.o glx_stats.o
+--- eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/build.sh.orig 2018-08-19 12:37:52.764590467 +0100
++++ eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT PI/gtk/library/build.sh 2018-08-19 12:38:15.032503913 +0100
+@@ -72,7 +72,8 @@
--CFLAGS = -O -Wall \
-+CFLAGS = -g -O -Wall \
- -DSWT_VERSION=$(SWT_VERSION) \
- $(NATIVE_STATS) \
- $(SWT_DEBUG) \
-@@ -110,14 +110,6 @@
- ${SWT_PTR_CFLAGS}
- LFLAGS = -shared -fPIC ${SWT_LFLAGS}
+ MAKE_TYPE=make
--ifndef NO_STRIP
-- # -s = Remove all symbol table and relocation information from the executable.
-- # i.e, more efficent code, but removes debug information. Should not be used if you want to debug.
-- # https://gcc.gnu.org/onlinedocs/gcc/Link-Options.html#Link-Options
-- # http://stackoverflow.com/questions/14175040/effects-of-removing-all-symbol-table-and-relocation-information-from-an-executab
-- AWT_LFLAGS := $(AWT_LFLAGS) -s
-- LFLAGS := $(LFLAGS) -s
--endif
-
- all: make_swt make_atk make_glx make_webkit
+-export CFLAGS='-O -Wall -fPIC'
++export CFLAGS='-O -g -Wall -fPIC'
++export NO_STRIP=1
+ # Determine which OS we are on
+ if [ "${OS}" = "" ]; then
--- rt.equinox.framework/features/org.eclipse.equinox.executable.feature/library/gtk/make_linux.mak.orig 2014-03-12 14:47:37.513191381 +0000
+++ rt.equinox.framework/features/org.eclipse.equinox.executable.feature/library/gtk/make_linux.mak 2014-03-12 14:47:45.672200015 +0000
@@ -91,7 +91,7 @@
diff --git a/eclipse-disable-droplets-in-dropins.patch b/eclipse-disable-droplets-in-dropins.patch
index 83eca56..72336e1 100644
--- a/eclipse-disable-droplets-in-dropins.patch
+++ b/eclipse-disable-droplets-in-dropins.patch
@@ -17,7 +17,7 @@ diff --git rt.equinox.p2/bundles/org.eclipse.equinox.p2.reconciler.dropins/src/o
index 802ee1b..74023fe 100644
--- rt.equinox.p2/bundles/org.eclipse.equinox.p2.reconciler.dropins/src/org/eclipse/equinox/internal/p2/reconciler/dropins/PlatformXmlListener.java
+++ rt.equinox.p2/bundles/org.eclipse.equinox.p2.reconciler.dropins/src/org/eclipse/equinox/internal/p2/reconciler/dropins/PlatformXmlListener.java
-@@ -182,11 +182,24 @@ public class PlatformXmlListener extends DirectoryChangeListener {
+@@ -168,11 +168,24 @@ public class PlatformXmlListener extends DirectoryChangeListener {
* Ensure that we have a repository for each site in the given configuration.
*/
protected void synchronizeConfiguration(Configuration config) {
diff --git a/eclipse-feature-plugins-to-category-ius.patch b/eclipse-feature-plugins-to-category-ius.patch
index f422be4..817ade0 100644
--- a/eclipse-feature-plugins-to-category-ius.patch
+++ b/eclipse-feature-plugins-to-category-ius.patch
@@ -1,7 +1,5 @@
-diff --git eclipse.jdt/org.eclipse.jdt-feature/feature.xml eclipse.jdt/org.eclipse.jdt-feature/feature.xml
-index 0743586..1cbf404 100644
---- eclipse.jdt/org.eclipse.jdt-feature/feature.xml
-+++ eclipse.jdt/org.eclipse.jdt-feature/feature.xml
+--- eclipse.jdt/org.eclipse.jdt-feature/feature.xml.orig 2018-08-17 01:24:16.000000000 +0100
++++ eclipse.jdt/org.eclipse.jdt-feature/feature.xml 2018-08-19 12:50:33.575708475 +0100
@@ -19,6 +19,23 @@
%license
@@ -26,10 +24,13 @@ index 0743586..1cbf404 100644
-
-
+-
+-
--
+-
-
--
--
+
+
-
+
+
+
@@ -315,8 +311,8 @@ index 88a8daa..382c5ee 100644
+
+
---- eclipse.platform.ui/features/org.eclipse.e4.rcp/feature.xml.orig 2017-01-13 11:29:16.362473652 +0000
-+++ eclipse.platform.ui/features/org.eclipse.e4.rcp/feature.xml 2017-01-13 11:29:16.371473551 +0000
+--- eclipse.platform.ui/features/org.eclipse.e4.rcp/feature.xml.orig 2018-08-19 13:57:13.249904259 +0100
++++ eclipse.platform.ui/features/org.eclipse.e4.rcp/feature.xml 2018-08-19 14:03:19.527742984 +0100
@@ -22,6 +22,22 @@
@@ -403,23 +399,16 @@ index 88a8daa..382c5ee 100644
id="org.eclipse.e4.core.di"
download-size="0"
install-size="0"
-@@ -165,41 +125,6 @@
+@@ -172,34 +132,6 @@
unpack="false"/>
--
--
--
+-
-
eclipse-plugin
@@ -531,7 +520,7 @@ index 88a8daa..382c5ee 100644
0.0.0
-@@ -76,7 +71,7 @@
+@@ -75,7 +70,7 @@
eclipse-plugin
@@ -540,7 +529,7 @@ index 88a8daa..382c5ee 100644
0.0.0
-@@ -96,7 +91,7 @@
+@@ -95,7 +90,7 @@
eclipse-plugin
diff --git a/eclipse-mockito.patch b/eclipse-mockito.patch
index 30a3d7e..b484ea6 100644
--- a/eclipse-mockito.patch
+++ b/eclipse-mockito.patch
@@ -49,3 +49,22 @@
download-size="0"
install-size="0"
version="0.0.0"
+--- eclipse.jdt.debug/org.eclipse.jdt.debug.tests/META-INF/MANIFEST.MF.orig 2018-08-20 12:54:25.245305107 +0100
++++ eclipse.jdt.debug/org.eclipse.jdt.debug.tests/META-INF/MANIFEST.MF 2018-08-20 12:54:37.952261537 +0100
+@@ -33,6 +33,7 @@
+ org.eclipse.ui.workbench.texteditor;resolution:=optional,
+ org.eclipse.ui.editors;resolution:=optional,
+ org.junit,
++ org.hamcrest.core,
+ org.eclipse.core.resources,
+ org.eclipse.core.variables,
+ org.eclipse.ui,
+--- ./eclipse.platform.ui/tests/org.eclipse.tests.urischeme/META-INF/MANIFEST.MF.orig 2018-08-20 13:22:04.987695821 +0100
++++ ./eclipse.platform.ui/tests/org.eclipse.tests.urischeme/META-INF/MANIFEST.MF 2018-08-20 13:22:28.507613518 +0100
+@@ -7,4 +7,5 @@
+ Fragment-Host: org.eclipse.urischeme;bundle-version="1.0.0"
+ Automatic-Module-Name: org.eclipse.urischeme.tests
+ Bundle-RequiredExecutionEnvironment: JavaSE-1.8
+-Require-Bundle: org.junit;bundle-version="[4.12.0,5.0.0)"
++Require-Bundle: org.junit;bundle-version="[4.12.0,5.0.0)",
++ org.hamcrest.core;bundle-version="1.3.0"
diff --git a/eclipse-no-source-for-dependencies.patch b/eclipse-no-source-for-dependencies.patch
index 3666fe3..54451f8 100644
--- a/eclipse-no-source-for-dependencies.patch
+++ b/eclipse-no-source-for-dependencies.patch
@@ -70,7 +70,7 @@
--- eclipse.platform.releng/features/org.eclipse.platform-feature/pom.xml.orig 2014-11-28 15:27:07.874872769 +0000
+++ eclipse.platform.releng/features/org.eclipse.platform-feature/pom.xml 2014-11-28 15:31:02.592652099 +0000
-@@ -72,6 +72,8 @@
+@@ -68,6 +68,8 @@
@@ -81,7 +81,7 @@
--- eclipse.platform.ui/features/org.eclipse.e4.rcp/pom.xml.orig 2014-05-26 18:37:25.406426611 +0300
+++ eclipse.platform.ui/features/org.eclipse.e4.rcp/pom.xml 2014-05-26 18:37:47.327449374 +0300
-@@ -45,6 +45,21 @@
+@@ -44,6 +44,22 @@
@@ -92,6 +92,7 @@
+
+
+
++
+
+
+
diff --git a/eclipse-remove-jgit-provider.patch b/eclipse-remove-jgit-provider.patch
index b10d555..f01103e 100644
--- a/eclipse-remove-jgit-provider.patch
+++ b/eclipse-remove-jgit-provider.patch
@@ -1,6 +1,6 @@
--- eclipse-platform-parent/pom.xml.orig 2014-11-28 14:54:50.000000000 +0000
+++ eclipse-platform-parent/pom.xml 2014-11-28 15:32:51.700154985 +0000
-@@ -360,7 +360,7 @@
+@@ -483,7 +483,7 @@
tycho-packaging-plugin
${tycho.version}
@@ -9,7 +9,7 @@
org.eclipse.tycho.extras
tycho-buildtimestamp-jgit
${tycho-extras.version}
-@@ -369,19 +369,19 @@
+@@ -492,19 +492,19 @@
org.eclipse.tycho.extras
tycho-sourceref-jgit
${tycho-extras.version}
diff --git a/eclipse-secondary-arches.patch b/eclipse-secondary-arches.patch
index 50d042c..a5bc00f 100644
--- a/eclipse-secondary-arches.patch
+++ b/eclipse-secondary-arches.patch
@@ -2,7 +2,7 @@ diff --git a/eclipse.platform.ui/features/org.eclipse.e4.rcp/feature.xml b/eclip
index 7e1f520..734dd10 100644
--- a/eclipse.platform.ui/features/org.eclipse.e4.rcp/feature.xml
+++ b/eclipse.platform.ui/features/org.eclipse.e4.rcp/feature.xml
-@@ -400,6 +400,36 @@
+@@ -418,6 +418,36 @@
install-size="0"
version="0.0.0"
fragment="true"/>
@@ -39,7 +39,7 @@ index 7e1f520..734dd10 100644
-
-
-+
-+
-+ build-native-launchers-gtk.linux.ppc64
-+
-+
-+ native
-+ gtk.linux.ppc64
-+
-+
-+
-+
-+
-+ maven-antrun-plugin
-+
-+
-+ compile-executable-natives
-+ generate-resources
-+
-+
-+
-+
-+
-+
-+ run
-+
-+
-+
-+
-+
-+
-+
-+
-+ build-native-launchers-gtk.linux.s390x
-+
-+
-+ native
-+ gtk.linux.s390x
-+
-+
-+
-+
-+
-+ maven-antrun-plugin
-+
-+
-+ compile-executable-natives
-+ generate-resources
-+
-+
-+
-+
-+
-+
-+ run
-+
-+
-+
-+
-+
-+
-+
-+
-
- build-native-launchers-win32.win32.x86_64
-
-@@ -563,8 +563,11 @@
+@@ -123,7 +123,11 @@
+
+
-
++
+
@@ -164,28 +95,31 @@ index 7e1f520..734dd10 100644
--- a/rt.equinox.framework/features/org.eclipse.equinox.executable.feature/build.properties 2015-01-30 14:44:03.436891441 +0000
+++ b/rt.equinox.framework/features/org.eclipse.equinox.executable.feature/build.properties 2015-01-30 14:45:25.232480509 +0000
-@@ -37,3 +37,12 @@
+@@ -34,3 +34,12 @@
root.linux.gtk.x86_64=bin/gtk/linux/x86_64,gtk_root
root.linux.gtk.x86_64.permissions.755=libcairo-swt.so
+
++root.linux.gtk.arm=bin/gtk/linux/arm,gtk_root
++root.linux.gtk.arm.permissions.755=launcher
++
+root.linux.gtk.aarch64=bin/gtk/linux/aarch64,gtk_root
+root.linux.gtk.aarch64.permissions.755=launcher
+
-+root.linux.gtk.arm=bin/gtk/linux/arm,gtk_root
-+root.linux.gtk.arm.permissions.755=launcher
++root.linux.gtk.ppc64=bin/gtk/linux/ppc64,gtk_root
++root.linux.gtk.ppc64.permissions.755=launcher
+
+root.linux.gtk.s390x=bin/gtk/linux/s390x,gtk_root
+root.linux.gtk.s390x.permissions.755=launcher
--- a/eclipse.platform.swt.binaries/pom.xml 2017-04-05 01:57:59.142576722 +0100
+++ b/eclipse.platform.swt.binaries/pom.xml 2017-04-05 02:00:00.153247342 +0100
-@@ -55,8 +55,11 @@
+@@ -54,7 +54,11 @@
bundles/org.eclipse.swt.cocoa.macosx.x86_64
+ bundles/org.eclipse.swt.gtk.linux.arm
+ bundles/org.eclipse.swt.gtk.linux.aarch64
- bundles/org.eclipse.swt.gtk.linux.ppc64
++ bundles/org.eclipse.swt.gtk.linux.ppc64
bundles/org.eclipse.swt.gtk.linux.ppc64le
+ bundles/org.eclipse.swt.gtk.linux.s390x
bundles/org.eclipse.swt.gtk.linux.x86
@@ -193,10 +127,15 @@ index 7e1f520..734dd10 100644
bundles/org.eclipse.swt.win32.win32.x86
--- a/eclipse.platform.swt/bundles/org.eclipse.swt/META-INF/p2.inf 2017-04-21 10:15:34.857977599 +0100
+++ b/eclipse.platform.swt/bundles/org.eclipse.swt/META-INF/p2.inf 2017-04-21 10:18:22.878025820 +0100
-@@ -39,3 +39,18 @@
- requires.8.name = org.eclipse.swt.gtk.linux.ppc64le
- requires.8.range = [$version$,$version$]
- requires.8.filter = (&(osgi.os=linux)(osgi.ws=gtk)(osgi.arch=ppc64le)(!(org.eclipse.swt.buildtime=true)))
+@@ -34,3 +34,18 @@
+ requires.7.name = org.eclipse.swt.gtk.linux.ppc64le
+ requires.7.range = [$version$,$version$]
+ requires.7.filter = (&(osgi.os=linux)(osgi.ws=gtk)(osgi.arch=ppc64le)(!(org.eclipse.swt.buildtime=true)))
++
++requires.8.namespace = org.eclipse.equinox.p2.iu
++requires.8.name = org.eclipse.swt.gtk.linux.ppc64
++requires.8.range = [$version$,$version$]
++requires.8.filter = (&(osgi.os=linux)(osgi.ws=gtk)(osgi.arch=ppc64)(!(org.eclipse.swt.buildtime=true)))
+
+requires.9.namespace = org.eclipse.equinox.p2.iu
+requires.9.name = org.eclipse.swt.gtk.linux.arm
@@ -214,7 +153,7 @@ index 7e1f520..734dd10 100644
+requires.11.filter = (&(osgi.os=linux)(osgi.ws=gtk)(osgi.arch=s390x)(!(org.eclipse.swt.buildtime=true)))
--- a/rt.equinox.framework/features/org.eclipse.equinox.executable.feature/library/gtk/build.sh 2017-04-19 13:31:15.000000000 +0100
+++ b/rt.equinox.framework/features/org.eclipse.equinox.executable.feature/library/gtk/build.sh 2017-04-23 16:58:34.022207885 +0100
-@@ -119,7 +119,7 @@
+@@ -106,7 +106,7 @@
"s390x")
defaultOSArch="s390x"
defaultJava=DEFAULT_JAVA_EXEC
@@ -225,11 +164,23 @@ index 7e1f520..734dd10 100644
defaultOSArch="arm"
--- a/rt.equinox.framework/pom.xml 2017-04-26 22:19:15.548461372 +0100
+++ b/rt.equinox.framework/pom.xml 2017-04-26 22:20:41.348571492 +0100
-@@ -73,6 +73,18 @@
+@@ -73,6 +73,30 @@
bundles/org.eclipse.equinox.launcher.gtk.linux.aarch64
+
++ build-native-launchers-gtk.linux.ppc64
++
++
++ native
++ gtk.linux.ppc64
++
++
++
++ bundles/org.eclipse.equinox.launcher.gtk.linux.ppc64
++
++
++
+ build-native-launchers-gtk.linux.s390x
+
+
diff --git a/eclipse-support-symlink-bundles.patch b/eclipse-support-symlink-bundles.patch
index c829d9b..63293fb 100644
--- a/eclipse-support-symlink-bundles.patch
+++ b/eclipse-support-symlink-bundles.patch
@@ -43,7 +43,7 @@ index ab69b88..d6bf121 100644
public class SimpleConfiguratorUtils {
-@@ -284,6 +288,16 @@ public class SimpleConfiguratorUtils {
+@@ -277,6 +281,16 @@ public class SimpleConfiguratorUtils {
String symbolicName = tok.nextToken().trim();
String version = tok.nextToken().trim();
URI location = parseLocation(tok.nextToken().trim());
@@ -60,7 +60,7 @@ index ab69b88..d6bf121 100644
int startLevel = Integer.parseInt(tok.nextToken().trim());
boolean markedAsStarted = Boolean.parseBoolean(tok.nextToken());
BundleInfo result = new BundleInfo(symbolicName, version, location, startLevel, markedAsStarted);
-@@ -414,4 +428,93 @@ public class SimpleConfiguratorUtils {
+@@ -400,4 +414,93 @@ public class SimpleConfiguratorUtils {
}
return regularTimestamp;
}
diff --git a/eclipse.spec b/eclipse.spec
index cfc553a..50dd34a 100644
--- a/eclipse.spec
+++ b/eclipse.spec
@@ -1,14 +1,14 @@
# Set to 1 to build Eclipse without circular dependency to eclipse-pde, API
# generation and docs will not be built and a second run will be required, but
# this is a way to bootstrap Eclipse on secondary archs.
-%global bootstrap 0
+%global bootstrap 1
Epoch: 1
-%global eb_commit 81122c55c72d9e308302c878f642f93c39507436
-%global eclipse_tag I20180611-0500
+%global eb_commit 23577466b35eaf62bee3b00090f4fbedc555b4e6
+%global eclipse_tag I20180817-2000
-%global _jetty_version 9.4.9
+%global _jetty_version 9.4.11
%global _lucene_version 7.1.0
%ifarch %{ix86}
@@ -39,9 +39,9 @@ Epoch: 1
Summary: An open, extensible IDE
Name: eclipse
-Version: 4.8.0
-Release: 4%{?dist}
-License: EPL
+Version: 4.9.0
+Release: 0.1%{?dist}
+License: EPL-2.0
URL: http://www.eclipse.org/
Source0: http://download.eclipse.org/eclipse/downloads/drops4/%{eclipse_tag}/eclipse-platform-sources-%{eclipse_tag}.tar.xz
@@ -65,17 +65,15 @@ Patch2: eclipse-ignore-version-when-calculating-home.patch
# just source, and we don't want additional dependencies.
Patch3: eclipse-remove-jgit-provider.patch
+Patch4: eclipse-secondary-arches.patch
+
+Patch5: eclipse-debug-symbols.patch
+
#Patch6: eclipse-test-support.patch
-Patch7: eclipse-secondary-arches.patch
-
-Patch10: eclipse-debug-symbols.patch
-
# https://bugs.eclipse.org/bugs/show_bug.cgi?id=408138
Patch12: eclipse-fix-dropins.patch
-Patch13: eclipse-bug-386377.patch
-
# org.mockito -> org.mockito.mockito-core
# org.hamcrest-> org.hamcrest.core
Patch14: eclipse-mockito.patch
@@ -94,12 +92,6 @@ Patch15: eclipse-support-symlink-bundles.patch
# org.w3c.dom.smil -> removed
Patch16: eclipse-feature-plugins-to-category-ius.patch
-# Fix for p2 UI
-Patch17: eclipse-bug-533655.patch
-
-# Fix webkit2 encoding bug
-Patch18: eclipse-bug-535392.patch
-
# Fix various JDT and PDE tests
Patch20: eclipse-fix-tests.patch
@@ -108,10 +100,10 @@ Patch21: eclipse-adjust-droplets.patch
Patch22: eclipse-pde-tp-support-droplets.patch
# Only build gtk3 backend for SWT
-Patch24: eclipse-swt-disable-gtk2.patch
+Patch23: eclipse-swt-disable-gtk2.patch
# Disable uses by default
-Patch25: eclipse-disable-uses-constraints.patch
+Patch24: eclipse-disable-uses-constraints.patch
# Droplet fixes
Patch26: eclipse-make-droplets-runnable.patch
@@ -126,9 +118,6 @@ Patch29: fix_ant_build.patch
# Hide the p2 Droplets from cluttering Install Wizard Combo
Patch30: eclipse-hide-droplets-from-install-wizard.patch
-# Use gsettings instead of gconf
-Patch31: eclipse-bug-394087.patch
-
# Use the jit on 32bit arm to speed up the build
%ifarch %{arm}
BuildRequires: java-1.8.0-openjdk-aarch32-devel
@@ -162,19 +151,19 @@ BuildRequires: pkgconfig(libsecret-1)
BuildRequires: pkgconfig(gtk+-2.0)
BuildRequires: pkgconfig(gtk+-3.0)
BuildRequires: pkgconfig(webkit2gtk-4.0)
-BuildRequires: icu4j >= 1:59.1
+BuildRequires: icu4j >= 1:62.1
BuildRequires: ant >= 1.10.1
BuildRequires: ant-antlr ant-apache-bcel ant-apache-log4j ant-apache-oro ant-apache-regexp ant-apache-resolver ant-commons-logging ant-apache-bsf
-BuildRequires: ant-commons-net ant-javamail ant-jdepend ant-junit ant-swing ant-jsch ant-testutil ant-apache-xalan2 ant-jmf
+BuildRequires: ant-commons-net ant-javamail ant-jdepend ant-junit ant-swing ant-jsch ant-testutil ant-apache-xalan2 ant-jmf ant-xz ant-junit5
BuildRequires: jsch >= 0:0.1.46-2
BuildRequires: apache-commons-el >= 1.0-22
BuildRequires: apache-commons-logging
BuildRequires: apache-commons-codec
BuildRequires: apache-commons-jxpath
BuildRequires: apache-commons-fileupload
-BuildRequires: osgi(org.apache.felix.gogo.shell) >= 1.0.0
+BuildRequires: osgi(org.apache.felix.gogo.shell) >= 1.1.0
BuildRequires: osgi(org.apache.felix.gogo.command) >= 1.0.2
-BuildRequires: osgi(org.apache.felix.gogo.runtime) >= 1.0.4
+BuildRequires: osgi(org.apache.felix.gogo.runtime) >= 1.1.0
BuildRequires: osgi(org.apache.felix.scr) >= 2.0.14
BuildRequires: osgi(org.eclipse.jetty.util) >= %{_jetty_version}
BuildRequires: osgi(org.eclipse.jetty.server) >= %{_jetty_version}
@@ -190,18 +179,18 @@ BuildRequires: lucene-analyzers-smartcn >= %{_lucene_version}
BuildRequires: junit >= 4.12
BuildRequires: junit5
BuildRequires: apiguardian
-BuildRequires: hamcrest >= 1.3
+BuildRequires: hamcrest
BuildRequires: sat4j
BuildRequires: objectweb-asm >= 6.1.1
BuildRequires: sac
-BuildRequires: batik >= 1.9-7
-BuildRequires: batik-css >= 1.9-7
+BuildRequires: batik >= 1.10
+BuildRequires: batik-css >= 1.10
BuildRequires: xmlgraphics-commons >= 2.2
BuildRequires: xml-commons-apis
BuildRequires: atinject
-BuildRequires: eclipse-ecf-core >= 3.14.0-1
-BuildRequires: eclipse-emf-core >= 1:2.14.0-1
-BuildRequires: eclipse-license
+BuildRequires: eclipse-ecf-core >= 3.14.1-2
+BuildRequires: eclipse-emf-core >= 1:2.15.0-0.2
+BuildRequires: eclipse-license2
BuildRequires: glassfish-el-api >= 3.0.1
BuildRequires: glassfish-el >= 3.0.1
BuildRequires: glassfish-jsp-api >= 2.2.1-4
@@ -209,6 +198,7 @@ BuildRequires: glassfish-jsp >= 2.2.5
BuildRequires: glassfish-servlet-api >= 3.1.0
BuildRequires: httpcomponents-core
BuildRequires: httpcomponents-client
+BuildRequires: jsoup
BuildRequires: xz-java
BuildRequires: mockito
BuildRequires: osgi(osgi.annotation)
@@ -228,8 +218,7 @@ everything in between.
%package swt
Summary: SWT Library for GTK+
-
-Requires: java-headless >= 1:1.7.0
+Requires: java-headless >= 1:1.8.0
Requires: javapackages-tools
Requires: gtk3
Requires: webkitgtk4
@@ -239,7 +228,7 @@ SWT Library for GTK+.
%package equinox-osgi
Summary: Eclipse OSGi - Equinox
-Requires: java-headless >= 1:1.7.0
+Requires: java-headless >= 1:1.8.0
Requires: javapackages-tools
Provides: osgi(system.bundle) = %{epoch}:%{version}
@@ -248,12 +237,12 @@ Eclipse OSGi - Equinox
%package platform
Summary: Eclipse platform common files
-Recommends: eclipse-abrt
-Recommends: eclipse-usage
+%{?fedora:Recommends}%{!?fedora:Requires}: eclipse-abrt
+%{?fedora:Recommends}%{!?fedora:Requires}: eclipse-usage
Requires: ant >= 1.10.1
Requires: ant-antlr ant-apache-bcel ant-apache-log4j ant-apache-oro ant-apache-regexp ant-apache-resolver ant-commons-logging ant-apache-bsf
-Requires: ant-commons-net ant-javamail ant-jdepend ant-junit ant-swing ant-jsch ant-testutil ant-apache-xalan2 ant-jmf
+Requires: ant-commons-net ant-javamail ant-jdepend ant-junit ant-swing ant-jsch ant-testutil ant-apache-xalan2 ant-jmf ant-xz ant-junit5
Requires: jsch >= 0.1.46-2
Requires: apache-commons-el >= 1.0-23
Requires: apache-commons-logging
@@ -276,8 +265,8 @@ Requires: lucene-queryparser >= %{_lucene_version}
Requires: lucene-analyzers-smartcn >= %{_lucene_version}
Requires: sat4j
Requires: sac
-Requires: batik >= 1.9-7
-Requires: batik-css >= 1.9-7
+Requires: batik >= 1.10
+Requires: batik-css >= 1.10
Requires: xmlgraphics-commons >= 2.2
Requires: xml-commons-apis
Requires: atinject
@@ -288,7 +277,7 @@ Requires: glassfish-el >= 3.0.1
Requires: glassfish-jsp-api >= 2.2.1-4
Requires: glassfish-jsp >= 2.2.5
Requires: glassfish-servlet-api >= 3.1.0
-Requires: icu4j >= 1:59.1
+Requires: icu4j >= 1:62.1
Requires: %{name}-swt = %{epoch}:%{version}-%{release}
Requires: %{name}-equinox-osgi = %{epoch}:%{version}-%{release}
Requires: httpcomponents-core
@@ -313,8 +302,8 @@ BuildArch: noarch
Provides: %{name} = %{epoch}:%{version}-%{release}
Requires: %{name}-platform = %{epoch}:%{version}-%{release}
Requires: osgi(org.junit) >= 4.12
-Requires: osgi(org.hamcrest.core) >= 1.3
-Recommends: eclipse-recommenders
+Requires: osgi(org.hamcrest.core)
+%{?fedora:Recommends}%{!?fedora:Requires}: eclipse-recommenders
%description jdt
Eclipse Java Development Tools. This package is required to use Eclipse for
@@ -369,7 +358,7 @@ Eclipse Tests.
tar --strip-components=1 -xf %{SOURCE1}
# Delete pre-built binary artifacts except some test data that cannot be generated
-find . ! -path "*/JCL/*" ! -name "rtstubs*.jar" ! -name "java10api.jar" \
+find . ! -path "*/JCL/*" ! -name "rtstubs*.jar" ! -name "java10api.jar" ! -name "j9stubs.jar" \
-type f -name *.jar -delete
find . -type f -name *.class -delete
find . -type f -name *.so -delete
@@ -383,21 +372,18 @@ rm -rf rt.equinox.binaries/org.eclipse.equinox.executable/{bin,contributed}/
%patch1
%patch2
%patch3
+%patch4 -p1
+%patch5
#%patch6
-%patch7 -p1
-%patch10
%patch12
-%patch13
%patch14
%patch15
%patch16
-%patch17 -p1
-%patch18 -p1
%patch20
%patch21
%patch22
+%patch23
%patch24
-%patch25
%patch26
%patch27
%if ! %{use_wayland}
@@ -406,9 +392,6 @@ rm -rf rt.equinox.binaries/org.eclipse.equinox.executable/{bin,contributed}/
%endif
%patch29
%patch30 -p1
-pushd eclipse.platform.team
-%patch31 -p1
-popd
# Use ecj when bootstrapping
%if %{bootstrap}
@@ -447,12 +430,10 @@ sed -i -e 's/groupId>org.eclipse.jdtorg.eclipse.tycho' eclipse-platf
%pom_disable_module bundles/org.eclipse.equinox.p2.tests.reconciler.product rt.equinox.p2
%pom_disable_module bundles/org.eclipse.equinox.p2.artifact.optimizers rt.equinox.p2
%pom_disable_module bundles/org.eclipse.equinox.p2.artifact.processors rt.equinox.p2
-%pom_disable_module bundles/ie.wombat.jbdiff rt.equinox.p2
-%pom_disable_module bundles/ie.wombat.jbdiff.test rt.equinox.p2
# Don't need annotations for obsolete JDKs
%pom_disable_module org.eclipse.jdt.annotation_v1 eclipse.jdt.core
-%pom_xpath_remove "plugin[@version='1.1.200.qualifier']" eclipse.jdt/org.eclipse.jdt-feature/feature.xml
+%pom_xpath_remove "plugin[@version='1.1.300.qualifier']" eclipse.jdt/org.eclipse.jdt-feature/feature.xml
sed -i -e '/org\.eclipse\.jdt\.annotation;bundle-version="\[1\.1\.0,2\.0\.0)"/d' \
eclipse.jdt.core/org.eclipse.jdt.core.tests.{model,builder,compiler}/META-INF/MANIFEST.MF \
eclipse.jdt.core/org.eclipse.jdt.apt.pluggable.tests/META-INF/MANIFEST.MF \
@@ -469,9 +450,9 @@ sed -i -e '/org\.eclipse\.jdt\.annotation;bundle-version="\[1\.1\.0,2\.0\.0)"/d'
%pom_disable_module bundles/org.eclipse.equinox.servletbridge.template rt.equinox.bundles
# This part generates secondary fragments using primary fragments
-for dir in rt.equinox.binaries ; do
+for dir in rt.equinox.binaries eclipse.platform.swt.binaries/bundles ; do
utils/ensure_arch.sh "$dir" x86 arm
- utils/ensure_arch.sh "$dir" x86_64 aarch64
+ utils/ensure_arch.sh "$dir" x86_64 aarch64 ppc64
done
# Remove platform-specific stuff that we don't care about to reduce build time
@@ -533,10 +514,10 @@ for f in eclipse.jdt/org.eclipse.jdt-feature/feature.xml \
done
# Fix versions in secondary arch fragments
-fix_files=$(grep -lr 3.106.100 eclipse.platform.swt.binaries/bundles/org.eclipse.swt.gtk.linux.*)
-sed -i -e "s/3.106.100/3.107.0/" $fix_files
-fix_files=$(grep -lr '1\.1\.[56]00' rt.equinox.framework/bundles/org.eclipse.equinox.launcher.gtk.linux.*)
-sed -i -e "s/1\.1\.[56]00/1.1.700/" $fix_files
+fix_files=$(grep -lr 3.107.100 eclipse.platform.swt.binaries/bundles/org.eclipse.swt.gtk.linux.*)
+sed -i -e "s/3.107.100/3.108.0/" $fix_files
+fix_files=$(grep -lr '1\.1\.[67]00' rt.equinox.framework/bundles/org.eclipse.equinox.launcher.gtk.linux.*)
+sed -i -e "s/1\.1\.[67]00/1.1.800/" $fix_files
sed -i -e "/Fragment-Host/s/\(bundle-version=\).*/\1\"1.0.0\"/" $fix_files
# We don't need SWT fragments since we only care for current arch
@@ -606,9 +587,6 @@ dependencies/fake_ant_dependency.sh
# Allow usage of javax.servlet.jsp 2.3.
sed -i '/javax\.servlet\.jsp/ s/2\.3/2\.4/' rt.equinox.bundles/bundles/org.eclipse.equinox.jsp.jasper/META-INF/MANIFEST.MF
-# Allow usage of batik 1.9 (1.9.1 is identical to 1.9 anyway)
-sed -i '/batik/s/1\.9\.1/1.9.0/' eclipse.platform.ui/bundles/org.eclipse.e4.ui.css.core/META-INF/MANIFEST.MF
-
# Use javax.servlet-api (Glassfish) instead of javax.servlet (Tomcat)
find -name feature.xml | xargs sed -i -e 's|"javax.servlet"|"javax.servlet-api"|'
sed -i -e "2iRequire-Bundle: javax.servlet-api" rt.equinox.bundles/bundles/org.eclipse.equinox.http.{jetty,servlet}/META-INF/MANIFEST.MF
@@ -1055,6 +1033,7 @@ fi
%{_eclipsedir}/plugins/org.eclipse.ui.workbench_*
%{_eclipsedir}/plugins/org.eclipse.ui.workbench.texteditor_*
%{_eclipsedir}/plugins/org.eclipse.update.configurator_*
+%{_eclipsedir}/plugins/org.eclipse.urischeme_*
%{_eclipsedir}/plugins/org.glassfish.web.javax.servlet.jsp_*
%{_eclipsedir}/plugins/org.kxml2_*
%{_eclipsedir}/plugins/org.sat4j.core_*
@@ -1090,6 +1069,10 @@ fi
%{_eclipsedir}/plugins/org.eclipse.osgi.util_*
%changelog
+* Sun Aug 19 2018 Mat Booth - 1:4.9.0-0.1
+- Update to latest I-build
+- Update license
+
* Thu Jul 12 2018 Fedora Release Engineering - 1:4.8.0-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
diff --git a/sources b/sources
index 4bb1ae3..ebc87ba 100644
--- a/sources
+++ b/sources
@@ -1,2 +1,2 @@
-SHA512 (eclipse-platform-sources-I20180611-0500.tar.xz) = 17f380aa28d51537f83efffb1224d3177426ba4e9a65deb867065a279de382328152159d8a229a993f2dec57405f7fa5f26056ed005798ced2d2385bfc84cf0c
-SHA512 (org.eclipse.linuxtools.eclipse-build-81122c55c72d9e308302c878f642f93c39507436.tar.xz) = 170d6801fd2c2f5f95c4d79cb14e36bb5db63142a52cafea81656f63dd132cf1a5b52b945fa0f85d4eed21ed660d22f46d2cdf9cde86e08fed06b16e9a22ed51
+SHA512 (eclipse-platform-sources-I20180817-2000.tar.xz) = fc84d193ea5ae69ba80a742fce4e4aa58aedba1b14ee2e29f4cc8cf28da4cf17f4fbbb779b958ba9d6f111ce54357041c9c4c754f9c645374c5f4f39b48be848
+SHA512 (org.eclipse.linuxtools.eclipse-build-23577466b35eaf62bee3b00090f4fbedc555b4e6.tar.xz) = d268ea945c33b997c79b390f9592c1139f52dc39ebdb7ea7155d41301459827f576389e20080462ad22f2aef833857626df983bbb2abe30845e79ca74a194bea