gwt-eclipse-plugin
gwt-eclipse-plugin copied to clipboard
Fix for #403
@branflake2267 Could you please accept this PR and update plugin at http://storage.googleapis.com/gwt-eclipse-plugin/v3/snapshot (or release) ? Without that it is not possible to use gwt 2.10 in Eclipse
@foal How do you build this plugin? I was not able to build it locally. Tried mvn clean package -U -Pbuild-eclipse-oxygen but it fails with "The effective compiler target level 1.8 is incompatible with the following OSGi execution environments:" Tried Java7 - but it fails immediatelly.
@slavap IIRC you need to use Java 11 to build the plugin. See: https://wiki.eclipse.org/Eclipse/Installation
@FrankHossfeld I have tried to compile it on Java 11, but it is not working. mvn clean package -U -Pbuild-eclipse-oxygen but it fails with "The effective compiler target level 1.8 is incompatible with the following OSGi execution environments:"
@slavap I have build it after export inside Eclipse. Use the eclipse-committers-2022-06-R-win32-x86_64.zip. But I needed to adapt the plugin to the latest target. Anyway, this patch is target independent and should work on any platform.
The attachment contains jar (rename zip to jar) with patched class.
@foal Thank you, it works now after replacing in Eclipse\plugins folder.
But now compilation of my project "GWT Compile Project" fails in Eclipse (but works just fine from command line).
Compiling module com.aaa.SwDev Tracing compile failure path for type 'java.io.OutputStreamWriter' [ERROR] Errors in 'jar:file:/C:/Programs/gwt-2.10.0/gwt-user.jar!/com/google/gwt/emul/java/io/OutputStreamWriter.java' [ERROR] Line 59: The method getBytes(String) in the type EmulatedCharset is not applicable for the arguments (char[], int, int) [ERROR] Aborting compile due to errors in some input files [ERROR] Error saving compilation unit to cache file: C:\Users\sl\Documents\work-sts\sw\sw-web\target\gwt-unitCache\gwt-unitCache-8c530e985114901166261cb2baf5ec75a6e55b9b-FF35F588CF7564DE259004F02565B00E-00000181B33684C8 java.io.IOException: Stream Closed at java.base/java.io.RandomAccessFile.readBytes(Native Method) at java.base/java.io.RandomAccessFile.read(RandomAccessFile.java:405) at com.google.gwt.dev.util.DiskCache.transferToStream(DiskCache.java:165) at com.google.gwt.dev.util.DiskCacheToken.writeObject(DiskCacheToken.java:73) at jdk.internal.reflect.GeneratedMethodAccessor36.invoke(Unknown Source) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:568) at java.base/java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:1201) at java.base/java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1526) at java.base/java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1448) at java.base/java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1191) at java.base/java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1582) at java.base/java.io.ObjectOutputStream.defaultWriteObject(ObjectOutputStream.java:447) at com.google.gwt.dev.javac.CachedCompilationUnit.writeObject(CachedCompilationUnit.java:230) at jdk.internal.reflect.GeneratedMethodAccessor37.invoke(Unknown Source) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:568) at java.base/java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:1201) at java.base/java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1526) at java.base/java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1448) at java.base/java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1191) at java.base/java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:354) at com.google.gwt.dev.javac.PersistentUnitCacheDir$OpenFile.writeUnit(PersistentUnitCacheDir.java:373) at com.google.gwt.dev.javac.PersistentUnitCacheDir.writeUnit(PersistentUnitCacheDir.java:194) at com.google.gwt.dev.javac.PersistentUnitCache$BackgroundService$6.run(PersistentUnitCache.java:444) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) at java.base/java.lang.Thread.run(Thread.java:833)
@foal @FrankHossfeld Any ideas? <<< Disregard, cured by cleaning target folder of my project. All works fine now, thanks!