error: no matching function for call to 'gzclose'
Brought to you by:
lerdsuwa
kcd 7.15.0 fails to build on macOS with zlib 1.2.11 installed using MacPorts:
./dirtree.cc:173:4: error: no matching function for call to 'gzclose'
gzclose(file);
^~~~~~~
/opt/local/include/zlib.h:1630:24: note: candidate function not viable: no known conversion from 'FILE *' (aka '__sFILE *') to 'gzFile' (aka 'gzFile_s *') for 1st argument
ZEXTERN int ZEXPORT gzclose OF((gzFile file));
^
./dirtree.cc:178:4: error: no matching function for call to 'gzclose'
gzclose(file);
^~~~~~~
/opt/local/include/zlib.h:1630:24: note: candidate function not viable: no known conversion from 'FILE *' (aka '__sFILE *') to 'gzFile' (aka 'gzFile_s *') for 1st argument
ZEXTERN int ZEXPORT gzclose OF((gzFile file));
^
2 errors generated.
Looks like a simple typo which went unnoticed in earlier versions of zlib which defined gzFile differently. The attached path allows the program to compile.
Hi
Thank you for the report. I will see what I can do with the patches,
because for a long time there is no update
to the project and it is left to Linux distributions to keep it going.
Best regards
Kriang
On Mon, Nov 4, 2019 at 8:47 PM Ryan Schmidt ryandesign@users.sourceforge.net wrote:
Related
Patches: #3