quixdb / squash-benchmark

Benchmarking all of the algorithms from Squash
https://quixdb.github.io/squash-benchmark/
MIT License
43 stars 10 forks source link

Can't find squash/squash.h #33

Closed travisdowns closed 7 years ago

travisdowns commented 7 years ago

When building squash-benchmark, after building and installing squash 0.8, it fails as follows:

cc -Wall -Wextra -g -o benchmark benchmark.c timer.c `pkg-config --libs --cflags squash-0.8`
benchmark.c:47:27: fatal error: squash/squash.h: No such file or directory

Indeed, benchmark.c does an #include <squash/squash.h>, but the squash headers themselves are installed into a version-specific squash directory:

/usr/local/include/squash-0.8/squash.h

That directory does get on the command line thanks to pkq-config, which resolves to:

-I/usr/local/include -I/usr/local/include/squash-0.8 -L/usr/local/lib -lsquash-0.8

... but squash.h is a direct child of squash-0.8 so #include <squash/squash.h> will fail. There is a squash directory under there, but it has just the finer-grained APIs, and not squash.h.

My guess is that the idea is just that users of the installed library should just include <squash.h> so I'll submit a pull request to that effect.

travisdowns commented 7 years ago

On second thought, looking at the existing squash project, the pattern everywhere seems to be <squash/squash.h>, so perhaps it is the way the make install builds the include dir that is faulty. I'll wait for further advice.

nemequ commented 7 years ago

Sorry, working my way through my backlog; this is the issue I noticed due to the squash0.8 vs. squash-0.8 bug you also brought up. It should be fixed by 26df120df352af392fd4431f05c6f1de63390753.

travisdowns commented 7 years ago

Thanks, confirmed that it works after I pulled down 26df120.