Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTobias Oberlies2011-12-17 09:30:33 -0500
committerLakshmi Shanmugam2014-11-19 12:13:56 -0500
commit1fb1522a48d55b59d07f0c37bf5e56bead8298b5 (patch)
tree442415e48184a1e063c32a891bf7220ac535c178
parentddf37d819ff05e07a09111f1aee82664955e5aa8 (diff)
downloadeclipse.platform.swt-1fb1522a48d55b59d07f0c37bf5e56bead8298b5.tar.gz
eclipse.platform.swt-1fb1522a48d55b59d07f0c37bf5e56bead8298b5.tar.xz
eclipse.platform.swt-1fb1522a48d55b59d07f0c37bf5e56bead8298b5.zip
361901 - p2 metadata of org.eclipse.swt is incomplete
Ensure installation of fragments of org.eclipse.swt - Make sure that SWT can be installed with p2: whenever the bundle org.eclipse.swt is installed, the appropriate native fragment shall be installed as well. This is achieved by adding install-time dependencies, filtered by the running platform, from org.eclipse.swt to all its fragments. - The install-time dependencies are disabled at build time because otherwise there would be a circular dependency between the host and its fragments. This is achieved through the additional condition "(!(org.eclipse.swt.buildtime=true))" in the filters which is made evaluate to false by setting org.eclipse.swt.buildtime=true in the build. - Modified buildSWT.xml to generate the time-stamp qualifiers and write the qualifiers in the pom files in source and binaries repos. Bug: 361901 Change-Id: I37b1f6c0ea5231850319e1fc4098e412e327d7e2 Signed-off-by: Tobias Oberlies <tobias.oberlies@sap.com> Signed-off-by: Lakshmi Shanmugam <lshanmug@in.ibm.com>
-rw-r--r--bundles/org.eclipse.swt/META-INF/p2.inf78
-rw-r--r--bundles/org.eclipse.swt/buildSWT.xml17
-rw-r--r--bundles/org.eclipse.swt/pom.xml13
-rw-r--r--pom.xml17
4 files changed, 123 insertions, 2 deletions
diff --git a/bundles/org.eclipse.swt/META-INF/p2.inf b/bundles/org.eclipse.swt/META-INF/p2.inf
index 5730e8a1f0..454607c1f3 100644
--- a/bundles/org.eclipse.swt/META-INF/p2.inf
+++ b/bundles/org.eclipse.swt/META-INF/p2.inf
@@ -8,4 +8,80 @@ requires.2.namespace=java.package
requires.2.name=org.eclipse.swt.accessibility2
requires.2.optional=true
requires.2.greedy=false
-requires.2.range=0.0.0 \ No newline at end of file
+requires.2.range=0.0.0
+
+# ensure that the applicable implementation fragment gets installed (bug 361901)
+requires.3.namespace = org.eclipse.equinox.p2.iu
+requires.3.name = org.eclipse.swt.win32.win32.x86
+requires.3.range = [$version$,$version$]
+requires.3.filter = (&(osgi.os=win32)(osgi.ws=win32)(osgi.arch=x86)(!(org.eclipse.swt.buildtime=true)))
+
+requires.4.namespace = org.eclipse.equinox.p2.iu
+requires.4.name = org.eclipse.swt.win32.win32.x86_64
+requires.4.range = [$version$,$version$]
+requires.4.filter = (&(osgi.os=win32)(osgi.ws=win32)(osgi.arch=x86_64)(!(org.eclipse.swt.buildtime=true)))
+
+requires.5.namespace = org.eclipse.equinox.p2.iu
+requires.5.name = org.eclipse.swt.gtk.linux.x86
+requires.5.range = [$version$,$version$]
+requires.5.filter = (&(osgi.os=linux)(osgi.ws=gtk)(osgi.arch=x86)(!(org.eclipse.swt.buildtime=true)))
+
+requires.6.namespace = org.eclipse.equinox.p2.iu
+requires.6.name = org.eclipse.swt.gtk.linux.s390x
+requires.6.range = [$version$,$version$]
+requires.6.filter = (&(osgi.os=linux)(osgi.ws=gtk)(osgi.arch=s390x)(!(org.eclipse.swt.buildtime=true)))
+
+requires.7.namespace = org.eclipse.equinox.p2.iu
+requires.7.name = org.eclipse.swt.gtk.linux.s390
+requires.7.range = [$version$,$version$]
+requires.7.filter = (&(osgi.os=linux)(osgi.ws=gtk)(osgi.arch=s390)(!(org.eclipse.swt.buildtime=true)))
+
+requires.8.namespace = org.eclipse.equinox.p2.iu
+requires.8.name = org.eclipse.swt.gtk.solaris.sparc
+requires.8.range = [$version$,$version$]
+requires.8.filter = (&(osgi.os=solaris)(osgi.ws=gtk)(osgi.arch=sparc)(!(org.eclipse.swt.buildtime=true)))
+
+requires.9.namespace = org.eclipse.equinox.p2.iu
+requires.9.name = org.eclipse.swt.gtk.solaris.x86
+requires.9.range = [$version$,$version$]
+requires.9.filter = (&(osgi.os=solaris)(osgi.ws=gtk)(osgi.arch=x86)(!(org.eclipse.swt.buildtime=true)))
+
+requires.10.namespace = org.eclipse.equinox.p2.iu
+requires.10.name = org.eclipse.swt.gtk.linux.ppc
+requires.10.range = [$version$,$version$]
+requires.10.filter = (&(osgi.os=linux)(osgi.ws=gtk)(osgi.arch=ppc)(!(org.eclipse.swt.buildtime=true)))
+
+requires.11.namespace = org.eclipse.equinox.p2.iu
+requires.11.name = org.eclipse.swt.gtk.linux.ppc64
+requires.11.range = [$version$,$version$]
+requires.11.filter = (&(osgi.os=linux)(osgi.ws=gtk)(osgi.arch=ppc64)(!(org.eclipse.swt.buildtime=true)))
+
+requires.12.namespace = org.eclipse.equinox.p2.iu
+requires.12.name = org.eclipse.swt.gtk.linux.x86_64
+requires.12.range = [$version$,$version$]
+requires.12.filter = (&(osgi.os=linux)(osgi.ws=gtk)(osgi.arch=x86_64)(!(org.eclipse.swt.buildtime=true)))
+
+requires.13.namespace = org.eclipse.equinox.p2.iu
+requires.13.name = org.eclipse.swt.gtk.linux.ppcle64
+requires.13.range = [$version$,$version$]
+requires.13.filter = (&(osgi.os=linux)(osgi.ws=gtk)(osgi.arch=ppcle64)(!(org.eclipse.swt.buildtime=true)))
+
+requires.14.namespace = org.eclipse.equinox.p2.iu
+requires.14.name = org.eclipse.swt.cocoa.macosx.x86_64
+requires.14.range = [$version$,$version$]
+requires.14.filter = (&(osgi.os=macosx)(osgi.ws=cocoa)(osgi.arch=x86_64)(!(org.eclipse.swt.buildtime=true)))
+
+requires.15.namespace = org.eclipse.equinox.p2.iu
+requires.15.name = org.eclipse.swt.gtk.aix.ppc
+requires.15.range = [$version$,$version$]
+requires.15.filter = (&(osgi.os=aix)(osgi.ws=gtk)(osgi.arch=ppc)(!(org.eclipse.swt.buildtime=true)))
+
+requires.16.namespace = org.eclipse.equinox.p2.iu
+requires.16.name = org.eclipse.swt.gtk.aix.ppc64
+requires.16.range = [$version$,$version$]
+requires.16.filter = (&(osgi.os=aix)(osgi.ws=gtk)(osgi.arch=ppc64)(!(org.eclipse.swt.buildtime=true)))
+
+requires.17.namespace = org.eclipse.equinox.p2.iu
+requires.17.name = org.eclipse.swt.gtk.hpux.ia64
+requires.17.range = [$version$,$version$]
+requires.17.filter = (&(osgi.os=hpux)(osgi.ws=gtk)(osgi.arch=ia64)(!(org.eclipse.swt.buildtime=true)))
diff --git a/bundles/org.eclipse.swt/buildSWT.xml b/bundles/org.eclipse.swt/buildSWT.xml
index c69286d5be..79e0185c8a 100644
--- a/bundles/org.eclipse.swt/buildSWT.xml
+++ b/bundles/org.eclipse.swt/buildSWT.xml
@@ -27,6 +27,8 @@
-->
<project name="swtbuild" basedir=".">
+ <taskdef name="xmltask" classname="com.oopsconsultancy.xmltask.ant.XmlTask"/>
+
<property name="gitroot" value="silenio@dev.eclipse.org:/gitroot/platform/"/>
<property name="TAG" value="master"/>
<property name="tmphome" value="../../../tmp"/>
@@ -1159,6 +1161,21 @@
<arg line="checkout master"/>
</exec>
</target>
+
+ <target name="generate_qualifier">
+ <tstamp><format property="build.qualifier" pattern="yyyyMMdd-HHmm"/></tstamp>
+ <echo>${build.qualifier}</echo>
+ </target>
+
+ <target name="write_qualifier" depends="generate_qualifier" description="writes the generated qualifier in pom.xml in src and binaries repo">
+ <xmltask source="${basedir}/${repo.src}/bundles/org.eclipse.swt/pom.xml" dest="${basedir}/${repo.src}/bundles/org.eclipse.swt/pom.xml" failWithoutMatch="true">
+ <replace path="/:project/:properties/:forceContextQualifier/text()" withText="v${build.qualifier}"/>
+ </xmltask>
+ <xmltask source="${basedir}/${repo.bin}/bundles/binaries-parent/pom.xml" dest="${basedir}/${repo.bin}/bundles/binaries-parent/pom.xml" failWithoutMatch="true">
+ <replace path="/:project/:properties/:forceContextQualifier/text()" withText="v${build.qualifier}"/>
+ </xmltask>
+ </target>
+
<!-- Convert SWT 32 bit java and C source to 64 bit -->
<target name="replace.32.to.64" depends="init_build">
diff --git a/bundles/org.eclipse.swt/pom.xml b/bundles/org.eclipse.swt/pom.xml
index 6fb6908c67..10e4ef20c7 100644
--- a/bundles/org.eclipse.swt/pom.xml
+++ b/bundles/org.eclipse.swt/pom.xml
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="UTF-8"?>
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!--
Copyright (c) 2012, 2013 Eclipse Foundation and others.
All rights reserved. This program and the accompanying materials
@@ -22,10 +22,21 @@
<artifactId>org.eclipse.swt</artifactId>
<version>3.104.0-SNAPSHOT</version>
<packaging>eclipse-plugin</packaging>
+ <properties>
+ <forceContextQualifier>v20141119-1356</forceContextQualifier>
+ </properties>
<build>
<plugins>
<plugin>
<groupId>org.eclipse.tycho</groupId>
+ <artifactId>tycho-packaging-plugin</artifactId>
+ <version>${tycho.version}</version>
+ <configuration>
+ <forceContextQualifier>${forceContextQualifier}</forceContextQualifier>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<configuration>
<dependency-resolution>
diff --git a/pom.xml b/pom.xml
index 0387ebe48e..ec57bb942c 100644
--- a/pom.xml
+++ b/pom.xml
@@ -41,6 +41,23 @@
</repository>
</repositories>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.eclipse.tycho</groupId>
+ <artifactId>target-platform-configuration</artifactId>
+ <version>${tycho.version}</version>
+ <configuration>
+ <dependency-resolution>
+ <profileProperties>
+ <org.eclipse.swt.buildtime>true</org.eclipse.swt.buildtime>
+ </profileProperties>
+ </dependency-resolution>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
<modules>
<module>bundles/org.eclipse.swt</module>
<module>bundles/org.eclipse.swt.tools</module>

Back to the top