diff options
author | Alexander Kriegisch <Alexander@Kriegisch.name> | 2021-06-04 07:58:52 +0700 |
---|---|---|
committer | Alexander Kriegisch <Alexander@Kriegisch.name> | 2021-06-04 07:58:52 +0700 |
commit | 49cb924f5402c9d24379ae1af62def6fa5892649 (patch) | |
tree | 69844405209043e2e18aa9eef0f01f287bc1ae52 /build | |
parent | 82df3f0fc9842758f15f12299c9113e48f1ccb5c (diff) | |
download | aspectj-49cb924f5402c9d24379ae1af62def6fa5892649.tar.gz aspectj-49cb924f5402c9d24379ae1af62def6fa5892649.zip |
Upgrade license from CPLv1/EPLv1 to EPLv2
This was required by the Eclipse team as one precondition for the next
release.
Signed-off-by: Alexander Kriegisch <Alexander@Kriegisch.name>
Diffstat (limited to 'build')
34 files changed, 565 insertions, 574 deletions
diff --git a/build/build-properties.xml b/build/build-properties.xml index acfcac2c5..c735b855b 100644 --- a/build/build-properties.xml +++ b/build/build-properties.xml @@ -1,12 +1,12 @@ <!-- -*- Mode: SGML; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- --> <!-- ========================================================================= --> <!-- Copyright (c) 2002 Palo Alto Research Center, Incorporated (PARC). --> -<!-- Copyright (c) 2003, 2005 Contributors. --> +<!-- Copyright (c) 2003, 2005 Contributors. --> <!-- All rights reserved. --> <!-- This program and the accompanying materials are made available --> -<!-- under the terms of the Eclipse Public License v1.0 --> +<!-- under the terms of the Eclipse Public License v 2.0 --> <!-- which accompanies this distribution and is available at --> -<!-- http://www.eclipse.org/legal/epl-v10.html --> +<!-- https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt --> <!-- --> <!-- Contributors: --> <!-- Xerox/PARC initial implementation --> @@ -16,7 +16,7 @@ <!-- include as common entity for module build scripts --> <!-- should only need to edit version properties --> <project name="build-properties" default="init-properties"> - + <target name="init-properties" unless="init-properties.done"> <!-- callers should define aspectj.modules.dir --> @@ -24,7 +24,7 @@ <require-available property="local-properties" path="${aspectj.modules.dir}/build/local.properties"/> <property file="${aspectj.modules.dir}/build/local.properties"/> - <!-- + <!-- Changing version: - base should always be 1.1 (used for manifests, other version-parsing code) - Others should be DEVELOPMENT unless testing/doing release builds, when @@ -36,67 +36,67 @@ --> <property name="min.vm" value="13"/> <property name="max.vm" value="15"/> - <property name="build.verbose" value="false"/> - <property name="build.version" value="DEVELOPMENT"/> - <property name="build.version.base" value="1.2"/> - <property name="build.version.long" value="DEVELOPMENT"/> - <property name="build.version.short" value="DEVELOPMENT"/> + <property name="build.verbose" value="false"/> + <property name="build.version" value="DEVELOPMENT"/> + <property name="build.version.base" value="1.2"/> + <property name="build.version.long" value="DEVELOPMENT"/> + <property name="build.version.short" value="DEVELOPMENT"/> <!-- formats comply with SimpleDateFormat --> - <property name="build.time.format" value="EEEE MMM d, yyyy 'at' HH:mm:ss z"/> - <property name="build.date.format" value="EEEE MMM d, yyyy"/> + <property name="build.time.format" value="EEEE MMM d, yyyy 'at' HH:mm:ss z"/> + <property name="build.date.format" value="EEEE MMM d, yyyy"/> <tstamp> - <format property="build.date" + <format property="build.date" pattern="${build.date.format}" timezone="GMT"/> - <format property="build.time" + <format property="build.time" pattern="${build.time.format}" timezone="GMT"/> </tstamp> - + <property name="company.name" value="aspectj.org"/> <property name="copyright.allRights.from1998" value="Copyright (c) 1998-2001 Xerox Corporation, 2002 Palo Alto Research Center, Incorporated, 2003-2008 Contributors. All rights reserved." /> - + <!-- aj... names are generated, can be mutated/cleaned --> <!-- these names are known to BuildModule.java and common to all --> - <property name="aj.build.dir" + <property name="aj.build.dir" location="${aspectj.modules.dir}/aj-build"/> - <property name="aj.temp.dir" + <property name="aj.temp.dir" location="${aj.build.dir}/temp"/> - <property name="aj.src.dir" + <property name="aj.src.dir" location="${aj.build.dir}/src"/> - <property name="aj.jar.dir" + <property name="aj.jar.dir" location="${aj.build.dir}/jars"/> - <property name="aj.dist.dir" + <property name="aj.dist.dir" location="${aj.build.dir}/dist"/> - <property name="aj.webDeploy.dir" + <property name="aj.webDeploy.dir" location="${aj.build.dir}/webDeploy"/> - <property name="aj.install.dir" + <property name="aj.install.dir" location="${aj.build.dir}/install"/> - <property name="aj.build.allresults.dir" + <property name="aj.build.allresults.dir" location="${aj.build.dir}/allresults"/> - <property name="aj.build.allfailures.file" + <property name="aj.build.allfailures.file" location="${aj.build.allresults.dir}/allfailures.txt"/> - <property name="aj.build.results.dir" + <property name="aj.build.results.dir" location="${aj.build.dir}/results"/> <property name="aj.failure.file" location="${aj.build.results.dir}/failures.txt"/> - <property name="aj.build-id.file" + <property name="aj.build-id.file" location="${aj.build.results.dir}/build-id.txt"/> - <property name="aj.junit.dir" + <property name="aj.junit.dir" location="${aj.build.results.dir}/junit"/> - <property name="aj.logs.dir" + <property name="aj.logs.dir" location="${aj.build.results.dir}/logs"/> - + <!-- aspectj... names are sources, not to be mutated --> <property name="aspectj.modules.lib.dir" location="${aspectj.modules.dir}/lib"/> - <property name="aspectj.modules.build.dir" + <property name="aspectj.modules.build.dir" location="${aspectj.modules.dir}/build"/> - <property name="aspectj.modules.docs.dir" + <property name="aspectj.modules.docs.dir" location="${aspectj.modules.dir}/docs"/> <property name="aspectj.modules.tests.dir" location="${aspectj.modules.dir}/tests"/> @@ -107,19 +107,19 @@ location="${aspectj.modules.dir}/tests"/> <property file="${aspectj.modules.build.dir}/junit-patterns.properties"/> - + <property name="aspectj.tools.modules.13" value="ajbrowser,ajde,ajde.core,ajdoc,asm,bridge,loadtime,org.aspectj.ajdt.core,runtime,taskdefs,util,weaver"/> <property name="aspectj.tools.modules.15" value="loadtime5,aspectj5rt,weaver5"/> <condition property="aspectj.tools.modules" value="${aspectj.tools.modules.13},${aspectj.tools.modules.15}"> - <equals arg1="1.5" arg2="${ant.java.version}"/> + <equals arg1="1.5" arg2="${ant.java.version}"/> </condition> <condition property="aspectj.tools.modules" value="${aspectj.tools.modules.13}"> <not> - <equals arg1="1.5" arg2="${ant.java.version}"/> + <equals arg1="1.5" arg2="${ant.java.version}"/> </not> </condition> <property name="aspectj.test.modules" @@ -128,8 +128,8 @@ value="tests"/> <property name="aspectj.other.modules" value="docs,eclipse.plugin"/> - - <jar-property name="junit.jar" + + <jar-property name="junit.jar" location="${aspectj.modules.lib.dir}/junit/junit.jar"/> <!-- TODO need version-specific JDK? --> <guarded-property name="jdk.tools.jar" @@ -141,12 +141,12 @@ <property name="init-properties.done" value="true"/> </target> - <target name="init-taskdefs" + <target name="init-taskdefs" depends="init-properties" unless="init-taskdefs.done" > - <jar-property name="aspectj.build.jar" + <jar-property name="aspectj.build.jar" location="${aspectj.modules.lib.dir}/build/build.jar"/> - <jar-property name="lib.ant.jar" + <jar-property name="lib.ant.jar" location="${aspectj.modules.lib.dir}/ant/lib/ant.jar"/> <taskdef resource="org/aspectj/internal/tools/ant/taskdefs/taskdefs.properties" classpath="${aspectj.build.jar}"/> @@ -155,12 +155,12 @@ <include name="**/*.jar"/> </fileset> </path> - <taskdef name="junit" + <taskdef name="junit" classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitTask" classpathref="ant.lib.path"/> - <available classname="org.apache.xalan.processor.TransformerFactoryImpl" + <available classname="org.apache.xalan.processor.TransformerFactoryImpl" property="xalan.available" - value="true"> + value="true"> <classpath refid="ant.lib.path"/> </available> <condition property="junitreport.available" value="true"> @@ -172,12 +172,12 @@ <target name="init-junitreport" depends="init-properties" if="xalan.available"> - <taskdef name="junitreport" + <taskdef name="junitreport" classname="org.apache.tools.ant.taskdefs.optional.junit.XMLResultAggregator" classpathref="ant.lib.path"/> </target> - <target name="init-directories" + <target name="init-directories" depends="init-properties" description="ensure dirs, possibly many times in a build"> <mkdir dir="${aj.build.dir}" /> @@ -193,20 +193,20 @@ unless="init-filters.done" > <!-- build.version and build.date used in filters throughout, and - build.version.base used in filtering manifest, but + build.version.base used in filtering manifest, but others used mainly for installer-resources/properties.txt --> - <filter token="build.version" value="${build.version}"/> - <filter token="build.version.base" value="${build.version.base}"/> - <filter token="build.version.long" value="${build.version.long}"/> - <filter token="build.version.short" value="${build.version.short}"/> + <filter token="build.version" value="${build.version}"/> + <filter token="build.version.base" value="${build.version.base}"/> + <filter token="build.version.long" value="${build.version.long}"/> + <filter token="build.version.short" value="${build.version.short}"/> - <filter token="build.time.format" value="${build.time.format}"/> - <filter token="build.date.format" value="${build.date.format}"/> + <filter token="build.time.format" value="${build.time.format}"/> + <filter token="build.date.format" value="${build.date.format}"/> <filter token="build.date" value="${build.date}"/> <filter token="build.time" value="${build.time}"/> - <filter token="company.name" value="${company.name}"/> - <filter token="copyright.allRights.from1998" + <filter token="company.name" value="${company.name}"/> + <filter token="copyright.allRights.from1998" value="${copyright.allRights.from1998}" /> <property name="init-filters.done" value="done"/> </target> @@ -214,11 +214,11 @@ <target name="clean-directories" depends="init-properties"> <delete quiet="on"> <fileset dir="${aj.build.dir}" includes="*,**/*"/> - </delete> + </delete> <antcall target="init-directories"/> </target> - - <target name="clean-jars" + + <target name="clean-jars" depends="init-directories" unless="clean-jars.done" > <delete quiet="on"> @@ -226,30 +226,30 @@ </delete> <property name="clean-jars.done" value="done"/> </target> - + <target name="clean-keep-results" depends="init-properties"> <delete> <fileset dir="${aj.build.dir}"> - <exclude name="results/*"/> - <exclude name="results/**"/> - <exclude name="allresults/*"/> - <exclude name="allresults/**"/> - </fileset> - </delete> + <exclude name="results/*"/> + <exclude name="results/**"/> + <exclude name="allresults/*"/> + <exclude name="allresults/**"/> + </fileset> + </delete> </target> - + <target name="clean-default-results" depends="init-properties"> <delete> <fileset dir="${aj.build.results.dir}" includes="*,**/*"/> - </delete> + </delete> </target> - + <target name="clean-result" depends="init-properties"> <delete quiet="on"> <fileset dir="${aj.build.results.dir}" includes="*,**/*"/> </delete> </target> - + <macrodef name="save-build-id" description="save ${id} to ${aj.build-id.file}"> <attribute name="id"/> @@ -267,13 +267,13 @@ <loadfile srcfile="${aj.build-id.file}" property="@{property}"/> </sequential> </macrodef> - + <target name="ensure-build-id" unless="aj.build-id.file.available" description="create datestamp build id in ${aj.build-id.file} if n/a"> <tstamp> - <format property="build.id.name" + <format property="build.id.name" timezone="GMT+10" - pattern="yyyyMMdd-hhmmss" + pattern="yyyyMMdd-hhmmss" /> </tstamp> <echo file="${aj.build-id.file}" message="${build.id.name}"/> @@ -283,8 +283,8 @@ <load-build-id property="build.id"/> <copy todir="${aj.build.allresults.dir}/${build.id}"> <fileset dir="${aj.build.results.dir}" /> - </copy> - </target> + </copy> + </target> <target name="echo-properties" depends="init-properties"> <echo> @@ -318,12 +318,12 @@ <not> <isset property="@{name}"/> </not> - <available file="${@{name}.path}"/> + <available file="${@{name}.path}"/> </and> </condition> </sequential> </macrodef> - + <macrodef name="clean-dir"> <attribute name="dir"/> <sequential> @@ -335,13 +335,13 @@ </sequential> </macrodef> - <!-- + <!-- Reporting failures - - Failure-reports supports running multiple build targets in sequence for a - configuration, saving off those results, doing it over, etc., and then + + Failure-reports supports running multiple build targets in sequence for a + configuration, saving off those results, doing it over, etc., and then checking the result (of the current builds or all builds), i.e., - + # first set of builds - build, report-if-failed ... - build, report-if-failed ... @@ -354,40 +354,40 @@ - build, report-if-failed ... ... - save-result - + # fail build if anything in either set failed - - fail-if-allresults-allfailures + - fail-if-allresults-allfailures - Clients call + Clients call <report-if-failed property="failed" text="JUnit failed"/> to signal failure. This goes into results/failures.txt, to be read later. - Many clients can call this, across many (current) build invocations, so + Many clients can call this, across many (current) build invocations, so results just accumulate. Clients should never call <fail> directly; while the cruise-control script can handle build failures, they won't be recorded in a way that supports easy evaluation. - - To fail if the current builds fail, do + + To fail if the current builds fail, do <antcall target="fail-if-results-failures"/> - + You can do a sequence of builds (e.g., in 1.3), save the results off, and do it again (e.g., in 1.4), save the results, and then compare them. Use save-result to store the current build results in ../allresults. - + Between such builds, you can do a clean-keep-results (to clear out jars and such), followed by clean-default-results (to clear the current results). - (The normal clean also cleans out any results, so avoid that when saving + (The normal clean also cleans out any results, so avoid that when saving results from multiple builds.) - + Each build can be named using save-build-id. This name must be a valid directory name. When the results are saved to ../allresults, the directory name will use the most recent build-id. If none has been saved, then this creates a name out of the date (down to the second). - + To fail if any of the saved builds has failed, do fail-if-allresults-allfailures. This target ignores the current builds (if they are unsaved). --> - + <macrodef name="report-if-failed"> <attribute name="property"/> <attribute name="text"/> @@ -415,7 +415,7 @@ <target name="fail-if-allresults-allfailures" depends="init-properties"> <concat destfile="${aj.build.allfailures.file}"> - <fileset dir="${aj.build.allresults.dir}" + <fileset dir="${aj.build.allresults.dir}" includes="*/failures.txt"/> </concat> <fail-if-failures failureFile="${aj.build.allfailures.file}"/> @@ -425,19 +425,19 @@ description="fail if ${failureFile} exists and is not empty"> <attribute name="failureFile"/> <sequential> - <loadfile + <loadfile failonerror="false" - property="failures" + property="failures" srcfile="@{failureFile}"/> <fail> <condition> - <length file="@{failureFile}" + <length file="@{failureFile}" when="greater" length="0"/> </condition> -# @{failureFile} failures: +# @{failureFile} failures: ${failures} </fail> - </sequential> + </sequential> </macrodef> <macrodef name="jar-property"> <attribute name="name"/> @@ -452,15 +452,15 @@ ${failures} message="unable to find @{name}: ${@{name}}"/> </sequential> </macrodef> - + <macrodef name="set-available" description="set property and property.available if path exists"> <attribute name="property"/> <attribute name="path"/> <sequential> - <property name="@{property}.location" + <property name="@{property}.location" location="@{path}"/> - + <available property="@{property}" file="${@{property}.location}" value="${@{property}.location}"/> @@ -475,12 +475,12 @@ ${failures} <attribute name="path"/> <attribute name="message" default=""/> <sequential> - + <set-available property="@{property}" path="@{path}"/> <fail unless="@{property}.available"> @{message} (property "@{property}" not at "@{path}") </fail> </sequential> </macrodef> - + </project> diff --git a/build/build.xml b/build/build.xml index a24ced729..1ea2f5aa7 100644 --- a/build/build.xml +++ b/build/build.xml @@ -2,12 +2,12 @@ <!-- ========================================================================= --> <!-- Copyright (c) 2002 Palo Alto Research Center, Incorporated (PARC), --> -<!-- 2003-2005 Contributors --> +<!-- 2003-2005 Contributors --> <!-- All rights reserved. --> <!-- This program and the accompanying materials are made available --> -<!-- under the terms of the Eclipse Public License v1.0 --> +<!-- under the terms of the Eclipse Public License v 2.0 --> <!-- which accompanies this distribution and is available at --> -<!-- http://www.eclipse.org/legal/epl-v10.html --> +<!-- https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt --> <!-- --> <!-- Contributors: (See CVS checkin's) --> <!-- Xerox/PARC initial implementation --> diff --git a/build/lib/BridgeVersion.java.txt b/build/lib/BridgeVersion.java.txt index 36c1e0df4..047854cc6 100644 --- a/build/lib/BridgeVersion.java.txt +++ b/build/lib/BridgeVersion.java.txt @@ -2,10 +2,10 @@ * Copyright (c) 1998-2001 Xerox Corporation, * 2002 Palo Alto Research Center, Incorporated (PARC). * All rights reserved. - * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 + * This program and the accompanying materials are made available + * under the terms of the Eclipse Public License v 2.0 * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt * * Contributors: * Xerox/PARC initial implementation diff --git a/build/products/aspectj/install/intro.html b/build/products/aspectj/install/intro.html index b29bb9484..d5b543705 100644 --- a/build/products/aspectj/install/intro.html +++ b/build/products/aspectj/install/intro.html @@ -7,8 +7,8 @@ <p>This installs the complete AspectJ 9 Development Kit (AJDK) distribution, with the compiler, aspect libraries, structure browser, ant tasks, documentation, and examples. -This distribution is covered by the Eclipse Public License (see - http://www.eclipse.org/legal/epl-v10.html). +This distribution is covered by the Eclipse Public License v 2.0 (see +https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt). <p> For IDE integrations or source code, see the project home page at http://eclipse.org/aspectj</p> diff --git a/build/release/aspectj-cc.xml b/build/release/aspectj-cc.xml index 9b6c8bede..79f13ec8f 100644 --- a/build/release/aspectj-cc.xml +++ b/build/release/aspectj-cc.xml @@ -3,27 +3,27 @@ <!-- Copyright (c) 2005 Contributors. --> <!-- All rights reserved. --> <!-- This program and the accompanying materials are made available --> -<!-- under the terms of the Eclipse Public License v1.0 --> +<!-- under the terms of the Eclipse Public License v 2.0 --> <!-- which accompanies this distribution and is available at --> -<!-- http://www.eclipse.org/legal/epl-v10.html --> +<!-- https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt --> <!-- --> <!-- Contributors: (See CVS checkins) --> <!-- ========================================================================= --> <project name="aspectj-cc" basedir="." default="all"> - + <target name="all" depends="init"> <antcall target="cvs-update"/> <aspectj-build target="all"/> <antcall target="cc-complete"/> - </target> - + </target> + <target name="cvs-update" depends="init" description="update AspectJ source tree"> <cvs cvsroot="${cvs.root}" dest="${aspectj.modules.rdir}" - package="${cvs.module}" - quiet="on" - failonerror="on" + package="${cvs.module}" + quiet="on" + failonerror="on" command="update -dP" /> </target> @@ -31,7 +31,7 @@ description="post-process cruise control build"> <!-- see ${aj.build.dir}/failures.txt --> </target> - + <target name="create-cc-properties"> <propertyfile file="created-aspectj-cc.properties" comment="Rename to aspectj-cc.properties, put with aspectj-cc script"> @@ -54,55 +54,55 @@ </target> <target name="init" depends="init-properties"/> - + <target name="init-properties"> <property file="${basedir}/aspectj-cc.properties" /> <property name="aspectj.build.dir" - location="${basedir}/${aspectj.modules.rdir}/build"/> + location="${basedir}/${aspectj.modules.rdir}/build"/> <property name="local.properties" - location="${aspectj.build.dir}/local.properties"/> + location="${aspectj.build.dir}/local.properties"/> </target> - + <target name="check-local-properties"> <condition property="local.properties.empty" value="true"> - <length file="${local.properties}" + <length file="${local.properties}" when="equal" length="0"/> </condition> <antcall target="do-write-local-properties"/> </target> - + <target name="do-write-local-properties" depends="init" if="local.properties.empty" unless="do-write-local-properties.done"> <propertyfile file="${local.properties}"> - <entry key="build.version" value="${build.version}"/> - <entry key="build.version.base" value="${build.version.base}"/> - <entry key="build.version.long" value="${build.version.long}"/> - <entry key="build.version.short" value="${build.version.short}"/> - <entry key="java.13" value="${java.13}"/> - <entry key="java.14" value="${java.14}"/> - <entry key="java.15" value="${java.15}"/> + <entry key="build.version" value="${build.version}"/> + <entry key="build.version.base" value="${build.version.base}"/> + <entry key="build.version.long" value="${build.version.long}"/> + <entry key="build.version.short" value="${build.version.short}"/> + <entry key="java.13" value="${java.13}"/> + <entry key="java.14" value="${java.14}"/> + <entry key="java.15" value="${java.15}"/> </propertyfile> <property name="do-write-local-properties.done" value="true"/> </target> - + <macrodef name="aspectj-build"> <attribute name="target"/> <sequential> <antcall target="check-local-properties"/> <fail message="did not find local.properties=${local.properties}"> <condition> - <length file="${local.properties}" + <length file="${local.properties}" when="equal" length="0"/> </condition> </fail> <ant antfile="release/build.xml" target="@{target}" - dir="${basedir}/${aspectj.modules.rdir}/build" + dir="${basedir}/${aspectj.modules.rdir}/build" inheritAll="false" /> </sequential> </macrodef> - + </project> diff --git a/build/release/build.xml b/build/release/build.xml index 43196f63f..52ec9e770 100644 --- a/build/release/build.xml +++ b/build/release/build.xml @@ -2,9 +2,9 @@ <!-- Copyright (c) 2003-2005 Contributors. --> <!-- All rights reserved. --> <!-- This program and the accompanying materials are made available --> -<!-- under the terms of the Eclipse Public License v1.0 --> +<!-- under the terms of the Eclipse Public License v 2.0 --> <!-- which accompanies this distribution and is available at --> -<!-- http://www.eclipse.org/legal/epl-v10.html --> +<!-- https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt --> <!-- --> <!-- Contributors: --> <!-- Wes Isberg initial implementation --> @@ -13,23 +13,23 @@ <project name="build" default="all" basedir=".."> <property name="aspectj.modules.dir" location="${basedir}/.."/> - + <import file="${aspectj.modules.dir}/build/build-properties.xml"/> <import file="${aspectj.modules.dir}/build/release/release-tests.xml"/> <target name="info"> <echo message="see build.readme.txt and readme.txt"/> </target> - + <target name="init" depends="init-release-properties"> </target> - + <target name="init-release-properties" depends="init-properties,init-directories"> <property name="do.cvs" value="false"/> <property name="run.${min.vm}" value="true"/> <property name="run.14" value="false"/> <property name="run.${max.vm}" value="true"/> - + <property name="aspectj.build.props" value=""/> <property name="ant.verbose" value=""/> <property name="failonerror" value="false"/> @@ -42,7 +42,7 @@ <property name="harness.jar" location="${aj.jar.dir}/testing-drivers-test-all.jar"/> - + <property name="java.home.file" location="${aj.build.dir}/javahome.props.tmp"/> @@ -51,13 +51,13 @@ <property name="java14.command" location="${java14.home}/bin/java"/> - + <property name="java15.command" location="${java15.home}/bin/java"/> <mkdir dir="${aj.logs.dir}"/> </target> - + <target name="all" depends="init"> <build-aspectj vm="${min.vm}" target="clean"/> <save-build-id id="min-vm-${min.vm}"/> @@ -66,11 +66,11 @@ <!-- ANDY removed... build-aspectj vm="${min.vm}" target="test-each-module"/--> <build-aspectj vm="${max.vm}" target="junitreport"/> <build-aspectj vm="${max.vm}" target="save-result"/> - + <build-aspectj vm="${max.vm}" target="clean-keep-results"/> <!-- can't use safety of build-aspectj since deleting output file --> <antcall target="clean-default-results"/> - + <save-build-id id="max-vm-${max.vm}"/> <build-aspectj vm="${max.vm}" target="echo-properties"/> <build-aspectj vm="${max.vm}" target="all"/> @@ -78,15 +78,15 @@ <build-aspectj vm="${max.vm}" target="junitreport"/> <antcall target="install"/> <antcall target="product-tests"/> - <!-- TODO re-enable antcall target="harness-tests"/ --> + <!-- TODO re-enable antcall target="harness-tests"/ --> <!-- Temporary removal to see if build will work... --> <!--build-aspectj vm="13" target="compile-runtime-11"/--> - + <build-aspectj vm="${max.vm}" target="save-result"/> - + <antcall target="fail-if-allresults-allfailures"/> </target> - + <target name="install" depends="init-release-properties" description="install AspectJ distribution using Java min.vm=${min.vm}"> <antcall target="init-postBuild-properties"/> @@ -95,17 +95,17 @@ <clean-dir dir="${aj.install.dir}"/> <setup-vm vm="${min.vm}"/> <property file="${java.home.file}"/> - <fail unless="build.java.command" + <fail unless="build.java.command" message="failed to read ${build.java.command} from ${java.home.file}"/> - <java - fork="true" + <java + fork="true" jvm="${build.java.command}" - jar="${aspectj.jar}" + jar="${aspectj.jar}" failonerror="true"> <arg line="-to ${aj.install.dir}"/> </java> </target> - + <macrodef name="build-aspectj"> <attribute name="target"/> <attribute name="vm"/> @@ -114,20 +114,20 @@ <condition property="do.ant.props" value=" "> <not><isset property="do.ant.props"/></not> </condition> - + <antcall target="do-run-ant"> <param name="verbose" value="true"/> <param name="ant.dir" location="${aspectj.modules.build.dir}"/> <param name="run.ant.file" value="build.xml"/> <param name="ant.target" value="@{target}"/> - <param name="ant.output" + <param name="ant.output" location="${aj.logs.dir}/build-@{target}"/> - <param name="ant.properties" + <param name="ant.properties" value="${do.ant.props} ${aspectj.build.props}"/> </antcall> </sequential> </macrodef> - + <target name="do-run-ant" depends="init-release-properties" description="the ant we use to build"> <!-- we could use normal ant, but we enforce using @@ -139,17 +139,17 @@ <property name="ant.properties" value=""/> <property file="${java.home.file}"/> - <fail unless="build.java.home" + <fail unless="build.java.home" message="failed to read ${build.java.home} from ${java.home.file}"/> - <fail unless="build.java.version" + <fail unless="build.java.version" message="failed to read ${build.java.version} from ${java.home.file}"/> - <available property="aspectjrt.path" + <available property="aspectjrt.path" value="${aj.install.dir}/lib/aspectjrt.jar" file="${aj.install.dir}/lib/aspectjrt.jar"/> <available property="aspectjrt.path" - value="${lib.test.aspectjrt.jar}" + value="${lib.test.aspectjrt.jar}" file="${lib.test.aspectjrt.jar}"/> - <property name="ant.output.file" + <property name="ant.output.file" location="${ant.output}-${build.java.version}.txt"/> <echo> do-run-ant dir ${ant.dir} @@ -160,7 +160,7 @@ aspectjrt.path ${aspectjrt.path} </echo> - <java + <java fork="true" resultproperty="do-run-ant.result" failonerror="${failonerror}" @@ -176,13 +176,13 @@ <include name="*.jar"/> </fileset> <pathelement location="${junit.jar}"/> - <pathelement location="${build.java.home}/lib/tools.jar"/> + <pathelement location="${build.java.home}/lib/tools.jar"/> </classpath> <!-- urk - all properties for any client --> <!-- for any build --> <sysproperty key="JAVA_HOME" path="${build.java.home}"/> - <sysproperty key="ANT_HOME" + <sysproperty key="ANT_HOME" path="${aspectj.ant.home}"/> <!-- for ajde --> @@ -196,16 +196,16 @@ <arg line="-f ${run.ant.file} ${ant.target} ${ant.verbose} ${ant.properties}"/> </java> <condition property="do-run-ant.failed" value="true"> - <not><equals arg1="0" arg2="${do-run-ant.result}"/></not> + <not><equals arg1="0" arg2="${do-run-ant.result}"/></not> </condition> <echo message="dra: do-run-ant.failed=${do-run-ant.failed} do-run-ant.result=${do-run-ant.result}"/> <report-if-failed property="do-run-ant.failed" text="Build failed: ${ant.output.file}"/> </target> - + <macrodef name="do-vm-targets"> <attribute name="target"/> - <sequential> + <sequential> <do-vm-target target="@{target}" vm="min" /> <do-vm-target target="@{target}" vm="14" /> <do-vm-target target="@{target}" vm="max" /> @@ -220,7 +220,7 @@ </antcall> </sequential> </macrodef> - + <target name="do-13-target" if="run.13"> <setup-vm vm="13"/> <antcall target="${do.target}"/> @@ -235,7 +235,7 @@ <setup-vm vm="15"/> <antcall target="${do.target}"/> </target> - + <target name="do-min-target" if="run.${min.vm}"> <setup-vm vm="${min.vm}"/> <antcall target="${do.target}"/> @@ -247,7 +247,7 @@ </target> <macrodef name="setup-vm"> <attribute name="vm"/> - <sequential> + <sequential> <property name="wjf@{vm}.bjh" location="${java@{vm}.home}"/> <property name="wjf@{vm}.cmd" location="${wjf@{vm}.bjh}/bin/java"/> <delete file="${java.home.file}"/> @@ -259,4 +259,4 @@ </sequential> </macrodef> -</project>
\ No newline at end of file +</project> diff --git a/build/release/release-tests.xml b/build/release/release-tests.xml index 3caf9eaeb..6e2a334a4 100644 --- a/build/release/release-tests.xml +++ b/build/release/release-tests.xml @@ -2,25 +2,25 @@ <!-- Copyright (c) 2005 Contributors. --> <!-- All rights reserved. --> <!-- This program and the accompanying materials are made available --> -<!-- under the terms of the Eclipse Public License v1.0 --> +<!-- under the terms of the Eclipse Public License v 2.0 --> <!-- which accompanies this distribution and is available at --> -<!-- http://www.eclipse.org/legal/epl-v10.html --> +<!-- https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt --> <!-- --> <!-- Contributors: --> <!-- Wes Isberg initial implementation --> <!-- ========================================================================= --> <project name="release-tests" default="product-tests"> - + <target name="product-tests" unless="skip.test" description="run product tests"> <do-vm-targets target="test-build-examples"/> </target> - + <target name="init-postBuild-properties" depends="init-release-properties"> <require-available property="aspectj.jar" - path="${aj.dist.dir}/aspectj-${build.version}.jar"/> + path="${aj.dist.dir}/aspectj-${build.version}.jar"/> </target> - + <target name="init-sources-available" depends="init-release-properties" unless="sources.available"> <available property="sources.available" @@ -32,7 +32,7 @@ unless="aspectj.available"> <available property="aspectj.available" file="${aj.install.dir}" type="dir"/> - <fail unless="aspectj.available" + <fail unless="aspectj.available" message="install first in ${aj.install.dir}"/> </target> @@ -41,11 +41,11 @@ <available property="harness.available" classname="org.aspectj.testing.drivers.Harness" classpath="${harness.jar}"/> - <fail unless="harness.available" + <fail unless="harness.available" message="harness not found - first build-testing"/> </target> - - <target name="test-build-examples" + + <target name="test-build-examples" depends="init-postBuild-properties,init-aspectj-available"> <run-example name="bean"/> <run-example name="intro"/> @@ -63,21 +63,21 @@ <run-example name="nonGui"/> <echo message="TODO: setup and run compiler adapter example"/> </target> - + <target name="do-run-harness" depends="init-postBuild-properties,init-harness-available"> <fail unless="suite.filename" message="define suite.filename"/> <fail unless="harness.args" message="define harness.args"/> <fail unless="harness.suffix" message="define harness.suffix"/> - + <property name="drho.default.options" value="-release -logFail -killTemp"/> - + <property file="${java.home.file}"/> <fail unless="build.java.home" message="failed to read ${build.java.home} from ${java.home.file}"/> <fail unless="build.java.version" message="failed to read ${build.java.version} from ${java.home.file}"/> - + <property name="harness.output.file" location="${aj.logs.dir}/test-${suite.filename}${harness.suffix}-${build.java.version}.txt"/> <echo> do-run-harness ${suite.filename}.xml with options @@ -91,18 +91,18 @@ <arg line="${drho.default.options} ${harness.args}"/> </java> </target> - + <macrodef name="run-example"> <attribute name="name"/> <sequential> - + <antcall target="init"/> <antcall target="do-run-ant"> - <param name="ant.dir" + <param name="ant.dir" location="${aj.install.dir}/doc/examples"/> <param name="run.ant.file" value="build.xml"/> <param name="ant.target" value="@{name}"/> - <param name="ant.output" + <param name="ant.output" location="${aj.logs.dir}/test-example-@{name}"/> <param name="ant.properties" value=""/> <!-- XXX getting OOMemory - permit and investigate --> @@ -110,20 +110,20 @@ </antcall> </sequential> </macrodef> - - <target name="test-ajc-aspectj" + + <target name="test-ajc-aspectj" depends="init-postBuild-properties,init-aspectj-available,init-sources-available"> <antcall target="do-run-ant"> - <param name="ant.dir" + <param name="ant.dir" location="${aspectj.modules.dir}/tests/product/build-aspectj"/> <param name="run.ant.file" value="build.xml"/> <param name="ant.target" value=""/> - <param name="ant.output" + <param name="ant.output" location="${aj.logs.dir}/test-ajc-aspectj"/> </antcall> <delete quiet="on" dir="${aspectj.modules.dir}/tests/product/build-aspectj/output"/> </target> - + <!-- ==== source tests ==== --> <target name="test-sources"> <do-vm-targets target="do-test-sources-sequence"/> @@ -134,12 +134,12 @@ <antcall target="test-junit-modules"/> </target> - <target name="test-doc-links" + <target name="test-doc-links" depends="init-aspectj-available,init-harness-available" description="run link check against distribution"> <setup-vm vm="13"/> <property file="${java.home.file}"/> - <fail unless="build.java.home" + <fail unless="build.java.home" message="failed to read ${build.java.home} from ${java.home.file}"/> <property name="doclink.output.file" @@ -154,11 +154,11 @@ - progguide/printable.html has harmless empty link to d0e26 (ajc-ref?) </echo> - <java + <java classname="org.aspectj.testing.util.LinkCheck" fork="true" dir="${aj.install.dir}" - classpath="${harness.jar}" + classpath="${harness.jar}" jvm="${build.java.command}" output="${doclink.output.file}-out.txt"> <arg value="${doclink.start.file}"/> @@ -169,7 +169,7 @@ <sysproperty key="http.proxyPort" value="${proxy.port}" /> </java> </target> - + <target name="test-examples-11" depends="init-harness-available" description="run examples under JDK 1.1"> <property name="j11.home" @@ -182,7 +182,7 @@ <param name="suite.filename" value="ajcTestsExamples"/> <param name="harness.args" value="-1.1"/> <param name="harness.suffix" value="-run11"/> - <param name="harness.jvmline" + <param name="harness.jvmline" value="-Djavarun.fork=true -Djavarun.java=${java11.command} -Djavarun.java.home=${j11.home} -Djavarun.bootclasspath=${java11.classes.zip}"/> </antcall> </target> @@ -194,10 +194,10 @@ <build-aspectj vm="${max.vm}" target="build-testing-jars"/> <property name="build-testing.done" value="true"/> </target> - + <target name="harness-tests" depends="build-testing"> <!-- we could use harness variants, e.g., "-emacssym-", - but separating runs puts each variant in a different + but separating runs puts each variant in a different output file, which makes them easier to analyze. --> <antcall target="init-harness-available"/> @@ -206,15 +206,15 @@ <param name="harness.args" value="-ajctestSkipKeywords=expect-fail"/> <param name="harness.suffix" value="-pass"/> </antcall> - + <antcall target="do-run-harness"> <param name="suite.filename" value="ajcTests"/> <param name="harness.args" value=""/> <param name="harness.suffix" value=""/> </antcall> - <!-- - skip variants for now + <!-- + skip variants for now <antcall target="do-run-harness"> <param name="suite.filename" value="ajcTests"/> <param name="harness.args" value="-emacssym"/> @@ -248,5 +248,5 @@ </antcall> --> </target> - -</project>
\ No newline at end of file + +</project> diff --git a/build/src/main/java/$installer$/org/aspectj/Main.java b/build/src/main/java/$installer$/org/aspectj/Main.java index a307be930..745c9d715 100644 --- a/build/src/main/java/$installer$/org/aspectj/Main.java +++ b/build/src/main/java/$installer$/org/aspectj/Main.java @@ -3,9 +3,9 @@ * 2002 Palo Alto Research Center, Incorporated (PARC). * All rights reserved. * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 + * under the terms of the Eclipse Public License v 2.0 * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt * * Contributors: * Xerox/PARC initial implementation diff --git a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/AJInstaller.java b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/AJInstaller.java index a67872e8c..f432af159 100644 --- a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/AJInstaller.java +++ b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/AJInstaller.java @@ -3,9 +3,9 @@ * 2002 Palo Alto Research Center, Incorporated (PARC). * All rights reserved. * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 + * under the terms of the Eclipse Public License v 2.0 * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt * * Contributors: * Xerox/PARC initial implementation diff --git a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/AJPush.java b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/AJPush.java index 81e592553..3d4c0caa3 100644 --- a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/AJPush.java +++ b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/AJPush.java @@ -3,9 +3,9 @@ * 2002 Palo Alto Research Center, Incorporated (PARC). * All rights reserved. * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 + * under the terms of the Eclipse Public License v 2.0 * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt * * Contributors: * Xerox/PARC initial implementation diff --git a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/AntBuilder.java b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/AntBuilder.java index 82edad5ea..1bfdf8a63 100644 --- a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/AntBuilder.java +++ b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/AntBuilder.java @@ -2,9 +2,9 @@ * Copyright (c) 2002 Palo Alto Research Center, Incorporated (PARC). * All rights reserved. * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 + * under the terms of the Eclipse Public License v 2.0 * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt * * Contributors: * Xerox/PARC initial implementation diff --git a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/BuildModule.java b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/BuildModule.java index 6ac6b5ba6..5fc4b3943 100644 --- a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/BuildModule.java +++ b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/BuildModule.java @@ -1,17 +1,17 @@ /* ******************************************************************* - * Copyright (c) 1999-2001 Xerox Corporation, + * Copyright (c) 1999-2001 Xerox Corporation, * 2002 Palo Alto Research Center, Incorporated (PARC). - * All rights reserved. - * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Xerox/PARC initial implementation + * All rights reserved. + * This program and the accompanying materials are made available + * under the terms of the Eclipse Public License v 2.0 + * which accompanies this distribution and is available at + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt + * + * Contributors: + * Xerox/PARC initial implementation * ******************************************************************/ - + package org.aspectj.internal.tools.ant.taskdefs; import java.io.File; @@ -31,7 +31,7 @@ public class BuildModule extends Task { // quickie hack... public static void main(String[] args) { TestBuildModule.main(args); - } + } private static File pathToFile(Path path) { if (null != path) { @@ -49,47 +49,47 @@ public class BuildModule extends Task { // quickie hack... buildSpec = new BuildSpec(); setTaskName("ajbuild"); } - + public void setModuledir(Path moduleDir) { buildSpec.moduleDir = pathToFile(moduleDir); } - + public void setModule(String module) { // XXX handle multiple modules, same builder buildSpec.module = module; } - + public void setVersion(String version) { buildSpec.version = version; } public void setBasedir(Path baseDir) { buildSpec.baseDir = pathToFile(baseDir); } - + public void setJardir(Path jarDir) { buildSpec.jarDir = pathToFile(jarDir); } - + public void setTrimtesting(boolean trimTesting) { buildSpec.trimTesting = trimTesting; } - + public void setAssembleall(boolean assembleAll) { buildSpec.assembleAll = assembleAll; } - - public void setRebuild(boolean rebuild) { + + public void setRebuild(boolean rebuild) { buildSpec.rebuild = rebuild; } - - public void setFailonerror(boolean failonerror) { + + public void setFailonerror(boolean failonerror) { buildSpec.failonerror = failonerror; } - - public void setCreateinstaller(boolean create) { + + public void setCreateinstaller(boolean create) { buildSpec.createInstaller = create; } - - public void setVerbose(boolean verbose) { + + public void setVerbose(boolean verbose) { buildSpec.verbose = verbose; } @@ -98,47 +98,47 @@ public class BuildModule extends Task { // quickie hack... } // --------------------------------------------------------- product build - + public void setProductdir(Path productDir) { buildSpec.productDir = pathToFile(productDir); } - + public void setTempdir(Path tempDir) { buildSpec.tempDir = pathToFile(tempDir); } - + public void setDistdir(Path distdir) { buildSpec.distDir = pathToFile(distdir); } - + public void execute() throws BuildException { final BuildSpec buildSpec = this.buildSpec; this.buildSpec = new BuildSpec(); - build(buildSpec); + build(buildSpec); } - + private void build(BuildSpec buildSpec) throws BuildException { final boolean failonerror = buildSpec.failonerror; Builder builder = null; try { // try using script first if not a product boolean built = false; - if ((null == buildSpec.productDir) && (null != buildSpec.moduleDir)) { + if ((null == buildSpec.productDir) && (null != buildSpec.moduleDir)) { File buildScript = new File(buildSpec.moduleDir, "build.xml"); // XXXFileLiteral if (buildScript.canRead()) { built = buildByScript(buildSpec, buildScript); if (!built) { - log("unable to build " - + buildSpec - + " using script: " + log("unable to build " + + buildSpec + + " using script: " + buildScript.getAbsolutePath()); } - } + } } if (!built) { builder = AntBuilder.getBuilder( - buildSpec.buildConfig, - getProject(), + buildSpec.buildConfig, + getProject(), buildSpec.tempDir); if (!builder.build(buildSpec) && failonerror) { Location loc = getLocation(); @@ -157,9 +157,8 @@ public class BuildModule extends Task { // quickie hack... } } - boolean buildByScript(BuildSpec buildSpec, File buildScript) + boolean buildByScript(BuildSpec buildSpec, File buildScript) throws BuildException { return false; } } -
\ No newline at end of file diff --git a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/Checklics.java b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/Checklics.java index 1f9b132ec..20b4b8353 100644 --- a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/Checklics.java +++ b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/Checklics.java @@ -2,9 +2,9 @@ * Copyright (c) 2002 Palo Alto Research Center, Incorporated (PARC). * All rights reserved. * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 + * under the terms of the Eclipse Public License v 2.0 * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt * * Contributors: * Xerox/PARC initial implementation @@ -524,14 +524,14 @@ class HeaderInfo { } void writeRest(PrintWriter writer) { - writer.println(" * All rights reserved. "); - writer.println(" * This program and the accompanying materials are made available "); - writer.println(" * under the terms of the Eclipse Public License v1.0 "); - writer.println(" * which accompanies this distribution and is available at "); - writer.println(" * http://www.eclipse.org/legal/epl-v10.html "); - writer.println(" * "); - writer.println(" * Contributors: "); - writer.println(" * Xerox/PARC initial implementation "); + writer.println(" * All rights reserved."); + writer.println(" * This program and the accompanying materials are made available"); + writer.println(" * under the terms of the Eclipse Public License v 2.0"); + writer.println(" * which accompanies this distribution and is available at"); + writer.println(" * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt"); + writer.println(" * "); + writer.println(" * Contributors:"); + writer.println(" * Xerox/PARC initial implementation"); writer.println(" * ******************************************************************/"); writer.println(""); } @@ -541,14 +541,6 @@ class HeaderInfo { public static final String PARC_ONLY = " * Copyright (c) 2002 Palo Alto Research Center, Incorporated (PARC)."; public static final String XEROX_PREFIX = " * Copyright (c) "; public static final String XEROX_SUFFIX = " Xerox Corporation"; - /* - * /* ******************************************************************* Copyright (c) 1998-2001 Xerox Corporation, 2002 Palo - * Alto Research Center, Incorporated (PARC). All rights reserved. This program and the accompanying materials are made - * available under the terms of the Eclipse Public License v1.0 which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Xerox/PARC initial implementation ****************************************************************** - */ } /** diff --git a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/ConditionalTask.java b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/ConditionalTask.java index 431f9b25b..fd46c8adc 100644 --- a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/ConditionalTask.java +++ b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/ConditionalTask.java @@ -3,9 +3,9 @@ * 2002 Palo Alto Research Center, Incorporated (PARC). * All rights reserved. * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 + * under the terms of the Eclipse Public License v 2.0 * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt * * Contributors: * Xerox/PARC initial implementation diff --git a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/CopyAndInlineStylesheet.java b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/CopyAndInlineStylesheet.java index 664616c07..f76eb2b0d 100644 --- a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/CopyAndInlineStylesheet.java +++ b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/CopyAndInlineStylesheet.java @@ -1,14 +1,14 @@ /* ******************************************************************* - * Copyright (c) 1999-2001 Xerox Corporation, + * Copyright (c) 1999-2001 Xerox Corporation, * 2002 Palo Alto Research Center, Incorporated (PARC). - * All rights reserved. - * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Xerox/PARC initial implementation + * All rights reserved. + * This program and the accompanying materials are made available + * under the terms of the Eclipse Public License v 2.0 + * which accompanies this distribution and is available at + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt + * + * Contributors: + * Xerox/PARC initial implementation * ******************************************************************/ package org.aspectj.internal.tools.ant.taskdefs; @@ -35,7 +35,7 @@ public class CopyAndInlineStylesheet extends Task { public void setTodir(String todir) { this.todir = project.resolveFile(todir); } - + public void execute() throws BuildException { try { @@ -46,7 +46,7 @@ public class CopyAndInlineStylesheet extends Task { throw new BuildException("must set 'file' attribute"); } log("copying html from" + file + " to " + todir.getAbsolutePath()); - + File toFile = new File(todir, file.getName()); Mkdir mkdir = (Mkdir) project.createTask("mkdir"); @@ -71,7 +71,7 @@ public class CopyAndInlineStylesheet extends Task { out.println(line); } } - + in.close(); out.close(); } catch (IOException e) { @@ -90,7 +90,7 @@ public class CopyAndInlineStylesheet extends Task { out.println("<style type=\"text/css\">"); out.println("<!--"); - + BufferedReader inStyle = new BufferedReader(new FileReader(styleSheetFile)); while (true) { @@ -108,7 +108,7 @@ public class CopyAndInlineStylesheet extends Task { private static boolean isStyleSheet(String line) throws IOException { line = line.toLowerCase(); int len = line.length(); - int i = 0; + int i = 0; while (true) { if (i == len) return false; diff --git a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/StripNonBodyHtml.java b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/StripNonBodyHtml.java index 61e29f3b3..dd63ee7e8 100644 --- a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/StripNonBodyHtml.java +++ b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/StripNonBodyHtml.java @@ -1,14 +1,14 @@ /* ******************************************************************* - * Copyright (c) 1999-2001 Xerox Corporation, + * Copyright (c) 1999-2001 Xerox Corporation, * 2002 Palo Alto Research Center, Incorporated (PARC). - * All rights reserved. - * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Xerox/PARC initial implementation + * All rights reserved. + * This program and the accompanying materials are made available + * under the terms of the Eclipse Public License v 2.0 + * which accompanies this distribution and is available at + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt + * + * Contributors: + * Xerox/PARC initial implementation * ******************************************************************/ package org.aspectj.internal.tools.ant.taskdefs; @@ -173,7 +173,7 @@ public class StripNonBodyHtml extends MatchingTask { * @param start the starting tag (case sensitive) * @param end the ending tag (case sensitive) */ - String stripTags(String input, final String SOURCE, + String stripTags(String input, final String SOURCE, final String START, final String END) { if (null == input) return input; StringBuffer buffer = new StringBuffer(input.length()); @@ -190,8 +190,8 @@ public class StripNonBodyHtml extends MatchingTask { if (-1 == endLoc) { log(SOURCE + " stripTags - no end tag - startLoc=" + startLoc); break; // <------------ invalid exit - } else if (endLoc < startLoc) { - log(SOURCE + " stripTags - impossible: startLoc=" + } else if (endLoc < startLoc) { + log(SOURCE + " stripTags - impossible: startLoc=" + startLoc + " > endLoc=" + endLoc); break; // <------------ invalid exit } else { @@ -235,7 +235,7 @@ public class StripNonBodyHtml extends MatchingTask { } private static class ParseException extends Exception { - private static final long serialVersionUID = -1l; + private static final long serialVersionUID = -1l; } private static ParseException barf() { diff --git a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/TestBuildModule.java b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/TestBuildModule.java index bd3b99609..89f02784a 100644 --- a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/TestBuildModule.java +++ b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/TestBuildModule.java @@ -1,17 +1,17 @@ /* ******************************************************************* - * Copyright (c) 1999-2001 Xerox Corporation, + * Copyright (c) 1999-2001 Xerox Corporation, * 2002 Palo Alto Research Center, Incorporated (PARC). - * All rights reserved. - * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Xerox/PARC initial implementation + * All rights reserved. + * This program and the accompanying materials are made available + * under the terms of the Eclipse Public License v 2.0 + * which accompanies this distribution and is available at + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt + * + * Contributors: + * Xerox/PARC initial implementation * ******************************************************************/ - + package org.aspectj.internal.tools.ant.taskdefs; import java.io.File; @@ -26,7 +26,7 @@ public class TestBuildModule { // private static boolean REBUILD = false; private static final String SYNTAX = "java {classname} <[product|module]dir>"; public static void main(String[] args) { - + if ((null == args) || (1 > args.length) || !Util.canReadDir(new File(args[0]))) { System.err.println(SYNTAX); @@ -42,7 +42,7 @@ public class TestBuildModule { System.err.println(SYNTAX); } } - + static void createModule(String[] args) { File moduleDir = new File(args[0]); File baseDir = moduleDir.getParentFile(); @@ -51,10 +51,10 @@ public class TestBuildModule { } File jarDir = new File(baseDir, "aj-build-jars"); if (!(Util.canReadDir(jarDir) || jarDir.mkdirs())) { - System.err.println("createModule unable to create " + jarDir); + System.err.println("createModule unable to create " + jarDir); return; } - + // set module dir or basedir plus module name BuildSpec buildSpec = new BuildSpec(); buildSpec.moduleDir = moduleDir; @@ -71,9 +71,9 @@ public class TestBuildModule { Builder builder = AntBuilder.getBuilder("", project, tempDir); builder.build(buildSpec); } - + static void createProduct(String[] args) { throw new Error("unimplemented"); } -} +} diff --git a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/VersionUptodate.java b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/VersionUptodate.java index 92b271c69..070adf772 100644 --- a/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/VersionUptodate.java +++ b/build/src/main/java/org/aspectj/internal/tools/ant/taskdefs/VersionUptodate.java @@ -1,13 +1,13 @@ /* ******************************************************************* * Copyright (c) 2002 Palo Alto Research Center, Incorporated (PARC). - * All rights reserved. - * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Xerox/PARC initial implementation + * All rights reserved. + * This program and the accompanying materials are made available + * under the terms of the Eclipse Public License v 2.0 + * which accompanies this distribution and is available at + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt + * + * Contributors: + * Xerox/PARC initial implementation * ******************************************************************/ package org.aspectj.internal.tools.ant.taskdefs; @@ -21,7 +21,7 @@ import java.io.IOException; import org.apache.tools.ant.BuildException; import org.apache.tools.ant.Task; -/** +/** * Check if version source file has the specified build version, * and ensure a tag file reflects whether it does or not. */ @@ -31,30 +31,30 @@ public class VersionUptodate extends Task { private String buildVersion; private File versionSource; private File versionTagFile; - - /** + + /** * @param buildVersion String expected as Version.text - required */ public void setVersion(String buildVersion) { this.buildVersion = buildVersion; } - /** - * @param versionSource the File Version.java containing text constant + /** + * @param versionSource the File Version.java containing text constant * - required */ public void setVersionSourceFile(File versionSource) { this.versionSource = versionSource; } - - /** + + /** * @param versionTagFile the File whose existence signals that the version * is uptodate after this task executes - required. */ public void setVersionTagFile(File versionTagFile) { this.versionTagFile = versionTagFile; } - + /** * If the Version.java source file contains the correct * build version, then create the output tag file, @@ -84,7 +84,7 @@ public class VersionUptodate extends Task { } } } - + /** * Detect whether version is correct in Java sources. * @param versionSource @@ -114,9 +114,9 @@ public class VersionUptodate extends Task { } catch (IOException e) { } } - } + } } - + /** * Create file with contents */ @@ -139,6 +139,6 @@ public class VersionUptodate extends Task { } } } - -} + +} diff --git a/build/src/main/java/org/aspectj/internal/tools/build/BuildSpec.java b/build/src/main/java/org/aspectj/internal/tools/build/BuildSpec.java index ed0a453e1..9d6968f72 100644 --- a/build/src/main/java/org/aspectj/internal/tools/build/BuildSpec.java +++ b/build/src/main/java/org/aspectj/internal/tools/build/BuildSpec.java @@ -1,24 +1,24 @@ /* ******************************************************************* - * Copyright (c) 1999-2001 Xerox Corporation, + * Copyright (c) 1999-2001 Xerox Corporation, * 2002 Palo Alto Research Center, Incorporated (PARC), * 2005 Contributors. - * All rights reserved. - * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Xerox/PARC initial implementation + * All rights reserved. + * This program and the accompanying materials are made available + * under the terms of the Eclipse Public License v 2.0 + * which accompanies this distribution and is available at + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt + * + * Contributors: + * Xerox/PARC initial implementation * ******************************************************************/ - + package org.aspectj.internal.tools.build; import java.io.File; -/** +/** * Open struct for specifying builds for both modules and products. * Separated from bulder to permit this to build many modules * concurrently. @@ -31,7 +31,7 @@ public class BuildSpec { public File jarDir; public File tempDir; public File stagingDir; - public String buildConfig; + public String buildConfig; public String version; public boolean rebuild; public boolean trimTesting; @@ -43,13 +43,13 @@ public class BuildSpec { public File productDir; public boolean createInstaller; public File distDir; - + // building modules public String module; public BuildSpec() { version = DEFAULT_VERSION; } - + public boolean isProduct() { return (Util.canReadDir(productDir)); } @@ -61,7 +61,7 @@ public class BuildSpec { public boolean isValid() { return (isProduct() || isModule()); } - + public String toString() { if (null != productDir) { return "product " + productDir.getName(); diff --git a/build/src/main/java/org/aspectj/internal/tools/build/Builder.java b/build/src/main/java/org/aspectj/internal/tools/build/Builder.java index b43578dd3..94e8c7997 100644 --- a/build/src/main/java/org/aspectj/internal/tools/build/Builder.java +++ b/build/src/main/java/org/aspectj/internal/tools/build/Builder.java @@ -3,9 +3,9 @@ * 2003 Contributors. * All rights reserved. * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 + * under the terms of the Eclipse Public License v 2.0 * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt * * Contributors: * PARC initial implementation diff --git a/build/src/main/java/org/aspectj/internal/tools/build/Messager.java b/build/src/main/java/org/aspectj/internal/tools/build/Messager.java index 4752fd645..80b8ce5f4 100644 --- a/build/src/main/java/org/aspectj/internal/tools/build/Messager.java +++ b/build/src/main/java/org/aspectj/internal/tools/build/Messager.java @@ -1,17 +1,17 @@ /* ******************************************************************* - * Copyright (c) 1999-2001 Xerox Corporation, + * Copyright (c) 1999-2001 Xerox Corporation, * 2002 Palo Alto Research Center, Incorporated (PARC). - * All rights reserved. - * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Xerox/PARC initial implementation + * All rights reserved. + * This program and the accompanying materials are made available + * under the terms of the Eclipse Public License v 2.0 + * which accompanies this distribution and is available at + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt + * + * Contributors: + * Xerox/PARC initial implementation * ******************************************************************/ - + package org.aspectj.internal.tools.build; /** logging stub XXX replace */ @@ -22,12 +22,12 @@ public class Messager { System.out.println(s); return true; } - + public boolean error(String s) { System.out.println(s); return true; } - + public boolean logException(String context, Throwable thrown) { System.err.println(context); thrown.printStackTrace(System.err); diff --git a/build/src/main/java/org/aspectj/internal/tools/build/Module.java b/build/src/main/java/org/aspectj/internal/tools/build/Module.java index 9d10e4743..07743a5db 100644 --- a/build/src/main/java/org/aspectj/internal/tools/build/Module.java +++ b/build/src/main/java/org/aspectj/internal/tools/build/Module.java @@ -3,9 +3,9 @@ * 2002 Palo Alto Research Center, Incorporated (PARC). * All rights reserved. * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 + * under the terms of the Eclipse Public License v 2.0 * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt * * Contributors: * Xerox/PARC initial implementation diff --git a/build/src/main/java/org/aspectj/internal/tools/build/Modules.java b/build/src/main/java/org/aspectj/internal/tools/build/Modules.java index ca2b50aac..9f14db899 100644 --- a/build/src/main/java/org/aspectj/internal/tools/build/Modules.java +++ b/build/src/main/java/org/aspectj/internal/tools/build/Modules.java @@ -1,34 +1,34 @@ /* ******************************************************************* - * Copyright (c) 1999-2001 Xerox Corporation, + * Copyright (c) 1999-2001 Xerox Corporation, * 2002 Palo Alto Research Center, Incorporated (PARC). - * All rights reserved. - * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Xerox/PARC initial implementation + * All rights reserved. + * This program and the accompanying materials are made available + * under the terms of the Eclipse Public License v 2.0 + * which accompanies this distribution and is available at + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt + * + * Contributors: + * Xerox/PARC initial implementation * ******************************************************************/ - + package org.aspectj.internal.tools.build; import java.io.File; import java.util.Hashtable; -/** - * Registration and factory for modules +/** + * Registration and factory for modules * @see Module * @see Builder */ public class Modules { - + private final Hashtable<String,Module> modules = new Hashtable<>(); public final File baseDir; public final File jarDir; private final Messager handler; - + public Modules(File baseDir, File jarDir, Messager handler) { this.baseDir = baseDir; this.jarDir = jarDir; @@ -37,9 +37,9 @@ public class Modules { Util.iaxIfNotCanReadDir(jarDir, "jarDir"); Util.iaxIfNull(handler, "handler"); } - - - /** + + + /** * Get module associated with name. * @return fail if unable to find or create module {name}. */ @@ -59,8 +59,8 @@ public class Modules { } else { handler.error("invalid module: " + result.toLongString()); } - } + } } return result; } -}
\ No newline at end of file +} diff --git a/build/src/main/java/org/aspectj/internal/tools/build/ProductModule.java b/build/src/main/java/org/aspectj/internal/tools/build/ProductModule.java index c695a4f8e..2ed25d419 100644 --- a/build/src/main/java/org/aspectj/internal/tools/build/ProductModule.java +++ b/build/src/main/java/org/aspectj/internal/tools/build/ProductModule.java @@ -1,13 +1,13 @@ /* ******************************************************************* * Copyright (c) 2002 Palo Alto Research Center, Incorporated (PARC). - * All rights reserved. - * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Xerox/PARC initial implementation + * All rights reserved. + * This program and the accompanying materials are made available + * under the terms of the Eclipse Public License v 2.0 + * which accompanies this distribution and is available at + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt + * + * Contributors: + * Xerox/PARC initial implementation * ******************************************************************/ package org.aspectj.internal.tools.build; @@ -16,29 +16,29 @@ import java.io.File; /** * Struct associating module with target product distribution jar * and assembly instructions. - * When building product distributions, a zero-length jar file - * in the dist directory may signify a module to be built, + * When building product distributions, a zero-length jar file + * in the dist directory may signify a module to be built, * renamed, and included in the distribution. */ public class ProductModule { /** name of distribution directory in product directory */ private static final String DIST = "dist"; - + /** top-level product directory being produced */ public final File productDir; - + /** path to file in distribution template dir for this module jar */ public final File replaceFile; - + /** relative path within distribution of this product module jar */ public final String relativePath; - + /** the module jar is the file to replace */ public final Module module; /** if true, assemble all when building module */ public final boolean assembleAll; - + public ProductModule(File productDir, File replaceFile, Module module, boolean assembleAll) { this.replaceFile = replaceFile; this.module = module; @@ -50,7 +50,7 @@ public class ProductModule { String productDirPath = productDir.getAbsolutePath(); String replaceFilePath = replaceFile.getAbsolutePath(); if (!replaceFilePath.startsWith(productDirPath)) { - String m = "\"" + replaceFilePath + String m = "\"" + replaceFilePath + "\" does not start with \"" + productDirPath + "\""; @@ -58,7 +58,7 @@ public class ProductModule { } replaceFilePath = replaceFilePath.substring(1+productDirPath.length()); if (!replaceFilePath.startsWith(DIST)) { - String m = "\"" + replaceFilePath + String m = "\"" + replaceFilePath + "\" does not start with \"" + DIST + "\""; throw new IllegalArgumentException(m); } diff --git a/build/src/main/java/org/aspectj/internal/tools/build/Result.java b/build/src/main/java/org/aspectj/internal/tools/build/Result.java index 22b92c8af..ef14c8617 100644 --- a/build/src/main/java/org/aspectj/internal/tools/build/Result.java +++ b/build/src/main/java/org/aspectj/internal/tools/build/Result.java @@ -2,9 +2,9 @@ * Copyright (c) 2005 Contributors. * All rights reserved. * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 + * under the terms of the Eclipse Public License v 2.0 * which accompanies this distribution and is available at - * http://eclipse.org/legal/epl-v10.html + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt * * Contributors: * Wes Isberg initial implementation diff --git a/build/src/main/java/org/aspectj/internal/tools/build/SampleGatherer.java b/build/src/main/java/org/aspectj/internal/tools/build/SampleGatherer.java index 2864bb92f..6ac1f45eb 100644 --- a/build/src/main/java/org/aspectj/internal/tools/build/SampleGatherer.java +++ b/build/src/main/java/org/aspectj/internal/tools/build/SampleGatherer.java @@ -2,9 +2,9 @@ * Copyright (c) 2003 Contributors. * All rights reserved. * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 + * under the terms of the Eclipse Public License v 2.0 * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt * * Contributors: * Wes Isberg initial implementation @@ -448,16 +448,16 @@ class SamplesRenderer { public static final String COPYRIGHT = "<p><small>Copyright 2003 Contributors. All Rights Reserved. " - + "This sample code is made available under the Common Public " - + "License version 1.0 available at " - + "<a href=\"http://www.eclipse.org/legal/epl-v10.html\">" - + "http://www.eclipse.org/legal/epl-v10.html</a>." + + "This sample code is made available under the Eclipse Public " + + "License v 2.0 available at " + + "<a href=\"https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt\">" + + "https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt</a>. " + "Contributors are listed in this document as authors. " + "Permission to republish portions of this sample code " + "is hereby granted if the publication acknowledges " + "the author by name and " + "the source by reference to the AspectJ project home page " - + " at http://eclipse.org/aspectj.</small></p>" + + "at http://eclipse.org/aspectj.</small></p>" + EOL; /** template algorithm to render */ diff --git a/build/src/main/java/org/aspectj/internal/tools/build/Util.java b/build/src/main/java/org/aspectj/internal/tools/build/Util.java index cd7d6623f..071826b47 100644 --- a/build/src/main/java/org/aspectj/internal/tools/build/Util.java +++ b/build/src/main/java/org/aspectj/internal/tools/build/Util.java @@ -3,9 +3,9 @@ * 2002 Palo Alto Research Center, Incorporated (PARC). * All rights reserved. * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 + * under the terms of the Eclipse Public License v 2.0 * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt * * Contributors: * Xerox/PARC initial implementation diff --git a/build/src/main/resources/$installer$/org/aspectj/resources/intro.html b/build/src/main/resources/$installer$/org/aspectj/resources/intro.html index b29bb9484..d5b543705 100644 --- a/build/src/main/resources/$installer$/org/aspectj/resources/intro.html +++ b/build/src/main/resources/$installer$/org/aspectj/resources/intro.html @@ -7,8 +7,8 @@ <p>This installs the complete AspectJ 9 Development Kit (AJDK) distribution, with the compiler, aspect libraries, structure browser, ant tasks, documentation, and examples. -This distribution is covered by the Eclipse Public License (see - http://www.eclipse.org/legal/epl-v10.html). +This distribution is covered by the Eclipse Public License v 2.0 (see +https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt). <p> For IDE integrations or source code, see the project home page at http://eclipse.org/aspectj</p> diff --git a/build/src/test/java/org/aspectj/build/BuildModuleTests.java b/build/src/test/java/org/aspectj/build/BuildModuleTests.java index 46f5b15a0..64f8b1016 100644 --- a/build/src/test/java/org/aspectj/build/BuildModuleTests.java +++ b/build/src/test/java/org/aspectj/build/BuildModuleTests.java @@ -1,15 +1,15 @@ package org.aspectj.build; /* ******************************************************************* - * Copyright (c) 1999-2001 Xerox Corporation, + * Copyright (c) 1999-2001 Xerox Corporation, * 2002 Palo Alto Research Center, Incorporated (PARC). - * All rights reserved. - * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Xerox/PARC initial implementation + * All rights reserved. + * This program and the accompanying materials are made available + * under the terms of the Eclipse Public License v 2.0 + * which accompanies this distribution and is available at + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt + * + * Contributors: + * Xerox/PARC initial implementation * ******************************************************************/ @@ -40,19 +40,19 @@ public class BuildModuleTests extends TestCase { /** if true, then replace old headers with new first */ private static final boolean replacing = false; // XXX never to enable again... - + /** replace commented out below - if any replace failed, halt all */ private static boolean replaceFailed = false; - + private static final String BASE_DIR = ".." + File.separator; private static final String[] JDT_SOURCE_DIRS = new String[] {}; - public static Test suite() { + public static Test suite() { TestSuite suite = new TestSuite("Build module tests"); - suite.addTestSuite(BuildModuleTests.class); - suite.addTestSuite(BuildModuleTest.class); - suite.addTestSuite(ModulesTest.class); - suite.addTestSuite(UtilsTest.class); + suite.addTestSuite(BuildModuleTests.class); + suite.addTestSuite(BuildModuleTest.class); + suite.addTestSuite(ModulesTest.class); + suite.addTestSuite(UtilsTest.class); return suite; } @@ -87,29 +87,29 @@ public class BuildModuleTests extends TestCase { } } public void testLicense_ajbrowser() { - checkLicense("ajbrowser"); + checkLicense("ajbrowser"); } public void testLicense_ajde() { - checkLicense("ajde"); + checkLicense("ajde"); } public void testLicense_aspectj5rt() { - checkLicense("aspectj5rt"); + checkLicense("aspectj5rt"); } public void testLicense_asm() { - checkLicense("asm"); + checkLicense("asm"); } public void testLicense_bridge() { - checkLicense("bridge"); + checkLicense("bridge"); } public void testLicense_build() { - checkLicense("build"); + checkLicense("build"); } public void testLicense_org_aspectj_ajdt_core() { - checkLicense("org.aspectj.ajdt.core"); + checkLicense("org.aspectj.ajdt.core"); } public void testLicense_org_aspectj_lib() { - checkLicense("org.aspectj.lib"); + checkLicense("org.aspectj.lib"); } public void testLicense_org_eclipse_jdt_core() { final String mod = "org.eclipse.jdt.core"; @@ -118,48 +118,48 @@ public class BuildModuleTests extends TestCase { checkSourceDirectory(new File(pre + jdtSourceDir), mod); } } - + public void testLicense_runtime() { - checkLicense("runtime"); + checkLicense("runtime"); } public void testLicense_taskdefs() { - checkLicense("taskdefs"); + checkLicense("taskdefs"); } public void testLicense_testing() { - checkLicense("testing"); + checkLicense("testing"); } public void testLicense_testing_client() { - checkLicense("testing-client"); + checkLicense("testing-client"); } public void testLicense_testing_drivers() { - checkLicense("testing-drivers"); + checkLicense("testing-drivers"); } public void testLicense_testing_util() { - checkLicense("testing-util"); + checkLicense("testing-util"); } public void testLicense_util() { - checkLicense("util"); + checkLicense("util"); } - + public void testLicense_weaver() { String module = "weaver"; // skip (testdata) packages fluffy, reflect checkSourceDirectory(new File(Util.path(new String[] {"..", module, "src","main","java"})), module); checkSourceDirectory(new File(Util.path(new String[] {"..", module, "src","test","java", "org"})), module); } - + public void testLicense_ajdoc() { checkLicense("ajdoc"); } - + public void testLicense_loadtime() { checkLicense("loadtime"); } - + public void testLicense_loadtime5() { checkLicense("loadtime5"); } - + public void testLicense_weaver5() { checkLicense("weaver5"); } @@ -172,7 +172,7 @@ public class BuildModuleTests extends TestCase { checkSourceDirectory(srcDir, module); } } - + void checkSourceDirectory(File srcDir, String module) { final String label = "source dir " + srcDir + " (module " + module + ")"; assertTrue(label, (srcDir.exists() && srcDir.isDirectory())); @@ -195,7 +195,7 @@ public class BuildModuleTests extends TestCase { } assertTrue(label + " fails", !BuildModuleTests.replaceFailed); } - + // separate check to verify all file types (suffixes) are known if (!isTestFolder(srcDir)) { ArrayList<File> unknownFiles = new ArrayList<>(); @@ -208,18 +208,18 @@ public class BuildModuleTests extends TestCase { } } } - + private boolean isTestFolder(File dir) { return dir.toString().contains("src"+File.separator+"test"+File.separator+"java"); } - + /** * Check tree for files not managed by the build system - * (either source files or managed as resources). + * (either source files or managed as resources). * This should pick up situations where new kinds of resources are added * to the tree without updating the build script patterns to pick them * up. - * @see Builder#BINARY_SOURCE_PATTERN + * @see Builder#BINARY_SOURCE_PATTERN * @see Builder#RESOURCE_PATTERN * @see org.aspectj.util.FileUtil#SOURCE_SUFFIXES */ @@ -234,12 +234,12 @@ public class BuildModuleTests extends TestCase { // sources from org.aspectj.util.FileUtil.SOURCE_SUFFIXES suffixes.add(".aj"); suffixes.add(".java"); - + // just because we know... suffixes.add(".html"); // others from Builder - final String input = Builder.BINARY_SOURCE_PATTERN + final String input = Builder.BINARY_SOURCE_PATTERN + "," + Builder.RESOURCE_PATTERN; StringTokenizer st = new StringTokenizer(input, ","); while (st.hasMoreTokens()) { @@ -256,15 +256,15 @@ public class BuildModuleTests extends TestCase { STATIC_ERRORS.add("unable to read pattern: " + s); } suffixes.add(token); - } + } KNOWN_SUFFIXES = Collections.unmodifiableList(suffixes); } - + private UnknownFileCheck() { - + } /** - * Return true if input File file is a valid path to a directory + * Return true if input File file is a valid path to a directory * or to a file * which is not hidden (starts with .) * and does not have a known suffix. @@ -274,7 +274,7 @@ public class BuildModuleTests extends TestCase { public boolean accept(File file) { if (null == file) { return false; - } + } if (file.isDirectory()) { return file.canRead(); } @@ -290,7 +290,7 @@ public class BuildModuleTests extends TestCase { } } return true; - + } void unknownFiles(File dir, ArrayList<File> results) { File[] files = dir.listFiles(this); @@ -305,7 +305,7 @@ public class BuildModuleTests extends TestCase { } } } - + } -} +} diff --git a/build/src/test/java/org/aspectj/internal/build/BuildClasspathTest.java b/build/src/test/java/org/aspectj/internal/build/BuildClasspathTest.java index c359e648c..813c58e30 100644 --- a/build/src/test/java/org/aspectj/internal/build/BuildClasspathTest.java +++ b/build/src/test/java/org/aspectj/internal/build/BuildClasspathTest.java @@ -2,9 +2,9 @@ * Copyright (c) 2005 Contributors. * All rights reserved. * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 + * under the terms of the Eclipse Public License v 2.0 * which accompanies this distribution and is available at - * http://eclipse.org/legal/epl-v10.html + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt * * Contributors: * Wes Isberg initial implementation diff --git a/build/src/test/java/org/aspectj/internal/build/BuildModuleTest.java b/build/src/test/java/org/aspectj/internal/build/BuildModuleTest.java index 33dac2a0a..f8f0b4bde 100644 --- a/build/src/test/java/org/aspectj/internal/build/BuildModuleTest.java +++ b/build/src/test/java/org/aspectj/internal/build/BuildModuleTest.java @@ -1,15 +1,15 @@ /* ******************************************************************* - * Copyright (c) 1999-2001 Xerox Corporation, + * Copyright (c) 1999-2001 Xerox Corporation, * 2002 Palo Alto Research Center, Incorporated (PARC), * 2005-2006 Contributors. - * All rights reserved. - * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Xerox/PARC initial implementation + * All rights reserved. + * This program and the accompanying materials are made available + * under the terms of the Eclipse Public License v 2.0 + * which accompanies this distribution and is available at + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt + * + * Contributors: + * Xerox/PARC initial implementation * ******************************************************************/ package org.aspectj.internal.build; @@ -40,7 +40,7 @@ import org.aspectj.internal.tools.build.Util; * will run; * (2) build.config takes the same form as it does for the * builder task, e.g., "useEclipseCompiles" will avoid - * recompiling with Javac and adopt classes in the + * recompiling with Javac and adopt classes in the * {module}/bin directories. */ public class BuildModuleTest extends TestCase { @@ -49,18 +49,18 @@ public class BuildModuleTest extends TestCase { private static boolean printedMessage; private static final boolean REMOVE_JARS_AFTER_DEBUGGING = true; // to just build one module verbosely - private static final String[] DEBUGS + private static final String[] DEBUGS = {}; // skip those requiring ajdoc, which requires tools.jar // also skip those requiring java5 unless manually set up // also skip big ones to avoid slowing the build too much - private static final String[] SKIPS + private static final String[] SKIPS //= {}; = {"aspectjtools", "ajdoc", "aspectj5rt", "run-all-junit-tests", "ajbrowser", "testing", "testing-drivers", "org.aspectj.ajdt.core", "weaver"}; - private static final String SKIP_MESSAGE = + private static final String SKIP_MESSAGE = "BuildModuleTest: Define \"run.build.tests\" as a system " + "property to run tests to build "; private static final String BUILD_CONFIG; @@ -76,12 +76,12 @@ public class BuildModuleTest extends TestCase { System.out.println("BuildModuleTest build.config: " + config); } } - + List<File> tempFiles = new ArrayList<>(); private File jarDir; private boolean deleteJars; boolean building; // must be enabled for tests to run - + public BuildModuleTest(String name) { super(name); building = Boolean.getBoolean("run.build.tests"); @@ -101,7 +101,7 @@ public class BuildModuleTest extends TestCase { } deleteTempFiles(); } - + protected void deleteTempFiles() { for (File file : tempFiles) { if (!Util.delete(file)) { @@ -127,12 +127,12 @@ public class BuildModuleTest extends TestCase { } public void testBuild() { - checkBuild("build", - Checklics.class.getName(), + checkBuild("build", + Checklics.class.getName(), new String[0], // help message true); // ant needed } - + public void testUtil() { checkBuild("util"); } @@ -140,16 +140,16 @@ public class BuildModuleTest extends TestCase { public void testAsm() { checkBuild("asm"); } - + public void testRuntime() { checkBuild("runtime"); } public void testAspectj5rt() { - checkBuild("aspectj5rt"); + checkBuild("aspectj5rt"); } - -// public void testLocalOutOfDate() { + +// public void testLocalOutOfDate() { // Messager handler = new Messager(); // File jarDir = new File("c:/home/ws/head/aj-build/jars"); // File baseDir = new File("c:/home/ws/head"); @@ -159,7 +159,7 @@ public class BuildModuleTest extends TestCase { // r.outOfDate(); // } // public void testAspectj5rtRequired() { -// File baseDir = new File(".."); +// File baseDir = new File(".."); // Modules modules = new Modules(baseDir, getJarDir(), new Messager()); // Module module = modules.getModule("aspectj5rt"); // Result result = module.getResult(Result.kind(true, true)); @@ -185,33 +185,33 @@ public class BuildModuleTest extends TestCase { } } public void testAjbrowser() { - checkBuild("ajbrowser", + checkBuild("ajbrowser", "org.aspectj.tools.ajbrowser.Main", new String[] {"-noExit", "-version"}); // compiler version } public void testTestingUtils() { - checkBuild("testing-util"); + checkBuild("testing-util"); } public void testAjdt() { - checkBuild("org.aspectj.ajdt.core", + checkBuild("org.aspectj.ajdt.core", "org.aspectj.tools.ajc.Main", new String[] { "-noExit", "-version" }); }// public void testTesting() { - checkBuild("testing", - "org.aspectj.testing.util.LangUtilTest", + checkBuild("testing", + "org.aspectj.testing.util.LangUtilTest", new String[] {"ignored"}); } public void testTestingDrivers() { - checkBuild("testing-drivers", - "org.aspectj.testing.drivers.Harness", + checkBuild("testing-drivers", + "org.aspectj.testing.drivers.Harness", new String[] {"-help"}); } public void testWeaver() { - checkBuild("weaver"); + checkBuild("weaver"); } - + // ajdoc relies on tools.jar public void testAspectjtools() { if (!shouldBuild("aspectjtools")) { @@ -261,7 +261,7 @@ public class BuildModuleTest extends TestCase { File getJUnitJar() { return new File("../lib/junit/junit.jar"); } - + File getJarDir() { if (null == jarDir) { File baseDir = new File("../aj-build/"); @@ -276,7 +276,7 @@ public class BuildModuleTest extends TestCase { } return jarDir; } - + BuildModule getTask(String module) { BuildModule task = new BuildModule(); Project project = new Project(); @@ -294,13 +294,13 @@ public class BuildModuleTest extends TestCase { } return task; } - - void checkBuild(String module) { + + void checkBuild(String module) { checkBuild(module, null, null, false); } - - void checkBuild(String module, - String classname, + + void checkBuild(String module, + String classname, String[] args) { checkBuild(module, classname, args, true); } @@ -364,7 +364,7 @@ public class BuildModuleTest extends TestCase { } return null; } - + private static String name(String module, boolean trimTesting, boolean assemble) { return module + (trimTesting?"":"-test") + (assemble?"-all":""); } @@ -378,15 +378,15 @@ public class BuildModuleTest extends TestCase { if (jar.exists()) { try { Thread.sleep(5000); - } catch (Throwable t) { + } catch (Throwable t) { } } if (jar.exists()) { assertTrue("cannot delete " + jar, jar.delete()); } } - void checkBuild(String module, - String classname, + void checkBuild(String module, + String classname, String[] args, boolean addAnt) { if (!shouldBuild(module)) { @@ -427,7 +427,7 @@ public class BuildModuleTest extends TestCase { assertTrue("BuildException running " + classname, false); } } - deleteJar(jar); + deleteJar(jar); } void doTask(String module, boolean trimTesting, boolean assembleAll) { doTask(module, trimTesting, assembleAll, false); diff --git a/build/src/test/java/org/aspectj/internal/build/ModulesTest.java b/build/src/test/java/org/aspectj/internal/build/ModulesTest.java index ce6d77d78..52f6f48dc 100644 --- a/build/src/test/java/org/aspectj/internal/build/ModulesTest.java +++ b/build/src/test/java/org/aspectj/internal/build/ModulesTest.java @@ -1,15 +1,15 @@ /* ******************************************************************* - * Copyright (c) 1999-2001 Xerox Corporation, + * Copyright (c) 1999-2001 Xerox Corporation, * 2002 Palo Alto Research Center, Incorporated (PARC), * 2005-2006 Contributors. - * All rights reserved. - * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Xerox/PARC initial implementation + * All rights reserved. + * This program and the accompanying materials are made available + * under the terms of the Eclipse Public License v 2.0 + * which accompanies this distribution and is available at + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt + * + * Contributors: + * Xerox/PARC initial implementation * Wes Isberg build tests * ******************************************************************/ package org.aspectj.internal.build; @@ -37,11 +37,11 @@ import org.aspectj.internal.tools.build.Util; import org.aspectj.internal.tools.build.Result.Kind; public class ModulesTest extends TestCase { - + public static final List<String> MODULE_NAMES; - + private static final File BASE_DIR = new File(".."); - + static { String[] names = { "ajbrowser", "ajde", "ajdoc", "asm", @@ -72,7 +72,7 @@ public class ModulesTest extends TestCase { } List<File> tempFiles = new ArrayList<>(); - + public ModulesTest(String name) { super(name); } @@ -85,7 +85,7 @@ public class ModulesTest extends TestCase { } } } - + Modules getModules(Messager handler) { File jarDir = new File("../aj-build-test-jars"); if (!jarDir.exists()) { @@ -98,7 +98,7 @@ public class ModulesTest extends TestCase { } return new Modules(baseDir, jarDir, handler); } - + public void testAllModulesCreation() { List<Module> badModules = new ArrayList<>(); for (String name: MODULE_NAMES) { @@ -124,7 +124,7 @@ public class ModulesTest extends TestCase { fail(sb.toString()); } } - + void checkModule(String s) { if ("docs".equals(s) || "lib".equals(s)) { return; @@ -135,13 +135,13 @@ public class ModulesTest extends TestCase { assertTrue(module.toLongString(), false); } } - + public void xtestClasspathCreation() { Modules modules = getModules(null); - + Module ajdt = modules.getModule("org.aspectj.ajdt.core"); assertTrue(ajdt.valid); - + Project project = new Project(); AntBuilder builder = getBuilder(project); Path classpath = new Path(project); @@ -153,7 +153,7 @@ public class ModulesTest extends TestCase { assertTrue(classpath.toString(), false); } } - + /** * This test requires two OSGI modules: * org.aspectj.util, which optionally depends on tempaspectjrt. @@ -163,11 +163,11 @@ public class ModulesTest extends TestCase { public void skip_testOSGIModuleCreation() { final String MODULE = "org.aspectj.util"; final String USES_MODULE = "tempaspectjrt"; - + Modules modules = getModules(null); Module newutil = modules.getModule(MODULE); assertTrue(newutil.valid); - + Project project = new Project(); AntBuilder builder = getBuilder(project); Path classpath = new Path(project); @@ -188,10 +188,10 @@ public class ModulesTest extends TestCase { project.setBaseDir(new File(".")); project.setName("testOSGIModuleCreation"); File tempDir = new File("."); - return (AntBuilder) AntBuilder.getBuilder("", project, tempDir); + return (AntBuilder) AntBuilder.getBuilder("", project, tempDir); } - - + + /********************************************************************* * The following tests/code enable you to run the entire build in JUnit * to debug directly from Eclipse. To compile using Javac, you will @@ -199,7 +199,7 @@ public class ModulesTest extends TestCase { */ public void skip_testBuildingAspectJModule() { final String moduleName = "org.aspectj.lib"; - + File modulesDir = new File("..").getAbsoluteFile(); File buildDir = new File(modulesDir, "aj-build"); File distDir = new File(buildDir, "dist"); @@ -214,7 +214,7 @@ public class ModulesTest extends TestCase { Project project = new Project(); project.setBaseDir(modulesDir); project.setName("testAspectjbuild"); - + BuildModule bm = new BuildModule(); bm.setProject(project); bm.setAssembleall(true); @@ -229,19 +229,19 @@ public class ModulesTest extends TestCase { bm.setVersion("1.2"); bm.setVerbose(true); bm.setFailonerror(true); - + bm.execute(); - + assertTrue(jar.canRead()); } - + public void skip_testBuildingProduct() { final String productName = "tools"; File modulesDir = new File("..").getAbsoluteFile(); File buildDir = new File(modulesDir, "aj-build"); File distDir = new File(buildDir, "dist"); File jarDir = new File(buildDir, "jars"); - File productDir = new File(modulesDir, + File productDir = new File(modulesDir, Util.path(new String[] {"build", "products", productName})); jarDir.mkdirs(); @@ -251,7 +251,7 @@ public class ModulesTest extends TestCase { project.setBaseDir(modulesDir); project.setName("testAspectjToolsbuild"); project.addBuildListener(new EventBuildListener(Project.MSG_WARN)); - + BuildModule bm = new BuildModule(); bm.setProject(project); bm.setAssembleall(true); @@ -265,7 +265,7 @@ public class ModulesTest extends TestCase { bm.setVersion("1.2"); bm.setFailonerror(true); bm.execute(); - + File libDir = new File(distDir, "tools/lib"); String[] jars = { "tools", "rt", "weaver", "lib"}; for (String s : jars) { @@ -287,7 +287,7 @@ public class ModulesTest extends TestCase { } public void buildFinished(BuildEvent event) {} public void buildStarted(BuildEvent event) { } - public void messageLogged(BuildEvent event) { + public void messageLogged(BuildEvent event) { if (min <= event.getPriority()) { Task t = event.getTask(); String src = (null == t ? "project" : t.getTaskName()); @@ -298,7 +298,7 @@ public class ModulesTest extends TestCase { public void targetStarted(BuildEvent event) { } public void taskFinished(BuildEvent event) { } public void taskStarted(BuildEvent event) { } - - } + + } } diff --git a/build/src/test/java/org/aspectj/internal/tools/build/UtilsTest.java b/build/src/test/java/org/aspectj/internal/tools/build/UtilsTest.java index e044afc01..5de8fc725 100644 --- a/build/src/test/java/org/aspectj/internal/tools/build/UtilsTest.java +++ b/build/src/test/java/org/aspectj/internal/tools/build/UtilsTest.java @@ -1,13 +1,13 @@ /* ******************************************************************* * Copyright (c) 2006 Contributors. - * All rights reserved. - * This program and the accompanying materials are made available - * under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution and is available at - * http://eclipse.org/legal/epl-v10.html - * - * Contributors: - * Wes Isberg initial implementation + * All rights reserved. + * This program and the accompanying materials are made available + * under the terms of the Eclipse Public License v 2.0 + * which accompanies this distribution and is available at + * https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt + * + * Contributors: + * Wes Isberg initial implementation * ******************************************************************/ package org.aspectj.internal.tools.build; diff --git a/build/test-build-script.xml b/build/test-build-script.xml index fc02e3999..610dd66cd 100644 --- a/build/test-build-script.xml +++ b/build/test-build-script.xml @@ -2,9 +2,9 @@ <!-- Copyright (c) 2005 Contributors --> <!-- All rights reserved. --> <!-- This program and the accompanying materials are made available --> -<!-- under the terms of the Eclipse Public License v1.0 --> +<!-- under the terms of the Eclipse Public License v 2.0 --> <!-- which accompanies this distribution and is available at --> -<!-- http://www.eclipse.org/legal/epl-v10.html --> +<!-- https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt --> <!-- --> <!-- Contributors: (See CVS checkin's) --> <!-- Wes Isberg initial implementation --> @@ -13,16 +13,16 @@ <project name="test-build-script" default="all" basedir="."> <property name="modules.dir" location="${basedir}/.."/> - + <import file="${modules.dir}/build/build-properties.xml"/> <target name="all" depends="failures"/> - + <target name="failures" depends="init-properties"> <delete file="${aj.failure.file}"/> <echo message="-> no false negative (no file)"/> <antcall target="fail-if-failures"/> - + <touch file="${aj.failure.file}"/> <echo message="-> no false negative (empty file)"/> <antcall target="fail-if-failures"/> @@ -39,4 +39,4 @@ <loadfile property="emit" srcfile="${aj.failure.file}"/> <echo message="-> file contents: ${emit}"/> </target> -</project>
\ No newline at end of file +</project> |