node-rdkafka: Mac build is broken
After a58b736 the build on OSX is failing due to
clang: error: no such file or directory: '/<bla_bla>/change-propagation/node_modules/node-rdkafka/build/deps/librdkafka.dylib'
clang: error: no such file or directory: '/<bla_bla>/change-propagation/node_modules/node-rdkafka/build/deps/librdkafka++.dylib'
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Reactions: 5
- Comments: 17 (3 by maintainers)
Thanks to https://github.com/Blizzard/node-rdkafka/issues/405#issuecomment-398139737, I solved this on my mac.
I set BUILD_LIBRDKAFKA to 0, to prevent node-gyp build the dependencies. Then I used homebrew to install the kafka bindings
brew install librdkafkaMy error was:
I face the same issue while installing node-rdkafka on Ubuntu from master using yarn.
yarn add https://github.com/Blizzard/node-rdkafkaCould you trigger new release, so that your package can be installed from npm?
i have solve that erros: ⇒ echo ‘export PATH=“/usr/local/opt/openssl/bin:$PATH”’ >> ~/.zshrc ⇒ echo ‘export LDFLAGS=“-L/usr/local/opt/openssl/lib”’ >> ~/.zshrc ⇒ echo ‘export CPPFLAGS=“-I/usr/local/opt/openssl/include”’ >> ~/.zshrc ⇒ reload terminal
but i got new error:
Release/node-librdkafka.node clang: error: no such file or directory: '/Users/wangyong/nodejs/jd-banner-kafka/node_modules/node-rdkafka/build/deps/librdkafka.dylib' clang: error: no such file or directory: '/Users/wangyong/nodejs/jd-banner-kafka/node_modules/node-rdkafka/build/deps/librdkafka++.dylib'Yes, now I’m getting different error. Looks like
./configureis missingThis is looking more and more to me like an NPM bug. Or maybe I was just using pre-install in a way it wasn’t intended.
It makes this staging directory and then has the node-gyp variables resolve to the staging directory during the configure step. At that point, it moves the files into the correct directory, so when it tries to link it gets messed up because the prefix was made at preinstall time.
I made an adjustment to put this in gyp again. Can you try to build this from github now? You should (hopefully) at least be getting a different error