Comments (15)
Have you set LIBZ_INCLUDE_DIR to point to the path where zlib.h is located?
from zipper.
Thanks for your reply Sebastian!
I've finally found a way by changing the paths to the zlib dir and dll in the "CMakeCache.txt" generated after the error... But I don't know if it's the good way.
The files are now generated without errors.
But the last step "make" does not work :-( It says there is not target/make file... Any advice?
from zipper.
(it's make from cygwin64)
from zipper.
After further investigations:
-Using CMake GUI definitely helped solving the zlib path issues
-Compiling with MinGW leads to an error with<filesystem>
in defs.h :
fatal error: filesystem: No such file or directory
#include <filesystem>
-Compiling with MVS 2017 leads unfortunately to other errors:
c:\zlib\zconf.h(477): fatal error C1083: cannot open include file : 'unistd.h' : No such file or directory
from zipper.
-Compiling with MinGW leads to an error with
<filesystem>
in defs.h :
I have the same issue compiling on windows with MinGW32.
from zipper.
I don't have a windows box so I cant really test it right now. @fbergmann any ideas here?
from zipper.
I have not tested with MingW32, which currently does not yet seem to support the filesystem api. Compilation will succeed with visual studio (which can be downloaded free of charge).
from zipper.
@fbergmann Yeah, I already figured that out. Compiling with Visual Studio works :) BTW is the <filesystem>
header for c++17 experimental filesystem api or is it something windows specific?
from zipper.
the filesystem api is not windows specific, but there is hardly any support in the std c++ libraries for it otherwise. That is why on other system i was using a class we wrote for out other project (COPASI). So all that will need to be done is to somehow detect mingw and then disable that include and default to the other one.
from zipper.
Hi, I'm also a noob with MinGW (I don't have Window) so I'm trying to compile zipper (in blind) with appveyor, and I have the following error:
-- Looking for gzopen in LIBZ_LIBRARY-NOTFOUND
CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
LIBZ_LIBRARY
Note: I installed zlib and libzip with pacman but I do not know how to set ZLIBROOT as requested in the README:
Note: For windows users, zlib is expected to be found at ZLIBROOT.
Any help is welcomed :)
from zipper.
In this case you specifically pass along the -DLIBZ_LIBRARY= < path to libz library to link against > cheers frank
from zipper.
Hi @fbergmann ! Thx for your fast answer but I think it will be more difficult than just added -DLIBZ_LIBRARY.
In my case zlib.h seems to be located in /mingw64/include/zlib.h
and /mingw32/include/zlib.h
and therefore matching the CMakeLists.txt code line 124 $ENV{ZLIBROOT}/include
.
So, at beginning, I tried to do that:
cd zipper
mkdir build
cd build
export ZLIBROOT="/mingw64"
cmake ..
Unfortunately failed because I do not have zdll.lib or zlib.lib files like expected by CMakeLists.txt line 113 $ENV{ZLIBROOT}/lib
In fact I have files libz.a and libz.dll.a located in /mingw64/lib
So I followed your answer:
cd zipper
mkdir build
cd build
export ZLIBROOT="/mingw64"
cmake -DLIBZ_LIBRARY="/mingw64/lib" ..
But failed:
-- Looking for gzopen in C:/msys64/mingw64/lib
WARNING: Target "cmTC_80ddf" requests linking to directory "C:/msys64/mingw64/lib". Targets may link only to libraries. CMake is dropping the item.
WARNING: Target "cmTC_80ddf" requests linking to directory "C:/msys64/mingw64/lib". Targets may link only to libraries. CMake is dropping the item.
WARNING: Target "cmTC_80ddf" requests linking to directory "C:/msys64/mingw64/lib". Targets may link only to libraries. CMake is dropping the item.
WARNING: Target "cmTC_80ddf" requests linking to directory "C:/msys64/mingw64/lib". Targets may link only to libraries. CMake is dropping the item.
-- Looking for gzopen in C:/msys64/mingw64/lib - not found
Note: I do not have Window computer with MinGW so I have to work blindly with an appveyor script: edit it, git push it, and see results in appveyor logs. Feel free to use and adapt my appveyor.yml script calling the pacman install script for your own tests.
from zipper.
Seems like you would need to edit the CMakeLists.txt file, such that it either:
- takes a user-defined value for
LIBZ_LIBRARY
, in your case pointing straight to/mingw64/lib/libz.a
(if (NOT LIBZ_LIBRARY)
, followed by anotherendif()
after the current one in @L128) - or also accepts
zlib.a
inNAMES
for LIBZ_LIBRARY (@l108)
Disclaimer: I did not test this solution. It's an educated guess.
from zipper.
@oranja, thanks you ! I had not time checking your suggestion yet. I postponed window CI for the moment.
from zipper.
Closed by #76
from zipper.
Related Issues (20)
- Stuck when adding files to a password protected zip file on WSL Ubuntu HOT 4
- Zip not updated if already exists HOT 4
- Update to Zlib outdated versions HOT 11
- Update to Minizip outdated versions HOT 2
- Annoucement: Zipper v2.0 in gestation HOT 1
- Do not mix zlib and zlib-ng and minizip (included in zlib) and minizip-ng HOT 3
- unzipper.cpp extractAll can be refined HOT 1
- What do I need to change to compile a static lib for Mac universal build? HOT 2
- why include minizip &&zlb HOT 1
- Dummy zip file cannot be open by Unzipper
- !!! PROJECT HAS CHANGED OF REPO !!! HOT 3
- unzip speed too low! HOT 14
- zip folder error HOT 1
- "extractAll" method is too slowly HOT 1
- Error encrypted archive HOT 5
- Remove exception HOT 3
- Mixture of public and private flags
- Problem with add method after calling password constructor HOT 5
- Oversized archive after zipping HOT 3
- Expose more of minizip's info struct HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from zipper.