diff options
author | David Tardon <dtardon@redhat.com> | 2012-03-18 11:39:45 +0100 |
---|---|---|
committer | David Tardon <dtardon@redhat.com> | 2012-03-18 21:23:41 +0100 |
commit | 1f09f96e95a74308fee7a1549234c2c364e55e4f (patch) | |
tree | a1018d19254f1aa888a906357ba7850b734ce4f8 /shell | |
parent | 1118f57582aaa7275a8fe1d1460e1515c111ac2e (diff) |
mingw: allow use of system zlib
Diffstat (limited to 'shell')
-rw-r--r-- | shell/inc/internal/types.hxx | 7 | ||||
-rw-r--r-- | shell/inc/internal/zipfile.hxx | 6 | ||||
-rw-r--r-- | shell/source/win32/ooofilereader/makefile.mk | 4 | ||||
-rw-r--r-- | shell/source/win32/shlxthandler/columninfo/makefile.mk | 4 | ||||
-rw-r--r-- | shell/source/win32/shlxthandler/infotips/makefile.mk | 4 | ||||
-rw-r--r-- | shell/source/win32/shlxthandler/makefile.mk | 6 | ||||
-rw-r--r-- | shell/source/win32/shlxthandler/ooofilt/makefile.mk | 6 | ||||
-rw-r--r-- | shell/source/win32/shlxthandler/prophdl/makefile.mk | 2 | ||||
-rw-r--r-- | shell/source/win32/shlxthandler/propsheets/makefile.mk | 4 | ||||
-rw-r--r-- | shell/source/win32/shlxthandler/util/makefile.mk | 4 | ||||
-rw-r--r-- | shell/source/win32/zipfile/makefile.mk | 6 |
11 files changed, 45 insertions, 8 deletions
diff --git a/shell/inc/internal/types.hxx b/shell/inc/internal/types.hxx index a806d02768dd..0c6810aec0d0 100644 --- a/shell/inc/internal/types.hxx +++ b/shell/inc/internal/types.hxx @@ -34,9 +34,14 @@ #include <utility> #include <vector> #include <stack> + +#if defined SYSTEM_ZLIB +#include <zlib.h> +#include <minizip/ioapi.h> +#else #include <external/zlib/zlib.h> #include <external/zlib/ioapi.h> - +#endif typedef std::vector<std::wstring> StringList_t; diff --git a/shell/inc/internal/zipfile.hxx b/shell/inc/internal/zipfile.hxx index 6d8d24b0538c..062ce38cf1af 100644 --- a/shell/inc/internal/zipfile.hxx +++ b/shell/inc/internal/zipfile.hxx @@ -33,9 +33,11 @@ #define _WINDOWS #endif - +#if defined SYSTEM_ZLIB +#include <minizip/unzip.h> +#else #include <external/zlib/unzip.h> - +#endif #include <string> #include <vector> diff --git a/shell/source/win32/ooofilereader/makefile.mk b/shell/source/win32/ooofilereader/makefile.mk index 6b9d1efe3664..b26e10a16795 100644 --- a/shell/source/win32/ooofilereader/makefile.mk +++ b/shell/source/win32/ooofilereader/makefile.mk @@ -47,6 +47,10 @@ CFLAGS_X64+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820 .ENDIF CDEFS_X64+=-U_WIN32_IE -D_WIN32_IE=0x501 -U_WIN32_WINNT -D_WIN32_WINNT=0x0501 +.IF "$(SYSTEM_ZLIB)" == "YES" +CDEFS += -DSYSTEM_ZLIB +.END + # --- Files -------------------------------------------------------- diff --git a/shell/source/win32/shlxthandler/columninfo/makefile.mk b/shell/source/win32/shlxthandler/columninfo/makefile.mk index 31c019f31f76..7157f8f6ae2b 100644 --- a/shell/source/win32/shlxthandler/columninfo/makefile.mk +++ b/shell/source/win32/shlxthandler/columninfo/makefile.mk @@ -42,6 +42,10 @@ CFLAGS+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820 .ENDIF CDEFS+=-U_WIN32_IE -D_WIN32_IE=0x501 -U_WIN32_WINNT -D_WIN32_WINNT=0x0501 +.IF "$(SYSTEM_ZLIB)" == "YES" +CDEFS += -DSYSTEM_ZLIB +.END + # --- Files -------------------------------------------------------- SLOFILES=$(SLO)$/columninfo.obj diff --git a/shell/source/win32/shlxthandler/infotips/makefile.mk b/shell/source/win32/shlxthandler/infotips/makefile.mk index e7caf3afd244..38126a54c697 100644 --- a/shell/source/win32/shlxthandler/infotips/makefile.mk +++ b/shell/source/win32/shlxthandler/infotips/makefile.mk @@ -42,6 +42,10 @@ CFLAGS+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820 .ENDIF CDEFS+=-U_WIN32_IE -D_WIN32_IE=0x501 -U_WIN32_WINNT -D_WIN32_WINNT=0x0501 +.IF "$(SYSTEM_ZLIB)" == "YES" +CDEFS += -DSYSTEM_ZLIB +.END + # --- Files -------------------------------------------------------- SLOFILES=$(SLO)$/$(TARGET).obj diff --git a/shell/source/win32/shlxthandler/makefile.mk b/shell/source/win32/shlxthandler/makefile.mk index b02a27838754..fa2a480dbff6 100644 --- a/shell/source/win32/shlxthandler/makefile.mk +++ b/shell/source/win32/shlxthandler/makefile.mk @@ -59,6 +59,10 @@ CDEFS+=-DDONT_HAVE_GDIPLUS CDEFS+=-U_WIN32_IE -D_WIN32_IE=0x501 -U_WIN32_WINNT -D_WIN32_WINNT=0x0501 +.IF "$(SYSTEM_ZLIB)" == "YES" +CDEFS += -DSYSTEM_ZLIB +.END + # --- Files -------------------------------------------------------- SLOFILES=$(SLO)$/classfactory.obj\ @@ -73,7 +77,7 @@ SLOFILES=$(SLO)$/classfactory.obj\ SHL1TARGET=$(TARGET) .IF "$(COM)"=="GCC" -SHL1STDLIBS=$(ZLIB3RDLIB) $(EXPAT3RDLIB) $(COMCTL32LIB) +SHL1STDLIBS=$(ZLIB3RDLIB) $(MINIZIP3RDLIB) $(EXPAT3RDLIB) $(COMCTL32LIB) SHL1LIBS= .ELSE SHL1STDLIBS= diff --git a/shell/source/win32/shlxthandler/ooofilt/makefile.mk b/shell/source/win32/shlxthandler/ooofilt/makefile.mk index 1748f46df112..afb2988bb12c 100644 --- a/shell/source/win32/shlxthandler/ooofilt/makefile.mk +++ b/shell/source/win32/shlxthandler/ooofilt/makefile.mk @@ -46,6 +46,10 @@ CFLAGS+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820 .ENDIF CDEFS+=-U_WIN32_IE -D_WIN32_IE=0x501 -U_WIN32_WINNT -D_WIN32_WINNT=0x0501 +.IF "$(SYSTEM_ZLIB)" == "YES" +CDEFS += -DSYSTEM_ZLIB +.END + # --- Files -------------------------------------------------------- SLOFILES=$(SLO)$/ooofilt.obj\ @@ -54,7 +58,7 @@ SLOFILES=$(SLO)$/ooofilt.obj\ SHL1TARGET=$(TARGET) .IF "$(COM)"=="GCC" -SHL1STDLIBS=$(ZLIB3RDLIB) $(EXPAT3RDLIB) +SHL1STDLIBS=$(ZLIB3RDLIB) $(MINIZIP3RDLIB) $(EXPAT3RDLIB) SHL1LIBS= .ELSE SHL1STDLIBS= diff --git a/shell/source/win32/shlxthandler/prophdl/makefile.mk b/shell/source/win32/shlxthandler/prophdl/makefile.mk index 64d83a68a4bd..8a6813a616fb 100644 --- a/shell/source/win32/shlxthandler/prophdl/makefile.mk +++ b/shell/source/win32/shlxthandler/prophdl/makefile.mk @@ -63,7 +63,7 @@ SLOFILES=$(SLO)$/$(TARGET).obj\ SHL1TARGET=$(TARGET) .IF "$(COM)"=="GCC" -SHL1STDLIBS=$(ZLIB3RDLIB) $(EXPAT3RDLIB) $(COMCTL32LIB) +SHL1STDLIBS=$(ZLIB3RDLIB) $(MINIZIP3RDLIB) $(EXPAT3RDLIB) $(COMCTL32LIB) SHL1LIBS= .ELSE SHL1STDLIBS= diff --git a/shell/source/win32/shlxthandler/propsheets/makefile.mk b/shell/source/win32/shlxthandler/propsheets/makefile.mk index 5b4405fd90cf..1d67510852fa 100644 --- a/shell/source/win32/shlxthandler/propsheets/makefile.mk +++ b/shell/source/win32/shlxthandler/propsheets/makefile.mk @@ -44,6 +44,10 @@ CFLAGS_X64+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820 CDEFS_X64+=-U_WIN32_IE -D_WIN32_WINNT=0x0501 -U_WIN32_WINNT -D_WIN32_IE=0x501 .ENDIF +.IF "$(SYSTEM_ZLIB)" == "YES" +CDEFS += -DSYSTEM_ZLIB +.END + # --- Files -------------------------------------------------------- SLOFILES=$(SLO)$/propsheets.obj\ diff --git a/shell/source/win32/shlxthandler/util/makefile.mk b/shell/source/win32/shlxthandler/util/makefile.mk index f2edb7f3719e..e2b7a8294319 100644 --- a/shell/source/win32/shlxthandler/util/makefile.mk +++ b/shell/source/win32/shlxthandler/util/makefile.mk @@ -47,6 +47,10 @@ CFLAGS_X64+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820 .ENDIF CDEFS_X64+=-U_WIN32_IE -D_WIN32_IE=0x501 -U_WIN32_WINNT -D_WIN32_WINNT=0x0501 +.IF "$(SYSTEM_ZLIB)" == "YES" +CDEFS += -DSYSTEM_ZLIB +.END + # --- Files -------------------------------------------------------- SLOFILES=$(SLO)$/fileextensions.obj\ diff --git a/shell/source/win32/zipfile/makefile.mk b/shell/source/win32/zipfile/makefile.mk index 93fdf6602ae4..0e165dd01faa 100644 --- a/shell/source/win32/zipfile/makefile.mk +++ b/shell/source/win32/zipfile/makefile.mk @@ -31,12 +31,14 @@ TARGET=zipfile ENABLE_EXCEPTIONS=TRUE EXTERNAL_WARNINGS_NOT_ERRORS := TRUE - - # --- Settings ----------------------------------------------------- .INCLUDE : settings.mk +.IF "$(SYSTEM_ZLIB)" == "YES" +CDEFS += -DSYSTEM_ZLIB +.END + # --- Files -------------------------------------------------------- |