Show
Ignore:
Timestamp:
10.01.2013 15:42:38 (7 years ago)
Author:
davidb
Message:

Support for cross-compilation added. In addition to the CrossOS check, this particular set of changes focus on flags that assist cross-compilation with JNI

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone2/common-src/indexers/mg/configure.in

    r25169 r26656  
    125125# set defaults 
    126126JNIINC="" 
     127JNIPREFIX="lib" 
    127128JNISUFFIX="so" 
    128 JNIFLAGS="-shared" 
     129JNICFLAGS="" 
     130JNILDFLAGS="-shared" 
    129131 
    130132if test "`(uname -s) 2> /dev/null`" = 'Darwin'; then 
     
    132134  JNIINC="-I/System/Library/Frameworks/JavaVM.framework/Headers/ " 
    133135  JNISUFFIX="jnilib" 
    134   JNIFLAGS="-dynamiclib -fno-common -single_module -framework JavaVM" 
     136  JNILDFLAGS="-dynamiclib -fno-common -single_module -framework JavaVM" 
    135137fi 
    136138if test "`(uname -s) 2> /dev/null`" = 'SunOS'; then 
     
    140142if test "`(uname -s) 2> /dev/null`" = 'Linux'; then 
    141143  AC_MSG_RESULT(Linux) 
    142   JNIINC="-I\$(JAVA_HOME)/include/linux -I\$(JAVA_HOME)/include " 
     144  JNIINC="-I\$(JAVA_HOME)/include/linux -I\$(JAVA_HOME)/in5Aclude " 
     145fi 
     146 
     147if test "x$crossOS" != "x" ; then 
     148  if test "$crossOS" = "windows" ; then 
     149    JNIINC="-I../../java-windows-include/win32 -I../../java-windows-include " 
     150    JNICFLAGS="-Wall -D_JNI_IMPLEMENTATION_ -Wl,--kill-at" 
     151    JNIPREFIX="" 
     152    JNISUFFIX="dll" 
     153  fi 
    143154fi 
    144155 
    145156AC_SUBST(JNIINC) 
     157AC_SUBST(JNIPREFIX) 
    146158AC_SUBST(JNISUFFIX) 
    147 AC_SUBST(JNIFLAGS) 
     159AC_SUBST(JNICFLAGS) 
     160AC_SUBST(JNILDFLAGS) 
    148161 
    149162fp_WITH_DMALLOC