aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorEugene Sandulenko2007-12-28 07:52:56 +0000
committerEugene Sandulenko2007-12-28 07:52:56 +0000
commitac54f3a26f5ebe1b1f7af03ebe1b6872ebe64703 (patch)
treef47426fee7827977824b526fd911225228840e42 /engines
parentae06d5337e80503d25c58cd9475bd8a45a87f48d (diff)
downloadscummvm-rg350-ac54f3a26f5ebe1b1f7af03ebe1b6872ebe64703.tar.gz
scummvm-rg350-ac54f3a26f5ebe1b1f7af03ebe1b6872ebe64703.tar.bz2
scummvm-rg350-ac54f3a26f5ebe1b1f7af03ebe1b6872ebe64703.zip
Patch #1858158: BUILD: Plugin building cleanup
svn-id: r30041
Diffstat (limited to 'engines')
-rw-r--r--engines/agos/res.cpp9
-rw-r--r--engines/scumm/module.mk2
-rw-r--r--engines/scumm/smush/smush_player.cpp8
3 files changed, 6 insertions, 13 deletions
diff --git a/engines/agos/res.cpp b/engines/agos/res.cpp
index ceb041b397..d74563226f 100644
--- a/engines/agos/res.cpp
+++ b/engines/agos/res.cpp
@@ -32,10 +32,7 @@
#include "agos/intern.h"
#include "agos/sound.h"
-
-#ifdef USE_ZLIB
-#include <zlib.h>
-#endif
+#include "common/zlib.h"
using Common::File;
@@ -77,8 +74,8 @@ void AGOSEngine::decompressData(const char *srcName, byte *dst, uint32 offset, u
error("decompressData: Read failed");
unsigned long decompressedSize = dstSize;
- int result = uncompress(dst, &decompressedSize, srcBuffer, srcSize);
- if (result != Z_OK)
+ int result = Common::uncompress(dst, &decompressedSize, srcBuffer, srcSize);
+ if (result != Common::ZLIB_OK)
error("decompressData: Zlib uncompress error");
free(srcBuffer);
} else {
diff --git a/engines/scumm/module.mk b/engines/scumm/module.mk
index ee3573975b..8dfb867943 100644
--- a/engines/scumm/module.mk
+++ b/engines/scumm/module.mk
@@ -117,8 +117,6 @@ endif
# This module can be built as a plugin
ifdef BUILD_PLUGINS
PLUGIN := 1
-# HACK HACK evil HACK HACK
-PLUGIN_LDFLAGS += -lz
endif
# Include common rules
diff --git a/engines/scumm/smush/smush_player.cpp b/engines/scumm/smush/smush_player.cpp
index 7c66c8124d..906395c0ca 100644
--- a/engines/scumm/smush/smush_player.cpp
+++ b/engines/scumm/smush/smush_player.cpp
@@ -59,9 +59,7 @@
#include <png.h>
#endif
-#ifdef USE_ZLIB
-#include <zlib.h>
-#endif
+#include "common/zlib.h"
namespace Scumm {
@@ -820,8 +818,8 @@ void SmushPlayer::handleZlibFrameObject(Chunk &b) {
unsigned long decompressedSize = READ_BE_UINT32(chunkBuffer);
byte *fobjBuffer = (byte *)malloc(decompressedSize);
- int result = uncompress(fobjBuffer, &decompressedSize, chunkBuffer + 4, chunkSize - 4);
- if (result != Z_OK)
+ int result = Common::uncompress(fobjBuffer, &decompressedSize, chunkBuffer + 4, chunkSize - 4);
+ if (result != Common::ZLIB_OK)
error("SmushPlayer::handleZlibFrameObject() Zlib uncompress error");
free(chunkBuffer);