[tycho] Non-bootstrap build.
by Roland Grunberg
commit 717b54a9e3538d0dc078ea4b785a7ccb471787a8
Author: Roland Grunberg <rgrunber(a)redhat.com>
Date: Mon Jun 11 15:18:19 2012 -0400
Non-bootstrap build.
tycho.spec | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/tycho.spec b/tycho.spec
index 1b613cc..f9fa8a2 100644
--- a/tycho.spec
+++ b/tycho.spec
@@ -1,4 +1,4 @@
-%global bootstrap 1
+%global bootstrap 0
%if %{bootstrap}
%global snap -SNAPSHOT
@@ -8,7 +8,7 @@
Name: tycho
Version: 0.14.1
-Release: 4.1%{?dist}
+Release: 5%{?dist}
Summary: Plugins and extensions for building Eclipse plugins and OSGI bundles with Maven
Group: Development/Libraries
@@ -199,6 +199,9 @@ install -pm 755 %{SOURCE3} %{buildroot}%{_javadir}/%{name}/copy-platform-all
%{_javadocdir}/%{name}
%changelog
+* Mon Jun 11 2012 Roland Grunberg <rgrunber(a)redhat.com> 0.14.1-5
+- Non-bootstrap build.
+
* Tue May 29 2012 Roland Grunberg <rgrunber(a)redhat.com> 0.14.1-4.1
- Fix Tycho Surfire to run Eclipse test bundles.
- Implement automatic creation of a system p2 repository.
11 years, 10 months
[tycho] Only create system p2 repository when running in local mode.
by Roland Grunberg
commit ebce2e6f424f83c3ccd765591cabea447d33a8d4
Author: Roland Grunberg <rgrunber(a)redhat.com>
Date: Mon Jun 11 15:00:17 2012 -0400
Only create system p2 repository when running in local mode.
tycho-use-custom-resolver.patch | 30 ++++++++++++++++--------------
1 files changed, 16 insertions(+), 14 deletions(-)
---
diff --git a/tycho-use-custom-resolver.patch b/tycho-use-custom-resolver.patch
index 1e3992d..db8b4b3 100644
--- a/tycho-use-custom-resolver.patch
+++ b/tycho-use-custom-resolver.patch
@@ -1,4 +1,4 @@
-From 590e6eb40fb807c5b45c8360b80b7a12185b37a6 Mon Sep 17 00:00:00 2001
+From 7d87e41ad0f3356b74d93be8588ef69539edcc91 Mon Sep 17 00:00:00 2001
From: Roland Grunberg <rgrunber(a)redhat.com>
Date: Thu, 7 Jun 2012 16:41:33 -0400
Subject: [PATCH] Implement a custom resolver for Tycho in local mode.
@@ -20,11 +20,11 @@ Change-Id: I0609a1caecad753d811c5a93183547b33737657f
---
.../tycho/p2/target/TargetDefinitionResolver.java | 8 +++-
.../tycho/p2/target/TargetPlatformBuilderImpl.java | 5 +++
- .../core/maven/TychoMavenLifecycleParticipant.java | 13 +++++++
+ .../core/maven/TychoMavenLifecycleParticipant.java | 15 ++++++++
.../tycho/core/osgitools/OsgiBundleProject.java | 38 +++++++++++++++++++-
.../tycho/osgi/runtime/TychoP2RuntimeLocator.java | 17 +++++++++
.../p2/resolver/P2TargetPlatformResolver.java | 10 +++++
- 6 files changed, 88 insertions(+), 3 deletions(-)
+ 6 files changed, 90 insertions(+), 3 deletions(-)
diff --git a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/target/TargetDefinitionResolver.java b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/target/TargetDefinitionResolver.java
index 2d7d3b9..c628e6e 100644
@@ -69,7 +69,7 @@ index 9da87bb..5785029 100644
metadataRepository = metadataRepositoryManager.loadRepository(location, monitor);
metadataRepositories.add(metadataRepository);
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 80810d6..e3c6732 100644
+index 80810d6..24efc87 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
@@ -11,6 +11,7 @@
@@ -80,20 +80,22 @@ index 80810d6..e3c6732 100644
import java.util.List;
import org.apache.maven.AbstractMavenLifecycleParticipant;
-@@ -51,6 +52,18 @@ public class TychoMavenLifecycleParticipant extends AbstractMavenLifecyclePartic
+@@ -51,6 +52,20 @@ public class TychoMavenLifecycleParticipant extends AbstractMavenLifecyclePartic
registerExecutionListener(session);
configureComponents(session);
+ // Create a system p2 repository for local dependency resolution
-+ try {
-+ String[] cmd = new String[] { "/usr/share/java/tycho/copy-platform-all",
-+ System.getProperty("user.dir") + "/.m2/p2/repo" };
-+ Process p = Runtime.getRuntime().exec(cmd);
-+ p.waitFor();
-+ } catch (IOException e) {
-+ // Continue
-+ } catch (InterruptedException e) {
-+ // Continue
++ if (System.getProperty("maven.local.mode") != null) {
++ try {
++ String[] cmd = new String[] { "/usr/share/java/tycho/copy-platform-all",
++ System.getProperty("user.dir") + "/.m2/p2/repo" };
++ Process p = Runtime.getRuntime().exec(cmd);
++ p.waitFor();
++ } catch (IOException e) {
++ // Continue
++ } catch (InterruptedException e) {
++ // Continue
++ }
+ }
+
List<MavenProject> projects = session.getProjects();
11 years, 10 months
[tycho] Allow for building SWT fragments (BZ #380934).
by Roland Grunberg
commit ed7b67b58d12b5d59d98f22e3f8dd550807706f9
Author: Roland Grunberg <rgrunber(a)redhat.com>
Date: Mon Jun 11 11:43:44 2012 -0400
Allow for building SWT fragments (BZ #380934).
tycho-fix-swt.patch | 129 +++++++++++++++++++++++++++++++++++++++++++++++++++
tycho.spec | 7 ++-
2 files changed, 134 insertions(+), 2 deletions(-)
---
diff --git a/tycho-fix-swt.patch b/tycho-fix-swt.patch
new file mode 100644
index 0000000..f28a984
--- /dev/null
+++ b/tycho-fix-swt.patch
@@ -0,0 +1,129 @@
+From 198ef97930794f59230035f350f286255ea63c61 Mon Sep 17 00:00:00 2001
+From: Igor Fedorenko <igor(a)ifedorenko.com>
+Date: Wed, 30 May 2012 10:01:36 -0400
+Subject: [PATCH] 380934 do not 'fixSWT' for swt fragment projects
+
+Change-Id: I2990ff68acfe14e104480ba85ce30c2138d74e45
+Signed-off-by: Igor Fedorenko <igor(a)ifedorenko.com>
+---
+ .../swt/org.eclipse.swt/META-INF/MANIFEST.MF | 4 ++
+ .../resolver/swt/swtFragment/META-INF/MANIFEST.MF | 6 ++
+ .../tycho/p2/impl/resolver/P2ResolverTest.java | 54 ++++++++++++++++++++
+ .../impl/resolver/ProjectorResolutionStrategy.java | 12 ++++
+ 4 files changed, 76 insertions(+), 0 deletions(-)
+ create mode 100644 tycho-bundles/org.eclipse.tycho.p2.resolver.impl.test/resources/resolver/swt/org.eclipse.swt/META-INF/MANIFEST.MF
+ create mode 100644 tycho-bundles/org.eclipse.tycho.p2.resolver.impl.test/resources/resolver/swt/swtFragment/META-INF/MANIFEST.MF
+
+diff --git a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl.test/resources/resolver/swt/org.eclipse.swt/META-INF/MANIFEST.MF b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl.test/resources/resolver/swt/org.eclipse.swt/META-INF/MANIFEST.MF
+new file mode 100644
+index 0000000..b2eda0d
+--- /dev/null
++++ b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl.test/resources/resolver/swt/org.eclipse.swt/META-INF/MANIFEST.MF
+@@ -0,0 +1,4 @@
++Manifest-Version: 1.0
++Bundle-ManifestVersion: 2
++Bundle-SymbolicName: org.eclipse.swt
++Bundle-Version: 3.0.0.qualifier
+diff --git a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl.test/resources/resolver/swt/swtFragment/META-INF/MANIFEST.MF b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl.test/resources/resolver/swt/swtFragment/META-INF/MANIFEST.MF
+new file mode 100644
+index 0000000..380c312
+--- /dev/null
++++ b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl.test/resources/resolver/swt/swtFragment/META-INF/MANIFEST.MF
+@@ -0,0 +1,6 @@
++Manifest-Version: 1.0
++Bundle-ManifestVersion: 2
++Bundle-Name: org.eclipse.tycho.p2.impl.resolver.test.swtFragment
++Bundle-SymbolicName: org.eclipse.tycho.p2.impl.resolver.swtFragment
++Bundle-Version: 1.0.0.qualifier
++Fragment-Host: org.eclipse.swt; bundle-version="[3.0.0,4.0.0)"
+diff --git a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl.test/src/test/java/org/eclipse/tycho/p2/impl/resolver/P2ResolverTest.java b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl.test/src/test/java/org/eclipse/tycho/p2/impl/resolver/P2ResolverTest.java
+index 7d5ea2d..cc7baf4 100644
+--- a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl.test/src/test/java/org/eclipse/tycho/p2/impl/resolver/P2ResolverTest.java
++++ b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl.test/src/test/java/org/eclipse/tycho/p2/impl/resolver/P2ResolverTest.java
+@@ -222,6 +222,60 @@ public class P2ResolverTest extends P2ResolverTestBase {
+ assertContainsUnit("org.eclipse.swt.gtk.linux.x86_64", result.getNonReactorUnits());
+ }
+
++ @Test
++ public void swt() throws Exception {
++ File swt = resourceFile("resolver/swt/org.eclipse.swt");
++ addReactorProject(swt, TYPE_ECLIPSE_PLUGIN, "org.eclipse.swt");
++ File swtFragment = resourceFile("resolver/swt/swtFragment");
++ addReactorProject(swtFragment, TYPE_ECLIPSE_PLUGIN, "org.eclipse.tycho.p2.impl.resolver.test.swtFragment");
++
++ List<P2ResolutionResult> results = impl.resolveProject(context.buildTargetPlatform(), swt);
++
++ Assert.assertEquals(1, results.size());
++ P2ResolutionResult result = results.get(0);
++
++ Assert.assertEquals(1, result.getArtifacts().size());
++ assertContainLocation(result, swt);
++ }
++
++ @Test
++ public void swtFragment() throws Exception {
++ File swt = resourceFile("resolver/swt/org.eclipse.swt");
++ addReactorProject(swt, TYPE_ECLIPSE_PLUGIN, "org.eclipse.swt");
++ File swtFragment = resourceFile("resolver/swt/swtFragment");
++ addReactorProject(swtFragment, TYPE_ECLIPSE_PLUGIN, "org.eclipse.tycho.p2.impl.resolver.test.swtFragment");
++
++ List<P2ResolutionResult> results = impl.resolveProject(context.buildTargetPlatform(), swtFragment);
++
++ Assert.assertEquals(1, results.size());
++ P2ResolutionResult result = results.get(0);
++
++ Assert.assertEquals(2, result.getArtifacts().size());
++ Assert.assertEquals(0, result.getNonReactorUnits().size());
++
++ assertContainLocation(result, swtFragment);
++ assertContainLocation(result, swt);
++ }
++
++ @Test
++ public void swtFragmentWithRemoteSWT() throws Exception {
++ context.addP2Repository(resourceFile("repositories/e361").toURI());
++
++ File swtFragment = resourceFile("resolver/swt/swtFragment");
++ addReactorProject(swtFragment, TYPE_ECLIPSE_PLUGIN, "org.eclipse.tycho.p2.impl.resolver.test.swtFragment");
++
++ List<P2ResolutionResult> results = impl.resolveProject(context.buildTargetPlatform(), swtFragment);
++
++ Assert.assertEquals(1, results.size());
++ P2ResolutionResult result = results.get(0);
++
++ Assert.assertEquals(2, result.getArtifacts().size());
++ Assert.assertEquals(1, result.getNonReactorUnits().size());
++
++ assertContainLocation(result, swtFragment);
++ assertContainsUnit("org.eclipse.swt", result.getNonReactorUnits());
++ }
++
+ private static void assertContainsUnit(String unitID, Set<?> units) {
+ Assert.assertFalse("Unit " + unitID + " not found", getInstallableUnits(unitID, units).isEmpty());
+ }
+diff --git a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java
+index 3d0f3db..c5bf797 100644
+--- a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java
++++ b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/impl/resolver/ProjectorResolutionStrategy.java
+@@ -110,6 +110,18 @@ public class ProjectorResolutionStrategy extends AbstractSlicerResolutionStrateg
+ return;
+ }
+
++ // 380934 one of rootIUs can be SWT or an SWT fragment
++ for (IInstallableUnit iu : rootIUs) {
++ if ("org.eclipse.swt".equals(iu.getId())) {
++ return;
++ }
++ for (IProvidedCapability provided : iu.getProvidedCapabilities()) {
++ if ("osgi.fragment".equals(provided.getNamespace()) && "org.eclipse.swt".equals(provided.getName())) {
++ return;
++ }
++ }
++ }
++
+ IInstallableUnit swtFragment = null;
+
+ all_ius: for (Iterator<IInstallableUnit> iter = availableIUs.query(QueryUtil.ALL_UNITS, monitor).iterator(); iter
+--
+1.7.7.6
+
diff --git a/tycho.spec b/tycho.spec
index a1aacb3..1b613cc 100644
--- a/tycho.spec
+++ b/tycho.spec
@@ -31,11 +31,12 @@ Patch1: %{name}-fix-surefire.patch
# Upstream builds against maven-surefire 2.10 but in rawhide we have 2.12
Patch2: %{name}-maven-surefire.patch
Patch3: %{name}-use-custom-resolver.patch
+Patch4: %{name}-fix-swt.patch
# Set some temporary build version so that the bootstrapped build has
# a different version from the nonbootstrapped. Otherwise there will
# be cyclic dependencies.
%if %{bootstrap}
-Patch4: %{name}-bootstrap.patch
+Patch5: %{name}-bootstrap.patch
%endif
BuildArch: noarch
@@ -114,8 +115,9 @@ This package contains the API documentation for %{name}.
%patch1 -p1
%patch2 -p2
%patch3 -p1
-%if %{bootstrap}
%patch4 -p1
+%if %{bootstrap}
+%patch5 -p1
%endif
find tycho-core -iname '*html' -delete
@@ -200,6 +202,7 @@ install -pm 755 %{SOURCE3} %{buildroot}%{_javadir}/%{name}/copy-platform-all
* Tue May 29 2012 Roland Grunberg <rgrunber(a)redhat.com> 0.14.1-4.1
- Fix Tycho Surfire to run Eclipse test bundles.
- Implement automatic creation of a system p2 repository.
+- Allow building SWT fragments (BZ #380934).
* Wed May 23 2012 Roland Grunberg <rgrunber(a)redhat.com> 0.14.1-4
- Non-bootstrap build.
11 years, 10 months
[tycho] Implement automatic creation of a system p2 repository.
by Roland Grunberg
commit 8a282a17294ab25a04cf0c4113a3a9fdbd52ee67
Author: Roland Grunberg <rgrunber(a)redhat.com>
Date: Mon Jun 11 13:14:37 2012 -0400
Implement automatic creation of a system p2 repository.
Automatically create a local p2 repository of all bundles on the system
so that they may be used for local dependency resolution. This is done
using a modified version of Eclipse's copy-platform script.
copy-platform-all | 95 ++++++++++++++++++++++
tycho-use-custom-resolver.patch | 167 +++++++++++++++++++++++++++++----------
tycho.spec | 3 +
3 files changed, 223 insertions(+), 42 deletions(-)
---
diff --git a/copy-platform-all b/copy-platform-all
new file mode 100755
index 0000000..0adfd14
--- /dev/null
+++ b/copy-platform-all
@@ -0,0 +1,95 @@
+#! /bin/sh
+
+where=$1'-sdk'
+repo=$1; shift
+eclipse=$(rpm --eval '%{_eclipse_base}'); shift
+
+datadir=/usr/share/eclipse
+
+mkdir -p $where/plugins $where/features
+pushd $where
+
+ (cd $eclipse;
+ ls -d plugins/* features/* 2>/dev/null) |
+ while read f; do
+ [ ! -e $f ] && ln -s $eclipse/$f $f
+ done
+ (cd $eclipse/dropins; ls -d * 2>/dev/null) |
+ while read f; do
+ if [ -e $eclipse/dropins/$f/eclipse ]; then
+ (cd $eclipse/dropins/$f/eclipse;
+ ls -d plugins/* features/* 2>/dev/null) |
+ while read g; do
+ [ ! -e $g ] && \
+ ln -s $eclipse/dropins/$f/eclipse/$g $g
+ done
+ else
+ (cd $eclipse/dropins/$f;
+ ls -d plugins/* features/* 2>/dev/null) |
+ while read g; do
+ [ ! -e $g ] && \
+ ln -s $eclipse/dropins/$f/$g $g
+ done
+ fi
+ done
+ (cd $datadir/dropins; ls -d * 2>/dev/null) |
+ while read f; do
+ if [ -e $datadir/dropins/$f/eclipse ]; then
+ (cd $datadir/dropins/$f/eclipse;
+ ls -d plugins/* features/* 2>/dev/null) |
+ while read g; do
+ [ ! -e $g ] && \
+ ln -s $datadir/dropins/$f/eclipse/$g $g
+ done
+ else
+ (cd $datadir/dropins/$f;
+ ls -d plugins/* features/* 2>/dev/null) |
+ while read g; do
+ [ ! -e $g ] && \
+ ln -s $datadir/dropins/$g $g
+ done
+ fi
+ done
+
+for p in $(ls -d $eclipse/dropins/jdt/plugins/*); do
+ plugin=$(basename $p)
+ [ ! -e plugins/$plugin ] && ln -s $eclipse/dropins/jdt/plugins/$plugin plugins/$plugin
+done
+for f in $(ls -d $eclipse/dropins/jdt/features/*); do
+ feature=$(basename $f)
+ [ ! -e features/$feature ] && ln -s $eclipse/dropins/jdt/features/$feature features/$feature
+done
+for p in $(ls -d $eclipse/dropins/sdk/plugins/*); do
+ plugin=$(basename $p)
+ [ ! -e plugins/$plugin ] && ln -s $eclipse/dropins/sdk/plugins/$plugin plugins/$plugin
+done
+for f in $(ls -d $eclipse/dropins/sdk/features/*); do
+ feature=$(basename $f)
+ [ ! -e features/$feature ] && ln -s $eclipse/dropins/sdk/features/$feature features/$feature
+done
+for p in $(ls -d $eclipse/plugins/*); do
+ plugin=$(basename $p)
+ [ ! -e plugins/$plugin ] && ln -s $eclipse/plugins/$plugin plugins/$plugin
+done
+for f in $(ls -d $eclipse/features/*); do
+ feature=$(basename $f)
+ [ ! -e features/$feature ] && ln -s $eclipse/features/$feature features/$feature
+done
+
+for p in $(find /usr/share/java -name "*.jar"); do
+ unzip -p $p 'META-INF/MANIFEST.MF' | grep -q 'Bundle-ManifestVersion'
+ if [ $? = 0 ]; then
+ plugin=$(basename $p)
+ [ ! -e plugins/$plugin ] && ln -s $p plugins/$plugin
+ fi
+done
+
+popd
+
+eclipse -nosplash -application org.eclipse.equinox.p2.publisher.FeaturesAndBundlesPublisher \
+-metadataRepository file:$repo \
+-artifactRepository file:$repo \
+-source $where \
+-compress -append -publishArtifacts
+
+rm -rf $where
diff --git a/tycho-use-custom-resolver.patch b/tycho-use-custom-resolver.patch
index 5c6f8b3..1e3992d 100644
--- a/tycho-use-custom-resolver.patch
+++ b/tycho-use-custom-resolver.patch
@@ -1,5 +1,33 @@
+From 590e6eb40fb807c5b45c8360b80b7a12185b37a6 Mon Sep 17 00:00:00 2001
+From: Roland Grunberg <rgrunber(a)redhat.com>
+Date: Thu, 7 Jun 2012 16:41:33 -0400
+Subject: [PATCH] Implement a custom resolver for Tycho in local mode.
+
+When running in local mode, dependencies should be resolved by looking
+on the local system. Remote repositories should be ignored unless
+offline mode is disabled.
+
+Automatically create a local p2 repository of all bundles on the system
+so that they may be used for local dependency resolution. This is done
+using a modified version of Eclipse's copy-platform script.
+
+Since Fedora 17, we need an Execution Environment of at least JavaSE-1.6
+for Eclipse bundles. Eclipse Juno platform bundles depend on
+javax.annotation. In Fedora this is provided by geronimo-annotation, but
+has a dependency on javax.lang.model (since 1.6).
+
+Change-Id: I0609a1caecad753d811c5a93183547b33737657f
+---
+ .../tycho/p2/target/TargetDefinitionResolver.java | 8 +++-
+ .../tycho/p2/target/TargetPlatformBuilderImpl.java | 5 +++
+ .../core/maven/TychoMavenLifecycleParticipant.java | 13 +++++++
+ .../tycho/core/osgitools/OsgiBundleProject.java | 38 +++++++++++++++++++-
+ .../tycho/osgi/runtime/TychoP2RuntimeLocator.java | 17 +++++++++
+ .../p2/resolver/P2TargetPlatformResolver.java | 10 +++++
+ 6 files changed, 88 insertions(+), 3 deletions(-)
+
diff --git a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/target/TargetDefinitionResolver.java b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/target/TargetDefinitionResolver.java
-index 2d7d3b9..3084fff 100644
+index 2d7d3b9..c628e6e 100644
--- a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/target/TargetDefinitionResolver.java
+++ b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/target/TargetDefinitionResolver.java
@@ -24,6 +24,7 @@ import org.eclipse.core.runtime.CoreException;
@@ -25,63 +53,52 @@ index 2d7d3b9..3084fff 100644
IQueryable<IInstallableUnit> locationUnits = new CompoundQueryable<IInstallableUnit>(
diff --git a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/target/TargetPlatformBuilderImpl.java b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/target/TargetPlatformBuilderImpl.java
-index 9da87bb..3d15c5e 100644
+index 9da87bb..5785029 100644
--- a/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/target/TargetPlatformBuilderImpl.java
+++ b/tycho-bundles/org.eclipse.tycho.p2.resolver.impl/src/main/java/org/eclipse/tycho/p2/target/TargetPlatformBuilderImpl.java
@@ -255,6 +255,11 @@ public class TargetPlatformBuilderImpl implements TargetPlatformBuilder {
return;
}
-+ // We cannot resolve a non-file URI in local mode
-+ if (System.getProperty("maven.local.mode") != null && !URIUtil.isFileURI(location)) {
++ // We cannot resolve a non-file URI in local mode while offline
++ if (System.getProperty("maven.local.mode") != null && offline && !URIUtil.isFileURI(location)) {
+ return;
+ }
+
try {
metadataRepository = metadataRepositoryManager.loadRepository(location, monitor);
metadataRepositories.add(metadataRepository);
-diff --git a/tycho-core/src/main/java/org/eclipse/tycho/osgi/runtime/TychoP2RuntimeLocator.java b/tycho-core/src/main/java/org/eclipse/tycho/osgi/runtime/TychoP2RuntimeLocator.java
-index 15b3fff..c8f14df 100644
---- a/tycho-core/src/main/java/org/eclipse/tycho/osgi/runtime/TychoP2RuntimeLocator.java
-+++ b/tycho-core/src/main/java/org/eclipse/tycho/osgi/runtime/TychoP2RuntimeLocator.java
-@@ -23,6 +23,7 @@ import org.apache.maven.artifact.repository.ArtifactRepository;
- import org.apache.maven.artifact.resolver.ArtifactResolutionException;
- import org.apache.maven.artifact.resolver.ArtifactResolutionRequest;
- import org.apache.maven.artifact.resolver.ArtifactResolutionResult;
-+import org.apache.maven.artifact.resolver.JavadirWorkspaceReader;
- import org.apache.maven.artifact.resolver.ResolutionErrorHandler;
- import org.apache.maven.execution.MavenSession;
- import org.apache.maven.model.Dependency;
-@@ -38,6 +39,7 @@ import org.codehaus.plexus.util.FileUtils;
- import org.eclipse.sisu.equinox.embedder.EquinoxRuntimeLocator;
- import org.eclipse.tycho.locking.facade.FileLockService;
- import org.eclipse.tycho.locking.facade.FileLocker;
-+import org.sonatype.aether.util.artifact.DefaultArtifact;
+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 80810d6..e3c6732 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
+@@ -11,6 +11,7 @@
+ package org.eclipse.tycho.core.maven;
- @Component(role = EquinoxRuntimeLocator.class)
- public class TychoP2RuntimeLocator implements EquinoxRuntimeLocator {
-@@ -158,6 +160,21 @@ public class TychoP2RuntimeLocator implements EquinoxRuntimeLocator {
- }
+ import java.io.File;
++import java.io.IOException;
+ import java.util.List;
- private File resolveArtifact(MavenSession session, Artifact artifact) throws MavenExecutionException {
-+
-+ // If we are in local mode, find the artifact on the system
-+ if (System.getProperty("maven.local.mode") != null) {
-+ JavadirWorkspaceReader wReader = new JavadirWorkspaceReader();
-+ DefaultArtifact newArtifact = new DefaultArtifact(artifact.getGroupId()
-+ + ":" + artifact.getArtifactId()
-+ + ":" + artifact.getType()
-+ + ":" + artifact.getVersion());
-+ File file = wReader.findArtifact(newArtifact);
-+ if (file != null) {
-+ artifact.setFile(file);
-+ return file;
-+ }
+ import org.apache.maven.AbstractMavenLifecycleParticipant;
+@@ -51,6 +52,18 @@ public class TychoMavenLifecycleParticipant extends AbstractMavenLifecyclePartic
+ registerExecutionListener(session);
+ configureComponents(session);
+
++ // Create a system p2 repository for local dependency resolution
++ try {
++ String[] cmd = new String[] { "/usr/share/java/tycho/copy-platform-all",
++ System.getProperty("user.dir") + "/.m2/p2/repo" };
++ Process p = Runtime.getRuntime().exec(cmd);
++ p.waitFor();
++ } catch (IOException e) {
++ // Continue
++ } catch (InterruptedException e) {
++ // Continue
+ }
+
- List<ArtifactRepository> repositories = new ArrayList<ArtifactRepository>();
- for (MavenProject project : session.getProjects()) {
- repositories.addAll(project.getPluginArtifactRepositories());
+ List<MavenProject> projects = session.getProjects();
+ for (MavenProject project : projects) {
+ resolver.setupProject(session, project, DefaultReactorProject.adapt(project));
diff --git a/tycho-core/src/main/java/org/eclipse/tycho/core/osgitools/OsgiBundleProject.java b/tycho-core/src/main/java/org/eclipse/tycho/core/osgitools/OsgiBundleProject.java
index 8d18453..051913e 100644
--- a/tycho-core/src/main/java/org/eclipse/tycho/core/osgitools/OsgiBundleProject.java
@@ -138,3 +155,69 @@ index 8d18453..051913e 100644
} catch (UnknownEnvironmentException e) {
throw new RuntimeException("Unknown execution environment specified in build.properties of project "
+ project, e);
+diff --git a/tycho-core/src/main/java/org/eclipse/tycho/osgi/runtime/TychoP2RuntimeLocator.java b/tycho-core/src/main/java/org/eclipse/tycho/osgi/runtime/TychoP2RuntimeLocator.java
+index 15b3fff..c8f14df 100644
+--- a/tycho-core/src/main/java/org/eclipse/tycho/osgi/runtime/TychoP2RuntimeLocator.java
++++ b/tycho-core/src/main/java/org/eclipse/tycho/osgi/runtime/TychoP2RuntimeLocator.java
+@@ -23,6 +23,7 @@ import org.apache.maven.artifact.repository.ArtifactRepository;
+ import org.apache.maven.artifact.resolver.ArtifactResolutionException;
+ import org.apache.maven.artifact.resolver.ArtifactResolutionRequest;
+ import org.apache.maven.artifact.resolver.ArtifactResolutionResult;
++import org.apache.maven.artifact.resolver.JavadirWorkspaceReader;
+ import org.apache.maven.artifact.resolver.ResolutionErrorHandler;
+ import org.apache.maven.execution.MavenSession;
+ import org.apache.maven.model.Dependency;
+@@ -38,6 +39,7 @@ import org.codehaus.plexus.util.FileUtils;
+ import org.eclipse.sisu.equinox.embedder.EquinoxRuntimeLocator;
+ import org.eclipse.tycho.locking.facade.FileLockService;
+ import org.eclipse.tycho.locking.facade.FileLocker;
++import org.sonatype.aether.util.artifact.DefaultArtifact;
+
+ @Component(role = EquinoxRuntimeLocator.class)
+ public class TychoP2RuntimeLocator implements EquinoxRuntimeLocator {
+@@ -158,6 +160,21 @@ public class TychoP2RuntimeLocator implements EquinoxRuntimeLocator {
+ }
+
+ private File resolveArtifact(MavenSession session, Artifact artifact) throws MavenExecutionException {
++
++ // If we are in local mode, find the artifact on the system
++ if (System.getProperty("maven.local.mode") != null) {
++ JavadirWorkspaceReader wReader = new JavadirWorkspaceReader();
++ DefaultArtifact newArtifact = new DefaultArtifact(artifact.getGroupId()
++ + ":" + artifact.getArtifactId()
++ + ":" + artifact.getType()
++ + ":" + artifact.getVersion());
++ File file = wReader.findArtifact(newArtifact);
++ if (file != null) {
++ artifact.setFile(file);
++ return file;
++ }
++ }
++
+ List<ArtifactRepository> repositories = new ArrayList<ArtifactRepository>();
+ for (MavenProject project : session.getProjects()) {
+ repositories.addAll(project.getPluginArtifactRepositories());
+diff --git a/tycho-p2/tycho-p2-facade/src/main/java/org/eclipse/tycho/p2/resolver/P2TargetPlatformResolver.java b/tycho-p2/tycho-p2-facade/src/main/java/org/eclipse/tycho/p2/resolver/P2TargetPlatformResolver.java
+index d4bcc9a..57ae997 100644
+--- a/tycho-p2/tycho-p2-facade/src/main/java/org/eclipse/tycho/p2/resolver/P2TargetPlatformResolver.java
++++ b/tycho-p2/tycho-p2-facade/src/main/java/org/eclipse/tycho/p2/resolver/P2TargetPlatformResolver.java
+@@ -204,6 +204,16 @@ public class P2TargetPlatformResolver extends AbstractTargetPlatformResolver imp
+ ee != null ? ee.getProfileName() : null, configuration.isDisableP2Mirrors());
+ tpBuilder.setProjectLocation(project.getBasedir());
+
++ // Add Fedora Local P2 Repository when running in local mode
++ if (System.getProperty("maven.local.mode") != null) {
++ String uri = "file:" + System.getProperty("user.dir") + "/.m2/p2/repo";
++ try {
++ tpBuilder.addP2Repository(new URI(uri));
++ } catch (URISyntaxException e) {
++ getLogger().warn("Unable to resolve repository URI : " + uri, e);
++ }
++ }
++
+ addThisReactorProjectToTargetPlatform(session, project, configuration, tpBuilder);
+
+ addOtherReactorProjectsToTargetPlatform(project, reactorProjects, tpBuilder);
+--
+1.7.7.6
+
diff --git a/tycho.spec b/tycho.spec
index df3181c..a1aacb3 100644
--- a/tycho.spec
+++ b/tycho.spec
@@ -24,6 +24,7 @@ Source0: %{name}-0.14.x.tar.bz2
Source1: EmptyMojo.java
# we need to make sure we are using maven 3 deps
Source2: depmap.xml
+Source3: copy-platform-all
Patch0: %{name}-fix-build.patch
Patch1: %{name}-fix-surefire.patch
@@ -178,6 +179,7 @@ install -pm 644 pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP.%{name}-main.pom
install -dm 755 %{buildroot}%{_javadocdir}/%{name}
cp -pr target/site/api*/* %{buildroot}%{_javadocdir}/%{name}
+install -pm 755 %{SOURCE3} %{buildroot}%{_javadir}/%{name}/copy-platform-all
%post
%update_maven_depmap
@@ -197,6 +199,7 @@ cp -pr target/site/api*/* %{buildroot}%{_javadocdir}/%{name}
%changelog
* Tue May 29 2012 Roland Grunberg <rgrunber(a)redhat.com> 0.14.1-4.1
- Fix Tycho Surfire to run Eclipse test bundles.
+- Implement automatic creation of a system p2 repository.
* Wed May 23 2012 Roland Grunberg <rgrunber(a)redhat.com> 0.14.1-4
- Non-bootstrap build.
11 years, 10 months
[tycho] Fix Surfire test plugin.
by Roland Grunberg
commit 416b07468268dfcc31b26add86b05c4171f63c89
Author: Roland Grunberg <rgrunber(a)redhat.com>
Date: Tue May 29 15:04:45 2012 -0400
Fix Surfire test plugin.
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.
tycho-bootstrap.patch | 2 +-
tycho-fix-build.patch | 10 ---
tycho-fix-surefire.patch | 160 ++++++++++++++++++++++++++++++++++++++++++++
tycho-maven-surefire.patch | 30 ++++++--
tycho.spec | 21 ++++--
5 files changed, 196 insertions(+), 27 deletions(-)
---
diff --git a/tycho-bootstrap.patch b/tycho-bootstrap.patch
index 51482cb..0592128 100644
--- a/tycho-bootstrap.patch
+++ b/tycho-bootstrap.patch
@@ -670,8 +670,8 @@ diff -rauN tycho-0.14.x.old/tycho-surefire/org.eclipse.tycho.surefire.osgibooter
--- tycho-0.14.x.old/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/META-INF/MANIFEST.MF 2012-02-24 06:40:15.000000000 -0500
+++ tycho-0.14.x/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/META-INF/MANIFEST.MF 2012-03-30 14:49:39.000000000 -0400
@@ -7,7 +7,7 @@
- jars/surefire-booter-2.10.jar,
jars/surefire-api-2.10.jar,
+ jars/plexus-utils-3.0.jar,
jars/maven-surefire-common-2.10.jar
-Bundle-Version: 0.14.1
+Bundle-Version: 0.14.1.qualifier
diff --git a/tycho-fix-build.patch b/tycho-fix-build.patch
index f78242c..3265ec3 100644
--- a/tycho-fix-build.patch
+++ b/tycho-fix-build.patch
@@ -97,16 +97,6 @@
} catch (BundleException e) {
throw new OsgiManifestParserException(location, e);
}
---- ./tycho-0.14.0.old/tycho-surefire/org.eclipse.tycho.surefire.junit/META-INF/MANIFEST.MF 2012-02-06 10:26:59.000000000 -0500
-+++ ./tycho-0.14.0/tycho-surefire/org.eclipse.tycho.surefire.junit/META-INF/MANIFEST.MF 2012-02-14 12:04:02.275017810 -0500
-@@ -6,6 +6,6 @@
- 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)"
-+Require-Bundle: org.junit;bundle-version="[3.8.0,4.9.0)"
- Bundle-ClassPath: jars/surefire-junit3-2.10.jar
- Bundle-Vendor: %providerName
--- ./tycho-0.14.x.old/tycho-core/src/main/java/org/eclipse/tycho/core/utils/EEVersion.java 2012-02-24 06:40:15.000000000 -0500
+++ ./tycho-0.14.x/tycho-core/src/main/java/org/eclipse/tycho/core/utils/EEVersion.java 2012-05-03 14:09:09.000000000 -0400
@@ -18,7 +18,7 @@
diff --git a/tycho-fix-surefire.patch b/tycho-fix-surefire.patch
new file mode 100644
index 0000000..2419e2d
--- /dev/null
+++ b/tycho-fix-surefire.patch
@@ -0,0 +1,160 @@
+From 5ddb88911071664de0e07f7f247aeeaedecc8cab Mon Sep 17 00:00:00 2001
+From: Roland Grunberg <rgrunber(a)redhat.com>
+Date: Tue, 29 May 2012 14:27:27 -0400
+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.
+---
+ pom.xml | 2 +-
+ .../META-INF/MANIFEST.MF | 5 +++--
+ .../build.properties | 2 +-
+ .../org.eclipse.tycho.surefire.junit/pom.xml | 5 +++++
+ .../META-INF/MANIFEST.MF | 4 +++-
+ .../build.properties | 2 +-
+ .../org.eclipse.tycho.surefire.junit4/pom.xml | 10 ++++++++++
+ .../META-INF/MANIFEST.MF | 3 ++-
+ .../org.eclipse.tycho.surefire.osgibooter/pom.xml | 5 +++++
+ 9 files changed, 31 insertions(+), 7 deletions(-)
+
+diff --git a/pom.xml b/pom.xml
+index e9d8624..ca20999 100644
+--- a/pom.xml
++++ b/pom.xml
+@@ -79,7 +79,7 @@
+ <junitVersion>3.8.2</junitVersion>
+ <plexusVersion>1.5.5</plexusVersion>
+ <plexusInterpolationVersion>1.14</plexusInterpolationVersion>
+- <plexusUtilsVersion>2.0.4</plexusUtilsVersion>
++ <plexusUtilsVersion>3.0</plexusUtilsVersion>
+ <sisuInjectVersion>1.4.2</sisuInjectVersion>
+ <wagonVersion>1.0-beta-6</wagonVersion>
+ <securityDispatcherVersion>1.3</securityDispatcherVersion>
+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 9264109..a27abe4 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.14.1
+ 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.10.jar
++Require-Bundle: org.junit;bundle-version="[3.8.0,4.9.0)"
++Bundle-ClassPath: jars/surefire-junit3-2.10.jar,
++ jars/common-junit3-2.10.jar
+ Bundle-Vendor: %providerName
+diff --git a/tycho-surefire/org.eclipse.tycho.surefire.junit/build.properties b/tycho-surefire/org.eclipse.tycho.surefire.junit/build.properties
+index 499ce76..fe88b19 100644
+--- a/tycho-surefire/org.eclipse.tycho.surefire.junit/build.properties
++++ b/tycho-surefire/org.eclipse.tycho.surefire.junit/build.properties
+@@ -9,5 +9,5 @@
+ # Sonatype Inc. - initial API and implementation
+ ###############################################################################
+ bin.includes = META-INF/,\
+- jars/surefire-junit3-2.10.jar,\
++ jars/,\
+ plugin.properties
+diff --git a/tycho-surefire/org.eclipse.tycho.surefire.junit/pom.xml b/tycho-surefire/org.eclipse.tycho.surefire.junit/pom.xml
+index 2a4afc8..ae35035 100644
+--- a/tycho-surefire/org.eclipse.tycho.surefire.junit/pom.xml
++++ b/tycho-surefire/org.eclipse.tycho.surefire.junit/pom.xml
+@@ -47,6 +47,11 @@
+ <artifactId>surefire-junit3</artifactId>
+ <version>${surefire-version}</version>
+ </artifactItem>
++ <artifactItem>
++ <groupId>org.apache.maven.surefire</groupId>
++ <artifactId>common-junit3</artifactId>
++ <version>${surefire-version}</version>
++ </artifactItem>
+ </artifactItems>
+ </configuration>
+ </execution>
+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 bbb54a8..82e66d1 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,7 +6,9 @@ Bundle-Version: 0.14.1
+ 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.10.jar
++Bundle-ClassPath: jars/surefire-junit4-2.10.jar,
++ jars/common-junit3-2.10.jar,
++ jars/common-junit4-2.10.jar
+ Import-Package: junit.framework;version="4.0.0",
+ org.junit;version="4.0.0",
+ org.junit.runner;version="4.0.0",
+diff --git a/tycho-surefire/org.eclipse.tycho.surefire.junit4/build.properties b/tycho-surefire/org.eclipse.tycho.surefire.junit4/build.properties
+index b787149..fe88b19 100644
+--- a/tycho-surefire/org.eclipse.tycho.surefire.junit4/build.properties
++++ b/tycho-surefire/org.eclipse.tycho.surefire.junit4/build.properties
+@@ -9,5 +9,5 @@
+ # Sonatype Inc. - initial API and implementation
+ ###############################################################################
+ bin.includes = META-INF/,\
+- jars/surefire-junit4-2.10.jar,\
++ jars/,\
+ plugin.properties
+diff --git a/tycho-surefire/org.eclipse.tycho.surefire.junit4/pom.xml b/tycho-surefire/org.eclipse.tycho.surefire.junit4/pom.xml
+index 08ab16a..2ed7c3a 100644
+--- a/tycho-surefire/org.eclipse.tycho.surefire.junit4/pom.xml
++++ b/tycho-surefire/org.eclipse.tycho.surefire.junit4/pom.xml
+@@ -71,6 +71,16 @@
+ <artifactId>surefire-junit4</artifactId>
+ <version>${surefire-version}</version>
+ </artifactItem>
++ <artifactItem>
++ <groupId>org.apache.maven.surefire</groupId>
++ <artifactId>common-junit3</artifactId>
++ <version>${surefire-version}</version>
++ </artifactItem>
++ <artifactItem>
++ <groupId>org.apache.maven.surefire</groupId>
++ <artifactId>common-junit4</artifactId>
++ <version>${surefire-version}</version>
++ </artifactItem>
+ </artifactItems>
+ </configuration>
+ </execution>
+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 fda57c6..ab5de08 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,7 +5,8 @@ Require-Bundle: org.eclipse.osgi;bundle-version="3.2.2",
+ Eclipse-AutoStart: true
+ Bundle-ClassPath: .,
+ jars/surefire-booter-2.10.jar,
+- jars/surefire-api-2.10.jar
++ jars/surefire-api-2.10.jar,
++ jars/plexus-utils-3.0.jar
+ Bundle-Version: 0.14.1
+ Bundle-Name: Tycho Surefire OSGi Booter Eclipse Application (Incubation)
+ Bundle-ManifestVersion: 2
+diff --git a/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/pom.xml b/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/pom.xml
+index cd5b2d7..d1d24da 100644
+--- a/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/pom.xml
++++ b/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/pom.xml
+@@ -52,6 +52,11 @@
+ <artifactId>surefire-booter</artifactId>
+ <version>${surefire-version}</version>
+ </artifactItem>
++ <artifactItem>
++ <groupId>org.codehaus.plexus</groupId>
++ <artifactId>plexus-utils</artifactId>
++ <version>${plexusUtilsVersion}</version>
++ </artifactItem>
+ </artifactItems>
+ </configuration>
+ </execution>
+--
+1.7.7.6
+
diff --git a/tycho-maven-surefire.patch b/tycho-maven-surefire.patch
index bf808cf..e321083 100644
--- a/tycho-maven-surefire.patch
+++ b/tycho-maven-surefire.patch
@@ -11,12 +11,12 @@
throw new MojoFailureException(message);
--- ./tycho-0.14.x.old/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/META-INF/MANIFEST.MF 2012-02-24 06:40:15.000000000 -0500
+++ ./tycho-0.14.x/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/META-INF/MANIFEST.MF 2012-03-09 14:53:53.000000000 -0500
-@@ -5,7 +5,8 @@
- Eclipse-AutoStart: true
+@@ -6,7 +6,8 @@
Bundle-ClassPath: .,
jars/surefire-booter-2.10.jar,
-- jars/surefire-api-2.10.jar
-+ jars/surefire-api-2.10.jar,
+ jars/surefire-api-2.10.jar,
+- jars/plexus-utils-3.0.jar
++ jars/plexus-utils-3.0.jar,
+ jars/maven-surefire-common-2.10.jar
Bundle-Version: 0.14.1
Bundle-Name: Tycho Surefire OSGi Booter Eclipse Application (Incubation)
@@ -70,10 +70,10 @@
RunResult result = surefireStarter.runSuitesInProcess();
--- ./tycho-0.14.x.old/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/pom.xml 2012-02-24 06:40:15.000000000 -0500
+++ ./tycho-0.14.x/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/pom.xml 2012-03-09 14:45:54.987999986 -0500
-@@ -51,6 +51,13 @@
- <groupId>org.apache.maven.surefire</groupId>
- <artifactId>surefire-booter</artifactId>
- <version>${surefire-version}</version>
+@@ -56,6 +56,13 @@
+ <groupId>org.codehaus.plexus</groupId>
+ <artifactId>plexus-utils</artifactId>
+ <version>${plexusUtilsVersion}</version>
+
+ </artifactItem>
+ <artifactItem>
@@ -84,3 +84,17 @@
</artifactItem>
</artifactItems>
</configuration>
+--- ./tycho-0.14.x.old/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/src/main/java/org/eclipse/tycho/surefire/osgibooter/TychoClasspathConfiguration.java 2012-02-24 06:40:15.000000000 -0500
++++ ./tycho-0.14.x/tycho-surefire/org.eclipse.tycho.surefire.osgibooter/src/main/java/org/eclipse/tycho/surefire/osgibooter/TychoClasspathConfiguration.java 2012-05-29 16:45:39.000000000 -0400
+@@ -30,6 +30,11 @@
+ }
+
+ @Override
++ public ClassLoader createInprocSurefireClassLoader(ClassLoader parent) throws SurefireExecutionException {
++ return surefireClassLoader;
++ }
++
++ @Override
+ public ClassLoader createTestClassLoader() throws SurefireExecutionException {
+ return testClassLoader;
+ }
diff --git a/tycho.spec b/tycho.spec
index e7faeb9..df3181c 100644
--- a/tycho.spec
+++ b/tycho.spec
@@ -1,4 +1,4 @@
-%global bootstrap 0
+%global bootstrap 1
%if %{bootstrap}
%global snap -SNAPSHOT
@@ -8,7 +8,7 @@
Name: tycho
Version: 0.14.1
-Release: 4%{?dist}
+Release: 4.1%{?dist}
Summary: Plugins and extensions for building Eclipse plugins and OSGI bundles with Maven
Group: Development/Libraries
@@ -26,14 +26,15 @@ Source1: EmptyMojo.java
Source2: depmap.xml
Patch0: %{name}-fix-build.patch
+Patch1: %{name}-fix-surefire.patch
# Upstream builds against maven-surefire 2.10 but in rawhide we have 2.12
-Patch1: %{name}-maven-surefire.patch
-Patch2: %{name}-use-custom-resolver.patch
+Patch2: %{name}-maven-surefire.patch
+Patch3: %{name}-use-custom-resolver.patch
# Set some temporary build version so that the bootstrapped build has
# a different version from the nonbootstrapped. Otherwise there will
# be cyclic dependencies.
%if %{bootstrap}
-Patch3: %{name}-bootstrap.patch
+Patch4: %{name}-bootstrap.patch
%endif
BuildArch: noarch
@@ -109,10 +110,11 @@ This package contains the API documentation for %{name}.
%setup -q -n %{name}-0.14.x
%patch0 -p2
-%patch1 -p2
-%patch2 -p1
-%if %{bootstrap}
+%patch1 -p1
+%patch2 -p2
%patch3 -p1
+%if %{bootstrap}
+%patch4 -p1
%endif
find tycho-core -iname '*html' -delete
@@ -193,6 +195,9 @@ cp -pr target/site/api*/* %{buildroot}%{_javadocdir}/%{name}
%{_javadocdir}/%{name}
%changelog
+* Tue May 29 2012 Roland Grunberg <rgrunber(a)redhat.com> 0.14.1-4.1
+- Fix Tycho Surfire to run Eclipse test bundles.
+
* Wed May 23 2012 Roland Grunberg <rgrunber(a)redhat.com> 0.14.1-4
- Non-bootstrap build.
11 years, 10 months
Maven packages in EPEL 6?
by Michel Alexandre Salim
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi,
First, a short self-introduction -- I'm a long-time Fedora
contributor, who's currently working on a feature to [improve support
for Clojure in Fedora](https://fedoraproject.org/wiki/Features/Clojure)
Part of the rationale is that Kushal Das (cc:ed) and myself would like
to eventually write some Fedora infrastructure in Clojure -- which
would, of course, necessitate having the whole stack in RHEL/EPEL 6 as
well.
I noticed [a post by
Lubomir](http://article.gmane.org/gmane.linux.redhat.fedora.java/3458/) back
in 2010 asking for Maven packages to be made available in EPEL, but as
we just discovered today, Maven is still not available. There seems to
be no reply, at least on the mailing list, to that request..
Is there any technical difficulty involved in making these packages
available on EPEL? If it's a lack of interest, Kushal and myself
hereby volunteer to be the ones in charge of doing the EPEL
maintenance work.
Thanks,
- --
Michel Alexandre Salim
Fedora Project Contributor: http://fedoraproject.org/
Email: salimma(a)fedoraproject.org | GPG key ID: A36A937A
Jabber: hircus(a)jabber.ccc.de | IRC: hircus(a)irc.freenode.net
() ascii ribbon campaign - against html e-mail
/\ www.asciiribbon.org - against proprietary attachments
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iQEcBAEBAgAGBQJP0gRRAAoJEEr1VKujapN6EZ4IAIB2CNDozgmJdU23oreschws
HcbyscUsLLJ/IZ3Bo4ezf2pjNCNnCrxQWil5RlOU5/W0OnduMzmiGnxmlby4OFUh
szXpdxZ23UJChN8Twu3Bi/CA3qkqd/MZUIaGphGGI0BhT69pnh7iW6fEs3T93Cpv
SLyD8PL7plE/xQiX20mmCzabHdyliOis8E64AAJ1zz5FIzyNTPYPboP6yM23qPXZ
eFL3x5lLht1RA8M5wXtff6NLEZ9aEXpPJC5J0Qw5lWksd5VlYpDaHguz0SqIQnN1
p7vX7SR/kPZPpxBrQJg82bAZBpUEv/tMdbGfWaDly9koRsMeDcaRKNooaCqVVkA=
=mwyf
-----END PGP SIGNATURE-----
11 years, 10 months
[maven-ant-tasks] Update to 2.1.3 Add missing requires (Bug 830786)
by Orion Poplawski
commit f6fbcf65eaaf8688b80d3e8461a3b5c330efbb98
Author: Orion Poplawski <orion(a)cora.nwra.com>
Date: Mon Jun 11 09:40:04 2012 -0600
Update to 2.1.3
Add missing requires (Bug 830786)
.gitignore | 1 +
maven-ant-tasks.spec | 12 ++++++++++--
sources | 2 +-
3 files changed, 12 insertions(+), 3 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index d6eea3f..68ee33b 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,2 @@
/maven-ant-tasks-2.1.1-src.zip
+/maven-ant-tasks-2.1.3-src.zip
diff --git a/maven-ant-tasks.spec b/maven-ant-tasks.spec
index c5062ab..609345a 100644
--- a/maven-ant-tasks.spec
+++ b/maven-ant-tasks.spec
@@ -1,6 +1,6 @@
Name: maven-ant-tasks
-Version: 2.1.1
-Release: 9%{?dist}
+Version: 2.1.3
+Release: 1%{?dist}
Summary: Allow Maven artifact handling features to be used from within an Ant build
Group: Development/Libraries
@@ -17,6 +17,7 @@ BuildArch: noarch
BuildRequires: jpackage-utils
BuildRequires: java-devel
BuildRequires: ant >= 1.8.0
+# maven-ant-tasks explicitly needs maven2
BuildRequires: maven2
BuildRequires: maven-antrun-plugin
BuildRequires: maven-compiler-plugin
@@ -36,6 +37,9 @@ Requires(post): jpackage-utils
Requires(postun): jpackage-utils
Requires: java
+Requires: ant >= 1.8.0
+Requires: maven2
+Requires: maven-error-diagnostics
%description
Maven Ant Tasks allow several of Maven's artifact handling features to be
@@ -123,6 +127,10 @@ rm -rf $(readlink -f %{_javadocdir}/%{name}) %{_javadocdir}/%{name} || :
%changelog
+* Mon Jun 11 2012 Orion Poplawski <orion(a)cora.nwra.com> - 2.1.3-1
+- Update to 2.1.3
+- Add missing requires (Bug 830786)
+
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng(a)lists.fedoraproject.org> - 2.1.1-9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
diff --git a/sources b/sources
index 73d400c..0585cfd 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-c37d7f6105f27fd87818045f5a0ae33a maven-ant-tasks-2.1.1-src.zip
+ae62c0c7f811f3f7fc60ad91a8b0b822 maven-ant-tasks-2.1.3-src.zip
11 years, 10 months
[Bug 819553] New: maven-project-info-reports-plugin: Please migrate from tomcat6 to tomcat7
by Red Hat Bugzilla
Please do not reply directly to this email. All additional
comments should be made in the comments box of this bug.
Summary: maven-project-info-reports-plugin: Please migrate from tomcat6 to tomcat7
https://bugzilla.redhat.com/show_bug.cgi?id=819553
Summary: maven-project-info-reports-plugin: Please migrate from
tomcat6 to tomcat7
Product: Fedora
Version: rawhide
Platform: All
OS/Version: Linux
Status: NEW
Severity: medium
Priority: medium
Component: maven-project-info-reports-plugin
AssignedTo: huwang(a)redhat.com
ReportedBy: mizdebsk(a)redhat.com
QAContact: extras-qa(a)fedoraproject.org
CC: huwang(a)redhat.com,
java-sig-commits(a)lists.fedoraproject.org
Classification: Fedora
Story Points: ---
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
We want to transition from tomcat6 to tomcat7 in Fedora. By depending on
tomcat6 maven-project-info-reports-plugin it is successfully blocking the
mentioned transition.
The following is the list of maven-project-info-reports-plugin dependencies
affecting the transition (the list is not guarranteed to be complete):
Requires: servlet25
BuildRequires: servlet25
Pleasee update maven-project-info-reports-plugin to use tomcat7 instead of
tomcat6. Thank you.
--
Configure bugmail: https://bugzilla.redhat.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
11 years, 10 months