Hello community, here is the log from the commit of package tycho for openSUSE:Factory checked in at 2020-07-16 12:12:07 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/tycho (Old) and /work/SRC/openSUSE:Factory/.tycho.new.3592 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "tycho" Thu Jul 16 12:12:07 2020 rev:4 rq:818536 version:1.6.0 Changes: -------- --- /work/SRC/openSUSE:Factory/tycho/tycho.changes 2020-04-01 19:19:27.775561475 +0200 +++ /work/SRC/openSUSE:Factory/.tycho.new.3592/tycho.changes 2020-07-16 12:13:35.110669435 +0200 @@ -1,0 +2,23 @@ +Fri Jul 3 09:59:22 UTC 2020 - Fridrich Strba <[email protected]> + +- Update to 1.6.0 +- Removed patches: + * build-against-surefire-2.21.patch + * build-against-surefire-2.22.patch + * port-to-surefire-junit-platform.patch + * tycho-fix-build.patch + * tycho-maven-archiver-3.0.1.patch + * tycho-maven-delegation.patch + * tycho-use-custom-resolver.patch + * use-java8-for-default-ee.patch +- Added patches: + * 0001-Fix-the-Tycho-build-to-work-on-Fedora.patch + * 0002-Implement-a-custom-resolver-for-Tycho-in-local-mode.patch + * 0003-Tycho-should-always-delegate-artifact-resolution-to-.patch + * 0004-Bug-537963-Make-the-default-EE-Java-1.8.patch + * 0005-Fix-uncaught-exception.patch + * 0006-Mockito-does-not-have-test-scope.patch + * 0007-Fix-dependency-problems-when-bootstrapping-with-extr.patch + * 0008-Use-custom-resolver-for-tycho-eclipserun-plugin.patch + +------------------------------------------------------------------- Old: ---- build-against-surefire-2.21.patch build-against-surefire-2.22.patch eclipse-bootstrap-photon.tar.xz org.eclipse.tycho-tycho-1.2.0.tar.xz port-to-surefire-junit-platform.patch tycho-fix-build.patch tycho-maven-archiver-3.0.1.patch tycho-maven-delegation.patch tycho-use-custom-resolver.patch use-java8-for-default-ee.patch New: ---- 0001-Fix-the-Tycho-build-to-work-on-Fedora.patch 0002-Implement-a-custom-resolver-for-Tycho-in-local-mode.patch 0003-Tycho-should-always-delegate-artifact-resolution-to-.patch 0004-Bug-537963-Make-the-default-EE-Java-1.8.patch 0005-Fix-uncaught-exception.patch 0006-Mockito-does-not-have-test-scope.patch 0007-Fix-dependency-problems-when-bootstrapping-with-extr.patch 0008-Use-custom-resolver-for-tycho-eclipserun-plugin.patch eclipse-bootstrap-2019-12.tar.xz org.eclipse.tycho-tycho-1.6.0.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ tycho.spec ++++++ --- /var/tmp/diff_new_pack.x7NKGF/_old 2020-07-16 12:13:37.398671749 +0200 +++ /var/tmp/diff_new_pack.x7NKGF/_new 2020-07-16 12:13:37.398671749 +0200 @@ -27,20 +27,15 @@ %global fp_p2_git_tag 290f67a4c717599b2f5166ea89aa5365571314b1 %global fp_p2_version 0.0.1 %global fp_p2_snap -SNAPSHOT +%global xmvn_libdir %(realpath $(dirname $(readlink -f $(which xmvn)))/../lib) %define __requires_exclude osgi* # Allow conditionally building without Junit 5 support %bcond_without junit5 -%if %{with bootstrap} -Name: tycho-bootstrap -%else -Name: tycho -%endif -Version: 1.2.0 +Version: 1.6.0 Release: 0 Summary: Plugins and extensions for building Eclipse plugins and OSGI bundles with Maven # license file is missing but all files having some licensing information are ASL 2.0 License: Apache-2.0 AND EPL-1.0 -Group: Development/Libraries/Java URL: https://eclipse.org/tycho # Tycho project source Source0: http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/snapshot/org.eclipse.tycho-%{git_tag}.tar.xz @@ -56,23 +51,23 @@ # Script that can be used to install or simulate installation of P2 # artifacts. It is used in OSGi requires generation. Source6: p2-install.sh -Patch0: tycho-fix-build.patch -# Submitted upstream: https://bugs.eclipse.org/bugs/show_bug.cgi?id=535564 -Patch1: tycho-maven-archiver-3.0.1.patch -Patch2: tycho-use-custom-resolver.patch -Patch3: tycho-maven-delegation.patch -# Changes needed for building against latest surefire -# Submitted upstream: https://bugs.eclipse.org/bugs/show_bug.cgi?id=537419 -Patch4: build-against-surefire-2.21.patch -Patch5: build-against-surefire-2.22.patch +# Fedora-specific patches +Patch0: 0001-Fix-the-Tycho-build-to-work-on-Fedora.patch +Patch1: 0002-Implement-a-custom-resolver-for-Tycho-in-local-mode.patch +Patch2: 0003-Tycho-should-always-delegate-artifact-resolution-to-.patch # Submitted upstream: https://bugs.eclipse.org/bugs/show_bug.cgi?id=537963 -Patch6: use-java8-for-default-ee.patch -# Build against org.apache.maven.surefire:surefire-junit-platform instead of -# against org.junit.platform:junit-platform-surefire-provider -Patch7: port-to-surefire-junit-platform.patch +Patch3: 0004-Bug-537963-Make-the-default-EE-Java-1.8.patch +# Fix compile error with uncaught exception +Patch4: 0005-Fix-uncaught-exception.patch +# Fix mis-scoped test deps, see: ebz#560394 +Patch5: 0006-Mockito-does-not-have-test-scope.patch +# Fix incorrect generated requires +Patch6: 0007-Fix-dependency-problems-when-bootstrapping-with-extr.patch +Patch7: 0008-Use-custom-resolver-for-tycho-eclipserun-plugin.patch Patch100: fedoraproject-p2-bootstrap-fix.patch BuildRequires: bash BuildRequires: fdupes +BuildRequires: glassfish-annotation-api BuildRequires: java-devel >= 1.8 BuildRequires: maven-local BuildRequires: unzip @@ -80,70 +75,72 @@ BuildRequires: mvn(biz.aQute.bnd:bnd-maven-plugin) BuildRequires: mvn(com.beust:jcommander) BuildRequires: mvn(de.pdark:decentxml) -BuildRequires: mvn(junit:junit) +BuildRequires: mvn(io.takari.polyglot:polyglot-common) BuildRequires: mvn(org.apache.commons:commons-compress) BuildRequires: mvn(org.apache.commons:commons-exec) BuildRequires: mvn(org.apache.commons:commons-lang3) BuildRequires: mvn(org.apache.felix:maven-bundle-plugin) -BuildRequires: mvn(org.apache.maven.plugin-testing:maven-plugin-testing-harness) BuildRequires: mvn(org.apache.maven.plugin-tools:maven-plugin-annotations) BuildRequires: mvn(org.apache.maven.plugins:maven-clean-plugin) BuildRequires: mvn(org.apache.maven.plugins:maven-dependency-plugin) BuildRequires: mvn(org.apache.maven.plugins:maven-install-plugin) BuildRequires: mvn(org.apache.maven.plugins:maven-plugin-plugin) BuildRequires: mvn(org.apache.maven.plugins:maven-source-plugin) -BuildRequires: mvn(org.apache.maven.shared:maven-verifier) BuildRequires: mvn(org.apache.maven.surefire:maven-surefire-common) BuildRequires: mvn(org.apache.maven.surefire:surefire-api) -BuildRequires: mvn(org.apache.maven.surefire:surefire-booter) -BuildRequires: mvn(org.apache.maven.surefire:surefire-logger-api) BuildRequires: mvn(org.apache.maven:maven-archiver) BuildRequires: mvn(org.apache.maven:maven-compat) BuildRequires: mvn(org.apache.maven:maven-core) +BuildRequires: mvn(org.apache.maven:maven-model) +BuildRequires: mvn(org.apache.maven:maven-model-builder) BuildRequires: mvn(org.apache.maven:maven-plugin-api) -BuildRequires: mvn(org.apiguardian:apiguardian-api) BuildRequires: mvn(org.codehaus.plexus:plexus-archiver) BuildRequires: mvn(org.codehaus.plexus:plexus-compiler-api) BuildRequires: mvn(org.codehaus.plexus:plexus-compiler-manager) BuildRequires: mvn(org.codehaus.plexus:plexus-component-annotations) BuildRequires: mvn(org.codehaus.plexus:plexus-component-metadata) -BuildRequires: mvn(org.codehaus.plexus:plexus-container-default) BuildRequires: mvn(org.codehaus.plexus:plexus-utils) -BuildRequires: mvn(org.easymock:easymock) -BuildRequires: mvn(org.eclipse.tycho:org.eclipse.jdt.compiler.apt) -BuildRequires: mvn(org.eclipse.tycho:org.eclipse.jdt.core) +BuildRequires: mvn(org.eclipse.jdt:ecj) +BuildRequires: mvn(org.eclipse.sisu:org.eclipse.sisu.plexus) BuildRequires: mvn(org.fedoraproject.xmvn:xmvn-api) BuildRequires: mvn(org.fedoraproject.xmvn:xmvn-core) BuildRequires: mvn(org.fedoraproject.xmvn:xmvn-install) BuildRequires: mvn(org.fedoraproject.xmvn:xmvn-parent:pom:) -BuildRequires: mvn(org.hamcrest:hamcrest-core) -BuildRequires: mvn(org.mockito:mockito-core) -BuildRequires: mvn(org.opentest4j:opentest4j) -BuildRequires: mvn(org.ow2.asm:asm-debug-all) +BuildRequires: mvn(org.ow2.asm:asm-tree) +BuildRequires: mvn(org.ow2.asm:asm-util) BuildRequires: mvn(org.slf4j:slf4j-api) BuildRequires: mvn(org.slf4j:slf4j-simple) +BuildConflicts: java >= 9 BuildConflicts: java-devel >= 9 +BuildConflicts: java-headless >= 9 Requires: ecj >= 4.7.3a-1 # maven-clean-plugin is bound to "initialize" Maven phase for # "eclipse-repository" projects Requires: maven-clean-plugin Requires: maven-local Requires: xmvn-minimal >= 3 +# Extras was folded into the main tycho package +Obsoletes: tycho-extras < %{version}-%{release} +Provides: tycho-extras = %{version}-%{release} BuildArch: noarch +# Upstream Eclipse no longer supports non-64bit arches +ExcludeArch: s390 %{arm} %{ix86} +%if %{with bootstrap} +Name: tycho-bootstrap +%else +Name: tycho +%endif # Prebuilt Eclipse bundles needed to build Tycho when Eclipse is not present # or when the Eclipse that is present is not compatible %if %{with bootstrap} -Source10: eclipse-bootstrap-photon.tar.xz +Source10: eclipse-bootstrap-2019-12.tar.xz %endif -%if %{without bootstrap} -# Ordinarily Tycho additionally requires itself and Eclipse to build -BuildRequires: %{name}-bootstrap -BuildRequires: eclipse-platform-bootstrap >= 4.8.0 -Requires: eclipse-platform >= 4.8.0 -Obsoletes: %{name}-bootstrap -#!BuildRequires: eclipse-emf-core-bootstrap -#!BuildRequires: eclipse-ecf-core-bootstrap -%else +%if %{with junit5} +BuildRequires: mvn(org.apache.maven.surefire:surefire-junit-platform) +BuildRequires: mvn(org.apiguardian:apiguardian-api) +BuildRequires: mvn(org.opentest4j:opentest4j) +%endif +%if %{with bootstrap} # For bootstrapping, we just need the dependencies of the Eclipse bundles we use BuildRequires: osgi(com.ibm.icu) BuildRequires: osgi(javax.servlet-api) @@ -151,14 +148,18 @@ BuildRequires: osgi(org.apache.batik.css) BuildRequires: osgi(org.apache.commons.jxpath) BuildRequires: osgi(org.apache.felix.scr) -BuildRequires: osgi(org.sat4j.core) >= 2.3.5 -BuildRequires: osgi(org.sat4j.pb) >= 2.3.5 +BuildRequires: osgi(org.sat4j.core) +BuildRequires: osgi(org.sat4j.pb) BuildRequires: osgi(org.w3c.css.sac) -%endif -%if %{with junit5} -BuildRequires: mvn(org.apache.maven.surefire:surefire-junit-platform) -BuildRequires: mvn(org.apiguardian:apiguardian-api) -BuildRequires: mvn(org.opentest4j:opentest4j) +BuildRequires: osgi(osgi.cmpn) +%else +# Ordinarily Tycho additionally requires itself and Eclipse to build +BuildRequires: %{name}-bootstrap +BuildRequires: eclipse-platform-bootstrap +Requires: eclipse-platform +Obsoletes: %{name}-bootstrap +#!BuildRequires: eclipse-emf-core-bootstrap +#!BuildRequires: eclipse-ecf-core-bootstrap %endif %description @@ -188,7 +189,8 @@ %package javadoc Summary: Javadocs for %{name} -Group: Documentation/HTML +Obsoletes: tycho-extras-javadoc < %{version}-%{release} +Provides: tycho-extras-javadoc = %{version}-%{release} %description javadoc This package contains the API documentation for %{name}. @@ -198,11 +200,11 @@ mv fedoraproject-p2-%{fp_p2_git_tag} fedoraproject-p2 %patch0 -p1 -%patch1 +%patch1 -p1 %patch2 -p1 %patch3 -p1 %patch4 -p1 -%patch5 +%patch5 -p1 %patch6 -p1 %patch7 -p1 %patch100 @@ -210,14 +212,15 @@ # Unneeded for RPM builds %pom_remove_plugin :maven-site-plugin +# These tycho plug-ins don't make sense in the context of RPM builds of Eclipse plug-ins +%pom_disable_module tycho-buildtimestamp-jgit tycho-extras +%pom_disable_module tycho-sourceref-jgit tycho-extras + %if %{without junit5} %pom_disable_module org.eclipse.tycho.surefire.junit5 tycho-surefire %pom_remove_dep ":org.eclipse.tycho.surefire.junit5" tycho-surefire/tycho-surefire-plugin %endif -# Switch for "tycho" platform deps -%pom_change_dep org.eclipse.jdt: org.eclipse.tycho: . tycho-compiler-jdt - # Move from org.sonatype.aether to org.eclipse.aether find . -name "*.java" | xargs sed -i 's/org.sonatype.aether/org.eclipse.aether/g' find . -name "*.java" | xargs sed -i 's/org.eclipse.aether.util.DefaultRepositorySystemSession/org.eclipse.aether.DefaultRepositorySystemSession/g' @@ -229,46 +232,51 @@ cp %{SOURCE2} . popd -# These units cannot be found during a regular build -sed -i '/^<unit id=.*$/d' tycho-bundles/tycho-bundles-target/tycho-bundles-target.target +# Homogenise requirement on OSGi bundle +%if %{with bootstrap} +sed -i -e "s/>org.eclipse.platform</>org.eclipse.tycho</" pom.xml tycho-core/pom.xml sisu-equinox/sisu-equinox-embedder/pom.xml +%else +sed -i -e "s/>org.eclipse.tycho</>org.eclipse.platform</" fedoraproject-p2/xmvn-p2-installer-plugin/pom.xml +%endif -# we don't have org.apache.commons:commons-compress:jar:sources -%pom_xpath_remove "pom:dependency[pom:classifier='sources' and pom:artifactId='commons-compress']" tycho-p2/tycho-p2-director-plugin +# Target platform does not really apply to RPM builds +%pom_disable_module tycho-bundles-target tycho-bundles +%pom_xpath_remove "pom:target" tycho-bundles -# Previously, JUnit would re-export Hamcrest -# Now modules using org.hamcrest.core must state the requirement explicitly -for mod in tycho-bundles/org.eclipse.tycho.{p2.{maven.repository.tests,resolver.impl.test,tools.tests},test.utils,core.shared.tests}; do - sed -i 's/^Require-Bundle:// - /org\.junit/ i Require-Bundle: org.hamcrest.core,' \ - $mod/META-INF/MANIFEST.MF -done +# Disable maven-properties-plugin used by tests +%pom_remove_plugin org.sonatype.plugins:maven-properties-plugin tycho-extras/tycho-p2-extras-plugin +# Remove dep on maven tarball used by tests +%pom_remove_dep org.apache.maven:apache-maven tycho-extras/tycho-p2-extras-plugin -# Fix bundle names -sed -i -e 's/org\.hamcrest/org.hamcrest.core/' tycho-bundles/pom.xml -sed -i -e 's/org\.mockito/org.mockito.mockito-core/' \ - tycho-bundles/org.eclipse.tycho.p2.tools.tests/META-INF/MANIFEST.MF \ - tycho-bundles/org.eclipse.tycho.p2.maven.repository.tests/META-INF/MANIFEST.MF \ - tycho-bundles/org.eclipse.tycho.p2.resolver.shared.tests/META-INF/MANIFEST.MF - -# Bootstrap Build -%if %{with bootstrap} +# we don't have org.apache.commons:commons-compress:jar:sources +%pom_xpath_remove "pom:dependency[pom:classifier='sources' and pom:artifactId='commons-compress']" tycho-p2/tycho-p2-director-plugin -# Don't build tests when bootstrapping +# Don't build tests for b in core.shared.tests p2.resolver.impl.test p2.resolver.shared.tests p2.maven.repository.tests p2.tools.tests test.utils ; do %pom_disable_module org.eclipse.tycho.$b tycho-bundles done %pom_disable_module org.fedoraproject.p2.tests fedoraproject-p2 +%pom_disable_module tycho-testing-harness %pom_remove_dep -r :::test +# Bootstrap Build +%if %{with bootstrap} + +# Break circular dep between tycho-lib-detector and tycho-compiler-jdt for bootstrapping +%pom_xpath_remove "pom:compilerId" tycho-lib-detector +%pom_remove_dep "org.eclipse.tycho:tycho-compiler-jdt" tycho-lib-detector + # Unpack a compatible version of Eclipse we can use to build against tar -xf %{SOURCE10} # Install OSGi bundles into local repo to override any incompatible system version # that may be already installed pushd bootstrap for f in usr/lib/eclipse/plugins/org.eclipse.osgi.compatibility.state_*.jar \ + usr/lib/eclipse/plugins/org.eclipse.osgi.services_*.jar \ + usr/lib/eclipse/plugins/org.eclipse.osgi.util_*.jar \ usr/lib/eclipse/plugins/org.eclipse.osgi_*.jar ; do xmvn -o install:install-file -Dfile=$f -Dpackaging=jar -DgroupId=org.eclipse.tycho -Dmaven.repo.local=$(pwd)/../.m2 \ - -DartifactId=$(echo $(basename $f) | cut -d_ -f1) -Dversion=$(echo "${f%.jar}" | cut -d_ -f2) + -DartifactId=$(echo $(basename $f) | cut -d_ -f1) -Dversion=$(echo "${f%%.jar}" | cut -d_ -f2) done popd @@ -299,6 +307,11 @@ jar uf boot/tycho-maven-plugin.jar META-INF/plexus/components.xml # Create XMvn metadata for the new JARs and POMs by customizing system Tycho metadata. +sed -i -e 's/xmlns=".*"//' boot/tycho-metadata.xml +%pom_xpath_remove -f "metadata/artifacts/artifact[artifactId='org.eclipse.osgi']" boot/tycho-metadata.xml +%pom_xpath_remove -f "metadata/artifacts/artifact[artifactId='org.eclipse.osgi.util']" boot/tycho-metadata.xml +%pom_xpath_remove -f "metadata/artifacts/artifact[artifactId='org.eclipse.osgi.services']" boot/tycho-metadata.xml +%pom_xpath_remove -f "metadata/artifacts/artifact[artifactId='org.eclipse.osgi.compatibility.state']" boot/tycho-metadata.xml sed -i ' s|>/[^<]*/\([^/]*\.pom\)</path>|>'$PWD'/boot/\1</path>| s|>'$sysVer'</version>|>%{version}-SNAPSHOT</version><compatVersions><version>%{version}-SNAPSHOT</version></compatVersions>| @@ -323,7 +336,7 @@ # Add fp-p2 to main build %pom_xpath_inject "pom:modules" "<module>fedoraproject-p2</module>" -%mvn_file :{*} tycho/@1 +%{mvn_file} :{*} tycho/@1 %build %if %{with bootstrap} @@ -343,14 +356,12 @@ # Don't package target platform definition files %{mvn_package} "::target::" __noinstall -# Don't package fp-p2 tests -%{mvn_package} ":org.fedoraproject.p2.tests" __noinstall %install # Get debundling scripts cp %{SOURCE3} %{SOURCE5} . -%if ! %{with bootstrap} +%if %{without bootstrap} # Debundle p2 runtime bash tycho-debundle.sh $(pwd)/tycho-bundles/tycho-bundles-external \ $(pwd)/tycho-bundles/tycho-bundles-external/target/tycho-bundles-external-manifest.txt @@ -362,17 +373,20 @@ %if %{with bootstrap} # Install our own copy of OSGi runtime when bootstrapping to avoid external dep on Eclipse for b in org.eclipse.osgi \ + org.eclipse.osgi.util \ + org.eclipse.osgi.services \ org.eclipse.osgi.compatibility.state ; do osgiJarPath=$(find .m2/org/eclipse/tycho/$b/*/ -name "*.jar") osgiPomPath=$(find .m2/org/eclipse/tycho/$b/*/ -name "*.pom") %{mvn_artifact} $osgiPomPath $osgiJarPath - %{mvn_alias} "org.eclipse.tycho:$b" "org.eclipse.osgi:$b" done %endif %mvn_install -%if ! %{with bootstrap} +%if %{without bootstrap} +%fdupes -s %{buildroot}%{_javadocdir} + install -pm 644 tycho-bundles/tycho-bundles-external/target/tycho-bundles-external-manifest.txt %{buildroot}%{_javadir}/tycho %add_maven_depmap org.eclipse.tycho:tycho-bundles-external:txt:manifest:%{version} tycho/tycho-bundles-external-manifest.txt %endif @@ -407,23 +421,22 @@ install -pm 755 %{SOURCE6} %{buildroot}%{_javadir}-utils/ # Symlink XMvn P2 plugin with all dependencies so that it can be loaded by XMvn -xmvn_libdir=$(realpath $(dirname $(readlink -f $(which xmvn)))/../lib) -install -dm 755 %{buildroot}${xmvn_libdir}/installer/ +install -dm 755 %{buildroot}%{xmvn_libdir}/installer/ %if %{with bootstrap} -ln -s %{_javadir}/tycho/org.eclipse.osgi.jar %{buildroot}${xmvn_libdir}/installer/ +ln -s %{_javadir}/tycho/org.eclipse.osgi.jar %{buildroot}%{xmvn_libdir}/installer/ %else -ln -s %{_javadir}/eclipse/osgi.jar %{buildroot}${xmvn_libdir}/installer/ +ln -s %{_javadir}/eclipse/osgi.jar %{buildroot}%{xmvn_libdir}/installer/ %endif -ln -s %{_javadir}/tycho/xmvn-p2-installer-plugin.jar %{buildroot}${xmvn_libdir}/installer/ -ln -s %{_javadir}/tycho/org.fedoraproject.p2.jar %{buildroot}${xmvn_libdir}/installer/ +ln -s %{_javadir}/tycho/xmvn-p2-installer-plugin.jar %{buildroot}%{xmvn_libdir}/installer/ +ln -s %{_javadir}/tycho/org.fedoraproject.p2.jar %{buildroot}%{xmvn_libdir}/installer/ %files -f .mfiles +%{xmvn_libdir}/installer +%{_javadir}-utils/p2-install.sh %if %{with bootstrap} %{_javadir}/tycho/core.*.jar %{_javadir}/tycho/equinox.*.jar %endif -%{_datadir}/xmvn/lib/installer -%{_javadir}-utils/p2-install.sh %doc README.md %if %{without bootstrap} ++++++ 0001-Fix-the-Tycho-build-to-work-on-Fedora.patch ++++++ From a09c1b1a9068d53d83b84948fb1a5b1379b01bcc Mon Sep 17 00:00:00 2001 From: Roland Grunberg <[email protected]> Date: Tue, 12 Jun 2012 09:56:38 -0400 Subject: [PATCH 1/8] Fix the Tycho build to work on Fedora. Minor fixes of limited scope needed to have Tycho building on Fedora. Change-Id: Ic8c0514c1fa10ee53580d2654ac6a363ccd66814 --- .../core/maven/TychoMavenLifecycleParticipant.java | 4 +++- .../tycho/test/AbstractTychoIntegrationTest.java | 11 +++++------ 2 files changed, 8 insertions(+), 7 deletions(-) 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 3cba466..f733774 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<MavenProject> 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 9d7bcb7..5b97868 100644 --- 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 @@ -113,12 +113,11 @@ public abstract class AbstractTychoIntegrationTest { verifier.getCliOptions().add(customOptions); } - if (System.getProperty(SYSPROP_STATELOCATION) != null) { - verifier.setForkJvm(false); - String m2eresolver = System.getProperty("tychodev-maven.ext.class.path"); // XXX - if (m2eresolver != null) { - verifier.addCliOption("-Dmaven.ext.class.path=" + m2eresolver); - } + String m2eState = System.getProperty("m2eclipse.workspace.state"); + String m2eResolver = System.getProperty("m2eclipse.workspace.resolver"); + + if (m2eState != null && m2eResolver != null) { + verifier.getVerifierProperties().put("m2eclipse.workspace.state", m2eState); } return verifier; -- 2.21.1 ++++++ 0002-Implement-a-custom-resolver-for-Tycho-in-local-mode.patch ++++++ ++++ 647 lines (skipped) ++++++ 0003-Tycho-should-always-delegate-artifact-resolution-to-.patch ++++++ ++++ 678 lines (skipped) ++++++ 0004-Bug-537963-Make-the-default-EE-Java-1.8.patch ++++++ From 2bafd02390adb77ef65c2d706b364cf42eb598cb Mon Sep 17 00:00:00 2001 From: Mat Booth <[email protected]> Date: Wed, 15 Aug 2018 15:58:10 +0100 Subject: [PATCH 4/8] Bug 537963 - Make the default EE Java 1.8 This allows bundles that don't otherwise specify an EE (for example if the bundle contains only a plugin.xml, or is a documentation only bundle, or otherwise does not contain any bytecode) to continue working in environments that are supported by the latest release of Eclipse. Change-Id: Ic6e41c3000c85e2e4222e8153e84b7701ab0e750 Signed-off-by: Mat Booth <[email protected]> --- .../tycho/osgicompiler/test/OsgiCompilerTest.java | 6 +++--- .../ee/ExecutionEnvironmentConfigurationImpl.java | 6 +++--- .../ee/ExecutionEnvironmentConfigurationTest.java | 4 ++-- .../tycho/core/osgitools/EquinoxResolverTest.java | 2 +- .../org/eclipse/tycho/core/test/TychoTest.java | 5 ++++- .../src/test/resources/projects/bree/pom.xml | 1 + .../bree/tycho-default/META-INF/MANIFEST.MF | 5 +++++ .../projects/bree/tycho-default/build.properties | 2 ++ .../resources/projects/bree/tycho-default/pom.xml | 15 +++++++++++++++ 9 files changed, 36 insertions(+), 10 deletions(-) create mode 100644 tycho-core/src/test/resources/projects/bree/tycho-default/META-INF/MANIFEST.MF create mode 100644 tycho-core/src/test/resources/projects/bree/tycho-default/build.properties create mode 100644 tycho-core/src/test/resources/projects/bree/tycho-default/pom.xml diff --git a/tycho-compiler-plugin/src/test/java/org/eclipse/tycho/osgicompiler/test/OsgiCompilerTest.java b/tycho-compiler-plugin/src/test/java/org/eclipse/tycho/osgicompiler/test/OsgiCompilerTest.java index a88cf1e..fb00f81 100644 --- a/tycho-compiler-plugin/src/test/java/org/eclipse/tycho/osgicompiler/test/OsgiCompilerTest.java +++ b/tycho-compiler-plugin/src/test/java/org/eclipse/tycho/osgicompiler/test/OsgiCompilerTest.java @@ -37,7 +37,7 @@ import copied.org.apache.maven.plugin.CompilationFailureException; public class OsgiCompilerTest extends AbstractTychoMojoTestCase { private static final int TARGET_1_4 = 48; - private static final int TARGET_9 = 53; + private static final int TARGET_8 = 52; protected File storage; @@ -235,10 +235,10 @@ public class OsgiCompilerTest extends AbstractTychoMojoTestCase { List<MavenProject> projects = getSortedProjects(basedir, null); MavenProject project; // project with neither POM nor MANIFEST configuration => must fallback to - // source/target level == 9 + // source/target level == 8 project = projects.get(1); getMojo(projects, project).execute(); - assertBytecodeMajorLevel(TARGET_9, new File(project.getBasedir(), "target/classes/Generic.class")); + assertBytecodeMajorLevel(TARGET_8, new File(project.getBasedir(), "target/classes/Generic.class")); // project with multiple execution envs. // Minimum source and target level must be taken diff --git a/tycho-core/src/main/java/org/eclipse/tycho/core/ee/ExecutionEnvironmentConfigurationImpl.java b/tycho-core/src/main/java/org/eclipse/tycho/core/ee/ExecutionEnvironmentConfigurationImpl.java index 11f0ccf..ea67379 100644 --- a/tycho-core/src/main/java/org/eclipse/tycho/core/ee/ExecutionEnvironmentConfigurationImpl.java +++ b/tycho-core/src/main/java/org/eclipse/tycho/core/ee/ExecutionEnvironmentConfigurationImpl.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012, 2014 SAP SE and others. + * Copyright (c) 2012, 2018 SAP SE and others. * 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 @@ -19,8 +19,8 @@ import org.eclipse.tycho.core.ee.shared.SystemCapability; import org.eclipse.tycho.core.shared.BuildFailureException; public class ExecutionEnvironmentConfigurationImpl implements ExecutionEnvironmentConfiguration { - // Most likely best to always be the latest known supported EE - private static final String DEFAULT_EXECUTION_ENVIRONMENT = "JavaSE-9"; + // Most likely best to always be the latest known supported long-term supported EE + private static final String DEFAULT_EXECUTION_ENVIRONMENT = "JavaSE-1.8"; private static final int PRIMARY = 0; private static final int SECONDARY = 1; diff --git a/tycho-core/src/test/java/org/eclipse/tycho/core/ee/ExecutionEnvironmentConfigurationTest.java b/tycho-core/src/test/java/org/eclipse/tycho/core/ee/ExecutionEnvironmentConfigurationTest.java index 5cc98f1..afd9c1e 100644 --- a/tycho-core/src/test/java/org/eclipse/tycho/core/ee/ExecutionEnvironmentConfigurationTest.java +++ b/tycho-core/src/test/java/org/eclipse/tycho/core/ee/ExecutionEnvironmentConfigurationTest.java @@ -45,9 +45,9 @@ public class ExecutionEnvironmentConfigurationTest { @Test public void testDefaults() { - assertThat(subject.getProfileName(), is("JavaSE-9")); + assertThat(subject.getProfileName(), is("JavaSE-1.8")); assertThat(subject.isCustomProfile(), is(false)); - assertThat(subject.getFullSpecification().getProfileName(), is("JavaSE-9")); + assertThat(subject.getFullSpecification().getProfileName(), is("JavaSE-1.8")); } @Test diff --git a/tycho-core/src/test/java/org/eclipse/tycho/core/osgitools/EquinoxResolverTest.java b/tycho-core/src/test/java/org/eclipse/tycho/core/osgitools/EquinoxResolverTest.java index 5c96236..b60ae4b 100644 --- a/tycho-core/src/test/java/org/eclipse/tycho/core/osgitools/EquinoxResolverTest.java +++ b/tycho-core/src/test/java/org/eclipse/tycho/core/osgitools/EquinoxResolverTest.java @@ -61,7 +61,7 @@ public class EquinoxResolverTest extends AbstractTychoMojoTestCase { properties.put("tycho-version", TychoVersion.getTychoVersion()); List<MavenProject> projects = getSortedProjects(basedir, properties, null); - assertEquals(6, projects.size()); + assertEquals(7, projects.size()); assertEquals("executionenvironment.manifest-minimal", projects.get(2).getArtifactId()); ExecutionEnvironment ee = TychoProjectUtils.getExecutionEnvironmentConfiguration(projects.get(2)) diff --git a/tycho-core/src/test/java/org/eclipse/tycho/core/test/TychoTest.java b/tycho-core/src/test/java/org/eclipse/tycho/core/test/TychoTest.java index ba6b69e..4ebe5ed 100644 --- a/tycho-core/src/test/java/org/eclipse/tycho/core/test/TychoTest.java +++ b/tycho-core/src/test/java/org/eclipse/tycho/core/test/TychoTest.java @@ -360,7 +360,7 @@ public class TychoTest extends AbstractTychoMojoTestCase { properties.put("tycho-version", TychoVersion.getTychoVersion()); List<MavenProject> projects = getSortedProjects(basedir, properties, null); - assertEquals(6, projects.size()); + assertEquals(7, projects.size()); int i = 0; assertEquals("executionenvironment.manifest", projects.get(++i).getArtifactId()); @@ -377,6 +377,9 @@ public class TychoTest extends AbstractTychoMojoTestCase { assertEquals("executionenvironment.pom-default", projects.get(++i).getArtifactId()); assertEquals("OSGi/Minimum-1.2", getActiveEEProfile(projects.get(i))); + + assertEquals("executionenvironment.tycho-default", projects.get(++i).getArtifactId()); + assertEquals("JavaSE-1.8", getActiveEEProfile(projects.get(i))); } public void testWithProjectReferencesItself() throws Exception { diff --git a/tycho-core/src/test/resources/projects/bree/pom.xml b/tycho-core/src/test/resources/projects/bree/pom.xml index 1ddff1d..18c5885 100644 --- a/tycho-core/src/test/resources/projects/bree/pom.xml +++ b/tycho-core/src/test/resources/projects/bree/pom.xml @@ -14,6 +14,7 @@ <module>pom-hard</module> <module>buildproperties</module> <module>pom-default</module> + <module>tycho-default</module> </modules> </project> diff --git a/tycho-core/src/test/resources/projects/bree/tycho-default/META-INF/MANIFEST.MF b/tycho-core/src/test/resources/projects/bree/tycho-default/META-INF/MANIFEST.MF new file mode 100644 index 0000000..e6d85c6 --- /dev/null +++ b/tycho-core/src/test/resources/projects/bree/tycho-default/META-INF/MANIFEST.MF @@ -0,0 +1,5 @@ +Manifest-Version: 1.0 +Bundle-ManifestVersion: 2 +Bundle-Name: A bundle that specifies no EE at all and relies on Tycho to set one. +Bundle-SymbolicName: executionenvironment.tycho-default +Bundle-Version: 1.0.0 diff --git a/tycho-core/src/test/resources/projects/bree/tycho-default/build.properties b/tycho-core/src/test/resources/projects/bree/tycho-default/build.properties new file mode 100644 index 0000000..7b02ed4 --- /dev/null +++ b/tycho-core/src/test/resources/projects/bree/tycho-default/build.properties @@ -0,0 +1,2 @@ +bin.includes = META-INF/ + diff --git a/tycho-core/src/test/resources/projects/bree/tycho-default/pom.xml b/tycho-core/src/test/resources/projects/bree/tycho-default/pom.xml new file mode 100644 index 0000000..f538f5e --- /dev/null +++ b/tycho-core/src/test/resources/projects/bree/tycho-default/pom.xml @@ -0,0 +1,15 @@ +<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> + <modelVersion>4.0.0</modelVersion> + + <parent> + <groupId>executionenvironment</groupId> + <artifactId>parent</artifactId> + <version>1.0.0</version> + </parent> + + <artifactId>executionenvironment.tycho-default</artifactId> + <version>1.0.0</version> + <packaging>eclipse-plugin</packaging> + +</project> -- 2.21.1 ++++++ 0005-Fix-uncaught-exception.patch ++++++ From 18bf98457aa55468fc9800eab5b4f78f95f546c9 Mon Sep 17 00:00:00 2001 From: Mat Booth <[email protected]> Date: Thu, 20 Feb 2020 16:08:00 +0000 Subject: [PATCH 5/8] Fix uncaught exception "unreported exception org.codehaus.plexus.configuration.PlexusConfigurationException; must be caught or declared to be thrown" --- .../tycho/extras/sourcefeature/SourceFeatureMojo.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tycho-extras/tycho-source-feature-plugin/src/main/java/org/eclipse/tycho/extras/sourcefeature/SourceFeatureMojo.java b/tycho-extras/tycho-source-feature-plugin/src/main/java/org/eclipse/tycho/extras/sourcefeature/SourceFeatureMojo.java index 9c95f2d..1f34a82 100644 --- a/tycho-extras/tycho-source-feature-plugin/src/main/java/org/eclipse/tycho/extras/sourcefeature/SourceFeatureMojo.java +++ b/tycho-extras/tycho-source-feature-plugin/src/main/java/org/eclipse/tycho/extras/sourcefeature/SourceFeatureMojo.java @@ -560,7 +560,12 @@ public class SourceFeatureMojo extends AbstractMojo { } private String getAttribute(PlexusConfiguration dom, String attrName) { - String attr = dom.getAttribute(attrName); + String attr = null; + try { + attr = dom.getAttribute(attrName); + } catch (Exception ex) { + attr = null; + } if (attr == null) { return null; } -- 2.21.1 ++++++ 0006-Mockito-does-not-have-test-scope.patch ++++++ From eed86a7fefb12f21a9076293dccb1a3c84e051fd Mon Sep 17 00:00:00 2001 From: Mat Booth <[email protected]> Date: Fri, 21 Feb 2020 10:08:13 +0000 Subject: [PATCH 6/8] Mockito does not have test scope Change-Id: Ia0554670d27f1f05dc0d5c72f9afbbbc32e7fdbb Signed-off-by: Mat Booth <[email protected]> --- tycho-artifactcomparator/pom.xml | 5 +++-- tycho-core/pom.xml | 3 ++- tycho-extras/tycho-eclipserun-plugin/pom.xml | 5 ++++- tycho-extras/tycho-pomless/pom.xml | 5 +++-- tycho-surefire/tycho-surefire-plugin/pom.xml | 4 +++- 5 files changed, 15 insertions(+), 7 deletions(-) diff --git a/tycho-artifactcomparator/pom.xml b/tycho-artifactcomparator/pom.xml index 9039f06..b2ee58a 100644 --- a/tycho-artifactcomparator/pom.xml +++ b/tycho-artifactcomparator/pom.xml @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="UTF-8"?> <!-- - - Copyright (c) 2012 Sonatype Inc. and others. + - Copyright (c) 2012, 2020 Sonatype Inc. and others. - 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 @@ -49,6 +49,7 @@ <dependency> <artifactId>junit</artifactId> <groupId>junit</groupId> + <scope>test</scope> </dependency> <dependency> <groupId>org.eclipse.sisu</groupId> @@ -68,4 +69,4 @@ </plugin> </plugins> </build> -</project> \ No newline at end of file +</project> diff --git a/tycho-core/pom.xml b/tycho-core/pom.xml index 9f2bf3b..bdd5a16 100644 --- a/tycho-core/pom.xml +++ b/tycho-core/pom.xml @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="UTF-8"?> <!-- - - Copyright (c) 2008, 2011 Sonatype Inc. and others. + - Copyright (c) 2008, 2020 Sonatype Inc. and others. - 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 @@ -168,6 +168,7 @@ <dependency> <groupId>org.mockito</groupId> <artifactId>mockito-core</artifactId> + <scope>test</scope> </dependency> </dependencies> diff --git a/tycho-extras/tycho-eclipserun-plugin/pom.xml b/tycho-extras/tycho-eclipserun-plugin/pom.xml index ffb886b..beedebc 100644 --- a/tycho-extras/tycho-eclipserun-plugin/pom.xml +++ b/tycho-extras/tycho-eclipserun-plugin/pom.xml @@ -1,5 +1,5 @@ <!-- -- Copyright (c) 2011 Marc-Andre Laperle and others. +- Copyright (c) 2011, 2020 Marc-Andre Laperle and others. - 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 @@ -42,14 +42,17 @@ <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> + <scope>test</scope> </dependency> <dependency> <groupId>org.eclipse.tycho</groupId> <artifactId>tycho-testing-harness</artifactId> + <scope>test</scope> </dependency> <dependency> <groupId>org.mockito</groupId> <artifactId>mockito-core</artifactId> + <scope>test</scope> </dependency> </dependencies> <profiles> diff --git a/tycho-extras/tycho-pomless/pom.xml b/tycho-extras/tycho-pomless/pom.xml index 2584910..f2d7ffa 100644 --- a/tycho-extras/tycho-pomless/pom.xml +++ b/tycho-extras/tycho-pomless/pom.xml @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="UTF-8"?> <!-- - - Copyright (c) 2015 SAP SE and others. + - Copyright (c) 2015, 2020 SAP SE and others. - 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 @@ -67,7 +67,8 @@ <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> + <scope>test</scope> </dependency> </dependencies> -</project> \ No newline at end of file +</project> diff --git a/tycho-surefire/tycho-surefire-plugin/pom.xml b/tycho-surefire/tycho-surefire-plugin/pom.xml index d03525a..5b2ac63 100644 --- a/tycho-surefire/tycho-surefire-plugin/pom.xml +++ b/tycho-surefire/tycho-surefire-plugin/pom.xml @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="UTF-8"?> <!-- - - Copyright (c) 2008, 2011 Sonatype Inc. and others. + - Copyright (c) 2008, 2020 Sonatype Inc. and others. - 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 @@ -162,10 +162,12 @@ <dependency> <groupId>org.mockito</groupId> <artifactId>mockito-core</artifactId> + <scope>test</scope> </dependency> <dependency> <groupId>org.eclipse.tycho</groupId> <artifactId>tycho-testing-harness</artifactId> + <scope>test</scope> </dependency> </dependencies> </project> -- 2.21.1 ++++++ 0007-Fix-dependency-problems-when-bootstrapping-with-extr.patch ++++++ From bf0f458e2cd41ad24ff212014a416c788477bfc4 Mon Sep 17 00:00:00 2001 From: Mat Booth <[email protected]> Date: Fri, 20 Mar 2020 02:35:02 +0000 Subject: [PATCH 7/8] Fix dependency problems when bootstrapping with extras --- tycho-extras/pack200/tycho-pack200b-plugin/pom.xml | 4 ++-- tycho-extras/pom.xml | 10 +++++----- tycho-extras/tycho-source-feature-plugin/pom.xml | 2 +- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/tycho-extras/pack200/tycho-pack200b-plugin/pom.xml b/tycho-extras/pack200/tycho-pack200b-plugin/pom.xml index f305eb3..4a3150b 100644 --- a/tycho-extras/pack200/tycho-pack200b-plugin/pom.xml +++ b/tycho-extras/pack200/tycho-pack200b-plugin/pom.xml @@ -36,7 +36,7 @@ <dependency> <groupId>org.eclipse.tycho</groupId> <artifactId>org.eclipse.tycho.p2.resolver.shared</artifactId> - <version>${tycho-version}</version> + <version>${project.version}</version> </dependency> </dependencies> -</project> \ No newline at end of file +</project> diff --git a/tycho-extras/pom.xml b/tycho-extras/pom.xml index 1769197..68c2bbe 100644 --- a/tycho-extras/pom.xml +++ b/tycho-extras/pom.xml @@ -88,28 +88,28 @@ <dependency> <groupId>org.eclipse.tycho</groupId> <artifactId>tycho-core</artifactId> - <version>${tycho-version}</version> + <version>${project.version}</version> </dependency> <dependency> <groupId>org.eclipse.tycho</groupId> <artifactId>tycho-p2-facade</artifactId> - <version>${tycho-version}</version> + <version>${project.version}</version> </dependency> <dependency> <groupId>org.eclipse.tycho</groupId> <artifactId>org.eclipse.tycho.core.shared</artifactId> - <version>${tycho-version}</version> + <version>${project.version}</version> </dependency> <dependency> <groupId>org.eclipse.tycho</groupId> <artifactId>tycho-testing-harness</artifactId> - <version>${tycho-version}</version> + <version>${project.version}</version> <scope>test</scope> </dependency> <dependency> <groupId>org.eclipse.tycho</groupId> <artifactId>sisu-equinox-launching</artifactId> - <version>${tycho-version}</version> + <version>${project.version}</version> </dependency> <dependency> <groupId>org.eclipse.tycho</groupId> diff --git a/tycho-extras/tycho-source-feature-plugin/pom.xml b/tycho-extras/tycho-source-feature-plugin/pom.xml index e305460..29fa308 100644 --- a/tycho-extras/tycho-source-feature-plugin/pom.xml +++ b/tycho-extras/tycho-source-feature-plugin/pom.xml @@ -42,7 +42,7 @@ <dependency> <groupId>org.eclipse.tycho</groupId> <artifactId>tycho-packaging-plugin</artifactId> - <version>${tycho-version}</version> + <version>${project.version}</version> <type>maven-plugin</type> </dependency> -- 2.21.1 ++++++ 0008-Use-custom-resolver-for-tycho-eclipserun-plugin.patch ++++++ From a19db9367faa7e88cb243b78c3a4a17069c6ea52 Mon Sep 17 00:00:00 2001 From: Roland Grunberg <[email protected]> Date: Mon, 6 May 2013 14:20:58 -0400 Subject: [PATCH 8/8] Use custom resolver for tycho-eclipserun-plugin. Add various system local OSGi bundle locations to the target platform used by tycho-eclipserun-plugin. Change-Id: Ifd0aae3f32c8077cd0ae33e70f40698c1129788d --- .../tycho/extras/eclipserun/EclipseRunMojo.java | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tycho-extras/tycho-eclipserun-plugin/src/main/java/org/eclipse/tycho/extras/eclipserun/EclipseRunMojo.java b/tycho-extras/tycho-eclipserun-plugin/src/main/java/org/eclipse/tycho/extras/eclipserun/EclipseRunMojo.java index b93e651..4032d10 100644 --- a/tycho-extras/tycho-eclipserun-plugin/src/main/java/org/eclipse/tycho/extras/eclipserun/EclipseRunMojo.java +++ b/tycho-extras/tycho-eclipserun-plugin/src/main/java/org/eclipse/tycho/extras/eclipserun/EclipseRunMojo.java @@ -13,6 +13,7 @@ package org.eclipse.tycho.extras.eclipserun; import java.io.File; import java.net.MalformedURLException; +import java.net.URI; import java.util.ArrayList; import java.util.List; import java.util.Map; @@ -52,6 +53,7 @@ import org.eclipse.tycho.p2.resolver.facade.P2Resolver; import org.eclipse.tycho.p2.resolver.facade.P2ResolverFactory; import org.eclipse.tycho.p2.target.facade.TargetPlatformConfigurationStub; import org.eclipse.tycho.plugins.p2.extras.Repository; +import org.fedoraproject.p2.EclipseSystemLayout; /** * Launch an eclipse process with arbitrary commandline arguments. The eclipse installation is @@ -225,6 +227,14 @@ public class EclipseRunMojo extends AbstractMojo { TargetPlatformConfigurationStub tpConfiguration = new TargetPlatformConfigurationStub(); // we want to resolve from remote repos only tpConfiguration.setForceIgnoreLocalArtifacts(true); + + // Add Fedora Local P2 Repository when running in local mode + if (System.getProperty("TYCHO_MVN_LOCAL") != null || System.getProperty("TYCHO_MVN_RPMBUILD") != null) { + for (URI uri : EclipseSystemLayout.getRepositories()) { + tpConfiguration.addP2Repository(new MavenRepositoryLocation(uri.getPath(), uri)); + } + } + for (Repository repository : repositories) { tpConfiguration.addP2Repository(new MavenRepositoryLocation(repository.getId(), repository.getLocation())); } -- 2.21.1 ++++++ org.eclipse.tycho-tycho-1.2.0.tar.xz -> org.eclipse.tycho-tycho-1.6.0.tar.xz ++++++ /work/SRC/openSUSE:Factory/tycho/org.eclipse.tycho-tycho-1.2.0.tar.xz /work/SRC/openSUSE:Factory/.tycho.new.3592/org.eclipse.tycho-tycho-1.6.0.tar.xz differ: char 26, line 1 ++++++ tycho-bootstrap.sh ++++++ --- /var/tmp/diff_new_pack.x7NKGF/_old 2020-07-16 12:13:37.550671902 +0200 +++ /var/tmp/diff_new_pack.x7NKGF/_new 2020-07-16 12:13:37.550671902 +0200 @@ -4,8 +4,8 @@ preV=$1 v="$preV-SNAPSHOT" -osgiV='3.13.0.v20180428-1222' -osgiCompatV='1.1.100.v20180428-1222' +osgiV='3.15.100.v20191219-0358' +osgiCompatV='1.1.600.v20191219-0358' fp2V='0.0.1-SNAPSHOT' bundles=() bundles[0]='tycho-bundles/org.eclipse.tycho.embedder.shared' @@ -94,7 +94,7 @@ echo '#Product Runtime Configuration File #Thu Dec 19 21:40:37 EST 2013 -osgi.bundles=org.apache.commons.codec,org.apache.commons.logging,org.apache.httpcomponents.httpclient,org.apache.httpcomponents.httpcore,org.eclipse.core.contenttype,org.eclipse.core.jobs,org.eclipse.core.net,org.eclipse.core.runtime@4\:start,org.eclipse.core.runtime.compatibility.registry,org.eclipse.ecf,org.eclipse.ecf.filetransfer,org.eclipse.ecf.identity,org.eclipse.ecf.provider.filetransfer,org.eclipse.ecf.provider.filetransfer.httpclient4,org.eclipse.ecf.provider.filetransfer.httpclient4.ssl,org.eclipse.ecf.provider.filetransfer.ssl,org.eclipse.ecf.ssl,org.eclipse.equinox.app,org.eclipse.equinox.common@2\:start,org.eclipse.equinox.concurrent,org.eclipse.equinox.ds@2\:start,org.eclipse.equinox.frameworkadmin,org.eclipse.equinox.frameworkadmin.equinox,org.eclipse.equinox.launcher,org.eclipse.equinox.p2.artifact.repository,org.eclipse.equinox.p2.core,org.eclipse.equinox.p2.director,org.eclipse.equinox.p2.director.app,org.eclipse.equinox.p2.engine,org.eclipse.equinox.p2.garbagecollector,org.eclipse.equinox.p2.jarprocessor,org.eclipse.equinox.p2.metadata,org.eclipse.equinox.p2.metadata.repository,org.eclipse.equinox.p2.publisher,org.eclipse.equinox.p2.publisher.eclipse,org.eclipse.equinox.p2.repository,org.eclipse.equinox.p2.repository.tools,org.eclipse.equinox.p2.touchpoint.eclipse,org.eclipse.equinox.p2.touchpoint.natives,org.eclipse.equinox.p2.transport.ecf,org.eclipse.equinox.p2.updatesite,org.eclipse.equinox.preferences,org.eclipse.equinox.registry,org.eclipse.equinox.security,org.eclipse.equinox.simpleconfigurator,org.eclipse.equinox.simpleconfigurator.manipulator,org.eclipse.equinox.util,org.eclipse.osgi.services,org.eclipse.osgi.compatibility.state,org.eclipse.tycho.noopsecurity,org.sat4j.core,org.sat4j.pb,org.eclipse.osgi.util,org.apache.felix.scr,org.kxml2,org.xmlpull,org.fedoraproject.p2 +osgi.bundles=org.apache.commons.codec,org.apache.commons.logging,org.apache.httpcomponents.httpclient,org.apache.httpcomponents.httpcore,org.eclipse.core.contenttype,org.eclipse.core.jobs,org.eclipse.core.net,org.eclipse.core.runtime@4\:start,org.eclipse.core.runtime.compatibility.registry,org.eclipse.ecf,org.eclipse.ecf.filetransfer,org.eclipse.ecf.identity,org.eclipse.ecf.provider.filetransfer,org.eclipse.ecf.provider.filetransfer.httpclient4,org.eclipse.ecf.provider.filetransfer.httpclient4.ssl,org.eclipse.ecf.provider.filetransfer.ssl,org.eclipse.ecf.ssl,org.eclipse.equinox.app,org.eclipse.equinox.common@2\:start,org.eclipse.equinox.concurrent,org.eclipse.equinox.ds@2\:start,org.eclipse.equinox.frameworkadmin,org.eclipse.equinox.frameworkadmin.equinox,org.eclipse.equinox.launcher,org.eclipse.equinox.p2.artifact.repository,org.eclipse.equinox.p2.core,org.eclipse.equinox.p2.director,org.eclipse.equinox.p2.director.app,org.eclipse.equinox.p2.engine,org.eclipse.equinox.p2.garbagecollector,org.eclipse.equinox.p2.jarprocessor,org.eclipse.equinox.p2.metadata,org.eclipse.equinox.p2.metadata.repository,org.eclipse.equinox.p2.publisher,org.eclipse.equinox.p2.publisher.eclipse,org.eclipse.equinox.p2.repository,org.eclipse.equinox.p2.repository.tools,org.eclipse.equinox.p2.touchpoint.eclipse,org.eclipse.equinox.p2.touchpoint.natives,org.eclipse.equinox.p2.transport.ecf,org.eclipse.equinox.p2.updatesite,org.eclipse.equinox.preferences,org.eclipse.equinox.registry,org.eclipse.equinox.security,org.eclipse.equinox.simpleconfigurator,org.eclipse.equinox.simpleconfigurator.manipulator,org.eclipse.equinox.util,org.eclipse.osgi.services,org.eclipse.osgi.compatibility.state,org.eclipse.tycho.noopsecurity,org.sat4j.core,org.sat4j.pb,org.eclipse.osgi.util,org.apache.felix.scr,org.osgi.cmpn.fedoraproject.p2 osgi.bundles.defaultStartLevel=4 eclipse.product=org.eclipse.equinox.p2.director.app.product osgi.splashPath=platform\:/base/plugins/org' > 'eclipse/configuration/config.ini' @@ -109,7 +109,7 @@ cp "${tbeTargetDir}/tycho-bundles-external-${v}.zip" ${loc} cp 'tycho-bundles/tycho-bundles-external/pom.xml' "${loc}/tycho-bundles-external-${v}.pom" -sed -i "s/<equinoxVersionMaven>.*<\/equinoxVersionMaven>/<equinoxVersionMaven>${osgiV}<\/equinoxVersionMaven>/" pom.xml -sed -i "s/<equinoxCompatVersionMaven>.*<\/equinoxCompatVersionMaven>/<equinoxCompatVersionMaven>${osgiCompatV}<\/equinoxCompatVersionMaven>/" pom.xml +sed -i "s/<equinoxVersion>.*<\/equinoxVersion>/<equinoxVersion>${osgiV}<\/equinoxVersion>/" pom.xml +sed -i "s/<equinoxCompatVersion>.*<\/equinoxCompatVersion>/<equinoxCompatVersion>${osgiCompatV}<\/equinoxCompatVersion>/" pom.xml # xmvn-p2-installer-plugin needs to find the org.eclipse.osgi bundle sed -i "s/>\${equinox-version}</>${osgiV}</" fedoraproject-p2/xmvn-p2-installer-plugin/pom.xml ++++++ tycho-scripts.sh ++++++ --- /var/tmp/diff_new_pack.x7NKGF/_old 2020-07-16 12:13:37.570671922 +0200 +++ /var/tmp/diff_new_pack.x7NKGF/_new 2020-07-16 12:13:37.570671922 +0200 @@ -4,11 +4,11 @@ basedir=$1 -src=`cat "${basedir}/build.properties" | grep 'source..' | cut -d'=' -f2 | tr ' ' '\0'` -output=`cat "${basedir}/build.properties" | grep 'output..' | cut -d'=' -f2 | tr ' ' '\0'` -bName=`cat "${basedir}/META-INF/MANIFEST.MF" | grep 'Bundle-SymbolicName:' | sed 's/Bundle-SymbolicName: \([a-zA-Z0-9_.-]*\)\(;\)\?.*/\1/'` -artifactId=`cat "${basedir}/pom.xml" | sed '/<parent>/,/<\/parent>/ d' | grep "<artifactId>" | sed 's/.*<artifactId>\(.*\)<\/artifactId>.*/\1/'` -version=`cat "${basedir}/pom.xml" | grep "<version>" | sed 's/.*<version>\(.*\)<\/version>.*/\1/'` +src=$(cat "${basedir}/build.properties" | grep 'source..' | cut -d'=' -f2 | sed -e 's/ //g') +output=$(cat "${basedir}/build.properties" | grep 'output..' | cut -d'=' -f2 | sed -e 's/ //g') +bName=$(cat "${basedir}/META-INF/MANIFEST.MF" | grep 'Bundle-SymbolicName:' | sed 's/Bundle-SymbolicName: \([a-zA-Z0-9_.-]*\)\(;\)\?.*/\1/') +artifactId=$(cat "${basedir}/pom.xml" | sed '/<parent>/,/<\/parent>/ d' | grep "<artifactId>" | sed 's/.*<artifactId>\(.*\)<\/artifactId>.*/\1/') +version=$(cat "${basedir}/pom.xml" | grep "<version>" | sed 's/.*<version>\(.*\)<\/version>.*/\1/') # External (System) dependencies if [ $# -eq 3 ]; then @@ -26,7 +26,7 @@ cp='-classpath '$2':'"${basedir}"'/target/externalDeps/*' fi -javac -d "${basedir}/${output}" \ +javac -d "${basedir}/${output}" -encoding utf8 -source 1.8 -target 1.8 \ $(for file in `find "${basedir}/${src}" -name "*.java"`; \ do echo -n "${file} "; \ done;) \
