You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-dev@logging.apache.org by ca...@apache.org on 2007/06/06 15:25:59 UTC
svn commit: r544836 - /logging/log4j/branches/v1_2-branch/src/ntdll/build.xml
Author: carnold
Date: Wed Jun 6 06:25:58 2007
New Revision: 544836
URL: http://svn.apache.org/viewvc?view=rev&rev=544836
Log:
Bug 37930: Support cross compilation of NTEventLogAppender.dll
Modified:
logging/log4j/branches/v1_2-branch/src/ntdll/build.xml
Modified: logging/log4j/branches/v1_2-branch/src/ntdll/build.xml
URL: http://svn.apache.org/viewvc/logging/log4j/branches/v1_2-branch/src/ntdll/build.xml?view=diff&rev=544836&r1=544835&r2=544836
==============================================================================
--- logging/log4j/branches/v1_2-branch/src/ntdll/build.xml (original)
+++ logging/log4j/branches/v1_2-branch/src/ntdll/build.xml Wed Jun 6 06:25:58 2007
@@ -23,14 +23,18 @@
<property name="src.dir" location="${basedir}"/>
<property name="failonerror" value="false"/>
<property name="failifexecutionfails" value="${failonerror}"/>
-
+
<target name="clean" description="Deletes generated files">
<delete dir="${target.dir}"/>
</target>
<target name="windres" description="Compiles resources">
+ <condition property="mingw-prefix" value="">
+ <os family="windows"/>
+ </condition>
+ <property name="mingw-prefix" value="i586-mingw32msvc-"/>
<mkdir dir="${object.dir}"/>
- <exec executable="windres"
+ <exec executable="${mingw-prefix}windres"
dir="${src.dir}"
resultproperty="windres_status"
failonerror="${failonerror}"
@@ -50,13 +54,17 @@
destdir="${object.dir}"
classpath="${classes.dir}"/>
- <property name="jni.include.dir" location="${java.home}\..\include"/>
- <exec executable="gcc">
+ <property name="jni.include.dir" location="${java.home}/../include"/>
+ <property name="jni.win32.include.dir" location="${jni.include.dir}/win32"/>
+ <!-- check for Win32 version of jni_md.h, if not available fail build -->
+ <available property="jni_md.h_available" file="${jni.win32.include.dir}/jni_md.h"/>
+ <fail unless="jni_md.h_available">${jni.win32.include.dir}/jni_md.h not found</fail>
+ <exec executable="${mingw-prefix}gcc">
<arg value="-Wall"/>
<arg value="-D_JNI_IMPLEMENTATION_"/>
<arg value="-Wl,--kill-at"/>
+ <arg value="-I${jni.win32.include.dir}"/>
<arg value="-I${jni.include.dir}"/>
- <arg value="-I${jni.include.dir}\win32"/>
<arg value="-I${object.dir}"/>
<arg value="-shared"/>
<arg file="${src.dir}/nteventlog.cpp"/>
@@ -74,4 +82,4 @@
<target name="build" depends="compile, warn">
</target>
-</project>
\ No newline at end of file
+</project>
---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-dev-help@logging.apache.org