Skip to content

Commit

Permalink
[ENGOPS-1779] subfloor updates for Java 8
Browse files Browse the repository at this point in the history
  • Loading branch information
buildguy committed Mar 28, 2016
1 parent 4fdf4bc commit 9ebdb0f
Show file tree
Hide file tree
Showing 2 changed files with 92 additions and 9 deletions.
79 changes: 78 additions & 1 deletion build-res/subfloor-pkg.xml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
files.
============================================================================-->

<project name="subfloor-pkg" basedir="." default="default" xmlns:ivy="antlib:org.apache.ivy.ant">
<project name="subfloor-pkg" basedir="." default="default" xmlns:ivy="antlib:org.apache.ivy.ant" xmlns:artifact="antlib:org.apache.maven.artifact.ant">

<!-- Define the default location of the common build file -->
<property name="subfloor.file"
Expand Down Expand Up @@ -126,6 +126,83 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
</zip>
</target>


<!-- ======================================== EULA assembly packaging ========================================= -->

<target name="package-eula" depends="install-antcontrib">
<property name="pentaho.resolve.repo" value="http://nexus.pentaho.org/content/groups/omni" />
<property name="artifactName" value="${package.basename}" />
<property name="pentaho-eula-wrap-config.version" value="${pentaho-eula-wrap-config.version}" />
<property name="izpack.version" value="${izpack.version}" />
<property name="maven-ant-tasks.version" value="2.1.3" />
<property name="izpack.type" value="zip" />
<property name="artifactBaseDir" value="${bin.dir}" />
<property name="artifactIncludes" value="*/*" />

<if>
<not>
<available file="${subfloor.tmp.dir}/maven-ant-tasks-${maven-ant-tasks.version}.jar" />
</not>
<then>
<get src="${pentaho.resolve.repo}/org/apache/maven/maven-ant-tasks/${maven-ant-tasks.version}/maven-ant-tasks-${maven-ant-tasks.version}.jar"
dest="${subfloor.tmp.dir}/maven-ant-tasks-${maven-ant-tasks.version}.jar"
verbose="true"
/>
</then>
</if>

<path id="maven-ant-tasks.classpath" path="${subfloor.tmp.dir}/maven-ant-tasks-${maven-ant-tasks.version}.jar" />
<typedef resource="org/apache/maven/artifact/ant/antlib.xml"
uri="antlib:org.apache.maven.artifact.ant"
classpathref="maven-ant-tasks.classpath" />

<artifact:dependencies pathId="izpack.classpath">
<dependency groupId="org.codehaus.izpack" artifactId="izpack-ant" version="${izpack.version}" />
</artifact:dependencies>

<taskdef name="izpack" classpathref="izpack.classpath" classname="com.izforge.izpack.ant.IzPackTask" />

<artifact:dependencies>
<dependency groupId="pentaho" artifactId="pentaho-eula-wrap-config" version="${pentaho-eula-wrap-config.version}" classifier="install" type="bat" />
<dependency groupId="pentaho" artifactId="pentaho-eula-wrap-config" version="${pentaho-eula-wrap-config.version}" classifier="install" type="sh" />
<dependency groupId="pentaho" artifactId="pentaho-eula-wrap-config" version="${pentaho-eula-wrap-config.version}" classifier="README" type="txt" />
<dependency groupId="pentaho" artifactId="pentaho-eula-wrap-config" version="${pentaho-eula-wrap-config.version}" classifier="eula" type="txt" />
<dependency groupId="pentaho" artifactId="pentaho-eula-wrap-config" version="${pentaho-eula-wrap-config.version}" classifier="izpack-sidebar" type="png" />
<dependency groupId="pentaho" artifactId="pentaho-eula-wrap-config" version="${pentaho-eula-wrap-config.version}" classifier="eula" type="html" />
<dependency groupId="pentaho" artifactId="pentaho-eula-wrap-config" version="${pentaho-eula-wrap-config.version}" classifier="izpack-zip" type="xml" />
<dependency groupId="pentaho" artifactId="pentaho-eula-wrap-config" version="${pentaho-eula-wrap-config.version}" classifier="izpack-dir" type="xml" />
<dependency groupId="pentaho" artifactId="pentaho-eula-wrap-config" version="${pentaho-eula-wrap-config.version}" type="jar" />
</artifact:dependencies>

