From a0d2d2d0de4ab0e67a714d3fec46d96b268ca1e4 Mon Sep 17 00:00:00 2001 From: wisberg Date: Wed, 28 May 2003 08:23:42 +0000 Subject: [PATCH] Script is usable! - lots of rearranging and cleanup, docs - now doing 1.3 and 1.4 testing - more harness tests (some unverified) - workaround OOM in examples - cleanup after building-aspectj-with-aspectj need more integration with manual process --- build/release/build.xml | 542 +++++++++++++++++++++++---------------- build/release/readme.txt | 58 +++++ 2 files changed, 377 insertions(+), 223 deletions(-) create mode 100644 build/release/readme.txt diff --git a/build/release/build.xml b/build/release/build.xml index 73fcb23dc..e3bea48bb 100644 --- a/build/release/build.xml +++ b/build/release/build.xml @@ -10,86 +10,101 @@ - + - + - This downloads and builds the AspectJ source tree: + Build and test the AspectJ source tree. Targets: - - checkout entire tree - - build distribution - - install distribution - - test - - ajcTests.xml ajc/harness tests in the build - - junitModules.xml junit tests in the build - - build installed examples - ... and more - - Targets of note: + all (default) + install # install distribution + build + build-release # build distribution + build-tests # build test classes + test + test-sources # - requires only sources + test-harness-tests # run tests/{suite}.xml's + test-junit-modules # tests/junitModules.xml + test-install # - requires distribution + test-build-examples # install/docs/examples + test-ajc-aspectj # ajc compiles aspectj + + Normally this builds with Java 1.3 and tests with both + Java 1.3 and 1.4, so define both as properties. You + can select any target (not prefixed "do-" or "init-"). + The leaf targets will run with Java version set in + ${java.home.file} + When running non-leaf targets, if you want to test + only in 1.3 or 1.4, set property "run.1[3|4].only". + + Properties to consider setting on the command-line: + + -- required + java13.home JAVA_HOME for latest J2SE 1.3 + java14.home JAVA_HOME for latest J2SE 1.4 + + -- flags to control + run.13.only only use Java 1.3 + run.14.only only use Java 1.4 + skip.cvs no CVS checkout (true) + skip.build no build (done already) + skip.test no tests + skip.build.release no build of release + skip.build.tests no build of tests + version set if not DEVELOPMENT(?) + + -- locations to re-use existing tree or install + aspectj.workspace location for new cvs tree + aspectj.modules.dir ... for existing cvs tree + aj.build.install.dir ... for installed dist - install checkout, build, and install AspectJ - test (default) test AspectJ sources and installation + Example command lines for using this script: - Properties of note (flags and default values): - - -- flags to control - skip.cvs no CVS checkout (done already) - skip.build no build (done already) - skip.build.release no build of release - skip.build.tests no build of tests - version set if not DEVELOPMENT - - -- locations to re-use existing tree or install - aspectj.workspace location for new cvs tree - aspectj.modules.dir location for existing cvs tree - aj.build.install.dir location for installed distribution - - Trails - - clean first - - cd build - ant clean - - - test only sources in local tree (junit and harness tests): + - define variable for standard properties - cd build/release - ant test-sources \ - -Dskip.cvs=true \ - -Daspectj.modules.dir=../.. + sp="-Djava13.home=d:/j13 -Djava14.home=d:/j14" + sp="$${sp} -Daspectj.modules.dir=../.." - - build local tree and install distribution: - - cd build/release - ant install \ - -Dskip.cvs=true \ - -Daspectj.modules.dir=../.. + - clean first + + cd build + ant clean + + - test only sources in local tree - - test installation and sources in local tree: + cd build/release + ant test-sources $${sp} + + - build and install distribution: + + cd build/release + ant install $${sp} - cd build/release - ant test \ - -Dskip.cvs=true \ - -Daspectj.modules.dir=../.. \ - -Dskip.build=true + - test installation and sources in local tree: - - do everything but checkout from cvs: + cd build/release + ant test $${sp} -Dskip.build=true - cd build - ant clean - cd release - ant all \ - -Dskip.cvs=true \ - -Daspectj.modules.dir=../.. + - do everything but checkout from cvs: - + cd build + ant clean + cd release + ant all $${sp} + + - + + + + + @@ -97,6 +112,8 @@ location="${aspectj.workspace}/org.aspectj/modules"/> + + + + - + + + @@ -165,14 +189,14 @@ - - @@ -180,7 +204,7 @@ message="install first in ${aj.build.install.dir}"/> - - @@ -199,13 +223,30 @@ + message="test classes not found - first build-tests"/> + + + + + + + + + + + + + + + + description="install AspectJ distribution using current java"> @@ -215,61 +256,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + - - - - - - + + + + + + + + + + - - - - + + + + + + + + + - - - - - - - - - - - - - - - - - - + + + + - - + + - + - - - - - - - + + + location="${aj.build.log.dir}/test-ajc-aspectj"/> + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + - - + + - - + - + - + - + - + - - - - + - - + + - + + + - + + + + + location="${aj.build.log.dir}/test-${suite.filename}${harness.suffix}-${build.java.version}.txt"/> - run-harness-once ${suite.filename}.xml - with options ${rho.default.options} ${harness.args} + do-run-harness ${suite.filename}.xml + with options ${drho.default.options} ${harness.args} to ${harness.output.file} - + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - + - + + + + + + + + do-run-ant dir ${ant.dir} + file/target -f ${run.ant.file} ${ant.target} + options ${ant.verbose} ${ant.properties} + output ${ant.output.file} + + + output="${ant.output.file}"> - - - + + - + @@ -495,9 +555,45 @@ file="${aspectj.modules.dir}"/> - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/build/release/readme.txt b/build/release/readme.txt new file mode 100644 index 000000000..b23769e31 --- /dev/null +++ b/build/release/readme.txt @@ -0,0 +1,58 @@ + +This script builds and tests an AspectJ release. +Use the info target to emit details. + +At the bottom is a bash script to run it. + +---- Evaluating the results of a build cycle + +There is a ../release-checklist.txt which has steps for a release, some of +which are automated in this script. Try the others ;). + +Known issues with these tests + +- ajc compile of tjp example as part of nonGui target + runs out of memory. Reproducible on the command-line: + [ajc] Running in-process using -verbose -d R:\home\wes\ec\aj- +build\install\doc\examples\classes -classpath R:\home\wes\ec\aj-buil +d\install\lib\aspectjrt.jar -argfile R:\home\wes\ec\aj-build\install +\doc\examples\tjp\files.lst +Exception reading component R:\home\wes\ec\aj-build\install\lib\aspe +ctjtools.jar +java.lang.OutOfMemoryError + <> +Exception in thread "main" java.lang.OutOfMemoryError + <> + + This target is run without failonerror="true" to complete + the testing. + +Known imperfect results in the AspectJ 1.1 release: + +- ajdeCompiler tests will have five known fails, listed + in releases/aspectj1.1/ajcTests-ajdeCompiler-FAIL.txt + +- under 1.4, the junit module test output for the weaver + module is corrupted - the last two characters are + duplicated, which cause the junit reporting task to + not pick up the weaver tests. Verify that the + weaver XML file lists no JUnit failures or errors. + + +------ untested bash/sh script +#!/bin/sh +sp="-Dskip.cvs=true -Daspectj.modules.dir=../.." +sp="$${sp} -Djava13.home=d:/jdk13 -Djava14.home=d:/jdk14" +alias myant="../../lib/ant/bin/ant" + +# clean +cd `dirname "$0"` +cd .. +myant clean + +# build local tree and install distribution: +cd release +myant install ${sp} + +# test installation and sources in local tree: +myant test ${sp} -Dskip.build=true -- 2.39.5