don't run gettext if 'require.gettext' is set to false

This commit is contained in:
kytv
2013-01-10 16:51:06 +00:00
parent e34cd0ba3f
commit 41af00a7d6
7 changed files with 28 additions and 10 deletions

View File

@ -8,12 +8,15 @@
<property name="resources" value="resources"/> <property name="resources" value="resources"/>
<property name="javadoc" value="javadoc"/> <property name="javadoc" value="javadoc"/>
<condition property="no.bundle">
<isfalse value="${require.gettext}" />
</condition>
<property name="javac.compilerargs" value=""/> <property name="javac.compilerargs" value=""/>
<property name="require.gettext" value="true" /> <property name="require.gettext" value="true" />
<target name="init"> <target name="init">
<mkdir dir="${build}"/> <mkdir dir="${build}"/>
<mkdir dir="${build}/${resources}"/> <mkdir dir="${build}/${resources}"/>
<mkdir dir="${build}/${javadoc}"/> <mkdir dir="${build}/${javadoc}"/>
<mkdir dir="${dist}"/> <mkdir dir="${dist}"/>
</target> </target>
@ -39,7 +42,7 @@
</copy> </copy>
</target> </target>
<target name="bundle" > <target name="bundle" unless="no.bundle">
<exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="${require.gettext}" > <exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="${require.gettext}" >
<arg value="./bundle-messages.sh" /> <arg value="./bundle-messages.sh" />
</exec> </exec>

View File

@ -24,6 +24,9 @@
</depend> </depend>
</target> </target>
<condition property="no.bundle">
<isfalse value="${require.gettext}" />
</condition>
<property name="javac.compilerargs" value="" /> <property name="javac.compilerargs" value="" />
<property name="require.gettext" value="true" /> <property name="require.gettext" value="true" />
@ -120,7 +123,7 @@
</uptodate> </uptodate>
</target> </target>
<target name="bundle" depends="compile"> <target name="bundle" depends="compile" unless="no.bundle">
<!-- Update the messages_*.po files. <!-- Update the messages_*.po files.
We need to supply the bat file for windows, and then change the fail property to true --> We need to supply the bat file for windows, and then change the fail property to true -->
<exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="${require.gettext}" > <exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="${require.gettext}" >

View File

@ -21,6 +21,9 @@
</depend> </depend>
</target> </target>
<condition property="no.bundle">
<isfalse value="${require.gettext}" />
</condition>
<property name="javac.compilerargs" value="" /> <property name="javac.compilerargs" value="" />
<property name="require.gettext" value="true" /> <property name="require.gettext" value="true" />
@ -84,7 +87,7 @@
</condition> </condition>
</target> </target>
<target name="bundle" depends="compile, precompilejsp"> <target name="bundle" depends="compile, precompilejsp" unless="no.bundle">
<!-- Update the messages_*.po files. <!-- Update the messages_*.po files.
We need to supply the bat file for windows, and then change the fail property to true --> We need to supply the bat file for windows, and then change the fail property to true -->
<exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="${require.gettext}" > <exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="${require.gettext}" >

View File

@ -8,6 +8,9 @@
<target name="prepare"> <target name="prepare">
<!-- run from top level build.xml to get dependencies built --> <!-- run from top level build.xml to get dependencies built -->
</target> </target>
<condition property="no.bundle">
<isfalse value="${require.gettext}" />
</condition>
<condition property="depend.available"> <condition property="depend.available">
<typefound name="depend" /> <typefound name="depend" />
</condition> </condition>
@ -113,7 +116,7 @@
</target> </target>
<!-- this is tricky because the message classes go in the jar, not in the war --> <!-- this is tricky because the message classes go in the jar, not in the war -->
<target name="bundle" depends="jar1, precompilejsp" > <target name="bundle" depends="jar1, precompilejsp" unless="no.bundle">
<!-- Update the messages_*.po files. <!-- Update the messages_*.po files.
We need to supply the bat file for windows, and then change the fail property to true --> We need to supply the bat file for windows, and then change the fail property to true -->
<exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="${require.gettext}" > <exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="${require.gettext}" >

View File

@ -24,6 +24,9 @@
<pathelement location="../../../core/java/build/i2p.jar" /> <pathelement location="../../../core/java/build/i2p.jar" />
</path> </path>
<property name="javac.compilerargs" value="" /> <property name="javac.compilerargs" value="" />
<condition property="no.bundle">
<isfalse value="${require.gettext}" />
</condition>
<property name="require.gettext" value="true" /> <property name="require.gettext" value="true" />
<target name="compile"> <target name="compile">
@ -121,7 +124,7 @@
</condition> </condition>
</target> </target>
<target name="bundle" depends="compile, precompilejsp"> <target name="bundle" depends="compile, precompilejsp" unless="no.bundle">
<!-- Update the messages_*.po files. <!-- Update the messages_*.po files.
We need to supply the bat file for windows, and then change the fail property to true --> We need to supply the bat file for windows, and then change the fail property to true -->
<exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="${require.gettext}" > <exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="${require.gettext}" >

View File

@ -7,6 +7,10 @@
</target> </target>
<property name="javac.compilerargs" value="" /> <property name="javac.compilerargs" value="" />
<condition property="no.bundle">
<isfalse value="${require.gettext}" />
</condition>
<property name="require.gettext" value="true" /> <property name="require.gettext" value="true" />
<target name="compile"> <target name="compile">
@ -71,7 +75,7 @@
</condition> </condition>
</target> </target>
<target name="bundle" depends="compile"> <target name="bundle" depends="compile" unless="no.bundle">
<!-- Update the messages_*.po files. <!-- Update the messages_*.po files.
We need to supply the bat file for windows, and then change the fail property to true --> We need to supply the bat file for windows, and then change the fail property to true -->
<exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="${require.gettext}" > <exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="${require.gettext}" >

View File

@ -33,8 +33,7 @@ sloccount.report.file=sloccount.sc
# Uncomment the next line to prevent building EXEs (changing it to false will have no impact) # Uncomment the next line to prevent building EXEs (changing it to false will have no impact)
#noExe=true #noExe=true
# Change this to false if you don't have gettext # Change this to false if you don't have gettext or you want to prevent it from running during the build
# Note that this does not prevent gettext from running if installed; to be fixed
require.gettext=true require.gettext=true
# Additional classpath if required # Additional classpath if required