From e13cf1d4781561cf5f0719997e4aab4c93cfa0ed Mon Sep 17 00:00:00 2001 From: Mat Booth Date: Wed, 2 May 2018 11:23:15 +0100 Subject: [PATCH] Update to latest tycho snapshot Bootstrap build --- .gitignore | 3 + build-against-photon-equinox.patch | 82 +++++ build-against-surefire-2.21.patch | 176 +++++++++ sources | 6 +- tycho-bootstrap.sh | 8 +- tycho-fix-bootstrap-build.patch | 118 +------ tycho-fix-build.patch | 45 --- tycho-maven-delegation.patch | 10 +- tycho-port-to-plexus-archiver-3.0.1.patch | 12 - tycho-scripts.sh | 27 +- tycho-surefire-2.19.patch | 389 -------------------- tycho-surefire-2.20.patch | 411 ---------------------- tycho-use-custom-resolver.patch | 14 +- tycho.spec | 121 ++++--- 14 files changed, 353 insertions(+), 1069 deletions(-) create mode 100644 build-against-photon-equinox.patch create mode 100644 build-against-surefire-2.21.patch delete mode 100644 tycho-port-to-plexus-archiver-3.0.1.patch delete mode 100644 tycho-surefire-2.19.patch delete mode 100644 tycho-surefire-2.20.patch diff --git a/.gitignore b/.gitignore index 9ddc454..18dd246 100644 --- a/.gitignore +++ b/.gitignore @@ -11,3 +11,6 @@ maven-repo.tar.xz /fedoraproject-p2-*.tar.xz /eclipse-bootstrap-neon.tar.xz /eclipse-bootstrap-oxygen.tar.xz +/fedoraproject-p2-290f67a4c717599b2f5166ea89aa5365571314b1.tar.gz +/tycho-d9ce75d316caae823be78527b7b690182b602895.tar.gz +/eclipse-bootstrap-photon.tar.xz diff --git a/build-against-photon-equinox.patch b/build-against-photon-equinox.patch new file mode 100644 index 0000000..d141ab5 --- /dev/null +++ b/build-against-photon-equinox.patch @@ -0,0 +1,82 @@ +--- tycho-core/src/main/java/org/eclipse/tycho/core/locking/FileLockServiceImpl.java.orig 2018-04-30 14:30:10.281927855 +0100 ++++ tycho-core/src/main/java/org/eclipse/tycho/core/locking/FileLockServiceImpl.java 2018-04-30 14:30:58.973755768 +0100 +@@ -29,7 +29,7 @@ + private Location anyLocation; + + public FileLockServiceImpl() { +- anyLocation = new BasicLocation(null, null, false, null, new ConfigValues(new HashMap()), ++ anyLocation = new BasicLocation(null, null, false, null, new ConfigValues(new HashMap(), new HashMap()), + new EquinoxContainer(null), new AtomicBoolean(false)); + } + +--- tycho-core/pom.xml.orig 2018-04-30 14:24:51.873051601 +0100 ++++ tycho-core/pom.xml 2018-04-30 14:25:46.426859073 +0100 +@@ -123,7 +123,7 @@ + plexus-archiver + + +- org.eclipse.platform ++ org.eclipse.tycho + org.eclipse.osgi.compatibility.state + + +--- sisu-equinox/sisu-equinox-embedder/pom.xml.orig 2018-04-30 14:25:12.892977419 +0100 ++++ sisu-equinox/sisu-equinox-embedder/pom.xml 2018-04-30 14:25:46.427859069 +0100 +@@ -30,7 +30,7 @@ + plexus-component-annotations + + +- org.eclipse.platform ++ org.eclipse.tycho + org.eclipse.osgi + + +--- tycho-compiler-jdt/pom.xml.orig 2018-04-30 14:57:02.459229391 +0100 ++++ tycho-compiler-jdt/pom.xml 2018-04-30 14:56:08.265420993 +0100 +@@ -29,7 +29,7 @@ + + + +- org.eclipse.jdt ++ org.eclipse.tycho + org.eclipse.jdt.core + + +@@ -47,7 +47,7 @@ + maven-core + + +- org.eclipse.jdt ++ org.eclipse.tycho + org.eclipse.jdt.compiler.apt + + +--- pom.xml.orig 2018-04-30 14:24:58.019029911 +0100 ++++ pom.xml 2018-04-30 14:56:08.264420997 +0100 +@@ -217,22 +217,22 @@ + 3.1 + + +- org.eclipse.platform ++ org.eclipse.tycho + org.eclipse.osgi + ${equinoxVersionMaven} + + +- org.eclipse.platform ++ org.eclipse.tycho + org.eclipse.osgi.compatibility.state + ${equinoxCompatVersionMaven} + + +- org.eclipse.jdt ++ org.eclipse.tycho + org.eclipse.jdt.core + ${jdtVersionMaven} + + +- org.eclipse.jdt ++ org.eclipse.tycho + org.eclipse.jdt.compiler.apt + ${jdtAptVersionMaven} + diff --git a/build-against-surefire-2.21.patch b/build-against-surefire-2.21.patch new file mode 100644 index 0000000..6a40fd0 --- /dev/null +++ b/build-against-surefire-2.21.patch @@ -0,0 +1,176 @@ +From d4d161e7ccfb21503e906229a37000eb9a821284 Mon Sep 17 00:00:00 2001 +From: Jan Sievers +Date: Tue, 4 Sep 2012 16:02:52 +0200 +Subject: [PATCH] Resolve all necessary dependencies for Tycho Surefire. + +When running an Eclipse bundle's tests, Tycho Surefire resolves its +runtime dependencies using a class loader, which is in fact just looking +through Bundle-ClassPath. As a result, it must copy over and include +system jars in its Bundle-ClassPath. We use Fedora system jars to +satisfy these dependencies but even these jars differ slightly in terms +of provided classes. This patch addresses this issue. + +Basically, the jars added to the Bundle-ClassPath in this patch, provide +the additional classes that are in the original jars used upstream. + +Change-Id: I9ef0239eed887fa47c380efcdce968934c788c9f +--- + pom.xml | 2 +- + .../META-INF/MANIFEST.MF | 5 ++-- + .../org.eclipse.tycho.surefire.junit/pom.xml | 5 ++++ + .../META-INF/MANIFEST.MF | 5 +++- + .../org.eclipse.tycho.surefire.junit4/pom.xml | 10 ++++++++ + .../META-INF/MANIFEST.MF | 8 ++++--- + .../org.eclipse.tycho.surefire.junit47/pom.xml | 10 ++++++++ + .../META-INF/MANIFEST.MF | 7 +++--- + .../org.eclipse.tycho.surefire.osgibooter/pom.xml | 5 ++++ + .../surefire/osgibooter/OsgiSurefireBooter.java | 20 ++++++++++------ + tycho-surefire/pom.xml | 2 +- + .../java/org/eclipse/tycho/surefire/TestMojo.java | 27 +++++++++++++++++++--- + 12 files changed, 85 insertions(+), 21 deletions(-) + +diff --git a/pom.xml b/pom.xml +index c43cc8d..6e5fde4 100644 +--- a/pom.xml ++++ b/pom.xml +@@ -88,7 +88,7 @@ + 3.3 + 3.0 + +- 2.19.1 ++ 2.21.0 + + + 3.12.100 +diff --git a/tycho-surefire/org.eclipse.tycho.surefire.junit/pom.xml b/tycho-surefire/org.eclipse.tycho.surefire.junit/pom.xml +index f99c319..0224cc6 100644 +--- a/tycho-surefire/org.eclipse.tycho.surefire.junit/pom.xml ++++ b/tycho-surefire/org.eclipse.tycho.surefire.junit/pom.xml +@@ -36,6 +36,11 @@ + surefire-junit3 + ${surefire-version} + ++ ++ org.apache.maven.surefire ++ common-junit3 ++ ${surefire-version} ++ + + + +diff --git a/tycho-surefire/org.eclipse.tycho.surefire.junit4/pom.xml b/tycho-surefire/org.eclipse.tycho.surefire.junit4/pom.xml +index 9628b06..2a09e91 100644 +--- a/tycho-surefire/org.eclipse.tycho.surefire.junit4/pom.xml ++++ b/tycho-surefire/org.eclipse.tycho.surefire.junit4/pom.xml +@@ -36,6 +36,16 @@ + surefire-junit4 + ${surefire-version} + ++ ++ org.apache.maven.surefire ++ common-junit3 ++ ${surefire-version} ++ ++ ++ org.apache.maven.surefire ++ common-junit4 ++ ${surefire-version} ++ + + + +diff --git a/tycho-surefire/org.eclipse.tycho.surefire.junit47/pom.xml b/tycho-surefire/org.eclipse.tycho.surefire.junit47/pom.xml +index dc49a46..db453ac 100644 +--- a/tycho-surefire/org.eclipse.tycho.surefire.junit47/pom.xml ++++ b/tycho-surefire/org.eclipse.tycho.surefire.junit47/pom.xml +@@ -46,6 +46,16 @@ + surefire-grouper + ${surefire-version} + ++ ++ org.apache.maven.surefire ++ common-junit4 ++ ${surefire-version} ++ ++ ++ org.apache.maven.surefire ++ common-junit3 ++ ${surefire-version} ++ + + + +diff --git a/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/META-INF/MANIFEST.MF b/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/META-INF/MANIFEST.MF +index 991edc1..83732d5 100644 +--- a/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/META-INF/MANIFEST.MF ++++ b/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/META-INF/MANIFEST.MF +@@ -5,9 +5,11 @@ Require-Bundle: org.eclipse.osgi;bundle-version="3.2.2", + Eclipse-AutoStart: true + Bundle-Version: 1.2.0.qualifier + Bundle-ClassPath: ., +- jars/surefire-booter-2.19.1.jar, +- jars/surefire-api-2.19.1.jar, +- jars/maven-surefire-common-2.19.1.jar ++ jars/surefire-booter-2.21.0.jar, ++ jars/surefire-api-2.21.0.jar, ++ jars/surefire-logger-api-2.21.0.jar, ++ jars/maven-surefire-common-2.21.0.jar, ++ jars/plexus-utils-3.0.jar + Bundle-Name: Tycho Surefire OSGi Booter Eclipse Application + Bundle-ManifestVersion: 2 + Bundle-SymbolicName: org.eclipse.tycho.surefire.osgibooter;singleton:=true +diff --git a/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/pom.xml b/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/pom.xml +index 82700eb..3fbc3a3 100644 +--- a/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/pom.xml ++++ b/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/pom.xml +@@ -59,6 +59,11 @@ + + + org.apache.maven.surefire ++ surefire-logger-api ++ ${surefire-version} ++ ++ ++ org.apache.maven.surefire + surefire-booter + ${surefire-version} + +@@ -67,6 +72,11 @@ + maven-surefire-common + ${surefire-version} + ++ ++ org.codehaus.plexus ++ plexus-utils ++ 3.0 ++ + + + +diff --git a/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/src/main/java/org/eclipse/tycho/surefire/osgibooter/OsgiSurefireBooter.java b/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/src/main/java/org/eclipse/tycho/surefire/osgibooter/OsgiSurefireBooter.java +index 033766c4..fe8105b9 100644 +--- a/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/src/main/java/org/eclipse/tycho/surefire/osgibooter/OsgiSurefireBooter.java ++++ b/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/src/main/java/org/eclipse/tycho/surefire/osgibooter/OsgiSurefireBooter.java +@@ -28,6 +28,7 @@ import java.util.Properties; + import java.util.Set; + + import org.apache.maven.plugin.surefire.StartupReportConfiguration; ++import org.apache.maven.plugin.surefire.log.api.NullConsoleLogger; + import org.apache.maven.plugin.surefire.report.DefaultReporterFactory; + import org.apache.maven.surefire.booter.BooterConstants; + import org.apache.maven.surefire.booter.ClassLoaderConfiguration; +@@ -97,11 +98,11 @@ public class OsgiSurefireBooter { + ProviderConfiguration providerConfiguration = new ProviderConfiguration(dirScannerParams, + new RunOrderParameters(runOrder, null), failIfNoTests, reporterConfig, null, testRequest, + extractProviderProperties(testProps), null, false, Collections. emptyList(), +- skipAfterFailureCount, Shutdown.DEFAULT); ++ skipAfterFailureCount, Shutdown.DEFAULT, 0); + StartupReportConfiguration startupReportConfig = new StartupReportConfiguration(useFile, printSummary, + StartupReportConfiguration.PLAIN_REPORT_FORMAT, redirectTestOutputToFile, disableXmlReport, reportsDir, +- trimStacktrace, null, "TESTHASH", false, rerunFailingTestsCount); +- ReporterFactory reporterFactory = new DefaultReporterFactory(startupReportConfig); ++ trimStacktrace, null, new File(reportsDir, "TESTHASH"), false, rerunFailingTestsCount, null); ++ ReporterFactory reporterFactory = new DefaultReporterFactory(startupReportConfig, new NullConsoleLogger()); + // API indicates we should use testClassLoader below but surefire also tries + // to load surefire classes using this classloader + RunResult result = ProviderFactory.invokeProvider(null, createCombinedClassLoader(testPlugin), reporterFactory, diff --git a/sources b/sources index 68355d1..8d9c374 100644 --- a/sources +++ b/sources @@ -1,3 +1,3 @@ -SHA512 (fedoraproject-p2-b8b13f9.tar.xz) = e271fbf57573b104190392adad369b03937af4f799d9696284904537ee55e49d5c9f311719669fa165f6949f484bf0583487b9c66ac5bea5bb10a18e51066def -SHA512 (org.eclipse.tycho-tycho-1.0.0.tar.xz) = 31a082931e578c03d1a7e435944c0d61b1062a99b54c25ae67a705858691855fbd163eba01642210a7a11376e53f7ffa65b29df1f41f3f2dc71771df9d13f10a -SHA512 (eclipse-bootstrap-oxygen.tar.xz) = 3d5694dd0d97334ec780c8e8df9d884f55b892e445a9afa371acb62bfb6d242a369728f7411d798a8274b2efa5c7cfbe1c7195c60e3992c88a520f9dda2fe55c +SHA512 (fedoraproject-p2-290f67a4c717599b2f5166ea89aa5365571314b1.tar.gz) = 5ddfa3e7c1dc3d64335d836d74d7325904f294e0ab1782de41a8815b09ddf42f0c47a263c3a6217626aaf293a17788d01174c327e17b192a0f451d07d5655c49 +SHA512 (tycho-d9ce75d316caae823be78527b7b690182b602895.tar.gz) = 7522ecb017e8c0fac93454386f41b34751462fb26238d2e5047ecc191254d2356b70a94f5f726f547b1631a678ce310b272bf33121a756385297dfd3190059e8 +SHA512 (eclipse-bootstrap-photon.tar.xz) = c18687eecd7d79bbd0722e8effc89d32a8fe31f2c9fe978cc73cfe9679d5a7fd01d8e12483404e3257d86817b7a12b4dcdfbd88316855a06d8f43da71a3c49a8 diff --git a/tycho-bootstrap.sh b/tycho-bootstrap.sh index 7a1c748..3485c71 100755 --- a/tycho-bootstrap.sh +++ b/tycho-bootstrap.sh @@ -5,8 +5,8 @@ eclipse_bootstrap=$1 preV=$2 v="$preV-SNAPSHOT" -osgiV='3.12.0.v20170419-1339' -osgiCompatV='1.0.300.v20170419-1339' +osgiV='3.13.0.v20180428-1222' +osgiCompatV='1.1.100.v20180428-1222' fp2V='0.0.1-SNAPSHOT' bundles=() bundles[0]='tycho-bundles/org.eclipse.tycho.embedder.shared' @@ -35,7 +35,7 @@ externalDeps[6]="org.eclipse.equinox.p2.director.app,org.eclipse.equinox.framewo xtraExternalDeps[0]="org.eclipse.osgi,org.eclipse.core.runtime,org.eclipse.equinox.common,org.eclipse.equinox.p2.metadata,org.eclipse.equinox.p2.repository,org.eclipse.equinox.p2.core,org.eclipse.equinox.p2.publisher.eclipse,org.eclipse.equinox.p2.publisher,org.eclipse.equinox.p2.touchpoint.eclipse,org.eclipse.equinox.p2.updatesite,org.eclipse.equinox.p2.repository.tools,org.eclipse.equinox.app,slf4j.api" -reactorprojs=( 'tycho-embedder-api' 'tycho-metadata-model' 'sisu-equinox/sisu-equinox-api' 'sisu-equinox/sisu-equinox-embedder' 'tycho-core' 'tycho-packaging-plugin' 'tycho-p2/tycho-p2-facade' 'tycho-maven-plugin' 'tycho-p2/tycho-p2-repository-plugin' 'tycho-p2/tycho-p2-publisher-plugin' 'target-platform-configuration' 'tycho-artifactcomparator' 'sisu-equinox/sisu-equinox-launching' 'tycho-p2/tycho-p2-plugin' 'tycho-compiler-jdt' 'tycho-compiler-plugin' ) +reactorprojs=( 'tycho-embedder-api' 'tycho-metadata-model' 'sisu-equinox/sisu-equinox-api' 'sisu-equinox/sisu-equinox-embedder' 'tycho-core' 'tycho-packaging-plugin' 'tycho-p2/tycho-p2-facade' 'tycho-maven-plugin' 'tycho-p2/tycho-p2-repository-plugin' 'tycho-p2/tycho-p2-publisher-plugin' 'target-platform-configuration' 'tycho-artifactcomparator' 'sisu-equinox/sisu-equinox-launching' 'tycho-p2/tycho-p2-plugin' 'tycho-lib-detector' 'tycho-compiler-jdt' 'tycho-compiler-plugin' ) for ((i=0; i < ${#xtraBundles[@]}; i++)) ;do echo '' @@ -90,7 +90,7 @@ popd for proj in ${reactorprojs[@]} ; do isolateProject ${proj} xmvn -B -o -e -f "${proj}/pom.xml" -Dmaven.repo.local=$(pwd)/.m2 -Dmaven.test.skip=true \ - -Dmaven.compiler.source=1.7 -Dmaven.compiler.target=1.7 -Dproject.build.sourceEncoding=UTF-8 \ + -Dmaven.compiler.source=1.8 -Dmaven.compiler.target=1.8 -Dproject.build.sourceEncoding=UTF-8 \ clean install unifyProject ${proj} done diff --git a/tycho-fix-bootstrap-build.patch b/tycho-fix-bootstrap-build.patch index 04c4b8b..73f1813 100644 --- a/tycho-fix-bootstrap-build.patch +++ b/tycho-fix-bootstrap-build.patch @@ -1,47 +1,3 @@ -diff --git a/tycho-artifactcomparator/pom.xml b/tycho-artifactcomparator/pom.xml -index adfdd95..81ad821 100644 ---- a/tycho-artifactcomparator/pom.xml -+++ b/tycho-artifactcomparator/pom.xml -@@ -51,6 +51,15 @@ - - org.codehaus.plexus - plexus-component-metadata -+ 1.5.5 -+ -+ -+ -+ generate-metadata -+ generate-test-metadata -+ -+ -+ - - - -diff --git a/tycho-compiler-jdt/pom.xml b/tycho-compiler-jdt/pom.xml -index 4c0c304..bfa9030 100644 ---- a/tycho-compiler-jdt/pom.xml -+++ b/tycho-compiler-jdt/pom.xml -@@ -26,8 +26,17 @@ - - - -- org.codehaus.plexus -- plexus-component-metadata -+ org.codehaus.plexus -+ plexus-component-metadata -+ 1.5.5 -+ -+ -+ -+ generate-metadata -+ generate-test-metadata -+ -+ -+ - - - diff --git a/tycho-compiler-plugin/pom.xml b/tycho-compiler-plugin/pom.xml index 923405d..33ce36d 100644 --- a/tycho-compiler-plugin/pom.xml @@ -70,32 +26,7 @@ diff --git a/tycho-core/pom.xml b/tycho-core/pom.xml index 9f79a46..10628cf 100644 --- a/tycho-core/pom.xml +++ b/tycho-core/pom.xml -@@ -59,11 +59,19 @@ - - - -- -- org.codehaus.plexus -- plexus-component-metadata -- -- -+ -+ org.codehaus.plexus -+ plexus-component-metadata -+ 1.5.5 -+ -+ -+ -+ generate-metadata -+ generate-test-metadata -+ -+ -+ -+ - - org.apache.felix - maven-bundle-plugin -@@ -148,12 +156,6 @@ +@@ -148,12 +148,6 @@ @@ -126,7 +57,7 @@ diff --git a/tycho-p2/tycho-p2-plugin/pom.xml b/tycho-p2/tycho-p2-plugin/pom.xml index e25b6d9..7e8a7f2 100644 --- a/tycho-p2/tycho-p2-plugin/pom.xml +++ b/tycho-p2/tycho-p2-plugin/pom.xml -@@ -53,21 +53,23 @@ +@@ -53,13 +53,6 @@ tycho-artifactcomparator ${project.version} @@ -140,27 +71,6 @@ index e25b6d9..7e8a7f2 100644 - -- -- org.codehaus.plexus -- plexus-component-metadata -- -+ -+ org.codehaus.plexus -+ plexus-component-metadata -+ 1.5.5 -+ -+ -+ -+ generate-metadata -+ generate-test-metadata -+ -+ -+ -+ - - - diff --git a/tycho-p2/tycho-p2-publisher-plugin/pom.xml b/tycho-p2/tycho-p2-publisher-plugin/pom.xml index e52cf18..bcd8c91 100644 --- a/tycho-p2/tycho-p2-publisher-plugin/pom.xml @@ -207,27 +117,3 @@ index 0990b2d..7dd1d68 100644 org.mockito mockito-core test -@@ -83,10 +70,19 @@ - - - -- -- org.codehaus.plexus -- plexus-component-metadata -- -+ -+ org.codehaus.plexus -+ plexus-component-metadata -+ 1.5.5 -+ -+ -+ -+ generate-metadata -+ generate-test-metadata -+ -+ -+ -+ - - - diff --git a/tycho-fix-build.patch b/tycho-fix-build.patch index 9af873c..e1a8fe3 100644 --- a/tycho-fix-build.patch +++ b/tycho-fix-build.patch @@ -5,50 +5,8 @@ Subject: [PATCH] Fix the Tycho build to work on Fedora. Minor fixes of limited scope needed to have Tycho building on Fedora. -Tycho upstream currently depends upon 0.15.0 when building -0.16.0-SNAPSHOT, which doesn't have reactor plugin version checking. In -Fedora we depend on the previously built version which has that version -checking. We must keep previous build version strings different to avoid -a cyclic dependency, but doing so causes the version checking to fail, -so we must provide a way to disable it. Disable by default. - Change-Id: Ic8c0514c1fa10ee53580d2654ac6a363ccd66814 --- - .../eclipse/tycho/p2/target/ee/CustomEEResolutionHandler.java | 2 +- - .../src/main/java/org/eclipse/tycho/test/util/HttpServer.java | 8 ++++++-- - .../tycho/core/maven/TychoMavenLifecycleParticipant.java | 4 +++- - .../eclipse/tycho/surefire/osgibooter/OsgiSurefireBooter.java | 2 +- - .../org/eclipse/tycho/test/AbstractTychoIntegrationTest.java | 11 +++++------ - 8 files changed, 17 insertions(+), 14 deletions(-) - -diff --git a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/target/ee/CustomEEResolutionHandler.java b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/target/ee/CustomEEResolutionHandler.java -index 7afa13e..82962f9 100644 ---- a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/target/ee/CustomEEResolutionHandler.java -+++ b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/target/ee/CustomEEResolutionHandler.java -@@ -59,7 +59,7 @@ class CustomEEResolutionHandler extends ExecutionEnvironmentResolutionHandler { - String name = capability.getName(); - String version = capability.getVersion().toString(); - -- if (JREAction.NAMESPACE_OSGI_EE.equals(namespace)) { -+ if ("osgi.ee".equals(namespace)) { - result.add(new SystemCapability(Type.OSGI_EE, name, version)); - } else if (PublisherHelper.CAPABILITY_NS_JAVA_PACKAGE.equals(namespace)) { - result.add(new SystemCapability(Type.JAVA_PACKAGE, name, version)); -diff --git a/tycho-core/src/main/java/org/eclipse/tycho/core/maven/TychoMavenLifecycleParticipant.java b/tycho-core/src/main/java/org/eclipse/tycho/core/maven/TychoMavenLifecycleParticipant.java -index b00c344..bc05c2d 100644 ---- a/tycho-core/src/main/java/org/eclipse/tycho/core/maven/TychoMavenLifecycleParticipant.java -+++ b/tycho-core/src/main/java/org/eclipse/tycho/core/maven/TychoMavenLifecycleParticipant.java -@@ -102,7 +102,9 @@ public class TychoMavenLifecycleParticipant extends AbstractMavenLifecyclePartic - } - - private void validate(List projects) throws MavenExecutionException { -- validateConsistentTychoVersion(projects); -+ if (System.getProperty("tycho.enableVersionCheck") != null) { -+ validateConsistentTychoVersion(projects); -+ } - validateUniqueBaseDirs(projects); - } - diff --git a/tycho-testing-harness/src/main/java/org/eclipse/tycho/test/AbstractTychoIntegrationTest.java b/tycho-testing-harness/src/main/java/org/eclipse/tycho/test/AbstractTychoIntegrationTest.java index 097bdeb..f90b10c 100644 --- a/tycho-testing-harness/src/main/java/org/eclipse/tycho/test/AbstractTychoIntegrationTest.java @@ -71,6 +29,3 @@ index 097bdeb..f90b10c 100644 } return verifier; --- -2.1.0 - diff --git a/tycho-maven-delegation.patch b/tycho-maven-delegation.patch index e706456..fee9ed7 100644 --- a/tycho-maven-delegation.patch +++ b/tycho-maven-delegation.patch @@ -48,9 +48,9 @@ index 9658fbc..efd0a2c 100644 --- a/tycho-bundles/org.eclipse.tycho.core.shared.tests/META-INF/MANIFEST.MF +++ b/tycho-bundles/org.eclipse.tycho.core.shared.tests/META-INF/MANIFEST.MF @@ -7,3 +7,4 @@ Fragment-Host: org.eclipse.tycho.core.shared - Bundle-RequiredExecutionEnvironment: JavaSE-1.7 Require-Bundle: org.junit;bundle-version="4.8.2" Bundle-Vendor: %providerName + Automatic-Module-Name: org.eclipse.tycho.core.shared.tests +Import-Package: org.eclipse.tycho.p2.repository diff --git a/tycho-bundles/org.eclipse.tycho.core.shared/src/main/java/org/eclipse/tycho/core/shared/MavenContext.java b/tycho-bundles/org.eclipse.tycho.core.shared/src/main/java/org/eclipse/tycho/core/shared/MavenContext.java index d63c1f1..cd8594d 100644 @@ -309,7 +309,7 @@ diff --git a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl.test/src/test/java index 50fe92f..3044e97 100644 --- a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl.test/src/test/java/org/eclipse/tycho/p2/target/TargetPlatformBundlePublisherTest.java +++ b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl.test/src/test/java/org/eclipse/tycho/p2/target/TargetPlatformBundlePublisherTest.java -@@ -31,6 +31,7 @@ import org.eclipse.tycho.p2.repository.RepositoryLayoutHelper; +@@ -32,6 +32,7 @@ import org.eclipse.tycho.p2.repository.RepositoryLayoutHelper; import org.eclipse.tycho.repository.p2base.artifact.provider.IRawArtifactProvider; import org.eclipse.tycho.repository.streaming.testutil.ProbeRawArtifactSink; import org.eclipse.tycho.test.util.LogVerifier; @@ -317,7 +317,7 @@ index 50fe92f..3044e97 100644 import org.junit.Before; import org.junit.Rule; import org.junit.Test; -@@ -56,7 +57,7 @@ public class TargetPlatformBundlePublisherTest { +@@ -57,7 +58,7 @@ public class TargetPlatformBundlePublisherTest { logVerifier.expectNoWarnings(); localRepositoryRoot = tempFolder.getRoot(); @@ -426,7 +426,7 @@ index 0195871..44a0f30 100644 this.logger = logger; } -@@ -206,8 +208,11 @@ public class TargetPlatformBundlePublisher { +@@ -204,8 +206,11 @@ public class TargetPlatformBundlePublisher { */ private static class PublishedBundlesArtifactRepository extends ArtifactRepositoryBaseImpl { @@ -439,7 +439,7 @@ index 0195871..44a0f30 100644 } void addPublishedArtifact(IArtifactDescriptor baseDescriptor, IArtifactFacade mavenArtifact) { -@@ -252,7 +257,7 @@ public class TargetPlatformBundlePublisher { +@@ -250,7 +255,7 @@ public class TargetPlatformBundlePublisher { @Override protected File internalGetArtifactStorageLocation(IArtifactDescriptor descriptor) { MavenRepositoryCoordinates coord = toInternalDescriptor(descriptor).getMavenCoordinates(); diff --git a/tycho-port-to-plexus-archiver-3.0.1.patch b/tycho-port-to-plexus-archiver-3.0.1.patch deleted file mode 100644 index 3b83d6d..0000000 --- a/tycho-port-to-plexus-archiver-3.0.1.patch +++ /dev/null @@ -1,12 +0,0 @@ ---- tycho-packaging-plugin/src/main/java/org/eclipse/tycho/packaging/LicenseFeatureHelper.java~ 2015-06-09 14:56:22.068303547 +0200 -+++ tycho-packaging-plugin/src/main/java/org/eclipse/tycho/packaging/LicenseFeatureHelper.java 2015-06-09 14:58:37.379329080 +0200 -@@ -117,8 +117,7 @@ - // mavenArchiver ignores license feature files that are also present in 'this' feature - // i.e. if there is a conflict, files from 'this' feature win - -- DefaultArchivedFileSet result = new DefaultArchivedFileSet(); -- result.setArchive(licenseFeature); -+ DefaultArchivedFileSet result = new DefaultArchivedFileSet(licenseFeature); - result.setIncludes(includes.toArray(new String[includes.size()])); - result.setExcludes(excludes.toArray(new String[excludes.size()])); - diff --git a/tycho-scripts.sh b/tycho-scripts.sh index 4f28aa7..c30a9b3 100755 --- a/tycho-scripts.sh +++ b/tycho-scripts.sh @@ -131,25 +131,24 @@ echo ${arr[@]} } function isolateProject () { -sed -i "/org.eclipse.osgi<\/artifactId>/ a ${osgiV}" "$1/pom.xml" -sed -i "/org.eclipse.osgi.compatibility.state<\/artifactId>/ a ${osgiCompatV}" "$1/pom.xml" + cp $1/pom.xml $1/pom.xml.boot -cp $1/pom.xml $1/pom.xml.bak - -sed -i '//,/<\/parent>/ d' "$1/pom.xml" -if [ $# -eq 2 ]; then - sed -i "// a org.eclipse.tycho<\/groupId>$2<\/version>" "$1/pom.xml" -else - sed -i "// a org.eclipse.tycho<\/groupId>${v}<\/version>" "$1/pom.xml" -fi + sed -i -e "/org.eclipse.osgi${osgiV}" \ + -e "/org.eclipse.osgi.compatibility.state${osgiCompatV}" \ + -e '//,/<\/parent>/ d' "$1/pom.xml" + if ! grep -q generate-metadata "$1/pom.xml" ; then + sed -i -e "/plexus-component-metadata1.5.5generate-metadata" "$1/pom.xml" + fi + if [ $# -eq 2 ]; then + sed -i "// a org.eclipse.tycho<\/groupId>$2<\/version>" "$1/pom.xml" + else + sed -i "// a org.eclipse.tycho<\/groupId>${v}<\/version>" "$1/pom.xml" + fi } function unifyProject () { - -cp $1/pom.xml.bak $1/pom.xml -sed -i "/${osgiV}<\/version>/ d" "$1/pom.xml" -sed -i "/${osgiCompatV}<\/version>/ d" "$1/pom.xml" + cp $1/pom.xml.boot $1/pom.xml } function readBSN () { diff --git a/tycho-surefire-2.19.patch b/tycho-surefire-2.19.patch deleted file mode 100644 index 206a650..0000000 --- a/tycho-surefire-2.19.patch +++ /dev/null @@ -1,389 +0,0 @@ -From d4d161e7ccfb21503e906229a37000eb9a821284 Mon Sep 17 00:00:00 2001 -From: Jan Sievers -Date: Tue, 4 Sep 2012 16:02:52 +0200 -Subject: [PATCH] Resolve all necessary dependencies for Tycho Surefire. - -When running an Eclipse bundle's tests, Tycho Surefire resolves its -runtime dependencies using a class loader, which is in fact just looking -through Bundle-ClassPath. As a result, it must copy over and include -system jars in its Bundle-ClassPath. We use Fedora system jars to -satisfy these dependencies but even these jars differ slightly in terms -of provided classes. This patch addresses this issue. - -Basically, the jars added to the Bundle-ClassPath in this patch, provide -the additional classes that are in the original jars used upstream. - -Change-Id: I9ef0239eed887fa47c380efcdce968934c788c9f ---- - pom.xml | 2 +- - .../META-INF/MANIFEST.MF | 5 ++-- - .../org.eclipse.tycho.surefire.junit/pom.xml | 5 ++++ - .../META-INF/MANIFEST.MF | 5 +++- - .../org.eclipse.tycho.surefire.junit4/pom.xml | 10 ++++++++ - .../META-INF/MANIFEST.MF | 8 ++++--- - .../org.eclipse.tycho.surefire.junit47/pom.xml | 10 ++++++++ - .../META-INF/MANIFEST.MF | 7 +++--- - .../org.eclipse.tycho.surefire.osgibooter/pom.xml | 5 ++++ - .../surefire/osgibooter/OsgiSurefireBooter.java | 20 ++++++++++------ - tycho-surefire/pom.xml | 2 +- - .../java/org/eclipse/tycho/surefire/TestMojo.java | 27 +++++++++++++++++++--- - 12 files changed, 85 insertions(+), 21 deletions(-) - -diff --git a/pom.xml b/pom.xml -index c43cc8d..6e5fde4 100644 ---- a/pom.xml -+++ b/pom.xml -@@ -390,7 +390,7 @@ - - org.apache.maven.plugins - maven-surefire-plugin -- 2.17 -+ 2.19.1 - - - org.apache.maven.plugins -diff --git a/tycho-surefire/org.eclipse.tycho.surefire.junit/META-INF/MANIFEST.MF b/tycho-surefire/org.eclipse.tycho.surefire.junit/META-INF/MANIFEST.MF -index da31140..fb5803f 100644 ---- a/tycho-surefire/org.eclipse.tycho.surefire.junit/META-INF/MANIFEST.MF -+++ b/tycho-surefire/org.eclipse.tycho.surefire.junit/META-INF/MANIFEST.MF -@@ -6,6 +6,7 @@ Bundle-Version: 0.23.0 - Fragment-Host: org.eclipse.tycho.surefire.osgibooter;bundle-version="0.14.0" - Bundle-RequiredExecutionEnvironment: J2SE-1.5, - JavaSE-1.6 --Require-Bundle: org.junit;bundle-version="[3.8.0,4.0.0)" --Bundle-ClassPath: jars/surefire-junit3-2.17.jar -+Require-Bundle: org.junit;bundle-version="[3.8.0,5.0.0)" -+Bundle-ClassPath: jars/surefire-junit3-2.19.1.jar, -+ jars/common-junit3-2.19.1.jar - Bundle-Vendor: %providerName -diff --git a/tycho-surefire/org.eclipse.tycho.surefire.junit/pom.xml b/tycho-surefire/org.eclipse.tycho.surefire.junit/pom.xml -index f99c319..0224cc6 100644 ---- a/tycho-surefire/org.eclipse.tycho.surefire.junit/pom.xml -+++ b/tycho-surefire/org.eclipse.tycho.surefire.junit/pom.xml -@@ -44,6 +44,11 @@ - surefire-junit3 - ${surefire-version} - -+ -+ org.apache.maven.surefire -+ common-junit3 -+ ${surefire-version} -+ - - - -diff --git a/tycho-surefire/org.eclipse.tycho.surefire.junit4/META-INF/MANIFEST.MF b/tycho-surefire/org.eclipse.tycho.surefire.junit4/META-INF/MANIFEST.MF -index 50be5ea..97760e2 100644 ---- a/tycho-surefire/org.eclipse.tycho.surefire.junit4/META-INF/MANIFEST.MF -+++ b/tycho-surefire/org.eclipse.tycho.surefire.junit4/META-INF/MANIFEST.MF -@@ -6,9 +6,12 @@ Bundle-Version: 0.23.0 - Fragment-Host: org.eclipse.tycho.surefire.osgibooter;bundle-version="0.14.0" - Bundle-RequiredExecutionEnvironment: J2SE-1.5, - JavaSE-1.6 --Bundle-ClassPath: jars/surefire-junit4-2.17.jar -+Bundle-ClassPath: jars/surefire-junit4-2.19.1.jar, -+ jars/common-junit3-2.19.1.jar, -+ jars/common-junit4-2.19.1.jar - Import-Package: junit.framework;version="3.0.0", - org.junit;version="4.0.0", - org.junit.runner;version="4.0.0", -+ org.junit.runner.manipulation;version="4.0.0", - org.junit.runner.notification;version="4.0.0" - Bundle-Vendor: %providerName -diff --git a/tycho-surefire/org.eclipse.tycho.surefire.junit4/pom.xml b/tycho-surefire/org.eclipse.tycho.surefire.junit4/pom.xml -index 9628b06..2a09e91 100644 ---- a/tycho-surefire/org.eclipse.tycho.surefire.junit4/pom.xml -+++ b/tycho-surefire/org.eclipse.tycho.surefire.junit4/pom.xml -@@ -44,6 +44,16 @@ - surefire-junit4 - ${surefire-version} - -+ -+ org.apache.maven.surefire -+ common-junit3 -+ ${surefire-version} -+ -+ -+ org.apache.maven.surefire -+ common-junit4 -+ ${surefire-version} -+ - - - -diff --git a/tycho-surefire/org.eclipse.tycho.surefire.junit47/META-INF/MANIFEST.MF b/tycho-surefire/org.eclipse.tycho.surefire.junit47/META-INF/MANIFEST.MF -index 595265b..1ac6c5d 100644 ---- a/tycho-surefire/org.eclipse.tycho.surefire.junit47/META-INF/MANIFEST.MF -+++ b/tycho-surefire/org.eclipse.tycho.surefire.junit47/META-INF/MANIFEST.MF -@@ -6,9 +6,11 @@ Bundle-Version: 0.23.0 - Fragment-Host: org.eclipse.tycho.surefire.osgibooter;bundle-version="0.16.0" - Bundle-RequiredExecutionEnvironment: J2SE-1.5 - Bundle-ClassPath: ., -- jars/surefire-junit47-2.17.jar, -- jars/common-junit48-2.17.jar, -- jars/surefire-grouper-2.17.jar -+ jars/surefire-junit47-2.19.1.jar, -+ jars/common-junit48-2.19.1.jar, -+ jars/surefire-grouper-2.19.1.jar, -+ jars/common-junit3-2.19.1.jar, -+ jars/common-junit4-2.19.1.jar - Import-Package: junit.framework;version="3.0.0", - org.junit;version="[4.7,5)", - org.junit.runner;version="[4.7,5)", -diff --git a/tycho-surefire/org.eclipse.tycho.surefire.junit47/pom.xml b/tycho-surefire/org.eclipse.tycho.surefire.junit47/pom.xml -index dc49a46..db453ac 100644 ---- a/tycho-surefire/org.eclipse.tycho.surefire.junit47/pom.xml -+++ b/tycho-surefire/org.eclipse.tycho.surefire.junit47/pom.xml -@@ -54,6 +54,16 @@ - surefire-grouper - ${surefire-version} - -+ -+ org.apache.maven.surefire -+ common-junit4 -+ ${surefire-version} -+ -+ -+ org.apache.maven.surefire -+ common-junit3 -+ ${surefire-version} -+ - - - -diff --git a/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/META-INF/MANIFEST.MF b/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/META-INF/MANIFEST.MF -index 991edc1..83732d5 100644 ---- a/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/META-INF/MANIFEST.MF -+++ b/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/META-INF/MANIFEST.MF -@@ -5,9 +5,10 @@ Require-Bundle: org.eclipse.osgi;bundle-version="3.2.2", - Eclipse-AutoStart: true - Bundle-Version: 1.0.0 - Bundle-ClassPath: ., -- jars/surefire-booter-2.17.jar, -- jars/surefire-api-2.17.jar, -- jars/maven-surefire-common-2.17.jar -+ jars/surefire-booter-2.19.1.jar, -+ jars/surefire-api-2.19.1.jar, -+ jars/maven-surefire-common-2.19.1.jar, -+ jars/plexus-utils-3.0.jar - Bundle-Name: Tycho Surefire OSGi Booter Eclipse Application - Bundle-ManifestVersion: 2 - Bundle-SymbolicName: org.eclipse.tycho.surefire.osgibooter;singleton:=true -diff --git a/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/pom.xml b/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/pom.xml -index 82700eb..3fbc3a3 100644 ---- a/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/pom.xml -+++ b/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/pom.xml -@@ -57,6 +57,11 @@ - maven-surefire-common - ${surefire-version} - -+ -+ org.codehaus.plexus -+ plexus-utils -+ 3.0 -+ - - - -diff --git a/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/src/main/java/org/eclipse/tycho/surefire/osgibooter/OsgiSurefireBooter.java b/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/src/main/java/org/eclipse/tycho/surefire/osgibooter/OsgiSurefireBooter.java -index 19eeab9..31e9d3e 100644 ---- a/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/src/main/java/org/eclipse/tycho/surefire/osgibooter/OsgiSurefireBooter.java -+++ b/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/src/main/java/org/eclipse/tycho/surefire/osgibooter/OsgiSurefireBooter.java -@@ -21,7 +21,9 @@ - import java.net.URL; - import java.util.ArrayList; - import java.util.Arrays; -+import java.util.Collections; - import java.util.Enumeration; -+import java.util.HashMap; - import java.util.List; - import java.util.Map; - import java.util.Properties; -@@ -36,12 +38,15 @@ - import org.apache.maven.surefire.booter.PropertiesWrapper; - import org.apache.maven.surefire.booter.ProviderConfiguration; - import org.apache.maven.surefire.booter.ProviderFactory; -+import org.apache.maven.surefire.booter.Shutdown; - import org.apache.maven.surefire.booter.StartupConfiguration; -+import org.apache.maven.surefire.cli.CommandLineOption; - import org.apache.maven.surefire.report.ReporterConfiguration; - import org.apache.maven.surefire.report.ReporterFactory; - import org.apache.maven.surefire.suite.RunResult; - import org.apache.maven.surefire.testset.DirectoryScannerParameters; - import org.apache.maven.surefire.testset.RunOrderParameters; -+import org.apache.maven.surefire.testset.TestListResolver; - import org.apache.maven.surefire.testset.TestRequest; - import org.eclipse.core.runtime.CoreException; - import org.eclipse.core.runtime.IStatus; -@@ -62,7 +67,11 @@ - File reportsDir = new File(testProps.getProperty("reportsdirectory")); - String provider = testProps.getProperty("testprovider"); - String runOrder = testProps.getProperty("runOrder"); -- PropertiesWrapper wrapper = new PropertiesWrapper(testProps); -+ Map testPropsMap = new HashMap(); -+ for (Map.Entry e : testProps.entrySet()) { -+ testPropsMap.put((String) e.getKey(), (String) e.getValue()); -+ } -+ PropertiesWrapper wrapper = new PropertiesWrapper(testPropsMap); - List suiteXmlFiles = wrapper.getStringList(BooterConstants.TEST_SUITE_XML_FILES); - - boolean forkRequested = true; -@@ -79,16 +88,17 @@ - new ClassLoaderConfiguration(useSystemClassloader, useManifestOnlyJar), forkRequested, inForkedVM); - // TODO dir scanning with no includes done here (done in TestMojo already) - // but without dirScannerParams we get an NPE accessing runOrder -- DirectoryScannerParameters dirScannerParams = new DirectoryScannerParameters(testClassesDir, emptyList(), -- emptyList(), emptyList(), failIfNoTests, runOrder); -+ DirectoryScannerParameters dirScannerParams = new DirectoryScannerParameters(testClassesDir, Collections.emptyList(), -+ Collections.emptyList(), Collections.emptyList(), failIfNoTests, runOrder); - ReporterConfiguration reporterConfig = new ReporterConfiguration(reportsDir, trimStacktrace); -- TestRequest testRequest = new TestRequest(suiteXmlFiles, testClassesDir, null); -+ TestRequest testRequest = new TestRequest(suiteXmlFiles, testClassesDir, new TestListResolver(Collections. emptyList())); - ProviderConfiguration providerConfiguration = new ProviderConfiguration(dirScannerParams, - new RunOrderParameters(runOrder, null), failIfNoTests, reporterConfig, null, testRequest, -- extractProviderProperties(testProps), null, false); -+ extractProviderProperties(testProps), null, false, Collections.emptyList(), -+ 0, Shutdown.DEFAULT); - StartupReportConfiguration startupReportConfig = new StartupReportConfiguration(useFile, printSummary, - StartupReportConfiguration.PLAIN_REPORT_FORMAT, redirectTestOutputToFile, disableXmlReport, reportsDir, -- trimStacktrace, null, "TESTHASH", false); -+ trimStacktrace, null, "TESTHASH", false, 0); - ReporterFactory reporterFactory = new DefaultReporterFactory(startupReportConfig); - // API indicates we should use testClassLoader below but surefire also tries - // to load surefire classes using this classloader -@@ -107,12 +117,12 @@ - /* - * See TestMojo#mergeProviderProperties - */ -- private static Properties extractProviderProperties(Properties surefireProps) { -- Properties providerProps = new Properties(); -+ private static Map extractProviderProperties(Properties surefireProps) { -+ Map providerProps = new HashMap(); - for (Map.Entry entry : surefireProps.entrySet()) { - String key = (String) entry.getKey(); - if (key.startsWith("__provider.")) { -- providerProps.put(key.substring("__provider.".length()), entry.getValue()); -+ providerProps.put(key.substring("__provider.".length()), (String)entry.getValue()); - } - } - return providerProps; -diff --git a/tycho-surefire/pom.xml b/tycho-surefire/pom.xml -index cb2b826..bbe5f29 100644 ---- a/tycho-surefire/pom.xml -+++ b/tycho-surefire/pom.xml -@@ -26,7 +26,7 @@ - Tycho Surefire Parent - - -- 2.17 -+ 2.19.1 -