comparison configure.ac @ 17819:af924e6572cb

build: Don't search path at compile time for jvm on Win32 platforms. * configure.ac: Don't search path for jvm on Win32 platforms. It is found through registry at runtime.
author Rik <rik@octave.org>
date Thu, 31 Oct 2013 16:38:32 -0700
parents e6317049225b
children 3488d987eb50
comparison
equal deleted inserted replaced
17818:f1b59ef34eda 17819:af924e6572cb
2456 else 2456 else
2457 AC_MSG_WARN([Java version is too old (< 1.5). Octave will not be able to call Java methods.]) 2457 AC_MSG_WARN([Java version is too old (< 1.5). Octave will not be able to call Java methods.])
2458 break 2458 break
2459 fi 2459 fi
2460 2460
2461 ## At this point Win32/MSVC systems have enough configuration data. We 2461 ## At this point Win32 systems have enough configuration data.
2462 ## assume that all appropriate variables (e.g. INCLUDE and LIB) already have 2462 ## We assume that all appropriate variables (e.g. INCLUDE and LIB) already
2463 ## the required paths to compile and link against JDK. 2463 ## contain the required paths to compile and link against JDK.
2464 case $host_os in 2464 case $host_os in
2465 msdosmsvc) 2465 msdosmsvc)
2466 build_java=yes 2466 build_java=yes
2467 JAVA_LIBS=-ladvapi32 2467 JAVA_LIBS=-ladvapi32
2468 AC_DEFINE(HAVE_JAVA, 1, 2468 AC_DEFINE(HAVE_JAVA, 1,
2469 [Define to 1 if Java is available and is at least version 1.5]) 2469 [Define to 1 if Java is available and is at least version 1.5])
2470 break 2470 break
2471 ;; 2471 ;;
2472 mingw*) 2472 mingw* | cygwin*)
2473 if test $have_msvc = yes; then 2473 build_java=yes
2474 build_java=yes 2474 JAVA_LIBS=-ladvapi32
2475 JAVA_LIBS=-ladvapi32 2475 if test $have_msvc = no; then
2476 AC_DEFINE(HAVE_JAVA, 1, 2476 if test -n "$JAVA_CPPFLAGS"; then
2477 [Define to 1 if Java is available and is at least version 1.5]) 2477 JAVA_CPPFLAGS="-I${JAVA_CPPFLAGS}/include -I${JAVA_CPPFLAGS}/include/win32"
2478 break 2478 else
2479 JAVA_CPPFLAGS="-I${JAVA_HOME}/include -I${JAVA_HOME}/include/win32"
2480 fi
2481 LDFLAGS="$LDFLAGS -Wl,--export-all-symbols"
2479 fi 2482 fi
2483 AC_DEFINE(HAVE_JAVA, 1,
2484 [Define to 1 if Java is available and is at least version 1.5])
2485 break
2480 ;; 2486 ;;
2481 esac 2487 esac
2482 2488
2483 ## Determine which library file name to search for. 2489 ## Determine which library file name to search for.
2484 case $host_os in 2490 case $host_os in
2485 darwin*) 2491 darwin*)
2486 jvmlib=libjvm.dylib 2492 jvmlib=libjvm.dylib
2487 ;;
2488 mingw* | cygwin*)
2489 jvmlib=jvm.dll
2490 ;; 2493 ;;
2491 *) 2494 *)
2492 jvmlib=libjvm.so 2495 jvmlib=libjvm.so
2493 ;; 2496 ;;
2494 esac 2497 esac
2566 JAVA_CPPFLAGS="-I${JAVA_CPPFLAGS}" 2569 JAVA_CPPFLAGS="-I${JAVA_CPPFLAGS}"
2567 else 2570 else
2568 JAVA_CPPFLAGS="-I${JAVA_HOME}/include -I/System/Library/Frameworks/JavaVM.framework/Home/include -I/System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Headers -I/System/Library/Frameworks/JavaVM.framework/Versions/Current/Headers" 2571 JAVA_CPPFLAGS="-I${JAVA_HOME}/include -I/System/Library/Frameworks/JavaVM.framework/Home/include -I/System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Headers -I/System/Library/Frameworks/JavaVM.framework/Versions/Current/Headers"
2569 fi 2572 fi
2570 JAVA_LIBS="-framework JavaVM" 2573 JAVA_LIBS="-framework JavaVM"
2571 ;;
2572 mingw* | cygwin*)
2573 if test -n "$JAVA_CPPFLAGS"; then
2574 JAVA_CPPFLAGS="-I${JAVA_CPPFLAGS}/include -I${JAVA_CPPFLAGS}/include/win32"
2575 else
2576 JAVA_CPPFLAGS="-I${JAVA_HOME}/include -I${JAVA_HOME}/include/win32"
2577 fi
2578 JAVA_LIBS=-ladvapi32
2579 LDFLAGS="$LDFLAGS -Wl,--export-all-symbols"
2580 ;; 2574 ;;
2581 *) 2575 *)
2582 if test -n "$JAVA_CPPFLAGS"; then 2576 if test -n "$JAVA_CPPFLAGS"; then
2583 JAVA_CPPFLAGS="-I${JAVA_CPPFLAGS}/include -I${JAVA_CPPFLAGS}/include/linux" 2577 JAVA_CPPFLAGS="-I${JAVA_CPPFLAGS}/include -I${JAVA_CPPFLAGS}/include/linux"
2584 else 2578 else