blob: 92db32b98ee6ebd721a5a7693fefee9603d11193 [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8"?>
<project name="build-nano" xmlns:ivy="antlib:org.apache.ivy.ant">
<path id="bundles">
</path>
<property file="${basedir}/../build.properties" />
<property file="${basedir}/../build.versions" />
<import file="${basedir}/../virgo-build/multi-bundle/default.xml" />
<property name="nano-full-package" value="virgo-nano-full" />
<property name="nano-package" value="virgo-nano" />
<property name="nano-rap-package" value="virgo-nano-rap" />
<property name="nano.basedir" value="${basedir}/nano" />
<!-- package-bundles-and-features -->
<target name="nano.prepare-bundles-and-features">
<!-- Copy the nano kernel artifacts to a prepared for publishing location - a p2 repo will be built around them -->
<ivy:resolve resolveId="copy.path" file="${nano.basedir}/nano-ivy.xml" transitive="false" />
<ivy:retrieve resolveId="copy.path" pattern="${nano.target.dir}/assembly/plugins/[artifact]_[revision].[ext]" conf="nano-runtime" type="jar" />
<ivy:retrieve resolveId="copy.path" pattern="${nano.target.dir}/assembly/plugins/[artifact]_[revision].[ext]" conf="nano-runtime" type="wab" />
<ivy:resolve resolveId="copy.path" file="${nano.basedir}/p2runtime-ivy.xml" transitive="true" />
<ivy:retrieve resolveId="copy.path" pattern="${nano.target.dir}/assembly/plugins/[artifact]_[revision].[ext]" conf="p2-runtime" type="jar" />
<ivy:resolve resolveId="copy.path" file="${nano.basedir}/gemini-web-ivy.xml" transitive="false" />
<ivy:retrieve resolveId="copy.path" pattern="${nano.target.dir}/assembly/plugins/[artifact]_[revision].[ext]" conf="gemini-web" type="jar" />
<ivy:resolve resolveId="copy.path" file="${nano.basedir}/enterprise-ivy.xml" transitive="false" />
<ivy:retrieve resolveId="copy.path" pattern="${nano.target.dir}/assembly/plugins/[artifact]_[revision].[ext]" conf="enterprise" type="jar" />
<!-- Prepare the features for publishing -->
<copy todir="${nano.target.dir}/assembly/features" failonerror="false">
<fileset dir="${nano.basedir}/publish_resources/features" excludes="keystore" />
<filterset>
<filter token="OSGI" value="${org.eclipse.osgi}" />
<filter token="ASPECTJ" value="${org.aspectj}" />
<filter token="JAVAX.ACTIVATION" value="${javax.activation}" />
<filter token="JAVAX.TRANSACTION" value="${javax.transaction}" />
<filter token="JAVAX.ANNOTATION" value="${javax.annotation}" />
<filter token="JAVAX.EJB" value="${javax.ejb}" />
<filter token="JAVAX.EL" value="${javax.el}" />
<filter token="JAVAX.MAIL" value="${javax.mail}" />
<filter token="JAVAX.PERSISTENCE" value="${javax.persistence}" />
<filter token="JAVAX.SERVLET" value="${javax.servlet}" />
<filter token="JAVAX.SERVLET.JSP" value="${javax.servlet.jsp}" />
<filter token="JAVAX.XML.RPC" value="${javax.xml.rpc}" />
<filter token="CATALINA" value="${org.apache.catalina}" />
<filter token="CATALINA.HA" value="${org.apache.catalina.ha}" />
<filter token="JASPER.VERSION" value="${org.apache.jasper}" />
<filter token="TRIBES.VERSION" value="${org.apache.catalina.tribes}" />
<filter token="COYOTE" value="${org.apache.coyote}" />
<filter token="EL" value="${org.apache.el}" />
<filter token="JULI.EXTRAS" value="${org.apache.juli.extras}" />
<filter token="TOMCAT.API" value="${org.apache.tomcat.api}" />
<filter token="TOMCAT.UTIL" value="${org.apache.tomcat.util}" />
<filter token="EQUINOX.CM" value="${org.eclipse.equinox.cm}" />
<filter token="EQUINOX.EVENT" value="${org.eclipse.equinox.event}" />
<filter token="EQUINOX.REGION" value="${org.eclipse.equinox.region}" />
<filter token="EQUINOX.UTIL" value="${org.eclipse.equinox.util}" />
<filter token="COMPILER.BATCH" value="${org.eclipse.jdt.core.compiler.batch}" />
<filter token="OSGI.SERVICES" value="${org.eclipse.osgi.services}" />
<filter token="SAT4J.CORE" value="${org.sat4j.core}" />
<filter token="SAT4J.PB" value="${org.sat4j.pb}" />
<filter token="SLF4J.API" value="${org.slf4j.api}" />
<filter token="SLF4J.JUL" value="${org.slf4j.jul}" />
<filter token="EQUINOX.CONSOLE.VERSION" value="${org.eclipse.equinox.console}" />
<filter token="EQUINOX.DS.VERSION" value="${org.eclipse.equinox.ds}" />
<filter token="FELIX.GOGO.SHELL.VERSION" value="${org.apache.felix.gogo.shell}" />
<filter token="FELIX.GOGO.COMMAND.VERSION" value="${org.apache.felix.gogo.command}" />
<filter token="FELIX.GOGO.RUNTIME.VERSION" value="${org.apache.felix.gogo.runtime}" />
<filter token="GEMINI.WEB" value="${org.eclipse.gemini.web}" />
<filter token="MEDIC.VERSION" value="${org.eclipse.virgo.medic}" />
<filter token="MINA.CORE.VERSION" value="${org.apache.mina.core}" />
<filter token="NANO.VERSION" value="${org.eclipse.virgo.nano}" />
<filter token="WEB.VERSION" value="${org.eclipse.virgo.web}" />
<filter token="SPRING.DM.VERSION" value="${org.eclipse.gemini.blueprint}" />
<filter token="SSHD.CORE.VERSION" value="${org.apache.sshd.core}" />
<filter token="UTIL.VERSION" value="${org.eclipse.virgo.util}" />
<filter token="KERNEL.VERSION" value="${org.eclipse.virgo.kernel}" />
<filter token="CONTENTTYPE.VERSION" value="${org.eclipse.core.contenttype}" />
<filter token="CORE.VERSION" value="${org.eclipse.core.runtime}" />
<filter token="CORE.NET.VERSION" value="${org.eclipse.core.net}" />
<filter token="ECF.FT.VERSION" value="${org.eclipse.ecf.filetransfer}" />
<filter token="ECF.I.VERSION" value="${org.eclipse.ecf.identity}" />
<filter token="ECF.P.FT.VERSION" value="${org.eclipse.ecf.provider.filetransfer}" />
<filter token="ECF.SSL.VERSION" value="${org.eclipse.ecf.ssl}" />
<filter token="ECF.VERSION" value="${org.eclipse.ecf}" />
<filter token="EQUINOX.APP.VERSION" value="${org.eclipse.equinox.app}" />
<filter token="EQUINOX.COMMON.VERSION" value="${org.eclipse.equinox.common}" />
<filter token="EQUINOX.CONSOLE.SSH.VERSION" value="${org.eclipse.equinox.console.ssh}" />
<filter token="EQUINOX.FRKA.E.VERSION" value="${org.eclipse.equinox.frameworkadmin.equinox}" />
<filter token="EQUINOX.FRKA.VERSION" value="${org.eclipse.equinox.frameworkadmin}" />
<filter token="EQUINOX.PFRCS.VERSION" value="${org.eclipse.equinox.preferences}" />
<filter token="EQUINOX.REGISTRY.VERSION" value="${org.eclipse.equinox.registry}" />
<filter token="EQUINOX.SC.M.VERSION" value="${org.eclipse.equinox.simpleconfigurator.manipulator}" />
<filter token="EQUINOX.SC.VERSION" value="${org.eclipse.equinox.simpleconfigurator}" />
<filter token="EQUINOX.SECURITY.VERSION" value="${org.eclipse.equinox.security}" />
<filter token="JOBS.VERSION" value="${org.eclipse.core.jobs}" />
<filter token="LOGBACK.CLASSIC.VERSION" value="${ch.qos.logback.classic}" />
<filter token="LOGBACK.CORE.VERSION" value="${ch.qos.logback.core}" />
<filter token="LOGBACK.SLF4J.VERSION" value="${ch.qos.logback.slf4j}" />
<filter token="P2.A.R.VERSION" value="${org.eclipse.equinox.p2.artifact.repository}" />
<filter token="P2.CONSOLE.VERSION" value="${org.eclipse.equinox.p2.console}" />
<filter token="P2.CORE.VERSION" value="${org.eclipse.equinox.p2.core}" />
<filter token="P2.DIRECTOR.VERSION" value="${org.eclipse.equinox.p2.director}" />
<filter token="P2.ENGINE.VERSION" value="${org.eclipse.equinox.p2.engine}" />
<filter token="P2.GC.VERSION" value="${org.eclipse.equinox.p2.garbagecollector}" />
<filter token="P2.JP.VERSION" value="${org.eclipse.equinox.p2.jarprocessor}" />
<filter token="P2.M.R.VERSION" value="${org.eclipse.equinox.p2.metadata.repository}" />
<filter token="P2.METADATA.VERSION" value="${org.eclipse.equinox.p2.metadata}" />
<filter token="P2.P.E.VERSION" value="${org.eclipse.equinox.p2.publisher.eclipse}" />
<filter token="P2.PUBLISHER.VERSION" value="${org.eclipse.equinox.p2.publisher}" />
<filter token="P2.REPOSITORY.VERSION" value="${org.eclipse.equinox.p2.repository}" />
<filter token="P2.T.E.VERSION" value="${org.eclipse.equinox.p2.touchpoint.eclipse}" />
<filter token="P2.T.ECF.VERSION" value="${org.eclipse.equinox.p2.transport.ecf}" />
<filter token="P2.T.N.VERSION" value="${org.eclipse.equinox.p2.touchpoint.natives}" />
<filter token="JAVASSIST" value="${javassist.feature}" />
<filter token="JAVAX.JMS" value="${javax.jms}" />
<filter token="JSTL.IMPL" value="${javax.servlet.jsp.jstl.impl}" />
<filter token="JSTL.API" value="${javax.servlet.jsp.jstl.api}" />
<filter token="JAVAX.VALIDATION" value="${javax.validation.feature}" />
<filter token="JAVAX.WS.RS" value="${javax.ws.rs}" />
<filter token="SLF4J.JCL" value="${org.slf4j.jcl}" />
<filter token="SLF4J.LOG4J" value="${org.slf4j.log4j}" />
<filter token="QUARTZ" value="${org.quartz}" />
<filter token="WB.COMMON" value="${org.apache.openwebbeans.ee.common}" />
<filter token="WB.EE" value="${org.apache.openwebbeans.ee}" />
<filter token="WB.EJB" value="${org.apache.openwebbeans.ejb}" />
<filter token="WB.IMPL" value="${org.apache.openwebbeans.impl}" />
<filter token="WB.SPI" value="${org.apache.openwebbeans.spi}" />
<filter token="WB.WEB" value="${org.apache.openwebbeans.web}" />
<filter token="WB.JSF" value="${org.apache.openwebbeans.jsf}" />
<filter token="WB.TOMCAT7" value="${org.apache.openwebbeans.tomcat7}" />
<filter token="COMMOMS.BEANUTILS" value="${org.apache.commons.beanutils}" />
<filter token="COMMONS.CLI" value="${org.apache.commons.cli}" />
<filter token="COMMONS.COLLECTIONS" value="${org.apache.commons.collections}" />
<filter token="COMMONS.DBCP" value="${org.apache.commons.dbcp}" />
<filter token="COMMONS.LANG" value="${org.apache.commons.lang}" />
<filter token="COMMONS.POOL" value="${org.apache.commons.pool}" />
<filter token="DERBY" value="${org.apache.derby.feature}" />
<filter token="BVAL" value="${org.apache.bval}" />
<filter token="G.CONNECTOR" value="${org.apache.geronimo.components.connector}" />
<filter token="G.TRANSACTIONS" value="${org.apache.geronimo.components.transaction}" />
<filter token="G.MANAGEMENT" value="${org.apache.geronimo.specs.j2ee.management}" />
<filter token="G.OSGI.LOCATOR" value="${org.apache.geronimo.specs.osgi.locator}" />
<filter token="G.OSGI.REGISTRY" value="${org.apache.geronimo.specs.osgi.registry}" />
<filter token="CDI.API" value="${cdi.api}" />
<filter token="OE.API" value="${org.apache.openejb.api.feature}" />
<filter token="OE.CORE" value="${org.apache.openejb.core.feature}" />
<filter token="OE.JAVAAGENT" value="${org.apache.openejb.javaagent.feature}" />
<filter token="OE.JEE" value="${org.apache.openejb.jee.feature}" />
<filter token="OE.LOADER" value="${org.apache.openejb.loader.feature}" />
<filter token="OE.JPA.INTEGRATION" value="${org.apache.openejb.jpa-integration.feature}" />
<filter token="JAVAX.WSDL" value="${javax.wsdl}" />
<filter token="XB.ASM" value="${org.apache.xbean.asm}" />
<filter token="XB.BUNDLEUTILS" value="${org.apache.xbean.bundleutils}" />
<filter token="XB.FINDER" value="${org.apache.xbean.finder}" />
<filter token="XB.NAMING" value="${org.apache.xbean.naming}" />
<filter token="XB.REFLECT" value="${org.apache.xbean.reflect}" />
<filter token="GEMINI.JPA" value="${org.eclipse.gemini.jpa}" />
<filter token="EL.ANTLR" value="${org.eclipse.persistence.antlr}" />
<filter token="EL.ASM" value="${org.eclipse.persistence.asm}" />
<filter token="EL.CORE" value="${org.eclipse.persistence.core}" />
<filter token="EL.JPA" value="${org.eclipse.persistence.jpa}" />
<filter token="EL.JPQL" value="${org.eclipse.persistence.jpa.jpql}" />
<filter token="FACES.IMPL" value="${org.glassfish.com.sun.faces}" />
<filter token="FACES.API" value="${org.glassfish.javax.faces}" />
<filter token="JAVAX.INJECT" value="${javax.inject}" />
<filter token="JAVAX.RESOURCE" value="${javax.resource}" />
<filter token="JAVAX.SECURITY.AUTH" value="${javax.security.auth.message}" />
<filter token="JAVAX.SECURITY.JACC" value="${javax.security.jacc}" />
<filter token="JOTM" value="${org.ow2.jotm.jotm-core}" />
<filter token="OSGI.ENTERPRISE" value="${osgi.enterprise}" />
<filter token="SCANNOTATION" value="${scannotation}" />
<filter token="JAVAX.EJB" value="${javax.ejb}" />
<filter token="HTTPSERVICE.VERSION" value="${org.eclipse.equinox.http}" />
<filter token="MNGMNT.CONSOLE.VERSION" value="${org.eclipse.virgo.kernel}" />
<filter token="GMNGMNT.VERSION" value="${org.eclipse.gemini.management}" />
<filter token="VIRGO.MNGMNT.FR.VERSION" value="${org.eclipse.virgo.kernel}" />
<filter token="C.FILEUPLOAD.VERSION" value="${org.apache.commons.fileupload}" />
<filter token="C.IO.VERSION" value="${org.apache.commons.io}" />
<filter token="JOLOKIA.VERSION" value="${org.jolokia.osgi}" />
<filter token="OBJECTWEB.ASM" value="${org.objectweb.asm}" />
<filter token="JETTY.RAP.VERSION" value="${org.eclipse.jetty.rap}" />
<filter token="RAP.RWT.VERSION" value="${org.eclipse.rap.rwt}" />
<filter token="RAP.RWT.OSGI.VERSION" value="${org.eclipse.rap.rwt.osgi}" />
<filter token="RAP.JFACE.VERSION" value="${org.eclipse.rap.jface}" />
<filter token="RAP.JFACE.DATABINDING.VERSION" value="${org.eclipse.rap.jface.databinding}" />
</filterset>
</copy>
<!--prepare Jetty and RAP bundles for publishing -->
<copy todir="${nano.target.dir}/assembly/plugins" failonerror="false">
<fileset dir="${nano.basedir}/rapbundles" />
</copy>
</target>
<target name="nano.publish-bundles-and-features">
<antcall target="p2.generate-inf">
<param name="source" value="${nano.target.dir}/assembly/features" />
</antcall>
<antcall target="p2.publish-bundles-features">
<param name="repository" value="${p2.repository.dir}" />
<param name="source" value="${nano.target.dir}/assembly" />
</antcall>
<echo message="Published Virgo Nano Server bundles and features to ${p2.repository.dir}." />
</target>
<!-- package resources and products -->
<target name="nano.package-resources-and-products" depends="ivy.init">
<property name="common.resources.location" value="${nano.target.dir}/common_resources_zipped" />
<property name="specific.resources.location" value="${nano.target.dir}/specific_resources_zipped" />
<property name="enterprise.resources.location" value="${nano.target.dir}/enterprise_resources_zipped" />
<property name="scripts.location" value="${nano.target.dir}/scripts_zipped" />
<antcall target="prepare-common-resources" />
<antcall target="prepare-specific-resources" />
<antcall target="prepare-enterprise-resources" />
<antcall target="prepare-scripts" />
<antcall target="publish-resources-and-products" />
</target>
<target name="prepare-common-resources">
<property name="common.resources" value="${nano.target.dir}/common_resources" />
<ivy:resolve resolveId="copy.path" file="${nano.basedir}/lib-ivy.xml" transitive="true" />
<ivy:retrieve resolveId="copy.path" pattern="${common.resources}/lib/[artifact]_[revision].[ext]" conf="lib" type="jar" />
<property name="common.resources" value="${nano.target.dir}/common_resources" />
<ivy:resolve resolveId="copy.path" file="${nano.basedir}/endorsed-ivy.xml" transitive="false" />
<ivy:retrieve resolveId="copy.path" pattern="${common.resources}/lib/endorsed/[artifact]_[revision].[ext]" conf="endorsed" type="jar" />
<property name="common.resources" value="${nano.target.dir}/common_resources" />
<ivy:resolve resolveId="copy.path" file="${nano.basedir}/lib-ivy.xml" transitive="false" />
<ivy:retrieve resolveId="copy.path" pattern="${common.resources}/lib/persistence/[artifact]_[revision].[ext]" conf="persistence" type="jar" />
<mkdir dir="${common.resources}/configuration" />
<mkdir dir="${common.resources}/pickup" />
<copy todir="${common.resources}" failonerror="false">
<fileset dir="${nano.basedir}/resources" />
</copy>
<copy todir="${common.resources}/configuration" failonerror="false">
<fileset dir="${nano.basedir}/configuration" excludes="keystore,serviceability.xml" />
</copy>
<copy file="${nano.basedir}/configuration/keystore" todir="${common.resources}/configuration" failonerror="false" />
<mkdir dir="${common.resources.location}/binary" />
<zip destfile="${common.resources.location}/binary/nano_common_resources">
<zipfileset dir="${common.resources}" />
</zip>
<delete dir="${common.resources}" quiet="true" />
</target>
<target name="prepare-specific-resources">
<property name="specific.resources" value="${nano.target.dir}/specific_resources" />
<mkdir dir="${specific.resources}/lib" />
<echo file="${specific.resources}/lib/.version" message="virgo.nano.version=${bundle.version}&#xa;" />
<copy todir="${specific.resources}/configuration" failonerror="false">
<fileset dir="${nano.basedir}/configuration">
<include name="serviceability.xml" />
</fileset>
</copy>
<!-- Package the Web Admin Console in both Nano's -->
<ivy:resolve resolveId="copy.path" file="${nano.basedir}/pickup-ivy.xml" transitive="true" />
<ivy:retrieve resolveId="copy.path" pattern="${specific.resources}/pickup/[artifact]_[revision].[ext]" type="jar, war, wab" conf="pickup" />
<mkdir dir="${specific.resources.location}/binary" />
<zip destfile="${specific.resources.location}/binary/nano_specific_resources">
<zipfileset dir="${specific.resources}" />
</zip>
<delete dir="${specific.resources}" quiet="true" />
</target>
<target name="prepare-enterprise-resources">
<property name="enterprise.resources" value="${nano.target.dir}/enterprise_resources" />
<mkdir dir="${enterprise.resources}/configuration" />
<copy todir="${enterprise.resources}/configuration" failonerror="false">
<fileset dir="${nano.basedir}/enterprise_resources" />
</copy>
<copy file="${nano.basedir}/abouts/AboutNanoWeb.html" todir="${enterprise.resources}" failonerror="false" />
<mkdir dir="${enterprise.resources.location}/binary" />
<zip destfile="${enterprise.resources.location}/binary/nano_enterprise_resources">
<zipfileset dir="${enterprise.resources}" />
</zip>
<delete dir="${enterprise.resources}" quiet="true" />
</target>
<target name="prepare-scripts">
<property name="scripts" value="${nano.target.dir}/scripts" />
<copy todir="${scripts}/bin" failonerror="false">
<fileset dir="${nano.basedir}/bin" />
</copy>
<mkdir dir="${scripts.location}/binary" />
<zip destfile="${scripts.location}/binary/scripts">
<zipfileset dir="${scripts}" />
</zip>
<delete dir="${scripts}" quiet="true" />
</target>
<target name="publish-resources-and-products">
<property name="p2.products.location" value="${nano.basedir}/publish_resources/products" />
<antcall target="p2.publish-binary-chmod">
<param name="repository" value="${p2.repository.dir}" />
<param name="source" value="${common.resources.location}" />
<param name="chmod.args" value="org.eclipse.virgo.kernel.jmxremote.access.properties@/configuration#600" />
</antcall>
<echo message="Published the commons resources to ${p2.repository.dir}." />
<antcall target="p2.publish-binary-chmod">
<param name="repository" value="${p2.repository.dir}" />
<param name="source" value="${scripts.location}" />
<param name="chmod.args" value="startup.sh@/bin#755,dmk.sh@/bin#755,checkJava.sh@/bin#755,jconsole.sh@/bin#755,setupClasspath.sh@/bin#755,shutdown.sh@/bin#755" />
</antcall>
<echo message="Published the scripts to ${p2.repository.dir}." />
<antcall target="p2.publish-binary">
<param name="repository" value="${p2.repository.dir}" />
<param name="source" value="${enterprise.resources.location}" />
</antcall>
<echo message="Published the nano enterprise resources to ${p2.repository.dir}." />
<antcall target="p2.publish-binary">
<param name="repository" value="${p2.repository.dir}" />
<param name="source" value="${specific.resources.location}" />
</antcall>
<echo message="Published the specific resources to ${p2.repository.dir}." />
<antcall target="p2.publish-product">
<param name="repository" value="${p2.repository.dir}" />
<param name="product.file.location" value="${p2.products.location}/base/base.product" />
</antcall>
<echo message="Published base product to ${p2.repository.dir}." />
<antcall target="p2.publish-product">
<param name="repository" value="${p2.repository.dir}" />
<param name="product.file.location" value="${p2.products.location}/nano-base/nano-base.product" />
</antcall>
<echo message="Published nano-base product to ${p2.repository.dir}." />
<antcall target="p2.publish-product">
<param name="repository" value="${p2.repository.dir}" />
<param name="product.file.location" value="${p2.products.location}/nano/nano.product" />
</antcall>
<echo message="Published nano product to ${p2.repository.dir}." />
<antcall target="p2.publish-product">
<param name="repository" value="${p2.repository.dir}" />
<param name="product.file.location" value="${p2.products.location}/nano-full/nano-full.product" />
</antcall>
<echo message="Published nano-full product to ${p2.repository.dir}." />
<antcall target="p2.publish-product">
<param name="repository" value="${p2.repository.dir}" />
<param name="product.file.location" value="${p2.products.location}/nano-rap/nano-rap.product" />
</antcall>
<echo message="Published nano-rap product to ${p2.repository.dir}." />
</target>
<!-- package distros -->
<target name="nano.package-distros" depends="ivy.init">
<antcall target="install-packages" />
<antcall target="assemble-zips" />
</target>
<target name="install-packages">
<antcall target="p2.install-virgo-product">
<param name="repository" value="${p2.repository.dir}" />
<param name="destination" value="${package.dir}/VN/${nano-package}-${bundle.version}" />
<param name="product.iu" value="nano.product" />
</antcall>
<echo message="Installed Virgo Nano for distribution purposes." />
<antcall target="p2.install-virgo-product">
<param name="repository" value="${p2.repository.dir}" />
<param name="destination" value="${package.dir}/VNF/${nano-full-package}-${bundle.version}" />
<param name="product.iu" value="nano-full.product" />
</antcall>
<echo message="Installed Virgo Nano Full for distribution purposes." />
<antcall target="p2.install-virgo-product">
<param name="repository" value="${p2.repository.dir}" />
<param name="destination" value="${package.dir}/VNR/${nano-rap-package}-${bundle.version}" />
<param name="product.iu" value="nano-rap.product" />
</antcall>
<echo message="Installed Virgo Nano RAP for distribution purposes." />
</target>
<target name="assemble-zips">
<property name="nano.package.dir" value="${package.dir}/VN"/>
<delete dir="${nano.package.dir}/${nano-package}-${bundle.version}/Eclipse.app" quiet="true"/>
<mkdir dir="${artifacts.dir}"/>
<zip destfile="${artifacts.dir}/${nano-package}-${bundle.version}.zip">
<zipfileset dir="${nano.package.dir}" includes="${nano-package}-${bundle.version}/bin/*.sh" filemode="755"/>
<zipfileset dir="${nano.package.dir}" includes="${nano-package}-${bundle.version}/configuration/org.eclipse.virgo.kernel.jmxremote.access.properties" filemode="600"/>
<zipfileset dir="${nano.package.dir}">
<exclude name="${nano-package}-${bundle.version}/bin/*.sh"/>
<exclude name="${nano-package}-${bundle.version}/configuration/org.eclipse.virgo.kernel.jmxremote.access.properties"/>
</zipfileset>
</zip>
<echo message="Virgo Nano assembled in ${artifacts.dir}/${nano-package}-${bundle.version}.zip"/>
<property name="nano.full.package.dir" value="${package.dir}/VNF"/>
<delete dir="${nano.full.package.dir}/${nano-full-package}-${bundle.version}/Eclipse.app" quiet="true"/>
<zip destfile="${artifacts.dir}/${nano-full-package}-${bundle.version}.zip">
<zipfileset dir="${nano.full.package.dir}" includes="${nano-full-package}-${bundle.version}/bin/*.sh" filemode="755"/>
<zipfileset dir="${nano.full.package.dir}" includes="${nano-full-package}-${bundle.version}/configuration/org.eclipse.virgo.kernel.jmxremote.access.properties" filemode="600"/>
<zipfileset dir="${nano.full.package.dir}">
<exclude name="${nano-full-package}-${bundle.version}/bin/*.sh"/>
<exclude name="${nano-full-package}-${bundle.version}/configuration/org.eclipse.virgo.kernel.jmxremote.access.properties"/>
</zipfileset>
</zip>
<echo message="Virgo Nano Full assembled in ${artifacts.dir}/${nano-full-package}-${bundle.version}.zip"/>
<property name="nano.rap.package.dir" value="${package.dir}/VNR" />
<delete dir="${nano.rap.package.dir}/${nano-rap-package}-${bundle.version}/Eclipse.app" quiet="true" />
<zip destfile="${artifacts.dir}/${nano-rap-package}-${bundle.version}.zip">
<zipfileset dir="${nano.rap.package.dir}" includes="${nano-rap-package}-${bundle.version}/bin/*.sh" filemode="755" />
<zipfileset dir="${nano.rap.package.dir}" includes="${nano-rap-package}-${bundle.version}/configuration/org.eclipse.virgo.kernel.jmxremote.access.properties" filemode="600" />
<zipfileset dir="${nano.rap.package.dir}">
<exclude name="${nano-rap-package}-${bundle.version}/bin/*.sh" />
<exclude name="${nano-rap-package}-${bundle.version}/configuration/org.eclipse.virgo.kernel.jmxremote.access.properties" />
</zipfileset>
</zip>
<echo message="Virgo Nano RAP assembled in ${artifacts.dir}/${nano-rap-package}-${bundle.version}.zip" />
</target>
<target name="nano.clean-up">
<delete dir="${nano.target.dir}/assembly" quiet="true" />
<delete dir="${common.resources.location}" quiet="true" />
<delete dir="${specific.resources.location}" quiet="true" />
<delete dir="${scripts.location}" quiet="true" />
<delete dir="${nano.target.dir}" quiet="true" />
</target>
<target name="smoke-test-nano" description="Runs a smoke test on the nano packaged build">
<path id="smoke.test.bundles">
<pathelement location="${nano.basedir}/org.eclipse.virgo.nano.smoketest" />
</path>
<antcall target="test.pre" />
<all-bundles target="test-package" buildpathRef="smoke.test.bundles">
<property name="package.output.file" value="${artifacts.dir}/${nano-full-package}-${bundle.version}.zip" />
<property name="package.basename" value="${nano-full-package}-${bundle.version}" />
</all-bundles>
<antcall target="test.post" />
</target>
<target name="publish-multiple-nano-packages-build" description="Uploads all Nano zipped packages to build.eclipse.org">
<antcall target="publish-package-build">
<param name="package.output.file" value="${package.output.file}" />
</antcall>
<antcall target="publish-package-build">
<param name="package.output.file" value="${artifacts.dir}/${nano-full-package}-${bundle.version}.zip" />
</antcall>
<antcall target="publish-package-build">
<param name="package.output.file" value="${artifacts.dir}/${nano-rap-package}-${bundle.version}.zip" />
</antcall>
</target>
<target name="simrel-package" depends="ivy.init">
<delete dir="${package.output.dir}" quiet="true" />
<mkdir dir="${package.output.dir}" />
<property name="common.resources.location" value="${nano.target.dir}/common_resources_zipped" />
<property name="specific.resources.location" value="${nano.target.dir}/specific_resources_zipped" />
<property name="enterprise.resources.location" value="${nano.target.dir}/enterprise_resources_zipped" />
<property name="scripts.location" value="${nano.target.dir}/scripts_zipped" />
<antcall target="simrel-common-resources" />
<antcall target="simrel-bundles-and-features" />
<antcall target="simrel-publish-p2-repo" />
</target>
<target name="simrel-publish-p2-repo">
<antcall target="fetch-unzipped-virgo-build-tools" />
<property name="p2.products.location" value="${nano.basedir}/publish_resources/products" />
<antcall target="p2.publish-bundles-features">
<param name="repository" value="${p2.repository.dir}" />
<param name="source" value="${nano.target.dir}/assembly" />
</antcall>
<echo message="Published bundles and features to ${p2.repository.dir}." />
<antcall target="p2.publish-product">
<param name="repository" value="${p2.repository.dir}" />
<param name="product.file.location" value="${p2.products.location}/virgo-nano/virgo-nano.product" />
</antcall>
<echo message="Published virgo-nano product to ${p2.repository.dir}." />
</target>
<target name="simrel-bundles-and-features">
<!-- Copy the nano kernel artifacts to a prepared for publishing location - a p2 repo will be built around them -->
<ivy:resolve resolveId="copy.path" file="${nano.basedir}/nano-ivy.xml" transitive="false" />
<ivy:retrieve resolveId="copy.path" pattern="${nano.target.dir}/assembly/plugins/[artifact]_[revision].[ext]" conf="nano-runtime" type="jar" />
<ivy:resolve resolveId="copy.path" file="${nano.basedir}/orbit-ivy.xml" transitive="false" />
<ivy:retrieve resolveId="copy.path" pattern="${nano.target.dir}/assembly/plugins/[artifact]_[revision].[ext]" conf="orbit-runtime" type="jar" />
<ivy:resolve resolveId="copy.path" file="${nano.basedir}/gemini-web-ivy.xml" transitive="false" />
<ivy:retrieve resolveId="copy.path" pattern="${nano.target.dir}/assembly/plugins/[artifact]_[revision].[ext]" conf="gemini-web" type="jar" />
</target>
<target name="simrel-common-resources">
<copy todir="${nano.target.dir}/assembly/plugins/org.eclipse.virgo.common.resources_${bundle.version}" failonerror="false">
<fileset dir="${nano.basedir}/publish_resources/org.eclipse.virgo.common.resources" />
<filterset>
<filter token="NANO.VERSION" value="${bundle.version}" />
</filterset>
</copy>
<property name="common.resources" value="${nano.target.dir}/assembly/plugins/org.eclipse.virgo.common.resources_${bundle.version}/root_content" />
<copy todir="${common.resources}/bin" failonerror="false">
<fileset dir="${nano.basedir}/bin" />
</copy>
<ivy:resolve resolveId="copy.path" file="${nano.basedir}/lib-ivy.xml" transitive="true" />
<ivy:retrieve resolveId="copy.path" pattern="${common.resources}/lib/[artifact]_[revision].[ext]" conf="lib" type="jar" />
<mkdir dir="${common.resources}/configuration" />
<mkdir dir="${common.resources}/pickup" />
<copy todir="${common.resources}" failonerror="false">
<fileset dir="${nano.basedir}/resources" />
</copy>
<copy todir="${common.resources}/configuration" failonerror="false">
<fileset dir="${nano.basedir}/configuration" excludes="keystore,serviceability.xml" />
</copy>
<copy file="${nano.basedir}/configuration/keystore" todir="${common.resources}/configuration" failonerror="false" />
<mkdir dir="${common.resources}/lib" />
<echo file="${common.resources}/lib/.version" message="virgo.nano.version=${bundle.version}&#xa;" />
<copy todir="${common.resources}/configuration" failonerror="false">
<fileset dir="${nano.basedir}/configuration">
<include name="serviceability.xml" />
</fileset>
</copy>
</target>
<target name="publish-multiple-nano-packages-download" description="Uploads all Nano zipped packages to download.eclipse.org">
<antcall target="publish-package-download">
<param name="package.output.file" value="${package.output.file}" />
</antcall>
<antcall target="publish-package-download">
<param name="package.output.file" value="${artifacts.dir}/${nano-full-package}-${bundle.version}.zip" />
</antcall>
<antcall target="publish-package-download">
<param name="package.output.file" value="${artifacts.dir}/${nano-rap-package}-${bundle.version}.zip" />
</antcall>
</target>
<target name="ci.publish.nightly" description="Publishes nightly repository to download.eclipse.org. Can be executed on Hudson only!">
<delete dir="${nightly.updatesite.dir}" />
<copy toDir="${nightly.updatesite.dir}">
<fileset dir="${p2.repository.dir}" />
</copy>
</target>
</project>