made bzip2 smaller than zlib mode !!!
git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@1241 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
parent
d14d52c461
commit
77cb319b8c
9 changed files with 38 additions and 569 deletions
|
@ -7,18 +7,16 @@
|
|||
#ifdef NSIS_CONFIG_COMPRESSION_SUPPORT
|
||||
#ifdef NSIS_COMPRESS_USE_ZLIB
|
||||
#include "../zlib/zlib.h"
|
||||
#define genrtable()
|
||||
#endif
|
||||
|
||||
#ifdef NSIS_COMPRESS_USE_BZIP2
|
||||
#include "../bzip2/bzlib.h"
|
||||
static char bz2_needreinit;
|
||||
void NSISCALL genrtable();
|
||||
|
||||
#define z_stream bz_stream
|
||||
#define inflateInit(x) { if (BZ2_bzDecompressInit(x)<0) return _LANG_INVALIDCRC; }
|
||||
#define inflate(x) BZ2_bzDecompress(x)
|
||||
#define inflateReset(x) { if (bz2_needreinit) { BZ2_bzDecompressEnd(x); inflateInit(x); } else bz2_needreinit++; }
|
||||
#define inflateReset(x) { if (bz2_needreinit) { inflateInit(x); } else bz2_needreinit++; }
|
||||
#define Z_OK BZ_OK
|
||||
#define Z_STREAM_END BZ_STREAM_END
|
||||
#endif//NSIS_COMPRESS_USE_BZIP2
|
||||
|
@ -62,7 +60,6 @@ const char * NSISCALL loadHeaders(void)
|
|||
data=(void*)my_GlobalAlloc(h.length_of_header);
|
||||
|
||||
#ifdef NSIS_CONFIG_COMPRESSION_SUPPORT
|
||||
genrtable();
|
||||
inflateInit(&g_inflate_stream);
|
||||
|
||||
#ifdef NSIS_COMPRESS_WHOLE
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue