diff options
Diffstat (limited to 'make/gluegen-cpptasks-base.xml')
-rwxr-xr-x | make/gluegen-cpptasks-base.xml | 57 |
1 files changed, 29 insertions, 28 deletions
diff --git a/make/gluegen-cpptasks-base.xml b/make/gluegen-cpptasks-base.xml index 426bfae..04b6628 100755 --- a/make/gluegen-cpptasks-base.xml +++ b/make/gluegen-cpptasks-base.xml @@ -88,9 +88,9 @@ - and the following properties: - - java.home.dir : path to the JDK home directory - - java.includes.dir : path to the JNI headers (.../jdk/include) - - java.includes.dir.platform : path to the platform JNI headers (.../jdk/include/linux) - java.lib.dir.platform : path to the Java library dir (libjawt.so, etc.) + - java.includes.dir : path to the GlueGen JNI headers: gluegen/make/stub_includes/jni + - java.includes.dir.platform : path to the GlueGen Platform JNI headers: gluegen/make/stub_includes/jni/<platform> - - If your project requires only minimal changes to the compiler - configuration, you may be able to simply refer to the @@ -922,7 +922,6 @@ <target name="setup.java.home.dir.nonmacosx" unless="isOSX"> <!-- java home dir is up one directory as java.home points to '<java-install-dir>/jre' --> <property name="java.home.dir" value="${java.home}/.." /> - <property name="java.includes.dir" value="${java.home.dir}/include" /> </target> <target name="setup.java.home.dir.macosx" if="isOSX"> <!-- Java7 std location --> @@ -930,15 +929,11 @@ value="${java.home}/.."> <available file="${java.home}/../include/jni.h"/> </condition> - <condition property="java.includes.dir" - value="${java.home}/../include"> - <available file="${java.home}/../include/jni.h"/> - </condition> <!-- Fallback value Java6 --> <property name="java.home.dir" value="/System/Library/Frameworks/JavaVM.framework/Home" /> - <property name="java.includes.dir" value="/System/Library/Frameworks/JavaVM.framework/Headers" /> </target> <target name="setup.java.home.dir" depends="setup.java.home.dir.nonmacosx,setup.java.home.dir.macosx"> + <property name="java.includes.dir" value="${gluegen.root.abs-path}/make/stub_includes/jni" /> <echo message="java.home.dir ${java.home.dir}" /> <echo message="java.includes.dir ${java.includes.dir}" /> </target> @@ -1223,16 +1218,19 @@ <linker id="linker.cfg.linux" name="${gcc.compat.compiler}"> <linkerarg value="-static-libgcc" if="isGCC"/> + <linkerarg value="-static-libstdc++" if="isGCC"/> </linker> <linker id="linker.cfg.linux.x86" name="${gcc.compat.compiler}"> <linkerarg value="-m32"/> <linkerarg value="-static-libgcc" if="isGCC"/> + <linkerarg value="-static-libstdc++" if="isGCC"/> </linker> <linker id="linker.cfg.linux.amd64" name="${gcc.compat.compiler}"> <linkerarg value="-m64"/> <linkerarg value="-static-libgcc" if="isGCC"/> + <linkerarg value="-static-libstdc++" if="isGCC"/> </linker> <!-- Using default compiler settings - utilize: @@ -1244,6 +1242,7 @@ <linkerarg value="-nostdlib" /> <linkerarg value="-Bdynamic" /> <linkerarg value="-static-libgcc" if="isGCC"/> + <linkerarg value="-static-libstdc++" if="isGCC"/> </linker> <linker id="linker.cfg.linux.aarch64" name="${gcc.compat.compiler}"> @@ -1251,6 +1250,7 @@ <linkerarg value="-nostdlib" /> <linkerarg value="-Bdynamic" /> <linkerarg value="-static-libgcc" if="isGCC"/> + <linkerarg value="-static-libstdc++" if="isGCC"/> </linker> <linker id="linker.cfg.linux.alpha" name="${gcc.compat.compiler}"> @@ -1297,16 +1297,19 @@ <linker id="linker.cfg.solaris" name="${gcc.compat.compiler}"> <linkerarg value="-m32"/> <linkerarg value="-static-libgcc" if="isGCC"/> + <linkerarg value="-static-libstdc++" if="isGCC"/> </linker> <linker id="linker.cfg.solaris.sparcv9" name="${gcc.compat.compiler}"> <linkerarg value="-xarch=v9a" /> <linkerarg value="-static-libgcc" if="isGCC"/> + <linkerarg value="-static-libstdc++" if="isGCC"/> </linker> <linker id="linker.cfg.solaris.amd64" name="${gcc.compat.compiler}"> <linkerarg value="-m64"/> <linkerarg value="-static-libgcc" if="isGCC"/> + <linkerarg value="-static-libstdc++" if="isGCC"/> <!-- linkerarg value="-xarch=amd64" / --> </linker> @@ -1322,6 +1325,7 @@ <linkerarg value="x86_64" if="use.macosx64"/> <linkerarg value="-mmacosx-version-min=10.5"/> <linkerarg value="-static-libgcc" if="isGCC"/> + <linkerarg value="-static-libstdc++" if="isGCC"/> <!-- Note: Apple doesn't seem to provide ppc64 binaries on Leopard --> </linker> @@ -1331,6 +1335,7 @@ <linker id="linker.cfg.linux64.mingw64" classname="net.sf.antcontrib.cpptasks.gcc.GccLinker"> <linkerarg value="-m64"/> <linkerarg value="-static-libgcc" if="isGCC"/> + <linkerarg value="-static-libstdc++" if="isGCC"/> </linker> <!--linker id="linker.cfg.linux64.mingw32" classname="net.sf.antcontrib.cpptasks.gcc.Gcc32Linker"--> @@ -1338,6 +1343,7 @@ <linkerarg value="-m32"/> <linkerarg value="-Wl,--kill-at" /> <!-- remove @ from function names, ie no __stdcall @nn --> <linkerarg value="-static-libgcc" if="isGCC"/> + <linkerarg value="-static-libstdc++" if="isGCC"/> </linker> <linker id="linker.cfg.win32.mingw" name="${gcc.compat.compiler}" incremental="false"> @@ -1346,6 +1352,7 @@ <linkerarg value="-Wl,--enable-stdcall-fixup"/> <!-- for linking against dll directly --> <linkerarg value="-Wl,--kill-at" /> <!-- remove @ from function names, ie no __stdcall @nn --> <linkerarg value="-static-libgcc" if="isGCC"/> + <linkerarg value="-static-libstdc++" if="isGCC"/> </linker> <linker id="linker.cfg.win64.mingw" name="${gcc.compat.compiler}" incremental="false"> @@ -1354,6 +1361,7 @@ <linkerarg value="-Wl,--enable-stdcall-fixup"/> <!-- for linking against dll directly --> <linkerarg value="-Wl,--kill-at" /> <!-- remove @ from function names, ie no __stdcall @nn --> <linkerarg value="-static-libgcc" if="isGCC"/> + <linkerarg value="-static-libstdc++" if="isGCC"/> </linker> <linker id="linker.cfg.win32.msvc" name="msvc" incremental="false"> @@ -1459,7 +1467,7 @@ <echo message="Linux.aarch64" /> <property name="compiler.cfg.id.base" value="compiler.cfg.linux.aarch64" /> <property name="linker.cfg.id.base" value="linker.cfg.linux.aarch64" /> - <property name="java.lib.dir.platform" value="${java.home.dir}/jre/lib/arm" /> + <property name="java.lib.dir.platform" value="${java.home.dir}/jre/lib/aarch64" /> </target> <target name="gluegen.cpptasks.declare.compiler.linux.ia64" if="isLinuxIA64"> @@ -1519,7 +1527,7 @@ </target> <target name="gluegen.cpptasks.declare.compiler.linux" depends="gluegen.cpptasks.declare.compiler.linux.x86,gluegen.cpptasks.declare.compiler.linux.amd64,gluegen.cpptasks.declare.compiler.linux.ia64,gluegen.cpptasks.declare.compiler.linux.armv6,gluegen.cpptasks.declare.compiler.linux.aarch64,gluegen.cpptasks.declare.compiler.linux.alpha,gluegen.cpptasks.declare.compiler.linux.hppa,gluegen.cpptasks.declare.compiler.linux.mips,gluegen.cpptasks.declare.compiler.linux.mipsel,gluegen.cpptasks.declare.compiler.linux.ppc,gluegen.cpptasks.declare.compiler.linux.s390,gluegen.cpptasks.declare.compiler.linux.s390x,gluegen.cpptasks.declare.compiler.linux.sparc" if="isLinux"> - <property name="java.includes.dir.platform" value="${java.includes.dir}/linux" /> + <property name="java.includes.dir.platform" value="${java.includes.dir}/x11" /> </target> <target name="gluegen.cpptasks.declare.compiler.solaris32" if="isSolaris32Bit"> @@ -1541,7 +1549,7 @@ </target> <target name="gluegen.cpptasks.declare.compiler.solaris" depends="gluegen.cpptasks.declare.compiler.solaris32,gluegen.cpptasks.declare.compiler.solaris.sparcv9,gluegen.cpptasks.declare.compiler.solaris.amd64" if="isSolaris"> - <property name="java.includes.dir.platform" value="${java.includes.dir}/solaris" /> + <property name="java.includes.dir.platform" value="${java.includes.dir}/x11" /> <property name="java.lib.dir.platform" value="${java.home.dir}/jre/lib/${solaris.cpu}" /> </target> @@ -1549,25 +1557,13 @@ <echo message="MacOSX" /> <property name="compiler.cfg.id.base" value="compiler.cfg.macosx" /> <property name="linker.cfg.id.base" value="linker.cfg.macosx" /> - <!-- Java7 std location --> - <!-- Temporary workaround: - Provided darwin/jawt_md.h from Oracle for OSX / Java7 - has X11 dependencies and does not define JAWT_SurfaceLayers. - value="${java.includes.dir}/darwin"> - --> - <condition property="java.includes.dir.platform" - value="${gluegen.root.abs-path}/make/stub_includes/jni/macosx"> - <available file="${java.includes.dir}/darwin/jawt_md.h"/> - </condition> + <property name="java.includes.dir.platform" value="${java.includes.dir}/macosx" /> <condition property="java.lib.dir.platform" value="${java.home.dir}/jre/lib"> <available file="${java.home.dir}/jre/lib/libjawt.dylib"/> </condition> <!-- Fallback value Java6 --> - <property name="java.includes.dir.platform" value="/System/Library/Frameworks/JavaVM.framework/Headers" /> <property name="java.lib.dir.platform" value="/System/Library/Frameworks/JavaVM.framework/Libraries" /> - <echo message="java.includes.dir.platform ${java.includes.dir.platform}" /> - <echo message="java.lib.dir.platform ${java.lib.dir.platform}" /> </target> <target name="gluegen.cpptasks.declare.compiler.freebsd.x86" if="isFreeBSDX86"> @@ -1585,19 +1581,22 @@ </target> <target name="gluegen.cpptasks.declare.compiler.freebsd" depends="gluegen.cpptasks.declare.compiler.freebsd.x86,gluegen.cpptasks.declare.compiler.freebsd.amd64" if="isFreeBSD"> - <property name="java.includes.dir.platform" value="${java.includes.dir}/freebsd" /> + <property name="java.includes.dir.platform" value="${java.includes.dir}/x11" /> </target> <target name="gluegen.cpptasks.declare.compiler.hpux" if="isHPUX"> <echo message="HP-UX" /> <property name="compiler.cfg.id.base" value="compiler.cfg.hpux" /> <property name="linker.cfg.id.base" value="linker.cfg.hpux" /> - <property name="java.includes.dir.platform" value="${java.includes.dir}/hp-ux" /> + <property name="java.includes.dir.platform" value="${java.includes.dir}/x11" /> <property name="java.lib.dir.platform" value="${java.home.dir}/jre/lib/PA_RISC2.0" /> </target> <target name="gluegen.cpptasks.declare.compiler" depends="gluegen.cpptasks.declare.compiler.environment,gluegen.cpptasks.declare.compiler.win32,gluegen.cpptasks.declare.compiler.linux,gluegen.cpptasks.declare.compiler.solaris,gluegen.cpptasks.declare.compiler.macosx,gluegen.cpptasks.declare.compiler.freebsd,gluegen.cpptasks.declare.compiler.hpux" > - <echo message="java.lib.dir.platform: ${java.lib.dir.platform}" /> + <echo message="java.home.dir ${java.home.dir}" /> + <echo message="java.includes.dir ${java.includes.dir}" /> + <echo message="java.includes.dir.platform ${java.includes.dir.platform}" /> + <echo message="java.lib.dir.platform ${java.lib.dir.platform}" /> </target> <target name="gluegen.cpptasks.setup.compiler" depends="gluegen.cpptasks.detect.compiler,gluegen.cpptasks.configure.compiler,gluegen.cpptasks.declare.compiler" /> @@ -1656,7 +1655,9 @@ <mkdir dir="${nativejarfile.tmpdir}/java" /> <mkdir dir="${nativejarfile.tmpdir.natives}" /> - <copy todir="${nativejarfile.tmpdir.natives}"> + <mkdir dir="${nativejarfile.tmpdir.natives}/natives" /> + <mkdir dir="${nativejarfile.tmpdir.natives}/natives/${os.and.arch}" /> + <copy todir="${nativejarfile.tmpdir.natives}/natives/${os.and.arch}"> <fileset dir="@{objdir}" includes="@{includelibs}" excludes="@{excludelibs}"/> |