libzip: libzip-discuss: Re: libzip compile under Windows

Thread

Thread Index

Message

From: Thomas Klausner <tk%giga.or.at@localhost>
To: yonah%gmx.net@localhost
Subject: Re: libzip compile under Windows
Date: Mon, 11 May 2009 15:58:40 +0200

Hi Yonah,

> please give me any Hints.
> 
> i changed  CMakeLists.txt to
> 
> FIND_PATH(ZLIB_INCLUDE_DIR zlib.h ../zlib)
> IF(ZLIB_INCLUDE_DIR)
>   FIND_LIBRARY(ZLIB_LIBRARY libzip.lib: ${ZLIB_INCLUDE_DIR})
> ENDIF(ZLIB_INCLUDE_DIR)

That's good. The test was somehow broken with the zlib.h that's
distributed on Windows. I'm not sure why, but that test is not so
important.

I've also tried it, but wasn't successful, though I don't understand
why.

I'm using the free Visual C++  9.0. I've installed the zlib header
files in C:/Programme/Microsoft Visual Studio 9.0/VC/include and the
library in C:/WINDOWS/system/zlib1.dll, because VC didn't find zlib.h.
The cmake file has
INCLUDE_DIRECTORIES(${ZLIB_INCLUDE_DIR})
so I don't understand why this step was necessary.
I then set ZLIB_INCLUDE_DIR to C:/Programme/Microsoft Visual Studio
9.0/VC/include and ZLIB_LIBRARY to C:/WINDOWS/system/zlib1.dll to make
cmake find them.

> i installed sh.exe but it still does not work.

This shouldn't be necessary any longer, I just added zip_err_str.c to
the hg repository.

I'm now stumped because the compiler complains about

C:\Dokumente und Einstellungen\...\lib\zipconf.h(11) : fatal error
C1083: Datei (Include) kann nicht geöffnet werden: "inttypes.h": No
such file or directory

where zipconf.h so contains:
 /* #undef HAVE_INTTYPES_H_LIBZIP */
#define HAVE_SYS_TYPES_H_LIBZIP
...
#if defined(HAVE_INTTYPES_H_LIBZIP)
#include <inttypes.h>
#elif defined(HAVE_SYS_TYPES_H_LIBZIP)
#include <sys/types.h>
#endif

Cheers,
 Thomas

> Homepage: http://home.pages.at/yonah

404?

Made by MHonArc.