Commit d7a3d021 authored by Gaston Dombiak's avatar Gaston Dombiak Committed by gato

Pack200 compression in plugins is now optional. It is still enabled by default. JM-1314

git-svn-id: http://svn.igniterealtime.org/svn/repos/openfire/trunk@10902 b35dd754-fafc-0310-a699-88a17e54d16e
parent d0a1c520
...@@ -100,6 +100,7 @@ ...@@ -100,6 +100,7 @@
<property name="jar.starter.name" value="startup.jar"/> <property name="jar.starter.name" value="startup.jar"/>
<property name="jar.dest.dir" value="${work.dir}/lib"/> <property name="jar.dest.dir" value="${work.dir}/lib"/>
<property name="resources.dir" value="${src.dir}/resources"/> <property name="resources.dir" value="${src.dir}/resources"/>
<property name="pack200.enabled" value="true"/>
<property name="overlay.dir" value="${basedir}/custom"/> <property name="overlay.dir" value="${basedir}/custom"/>
<property name="overlay.src.dir" value="${overlay.dir}/source"/> <property name="overlay.src.dir" value="${overlay.dir}/source"/>
...@@ -1516,27 +1517,50 @@ ...@@ -1516,27 +1517,50 @@
<property name="pack200.excludes" <property name="pack200.excludes"
value="gnujaxp.jar,mail.jar,activation.jar,bouncycastle.jar,tangosol.jar"/> value="gnujaxp.jar,mail.jar,activation.jar,bouncycastle.jar,tangosol.jar"/>
<for param="jar"> <if>
<path> <equals arg1="${pack200.enabled}" arg2="true" />
<fileset dir="${plugin.dev.dest.dir}/@{plugin}/target/lib" includes="*.jar" <then>
excludes="${pack200.excludes}"/> <for param="jar">
</path> <path>
<sequential> <fileset dir="${plugin.dev.dest.dir}/@{plugin}/target/lib" includes="*.jar"
<delete file="@{jar}.pack"/> excludes="${pack200.excludes}"/>
<pack200 src="@{jar}" </path>
destfile="@{jar}.pack" <sequential>
gzipoutput="false" <delete file="@{jar}.pack"/>
/> <pack200 src="@{jar}"
</sequential> destfile="@{jar}.pack"
</for> gzipoutput="false"
/>
</sequential>
</for>
<copy todir="${plugin.dev.dest.dir}/@{plugin}/jar" overwrite="true">
<fileset dir="${plugin.dev.dest.dir}/@{plugin}/target">
<include name="lib/*.pack"/>
<include name="web/WEB-INF/web.xml"/>
<include name="web/WEB-INF/web-custom.xml"/>
</fileset>
</copy>
<!-- Excluded pack files need to be copied over as well -->
<copy todir="${plugin.dev.dest.dir}/@{plugin}/jar/lib" overwrite="true">
<fileset dir="${plugin.dev.dest.dir}/@{plugin}/target/lib"
includes="${pack200.excludes}"/>
</copy>
</then>
<else>
<copy todir="${plugin.dev.dest.dir}/@{plugin}/jar" overwrite="true">
<fileset dir="${plugin.dev.dest.dir}/@{plugin}/target">
<include name="lib/*.jar"/>
<include name="web/WEB-INF/web.xml"/>
<include name="web/WEB-INF/web-custom.xml"/>
</fileset>
</copy>
</else>
</if>
<!-- Copy everything else to Openfire's plugin dir --> <!-- Copy everything else to Openfire's plugin dir -->
<copy todir="${plugin.dev.dest.dir}/@{plugin}/jar" overwrite="true"> <copy todir="${plugin.dev.dest.dir}/@{plugin}/jar" overwrite="true">
<fileset dir="${plugin.dev.dest.dir}/@{plugin}/target">
<include name="lib/*.pack"/>
<include name="web/WEB-INF/web.xml"/>
<include name="web/WEB-INF/web-custom.xml"/>
</fileset>
<fileset dir="@{pluginsrc}/@{plugin}"> <fileset dir="@{pluginsrc}/@{plugin}">
<include name="classes/**/*.*"/> <include name="classes/**/*.*"/>
</fileset> </fileset>
...@@ -1551,12 +1575,6 @@ ...@@ -1551,12 +1575,6 @@
</fileset> </fileset>
</copy> </copy>
<!-- Excluded pack files need to be copied over as well -->
<copy todir="${plugin.dev.dest.dir}/@{plugin}/jar/lib" overwrite="true">
<fileset dir="${plugin.dev.dest.dir}/@{plugin}/target/lib"
includes="${pack200.excludes}"/>
</copy>
<!-- Jar the plugin --> <!-- Jar the plugin -->
<jar jarfile="${plugin.dest.dir}/@{plugin}.jar"> <jar jarfile="${plugin.dest.dir}/@{plugin}.jar">
<fileset dir="${plugin.dev.dest.dir}/@{plugin}/jar"/> <fileset dir="${plugin.dev.dest.dir}/@{plugin}/jar"/>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment