[Releng] Reorganize category and add source feature to p2

Change-Id: I113103cde598468149645c61b2f774fab525d2df
Signed-off-by: Pauline DEVILLE <pauline.deville@cea.fr>
diff --git a/releng/org.eclipse.papyrus.moka.configuration/pom.xml b/releng/org.eclipse.papyrus.moka.configuration/pom.xml
index e050a09..134d527 100644
--- a/releng/org.eclipse.papyrus.moka.configuration/pom.xml
+++ b/releng/org.eclipse.papyrus.moka.configuration/pom.xml
@@ -13,8 +13,8 @@
 	<inceptionYear>2012</inceptionYear>
 
 	<properties>
-		<tycho.version>1.7.0</tycho.version>
-		<tycho.extras.version>1.7.0</tycho.extras.version>
+		<tycho.version>2.2.0</tycho.version>
+		<tycho.extras.version>2.2.0</tycho.extras.version>
 		<xtend.version>2.21.0</xtend.version>
 		<maven.resources.version>3.1.0</maven.resources.version>
 		<maven.clean.version>3.1.0</maven.clean.version>
@@ -151,6 +151,44 @@
 					</target>
 				</configuration>
 			</plugin>
+			
+			<plugin>
+				<!-- enable source bundle generation -->
+				<groupId>org.eclipse.tycho</groupId>
+				<artifactId>tycho-source-plugin</artifactId>
+				<version>${tycho.version}</version>
+				<executions>
+					<execution>
+						<id>plugin-source</id>
+						<goals>
+							<goal>plugin-source</goal>
+						</goals>
+					</execution>
+					<execution>
+						<id>feature-source</id>
+						<goals>
+							<goal>feature-source</goal>
+						</goals>
+					</execution>
+				</executions>
+			</plugin>
+			<plugin>
+				<groupId>org.eclipse.tycho</groupId>
+				<artifactId>tycho-p2-plugin</artifactId>
+				<version>${tycho.version}</version>
+				<executions>
+					<execution>
+						<id>attach-p2-metadata</id>
+						<phase>package</phase>
+						<goals>
+							<goal>p2-metadata</goal>
+						</goals>
+					</execution>
+				</executions>
+				<configuration>
+					<defaultP2Metadata>false</defaultP2Metadata>
+				</configuration>
+			</plugin>
 		</plugins>
 	</build>
 
diff --git a/releng/org.eclipse.papyrus.moka.p2/category.xml b/releng/org.eclipse.papyrus.moka.p2/category.xml
index 277f8c5..099d84a 100644
--- a/releng/org.eclipse.papyrus.moka.p2/category.xml
+++ b/releng/org.eclipse.papyrus.moka.p2/category.xml
@@ -1,9 +1,12 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <site>
-   <feature id="org.eclipse.papyrus.moka.feature">
-      <category name="org.eclipse.papyrus.moka"/>
+   <feature url="features/org.eclipse.papyrus.moka.feature_4.1.0.qualifier.jar" id="org.eclipse.papyrus.moka.feature" version="4.1.0.qualifier">
+      <category name="org.eclipse.papyrus.moka.category"/>
    </feature>
-   <category-def name="org.eclipse.papyrus.moka" label="Moka">
+   <feature url="features/org.eclipse.papyrus.moka.feature.source_4.1.0.qualifier.jar" id="org.eclipse.papyrus.moka.feature.source" version="4.1.0.qualifier">
+      <category name="org.eclipse.papyrus.moka.category"/>
+   </feature>
+   <category-def name="org.eclipse.papyrus.moka.category" label="Moka">
       <description>
          Papyrus Model Execution Tool
       </description>