Hi i trying to compile wargus 2.2.6 on Gentoo and get this error:
[ himera ] brezerk@pts/1:209 ~/build/wargus_2.2.6.orig/build $
make
[ 28%] Built target pudconvert
[ 42%] Built target wargus
[ 57%] Building C object CMakeFiles/wartool.dir/wartool.c.o
/home/brezerk/build/wargus_2.2.6.orig/wartool.c: In function ‘SavePNG’:
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:1852:6: error: dereferencing pointer to incomplete type
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:1861:37: error: ‘Z_BEST_COMPRESSION’ undeclared (first use in this function)
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:1861:37: note: each undeclared identifier is reported only once for each function it appears in
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:1864:10: error: dereferencing pointer to incomplete type
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:1865:10: error: dereferencing pointer to incomplete type
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:1866:10: error: dereferencing pointer to incomplete type
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:1867:10: error: dereferencing pointer to incomplete type
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:1868:10: error: dereferencing pointer to incomplete type
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:1869:10: error: dereferencing pointer to incomplete type
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:1870:10: error: dereferencing pointer to incomplete type
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:1871:10: error: dereferencing pointer to incomplete type
/home/brezerk/build/wargus_2.2.6.orig/wartool.c: In function ‘ConvertWav’:
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:3231:2: error: ‘gzFile’ undeclared (first use in this function)
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:3231:9: error: expected ‘;’ before ‘gf’
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:3238:2: error: ‘gf’ undeclared (first use in this function)
/home/brezerk/build/wargus_2.2.6.orig/wartool.c: In function ‘ConvertXmi’:
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:3270:2: error: ‘gzFile’ undeclared (first use in this function)
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:3270:9: error: expected ‘;’ before ‘gf’
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:3367:2: error: ‘gf’ undeclared (first use in this function)
/home/brezerk/build/wargus_2.2.6.orig/wartool.c: In function ‘ConvertText’:
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:3601:2: error: ‘gzFile’ undeclared (first use in this function)
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:3601:9: error: expected ‘;’ before ‘gf’
/home/brezerk/build/wargus_2.2.6.orig/wartool.c:3620:2: error: ‘gf’ undeclared (first use in this function)
make[2]: *** [CMakeFiles/wartool.dir/wartool.c.o] Error 1
make[1]: *** [CMakeFiles/wartool.dir/all] Error 2
make: *** [all] Error 2
I am using:
sys-devel/gcc 4.5.3-r2
dev-util/cmake 2.8.7-r5
sys-libs/zlib 1.2.6
media-libs/libsdl 1.2.15-r1
media-libs/sdl-gfx 2.0.23
media-libs/sdl-image 1.2.12
media-libs/sdl-mixer 1.2.12-r1
media-libs/sdl-net 1.2.8
[media-libs/sdl-sound 1.0.3
[media-libs/sdl-ttf 2.0.11
Ok. It looks like libpng-1.5.x. 'libpng15/png.h' no longer includes 'zlib.h'. So you must do it yourself.
[ himera ] brezerk@pts/1:225 ~/build/ wargus_ 2.2.6.orig/ build $ build/wargus_ 2.2.6.orig/ wartool. c.orig /home/brezerk/ build/wargus_ 2.2.6.orig/ wartool. c build/wargus_ 2.2.6.orig/ wartool. c.orig 2012-05-18 18:06:25.000000000 +0300 build/wargus_ 2.2.6.orig/ wartool. c 2012-05-18 18:06:39.000000000 +0300
diff -u /home/brezerk/
--- /home/brezerk/
+++ /home/brezerk/
@@ -53,6 +53,7 @@
#include <stdint.h>
#include <ctype.h>
#include <png.h>
+#include <zlib.h>
#if defined(_MSC_VER) || defined(WIN32)
#include <windows.h>
This helps, but i still can't compile:
[ himera ] brezerk@pts/1:223 ~/build/ wargus_ 2.2.6.orig/ build $ wartool. dir/wartool. c.o build/wargus_ 2.2.6.orig/ wartool. c: In function ‘SavePNG’: build/wargus_ 2.2.6.orig/ wartool. c:1853: 6: error: dereferencing pointer to incomplete type build/wargus_ 2.2.6.orig/ wartool. c:1865: 10: error: dereferencing pointer to incomplete type build/wargus_ 2.2.6.orig/ wartool. c:1866: 10: error: dereferencing pointer to incomplete type build/wargus_ 2.2.6.orig/ wartool. c:1867: 10: error: dereferencing pointer to incomplete type build/wargus_ 2.2.6.orig/ wartool. c:1868: 10: error: dereferencing pointer to incomplete type build/wargus_ 2.2.6.orig/ wartool. c:1869: 10: error: dereferencing pointer to incomplete type build/wargus_ 2.2.6.orig/ wartool. c:1870: 10: error: dereferencing pointer to incomplete type build/wargus_ 2.2.6.orig/ wartool. c:1871: 10: error: dereferencing pointer to incomplete type build/wargus_ 2.2.6.orig/ wartool. c:1872: 10: error: dereferencing pointer to incomplete type wartool. dir/wartool. c.o] Error 1 wartool. dir/all] Error 2
make
[ 28%] Built target pudconvert
[ 42%] Built target wargus
[ 57%] Building C object CMakeFiles/
/home/brezerk/
/home/brezerk/
/home/brezerk/
/home/brezerk/
/home/brezerk/
/home/brezerk/
/home/brezerk/
/home/brezerk/
/home/brezerk/
/home/brezerk/
make[2]: *** [CMakeFiles/
make[1]: *** [CMakeFiles/
make: *** [all] Error 2