Re: [xml] Compression problem using Zlib



Does anybody has libxml library which is compiled with zlib file for win32?

Thanks in advace,
Arda



----- Original Message -----
From: "Igor Zlatkovic" <igor zlatkovic com>
To: "Arda Tekin" <arda tekin softhome net>
Cc: <xml gnome org>
Sent: Thursday, March 27, 2003 2:48 PM
Subject: Re: [xml] Compression problem using Zlib


Hi,

Do you use the precompiled libxml binaries?

The precompiled binaries do not support zlib. Doing this would give
another dependency on Windows and many would roast my liver for that.

You will have to grab the source, change the relevant parameters and
recompile with zlib support.

Ciao,
Igor

On Thu, Mar 27, 2003 at 02:28:32PM +0200, Arda Tekin wrote:
I develop a project which builds a xml file. Building and saving process
for a valid xmlDocPtr object is successful. And saved xml file is well
formatted. But I need to compress this file before saving it. I used zlib
win32 dll version.
(ZLib 1.1.4 for Win98/NT)
Files are:
zlib114dll/dll32/zlib.dll
zlib114dll/dll32/zlib.lib

#define _WINDOWS
#define ZLIB_DLL
#include "zlib.h"

..Xml Create process...
int nComp = xmlGetDocCompressMode(doc);
xmlSetDocCompressMode(doc, 9);
xmlSaveFile("c:\\VEReq.xml", doc);

Compiles and links without any error.
XML document are saved to disk without compressed. I mean, program works
same as uncompressed mode. Saved file is well formatted xml document.

How will I use compression option in libxml?
Thanks in advance.





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]