diff options
-rw-r--r-- | build.xml | 37 | ||||
-rwxr-xr-x[-rw-r--r--] | docker/provision/ant/ant-1.10.1.sh | 0 | ||||
-rwxr-xr-x[-rw-r--r--] | docker/provision/gradle/gradle-4.2.1.sh | 0 | ||||
-rwxr-xr-x | docker/provision/jdk/java-10.sh | 4 | ||||
-rwxr-xr-x[-rw-r--r--] | docker/provision/jdk/java-8.sh | 0 | ||||
-rwxr-xr-x[-rw-r--r--] | docker/provision/jdk/java-9.sh | 4 | ||||
-rwxr-xr-x[-rw-r--r--] | docker/provision/maven/maven-3.5.0.sh | 0 | ||||
-rw-r--r-- | src/core/lombok/javac/apt/LombokFileObjects.java | 7 | ||||
-rw-r--r-- | src/installer/lombok/installer/eclipse/STS4LocationProvider.java | 44 |
9 files changed, 87 insertions, 9 deletions
@@ -28,8 +28,19 @@ the common tasks and can be called on to run the main aspects of all the sub-scr <property name="build.compiler" value="javac1.6" /> <property name="ivy.retrieve.pattern" value="lib/[conf]/[organisation]-[artifact].[ext]" /> <available file="lib/ivyplusplus.jar" property="ivyplusplus.available" /> - <available file="lib/openJDK6Environment/rt-openjdk6.jar" property="rt-openjdk6.available" /> - + <property name="rt-openjdk6" location="lib/openJDk6Environment/rt-openjdk6.jar" /> + <property name="rt-openjdk8" location="lib/openJDk8Environment/rt-openjdk8.jar" /> + <property name="openjdk6.md5" value="de953d5062b7183fbf3fa9f5d623e2e7" /> + <property name="openjdk8.md5" value="8099e5d7aa182374d299d03f5003a27f" /> + <checksum file="${rt-openjdk6}" property="${openjdk6.md5}" verifyProperty="rt-openjdk6.checksumOk" /> + <checksum file="${rt-openjdk8}" property="${openjdk8.md5}" verifyProperty="rt-openjdk8.checksumOk" /> + <condition property="rt-openjdk6.available"> + <equals arg1="${rt-openjdk6.checksumOk}" arg2="true" /> + </condition> + <condition property="rt-openjdk8.available"> + <equals arg1="${rt-openjdk8.checksumOk}" arg2="true" /> + </condition> + <path id="build.path"> <fileset dir="lib/build"> <include name="*.jar" /> @@ -98,12 +109,17 @@ the common tasks and can be called on to run the main aspects of all the sub-scr <ivy:retrieve /> </target> - <target name="ensureOpenJdk7Rt" unless="rt-openjdk6.available"> + <target name="ensureOpenJdk6Rt" unless="rt-openjdk6.available"> <mkdir dir="lib/openJDK6Environment" /> - <get src="https://projectlombok.org/ivyrepo/langtools/rt-openjdk6.jar" dest="lib/openJDK6Environment/rt-openjdk6.jar" verbose="true" usetimestamp="true" /> + <get src="https://projectlombok.org/ivyrepo/langtools/rt-openjdk6.jar" dest="${rt-openjdk6}" verbose="true" usetimestamp="true" /> + </target> + + <target name="ensureOpenJdk8Rt" unless="rt-openjdk8.available"> + <mkdir dir="lib/openJDK8Environment" /> + <get src="https://projectlombok.org/ivyrepo/langtools/rt-openjdk8.jar" dest="${rt-openjdk8}" verbose="true" usetimestamp="true" /> </target> - <target name="ensureBuildDeps" depends="config-ivy,ensureOpenJdk7Rt"> + <target name="ensureBuildDeps" depends="config-ivy,ensureOpenJdk6Rt"> <ivy:resolve file="buildScripts/ivy.xml" refresh="true" conf="build, javac7" /> <ivy:retrieve /> </target> @@ -123,9 +139,10 @@ the common tasks and can be called on to run the main aspects of all the sub-scr <ivy:retrieve /> </target> - <target name="version" depends="ensure-ipp" description="Shows the version number." unless="lombok.version"> + <target name="version" depends="ensure-ipp, ensureOpenJdk8Rt" description="Shows the version number." unless="lombok.version"> <mkdir dir="build/lombok" /> <ivy:compile destdir="build/lombok" source="1.5" target="1.5" ecj="true" nowarn="true"> + <bootclasspath path="${rt-openjdk8}" /> <src path="src/core" /> <include name="lombok/core/Version.java" /> </ivy:compile> @@ -160,10 +177,12 @@ the common tasks and can be called on to run the main aspects of all the sub-scr <delete file="build/lombok/META-INF/services/javax.annotation.processing.Processor" quiet="true" /> <delete file="build/lombok/META-INF/services/org.mapstruct.ap.spi.AstModifyingAnnotationProcessor" quiet="true" /> <ivy:compile destdir="build/stubsstubs" source="1.5" target="1.5" ecj="true" nowarn="true"> + <bootclasspath path="${rt-openjdk8}" /> <src path="src/stubsstubs" /> <classpath location="build/stubsstubs" /> </ivy:compile> <ivy:compile destdir="build/stubs" source="1.5" target="1.5" ecj="true" nowarn="true"> + <bootclasspath path="${rt-openjdk8}" /> <src path="src/stubs" /> <src path="src/javac-only-stubs" /> <classpath location="build/stubsstubs" /> @@ -172,6 +191,7 @@ the common tasks and can be called on to run the main aspects of all the sub-scr <ivy:compile destdir="build/lombok-utils" source="1.5" target="1.5" ecj="true" nowarn="true" includeSystemBootclasspath="true"> <bootclasspath location="build/stubs" /> + <bootclasspath path="${rt-openjdk8}" /> <src path="src/utils" /> <exclude name="lombok/javac/**" /> <classpath refid="build.path" /> @@ -204,16 +224,19 @@ the common tasks and can be called on to run the main aspects of all the sub-scr <ivy:compile destdir="build/lombok" source="1.4" target="1.4" ecj="true" nowarn="true" includeSystemBootclasspath="true"> <bootclasspath location="build/stubs" /> + <bootclasspath path="${rt-openjdk8}" /> <src path="build/transformedSources" /> </ivy:compile> <ivy:compile destdir="build/lombok/Class50" source="1.4" target="1.6" ecj="true" nowarn="true" includeSystemBootclasspath="true"> <bootclasspath location="build/stubs" /> + <bootclasspath path="${rt-openjdk8}" /> <src path="build/transformedSources" /> </ivy:compile> <ivy:compile destdir="build/lombok" source="1.5" target="1.5" ecj="true" nowarn="true" includeSystemBootclasspath="true"> <bootclasspath location="build/stubs" /> + <bootclasspath path="${rt-openjdk8}" /> <src path="src/launch" /> <src path="src/core" /> <src path="src/installer" /> @@ -235,6 +258,7 @@ the common tasks and can be called on to run the main aspects of all the sub-scr <ivy:compile destdir="build/lombok/Class50" source="1.5" target="1.6" ecj="true" nowarn="true" includeSystemBootclasspath="true"> <bootclasspath location="build/stubs" /> + <bootclasspath path="${rt-openjdk8}" /> <src path="src/eclipseAgent" /> <include name="lombok/launch/PatchFixesHider.java" /> <classpath location="build/lombok" /> @@ -508,6 +532,7 @@ ${sourceWarning}</echo> <target name="-test-compile" depends="ensureTestDeps, compile" unless="skipTests"> <mkdir dir="build/tests" /> <ivy:compile destdir="build/tests" source="1.5" target="1.5" ecj="true" nowarn="true"> + <bootclasspath path="${rt-openjdk8}" /> <classpath refid="test.path" /> <classpath refid="build.path" /> <classpath path="build/lombok" /> diff --git a/docker/provision/ant/ant-1.10.1.sh b/docker/provision/ant/ant-1.10.1.sh index 3de7f3d0..3de7f3d0 100644..100755 --- a/docker/provision/ant/ant-1.10.1.sh +++ b/docker/provision/ant/ant-1.10.1.sh diff --git a/docker/provision/gradle/gradle-4.2.1.sh b/docker/provision/gradle/gradle-4.2.1.sh index 8c300f11..8c300f11 100644..100755 --- a/docker/provision/gradle/gradle-4.2.1.sh +++ b/docker/provision/gradle/gradle-4.2.1.sh diff --git a/docker/provision/jdk/java-10.sh b/docker/provision/jdk/java-10.sh new file mode 100755 index 00000000..ecdafc8b --- /dev/null +++ b/docker/provision/jdk/java-10.sh @@ -0,0 +1,4 @@ +apt-get update && apt-get install -y wget +wget https://download.java.net/java/jdk10/archive/44/GPL/openjdk-10+44_linux-x64_bin.tar.gz -O jdk.tar.gz +tar -xzf jdk.tar.gz -C /opt/ +mv /opt/jdk-10 /opt/jdk diff --git a/docker/provision/jdk/java-8.sh b/docker/provision/jdk/java-8.sh index 44795c6c..44795c6c 100644..100755 --- a/docker/provision/jdk/java-8.sh +++ b/docker/provision/jdk/java-8.sh diff --git a/docker/provision/jdk/java-9.sh b/docker/provision/jdk/java-9.sh index 2023ae39..fd488dc8 100644..100755 --- a/docker/provision/jdk/java-9.sh +++ b/docker/provision/jdk/java-9.sh @@ -1,4 +1,4 @@ apt-get update && apt-get install -y wget -wget --header "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/9.0.1+11/jdk-9.0.1_linux-x64_bin.tar.gz -O jdk.tar.gz +wget --header "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/9.0.4+11/c2514751926b4512b076cc82f959763f/jdk-9.0.4_linux-x64_bin.tar.gz -O jdk.tar.gz tar -xzf jdk.tar.gz -C /opt/ -mv /opt/jdk-9.0.1 /opt/jdk +mv /opt/jdk-9.0.4 /opt/jdk diff --git a/docker/provision/maven/maven-3.5.0.sh b/docker/provision/maven/maven-3.5.0.sh index 3167a964..3167a964 100644..100755 --- a/docker/provision/maven/maven-3.5.0.sh +++ b/docker/provision/maven/maven-3.5.0.sh diff --git a/src/core/lombok/javac/apt/LombokFileObjects.java b/src/core/lombok/javac/apt/LombokFileObjects.java index 7184629f..aba10540 100644 --- a/src/core/lombok/javac/apt/LombokFileObjects.java +++ b/src/core/lombok/javac/apt/LombokFileObjects.java @@ -106,7 +106,8 @@ final class LombokFileObjects { "com.google.devtools.build.buildjar.javac.BlazeJavacMain$ClassloaderMaskingFileManager", "com.google.devtools.build.java.turbine.javac.JavacTurbineCompiler$ClassloaderMaskingFileManager", "org.netbeans.modules.java.source.parsing.ProxyFileManager", - "com.sun.tools.javac.api.ClientCodeWrapper$WrappedStandardJavaFileManager" + "com.sun.tools.javac.api.ClientCodeWrapper$WrappedStandardJavaFileManager", + "com.sun.tools.javac.main.DelegatingJavaFileManager$DelegatingSJFM" // IntelliJ + JDK10 ); static Compiler getCompiler(JavaFileManager jfm) { @@ -130,6 +131,10 @@ final class LombokFileObjects { catch (Throwable e) {} } try { + if (Class.forName("com.sun.tools.javac.file.PathFileObject") == null) throw new NullPointerException(); + return new Java9Compiler(jfm); + } catch (Throwable e) {} + try { if (Class.forName("com.sun.tools.javac.file.BaseFileObject") == null) throw new NullPointerException(); return Compiler.JAVAC7; } catch (Throwable e) {} diff --git a/src/installer/lombok/installer/eclipse/STS4LocationProvider.java b/src/installer/lombok/installer/eclipse/STS4LocationProvider.java new file mode 100644 index 00000000..47a07bdd --- /dev/null +++ b/src/installer/lombok/installer/eclipse/STS4LocationProvider.java @@ -0,0 +1,44 @@ +/* + * Copyright (C) 2018 The Project Lombok Authors. + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ +package lombok.installer.eclipse; + +import java.util.Arrays; +import java.util.Collections; + +import lombok.installer.IdeLocationProvider; + +import org.mangosdk.spi.ProviderFor; + +@ProviderFor(IdeLocationProvider.class) +public class STS4LocationProvider extends EclipseProductLocationProvider { + + private static final EclipseProductDescriptor STS4 = new StandardProductDescriptor("Spring Tools Suite 4", + "SpringToolSuite4", + "sts", + STS4LocationProvider.class.getResource("STS.png"), + Collections.unmodifiableList(Arrays.asList("springsource", "spring-tool-suite")) + ); + + public STS4LocationProvider() { + super(STS4); + } +} |