diff options
-rw-r--r-- | build.xml | 37 | ||||
-rw-r--r-- | src/installer/lombok/installer/eclipse/STS4LocationProvider.java | 44 |
2 files changed, 75 insertions, 6 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/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); + } +} |