From 30f218eb43414407ff8fad136ac1b14d419c29b5 Mon Sep 17 00:00:00 2001 From: pixel Date: Fri, 20 Jun 2003 14:08:16 +0000 Subject: Compiling again --- lib/Makefile | 4 ++-- lib/dteutils.cpp | 2 +- lib/lzss.cpp | 30 +++++++++++++++--------------- 3 files changed, 18 insertions(+), 18 deletions(-) (limited to 'lib') diff --git a/lib/Makefile b/lib/Makefile index 24c068e..8dda356 100755 --- a/lib/Makefile +++ b/lib/Makefile @@ -1,9 +1,9 @@ #!/usr/bin/make -f -CPPFLAGS=-Wall -g -O3 -mcpu=i686 -Werror -I../includes -DHAVE_ZLIB -DUSE_CDREADER -DDEBUG +CPPFLAGS=-Wall -g -O3 -mcpu=i686 -Werror -I../includes -DHAVE_ZLIB -DUSE_CDREADER -DDEBUG `baltisot-config --cflags` CXX=g++ -OBJECTS = cdutils.o lzss.o yazedc.o dteutils.o cdreader.o cdabstract.o +OBJECTS = cdutils.o lzss.o yazedc.o cdreader.o cdabstract.o TARGET = lib.a all: ${TARGET} diff --git a/lib/dteutils.cpp b/lib/dteutils.cpp index 0f52667..85a7df2 100644 --- a/lib/dteutils.cpp +++ b/lib/dteutils.cpp @@ -24,7 +24,7 @@ #include "generic.h" #include "Handle.h" -class thingtree { +class thingtree : public Base { public: static void addstring(const String, long); static long look(const String); diff --git a/lib/lzss.cpp b/lib/lzss.cpp index f31b2f2..530c6d9 100644 --- a/lib/lzss.cpp +++ b/lib/lzss.cpp @@ -81,13 +81,13 @@ void lzss::compute_limits(void) { lzss_maxptr += scheme.one_jump; if (scheme.l_mask_1 & scheme.j_mask_1) { - printm(M_ERROR, "Masks are overlapping for value 1\n"); - exit(-1); + printm(M_ERROR, "Masks are overlapping for value 1\n"); + exit(-1); } if (scheme.l_mask_2 & scheme.j_mask_2) { - printm(M_ERROR, "Masks are overlapping for value 2\n"); - exit(-1); + printm(M_ERROR, "Masks are overlapping for value 2\n"); + exit(-1); } if (shift(scheme.l_mask_1, scheme.l_shft_1) & shift(scheme.l_mask_2, scheme.l_shft_2)) { @@ -103,7 +103,7 @@ void lzss::compute_limits(void) { printm(M_INFO, "Computed values: maxsize = %i, maxptr = 0x%06x\n", lzss_maxsize, lzss_maxptr); } -unsigned long lzss::lzss_decomp(Handle * f_source, Handle * f_cible, long true_length) +unsigned int lzss::lzss_decomp(Handle * f_source, Handle * f_cible, int true_length) { unsigned char bitmap, fbitmap; unsigned char valeur; @@ -119,13 +119,13 @@ unsigned long lzss::lzss_decomp(Handle * f_source, Handle * f_cible, long true_l int loop_length; int whole_count; int i, j; - long length, reads; + int length, reads; compute_limits(); f_source->read(&length, 4); if (true_length >= 0) { - length = true_length; + length = true_length; } whole_count = 0; @@ -251,13 +251,13 @@ unsigned long lzss::lzss_decomp(Handle * f_source, Handle * f_cible, long true_l return length; } -unsigned char lzss::lzss_rd(unsigned char * t, long p) { +unsigned char lzss::lzss_rd(unsigned char * t, int p) { return ((p < 0) ? 0 : (t[p])); } -long lzss::lzss_comp_strstr(unsigned char * needle, unsigned char * r, long * l, long sp) { +int lzss::lzss_comp_strstr(unsigned char * needle, unsigned char * r, int * l, int sp) { char redo[256]; - long length, i, p, ptr, maxlength; + int length, i, p, ptr, maxlength; i = 1; redo[0] = p = 0; @@ -300,10 +300,10 @@ long lzss::lzss_comp_strstr(unsigned char * needle, unsigned char * r, long * l, return ptr; } -unsigned char * lzss::lzss_memcomp(unsigned char * r, long * l, long * delta) { +unsigned char * lzss::lzss_memcomp(unsigned char * r, int * l, int * delta) { unsigned char bitmap, * comp; - long ptr, needle, needle_length, comp_ptr, bitmap_ptr, val1, val2; - long jump, farest, remaining; + int ptr, needle, needle_length, comp_ptr, bitmap_ptr, val1, val2; + int jump, farest, remaining; int j; comp = (unsigned char *) malloc(3 * *l); @@ -425,8 +425,8 @@ unsigned char * lzss::lzss_memcomp(unsigned char * r, long * l, long * delta) { return comp; } -void lzss::lzss_comp(Handle * f_source, Handle * f_cible, long * delta) { - long length = f_source->GetSize(), l; +void lzss::lzss_comp(Handle * f_source, Handle * f_cible, int * delta) { + int length = f_source->GetSize(), l; unsigned char * r = (unsigned char *) malloc(length), * c; f_source->read(r, length); -- cgit v1.2.3