<if>
<equals arg1="${izpack.type}" arg2="dir" />
<then>
<var name="izpackConfigFile" value="${pentaho:pentaho-eula-wrap-config:xml:izpack-dir}" />
<echo>constructing EULA wrapped dist from ${artifactIncludes} in directory ${artifactBaseDir} ...</echo>
</then>
<else>
<var name="izpackConfigFile" value="${pentaho:pentaho-eula-wrap-config:xml:izpack-zip}" />
<echo>constructing EULA wrapped dist from ${artifactName}.zip in directory ${dist.dir} ...</echo>
</else>
</if>

<izpack input="${izpackConfigFile}"
output="${dist.dir}/installer.jar"
installerType="standard"
inheritAll="true"
basedir="${dist.dir}"
/>

<zip destfile="${dist.dir}/${artifactName}-dist.zip" preserve0permissions="true">
<zipfileset file="${pentaho:pentaho-eula-wrap-config:txt:README}" fullpath="${artifactName}/README.txt" />
<zipfileset file="${pentaho:pentaho-eula-wrap-config:bat:install}" fullpath="${artifactName}/install.bat" />
<zipfileset file="${pentaho:pentaho-eula-wrap-config:sh:install}" fullpath="${artifactName}/install.sh" filemode="755" />
<zipfileset file="${pentaho:pentaho-eula-wrap-config:txt:eula}" fullpath="${artifactName}/license.txt" />
<zipfileset dir="${dist.dir}" includes="installer.jar" fullpath="${artifactName}/installer.jar"/>
</zip>
<delete file="${dist.dir}/installer.jar"/>

</target>


<!-- ============================================linuxPackage===================================================== -->
Expand Down
22 changes: 14 additions & 8 deletions build-res/subfloor.xml
Original file line number Diff line number Diff line change
Expand Up @@ -155,8 +155,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
<property name="javac.deprecation"
value="true"
description="Indicates whether source should be compiled with deprecation information"/>
<property name="javac.source" value="7" description="Provide source compatibility with specified release"/>
<property name="javac.target" value="7" description="Generate class files for specific VM version"/>
<property name="javac.source" value="8" description="Provide source compatibility with specified release"/>
<property name="javac.target" value="8" description="Generate class files for specific VM version"/>
<property name="javac.maxmemory" value="256M" description="Max memory alloted to java compile"/>
<property name="javac.xlint" value="-Xlint:all"/>

Expand Down Expand Up @@ -242,7 +242,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
value="${testbin.dir}/instrumented-classes"
description="Directory where instrumented project classes are placed for use by code coverage utility"/>
<property name="jacoco.version"
value="0.7.4.201502262128"
value="0.7.6.201602180812"
description="The version of jacoco to use for code coverage"/>
<property name="cobertura.version"
value="2.1.1"
Expand Down Expand Up @@ -326,9 +326,9 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

<!-- Sonar properties -->

<property name="sonar-ant-task-version" value="2.2"/>
<property name="sonar-ant-task-version" value="2.4"/>
<property name="sonar.classname" value="org.sonar.ant.SonarTask"/>
<property name="sonar.hostname" value="10.177.176.23"/>
<property name="sonar.hostname" value="sonar.pentaho.com"/>
<property name="sonar.port" value="9000"/>
<property name="sonar.host.url" value="http://${sonar.hostname}:${sonar.port}"/>
<property name="sonar.jdbc.username" value="sonar"/>
Expand Down Expand Up @@ -366,7 +366,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
value="6.12"
description="The version of CheckStyle to use for coding standards"/>
<property name="pentaho.coding.standards.version"
value="1.0.3"/>
value="1.0.4"/>
<property name="checkstyle.dir"
value="${basedir}/checkstyle"/>
<property name="checkstyle.lib.dir"
Expand Down Expand Up @@ -1846,12 +1846,18 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
init-test-reports
Prepare directories for JUnit test reports
Do not chain the clean-test-reports target because running unit tests
followed by integration tests is resulting in missing unit test reports.
These directories will be cleaned by a top level "clean" call or a user
can call "clean-test-reports" directly if desired.
====================================================================-->
<target name="init-test-reports" depends="clean-test-reports">
<target name="init-test-reports" >
<mkdir dir="${testreports.xml.dir}"/>
<mkdir dir="${testreports.html.dir}"/>
</target>


<!--=======================================================================
integration-test
Expand Down Expand Up @@ -1950,7 +1956,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
<target name="javadoc" depends="javadoc.init, compile">
<javadoc destdir="${javadoc.dir}/docs/api"
access="public"
source="7"
source="${javac.source}"
use="true"
notree="false"
nonavbar="false"
Expand Down

0 comments on commit 9ebdb0f

Please sign in to comment.