changeset 3673:972f2d9c76ca

tar-dist: update dist rules for native-mingw tar-dist to work (Bug #42874) * binary-dist-rules.mk: only include windows dist deps of native-*, npp and msys-base if not native mingw build. change copy-windows-dist-files for same.
author John Donoghue
date Thu, 31 Jul 2014 11:23:18 -0400
parents 05e3d28e2e67
children 78e9c838e0c8
files binary-dist-rules.mk
diffstat 1 files changed, 39 insertions(+), 23 deletions(-) [+]
line wrap: on
line diff
--- a/binary-dist-rules.mk	Fri Aug 01 09:16:07 2014 -0400
+++ b/binary-dist-rules.mk	Thu Jul 31 11:23:18 2014 -0400
@@ -12,10 +12,15 @@
 ifeq ($(MXE_WINDOWS_BUILD),yes)
   TAR_H_OPTION := -h
   WINDOWS_BINARY_DIST_DEPS := \
-    msys-base \
-    native-binutils \
-    native-gcc \
-    npp
+    msys-base 
+
+  ifeq ($(MXE_NATIVE_BUILD),no)
+    WINDOWS_BINARY_DIST_DEPS += \
+      native-binutils \
+      native-gcc \
+      npp
+  endif
+
 endif
 
 BINARY_DIST_DEPS := \
@@ -48,25 +53,36 @@
 endef
 
 ifeq ($(MXE_WINDOWS_BUILD),yes)
-  define copy-windows-dist-files
-    echo "  DLL files..."
-    cp $(BUILD_TOOLS_PREFIX)/lib/gcc/$(TARGET)/*.dll $(OCTAVE_DIST_DIR)/bin
-    cp $(BUILD_TOOLS_PREFIX)/lib/gcc/$(TARGET)/*.dll $(OCTAVE_DIST_DIR)/bin
-    cp $(BUILD_TOOLS_PREFIX)/lib/gcc/$(TARGET)/$(build-gcc_VERSION)/*.dll $(OCTAVE_DIST_DIR)/bin
-    echo "  msys base files..."
-    cd $(TOP_DIR)/msys-base \
-      && tar -c $(TAR_H_OPTION) -f - . | ( cd $(OCTAVE_DIST_DIR) ; tar xpf - )
-    echo "  msys extension files..."
-    cd $(TOP_DIR)/msys-extension \
-      && tar -c $(TAR_H_OPTION) -f - . | ( cd $(OCTAVE_DIST_DIR) ; tar xpf - )
-    echo "  notepad++..."
-    cd $(TOP_DIR) \
-      && tar -c $(TAR_H_OPTION) -f - notepad++ | ( cd $(OCTAVE_DIST_DIR) ; tar xpf - )
-    echo "  README.html..."
-    cp $(TOP_DIR)/installer-files/README.html $(OCTAVE_DIST_DIR)/
-    echo "  refblas..."
-    cp $(OCTAVE_DIST_DIR)/bin/libblas.dll $(OCTAVE_DIST_DIR)/bin/librefblas.dll
-  endef
+  ifeq ($(MXE_NATIVE_BUILD),no)
+    define copy-windows-dist-files
+      echo "  DLL files..."
+      cp $(BUILD_TOOLS_PREFIX)/lib/gcc/$(TARGET)/*.dll $(OCTAVE_DIST_DIR)/bin
+      cp $(BUILD_TOOLS_PREFIX)/lib/gcc/$(TARGET)/*.dll $(OCTAVE_DIST_DIR)/bin
+      cp $(BUILD_TOOLS_PREFIX)/lib/gcc/$(TARGET)/$(build-gcc_VERSION)/*.dll $(OCTAVE_DIST_DIR)/bin
+      echo "  msys base files..."
+      cd $(TOP_DIR)/msys-base \
+        && tar -c $(TAR_H_OPTION) -f - . | ( cd $(OCTAVE_DIST_DIR) ; tar xpf - )
+      echo "  msys extension files..."
+      cd $(TOP_DIR)/msys-extension \
+        && tar -c $(TAR_H_OPTION) -f - . | ( cd $(OCTAVE_DIST_DIR) ; tar xpf - )
+      echo "  notepad++..."
+      cd $(TOP_DIR) \
+          && tar -c $(TAR_H_OPTION) -f - notepad++ | ( cd $(OCTAVE_DIST_DIR) ; tar xpf - )
+      echo "  README.html..."
+      cp $(TOP_DIR)/installer-files/README.html $(OCTAVE_DIST_DIR)/
+      echo "  refblas..."
+      cp $(OCTAVE_DIST_DIR)/bin/libblas.dll $(OCTAVE_DIST_DIR)/bin/librefblas.dll
+    endef
+  else
+    define copy-windows-dist-files
+      echo "  DLL files..."
+      cp /mingw/bin/*.dll $(OCTAVE_DIST_DIR)/bin
+      echo "  README.html..."
+      cp $(TOP_DIR)/installer-files/README.html $(OCTAVE_DIST_DIR)/
+      echo "  refblas..."
+      cp $(OCTAVE_DIST_DIR)/bin/libblas.dll $(OCTAVE_DIST_DIR)/bin/librefblas.dll
+    endef
+  endif
 endif
 
 define make-dist-files-writable