changeset 3200:5f79be06974b

src/octave.mk: Limit using of separate JNI headers to MinGW cross-compilation
author Anirudha Bose <ani07nov@gmail.com>
date Thu, 01 Aug 2013 17:41:17 +0530
parents f1408becd859
children e62bfaade28d
files src/octave.mk
diffstat 1 files changed, 28 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/octave.mk
+++ b/src/octave.mk
@@ -58,6 +58,33 @@
     echo $(octave_VERSION)
 endef
 
+ifeq ($(MXE_NATIVE_MINGW_BUILD),yes)
+define $(PKG)_BUILD
+    mkdir '$(1)/.build'
+    cd '$(1)' && autoreconf -W none
+    cd '$(1)/.build' && $($(PKG)_CONFIGURE_ENV) '$(1)/configure' \
+        $(CONFIGURE_CPPFLAGS) \
+        $(HOST_AND_BUILD_CONFIGURE_OPTIONS) \
+        --prefix='$($(PKG)_PREFIX)' \
+	--enable-docs \
+        $($(PKG)_BLAS_OPTION) \
+	$($(PKG)_CROSS_CONFIG_OPTIONS) \
+        $($(PKG)_ENABLE_64_CONFIGURE_OPTIONS) \
+        $($(PKG)_ENABLE_JIT_CONFIGURE_OPTIONS) \
+	$($(PKG)_EXTRA_CONFIGURE_OPTIONS) \
+	PKG_CONFIG='$(MXE_PKG_CONFIG)' \
+	PKG_CONFIG_PATH='$(HOST_LIBDIR)/pkgconfig' \
+        && $($(PKG)_CONFIGURE_POST_HOOK)
+
+    ## We want both of these install steps so that we install in the
+    ## location set by the configure --prefix option, and the other
+    ## in a directory tree that will have just Octave files.
+    $(MAKE) -C '$(1)/.build' -j '$(JOBS)' install install-pdf install-html
+    if [ $(MXE_SYSTEM) != msvc ]; then \
+        $(MAKE) -C '$(1)/.build' -j '$(JOBS)' DESTDIR=$(TOP_DIR)/octave install; \
+    fi
+endef
+else
 define $(PKG)_BUILD
     mkdir '$(1)/.build'
     mkdir -p '$(HOST_PREFIX)/include/java/include'
@@ -89,4 +116,4 @@
         $(MAKE) -C '$(1)/.build' -j '$(JOBS)' DESTDIR=$(TOP_DIR)/octave install; \
     fi
 endef
-
+endif