[#3143] Review and update jopatai's work on the maven/ecj agent jar

* Update copyright headers
* Update code style (tabs, not spaces, spaces around + operator - that's about it)
* Use `x.class.getResourceAsStream`, not `x.getClass().` - minor mostly irrelevant nit.
* Rename and re-locate the jar itself.
* 'ecj' as an alias for this command seems a bit too cavalier' removed it.
* The source is in its own 'root' src dir, it doesn't really fit in the eclipse agent sources - it's more a maven agent.
* Fixed a bug where a filehandle wasn't safe closed. Mostly irrelevant (JVM would quite afterwards anyway).
* Slight rewording of the ecj docs.
This commit is contained in:
Reinier Zwitserloot committed 2022-04-02 06:12:50 +02:00
1 parent 110434ff60
commit c8607ba782
8 files changed
+115 -121

No files matched your search

+6 -7
View File
@@ -1,5 +1,5 @@
<!--
Copyright (C) 2020-2021 The Project Lombok Authors.
Copyright (C) 2020-2022 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
@@ -74,13 +74,13 @@ This buildfile is part of projectlombok.org. It takes care of compiling and buil
</jar>
</target>
<target name="create.agentBootstrap" depends="-setup.build" description="Compiles the Maven ECJ bootstrap agent">
<ivy:compile destdir="build/agentBootstrap" source="1.6" target="1.6" ecj="true">
<target name="create.mavenEcjBootstrapAgent" depends="-setup.build" description="Compiles the Maven ECJ bootstrap agent">
<ivy:compile destdir="build/mavenEcjBootstrapAgent" source="1.6" target="1.6" ecj="true">
<bootclasspath path="${jdk6-rt.loc}" />
<src path="src/eclipseAgent" />
<include name="lombok/launch/AgentBootstrap.java" />
<src path="src/mavenEcjBootstrapAgent" />
</ivy:compile>
<jar destfile="build/lombok-main/lombok/eclipse/agent/lombok-bootstrap.jar" basedir="build/agentBootstrap" includes="lombok/launch/AgentBootstrap*.class">
<mkdir dir="build/lombok-main/lombok/launch" />
<jar destfile="build/lombok-main/lombok/launch/mavenEcjBootstrapAgent.jar" basedir="build/mavenEcjBootstrapAgent">
<manifest>
<attribute name="Premain-Class" value="lombok.launch.AgentBootstrap" />
<attribute name="Can-Redefine-Classes" value="true" />
@@ -183,7 +183,6 @@ This buildfile is part of projectlombok.org. It takes care of compiling and buil
<src path="src/eclipseAgent" />
<src path="src/delombok" />
<exclude name="**/*Transplants.java" />
<exclude name="**/AgentBootstrap.java" />
<classpath refid="cp.build" />
<classpath refid="cp.eclipse-oxygen" />
<classpath refid="cp.javac6" />
+2 -1
View File
@@ -1,5 +1,5 @@
<!--
Copyright (C) 2010-2021 The Project Lombok Authors.
Copyright (C) 2010-2022 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
@@ -34,6 +34,7 @@ This buildfile is part of projectlombok.org. It creates the infrastructure neede
<srcdir dir="src/launch" />
<srcdir dir="src/utils" />
<srcdir dir="src/eclipseAgent" />
<srcdir dir="src/mavenEcjBootstrapAgent" />
<srcdir dir="src/installer" />
<srcdir dir="src/delombok" />
<srcdir dir="src/stubs" srcout="bin/stubs" />
+2 -1
View File
@@ -1,5 +1,5 @@
<!--
Copyright (C) 2010-2021 The Project Lombok Authors.
Copyright (C) 2010-2022 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
@@ -45,6 +45,7 @@ This buildfile is part of projectlombok.org. It creates the infrastructure neede
<srcdir dir="src/launch" />
<srcdir dir="src/utils" />
<srcdir dir="src/eclipseAgent" />
<srcdir dir="src/mavenEcjBootstrapAgent" />
<srcdir dir="src/installer" />
<srcdir dir="src/delombok" />
<srcdir dir="src/stubs" />
+2 -1
View File
@@ -1,5 +1,5 @@
<!--
Copyright (C) 2020 The Project Lombok Authors.
Copyright (C) 2020-2022 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
@@ -43,6 +43,7 @@ This buildfile is part of projectlombok.org. It makes maven-compatible repositor
<fileset dir="src/launch" />
<fileset dir="src/utils" />
<fileset dir="src/eclipseAgent" />
<fileset dir="src/mavenEcjBootstrapAgent" />
<fileset dir="src/installer" />
<fileset dir="src/delombok" />
<fileset dir="test/transform/src" />