Closed staticmem closed 2 months ago
So the file /usr/include/zzip/__hints.h does exist? Then it is nothing more that the default includepath being diverted.
On the other hand, the __xy.h files were considered to be private, so that may have led to not get them installed which breaks if they referenced in public files. I'll check that - thanks for the report.
..... the usage of __hints.h in memdisk.h is quite old however. It crept in with 1e5b1ac48186e34e871945769623becfa3650956
Yes /usr/include/zzip/__hints.h is there.
Edit: Sorry, No, it's not there.
I think this issue started after 2017 or so. Before that it had worked ok.
Sorry, no the file is not there.
$ ls -l /usr/include/zzip/
total 128
-rw-r--r-- 1 root root 1373 Jan 5 2021 autoconf.h
-rw-r--r-- 1 root root 6076 Jan 5 2021 conf.h
-rw-r--r-- 1 root root 4996 Jun 21 2021 _config.h
-rw-r--r-- 1 root root 22474 Jan 5 2021 fetch.h
-rw-r--r-- 1 root root 1897 Jan 5 2021 file.h
-rw-r--r-- 1 root root 10239 Jan 5 2021 format.h
-rw-r--r-- 1 root root 4995 Jan 5 2021 fseeko.h
-rw-r--r-- 1 root root 567 Jan 5 2021 info.h
-rw-r--r-- 1 root root 2688 Jan 5 2021 lib.h
-rw-r--r-- 1 root root 6561 Jan 5 2021 memdisk.h
-rw-r--r-- 1 root root 3965 Jan 5 2021 mmapped.h
-rw-r--r-- 1 root root 6673 Jan 5 2021 _msvc.h
-rw-r--r-- 1 root root 3095 Jan 5 2021 plugin.h
-rw-r--r-- 1 root root 1862 Jan 5 2021 stdint.h
-rw-r--r-- 1 root root 1964 Jan 5 2021 types.h
-rw-r--r-- 1 root root 776 Jan 5 2021 wrap.h
-rw-r--r-- 1 root root 2360 Jan 5 2021 write.h
-rw-r--r-- 1 root root 1065 Jan 5 2021 zzip32.h
-rw-r--r-- 1 root root 8061 Jan 5 2021 zzip.h
This is the package that was installed. I've list the file contents $ dpkg -c /var/cache/apt/archives/libzzip-dev_0.13.72+dfsg.1-1.1_amd64.deb | grep -i __hints.h Nothing
$ dpkg -c /var/cache/apt/archives/libzzip-dev_0.13.72+dfsg.1-1.1_amd64.deb | grep -i hints.h nothing
I see you have fixed the problem. I grabbed the latest ZIP and checked the ChangeLog. I'm not use to using cmake but managed to build it and install it and now my app builds successfully. Now I just need to work out how to do cross compilations. Thanks for getting on to it so quickly.
I have updated the automake stuff as well but in any case it is best to use cmake as the build tool (or conan in the future). That's where the industry is moving to.
Thanks for the feedback. And yeah, I want to provide more examples how to do crosscompiling as well.
Hello @gdraheim , not sure whether to open a new issue but it's quite related to this one. Quite a lot of the "bin" sources include the __foo.h "internal" header files. E.g. /bins/unzzip.c inludes:
#include <zzip/__debug.h>
#include <zzip/__mkdir.h>
#include <zzip/__param.h>
#include <zzip/__string.h>
Is this actually intended? The __foo.h files do not seem to be installed (see the ls output in one of the previous comments) by the make install and IIUC are supposed to be internal only. On the other hand, the unzzip.c source file mentions in the comment header: "This file is used as an example to clarify zzip api usage.", and yet it uses headers that are not part of the installed zziplib package and thus makes the unzzip.c (and the other bins/foo.c files) not really usable. In my opinion one of the following should be true:
I'm having problems building against this zzip:
Under the current Linux Mint 64 bit release I have installed this:
$ sudo apt-get install libzzip-dev
My testfile.c has:
include
include <zzip/memdisk.h>
.....
In file included from testfile.c:50: /usr/include/zzip/memdisk.h:12:10: fatal error: zzip/hints.h: No such file or directory 12 | #include <zzip/hints.h>
I don't understand what is causing this. It used to compile some years ago under a different system install.
Any solutions?