Reputation: 131
I'm trying to execute the zpipe.c file from https://zlib.net/zlib_how.html
gcc zpipe.c -o executable -lz
But I'm getting the error
zpipe.c:18:18: fatal error: zlib.h No such file or directory
I installed zlib from source following this tutorial https://geeksww.com/tutorials/libraries/zlib/installation/installing_zlib_on_ubuntu_linux.php
Upvotes: 0
Views: 3065
Reputation: 3726
Try adding -I/usr/local/include/
. It could happen that you have to specify even the library's location with -L/usr/local/lib/
.
Upvotes: 0