external/zlib-1.2.11.patch
author Sam Lantinga <slouken@libsdl.org>
Fri, 26 Oct 2018 14:58:01 -0700
changeset 617 d64228a395fc
parent 522 cdbdf5652e8e
permissions -rw-r--r--
Fixed webp library detection when cross-compiling for Windows
slouken@522
     1
diff -ruN zlib-1.2.11.orig/make-cross-x64.sh zlib-1.2.11/make-cross-x64.sh
slouken@522
     2
--- zlib-1.2.11.orig/make-cross-x64.sh	1969-12-31 16:00:00.000000000 -0800
slouken@522
     3
+++ zlib-1.2.11/make-cross-x64.sh	2017-10-21 21:09:10.000000000 -0700
slouken@522
     4
@@ -0,0 +1,14 @@
slouken@522
     5
+#!/bin/sh
slouken@522
     6
+
slouken@522
     7
+TARGET=x86_64-w64-mingw32
slouken@522
     8
+INSTALL_PATH=/usr/local/$TARGET
slouken@522
     9
+export PATH=$PATH:/usr/local/bin
slouken@522
    10
+
slouken@522
    11
+make -f win32/Makefile.gcc \
slouken@522
    12
+    SHARED_MODE=1 \
slouken@522
    13
+    LDFLAGS=-static-libgcc \
slouken@522
    14
+    PREFIX=$TARGET- \
slouken@522
    15
+    prefix=$INSTALL_PATH \
slouken@522
    16
+    BINARY_PATH=$INSTALL_PATH/bin \
slouken@522
    17
+    INCLUDE_PATH=$INSTALL_PATH/include \
slouken@522
    18
+    LIBRARY_PATH=$INSTALL_PATH/lib $*
slouken@522
    19
diff -ruN zlib-1.2.11.orig/make-cross-x86.sh zlib-1.2.11/make-cross-x86.sh
slouken@522
    20
--- zlib-1.2.11.orig/make-cross-x86.sh	1969-12-31 16:00:00.000000000 -0800
slouken@522
    21
+++ zlib-1.2.11/make-cross-x86.sh	2017-10-21 21:09:10.000000000 -0700
slouken@522
    22
@@ -0,0 +1,14 @@
slouken@522
    23
+#!/bin/sh
slouken@522
    24
+
slouken@522
    25
+TARGET=i686-w64-mingw32
slouken@522
    26
+INSTALL_PATH=/usr/local/$TARGET
slouken@522
    27
+export PATH=$PATH:/usr/local/bin
slouken@522
    28
+
slouken@522
    29
+make -f win32/Makefile.gcc \
slouken@522
    30
+    SHARED_MODE=1 \
slouken@522
    31
+    LDFLAGS=-static-libgcc \
slouken@522
    32
+    PREFIX=$TARGET- \
slouken@522
    33
+    prefix=$INSTALL_PATH \
slouken@522
    34
+    BINARY_PATH=$INSTALL_PATH/bin \
slouken@522
    35
+    INCLUDE_PATH=$INSTALL_PATH/include \
slouken@522
    36
+    LIBRARY_PATH=$INSTALL_PATH/lib $*