Not able to build
bharathphatak opened this issue · 8 comments
Hi, clone the project and trying the build the project. All the dependency are installed.
While building i get the following error.
ffi@2.2.0 install /home/user/plugins/kbn-authentication-plugin/node_modules/ffi
node-gyp rebuild
make: Entering directory /home/user/plugins/kbn-authentication-plugin/node_modules/ffi/build' CC(target) Release/obj.target/ffi/deps/libffi/src/prep_cif.o ../deps/libffi/src/prep_cif.c:26:17: fatal error: ffi.h: No such file or directory #include <ffi.h> ^ compilation terminated. make: *** [Release/obj.target/ffi/deps/libffi/src/prep_cif.o] Error 1 make: Leaving directory
/home/user/plugins/kbn-authentication-plugin/node_modules/ffi/build'
gyp ERR! build error
gyp ERR! stack Error: make
failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:258:23)
gyp ERR! stack at emitTwo (events.js:125:13)
gyp ERR! stack at ChildProcess.emit (events.js:213:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Linux 3.10.0-514.26.2.el7.x86_64
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/user/plugins/kbn-authentication-plugin/node_modules/ffi
gyp ERR! node -v v8.6.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! ffi@2.2.0 install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the ffi@2.2.0 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
Let me know if this is a know issue.? Or i am missing something.
Thanks,
Bharath
Hello!
Thanks for submitting an issue. Will investigate and try to reproduce as soon as possible.
Regards,
Robin
had some errors when building on linux as well. Not the exact same issue though.
do you have the build tools installed?
sudo apt-get install build-essential libssl-dev libffi-dev python-dev
Yes, I have required tool installed.
#######################################
yum install build-essential libssl-dev libffi-dev python-dev
Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile
No package build-essential available.
No package libssl-dev available.
No package libffi-dev available.
No package python-dev available.
Error: Nothing to do
##########################
"No package available" indicates that its missing, you might need to add a repository for yum to find the packages.
Could you try installing dependencies again using, for yum:
yum install -y gcc libffi-devel python-devel openssl-devel
Please let me know if this works for you.
Thanks for the replay.
I ran the above yum command.
yum install -y gcc libffi-devel python-devel openssl-devel
Loaded plugins: fastestmirror, langpacks
osquery-s3-centos7-repo | 951 B 00:00:00
Loading mirror speeds from cached hostfile
Package gcc-4.8.5-16.el7.x86_64 already installed and latest version
Package python-devel-2.7.5-58.el7.x86_64 already installed and latest version
Package 1:openssl-devel-1.0.2k-8.el7.x86_64 already installed and latest version
Resolving Dependencies
--> Running transaction check
---> Package libffi-devel.x86_64 0:3.0.13-18.el7 will be installed
--> Finished Dependency Resolution
Dependencies Resolved
===============================================================================================================================================================================================================
Package Arch Version Repository Size
===============================================================================================================================================================================================================
Installing:
libffi-devel x86_64 3.0.13-18.el7 base 23 k
Transaction Summary
===============================================================================================================================================================================================================
Install 1 Package
Total download size: 23 k
Installed size: 27 k
Downloading packages:
libffi-devel-3.0.13-18.el7.x86_64.rpm | 23 kB 00:00:00
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Installing : libffi-devel-3.0.13-18.el7.x86_64 1/1
Verifying : libffi-devel-3.0.13-18.el7.x86_64 1/1
Installed:
libffi-devel.x86_64 0:3.0.13-18.el7
Complete!
After running npm install --arch=ia32
I still get error
`ake: *** [Release/obj.target/binding/src/binding.o] Error 1
make: Leaving directory `/usr/codebase/kibana-plugins/kbn-authentication-plugin/node_modules/ref/build'
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:258:23)
gyp ERR! stack at emitTwo (events.js:125:13)
gyp ERR! stack at ChildProcess.emit (events.js:213:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Linux 3.10.0-514.26.2.el7.x86_64
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /usr/codebase/kibana-plugins/kbn-authentication-plugin/node_modules/ref
gyp ERR! node -v v8.6.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! ref@1.3.5 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the ref@1.3.5 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
`
Could you try running npm update
and then build again?
Sorry for the delayed response. After npm update, i am able to build.
Thanks :)
Closing the bug.
Thanks for reporting back!