json2avro
json2avro copied to clipboard
snappy library not found.
Attempting to compile under Cygwin, I get the following error:
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:
SNAPPY_LIBRARIES (ADVANCED)
linked by target "avro-shared" in directory /home/<usernaeme>/json2avro/avro-c/src
linked by target "avro-static" in directory /home/<usernaeme>/json2avro/avro-c/src
This contraticts the text found under json2avro/avro-c/INSTALL:
Avro uses CMake [1] as its build manager. You must have this installed,
along with a C compiler (such as gcc) to build the library.
Avro doesn't depend on any other libraries, but you need asciidoc [2]
and source-highlight [3] installed to build Avro's documentation. The
build scripts will automatically detect whether these tools are
installed, and will skip the documentation if they're not.
Under Cygwin, I could not find any library with "snappy" in the name. Not sure what this library is about. If the dependency can become optional, the better. Else, please document the dependency in json2avro/avro-c/INSTALL.
I have the same issue in my machine as well. Were you able to solve it?
brew install snappy
(macos)
However, it was still not able to reference snappy-c.h
file, which I manually added in src
. After that the make
was successful.
Not able to make the application... due to json2avro/avro-c/src/codec.c:20:10: fatal error: 'snappy-c.h' file not found. Installed snappy using brew. Any other option other than manually placing the file inside source folder?
You're probably missing a dev package, I'm not familiar with brew, but on Linux distros it would be called something like snappy-dev or snappy-devel and would have the headers necessary for compilation included.
brew install snappy
Then:
cd avro-c/src
ln -s /usr/local/Cellar/snappy/1.1.9/include/snappy-c.h .
cd ../..
make
Works.
However, it was still not able to reference snappy-c.h file, which I manually added in src. After that the make was successful.