$NetBSD: patch-ab,v 1.12 2012/06/28 05:21:19 sbd Exp $

* Use system/buildlinked headers.
* The correct type for get_crc_table with zlib 1.2.7 is z_crc_t*

--- UnAlz.cpp.orig	2007-02-10 05:51:54.000000000 +0000
+++ UnAlz.cpp
@@ -1,5 +1,5 @@
-#include "zlib/zlib.h"
-#include "bzip2/bzlib.h"
+#include <zlib.h>
+#include <bzlib.h>
 #include "UnAlz.h"
 
 // utime Լ ó
@@ -1891,7 +1891,11 @@ void CUnAlz::DecryptingData(int nSize, B
 ////////////////////////////////////////////////////////////////////////////////////////////////////
 UINT32 CUnAlz::CRC32(UINT32 l, BYTE c)
 {
+#if ZLIB_VERNUM >= 0x1270
+	const z_crc_t *CRC_TABLE = get_crc_table();
+#else
 	const unsigned long *CRC_TABLE = get_crc_table();
+#endif
 	return CRC_TABLE[(l ^ c) & 0xff] ^ (l >> 8);
 }
 
