| <?xml version="1.0" encoding="UTF-8"?> |
| <!--#======================================================================= --> |
| <!--# Copyright (c) 2012, 2014 - C4biz Softwares ME, Loetz GmbH&Co.KG (69115 Heidelberg, Germany) --> |
| <!--# All rights reserved. This program and the accompanying materials --> |
| <!--# are made available under the terms of the Eclipse Public License 2.0 --> |
| <!--# which accompanies this distribution, and is available at --> |
| <!--# https://www.eclipse.org/legal/epl-2.0/ --> |
| <!--# --> |
| <!--# SPDX-License-Identifier: EPL-2.0 --> |
| <!--# --> |
| <!--# Contributors: --> |
| <!--# Cristiano GaviĆ£o (C4biz)- initial API and implementation --> |
| <!--#======================================================================= --> |
| <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/xsd/maven-4.0.0.xsd"> |
| <modelVersion>4.0.0</modelVersion> |
| |
| <parent> |
| <groupId>org.eclipse.osbp.releng.maven</groupId> |
| <artifactId>org.eclipse.osbp.releng.maven</artifactId> |
| <version>0.9.0-SNAPSHOT</version> |
| <relativePath>../pom.xml</relativePath> |
| </parent> |
| |
| <artifactId>org.eclipse.osbp.releng.maven.parent.tycho</artifactId> |
| |
| <packaging>pom</packaging> |
| |
| <properties> |
| |
| <!-- these will be set by profiles (defaults to OSBPa) --> |
| <!-- <osbp.build.eclipse.platform.name></osbp.build.eclipse.platform.name> --> |
| <!-- <osbp.build.eclipse.platform.p2.url></osbp.build.eclipse.platform.p2.url> --> |
| |
| <!-- these will be set by profiles that deals with the local federated |
| stage repository --> |
| <osbp.build.local.federated.p2.dir>${osbp.stage.p2.technologystack.target.dir.base}${file.separator}${osbp.build.branch}${file.separator}</osbp.build.local.federated.p2.dir> |
| <osbp.build.local.federated.p2.url>file:////${osbp.build.local.federated.p2.dir}</osbp.build.local.federated.p2.url> |
| <osbp.build.remote.federated.p2.url>${osbp.p2.base}${osbp.build.eclipse.platform.name}${file.separator}${osbp.build.branch}${file.separator}</osbp.build.remote.federated.p2.url> |
| |
| <!-- this property is calculated based on the aggregator pom's version --> |
| <!-- osbp.stage.artifact.version>none</osbp.stage.artifact.version> --> |
| <osbp.stage.artifact.version>${parsedVersion.majorVersion}.${parsedVersion.minorVersion}.${parsedVersion.incrementalVersion}.${osgi-version-qualifier}</osbp.stage.artifact.version> |
| <osbp.stage.p2.keep.old>false</osbp.stage.p2.keep.old> |
| </properties> |
| |
| <scm> |
| <connection>${osbp.scm.connection}</connection> |
| <developerConnection>${osbp.scm.connection.dev}</developerConnection> |
| <tag>HEAD</tag> |
| </scm> |
| |
| <profiles> |
| <profile> |
| <id>platform.default</id> |
| <activation> |
| <property> |
| <name>!osbp.build.eclipse.platform.name</name> |
| </property> |
| </activation> |
| <properties> |
| <osbee.build.eclipse.platform.p2.url>http://download.eclipse.org/releases/neon</osbee.build.eclipse.platform.p2.url> |
| <osbp.build.eclipse.platform.name>neon</osbp.build.eclipse.platform.name> |
| <orbit-site>http://download.eclipse.org/tools/orbit/downloads/drops/R20170307180635/repository/</orbit-site> |
| </properties> |
| <repositories> |
| <repository> |
| <id>Neon eclipse.p2</id> |
| <url>http://download.eclipse.org/releases/neon</url> |
| <layout>p2</layout> |
| </repository> |
| <!-- |
| <repository> |
| <id>EclipseNeonSR2</id> |
| <url>http://download.eclipse.org/releases/neon/201612211000/ |
| </url> |
| <layout>p2</layout> |
| </repository> |
| <repository> |
| <id>EclipseNeonSR3</id> |
| <url>http://download.eclipse.org/releases/neon/201703231000/ |
| </url> |
| <layout>p2</layout> |
| </repository> |
| --> |
| <repository> |
| <id>Neon3 Orbit</id> |
| <url>http://download.eclipse.org/tools/orbit/downloads/drops/R20170307180635/repository/ |
| </url> |
| <layout>p2</layout> |
| </repository> |
| <repository> |
| <id>EclipseNeonComposite</id> |
| <url>http://download.eclipse.org/eclipse/updates/4.6/ |
| </url> |
| <layout>p2</layout> |
| </repository> |
| </repositories> |
| </profile> |
| <profile> |
| <id>platform.neon</id> |
| <activation> |
| <property> |
| <name>osbp.build.eclipse.platform.name</name> |
| <value>neon</value> |
| </property> |
| </activation> |
| <properties> |
| <osbee.build.eclipse.platform.p2.url>http://download.eclipse.org/releases/neon</osbee.build.eclipse.platform.p2.url> |
| <orbit-site>http://download.eclipse.org/tools/orbit/downloads/drops/R20170307180635/repository/</orbit-site> |
| <osbp.build.eclipse.platform.name>neon</osbp.build.eclipse.platform.name> |
| </properties> |
| <repositories> |
| <repository> |
| <id>Neon eclipse.p2</id> |
| <url>http://download.eclipse.org/releases/neon</url> |
| <layout>p2</layout> |
| </repository> |
| <!-- |
| <repository> |
| <id>EclipseNeonSR2</id> |
| <url>http://download.eclipse.org/releases/neon/201612211000/ |
| </url> |
| <layout>p2</layout> |
| </repository> |
| <repository> |
| <id>EclipseNeonSR3</id> |
| <url>http://download.eclipse.org/releases/neon/201703231000/ |
| </url> |
| <layout>p2</layout> |
| </repository> |
| --> |
| <repository> |
| <id>Neon3 Orbit</id> |
| <url>http://download.eclipse.org/tools/orbit/downloads/drops/R20170307180635/repository/ |
| </url> |
| <layout>p2</layout> |
| </repository> |
| <repository> |
| <id>EclipseNeonComposite</id> |
| <url>http://download.eclipse.org/eclipse/updates/4.6/ |
| </url> |
| <layout>p2</layout> |
| </repository> |
| </repositories> |
| </profile> |
| <profile> |
| <id>platform.luna</id> |
| <activation> |
| <property> |
| <name>osbp.build.eclipse.platform.name</name> |
| <value>luna</value> |
| </property> |
| </activation> |
| <properties> |
| <osbp.build.eclipse.platform.name>luna</osbp.build.eclipse.platform.name> |
| <orbit-site>http://download.eclipse.org/tools/orbit/downloads/drops/R20140525021250/repository/</orbit-site> |
| </properties> |
| <repositories> |
| <repository> |
| <id>Luna eclipse.p2</id> |
| <url>http://download.eclipse.org/releases/luna</url> |
| <layout>p2</layout> |
| </repository> |
| <repository> |
| <id>orbit</id> |
| <url>http://download.eclipse.org/tools/orbit/downloads/drops/R20140525021250/repository/</url> |
| <layout>p2</layout> |
| </repository> |
| </repositories> |
| |
| </profile> |
| <profile> |
| <id>osbp.build.uses.local.federated.p2</id> |
| <activation> |
| <property> |
| <name>osbp.build.uses.local.federated.p2</name> |
| </property> |
| </activation> |
| <repositories> |
| <repository> |
| <id>OSBP Technologystack Internal P2</id> |
| <url>${osbp.technologystack.p2}</url> |
| <layout>p2</layout> |
| </repository> |
| </repositories> |
| </profile> |
| <profile> |
| <id>osbp.build.uses.remote.federated.p2</id> |
| <activation> |
| <property> |
| <name>osbp.build.uses.remote.federated.p2</name> |
| </property> |
| </activation> |
| <repositories> |
| <repository> |
| <id>OSBP Technologystack Internal P2</id> |
| <url>${osbp.technologystack.p2}</url> |
| <layout>p2</layout> |
| </repository> |
| </repositories> |
| </profile> |
| <profile> |
| <id>prepare-for-next-release</id> |
| <activation> |
| <activeByDefault>false</activeByDefault> |
| </activation> |
| <build> |
| <defaultGoal>org.eclipse.tycho:tycho-versions-plugin:set-version</defaultGoal> |
| <plugins> |
| <plugin> |
| <groupId>org.eclipse.tycho</groupId> |
| <artifactId>tycho-versions-plugin</artifactId> |
| <version>${tycho-version}</version> |
| <executions> |
| <execution> |
| <id>change-next-release</id> |
| <goals> |
| <goal>set-version</goal> |
| </goals> |
| </execution> |
| </executions> |
| <configuration> |
| <newVersion>${next-release}</newVersion> |
| </configuration> |
| </plugin> |
| </plugins> |
| </build> |
| </profile> |
| <profile> |
| <!-- this profile must be activated when there isn't osbp.build.branch |
| defined. --> |
| <id>latest</id> |
| <activation> |
| <property> |
| <name>!osbp.build.branch</name> |
| </property> |
| </activation> |
| <properties> |
| <osbp.build.branch>latest</osbp.build.branch> |
| <osbp.stage.artifact.version>${parsedVersion.majorVersion}.${parsedVersion.minorVersion}.${parsedVersion.incrementalVersion}.${osgi-version-qualifier}</osbp.stage.artifact.version> |
| <osbp.stage.p2.keep.old>false</osbp.stage.p2.keep.old> |
| </properties> |
| <build> |
| <plugins> |
| <!-- used to debug... --> |
| <!-- <plugin> --> |
| <!-- <artifactId>maven-antrun-plugin</artifactId> --> |
| <!-- <executions> --> |
| <!-- <execution> --> |
| <!-- <phase>initialize</phase> --> |
| <!-- <configuration> --> |
| <!-- <quiet>true</quiet> --> |
| <!-- <target> --> |
| <!-- <echo message="Started a Latest Build..." /> --> |
| <!-- </target> --> |
| <!-- </configuration> --> |
| <!-- <goals> --> |
| <!-- <goal>run</goal> --> |
| <!-- </goals> --> |
| <!-- </execution> --> |
| <!-- </executions> --> |
| <!-- </plugin> --> |
| </plugins> |
| </build> |
| </profile> |
| |
| <profile> |
| <id>milestone</id> |
| <activation> |
| <property> |
| <name>osbp.build.branch</name> |
| <value>milestone</value> |
| </property> |
| </activation> |
| <properties> |
| <osbp.stage.artifact.version>M${parsedVersion.majorVersion}.${parsedVersion.minorVersion}.${parsedVersion.incrementalVersion}.${osgi-version-qualifier}</osbp.stage.artifact.version> |
| <osbp.stage.p2.keep.old>false</osbp.stage.p2.keep.old> |
| </properties> |
| <build> |
| <plugins> |
| <!-- used to debug... --> |
| <!-- <plugin> --> |
| <!-- <artifactId>maven-antrun-plugin</artifactId> --> |
| <!-- <executions> --> |
| <!-- <execution> --> |
| <!-- <phase>initialize</phase> --> |
| <!-- <configuration> --> |
| <!-- <quiet>true</quiet> --> |
| <!-- <target> --> |
| <!-- <echo message="Started a Milestone Build..." /> --> |
| <!-- </target> --> |
| <!-- </configuration> --> |
| <!-- <goals> --> |
| <!-- <goal>run</goal> --> |
| <!-- </goals> --> |
| <!-- </execution> --> |
| <!-- </executions> --> |
| <!-- </plugin> --> |
| </plugins> |
| </build> |
| </profile> |
| |
| <profile> |
| <id>release</id> |
| <activation> |
| <property> |
| <name>osbp.build.branch</name> |
| <value>release</value> |
| </property> |
| </activation> |
| <properties> |
| <osbp.stage.artifact.version>${parsedVersion.majorVersion}.${parsedVersion.minorVersion}.${parsedVersion.incrementalVersion}</osbp.stage.artifact.version> |
| <osbp.stage.p2.keep.old>true</osbp.stage.p2.keep.old> |
| </properties> |
| <build> |
| <plugins> |
| <!-- <plugin> --> |
| <!-- <artifactId>maven-antrun-plugin</artifactId> --> |
| <!-- <executions> --> |
| <!-- <execution> --> |
| <!-- <phase>validate</phase> --> |
| <!-- <configuration> --> |
| <!-- <quiet>true</quiet> --> |
| <!-- <target> --> |
| <!-- <echo message="Started a Release Build..." /> --> |
| <!-- <fail message="Release should not use SNAPSHOT version !"> --> |
| <!-- <condition> --> |
| <!-- <contains string="${project.version}" substring="SNAPSHOT" /> --> |
| <!-- </condition> --> |
| <!-- </fail> --> |
| <!-- </target> --> |
| <!-- </configuration> --> |
| <!-- <goals> --> |
| <!-- <goal>run</goal> --> |
| <!-- </goals> --> |
| <!-- </execution> --> |
| <!-- </executions> --> |
| <!-- </plugin> --> |
| </plugins> |
| </build> |
| </profile> |
| <profile> |
| <id>whenIsDependenciesRepositoryP2Project</id> |
| <activation> |
| <file> |
| <exists>.osbp.releng.eclipse.dependencies.p2</exists> |
| </file> |
| </activation> |
| <properties> |
| <!-- this properties should be overridden for each repository POM --> |
| <osbp.stage.p2.label>${project.artifactId}</osbp.stage.p2.label> |
| </properties> |
| <build> |
| <plugins> |
| <plugin> |
| <groupId>org.eclipse.tycho</groupId> |
| <artifactId>target-platform-configuration</artifactId> |
| <configuration> |
| <resolver>p2</resolver> |
| <pomDependencies>consider</pomDependencies> |
| <environments> |
| <environment> |
| <os>win32</os> |
| <ws>win32</ws> |
| <arch>x86</arch> |
| </environment> |
| <environment> |
| <os>win32</os> |
| <ws>win32</ws> |
| <arch>x86_64</arch> |
| </environment> |
| <environment> |
| <os>linux</os> |
| <ws>gtk</ws> |
| <arch>x86</arch> |
| </environment> |
| <environment> |
| <os>linux</os> |
| <ws>gtk</ws> |
| <arch>x86_64</arch> |
| </environment> |
| <environment> |
| <os>macosx</os> |
| <ws>cocoa</ws> |
| <arch>x86_64</arch> |
| </environment> |
| </environments> |
| </configuration> |
| </plugin> |
| </plugins> |
| </build> |
| |
| </profile> |
| <profile> |
| <id>whenIsRepositoryP2Project</id> |
| <activation> |
| <file> |
| <exists>.osbp.releng.eclipse.p2</exists> |
| </file> |
| </activation> |
| <properties> |
| <!-- this properties should be overridden for each repository POM --> |
| <osbp.stage.p2.label>${project.artifactId}</osbp.stage.p2.label> |
| </properties> |
| <build> |
| <plugins> |
| <plugin> |
| <groupId>org.eclipse.tycho</groupId> |
| <artifactId>target-platform-configuration</artifactId> |
| <configuration> |
| <resolver>p2</resolver> |
| <pomDependencies>consider</pomDependencies> |
| <environments> |
| <environment> |
| <os>win32</os> |
| <ws>win32</ws> |
| <arch>x86</arch> |
| </environment> |
| <environment> |
| <os>win32</os> |
| <ws>win32</ws> |
| <arch>x86_64</arch> |
| </environment> |
| <environment> |
| <os>linux</os> |
| <ws>gtk</ws> |
| <arch>x86</arch> |
| </environment> |
| <environment> |
| <os>linux</os> |
| <ws>gtk</ws> |
| <arch>x86_64</arch> |
| </environment> |
| <environment> |
| <os>macosx</os> |
| <ws>cocoa</ws> |
| <arch>x86_64</arch> |
| </environment> |
| </environments> |
| </configuration> |
| </plugin> |
| </plugins> |
| </build> |
| |
| </profile> |
| <profile> |
| <id>whenIsDependenciesRepositoryP2Project.stage.p2</id> |
| <activation> |
| <file> |
| <exists>.osbp.releng.eclipse.dependencies.p2</exists> |
| </file> |
| </activation> |
| <properties> |
| <!-- encoded files needed by ant task --> |
| <encoded.p2index>dmVyc2lvbiA9IDEKIG1ldGFkYXRhLnJlcG9zaXRvcnkuZmFjdG9yeS5vcmRlciA9IGNvbXBvc2l0ZUNvbnRlbnQueG1sLFwhCiBhcnRpZmFjdC5yZXBvc2l0b3J5LmZhY3Rvcnkub3JkZXIgPSBjb21wb3NpdGVBcnRpZmFjdHMueG1sLFwh</encoded.p2index> |
| <encoded.compositeArtifacts>PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4KPD9jb21wb3NpdGVBcnRpZmFjdFJlcG9zaXRvcnkgdmVyc2lvbj0nMS4wLjAnPz4KPHJlcG9zaXRvcnkgbmFtZT0nT1NCUCBQdWJsaWMgUDIgUmVwb3NpdG9yeScgdHlwZT0nb3JnLmVjbGlwc2UuZXF1aW5veC5pbnRlcm5hbC5wMi5hcnRpZmFjdC5yZXBvc2l0b3J5LkNvbXBvc2l0ZUFydGlmYWN0UmVwb3NpdG9yeScgdmVyc2lvbj0nMS4wLjAnPgogIDxwcm9wZXJ0aWVzIHNpemU9JzEnPgoJPHByb3BlcnR5IG5hbWU9J3AyLnRpbWVzdGFtcCcgdmFsdWU9JzEyNDM4MjI1MDI0NDAnLz4KICA8L3Byb3BlcnRpZXM+CiAgPGNoaWxkcmVuIHNpemU9JzAnPgkKICA8L2NoaWxkcmVuPgo8L3JlcG9zaXRvcnk+Cg==</encoded.compositeArtifacts> |
| <encoded.compositeContent>PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4KPD9jb21wb3NpdGVNZXRhZGF0YVJlcG9zaXRvcnkgdmVyc2lvbj0nMS4wLjAnPz4KPHJlcG9zaXRvcnkgbmFtZT0nT1NCUCBQdWJsaWMgUDIgUmVwb3NpdG9yeScgdHlwZT0nb3JnLmVjbGlwc2UuZXF1aW5veC5pbnRlcm5hbC5wMi5tZXRhZGF0YS5yZXBvc2l0b3J5LkNvbXBvc2l0ZU1ldGFkYXRhUmVwb3NpdG9yeScgdmVyc2lvbj0nMS4wLjAnPgogIDxwcm9wZXJ0aWVzIHNpemU9JzEnPgoJPHByb3BlcnR5IG5hbWU9J3AyLnRpbWVzdGFtcCcgdmFsdWU9JzEyNDM4MjI1MDI0OTknLz4KICA8L3Byb3BlcnRpZXM+CiAgPGNoaWxkcmVuIHNpemU9JzAnPgogIDwvY2hpbGRyZW4+CjwvcmVwb3NpdG9yeT4K</encoded.compositeContent> |
| |
| <osbp.build.local.federated.p2.dir>${osbp.stage.p2.dependencies.target.dir.base}${file.separator}${osbp.build.branch}${file.separator}</osbp.build.local.federated.p2.dir> |
| |
| <osbp.stage.p2.log.file.path>${project.basedir}${file.separator}build.${osbp.stage.p2.label}.${osbp.build.eclipse.platform.name}.${osbp.build.branch}.log.properties</osbp.stage.p2.log.file.path> |
| <osbp.stage.p2.origin.dir>${project.build.directory}${file.separator}repository</osbp.stage.p2.origin.dir> |
| <osbp.stage.p2.target.dir>${osbp.build.local.federated.p2.dir}${osbp.stage.p2.label}${file.separator}${osbp.stage.artifact.version}</osbp.stage.p2.target.dir> |
| </properties> |
| <pluginRepositories> |
| <pluginRepository> |
| <id>Atlassian Maven External</id> |
| <url>https://packages.atlassian.com/mvn/maven-external/</url> |
| </pluginRepository> |
| </pluginRepositories> |
| <build> |
| <plugins> |
| <plugin> |
| <artifactId>maven-antrun-plugin</artifactId> |
| <executions> |
| <execution> |
| <id>generate-files</id> |
| <phase>verify</phase> |
| <configuration> |
| <quiet>true</quiet> |
| <target> |
| <taskdef name="groovy" classname="org.codehaus.groovy.ant.Groovy"> |
| <classpath refid="maven.compile.classpath"/> |
| </taskdef> |
| <taskdef resource="net/sf/antcontrib/antlib.xml"/> |
| <taskdef resource="net/sf/antcontrib/antcontrib.properties"/> |
| <taskdef name="xmltask" classname="com.oopsconsultancy.xmltask.ant.XmlTask"/> |
| |
| <echo message="Federated Repository Local Dir (osbp.build.local.federated.p2.dir): ${osbp.build.local.federated.p2.dir}"/> |
| <echo message="Platform: ${osbp.build.eclipse.platform.name}"/> |
| <echo message="Build Type: ${osbp.build.branch}"/> |
| <echo message="Repo Name: ${osbp.stage.p2.label}"/> |
| <echo message="Repo Keep Old: ${osbp.stage.p2.keep.old}"/> |
| <echo message="Repo Version: ${osbp.stage.artifact.version}"/> |
| <echo message="Log File (osbp.stage.p2.log.file.path): ${osbp.stage.p2.log.file.path}"/> |
| <echo message="P2 Source Dir (osbp.stage.p2.origin.dir): ${osbp.stage.p2.origin.dir}"/> |
| <echo message="P2 Target Dir (osbp.stage.p2.target.dir): ${osbp.stage.p2.target.dir}"/> |
| |
| <!-- "init" --> |
| <fail message="There property 'osbp.developer.home' was not defined in settings.xml or in commandline."> |
| <condition> |
| <or> |
| <not> |
| <isset property="osbp.developer.home"/> |
| </not> |
| <equals arg1="${osbp.developer.home}" arg2="none"/> |
| </or> |
| </condition> |
| </fail> |
| <if> |
| <not> |
| <available file="${osbp.developer.home}" type="dir"/> |
| </not> |
| <then> |
| <mkdir dir="${osbp.developer.home}"/> |
| </then> |
| </if> |
| <if> |
| <not> |
| <available file="${osbp.developer.home.repositories}" type="dir"/> |
| </not> |
| <then> |
| <mkdir dir="${osbp.developer.home.repositories}"/> |
| </then> |
| </if> |
| <if> |
| <not> |
| <available file="${osbp.build.local.federated.p2.dir}" type="dir"/> |
| </not> |
| <then> |
| <mkdir dir="${osbp.build.local.federated.p2.dir}"/> |
| </then> |
| </if> |
| <groovy> |
| ant.echo "Extracted building templates..." |
| |
| def |
| separator = |
| "${properties['file.separator']}" |
| def directory = |
| "${properties['project.build.directory']}" + separator + |
| "templates" + separator |
| |
| new |
| File(directory).mkdir() |
| |
| def |
| encodedP2index = |
| "${properties['encoded.p2index']}" |
| def |
| encodedCompositeArtifacts = |
| "${properties['encoded.compositeArtifacts']}" |
| def |
| encodedCompositeContent = |
| "${properties['encoded.compositeContent']}" |
| |
| properties.p2indexFile = directory + "p2.index" |
| properties.compositeArtifactsFile = directory + |
| "compositeArtifacts.xml" |
| properties.compositeContentFile = |
| directory + "compositeContent.xml" |
| |
| new |
| FileOutputStream(properties.p2indexFile).write(encodedP2index.decodeBase64()) |
| new |
| FileOutputStream(properties.compositeArtifactsFile).write(encodedCompositeArtifacts.decodeBase64()) |
| new |
| FileOutputStream(properties.compositeContentFile).write(encodedCompositeContent.decodeBase64()) |
| |
| </groovy> |
| <echo message="** OSBP User Developer Home: ${osbp.developer.home}"/> |
| <echo message=" - index source: ${p2indexFile}"/> |
| <echo message=" - contentFile source: ${compositeContentFile}"/> |
| <echo message=" - artifactsFile source: ${compositeArtifactsFile}"/> |
| |
| <!-- generate.composite.p2.init --> |
| |
| <fail message="Could not find p2.index template at ${p2indexFile} !"> |
| <condition> |
| <not> |
| <available file="${p2indexFile}" type="file"/> |
| </not> |
| </condition> |
| </fail> |
| |
| <fail message="Could not find compositeContent.xml template at ${compositeContentFile} !"> |
| <condition> |
| <not> |
| <available file="${compositeContentFile}" type="file"/> |
| </not> |
| </condition> |
| </fail> |
| |
| <fail message="Could not find compositeArtifacts.xml template at ${compositeArtifactsFile} !"> |
| <condition> |
| <not> |
| <available file="${compositeArtifactsFile}" type="file"/> |
| </not> |
| </condition> |
| </fail> |
| |
| <!-- "deploy.generated.p2.to.composite.dir.init" --> |
| <echo message="Copying repo to Federated Repository !!!"/> |
| <echo message="Checking existence of log file at:'${osbp.stage.p2.log.file.path}'"/> |
| <if> |
| <available file="${osbp.stage.p2.log.file.path}" type="file"/> |
| <then> |
| <echo message="OPEN BUILD LOG"/> |
| <property file="${osbp.stage.p2.log.file.path}" prefix="old"/> |
| <echoproperties prefix="old."/> |
| </then> |
| <else> |
| <echo message="Log file was not found at: '${osbp.stage.p2.log.file.path}'"/> |
| </else> |
| </if> |
| |
| <!-- deploy.generated.p2.to.composite.dir.clean --> |
| <!-- remove an existent repository directory --> |
| <if> |
| <available file="${osbp.build.local.federated.p2.dir}${osbp.stage.p2.label}" type="dir"/> |
| <then> |
| <delete includeemptydirs="true" failonerror="false"> |
| <fileset includes="**/*" dir="${osbp.build.local.federated.p2.dir}${osbp.stage.p2.label}"/> |
| </delete> |
| <delete dir="${osbp.build.local.federated.p2.dir}${osbp.stage.p2.label}"/> |
| </then> |
| </if> |
| |
| <!-- deploy.generated.p2.to.composite.p2 --> |
| <!-- create the repository directory and copy files from the generated |
| P2 --> |
| <echo message="COPYING P2"/> |
| <if> |
| <available file="${osbp.stage.p2.origin.dir}" type="dir"/> |
| <then> |
| <mkdir dir="${osbp.stage.p2.target.dir}"/> |
| <copy todir="${osbp.stage.p2.target.dir}"> |
| <fileset dir="${osbp.stage.p2.origin.dir}" includes="**/*"/> |
| </copy> |
| <if> |
| <equals arg1="${osbp.stage.p2.keep.old}" arg2="false"/> |
| <then> |
| <propertyfile file="${osbp.stage.p2.log.file.path}" comment="Building log for ${osbp.build.eclipse.platform.name} - ${osbp.build.branch}"> |
| <entry key="build.counter" type="int" default="0" operation="+"/> |
| <entry key="build.date" type="date" value="now"/> |
| <entry key="osbp.stage.artifact.version" value="${osbp.stage.artifact.version}"/> |
| <entry key="osbp.stage.p2.target.dir" value="${osbp.stage.p2.target.dir}"/> |
| </propertyfile> |
| </then> |
| <else> |
| <propertyfile file="${osbp.stage.p2.log.file.path}" comment="Building log for ${osbp.build.eclipse.platform.name} - ${osbp.build.branch}"> |
| <entry key="build.counter" type="int" default="0" operation="+"/> |
| <entry key="build.date" type="date" value="now"/> |
| <entry key="osbp.build.local.federated.p2.dir" value="${osbp.build.local.federated.p2.dir}"/> |
| <entry key="osbp.stage.artifact.versions" default="" operation="+" value=",${osbp.stage.artifact.version}"/> |
| </propertyfile> |
| </else> |
| </if> |
| </then> |
| <else> |
| <fail message="The P2 repository was not generated in '${osbp.stage.p2.origin.dir}' !"/> |
| </else> |
| </if> |
| |
| <!-- start rebuilding... --> |
| <echo message="Rebuilding Federated Repository !!!"/> |
| <echo message=" (osbp.build.local.federated.p2.dir): ${osbp.build.local.federated.p2.dir}"/> |
| |
| <dirset id="dirs" dir="${osbp.build.local.federated.p2.dir}" includes="*/*"/> |
| |
| <fail message="There is no repositories to process !"> |
| <condition> |
| <resourcecount when="equal" count="0" refid="dirs"/> |
| </condition> |
| </fail> |
| |
| <if> |
| <available file="${osbp.build.local.federated.p2.dir}compositeContent.xml" type="file"/> |
| <then> |
| <echo message="DELETED OLD CONTENT FILE"/> |
| <delete file="${osbp.build.local.federated.p2.dir}compositeContent.xml"/> |
| </then> |
| </if> |
| <if> |
| <available file="${osbp.build.local.federated.p2.dir}compositeArtifacts.xml" type="file"/> |
| <then> |
| <echo message="DELETED OLD ARTIFACTS FILE"/> |
| <delete file="${osbp.build.local.federated.p2.dir}compositeArtifacts.xml"/> |
| </then> |
| </if> |
| |
| <!-- generate.composite.p2.add.compositeContentFile --> |
| <xmltask source="${compositeContentFile}" destbuffer="bufferCompositeContent" report="true"/> |
| <var name="counterContent" value="0"/> |
| <for param="child" list="${toString:dirs}" delimiter=";"> |
| <sequential> |
| <math result="counterContent" operand1="${counterContent}" operand2="1" operation="+" datatype="int"/> |
| <echo message="Adding Content Child @{child} - ${counterContent}"/> |
| <xmltask sourcebuffer="bufferCompositeContent" destbuffer="bufferCompositeContent"> |
| <insert path="/repository/children"> |
| <child location='@{child}' /> |
| </insert> |
| </xmltask> |
| </sequential> |
| </for> |
| <xmltask sourcebuffer="bufferCompositeContent" destbuffer="bufferCompositeContent"> |
| <replace path="/repository/children/@size" withText="${counterContent}"/> |
| </xmltask> |
| |
| <!-- generate.composite.p2.add.compositeArtifactsFile --> |
| <xmltask source="${compositeArtifactsFile}" destbuffer="bufferCompositeArtifacts" report="true"/> |
| <var name="counterArtifacts" value="0"/> |
| <for param="child" list="${toString:dirs}" delimiter=";"> |
| <sequential> |
| <math result="counterArtifacts" operand1="${counterArtifacts}" operand2="1" operation="+" datatype="int"/> |
| <echo message="Adding Artifact Child @{child} - ${counterArtifacts}"/> |
| <xmltask sourcebuffer="bufferCompositeArtifacts" destbuffer="bufferCompositeArtifacts"> |
| <insert path="/repository/children"> |
| <child location='@{child}' /> |
| </insert> |
| </xmltask> |
| </sequential> |
| </for> |
| <xmltask sourcebuffer="bufferCompositeArtifacts" destbuffer="bufferCompositeArtifacts"> |
| <replace path="/repository/children/@size" withText="${counterArtifacts}"/> |
| </xmltask> |
| |
| <!-- generate.composite.p2.add.p2.index.file --> |
| <if> |
| <not> |
| <available file="${osbp.build.local.federated.p2.dir}p2.index" type="file"/> |
| </not> |
| <then> |
| <copy file="${p2indexFile}" todir="${osbp.build.local.federated.p2.dir}"/> |
| </then> |
| </if> |
| |
| <!-- generate.composite.p2 --> |
| <echo message="CREATE COMPOSITE ARTIFACTS"/> |
| <xmltask sourcebuffer="bufferCompositeArtifacts" dest="${osbp.build.local.federated.p2.dir}compositeArtifacts.xml"/> |
| |
| <echo message="CREATE COMPOSITE CONTENT"/> |
| <xmltask sourcebuffer="bufferCompositeContent" dest="${osbp.build.local.federated.p2.dir}compositeContent.xml"/> |
| |
| <!-- end generation --> |
| |
| </target> |
| </configuration> |
| <goals> |
| <goal>run</goal> |
| </goals> |
| </execution> |
| </executions> |
| <dependencies> |
| <dependency> |
| <groupId>org.codehaus.groovy</groupId> |
| <artifactId>groovy-all</artifactId> |
| <version>${groovy-all.version}</version> |
| </dependency> |
| <dependency> |
| <groupId>org.apache.ant</groupId> |
| <artifactId>ant</artifactId> |
| <version>${ant-version}</version> |
| </dependency> |
| <dependency> |
| <groupId>ant-contrib</groupId> |
| <artifactId>ant-contrib</artifactId> |
| <version>1.0b3</version> |
| <exclusions> |
| <exclusion> |
| <groupId>ant</groupId> |
| <artifactId>ant</artifactId> |
| </exclusion> |
| </exclusions> |
| </dependency> |
| <dependency> |
| <groupId>net.sf.saxon</groupId> |
| <artifactId>Saxon-HE</artifactId> |
| <version>9.4</version> |
| </dependency> |
| <dependency> |
| <groupId>com.oopsconsultancy</groupId> |
| <artifactId>xmltask</artifactId> |
| <version>1.16</version> |
| </dependency> |
| </dependencies> |
| </plugin> |
| </plugins> |
| </build> |
| </profile> |
| <profile> |
| <!-- used for technologystack --> |
| <id>whenIsTechnologystackP2Project.stage.p2</id> |
| <activation> |
| <file> |
| <exists>.osbp.releng.eclipse.technologystack.p2</exists> |
| </file> |
| </activation> |
| <properties> |
| <!-- encoded files needed by ant task --> |
| <encoded.p2index>dmVyc2lvbiA9IDEKIG1ldGFkYXRhLnJlcG9zaXRvcnkuZmFjdG9yeS5vcmRlciA9IGNvbXBvc2l0ZUNvbnRlbnQueG1sLFwhCiBhcnRpZmFjdC5yZXBvc2l0b3J5LmZhY3Rvcnkub3JkZXIgPSBjb21wb3NpdGVBcnRpZmFjdHMueG1sLFwh</encoded.p2index> |
| <encoded.compositeArtifacts>PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4KPD9jb21wb3NpdGVBcnRpZmFjdFJlcG9zaXRvcnkgdmVyc2lvbj0nMS4wLjAnPz4KPHJlcG9zaXRvcnkgbmFtZT0nT1NCUCBQdWJsaWMgUDIgUmVwb3NpdG9yeScgdHlwZT0nb3JnLmVjbGlwc2UuZXF1aW5veC5pbnRlcm5hbC5wMi5hcnRpZmFjdC5yZXBvc2l0b3J5LkNvbXBvc2l0ZUFydGlmYWN0UmVwb3NpdG9yeScgdmVyc2lvbj0nMS4wLjAnPgogIDxwcm9wZXJ0aWVzIHNpemU9JzEnPgoJPHByb3BlcnR5IG5hbWU9J3AyLnRpbWVzdGFtcCcgdmFsdWU9JzEyNDM4MjI1MDI0NDAnLz4KICA8L3Byb3BlcnRpZXM+CiAgPGNoaWxkcmVuIHNpemU9JzAnPgkKICA8L2NoaWxkcmVuPgo8L3JlcG9zaXRvcnk+Cg==</encoded.compositeArtifacts> |
| <encoded.compositeContent>PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4KPD9jb21wb3NpdGVNZXRhZGF0YVJlcG9zaXRvcnkgdmVyc2lvbj0nMS4wLjAnPz4KPHJlcG9zaXRvcnkgbmFtZT0nT1NCUCBQdWJsaWMgUDIgUmVwb3NpdG9yeScgdHlwZT0nb3JnLmVjbGlwc2UuZXF1aW5veC5pbnRlcm5hbC5wMi5tZXRhZGF0YS5yZXBvc2l0b3J5LkNvbXBvc2l0ZU1ldGFkYXRhUmVwb3NpdG9yeScgdmVyc2lvbj0nMS4wLjAnPgogIDxwcm9wZXJ0aWVzIHNpemU9JzEnPgoJPHByb3BlcnR5IG5hbWU9J3AyLnRpbWVzdGFtcCcgdmFsdWU9JzEyNDM4MjI1MDI0OTknLz4KICA8L3Byb3BlcnRpZXM+CiAgPGNoaWxkcmVuIHNpemU9JzAnPgogIDwvY2hpbGRyZW4+CjwvcmVwb3NpdG9yeT4K</encoded.compositeContent> |
| |
| <!-- this properties should be overridden for each repository POM --> |
| <osbp.stage.p2.label>${project.artifactId}</osbp.stage.p2.label> |
| |
| <osbp.build.local.federated.p2.dir>${osbp.stage.p2.technologystack.target.dir.base}${file.separator}${osbp.build.branch}${file.separator}</osbp.build.local.federated.p2.dir> |
| |
| <osbp.stage.p2.log.file.path>${project.basedir}${file.separator}build.${osbp.stage.p2.label}.${osbp.build.eclipse.platform.name}.${osbp.build.branch}.log.properties</osbp.stage.p2.log.file.path> |
| <osbp.stage.p2.origin.dir>${project.build.directory}${file.separator}repository</osbp.stage.p2.origin.dir> |
| <osbp.stage.p2.target.dir>${osbp.build.local.federated.p2.dir}${osbp.stage.p2.label}${file.separator}${osbp.stage.artifact.version}</osbp.stage.p2.target.dir> |
| </properties> |
| <pluginRepositories> |
| <pluginRepository> |
| <id>Atlassian Maven External</id> |
| <url>https://packages.atlassian.com/mvn/maven-external/</url> |
| </pluginRepository> |
| </pluginRepositories> |
| <repositories> |
| <repository> |
| <id>OSBP dependencies Internal P2</id> |
| <url>file:////${osbp.stage.p2.dependencies.target.dir.base}${file.separator}${osbp.build.branch}${file.separator}</url> |
| <layout>p2</layout> |
| </repository> |
| </repositories> |
| <build> |
| <plugins> |
| <plugin> |
| <artifactId>maven-antrun-plugin</artifactId> |
| <executions> |
| <execution> |
| <id>generate-files</id> |
| <phase>verify</phase> |
| <configuration> |
| <quiet>true</quiet> |
| <target> |
| <taskdef name="groovy" classname="org.codehaus.groovy.ant.Groovy"> |
| <classpath refid="maven.compile.classpath"/> |
| </taskdef> |
| <taskdef resource="net/sf/antcontrib/antlib.xml"/> |
| <taskdef resource="net/sf/antcontrib/antcontrib.properties"/> |
| <taskdef name="xmltask" classname="com.oopsconsultancy.xmltask.ant.XmlTask"/> |
| |
| <echo message="Federated Repository Local Dir (osbp.build.local.federated.p2.dir): ${osbp.build.local.federated.p2.dir}"/> |
| <echo message="Platform: ${osbp.build.eclipse.platform.name}"/> |
| <echo message="Build Type: ${osbp.build.branch}"/> |
| <echo message="Repo Name: ${osbp.stage.p2.label}"/> |
| <echo message="Repo Keep Old: ${osbp.stage.p2.keep.old}"/> |
| <echo message="Repo Version: ${osbp.stage.artifact.version}"/> |
| <echo message="Log File (osbp.stage.p2.log.file.path): ${osbp.stage.p2.log.file.path}"/> |
| <echo message="P2 Source Dir (osbp.stage.p2.origin.dir): ${osbp.stage.p2.origin.dir}"/> |
| <echo message="P2 Target Dir (osbp.stage.p2.target.dir): ${osbp.stage.p2.target.dir}"/> |
| |
| <!-- "init" --> |
| <fail message="There property 'osbp.developer.home' was not defined in settings.xml or in commandline."> |
| <condition> |
| <or> |
| <not> |
| <isset property="osbp.developer.home"/> |
| </not> |
| <equals arg1="${osbp.developer.home}" arg2="none"/> |
| </or> |
| </condition> |
| </fail> |
| <if> |
| <not> |
| <available file="${osbp.developer.home}" type="dir"/> |
| </not> |
| <then> |
| <mkdir dir="${osbp.developer.home}"/> |
| </then> |
| </if> |
| <if> |
| <not> |
| <available file="${osbp.developer.home.repositories}" type="dir"/> |
| </not> |
| <then> |
| <mkdir dir="${osbp.developer.home.repositories}"/> |
| </then> |
| </if> |
| <if> |
| <not> |
| <available file="${osbp.build.local.federated.p2.dir}" type="dir"/> |
| </not> |
| <then> |
| <mkdir dir="${osbp.build.local.federated.p2.dir}"/> |
| </then> |
| </if> |
| <groovy> |
| ant.echo "Extracted building templates..." |
| |
| def |
| separator = |
| "${properties['file.separator']}" |
| def directory = |
| "${properties['project.build.directory']}" + separator + |
| "templates" + separator |
| |
| new |
| File(directory).mkdir() |
| |
| def |
| encodedP2index = |
| "${properties['encoded.p2index']}" |
| def |
| encodedCompositeArtifacts = |
| "${properties['encoded.compositeArtifacts']}" |
| def |
| encodedCompositeContent = |
| "${properties['encoded.compositeContent']}" |
| |
| properties.p2indexFile = directory + "p2.index" |
| properties.compositeArtifactsFile = directory + |
| "compositeArtifacts.xml" |
| properties.compositeContentFile = |
| directory + "compositeContent.xml" |
| |
| new |
| FileOutputStream(properties.p2indexFile).write(encodedP2index.decodeBase64()) |
| new |
| FileOutputStream(properties.compositeArtifactsFile).write(encodedCompositeArtifacts.decodeBase64()) |
| new |
| FileOutputStream(properties.compositeContentFile).write(encodedCompositeContent.decodeBase64()) |
| |
| </groovy> |
| <echo message="** OSBP User Developer Home: ${osbp.developer.home}"/> |
| <echo message=" - index source: ${p2indexFile}"/> |
| <echo message=" - contentFile source: ${compositeContentFile}"/> |
| <echo message=" - artifactsFile source: ${compositeArtifactsFile}"/> |
| |
| <!-- generate.composite.p2.init --> |
| |
| <fail message="Could not find p2.index template at ${p2indexFile} !"> |
| <condition> |
| <not> |
| <available file="${p2indexFile}" type="file"/> |
| </not> |
| </condition> |
| </fail> |
| |
| <fail message="Could not find compositeContent.xml template at ${compositeContentFile} !"> |
| <condition> |
| <not> |
| <available file="${compositeContentFile}" type="file"/> |
| </not> |
| </condition> |
| </fail> |
| |
| <fail message="Could not find compositeArtifacts.xml template at ${compositeArtifactsFile} !"> |
| <condition> |
| <not> |
| <available file="${compositeArtifactsFile}" type="file"/> |
| </not> |
| </condition> |
| </fail> |
| |
| <!-- "deploy.generated.p2.to.composite.dir.init" --> |
| <echo message="Copying repo to Federated Repository !!!"/> |
| <echo message="Checking existence of log file at:'${osbp.stage.p2.log.file.path}'"/> |
| <if> |
| <available file="${osbp.stage.p2.log.file.path}" type="file"/> |
| <then> |
| <echo message="OPEN BUILD LOG"/> |
| <property file="${osbp.stage.p2.log.file.path}" prefix="old"/> |
| <echoproperties prefix="old."/> |
| </then> |
| <else> |
| <echo message="Log file was not found at: '${osbp.stage.p2.log.file.path}'"/> |
| </else> |
| </if> |
| |
| <!-- deploy.generated.p2.to.composite.dir.clean --> |
| <!-- remove an existent repository directory --> |
| <if> |
| <available file="${osbp.build.local.federated.p2.dir}${osbp.stage.p2.label}" type="dir"/> |
| <then> |
| <delete includeemptydirs="true" failonerror="false"> |
| <fileset includes="**/*" dir="${osbp.build.local.federated.p2.dir}${osbp.stage.p2.label}"/> |
| </delete> |
| <delete dir="${osbp.build.local.federated.p2.dir}${osbp.stage.p2.label}"/> |
| </then> |
| </if> |
| |
| <!-- deploy.generated.p2.to.composite.p2 --> |
| <!-- create the repository directory and copy files from the generated |
| P2 --> |
| <echo message="COPYING P2"/> |
| <if> |
| <available file="${osbp.stage.p2.origin.dir}" type="dir"/> |
| <then> |
| <mkdir dir="${osbp.stage.p2.target.dir}"/> |
| <copy todir="${osbp.stage.p2.target.dir}"> |
| <fileset dir="${osbp.stage.p2.origin.dir}" includes="**/*"/> |
| </copy> |
| <if> |
| <equals arg1="${osbp.stage.p2.keep.old}" arg2="false"/> |
| <then> |
| <propertyfile file="${osbp.stage.p2.log.file.path}" comment="Building log for ${osbp.build.eclipse.platform.name} - ${osbp.build.branch}"> |
| <entry key="build.counter" type="int" default="0" operation="+"/> |
| <entry key="build.date" type="date" value="now"/> |
| <entry key="osbp.stage.artifact.version" value="${osbp.stage.artifact.version}"/> |
| <entry key="osbp.stage.p2.target.dir" value="${osbp.stage.p2.target.dir}"/> |
| </propertyfile> |
| </then> |
| <else> |
| <propertyfile file="${osbp.stage.p2.log.file.path}" comment="Building log for ${osbp.build.eclipse.platform.name} - ${osbp.build.branch}"> |
| <entry key="build.counter" type="int" default="0" operation="+"/> |
| <entry key="build.date" type="date" value="now"/> |
| <entry key="osbp.build.local.federated.p2.dir" value="${osbp.build.local.federated.p2.dir}"/> |
| <entry key="osbp.stage.artifact.versions" default="" operation="+" value=",${osbp.stage.artifact.version}"/> |
| </propertyfile> |
| </else> |
| </if> |
| </then> |
| <else> |
| <fail message="The P2 repository was not generated in '${osbp.stage.p2.origin.dir}' !"/> |
| </else> |
| </if> |
| |
| <!-- start rebuilding... --> |
| <echo message="Rebuilding Federated Repository !!!"/> |
| <echo message=" (osbp.build.local.federated.p2.dir): ${osbp.build.local.federated.p2.dir}"/> |
| |
| <dirset id="dirs" dir="${osbp.build.local.federated.p2.dir}" includes="*/*"/> |
| |
| <fail message="There is no repositories to process !"> |
| <condition> |
| <resourcecount when="equal" count="0" refid="dirs"/> |
| </condition> |
| </fail> |
| |
| <if> |
| <available file="${osbp.build.local.federated.p2.dir}compositeContent.xml" type="file"/> |
| <then> |
| <echo message="DELETED OLD CONTENT FILE"/> |
| <delete file="${osbp.build.local.federated.p2.dir}compositeContent.xml"/> |
| </then> |
| </if> |
| <if> |
| <available file="${osbp.build.local.federated.p2.dir}compositeArtifacts.xml" type="file"/> |
| <then> |
| <echo message="DELETED OLD ARTIFACTS FILE"/> |
| <delete file="${osbp.build.local.federated.p2.dir}compositeArtifacts.xml"/> |
| </then> |
| </if> |
| |
| <!-- generate.composite.p2.add.compositeContentFile --> |
| <xmltask source="${compositeContentFile}" destbuffer="bufferCompositeContent" report="true"/> |
| <var name="counterContent" value="0"/> |
| <for param="child" list="${toString:dirs}" delimiter=";"> |
| <sequential> |
| <math result="counterContent" operand1="${counterContent}" operand2="1" operation="+" datatype="int"/> |
| <echo message="Adding Content Child @{child} - ${counterContent}"/> |
| <xmltask sourcebuffer="bufferCompositeContent" destbuffer="bufferCompositeContent"> |
| <insert path="/repository/children"> |
| <child location='@{child}' /> |
| </insert> |
| </xmltask> |
| </sequential> |
| </for> |
| <xmltask sourcebuffer="bufferCompositeContent" destbuffer="bufferCompositeContent"> |
| <replace path="/repository/children/@size" withText="${counterContent}"/> |
| </xmltask> |
| |
| <!-- generate.composite.p2.add.compositeArtifactsFile --> |
| <xmltask source="${compositeArtifactsFile}" destbuffer="bufferCompositeArtifacts" report="true"/> |
| <var name="counterArtifacts" value="0"/> |
| <for param="child" list="${toString:dirs}" delimiter=";"> |
| <sequential> |
| <math result="counterArtifacts" operand1="${counterArtifacts}" operand2="1" operation="+" datatype="int"/> |
| <echo message="Adding Artifact Child @{child} - ${counterArtifacts}"/> |
| <xmltask sourcebuffer="bufferCompositeArtifacts" destbuffer="bufferCompositeArtifacts"> |
| <insert path="/repository/children"> |
| <child location='@{child}' /> |
| </insert> |
| </xmltask> |
| </sequential> |
| </for> |
| <xmltask sourcebuffer="bufferCompositeArtifacts" destbuffer="bufferCompositeArtifacts"> |
| <replace path="/repository/children/@size" withText="${counterArtifacts}"/> |
| </xmltask> |
| |
| <!-- generate.composite.p2.add.p2.index.file --> |
| <if> |
| <not> |
| <available file="${osbp.build.local.federated.p2.dir}p2.index" type="file"/> |
| </not> |
| <then> |
| <copy file="${p2indexFile}" todir="${osbp.build.local.federated.p2.dir}"/> |
| </then> |
| </if> |
| |
| <!-- generate.composite.p2 --> |
| <echo message="CREATE COMPOSITE ARTIFACTS"/> |
| <xmltask sourcebuffer="bufferCompositeArtifacts" dest="${osbp.build.local.federated.p2.dir}compositeArtifacts.xml"/> |
| |
| <echo message="CREATE COMPOSITE CONTENT"/> |
| <xmltask sourcebuffer="bufferCompositeContent" dest="${osbp.build.local.federated.p2.dir}compositeContent.xml"/> |
| |
| <!-- end generation --> |
| |
| </target> |
| </configuration> |
| <goals> |
| <goal>run</goal> |
| </goals> |
| </execution> |
| </executions> |
| <dependencies> |
| <dependency> |
| <groupId>org.codehaus.groovy</groupId> |
| <artifactId>groovy-all</artifactId> |
| <version>${groovy-all.version}</version> |
| </dependency> |
| <dependency> |
| <groupId>org.apache.ant</groupId> |
| <artifactId>ant</artifactId> |
| <version>${ant-version}</version> |
| </dependency> |
| <dependency> |
| <groupId>ant-contrib</groupId> |
| <artifactId>ant-contrib</artifactId> |
| <version>1.0b3</version> |
| <exclusions> |
| <exclusion> |
| <groupId>ant</groupId> |
| <artifactId>ant</artifactId> |
| </exclusion> |
| </exclusions> |
| </dependency> |
| <dependency> |
| <groupId>net.sf.saxon</groupId> |
| <artifactId>Saxon-HE</artifactId> |
| <version>9.4</version> |
| </dependency> |
| <dependency> |
| <groupId>com.oopsconsultancy</groupId> |
| <artifactId>xmltask</artifactId> |
| <version>1.16</version> |
| </dependency> |
| </dependencies> |
| </plugin> |
| </plugins> |
| </build> |
| </profile> |
| <profile> |
| <!-- used for softwarefactory --> |
| <id>whenIsRepositoryP2Project.stage.p2</id> |
| <activation> |
| <file> |
| <exists>.osbp.releng.eclipse.p2</exists> |
| </file> |
| </activation> |
| <properties> |
| <!-- encoded files needed by ant task --> |
| <encoded.p2index>dmVyc2lvbiA9IDEKIG1ldGFkYXRhLnJlcG9zaXRvcnkuZmFjdG9yeS5vcmRlciA9IGNvbXBvc2l0ZUNvbnRlbnQueG1sLFwhCiBhcnRpZmFjdC5yZXBvc2l0b3J5LmZhY3Rvcnkub3JkZXIgPSBjb21wb3NpdGVBcnRpZmFjdHMueG1sLFwh</encoded.p2index> |
| <encoded.compositeArtifacts>PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4KPD9jb21wb3NpdGVBcnRpZmFjdFJlcG9zaXRvcnkgdmVyc2lvbj0nMS4wLjAnPz4KPHJlcG9zaXRvcnkgbmFtZT0nT1NCUCBQdWJsaWMgUDIgUmVwb3NpdG9yeScgdHlwZT0nb3JnLmVjbGlwc2UuZXF1aW5veC5pbnRlcm5hbC5wMi5hcnRpZmFjdC5yZXBvc2l0b3J5LkNvbXBvc2l0ZUFydGlmYWN0UmVwb3NpdG9yeScgdmVyc2lvbj0nMS4wLjAnPgogIDxwcm9wZXJ0aWVzIHNpemU9JzEnPgoJPHByb3BlcnR5IG5hbWU9J3AyLnRpbWVzdGFtcCcgdmFsdWU9JzEyNDM4MjI1MDI0NDAnLz4KICA8L3Byb3BlcnRpZXM+CiAgPGNoaWxkcmVuIHNpemU9JzAnPgkKICA8L2NoaWxkcmVuPgo8L3JlcG9zaXRvcnk+Cg==</encoded.compositeArtifacts> |
| <encoded.compositeContent>PD94bWwgdmVyc2lvbj0nMS4wJyBlbmNvZGluZz0nVVRGLTgnPz4KPD9jb21wb3NpdGVNZXRhZGF0YVJlcG9zaXRvcnkgdmVyc2lvbj0nMS4wLjAnPz4KPHJlcG9zaXRvcnkgbmFtZT0nT1NCUCBQdWJsaWMgUDIgUmVwb3NpdG9yeScgdHlwZT0nb3JnLmVjbGlwc2UuZXF1aW5veC5pbnRlcm5hbC5wMi5tZXRhZGF0YS5yZXBvc2l0b3J5LkNvbXBvc2l0ZU1ldGFkYXRhUmVwb3NpdG9yeScgdmVyc2lvbj0nMS4wLjAnPgogIDxwcm9wZXJ0aWVzIHNpemU9JzEnPgoJPHByb3BlcnR5IG5hbWU9J3AyLnRpbWVzdGFtcCcgdmFsdWU9JzEyNDM4MjI1MDI0OTknLz4KICA8L3Byb3BlcnRpZXM+CiAgPGNoaWxkcmVuIHNpemU9JzAnPgogIDwvY2hpbGRyZW4+CjwvcmVwb3NpdG9yeT4K</encoded.compositeContent> |
| |
| <osbp.build.local.federated.p2.dir>${osbp.stage.p2.target.dir.base}${file.separator}${osbp.build.branch}${file.separator}</osbp.build.local.federated.p2.dir> |
| |
| <osbp.stage.p2.log.file.path>${project.basedir}${file.separator}build.${osbp.stage.p2.label}.${osbp.build.eclipse.platform.name}.${osbp.build.branch}.log.properties</osbp.stage.p2.log.file.path> |
| <osbp.stage.p2.origin.dir>${project.build.directory}${file.separator}repository</osbp.stage.p2.origin.dir> |
| |
| <osbp.stage.p2.target.dir>${osbp.build.local.federated.p2.dir}${osbp.stage.p2.label}${file.separator}${osbp.stage.artifact.version}</osbp.stage.p2.target.dir> |
| </properties> |
| <pluginRepositories> |
| <pluginRepository> |
| <id>atlassian 3rd party</id> |
| <url>https://maven.atlassian.com/3rdparty/</url> |
| <snapshots> |
| <enabled>true</enabled> |
| <updatePolicy>never</updatePolicy> |
| <checksumPolicy>warn</checksumPolicy> |
| </snapshots> |
| <releases> |
| <enabled>true</enabled> |
| <checksumPolicy>warn</checksumPolicy> |
| </releases> |
| </pluginRepository> |
| <pluginRepository> |
| <id>atlassian 3rd party legacy</id> |
| <url>https://packages.atlassian.com/maven-3rdparty-legacy/</url> |
| <snapshots> |
| <enabled>true</enabled> |
| <updatePolicy>never</updatePolicy> |
| <checksumPolicy>warn</checksumPolicy> |
| </snapshots> |
| <releases> |
| <enabled>true</enabled> |
| <checksumPolicy>warn</checksumPolicy> |
| </releases> |
| </pluginRepository> |
| </pluginRepositories> |
| <repositories> |
| <repository> |
| <id>OSBP Technologystack Internal P2</id> |
| <url>${osbp.technologystack.p2}</url> |
| <layout>p2</layout> |
| </repository> |
| </repositories> |
| <build> |
| <plugins> |
| <plugin> |
| <artifactId>maven-antrun-plugin</artifactId> |
| <executions> |
| <execution> |
| <id>generate-files</id> |
| <phase>verify</phase> |
| <configuration> |
| <quiet>true</quiet> |
| <target> |
| <taskdef name="groovy" classname="org.codehaus.groovy.ant.Groovy"> |
| <classpath refid="maven.compile.classpath"/> |
| </taskdef> |
| <taskdef resource="net/sf/antcontrib/antlib.xml"/> |
| <taskdef resource="net/sf/antcontrib/antcontrib.properties"/> |
| <taskdef name="xmltask" classname="com.oopsconsultancy.xmltask.ant.XmlTask"/> |
| |
| <echo message="Federated Repository Local Dir (osbp.build.local.federated.p2.dir): ${osbp.build.local.federated.p2.dir}"/> |
| <echo message="Platform: ${osbp.build.eclipse.platform.name}"/> |
| <echo message="Build Type: ${osbp.build.branch}"/> |
| <echo message="Repo Name: ${osbp.stage.p2.label}"/> |
| <echo message="Repo Keep Old: ${osbp.stage.p2.keep.old}"/> |
| <echo message="Repo Version: ${osbp.stage.artifact.version}"/> |
| <echo message="Log File (osbp.stage.p2.log.file.path): ${osbp.stage.p2.log.file.path}"/> |
| <echo message="P2 Source Dir (osbp.stage.p2.origin.dir): ${osbp.stage.p2.origin.dir}"/> |
| <echo message="P2 Target Dir (osbp.stage.p2.target.dir): ${osbp.stage.p2.target.dir}"/> |
| |
| <!-- "init" --> |
| <fail message="There property 'osbp.developer.home' was not defined in settings.xml or in commandline."> |
| <condition> |
| <or> |
| <not> |
| <isset property="osbp.developer.home"/> |
| </not> |
| <equals arg1="${osbp.developer.home}" arg2="none"/> |
| </or> |
| </condition> |
| </fail> |
| <if> |
| <not> |
| <available file="${osbp.developer.home}" type="dir"/> |
| </not> |
| <then> |
| <mkdir dir="${osbp.developer.home}"/> |
| </then> |
| </if> |
| <if> |
| <not> |
| <available file="${osbp.developer.home.repositories}" type="dir"/> |
| </not> |
| <then> |
| <mkdir dir="${osbp.developer.home.repositories}"/> |
| </then> |
| </if> |
| <if> |
| <not> |
| <available file="${osbp.build.local.federated.p2.dir}" type="dir"/> |
| </not> |
| <then> |
| <mkdir dir="${osbp.build.local.federated.p2.dir}"/> |
| </then> |
| </if> |
| <groovy> |
| ant.echo "Extracted building templates..." |
| |
| def |
| separator = |
| "${properties['file.separator']}" |
| def directory = |
| "${properties['project.build.directory']}" + separator + |
| "templates" + separator |
| |
| new |
| File(directory).mkdir() |
| |
| def |
| encodedP2index = |
| "${properties['encoded.p2index']}" |
| def |
| encodedCompositeArtifacts = |
| "${properties['encoded.compositeArtifacts']}" |
| def |
| encodedCompositeContent = |
| "${properties['encoded.compositeContent']}" |
| |
| properties.p2indexFile = directory + "p2.index" |
| properties.compositeArtifactsFile = directory + |
| "compositeArtifacts.xml" |
| properties.compositeContentFile = |
| directory + "compositeContent.xml" |
| |
| new |
| FileOutputStream(properties.p2indexFile).write(encodedP2index.decodeBase64()) |
| new |
| FileOutputStream(properties.compositeArtifactsFile).write(encodedCompositeArtifacts.decodeBase64()) |
| new |
| FileOutputStream(properties.compositeContentFile).write(encodedCompositeContent.decodeBase64()) |
| |
| </groovy> |
| <echo message="** OSBP User Developer Home: ${osbp.developer.home}"/> |
| <echo message=" - index source: ${p2indexFile}"/> |
| <echo message=" - contentFile source: ${compositeContentFile}"/> |
| <echo message=" - artifactsFile source: ${compositeArtifactsFile}"/> |
| |
| <!-- generate.composite.p2.init --> |
| |
| <fail message="Could not find p2.index template at ${p2indexFile} !"> |
| <condition> |
| <not> |
| <available file="${p2indexFile}" type="file"/> |
| </not> |
| </condition> |
| </fail> |
| |
| <fail message="Could not find compositeContent.xml template at ${compositeContentFile} !"> |
| <condition> |
| <not> |
| <available file="${compositeContentFile}" type="file"/> |
| </not> |
| </condition> |
| </fail> |
| |
| <fail message="Could not find compositeArtifacts.xml template at ${compositeArtifactsFile} !"> |
| <condition> |
| <not> |
| <available file="${compositeArtifactsFile}" type="file"/> |
| </not> |
| </condition> |
| </fail> |
| |
| <!-- "deploy.generated.p2.to.composite.dir.init" --> |
| <echo message="Copying repo to Federated Repository !!!"/> |
| <echo message="Checking existence of log file at:'${osbp.stage.p2.log.file.path}'"/> |
| <if> |
| <available file="${osbp.stage.p2.log.file.path}" type="file"/> |
| <then> |
| <echo message="OPEN BUILD LOG"/> |
| <property file="${osbp.stage.p2.log.file.path}" prefix="old"/> |
| <echoproperties prefix="old."/> |
| </then> |
| <else> |
| <echo message="Log file was not found at: '${osbp.stage.p2.log.file.path}'"/> |
| </else> |
| </if> |
| |
| <!-- deploy.generated.p2.to.composite.dir.clean --> |
| <!-- remove an existent repository directory --> |
| <if> |
| <available file="${osbp.build.local.federated.p2.dir}${osbp.stage.p2.label}" type="dir"/> |
| <then> |
| <delete includeemptydirs="true" failonerror="false"> |
| <fileset includes="**/*" dir="${osbp.build.local.federated.p2.dir}${osbp.stage.p2.label}"/> |
| </delete> |
| <delete dir="${osbp.build.local.federated.p2.dir}${osbp.stage.p2.label}"/> |
| </then> |
| </if> |
| |
| <!-- deploy.generated.p2.to.composite.p2 --> |
| <!-- create the repository directory and copy files from the generated |
| P2 --> |
| <echo message="COPYING P2"/> |
| <if> |
| <available file="${osbp.stage.p2.origin.dir}" type="dir"/> |
| <then> |
| <mkdir dir="${osbp.stage.p2.target.dir}"/> |
| <copy todir="${osbp.stage.p2.target.dir}"> |
| <fileset dir="${osbp.stage.p2.origin.dir}" includes="**/*"/> |
| </copy> |
| <if> |
| <equals arg1="${osbp.stage.p2.keep.old}" arg2="false"/> |
| <then> |
| <propertyfile file="${osbp.stage.p2.log.file.path}" comment="Building log for ${osbp.build.eclipse.platform.name} - ${osbp.build.branch}"> |
| <entry key="build.counter" type="int" default="0" operation="+"/> |
| <entry key="build.date" type="date" value="now"/> |
| <entry key="osbp.stage.artifact.version" value="${osbp.stage.artifact.version}"/> |
| <entry key="osbp.stage.p2.target.dir" value="${osbp.stage.p2.target.dir}"/> |
| </propertyfile> |
| </then> |
| <else> |
| <propertyfile file="${osbp.stage.p2.log.file.path}" comment="Building log for ${osbp.build.eclipse.platform.name} - ${osbp.build.branch}"> |
| <entry key="build.counter" type="int" default="0" operation="+"/> |
| <entry key="build.date" type="date" value="now"/> |
| <entry key="osbp.build.local.federated.p2.dir" value="${osbp.build.local.federated.p2.dir}"/> |
| <entry key="osbp.stage.artifact.versions" default="" operation="+" value=",${osbp.stage.artifact.version}"/> |
| </propertyfile> |
| </else> |
| </if> |
| </then> |
| <else> |
| <fail message="The P2 repository was not generated in '${osbp.stage.p2.origin.dir}' !"/> |
| </else> |
| </if> |
| |
| <!-- start rebuilding... --> |
| <echo message="Rebuilding Federated Repository !!!"/> |
| <echo message=" (osbp.build.local.federated.p2.dir): ${osbp.build.local.federated.p2.dir}"/> |
| |
| <dirset id="dirs" dir="${osbp.build.local.federated.p2.dir}" includes="*/*"/> |
| |
| <fail message="There is no repositories to process !"> |
| <condition> |
| <resourcecount when="equal" count="0" refid="dirs"/> |
| </condition> |
| </fail> |
| |
| <if> |
| <available file="${osbp.build.local.federated.p2.dir}compositeContent.xml" type="file"/> |
| <then> |
| <echo message="DELETED OLD CONTENT FILE"/> |
| <delete file="${osbp.build.local.federated.p2.dir}compositeContent.xml"/> |
| </then> |
| </if> |
| <if> |
| <available file="${osbp.build.local.federated.p2.dir}compositeArtifacts.xml" type="file"/> |
| <then> |
| <echo message="DELETED OLD ARTIFACTS FILE"/> |
| <delete file="${osbp.build.local.federated.p2.dir}compositeArtifacts.xml"/> |
| </then> |
| </if> |
| |
| <!-- generate.composite.p2.add.compositeContentFile --> |
| <xmltask source="${compositeContentFile}" destbuffer="bufferCompositeContent" report="true"/> |
| <var name="counterContent" value="0"/> |
| <for param="child" list="${toString:dirs}" delimiter=";"> |
| <sequential> |
| <math result="counterContent" operand1="${counterContent}" operand2="1" operation="+" datatype="int"/> |
| <echo message="Adding Content Child @{child} - ${counterContent}"/> |
| <xmltask sourcebuffer="bufferCompositeContent" destbuffer="bufferCompositeContent"> |
| <insert path="/repository/children"> |
| <child location='@{child}' /> |
| </insert> |
| </xmltask> |
| </sequential> |
| </for> |
| <xmltask sourcebuffer="bufferCompositeContent" destbuffer="bufferCompositeContent"> |
| <replace path="/repository/children/@size" withText="${counterContent}"/> |
| </xmltask> |
| |
| <!-- generate.composite.p2.add.compositeArtifactsFile --> |
| <xmltask source="${compositeArtifactsFile}" destbuffer="bufferCompositeArtifacts" report="true"/> |
| <var name="counterArtifacts" value="0"/> |
| <for param="child" list="${toString:dirs}" delimiter=";"> |
| <sequential> |
| <math result="counterArtifacts" operand1="${counterArtifacts}" operand2="1" operation="+" datatype="int"/> |
| <echo message="Adding Artifact Child @{child} - ${counterArtifacts}"/> |
| <xmltask sourcebuffer="bufferCompositeArtifacts" destbuffer="bufferCompositeArtifacts"> |
| <insert path="/repository/children"> |
| <child location='@{child}' /> |
| </insert> |
| </xmltask> |
| </sequential> |
| </for> |
| <xmltask sourcebuffer="bufferCompositeArtifacts" destbuffer="bufferCompositeArtifacts"> |
| <replace path="/repository/children/@size" withText="${counterArtifacts}"/> |
| </xmltask> |
| |
| <!-- generate.composite.p2.add.p2.index.file --> |
| <if> |
| <not> |
| <available file="${osbp.build.local.federated.p2.dir}p2.index" type="file"/> |
| </not> |
| <then> |
| <copy file="${p2indexFile}" todir="${osbp.build.local.federated.p2.dir}"/> |
| </then> |
| </if> |
| |
| <!-- generate.composite.p2 --> |
| <echo message="CREATE COMPOSITE ARTIFACTS"/> |
| <xmltask sourcebuffer="bufferCompositeArtifacts" dest="${osbp.build.local.federated.p2.dir}compositeArtifacts.xml"/> |
| |
| <echo message="CREATE COMPOSITE CONTENT"/> |
| <xmltask sourcebuffer="bufferCompositeContent" dest="${osbp.build.local.federated.p2.dir}compositeContent.xml"/> |
| |
| <!-- end generation --> |
| |
| </target> |
| </configuration> |
| <goals> |
| <goal>run</goal> |
| </goals> |
| </execution> |
| </executions> |
| <dependencies> |
| <dependency> |
| <groupId>org.codehaus.groovy</groupId> |
| <artifactId>groovy-all</artifactId> |
| <version>${groovy-all.version}</version> |
| </dependency> |
| <dependency> |
| <groupId>org.apache.ant</groupId> |
| <artifactId>ant</artifactId> |
| <version>${ant-version}</version> |
| </dependency> |
| <dependency> |
| <groupId>ant-contrib</groupId> |
| <artifactId>ant-contrib</artifactId> |
| <version>1.0b3</version> |
| <exclusions> |
| <exclusion> |
| <groupId>ant</groupId> |
| <artifactId>ant</artifactId> |
| </exclusion> |
| </exclusions> |
| </dependency> |
| <dependency> |
| <groupId>net.sf.saxon</groupId> |
| <artifactId>Saxon-HE</artifactId> |
| <version>9.4</version> |
| </dependency> |
| <dependency> |
| <groupId>com.oopsconsultancy</groupId> |
| <artifactId>xmltask</artifactId> |
| <version>1.16</version> |
| </dependency> |
| </dependencies> |
| </plugin> |
| </plugins> |
| </build> |
| </profile> |
| |
| <profile> |
| <id>whenIsProductProject</id> |
| <activation> |
| <file> |
| <exists>.osbp.releng.eclipse.rcp</exists> |
| </file> |
| </activation> |
| <build> |
| <pluginManagement> |
| <plugins> |
| <plugin> |
| <groupId>org.eclipse.tycho</groupId> |
| <artifactId>tycho-p2-director-plugin</artifactId> |
| <version>${tycho-version}</version> |
| <executions> |
| <execution> |
| <!-- install the product for all configured os/ws/arch environments |
| using p2 director --> |
| <id>materialize-products</id> |
| <goals> |
| <goal>materialize-products</goal> |
| </goals> |
| </execution> |
| <execution> |
| <!-- (optional) create product zips (one per os/ws/arch) --> |
| <id>archive-products</id> |
| <goals> |
| <goal>archive-products</goal> |
| </goals> |
| <phase>pre-integration-test</phase> |
| </execution> |
| </executions> |
| <configuration> |
| <formats> |
| <win32>zip</win32> |
| <linux>tar.gz</linux> |
| <macosx>tar.gz</macosx> |
| </formats> |
| <products> |
| <product> |
| <id>${project.artifactId}</id> |
| <!-- <archiveFileName>Equinox-OSBPa-Standard-Node-${unqualifiedVersion}.${buildQualifier}</archiveFileName> --> |
| <!-- (optional) customize the root folder name of the product zip --> |
| <!-- <rootFolder>myServer</rootFolder> --> |
| </product> |
| </products> |
| </configuration> |
| </plugin> |
| </plugins> |
| </pluginManagement> |
| </build> |
| </profile> |
| |
| |
| <profile> |
| <!-- do static weaving to enable performant transactions across entity levels --> |
| <id>dostaticweaving</id> |
| <activation> |
| <file> |
| <exists>.doStaticWeaving</exists> |
| </file> |
| </activation> |
| <build> |
| <pluginManagement> |
| <plugins> |
| <!-- This plugin's configuration is used to store Eclipse m2e settings |
| only. It has no influence on the Maven build itself. --> |
| <plugin> |
| <groupId>org.eclipse.m2e</groupId> |
| <artifactId>lifecycle-mapping</artifactId> |
| <version>1.0.0</version> |
| <configuration> |
| <lifecycleMappingMetadata> |
| <pluginExecutions> |
| <pluginExecution> |
| <pluginExecutionFilter> |
| <groupId>de.empulse.eclipselink</groupId> |
| <artifactId>staticweave-maven-plugin</artifactId> |
| <versionRange>[1.0,)</versionRange> |
| <goals> |
| <goal>weave</goal> |
| </goals> |
| </pluginExecutionFilter> |
| <action> |
| <execute> |
| <runOnIncremental>true</runOnIncremental> |
| <runOnConfiguration>true</runOnConfiguration> |
| </execute> |
| </action> |
| </pluginExecution> |
| </pluginExecutions> |
| </lifecycleMappingMetadata> |
| </configuration> |
| </plugin> |
| </plugins> |
| </pluginManagement> |
| <plugins> |
| <plugin> |
| <groupId>de.empulse.eclipselink</groupId> |
| <artifactId>staticweave-maven-plugin</artifactId> |
| <version>1.0.0</version> |
| <executions> |
| <execution> |
| <!-- <?m2e execute onConfiguration,onIncremental?> --> |
| <phase>process-classes</phase> |
| <goals> |
| <goal>weave</goal> |
| </goals> |
| <configuration> |
| |
| <persistenceXMLLocation>../../META-INF/persistence.xml</persistenceXMLLocation> |
| <logLevel>FINE</logLevel> |
| </configuration> |
| </execution> |
| </executions> |
| <dependencies> |
| <dependency> |
| <groupId>org.eclipse.persistence</groupId> |
| <artifactId>org.eclipse.persistence.jpa</artifactId> |
| <version>2.6.1</version> |
| </dependency> |
| <dependency> |
| <groupId>org.eclipse.platform</groupId> |
| <artifactId>org.eclipse.core.runtime</artifactId> |
| <version>3.12.0</version> |
| </dependency> |
| <dependency> |
| <groupId>org.eclipse.osbp.dsl</groupId> |
| <artifactId>org.eclipse.osbp.dsl.datatype.lib</artifactId> |
| <version>0.9.0-SNAPSHOT</version> |
| </dependency> |
| <dependency> |
| <groupId>org.eclipse.osbp.dsl</groupId> |
| <artifactId>org.eclipse.osbp.dsl.dto.lib</artifactId> |
| <version>0.9.0-SNAPSHOT</version> |
| </dependency> |
| <dependency> |
| <groupId>org.eclipse.osbp.runtime</groupId> |
| <artifactId>org.eclipse.osbp.runtime.common</artifactId> |
| <version>0.9.0-SNAPSHOT</version> |
| </dependency> |
| </dependencies> |
| </plugin> |
| </plugins> |
| </build> |
| </profile> |
| <profile> |
| <!-- switch off jarsigner if not properly configured in settings.xml --> |
| <id>donotsign</id> |
| <activation> |
| <property> |
| |
| <name>!maven-jarsigner-plugin.keystore</name> |
| </property> |
| </activation> |
| <build> |
| <plugins> |
| <plugin> |
| <groupId>org.apache.maven.plugins</groupId> |
| <artifactId>maven-jarsigner-plugin</artifactId> |
| <configuration> |
| <skip>true</skip> |
| </configuration> |
| </plugin> |
| </plugins> |
| </build> |
| </profile> |
| <profile> |
| <id>sign</id> |
| <activation> |
| <file> |
| <missing>.osbp.releng.root</missing> |
| </file> |
| </activation> |
| <build> |
| <plugins> |
| <plugin> |
| <groupId>org.apache.maven.plugins</groupId> |
| <artifactId>maven-jarsigner-plugin</artifactId> |
| <configuration> |
| <verify>true</verify> |
| <storetype>jks</storetype> |
| <tsa>${maven-jarsigner-plugin.tsa}</tsa> |
| <keystore>${maven-jarsigner-plugin.keystore}</keystore> |
| <alias>${maven-jarsigner-plugin.alias}</alias> |
| <storepass>${maven-jarsigner-plugin.storepass}</storepass> |
| <removeExistingSignatures>true</removeExistingSignatures> |
| <verbose>true</verbose> |
| </configuration> |
| <executions> |
| <execution> |
| <id>sign</id> |
| <goals> |
| <goal>sign</goal> |
| </goals> |
| </execution> |
| <execution> |
| <id>verify</id> |
| <goals> |
| <goal>verify</goal> |
| </goals> |
| </execution> |
| </executions> |
| </plugin> |
| </plugins> |
| </build> |
| </profile> |
| </profiles> |
| |
| <build> |
| <sourceDirectory>src</sourceDirectory> |
| |
| <plugins> |
| <plugin> |
| <groupId>org.eclipse.tycho</groupId> |
| <artifactId>tycho-maven-plugin</artifactId> |
| </plugin> |
| |
| <plugin> |
| <groupId>org.eclipse.tycho</groupId> |
| <artifactId>tycho-compiler-plugin</artifactId> |
| </plugin> |
| |
| <plugin> |
| <groupId>org.eclipse.tycho</groupId> |
| <artifactId>target-platform-configuration</artifactId> |
| </plugin> |
| |
| <plugin> |
| <groupId>org.eclipse.tycho</groupId> |
| <artifactId>tycho-source-plugin</artifactId> |
| </plugin> |
| |
| <plugin> |
| <artifactId>maven-clean-plugin</artifactId> |
| <configuration> |
| <filesets> |
| <fileset> |
| <directory>xtend-gen</directory> |
| <includes> |
| <include>**</include> |
| </includes> |
| </fileset> |
| </filesets> |
| </configuration> |
| </plugin> |
| <plugin> |
| <groupId>org.eclipse.xtend</groupId> |
| <artifactId>xtend-maven-plugin</artifactId> |
| <dependencies> |
| <!-- due to https://github.com/eclipse/xtext/issues/1231 --> |
| <dependency> |
| <groupId>org.eclipse.platform</groupId> |
| <artifactId>org.eclipse.equinox.common</artifactId> |
| <version>3.10.0</version> |
| </dependency> |
| <dependency> |
| <groupId>org.eclipse.jdt</groupId> |
| <artifactId>org.eclipse.jdt.core</artifactId> |
| <version>3.12.2</version> |
| </dependency> |
| <dependency> |
| <groupId>org.eclipse.jdt</groupId> |
| <artifactId>org.eclipse.jdt.debug</artifactId> |
| <version>3.12.0</version> |
| </dependency> |
| <dependency> |
| <groupId>org.eclipse.jdt</groupId> |
| <artifactId>org.eclipse.jdt.launching</artifactId> |
| <version>3.11.0</version> |
| </dependency> |
| </dependencies> |
| <executions> |
| <execution> |
| <goals> |
| <goal>compile</goal> |
| <goal>testCompile</goal> |
| </goals> |
| <configuration> |
| <javaSourceVersion>1.7</javaSourceVersion> |
| <writeTraceFiles>false</writeTraceFiles> |
| <outputDirectory>xtend-gen</outputDirectory> |
| </configuration> |
| </execution> |
| </executions> |
| </plugin> |
| </plugins> |
| |
| <pluginManagement> |
| <plugins> |
| <!-- enable tycho build --> |
| <plugin> |
| <groupId>org.eclipse.tycho</groupId> |
| <artifactId>tycho-maven-plugin</artifactId> |
| <version>${tycho-version}</version> |
| <extensions>true</extensions> |
| <configuration> |
| <localArtifacts>ignore</localArtifacts> |
| </configuration> |
| |
| </plugin> |
| <plugin> |
| <groupId>org.eclipse.tycho</groupId> |
| <artifactId>tycho-compiler-plugin</artifactId> |
| <version>${tycho-version}</version> |
| <configuration> |
| <compilerVersion>1.8</compilerVersion> |
| <encoding>UTF-8</encoding> |
| <source>1.8</source> |
| <target>1.8</target> |
| </configuration> |
| </plugin> |
| <plugin> |
| <groupId>org.eclipse.tycho</groupId> |
| <artifactId>target-platform-configuration</artifactId> |
| <version>${tycho-version}</version> |
| <configuration> |
| <resolver>p2</resolver> |
| <pomDependencies>consider</pomDependencies> |
| </configuration> |
| </plugin> |
| <plugin> |
| <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> |
| </executions> |
| </plugin> |
| <plugin> |
| <groupId>org.eclipse.tycho</groupId> |
| <artifactId>tycho-surefire-plugin</artifactId> |
| <version>${tycho-version}</version> |
| <configuration> |
| <includes> |
| <include>**/*Tests.java</include> |
| </includes> |
| <showEclipseLog>true</showEclipseLog> |
| <useUIHarness>false</useUIHarness> |
| <useUIThread>false</useUIThread> |
| <failIfNoTests>false</failIfNoTests> |
| <!-- <appArgLine>-Dfile.encoding=UTF-8</appArgLine> --> |
| <argLine>${jacoco.agent.it.arg}</argLine> |
| <!-- Kill test JVM if tests take more than 10 minutes (600 seconds) |
| to finish --> |
| <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds> |
| </configuration> |
| </plugin> |
| <plugin> |
| <groupId>org.codehaus.mojo</groupId> |
| <artifactId>build-helper-maven-plugin</artifactId> |
| <executions> |
| <execution> |
| <id>add-source</id> |
| <phase>initialize</phase> |
| <goals> |
| <goal>add-source</goal> |
| </goals> |
| <configuration> |
| <sources> |
| <source>src-gen</source> |
| <source>xtend-gen</source> |
| <source>emf-gen</source> |
| </sources> |
| </configuration> |
| </execution> |
| </executions> |
| </plugin> |
| <plugin> |
| <groupId>org.eclipse.xtend</groupId> |
| <artifactId>xtend-maven-plugin</artifactId> |
| <version>${xtext.version}</version> |
| <dependencies> |
| <!-- due to https://github.com/eclipse/xtext/issues/1231 --> |
| <dependency> |
| <groupId>org.eclipse.platform</groupId> |
| <artifactId>org.eclipse.equinox.common</artifactId> |
| <version>3.10.0</version> |
| </dependency> |
| <dependency> |
| <groupId>org.eclipse.jdt</groupId> |
| <artifactId>org.eclipse.jdt.core</artifactId> |
| <version>3.12.2</version> |
| </dependency> |
| <dependency> |
| <groupId>org.eclipse.jdt</groupId> |
| <artifactId>org.eclipse.jdt.debug</artifactId> |
| <version>3.12.0</version> |
| </dependency> |
| <dependency> |
| <groupId>org.eclipse.jdt</groupId> |
| <artifactId>org.eclipse.jdt.launching</artifactId> |
| <version>3.11.0</version> |
| </dependency> |
| </dependencies> |
| <executions> |
| <execution> |
| <goals> |
| <goal>compile</goal> |
| <goal>xtend-install-debug-info</goal> |
| <goal>testCompile</goal> |
| <goal>xtend-test-install-debug-info</goal> |
| </goals> |
| </execution> |
| </executions> |
| <configuration> |
| <javaSourceVersion>1.7</javaSourceVersion> |
| <writeTraceFiles>false</writeTraceFiles> |
| <outputDirectory>xtend-gen</outputDirectory> |
| </configuration> |
| </plugin> |
| <plugin> |
| <groupId>pl.project13.maven</groupId> |
| <artifactId>git-commit-id-plugin</artifactId> |
| <version>2.2.0</version> |
| <executions> |
| <execution> |
| <goals> |
| <goal>revision</goal> |
| </goals> |
| </execution> |
| </executions> |
| |
| </plugin> |
| |
| </plugins> |
| </pluginManagement> |
| </build> |
| <dependencies> |
| <dependency> |
| <groupId>org.eclipse.osbp.releng.maven</groupId> |
| <artifactId>org.eclipse.osbp.releng.maven.licenses</artifactId> |
| <version>0.9.0-SNAPSHOT</version> |
| <!-- <classifier>third-party</classifier> --> |
| <!-- <type>properties</type> --> |
| <!-- <scope>provided</scope> --> |
| </dependency> |
| </dependencies> |
| </project> |