Kaydet (Commit) 3934efe2 authored tarafından Caolán McNamara's avatar Caolán McNamara

sigh, need a 64bit zlib too on windows, reverting

üst 134fe756
...@@ -90,12 +90,12 @@ endef ...@@ -90,12 +90,12 @@ endef
else # !SYSTEM_ZLIB else # !SYSTEM_ZLIB
$(eval $(call gb_Helper_register_static_libraries,PLAINLIBS, \ $(eval $(call gb_Helper_register_static_libraries,PLAINLIBS, \
z \ zlib \
)) ))
define gb_LinkTarget__use_zlib define gb_LinkTarget__use_zlib
$(call gb_LinkTarget_use_static_libraries,$(1),\ $(call gb_LinkTarget_use_static_libraries,$(1),\
z \ zlib \
) )
endef endef
......
...@@ -54,7 +54,7 @@ gb_Library_DLLFILENAMES := $(patsubst icuuc:icuuc%,icuuc:icuuc40%,$(gb_Library_D ...@@ -54,7 +54,7 @@ gb_Library_DLLFILENAMES := $(patsubst icuuc:icuuc%,icuuc:icuuc40%,$(gb_Library_D
gb_Library_DLLFILENAMES := $(patsubst log_uno:log_uno%,log_uno:log_uno_uno%,$(gb_Library_DLLFILENAMES)) gb_Library_DLLFILENAMES := $(patsubst log_uno:log_uno%,log_uno:log_uno_uno%,$(gb_Library_DLLFILENAMES))
gb_Library_DLLFILENAMES := $(patsubst ucbhelper:ucbhelper%,ucbhelper:ucbhelper4%,$(gb_Library_DLLFILENAMES)) gb_Library_DLLFILENAMES := $(patsubst ucbhelper:ucbhelper%,ucbhelper:ucbhelper4%,$(gb_Library_DLLFILENAMES))
gb_Library_DLLFILENAMES := $(patsubst unsafe_uno:unsafe_uno%,unsafe_uno:unsafe_uno_uno%,$(gb_Library_DLLFILENAMES)) gb_Library_DLLFILENAMES := $(patsubst unsafe_uno:unsafe_uno%,unsafe_uno:unsafe_uno_uno%,$(gb_Library_DLLFILENAMES))
gb_Library_DLLFILENAMES := $(patsubst z:z%,z:z%,$(gb_Library_DLLFILENAMES)) gb_Library_DLLFILENAMES := $(patsubst z:z%,z:zlib%,$(gb_Library_DLLFILENAMES))
gb_Library_FILENAMES := $(patsubst sb:isb%,sb:basic%,$(gb_Library_FILENAMES)) gb_Library_FILENAMES := $(patsubst sb:isb%,sb:basic%,$(gb_Library_FILENAMES))
gb_Library_FILENAMES := $(patsubst sfx:isfx%,sfx:sfx%,$(gb_Library_FILENAMES)) gb_Library_FILENAMES := $(patsubst sfx:isfx%,sfx:sfx%,$(gb_Library_FILENAMES))
...@@ -74,7 +74,7 @@ gb_Library_FILENAMES := $(patsubst rdf:irdf%,rdf:librdf.dll$(gb_Library_IARCEXT) ...@@ -74,7 +74,7 @@ gb_Library_FILENAMES := $(patsubst rdf:irdf%,rdf:librdf.dll$(gb_Library_IARCEXT)
gb_Library_FILENAMES := $(patsubst ssl:issl%,ssl:ssl%,$(gb_Library_FILENAMES)) gb_Library_FILENAMES := $(patsubst ssl:issl%,ssl:ssl%,$(gb_Library_FILENAMES))
gb_Library_FILENAMES := $(patsubst xml2:ixml2%,xml2:libxml2$(gb_Library_IARCEXT),$(gb_Library_FILENAMES)) gb_Library_FILENAMES := $(patsubst xml2:ixml2%,xml2:libxml2$(gb_Library_IARCEXT),$(gb_Library_FILENAMES))
gb_Library_FILENAMES := $(patsubst xslt:ixslt%,xslt:libxslt$(gb_Library_IARCEXT),$(gb_Library_FILENAMES)) gb_Library_FILENAMES := $(patsubst xslt:ixslt%,xslt:libxslt$(gb_Library_IARCEXT),$(gb_Library_FILENAMES))
gb_Library_FILENAMES := $(patsubst z:iz%,z:z%,$(gb_Library_FILENAMES)) gb_Library_FILENAMES := $(patsubst z:iz%,z:zlib%,$(gb_Library_FILENAMES))
# Libraries not provided by mingw(-w64), available only in the Windows # Libraries not provided by mingw(-w64), available only in the Windows
...@@ -109,7 +109,7 @@ gb_Library_FILENAMES := $(patsubst xmlsec1:ixmlsec1%,xmlsec1:libxmlsec%,$(gb_Lib ...@@ -109,7 +109,7 @@ gb_Library_FILENAMES := $(patsubst xmlsec1:ixmlsec1%,xmlsec1:libxmlsec%,$(gb_Lib
gb_Library_FILENAMES := $(patsubst xmlsec1-mscrypto:ixmlsec1-mscrypto%,xmlsec1-mscrypto:libxmlsec-mscrypto%,$(gb_Library_FILENAMES)) gb_Library_FILENAMES := $(patsubst xmlsec1-mscrypto:ixmlsec1-mscrypto%,xmlsec1-mscrypto:libxmlsec-mscrypto%,$(gb_Library_FILENAMES))
gb_Library_FILENAMES := $(patsubst xmlsec1-nss:ixmlsec1-nss%,xmlsec1-nss:libxmlsec-nss%,$(gb_Library_FILENAMES)) gb_Library_FILENAMES := $(patsubst xmlsec1-nss:ixmlsec1-nss%,xmlsec1-nss:libxmlsec-nss%,$(gb_Library_FILENAMES))
gb_Library_FILENAMES := $(patsubst xslt:ixslt%,xslt:libxslt%,$(gb_Library_FILENAMES)) gb_Library_FILENAMES := $(patsubst xslt:ixslt%,xslt:libxslt%,$(gb_Library_FILENAMES))
gb_Library_FILENAMES := $(patsubst z:z%,z:z%,$(gb_Library_FILENAMES)) gb_Library_FILENAMES := $(patsubst z:z%,z:zlib%,$(gb_Library_FILENAMES))
# change the names of all import libraries that don't have an "i" prefix as in our standard naming schema # change the names of all import libraries that don't have an "i" prefix as in our standard naming schema
......
...@@ -139,7 +139,6 @@ $(eval $(call gb_Module_add_moduledirs,ooo,\ ...@@ -139,7 +139,6 @@ $(eval $(call gb_Module_add_moduledirs,ooo,\
xmloff \ xmloff \
xmlreader \ xmlreader \
xmlscript \ xmlscript \
zlib \
)) ))
ifneq ($(SOLAR_JAVA),) ifneq ($(SOLAR_JAVA),)
......
...@@ -38,7 +38,7 @@ ...@@ -38,7 +38,7 @@
DEFAULT_CFLAGS += -I. -I$(top_srcdir) DEFAULT_CFLAGS += -I. -I$(top_srcdir)
DEFAULT_CFLAGS += $(PIXMAN_CFLAGS) $(LIBPNG_CFLAGS) $(ZLIB_CFLAGS) DEFAULT_CFLAGS += $(PIXMAN_CFLAGS) $(LIBPNG_CFLAGS) $(ZLIB_CFLAGS)
+DEFAULT_CFLAGS += $(SOLARINC) +DEFAULT_CFLAGS += $(SOLARINC)
+DEFAULT_CFLAGS += -I$(SOLARVER)/$(INPATH)/inc/external/libpng -DDISABLE_SOME_FLOATING_POINT=1 +DEFAULT_CFLAGS += -I$(SOLARVER)/$(INPATH)/inc/zlib -I$(SOLARVER)/$(INPATH)/inc/external/libpng -DZLIB_FIX -DDISABLE_SOME_FLOATING_POINT=1
CAIRO_CFLAGS = $(DEFAULT_CFLAGS) $(CFLAGS) CAIRO_CFLAGS = $(DEFAULT_CFLAGS) $(CFLAGS)
...@@ -189,6 +189,20 @@ ...@@ -189,6 +189,20 @@
cairo_cv_xml_use=$use_xml cairo_cv_xml_use=$use_xml
cairo_cv_xml_cache_vars=" BASE REQUIRES CFLAGS NONPKGCONFIG_CFLAGS LIBS NONPKGCONFIG_LIBS NONPKGCONFIG_EXTRA_LIBS" cairo_cv_xml_cache_vars=" BASE REQUIRES CFLAGS NONPKGCONFIG_CFLAGS LIBS NONPKGCONFIG_LIBS NONPKGCONFIG_EXTRA_LIBS"
--- misc/cairo-1.10.2/src/cairo-deflate-stream.c 2010-06-18 13:47:12.000000000 +0200
+++ misc/build/cairo-1.10.2/src/cairo-deflate-stream.c 2010-06-18 13:47:12.000000000 +0200
@@ -37,7 +37,11 @@
#include "cairoint.h"
#include "cairo-error-private.h"
#include "cairo-output-stream-private.h"
+#ifdef ZLIB_FIX
+#include <zlib/zlib.h>
+#else
#include <zlib.h>
+#endif
#define BUFFER_SIZE 16384
--- misc/cairo-1.10.2/src/cairo-output-stream.c 2010-07-12 10:57:03.000000000 +0200 --- misc/cairo-1.10.2/src/cairo-output-stream.c 2010-07-12 10:57:03.000000000 +0200
+++ misc/build/cairo-1.10.2/src/cairo-output-stream.c 2010-07-12 10:57:03.000000000 +0200 +++ misc/build/cairo-1.10.2/src/cairo-output-stream.c 2010-07-12 10:57:03.000000000 +0200
@@ -313,7 +313,11 @@ @@ -313,7 +313,11 @@
...@@ -203,6 +217,34 @@ ...@@ -203,6 +217,34 @@
decimal_point_len = strlen (decimal_point); decimal_point_len = strlen (decimal_point);
assert (decimal_point_len != 0); assert (decimal_point_len != 0);
--- misc/cairo-1.10.2/src/cairo-pdf-surface.c 2010-12-25 15:21:34.000000000 +0100
+++ misc/build/cairo-1.10.2/src/cairo-pdf-surface.c 2010-12-25 15:21:34.000000000 +0100
@@ -57,7 +57,11 @@
#include "cairo-type3-glyph-surface-private.h"
#include <time.h>
+#ifdef ZLIB_FIX
+#include <zlib/zlib.h>
+#else
#include <zlib.h>
+#endif
/* Issues:
*
--- misc/cairo-1.10.2/src/cairo-ps-surface.c 2010-12-25 15:21:34.000000000 +0100
+++ misc/build/cairo-1.10.2/src/cairo-ps-surface.c 2010-12-25 15:21:34.000000000 +0100
@@ -72,7 +72,11 @@
#include <stdio.h>
#include <ctype.h>
#include <time.h>
+#ifdef ZLIB_FIX
+#include <zlib/zlib.h>
+#else
#include <zlib.h>
+#endif
#include <errno.h>
#define DEBUG_PS 0
--- misc/cairo-1.10.2/src/cairo-ft-font.c 2010-12-25 15:21:34.000000000 +0100 --- misc/cairo-1.10.2/src/cairo-ft-font.c 2010-12-25 15:21:34.000000000 +0100
+++ misc/build/cairo-1.10.2/src/cairo-ft-font.c 2010-12-25 15:21:34.000000000 +0100 +++ misc/build/cairo-1.10.2/src/cairo-ft-font.c 2010-12-25 15:21:34.000000000 +0100
@@ -534,16 +534,16 @@ @@ -534,16 +534,16 @@
......
...@@ -70,7 +70,12 @@ cairo_LDFLAGS=-L$(SOLARVER)$/$(INPATH)$/lib ...@@ -70,7 +70,12 @@ cairo_LDFLAGS=-L$(SOLARVER)$/$(INPATH)$/lib
cairo_CPPFLAGS= cairo_CPPFLAGS=
.IF "$(SYSTEM_ZLIB)"!="YES"
cairo_CPPFLAGS+=-I$(SOLARINCDIR)$/external$/zlib
cairo_COMPRESS=z_compress
.ELSE
cairo_COMPRESS=compress cairo_COMPRESS=compress
.ENDIF
cairo_CPPFLAGS+=$(INCLUDE) cairo_CPPFLAGS+=$(INCLUDE)
.IF "$(OS)"=="WNT" .IF "$(OS)"=="WNT"
......
...@@ -61,6 +61,7 @@ $(CLSO)/done : $(cl_FIXED_TARFILE_LOCATION) \ ...@@ -61,6 +61,7 @@ $(CLSO)/done : $(cl_FIXED_TARFILE_LOCATION) \
$(call gb_Helper_abbreviate_dirs, \ $(call gb_Helper_abbreviate_dirs, \
mkdir -p $(dir $@) && cd $(dir $@) && \ mkdir -p $(dir $@) && cd $(dir $@) && \
$(GNUTAR) -x -z $(STRIP_COMPONENTS)=1 -f $< && \ $(GNUTAR) -x -z $(STRIP_COMPONENTS)=1 -f $< && \
$(GNUPATCH) -p0 < $(SRCDIR)/clucene/patches/clucene-internal-zlib.patch && \
$(GNUPATCH) -p0 < $(SRCDIR)/clucene/patches/clucene-warnings.patch && \ $(GNUPATCH) -p0 < $(SRCDIR)/clucene/patches/clucene-warnings.patch && \
$(GNUPATCH) -p0 < $(SRCDIR)/clucene/patches/clucene-gcc-atomics.patch && \ $(GNUPATCH) -p0 < $(SRCDIR)/clucene/patches/clucene-gcc-atomics.patch && \
$(GNUPATCH) -p0 < $(SRCDIR)/clucene/patches/clucene-debug.patch && \ $(GNUPATCH) -p0 < $(SRCDIR)/clucene/patches/clucene-debug.patch && \
......
--- src/shared/CLucene/util/Misc.cpp 2012-02-17 15:33:09.217891100 +0000
+++ src/shared/CLucene/util/Misc.cpp 2012-02-17 15:38:10.836597500 +0000
@@ -34,7 +34,11 @@
#include "CLucene/util/dirent.h" //if we have dirent, then the native one will be used
//for zlib...
-#include "zlib.h"
+#ifdef SYSTEM_ZLIB
+#include <zlib.h>
+#else
+#include <external/zlib/zlib.h>
+#endif
#if defined(MSDOS) || defined(OS2) || defined(WIN32) || defined(__CYGWIN__)
# include <fcntl.h>
# include <io.h>
...@@ -41,7 +41,13 @@ ...@@ -41,7 +41,13 @@
#include <vcl/graphictools.hxx> #include <vcl/graphictools.hxx>
#include <vcl/rendergraphicrasterizer.hxx> #include <vcl/rendergraphicrasterizer.hxx>
#ifndef _ZLIB_H
#ifdef SYSTEM_ZLIB
#include <zlib.h> #include <zlib.h>
#else
#include <external/zlib/zlib.h>
#endif
#endif
#include <vcl/salbtype.hxx> #include <vcl/salbtype.hxx>
#include <basegfx/polygon/b2dpolygon.hxx> #include <basegfx/polygon/b2dpolygon.hxx>
......
...@@ -208,7 +208,7 @@ ...@@ -208,7 +208,7 @@
+GLIB_LIB = $(OUTDIR)\lib\glib-2.0.lib $(OUTDIR)\lib\gobject-2.0.lib $(OUTDIR)\lib\gmodule-2.0.lib $(OUTDIR)\lib\gio-2.0.lib $(OUTDIR)\lib\gthread-2.0.lib +GLIB_LIB = $(OUTDIR)\lib\glib-2.0.lib $(OUTDIR)\lib\gobject-2.0.lib $(OUTDIR)\lib\gmodule-2.0.lib $(OUTDIR)\lib\gio-2.0.lib $(OUTDIR)\lib\gthread-2.0.lib
+LIBJPEG_LIB = $(OUTDIR)\lib\jpeg.lib +LIBJPEG_LIB = $(OUTDIR)\lib\jpeg.lib
+LIBPNG_LIB = $(OUTDIR)\lib\libpng.lib +LIBPNG_LIB = $(OUTDIR)\lib\libpng.lib
+ZLIB_LIB = $(OUTDIR)\lib\z.lib +ZLIB_LIB = $(OUTDIR)\lib\zlib.lib
+GDIPLUS_LIB = gdiplus.lib +GDIPLUS_LIB = gdiplus.lib
-!INCLUDE $(TOP)/glib/build/win32/make.msc -!INCLUDE $(TOP)/glib/build/win32/make.msc
......
...@@ -73,17 +73,26 @@ ...@@ -73,17 +73,26 @@
!IFDEF ZLIB !IFDEF ZLIB
ZLIB_CFLAGS = -I $(ZLIB) ZLIB_CFLAGS = -I $(ZLIB)
-ZLIB_LIBS = $(ZLIB)\projects\visualc6\Win32_LIB_Release\zlib.lib -ZLIB_LIBS = $(ZLIB)\projects\visualc6\Win32_LIB_Release\zlib.lib
+ZLIB_LIBS = $(OUTDIR)\lib\z.lib +ZLIB_LIBS = $(OUTDIR)\lib\zlib.lib
!ELSE !ELSE
-ZLIB_CFLAGS = -I $(DEVTOP)\include -ZLIB_CFLAGS = -I $(DEVTOP)\include
-ZLIB_LIBS = $(DEVTOP)\lib\zdll.lib -ZLIB_LIBS = $(DEVTOP)\lib\zdll.lib
+ZLIB_CFLAGS = -I $(OUTDIR)\inc\external +ZLIB_CFLAGS = -I $(OUTDIR)\inc\external\zlib
+ZLIB_LIBS = $(OUTDIR)\lib\z.lib +ZLIB_LIBS = $(OUTDIR)\lib\zlib.lib
!ENDIF !ENDIF
################ ################
--- misc/glib-2.28.1/gio/gzlibcompressor.c 2011-02-11 16:23:12.000000000 +0100 --- misc/glib-2.28.1/gio/gzlibcompressor.c 2011-02-11 16:23:12.000000000 +0100
+++ misc/build/glib-2.28.1/gio/gzlibcompressor.c 2011-03-07 10:33:19.559189800 +0100 +++ misc/build/glib-2.28.1/gio/gzlibcompressor.c 2011-03-07 10:33:19.559189800 +0100
@@ -25,7 +25,7 @@
#include "gzlibcompressor.h"
#include <errno.h>
-#include <zlib.h>
+#include <zlib/zlib.h>
#include <string.h>
#include "gfileinfo.h"
@@ -64,8 +64,10 @@ @@ -64,8 +64,10 @@
GZlibCompressorFormat format; GZlibCompressorFormat format;
...@@ -106,6 +115,15 @@ ...@@ -106,6 +115,15 @@
if (compressor->format != G_ZLIB_COMPRESSOR_FORMAT_GZIP || if (compressor->format != G_ZLIB_COMPRESSOR_FORMAT_GZIP ||
--- misc/glib-2.28.1/gio/gzlibdecompressor.c 2011-03-07 09:13:41.324890400 +0100 --- misc/glib-2.28.1/gio/gzlibdecompressor.c 2011-03-07 09:13:41.324890400 +0100
+++ misc/build/glib-2.28.1/gio/gzlibdecompressor.c 2011-03-04 11:28:39.712480200 +0100 +++ misc/build/glib-2.28.1/gio/gzlibdecompressor.c 2011-03-04 11:28:39.712480200 +0100
@@ -25,7 +25,7 @@
#include "gzlibdecompressor.h"
#include <errno.h>
-#include <zlib.h>
+#include <zlib/zlib.h>
#include <string.h>
#include "gfileinfo.h"
@@ -76,7 +76,7 @@ @@ -76,7 +76,7 @@
g_zlib_decompressor_set_gzheader (GZlibDecompressor *decompressor) g_zlib_decompressor_set_gzheader (GZlibDecompressor *decompressor)
{ {
......
...@@ -29,7 +29,12 @@ ...@@ -29,7 +29,12 @@
#ifndef _HWPGZIP_H_ #ifndef _HWPGZIP_H_
#define _HWPGZIP_H_ #define _HWPGZIP_H_
// DVO: add zlib/ prefix
#ifdef SYSTEM_ZLIB
#include <zlib.h> #include <zlib.h>
#else
#include "zlib/zlib.h"
#endif
class HStream; class HStream;
/** /**
......
...@@ -28,7 +28,12 @@ ...@@ -28,7 +28,12 @@
#include <stdio.h> #include <stdio.h>
#include <errno.h> #include <errno.h>
// DVO: add zlib/ prefix
#ifdef SYSTEM_ZLIB
#include <zlib.h> #include <zlib.h>
#else
#include <zlib/zlib.h>
#endif
#ifdef WIN32 #ifdef WIN32
# include <io.h> # include <io.h>
#else #else
......
...@@ -55,7 +55,7 @@ ...@@ -55,7 +55,7 @@
+ +
+.INCLUDE : settings.mk +.INCLUDE : settings.mk
+ +
+CFLAGS+= -I.. -I$(SOLARINCDIR)$/external$/glib-2.0 -I$(SOLARINCDIR)$/external +CFLAGS+= -I.. -I$(SOLARINCDIR)$/external$/glib-2.0 -I$(SOLARINCDIR)$/external$/zlib -I$(SOLARINCDIR)$/external
+ +
+# --- Files ------------------------------------- +# --- Files -------------------------------------
+ +
...@@ -115,7 +115,7 @@ ...@@ -115,7 +115,7 @@
+ gobject-2.0.lib \ + gobject-2.0.lib \
+ glib-2.0.lib \ + glib-2.0.lib \
+ intl.lib \ + intl.lib \
+ z.lib \ + zlib.lib \
+ Advapi32.lib + Advapi32.lib
+ +
+ +
......
...@@ -231,3 +231,51 @@ ...@@ -231,3 +231,51 @@
+#define PNG_iTXt_SUPPORTED +#define PNG_iTXt_SUPPORTED
+/* end of options */ +/* end of options */
+#endif /* PNGLCONF_H */ +#endif /* PNGLCONF_H */
--- misc/libpng-1.5.1/pngstruct.h 2011-02-03 05:58:17.000000000 +0100
+++ misc/build/libpng-1.5.1/pngstruct.h 2011-03-24 21:47:23.380397048 +0100
@@ -24,7 +24,15 @@
* in this structure and is required for decompressing the LZ compressed
* data in PNG files.
*/
+/* WTF, surely this should depend explicitly on whether using the system or
+ * internal zlib, not on OS... But yeah, so maybe MacOSX, iOS and Android are the only OSes for which
+ * we use a system zlib but internal libpng, at least by default.
+ */
+#if defined MACOSX || defined IOS || defined ANDROID
#include "zlib.h"
+#else
+#include <external/zlib/zlib.h>
+#endif
struct png_struct_def
{
--- misc/libpng-1.5.1/pngtest.c 2011-02-03 05:58:17.000000000 +0100
+++ misc/build/libpng-1.5.1/pngtest.c 2011-03-24 21:47:23.380397048 +0100
@@ -31,7 +31,12 @@
* of files at once by typing "pngtest -m file1.png file2.png ..."
*/
+#if defined MACOSX || defined IOS || defined ANDROID
#include "zlib.h"
+#else
+#include <external/zlib/zlib.h>
+#endif
+
#include "png.h"
/* Copied from pngpriv.h but only used in error messages below. */
#ifndef PNG_ZBUF_SIZE
--- misc/libpng-1.5.1/pngvalid.c 2011-02-03 05:58:17.000000000 +0100
+++ misc/build/libpng-1.5.1/pngvalid.c 2011-03-24 21:47:23.381397048 +0100
@@ -51,7 +51,11 @@
#define PNG_READ_16BIT_SUPPORTED
#endif
-#include "zlib.h" /* For crc32 */
+#if defined MACOSX || defined IOS || defined ANDROID
+#include "zlib.h"
+#else
+#include <external/zlib/zlib.h>
+#endif
#include <float.h> /* For floating point constants */
#include <stdlib.h> /* For malloc */
...@@ -220,14 +220,16 @@ MOZDIR=$(MISC)$/build$/seamonkey ...@@ -220,14 +220,16 @@ MOZDIR=$(MISC)$/build$/seamonkey
MOZTARGET=$(OS)$(COM)$(CPU) MOZTARGET=$(OS)$(COM)$(CPU)
.IF "$(GUI)"=="WNT" .IF "$(GUI)"=="WNT"
#for moz to link to our static lz if necessary
SYSTEM_ZLIB:="YES"
# "Our" build environment uses "NO" for the environment variable that # "Our" build environment uses "NO" for the environment variable that
# indicate if system libraries should be used, the mozilla build uses # indicate if system libraries should be used, the mozilla build uses
# "" in this case. This conflicts (at least for W32) with mozilla (1.7b) # "" in this case. This conflicts (at least for W32) with mozilla (1.7b)
# because it disables the library checks for msvc so that # because it disables the library checks for msvc so that
# --without-system-* is not evaluated. To build the included libraries # --without-system-* is not evaluated. To build the included libraries
# the affected variables have to be empty and not NO. # the affected variables have to be empty and not NO.
.IF "$(SYSTEM_ZLIB)"=="NO"
SYSTEM_ZLIB:=
.EXPORT : SYSTEM_ZLIB
.ENDIF
.IF "$(SYSTEM_JPEG)"=="NO" .IF "$(SYSTEM_JPEG)"=="NO"
SYSTEM_JPEG:= SYSTEM_JPEG:=
.EXPORT : SYSTEM_JPEG .EXPORT : SYSTEM_JPEG
......
...@@ -492,7 +492,7 @@ ...@@ -492,7 +492,7 @@
+#endif +#endif
--- misc/neon-0.29.5/src/makefile.mk 2011-02-03 10:32:38.000000000 +0100 --- misc/neon-0.29.5/src/makefile.mk 2011-02-03 10:32:38.000000000 +0100
+++ misc/build/neon-0.29.5/src/makefile.mk 2011-02-03 10:26:19.000000000 +0100 +++ misc/build/neon-0.29.5/src/makefile.mk 2011-02-03 10:26:19.000000000 +0100
@@ -1,1 +1,89 @@ @@ -1,1 +1,96 @@
-dummy -dummy
+PRJ=..$/..$/..$/..$/.. +PRJ=..$/..$/..$/..$/..
+ +
...@@ -523,6 +523,13 @@ ...@@ -523,6 +523,13 @@
+CFLAGS+= $(OPENSSL_CFLAGS) +CFLAGS+= $(OPENSSL_CFLAGS)
+.ENDIF +.ENDIF
+ +
+.IF "$(SYSTEM_ZLIB)" == "YES"
+CFLAGS+=-DSYSTEM_ZLIB
+.ELSE
+ZLIBINCDIR=external$/zlib
+CFLAGS+=-I$(SOLARINCDIR)$/$(ZLIBINCDIR)
+.ENDIF
+
+SLOFILES= \ +SLOFILES= \
+ $(SLO)$/ne_207.obj \ + $(SLO)$/ne_207.obj \
+ $(SLO)$/ne_acl3744.obj \ + $(SLO)$/ne_acl3744.obj \
......
...@@ -67,6 +67,20 @@ ...@@ -67,6 +67,20 @@
LDFLAGS += $(ARCHFLAG) LDFLAGS += $(ARCHFLAG)
# INCLUDES += -I/usr/include -Y/usr/include/linux # INCLUDES += -I/usr/include -Y/usr/include/linux
@@ -158,8 +161,13 @@
#
CPU_TAG = _$(CPU_ARCH)
+ifeq ($(SYSTEM_ZLIB),YES)
+# Currently (3.12.4) only the tools modutil and signtool are linked with libz
+# If USE_SYSTEM_ZLIB is not set then the tools link statically libzlib.a which
+# is also build in nss.
USE_SYSTEM_ZLIB = 1
ZLIB_LIBS = -lz
+endif
# The -rpath '$$ORIGIN' linker option instructs this library to search for its
# dependencies in the same directory where it resides.
--- misc/nss-3.12.8/mozilla/security/coreconf/SunOS5.mk 2009-06-11 02:55:32.000000000 +0200 --- misc/nss-3.12.8/mozilla/security/coreconf/SunOS5.mk 2009-06-11 02:55:32.000000000 +0200
+++ misc/build/nss-3.12.8/mozilla/security/coreconf/SunOS5.mk 2010-06-11 16:35:54.985571182 +0200 +++ misc/build/nss-3.12.8/mozilla/security/coreconf/SunOS5.mk 2010-06-11 16:35:54.985571182 +0200
@@ -89,8 +89,12 @@ @@ -89,8 +89,12 @@
......
ns nss : solenv ZLIB:zlib NULL ns nss : solenv NULL
ns nss nmake - usr1 ns_mkout NULL ns nss nmake - usr1 ns_mkout NULL
ns nss nmake - all ns_nss NULL ns nss nmake - all ns_nss NULL
...@@ -88,4 +88,10 @@ $(eval $(call gb_Library_add_exception_objects,package2,\ ...@@ -88,4 +88,10 @@ $(eval $(call gb_Library_add_exception_objects,package2,\
package/source/zippackage/ZipPackageStream \ package/source/zippackage/ZipPackageStream \
)) ))
ifeq ($(SYSTEM_ZLIB),YES)
$(eval $(call gb_Library_add_defs,package2,\
-DSYSTEM_ZLIB \
))
endif
# vim: set noet sw=4 ts=4: # vim: set noet sw=4 ts=4:
...@@ -27,7 +27,11 @@ ...@@ -27,7 +27,11 @@
************************************************************************/ ************************************************************************/
#include <package/Deflater.hxx> #include <package/Deflater.hxx>
#ifdef SYSTEM_ZLIB
#include <zlib.h> #include <zlib.h>
#else
#include <external/zlib/zlib.h>
#endif
#include <com/sun/star/packages/zip/ZipConstants.hpp> #include <com/sun/star/packages/zip/ZipConstants.hpp>
#include <string.h> // for memset #include <string.h> // for memset
......
...@@ -27,7 +27,11 @@ ...@@ -27,7 +27,11 @@
************************************************************************/ ************************************************************************/
#include <package/Inflater.hxx> #include <package/Inflater.hxx>
#ifdef SYSTEM_ZLIB
#include <zlib.h> #include <zlib.h>
#else
#include <external/zlib/zlib.h>
#endif
#include <string.h> // for memset #include <string.h> // for memset
using namespace com::sun::star::uno; using namespace com::sun::star::uno;
......
...@@ -36,7 +36,11 @@ ...@@ -36,7 +36,11 @@
#include <rtl/digest.h> #include <rtl/digest.h>
#include <rtl/cipher.h> #include <rtl/cipher.h>
#include <rtl/memory.h> #include <rtl/memory.h>
#ifdef SYSTEM_ZLIB
#include "zlib.h" #include "zlib.h"
#else
#include <zlib/zlib.h>
#endif
#include <math.h> #include <math.h>
#include <map> #include <map>
......
...@@ -32,7 +32,11 @@ ...@@ -32,7 +32,11 @@
#define BASEGFX_STATICLIBRARY #define BASEGFX_STATICLIBRARY
#ifdef SYSTEM_ZLIB
#include "zlib.h" #include "zlib.h"
#else
#include <zlib/zlib.h>
#endif
#include "outputwrap.hxx" #include "outputwrap.hxx"
#include "contentsink.hxx" #include "contentsink.hxx"
......
...@@ -32,7 +32,12 @@ ...@@ -32,7 +32,12 @@
#include "pnghelper.hxx" #include "pnghelper.hxx"
#include <sal/macros.h> #include <sal/macros.h>
#ifdef SYSTEM_ZLIB
#include "zlib.h" #include "zlib.h"
#else
#define ZLIB_INTERNAL 1
#include <zlib/zlib.h>
#endif
using namespace pdfi; using namespace pdfi;
......
...@@ -33,7 +33,11 @@ ...@@ -33,7 +33,11 @@
#define _WINDOWS #define _WINDOWS
#endif #endif
#ifdef SYSTEM_ZLIB
#include <zlib.h> #include <zlib.h>
#else
#include <external/zlib/zlib.h>
#endif
#include <string> #include <string>
#include <vector> #include <vector>
......
...@@ -47,6 +47,10 @@ CFLAGS_X64+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820 ...@@ -47,6 +47,10 @@ CFLAGS_X64+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820
.ENDIF .ENDIF
CDEFS_X64+=-U_WIN32_IE -D_WIN32_IE=0x501 -U_WIN32_WINNT -D_WIN32_WINNT=0x0501 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 -------------------------------------------------------- # --- Files --------------------------------------------------------
......
...@@ -42,6 +42,10 @@ CFLAGS+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820 ...@@ -42,6 +42,10 @@ CFLAGS+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820
.ENDIF .ENDIF
CDEFS+=-U_WIN32_IE -D_WIN32_IE=0x501 -U_WIN32_WINNT -D_WIN32_WINNT=0x0501 CDEFS+=-U_WIN32_IE -D_WIN32_IE=0x501 -U_WIN32_WINNT -D_WIN32_WINNT=0x0501
.IF "$(SYSTEM_ZLIB)" == "YES"
CDEFS += -DSYSTEM_ZLIB
.END
# --- Files -------------------------------------------------------- # --- Files --------------------------------------------------------
SLOFILES=$(SLO)$/columninfo.obj SLOFILES=$(SLO)$/columninfo.obj
......
...@@ -42,6 +42,10 @@ CFLAGS+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820 ...@@ -42,6 +42,10 @@ CFLAGS+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820
.ENDIF .ENDIF
CDEFS+=-U_WIN32_IE -D_WIN32_IE=0x501 -U_WIN32_WINNT -D_WIN32_WINNT=0x0501 CDEFS+=-U_WIN32_IE -D_WIN32_IE=0x501 -U_WIN32_WINNT -D_WIN32_WINNT=0x0501
.IF "$(SYSTEM_ZLIB)" == "YES"
CDEFS += -DSYSTEM_ZLIB
.END
# --- Files -------------------------------------------------------- # --- Files --------------------------------------------------------
SLOFILES=$(SLO)$/$(TARGET).obj SLOFILES=$(SLO)$/$(TARGET).obj
......
...@@ -59,6 +59,10 @@ CDEFS+=-DDONT_HAVE_GDIPLUS ...@@ -59,6 +59,10 @@ CDEFS+=-DDONT_HAVE_GDIPLUS
CDEFS+=-U_WIN32_IE -D_WIN32_IE=0x501 -U_WIN32_WINNT -D_WIN32_WINNT=0x0501 CDEFS+=-U_WIN32_IE -D_WIN32_IE=0x501 -U_WIN32_WINNT -D_WIN32_WINNT=0x0501
.IF "$(SYSTEM_ZLIB)" == "YES"
CDEFS += -DSYSTEM_ZLIB
.END
# --- Files -------------------------------------------------------- # --- Files --------------------------------------------------------
SLOFILES=$(SLO)$/classfactory.obj\ SLOFILES=$(SLO)$/classfactory.obj\
...@@ -78,7 +82,7 @@ SHL1STDLIBS=$(ZLIB3RDLIB) $(MINIZIP3RDLIB) $(EXPAT3RDLIB) $(COMCTL32LIB) ...@@ -78,7 +82,7 @@ SHL1STDLIBS=$(ZLIB3RDLIB) $(MINIZIP3RDLIB) $(EXPAT3RDLIB) $(COMCTL32LIB)
SHL1LIBS= SHL1LIBS=
.ELSE .ELSE
SHL1STDLIBS= SHL1STDLIBS=
SHL1LIBS=$(SOLARLIBDIR)$/$(ZLIB3RDLIB)\ SHL1LIBS=$(SOLARLIBDIR)$/zlib.lib\
$(SOLARLIBDIR)$/expat_xmlparse.lib\ $(SOLARLIBDIR)$/expat_xmlparse.lib\
$(SOLARLIBDIR)$/expat_xmltok.lib $(SOLARLIBDIR)$/expat_xmltok.lib
.ENDIF .ENDIF
...@@ -128,7 +132,7 @@ SLOFILES_X64= \ ...@@ -128,7 +132,7 @@ SLOFILES_X64= \
$(SLO_X64)$/stream_helper.obj\ $(SLO_X64)$/stream_helper.obj\
SHL1TARGET_X64=$(TARGET) SHL1TARGET_X64=$(TARGET)
SHL1LIBS_X64=$(SOLARLIBDIR_X64)$/$(ZLIB3RDLIB)\ SHL1LIBS_X64=$(SOLARLIBDIR_X64)$/zlib.lib\
$(SOLARLIBDIR_X64)$/expat_xmlparse.lib\ $(SOLARLIBDIR_X64)$/expat_xmlparse.lib\
$(SOLARLIBDIR_X64)$/expat_xmltok.lib $(SOLARLIBDIR_X64)$/expat_xmltok.lib
......
...@@ -46,6 +46,10 @@ CFLAGS+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820 ...@@ -46,6 +46,10 @@ CFLAGS+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820
.ENDIF .ENDIF
CDEFS+=-U_WIN32_IE -D_WIN32_IE=0x501 -U_WIN32_WINNT -D_WIN32_WINNT=0x0501 CDEFS+=-U_WIN32_IE -D_WIN32_IE=0x501 -U_WIN32_WINNT -D_WIN32_WINNT=0x0501
.IF "$(SYSTEM_ZLIB)" == "YES"
CDEFS += -DSYSTEM_ZLIB
.END
# --- Files -------------------------------------------------------- # --- Files --------------------------------------------------------
SLOFILES=$(SLO)$/ooofilt.obj\ SLOFILES=$(SLO)$/ooofilt.obj\
...@@ -58,7 +62,7 @@ SHL1STDLIBS=$(ZLIB3RDLIB) $(MINIZIP3RDLIB) $(EXPAT3RDLIB) ...@@ -58,7 +62,7 @@ SHL1STDLIBS=$(ZLIB3RDLIB) $(MINIZIP3RDLIB) $(EXPAT3RDLIB)
SHL1LIBS= SHL1LIBS=
.ELSE .ELSE
SHL1STDLIBS= SHL1STDLIBS=
SHL1LIBS=$(SOLARLIBDIR)$/$(ZLIB3RDLIB)\ SHL1LIBS=$(SOLARLIBDIR)$/zlib.lib\
$(SOLARLIBDIR)$/expat_xmlparse.lib\ $(SOLARLIBDIR)$/expat_xmlparse.lib\
$(SOLARLIBDIR)$/expat_xmltok.lib $(SOLARLIBDIR)$/expat_xmltok.lib
.ENDIF .ENDIF
...@@ -104,7 +108,7 @@ SLOFILES_X64=$(SLO_X64)$/ooofilt.obj\ ...@@ -104,7 +108,7 @@ SLOFILES_X64=$(SLO_X64)$/ooofilt.obj\
SHL1TARGET_X64=$(TARGET) SHL1TARGET_X64=$(TARGET)
SHL1LIBS_X64=$(SOLARLIBDIR_X64)$/$(ZLIB3RDLIB)\ SHL1LIBS_X64=$(SOLARLIBDIR_X64)$/zlib.lib\
$(SOLARLIBDIR_X64)$/expat_xmlparse.lib\ $(SOLARLIBDIR_X64)$/expat_xmlparse.lib\
$(SOLARLIBDIR_X64)$/expat_xmltok.lib $(SOLARLIBDIR_X64)$/expat_xmltok.lib
......
...@@ -67,7 +67,7 @@ SHL1STDLIBS=$(ZLIB3RDLIB) $(MINIZIP3RDLIB) $(EXPAT3RDLIB) $(COMCTL32LIB) ...@@ -67,7 +67,7 @@ SHL1STDLIBS=$(ZLIB3RDLIB) $(MINIZIP3RDLIB) $(EXPAT3RDLIB) $(COMCTL32LIB)
SHL1LIBS= SHL1LIBS=
.ELSE .ELSE
SHL1STDLIBS= SHL1STDLIBS=
SHL1LIBS=$(SOLARLIBDIR)$/$(ZLIB3RDLIB)\ SHL1LIBS=$(SOLARLIBDIR)$/zlib.lib\
$(SOLARLIBDIR)$/expat_xmlparse.lib\ $(SOLARLIBDIR)$/expat_xmlparse.lib\
$(SOLARLIBDIR)$/expat_xmltok.lib $(SOLARLIBDIR)$/expat_xmltok.lib
.ENDIF .ENDIF
...@@ -115,7 +115,7 @@ SLOFILES_X64= \ ...@@ -115,7 +115,7 @@ SLOFILES_X64= \
$(SLO_X64)$/stream_helper.obj\ $(SLO_X64)$/stream_helper.obj\
SHL1TARGET_X64=$(TARGET) SHL1TARGET_X64=$(TARGET)
SHL1LIBS_X64=$(SOLARLIBDIR_X64)$/$(ZLIB3RDLIB)\ SHL1LIBS_X64=$(SOLARLIBDIR_X64)$/zlib.lib\
$(SOLARLIBDIR_X64)$/expat_xmlparse.lib\ $(SOLARLIBDIR_X64)$/expat_xmlparse.lib\
$(SOLARLIBDIR_X64)$/expat_xmltok.lib $(SOLARLIBDIR_X64)$/expat_xmltok.lib
......
...@@ -44,6 +44,10 @@ CFLAGS_X64+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820 ...@@ -44,6 +44,10 @@ CFLAGS_X64+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820
CDEFS_X64+=-U_WIN32_WINNT -D_WIN32_WINNT=0x0501 -U_WIN32_IE -D_WIN32_IE=0x501 CDEFS_X64+=-U_WIN32_WINNT -D_WIN32_WINNT=0x0501 -U_WIN32_IE -D_WIN32_IE=0x501
.ENDIF .ENDIF
.IF "$(SYSTEM_ZLIB)" == "YES"
CDEFS += -DSYSTEM_ZLIB
.END
# --- Files -------------------------------------------------------- # --- Files --------------------------------------------------------
SLOFILES=$(SLO)$/propsheets.obj\ SLOFILES=$(SLO)$/propsheets.obj\
......
...@@ -47,6 +47,10 @@ CFLAGS_X64+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820 ...@@ -47,6 +47,10 @@ CFLAGS_X64+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820
.ENDIF .ENDIF
CDEFS_X64+=-U_WIN32_IE -D_WIN32_IE=0x501 -U_WIN32_WINNT -D_WIN32_WINNT=0x0501 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 -------------------------------------------------------- # --- Files --------------------------------------------------------
SLOFILES=$(SLO)$/fileextensions.obj\ SLOFILES=$(SLO)$/fileextensions.obj\
......
...@@ -35,6 +35,10 @@ EXTERNAL_WARNINGS_NOT_ERRORS := TRUE ...@@ -35,6 +35,10 @@ EXTERNAL_WARNINGS_NOT_ERRORS := TRUE
.INCLUDE : settings.mk .INCLUDE : settings.mk
.IF "$(SYSTEM_ZLIB)" == "YES"
CDEFS += -DSYSTEM_ZLIB
.END
# --- Files -------------------------------------------------------- # --- Files --------------------------------------------------------
......
...@@ -193,7 +193,11 @@ EXPATASCII3RDLIB=-lexpat ...@@ -193,7 +193,11 @@ EXPATASCII3RDLIB=-lexpat
EXPAT3RDLIB=-lexpat_xmlparse -lexpat_xmltok EXPAT3RDLIB=-lexpat_xmlparse -lexpat_xmltok
EXPATASCII3RDLIB=-lascii_expat_xmlparse -lexpat_xmltok EXPATASCII3RDLIB=-lascii_expat_xmlparse -lexpat_xmltok
.ENDIF .ENDIF
.IF "$(SYSTEM_ZLIB)"=="YES"
ZLIB3RDLIB=-lz ZLIB3RDLIB=-lz
.ELSE
ZLIB3RDLIB=-lzlib
.ENDIF
.IF "$(SYSTEM_MINIZIP)"=="YES" .IF "$(SYSTEM_MINIZIP)"=="YES"
MINIZIP3RDLIB=$(MINIZIP_LIBS) MINIZIP3RDLIB=$(MINIZIP_LIBS)
.ELSE .ELSE
...@@ -463,7 +467,7 @@ LNGLIB=ilng.lib ...@@ -463,7 +467,7 @@ LNGLIB=ilng.lib
CLUCENELIB=iclucene.lib CLUCENELIB=iclucene.lib
EXPAT3RDLIB=expat_xmltok.lib expat_xmlparse.lib EXPAT3RDLIB=expat_xmltok.lib expat_xmlparse.lib
EXPATASCII3RDLIB=expat_xmltok.lib ascii_expat_xmlparse.lib EXPATASCII3RDLIB=expat_xmltok.lib ascii_expat_xmlparse.lib
ZLIB3RDLIB=z.lib ZLIB3RDLIB=zlib.lib
JPEG3RDLIB=jpeglib.lib JPEG3RDLIB=jpeglib.lib
NEON3RDLIB=ineon.lib NEON3RDLIB=ineon.lib
BERKELEYLIB=libdb47.lib BERKELEYLIB=libdb47.lib
......
...@@ -27,7 +27,13 @@ ...@@ -27,7 +27,13 @@
************************************************************************/ ************************************************************************/
#include <tools/stream.hxx> #include <tools/stream.hxx>
#ifndef _ZLIB_H
#ifdef SYSTEM_ZLIB
#include "zlib.h" #include "zlib.h"
#else
#include "zlib/zlib.h"
#endif
#endif
#include <tools/zcodec.hxx> #include <tools/zcodec.hxx>
#include <rtl/crc.h> #include <rtl/crc.h>
#include <osl/endian.h> #include <osl/endian.h>
......
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License or as specified alternatively below. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# Major Contributor(s):
# Copyright (C) 2012 Red Hat, Inc., Caolán McNamara <caolanm@redhat.com>
# (initial developer)
# Copyright (C) 2012 Red Hat, Inc., David Tardon <dtardon@redhat.com>
#
# All Rights Reserved.
#
# For minor contributions see the git repository.
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
# instead of those above.
$(eval $(call gb_CustomTarget_CustomTarget,zlib/source))
ZLSO := $(call gb_CustomTarget_get_workdir,zlib/source)
$(call gb_CustomTarget_get_target,zlib/source) : $(ZLSO)/done
# FIXME: do not hardcode the path here
ifeq ($(OS_FOR_BUILD),WNT)
zl_FIXED_TARFILE_LOCATION := $(shell cygpath -u $(TARFILE_LOCATION))/c735eab2d659a96e5a594c9e8541ad63-zlib-1.2.5.tar.gz
else
zl_FIXED_TARFILE_LOCATION := $(TARFILE_LOCATION)/c735eab2d659a96e5a594c9e8541ad63-zlib-1.2.5.tar.gz
endif
$(ZLSO)/done : $(zl_FIXED_TARFILE_LOCATION)
$(call gb_Output_announce,$(subst $(WORKDIR)/,,$@),$(true),TAR,1)
$(call gb_Helper_abbreviate_dirs, \
mkdir -p $(dir $@) && cd $(dir $@) && \
$(GNUTAR) -x -z $(STRIP_COMPONENTS)=1 -f $< && \
$(GNUPATCH) -p1 < $(SRCDIR)/zlib/patches/zlib-1.2.5-gentoo.patch && \
$(GNUPATCH) -p1 < $(SRCDIR)/zlib/patches/minizip-null.patch && \
$(GNUPATCH) -p1 < $(SRCDIR)/zlib/patches/zlib-1.2.5-minizip-fixuncrypt.patch && \
$(GNUPATCH) -p1 < $(SRCDIR)/zlib/patches/zlib-1.2.5-zip64.patch )
touch $@
# vim: set noet sw=4 ts=4:
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
#
EXTERNAL_WARNINGS_NOT_ERRORS := TRUE
export EXTERNAL_WARNINGS_NOT_ERRORS
module_directory:=$(dir $(realpath $(firstword $(MAKEFILE_LIST))))
include $(module_directory)/../solenv/gbuild/partial_build.mk
# vim: set noet sw=4 ts=4:
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License or as specified alternatively below. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# Major Contributor(s):
# Copyright (C) 2012 Red Hat, Inc., Caolán McNamara <caolanm@redhat.com>
# (initial developer)
#
# All Rights Reserved.
#
# For minor contributions see the git repository.
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
# instead of those above.
$(eval $(call gb_Module_Module,zlib))
$(eval $(call gb_Module_add_targets,zlib,\
CustomTarget_source \
StaticLibrary_zlib \
Package_source \
))
# vim: set noet sw=4 ts=4:
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License or as specified alternatively below. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# Major Contributor(s):
# Copyright (C) 2012 Red Hat, Inc., Caolán McNamara <caolanm@redhat.com>
# (initial developer)
# Copyright (C) 2012 Red Hat, Inc., David Tardon <dtardon@redhat.com>
#
# All Rights Reserved.
#
# For minor contributions see the git repository.
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
# instead of those above.
$(eval $(call gb_Package_Package,zlib_source,$(call gb_CustomTarget_get_workdir,zlib/source)))
$(call gb_Package_get_preparation_target,zlib_source) : $(call gb_CustomTarget_get_target,zlib/source)
$(eval $(call gb_Package_add_file,zlib_source,inc/external/zconf.h,zconf.h))
$(eval $(call gb_Package_add_file,zlib_source,inc/external/zlib.h,zlib.h))
$(eval $(call gb_Package_add_file,zlib_source,inc/external/minizip/unzip.h,contrib/minizip/unzip.h))
$(eval $(call gb_Package_add_file,zlib_source,inc/external/minizip/ioapi.h,contrib/minizip/ioapi.h))
# vim: set noet sw=4 ts=4:
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License or as specified alternatively below. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# Major Contributor(s):
# Copyright (C) 2012 Red Hat, Inc., Caolán McNamara <caolanm@redhat.com>
# (initial developer)
#
# All Rights Reserved.
#
# For minor contributions see the git repository.
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
# instead of those above.
$(eval $(call gb_StaticLibrary_StaticLibrary,z))
$(eval $(call gb_StaticLibrary_use_package,z,zlib_source))
$(eval $(call gb_StaticLibrary_set_warnings_not_errors,zlib))
$(eval $(call gb_StaticLibrary_set_include,z,\
$$(INCLUDE) \
))
$(eval $(call gb_StaticLibrary_add_defs,z,\
$(LFS_CFLAGS) \
))
# zlib does not depend on sal nor needs uwinapi here
$(eval $(call gb_StaticLibrary_use_libraries,z,\
$(filter-out uwinapi,$(gb_STDLIBS)) \
))
ifeq ($(OS),LINUX)
$(eval $(call gb_StaticLibrary_use_libraries,z,\
m \
pthread \
))
endif
$(eval $(call gb_StaticLibrary_add_generated_cobjects,z,\
CustomTarget/zlib/source/adler32 \
CustomTarget/zlib/source/compress \
CustomTarget/zlib/source/deflate \
CustomTarget/zlib/source/crc32 \
CustomTarget/zlib/source/inffast \
CustomTarget/zlib/source/inflate \
CustomTarget/zlib/source/inftrees \
CustomTarget/zlib/source/trees \
CustomTarget/zlib/source/zutil \
,$(if $(filter TRUE,$(EXTERNAL_WARNINGS_NOT_ERRORS)),\
$(filter-out $(gb_CFLAGS_WERROR),$(CFLAGS)),\
$(CFLAGS)) \
$(gb_COMPILEROPTFLAGS) \
))
# vim: set noet sw=4 ts=4:
:
eval 'exec perl -S $0 ${1+"$@"}'
if 0;
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# Copyright 2000, 2010 Oracle and/or its affiliates.
#
# OpenOffice.org - a multi-platform office productivity suite
#
# This file is part of OpenOffice.org.
#
# OpenOffice.org is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License version 3
# only, as published by the Free Software Foundation.
#
# OpenOffice.org is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Lesser General Public License version 3 for more details
# (a copy is included in the LICENSE file that accompanied this code).
#
# You should have received a copy of the GNU Lesser General Public License
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
#
#*************************************************************************
#
# make_patched_header - make patched header
#
use strict;
use File::Basename;
use File::Path;
use Carp;
my $patched_file = shift @ARGV;
$patched_file =~ s/\\/\//g;
my $module = shift @ARGV;
my $patch_dir = dirname($patched_file);
my $orig_file = $patched_file;
$orig_file =~ s/\/patched\//\//;
if (!-f $orig_file) { carp("Cannot find file $orig_file\n"); };
if (!-d $patch_dir) {
mkpath($patch_dir, 0, 0775);
if (!-d $patch_dir) {("mkdir: could not create directory $patch_dir\n"); };
};
open(PATCHED_FILE, ">$patched_file") or carp("Cannot open file $patched_file\n");
open(ORIG_FILE, "<$orig_file") or carp("Cannot open file $orig_file\n");
foreach (<ORIG_FILE>) {
if (/#include\s*"(\w+\.h\w*)"/) {
my $include = $1;
s/#include "$include"/#include <$module\/$include>/g;
};
print PATCHED_FILE $_;
};
close PATCHED_FILE;
close ORIG_FILE;
exit(0);
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# Copyright 2000, 2010 Oracle and/or its affiliates.
#
# OpenOffice.org - a multi-platform office productivity suite
#
# This file is part of OpenOffice.org.
#
# OpenOffice.org is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License version 3
# only, as published by the Free Software Foundation.
#
# OpenOffice.org is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Lesser General Public License version 3 for more details
# (a copy is included in the LICENSE file that accompanied this code).
#
# You should have received a copy of the GNU Lesser General Public License
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
#
#*************************************************************************
PRJ=.
PRJNAME=zlib
TARGET=zlib
.IF "$(GUI)" == "UNX"
.IF "$(SYSTEM_ZLIB)" == "YES"
all:
@echo "An already available installation of zlib should exist on your system."
@echo "Therefore the version provided here does not need to be built in addition."
.ENDIF
.ENDIF
# --- Settings -----------------------------------------------------
.INCLUDE : settings.mk
# --- Files --------------------------------------------------------
TARFILE_NAME=zlib-1.2.5
TARFILE_MD5=c735eab2d659a96e5a594c9e8541ad63
PATCH_FILES=zlib-1.2.5.patch
ADDITIONAL_FILES=makefile.mk
#relative to CONFIGURE_DIR
BUILD_DIR=$(CONFIGURE_DIR)
BUILD_ACTION=dmake $(MFLAGS) $(CALLMACROS)
OUT2INC= \
zlib.h \
zconf.h \
contrib$/minizip$/unzip.h \
contrib$/minizip$/ioapi.h
PATCHED_HEADERS=$(INCCOM)$/patched$/zlib.h
# --- Targets ------------------------------------------------------
.INCLUDE : set_ext.mk
.INCLUDE : target.mk
.INCLUDE : tg_ext.mk
ALLTAR: $(PATCHED_HEADERS)
$(PATCHED_HEADERS) : $(PACKAGE_DIR)$/$(PREDELIVER_FLAG_FILE)
@$(PERL) make_patched_header.pl $@ $(PRJNAME)
diff -up zlib-1.2.5/contrib/minizip/unzip.c.pom zlib-1.2.5/contrib/minizip/unzip.c
--- zlib-1.2.5/contrib/minizip/unzip.c.pom 2010-02-15 12:59:40.000000000 +0100
+++ zlib-1.2.5/contrib/minizip/unzip.c 2011-04-06 12:06:04.000000000 +0200
@@ -1145,7 +1145,7 @@ extern int ZEXPORT unzGetCurrentFileInfo
szFileName,fileNameBufferSize,
extraField,extraFieldBufferSize,
szComment,commentBufferSize);
- if (err==UNZ_OK)
+ if (pfile_info && err==UNZ_OK)
{
pfile_info->version = file_info64.version;
pfile_info->version_needed = file_info64.version_needed;
diff -up zlib-1.2.5/zlib.h.pom zlib-1.2.5/zlib.h
--- zlib-1.2.5/zlib.h.pom 2010-04-20 06:12:48.000000000 +0200
+++ zlib-1.2.5/zlib.h 2010-06-16 13:08:59.000000000 +0200
@@ -1578,7 +1578,7 @@ ZEXTERN int ZEXPORT inflateBackInit_ OF(
# define gzoffset gzoffset64
# define adler32_combine adler32_combine64
# define crc32_combine crc32_combine64
-# ifdef _LARGEFILE64_SOURCE
+# ifndef _LARGEFILE64_SOURCE
ZEXTERN gzFile ZEXPORT gzopen64 OF((const char *, const char *));
ZEXTERN z_off_t ZEXPORT gzseek64 OF((gzFile, z_off_t, int));
ZEXTERN z_off_t ZEXPORT gztell64 OF((gzFile));
diff -up zlib-1.2.5/contrib/minizip/unzip.c.fixuncrypt zlib-1.2.5/contrib/minizip/unzip.c
--- zlib-1.2.5/contrib/minizip/unzip.c.fixuncrypt 2011-11-11 12:13:56.335867758 -0500
+++ zlib-1.2.5/contrib/minizip/unzip.c 2011-11-11 12:14:01.747799372 -0500
@@ -68,10 +68,6 @@
#include <stdlib.h>
#include <string.h>
-#ifndef NOUNCRYPT
- #define NOUNCRYPT
-#endif
-
#include "zlib.h"
#include "unzip.h"
diff -ru zlib-1.2.5/contrib/minizip/ioapi.c zlib-1.2.5-patch/contrib/minizip/ioapi.c
--- zlib-1.2.5/contrib/minizip/ioapi.c 2010-01-04 12:31:24.000000000 -0500
+++ zlib-1.2.5-patch/contrib/minizip/ioapi.c 2011-07-05 15:47:48.263474587 -0400
@@ -47,7 +47,7 @@
else
{
uLong tell_uLong = (*(pfilefunc->ztell32_file))(pfilefunc->zfile_func64.opaque,filestream);
- if ((tell_uLong) == ((uLong)-1))
+ if ((tell_uLong) == MAXU32)
return (ZPOS64_T)-1;
else
return tell_uLong;
diff -ru zlib-1.2.5/contrib/minizip/ioapi.h zlib-1.2.5-patch/contrib/minizip/ioapi.h
--- zlib-1.2.5/contrib/minizip/ioapi.h 2010-02-15 06:59:40.000000000 -0500
+++ zlib-1.2.5-patch/contrib/minizip/ioapi.h 2011-07-05 15:48:36.281546917 -0400
@@ -85,6 +85,8 @@
typedef uint64_t ZPOS64_T;
#else
+/* Maximum unsigned 32-bit value used as placeholder for zip64 */
+#define MAXU32 0xffffffff
#if defined(_MSC_VER) || defined(__BORLANDC__)
typedef unsigned __int64 ZPOS64_T;
diff -ru zlib-1.2.5/contrib/minizip/unzip.c zlib-1.2.5-patch/contrib/minizip/unzip.c
--- zlib-1.2.5/contrib/minizip/unzip.c 2010-02-15 06:59:40.000000000 -0500
+++ zlib-1.2.5-patch/contrib/minizip/unzip.c 2011-07-05 15:50:31.409310349 -0400
@@ -1040,26 +1040,26 @@
{
uLong uL;
- if(file_info.uncompressed_size == (ZPOS64_T)(unsigned long)-1)
+ if(file_info.uncompressed_size == MAXU32)
{
if (unz64local_getLong64(&s->z_filefunc, s->filestream,&file_info.uncompressed_size) != UNZ_OK)
err=UNZ_ERRNO;
}
- if(file_info.compressed_size == (ZPOS64_T)(unsigned long)-1)
+ if(file_info.compressed_size == MAXU32)
{
if (unz64local_getLong64(&s->z_filefunc, s->filestream,&file_info.compressed_size) != UNZ_OK)
err=UNZ_ERRNO;
}
- if(file_info_internal.offset_curfile == (ZPOS64_T)(unsigned long)-1)
+ if(file_info_internal.offset_curfile == MAXU32)
{
/* Relative Header offset */
if (unz64local_getLong64(&s->z_filefunc, s->filestream,&file_info_internal.offset_curfile) != UNZ_OK)
err=UNZ_ERRNO;
}
- if(file_info.disk_num_start == (unsigned long)-1)
+ if(file_info.disk_num_start == MAXU32)
{
/* Disk Start Number */
if (unz64local_getLong(&s->z_filefunc, s->filestream,&uL) != UNZ_OK)
cl zlib : soltools NULL zl zlib : soltools NULL
cl zlib usr1 - all zl_mkout NULL zl zlib nmake - all zl_mkout NULL
cl zlib\prj nmake - all zl_prj NULL
mkdir: %_DEST%\inc\external\zlib
mkdir: %_DEST%\lib\x64
..\%__SRC%\inc\patched\zlib.h %_DEST%\inc\external\zlib\zlib.h
..\%__SRC%\inc\zconf.h %_DEST%\inc\external\zlib\zconf.h
..\%__SRC%\lib\libzlib.a %_DEST%\lib\libzlib.a
..\%__SRC%\slb\zlib.lib %_DEST%\lib\zlib.lib
..\%__SRC%\slb\zlib.lin %_DEST%\lib\zlib.lin
..\%__SRC%\slb\x64\zlib.lib %_DEST%\lib\x64\zlib.lib
..\%__SRC%\slb\x64\zlib.lin %_DEST%\lib\x64\zlib.lin
--- misc/zlib-1.2.5/makefile.mk Fri Mar 14 10:17:06 2008
+++ misc/build/zlib-1.2.5/makefile.mk Fri Mar 14 10:16:56 2008
@@ -1 +1,63 @@
-dummy
+#*************************************************************************
+#
+# Copyright according the GNU Public License.
+#
+#*************************************************************************
+
+PRJ=..$/..$/..$/..
+
+PRJNAME=zlib
+TARGET=zlib
+LIBTARGET=NO
+EXTERNAL_WARNINGS_NOT_ERRORS=TRUE
+
+# --- Settings -----------------------------------------------------
+
+.INCLUDE : settings.mk
+
+# --- Files --------------------------------------------------------
+
+INCEXT=contrib$/minizip
+
+SLOFILES= $(SLO)$/adler32.obj \
+ $(SLO)$/compress.obj \
+ $(SLO)$/deflate.obj \
+ $(SLO)$/crc32.obj \
+ $(SLO)$/inffast.obj \
+ $(SLO)$/inflate.obj \
+ $(SLO)$/inftrees.obj \
+ $(SLO)$/trees.obj \
+ $(SLO)$/zutil.obj
+
+
+LIB1TARGET=$(SLB)$/$(TARGET).lib
+LIB1ARCHIV=$(LB)$/lib$(TARGET).a
+LIB1OBJFILES=$(SLOFILES)
+
+.IF "$(BUILD_X64)"!=""
+SLOFILES_X64= $(SLO_X64)$/adler32.obj \
+ $(SLO_X64)$/compress.obj \
+ $(SLO_X64)$/deflate.obj \
+ $(SLO_X64)$/crc32.obj \
+ $(SLO_X64)$/inffast.obj \
+ $(SLO_X64)$/inflate.obj \
+ $(SLO_X64)$/inftrees.obj \
+ $(SLO_X64)$/trees.obj \
+ $(SLO_X64)$/zutil.obj
+
+LIB1TARGET_X64=$(SLB_X64)$/$(TARGET).lib
+LIB1OBJFILES_X64=$(SLOFILES_X64)
+.ENDIF # "$(BUILD_X64)"!=""
+
+
+# --- Targets ------------------------------------------------------
+
+$(MISC)$/%.c : contrib$/minizip$/%.c
+ @echo ------------------------------
+ @echo Making: $@
+ @$(COPY) $< $@
+
+.INCLUDE : set_wntx64.mk
+.INCLUDE : target.mk
+.INCLUDE : tg_wntx64.mk
+
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment