Snorby / snorby

Ruby On Rails Application For Network Security Monitoring
Other
1k stars 225 forks source link

Gem::Ext::BuildError: ERROR: Failed to build gem native extension. #457

Open lowrisk opened 7 years ago

lowrisk commented 7 years ago

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory: /snorby/vendor/cache/ruby/2.3.0/gems/do_postgres-0.10.16/ext/do_postgres

/usr/bin/ruby2.3 -r ./siteconf20170220-14909-12k1vq7.rb extconf.rb checking for main() in -lpq... yes checking for libpq-fe.h... yes checking for libpq/libpq-fs.h... yes checking for postgres.h... no extconf.rb failed Could not create Makefile due to some reason, probably lack of necessary libraries and/or headers. Check the mkmf.log file for more details. You may need configuration options.

Provided configuration options: --with-opt-dir --without-opt-dir --with-opt-include --without-opt-include=${opt-dir}/include --with-opt-lib --without-opt-lib=${opt-dir}/lib --with-make-prog --without-make-prog --srcdir=. --curdir --ruby=/usr/bin/$(RUBY_BASE_NAME)2.3 --with-pgsql-server-dir --without-pgsql-server-dir --with-pgsql-server-include --without-pgsql-server-include=${pgsql-server-dir}/include --with-pgsql-server-lib --without-pgsql-server-lib=${pgsql-server-dir}/lib --with-pgsql-client-dir --without-pgsql-client-dir --with-pgsql-client-include --without-pgsql-client-include=${pgsql-client-dir}/include --with-pgsql-client-lib --without-pgsql-client-lib=${pgsql-client-dir}/lib --with-pqlib --without-pqlib Could not find PostgreSQL build environment (libraries & headers): Makefile not created

To see why this extension failed to compile, please check the mkmf.log which can be found here:

/snorby/vendor/cache/ruby/2.3.0/extensions/arm-linux/2.3.0/do_postgres-0.10.16/mkmf.log

extconf failed, exit code 1

Gem files will remain installed in /snorby/vendor/cache/ruby/2.3.0/gems/do_postgres-0.10.16 for inspection. Results logged to /snorby/vendor/cache/ruby/2.3.0/extensions/arm-linux/2.3.0/do_postgres-0.10.16/gem_make.out

An error occurred while installing do_postgres (0.10.16), and Bundler cannot continue. Make sure that gem install do_postgres -v '0.10.16' succeeds before bundling.

ITwrx commented 7 years ago

i had the same problem and i installed postgresql and postgresql-libs (i'm using archlinux) and it worked afterward.

wnpltech commented 7 years ago

I am having the same issue. I am attempting to install snorby and I can not becuase do_postgres-0.10.16 is not exsistent for the "install bundle" to work. I have downloaded do_postgres-0.10.17 gem but this i still can not install snorby. Below is my output.

~$: sudo bundle install Don't run Bundler as root. Bundler can ask for sudo if it is needed, and installing your bundle as root will break this application for all non-root users on this machine. The dependency jruby-openssl (>= 0) will be unused by any of the platforms Bundler is installing for. Bundler is installing for ruby but the dependency is only for java. To add those platforms to the bundle, run bundle lock --add-platform java. The dependency warbler (>= 0) will be unused by any of the platforms Bundler is installing for. Bundler is installing for ruby but the dependency is only for java. To add those platforms to the bundle, run bundle lock --add-platform java. The dependency jruby-rack-worker (>= 0) will be unused by any of the platforms Bundler is installing for. Bundler is installing for ruby but the dependency is only for java. To add those platforms to the bundle, run bundle lock --add-platform java.

Fetching gem metadata from https://rubygems.org/............ Fetching version metadata from https://rubygems.org/... Fetching dependency metadata from https://rubygems.org/.. Resolving dependencies... Using rake 0.9.2 Using RedCloth 4.2.9 Using i18n 0.7.0 Using multi_json 1.11.2 Using builder 3.0.4 Using erubis 2.7.0 Using journey 1.0.4 Using rack 1.4.7 Using hike 1.2.3 Using tilt 1.4.1 Using mime-types 1.25.1 Using polyglot 0.3.5 Using arel 3.0.3 Using tzinfo 0.3.44 Using addressable 2.3.8 Using ansi 1.5.0 Using bcrypt 3.1.10 Using bundler 1.14.6 Using byebug 6.0.0 Using cancan 1.6.10 Using highline 1.7.3 Using net-ssh 2.9.2 Using mini_portile 0.6.2 Using chronic 0.3.0 Using closure-compiler 1.1.11 Using daemons 1.1.9 Using orm_adapter 0.0.7 Using diff-lcs 1.2.5 Using json 1.8.3 Using thor 0.19.1 Using fastercsv 1.5.5 Using json_pure 1.8.2 Using stringex 1.5.1 Using uuidtools 2.1.5 Using ruby-graphviz 1.2.2 Using env 0.3.0 Using eventmachine 1.0.8 Using pdfkit 0.4.6 Using geoip 1.1.2 Using home_run 1.0.9 Using yui-compressor 0.12.0 Using minitest 4.7.5 Using net-dns 0.6.1 Using netaddr 1.5.0 Using power_assert 0.2.4 Using request_store 1.0.8 Using rspec-core 2.0.1 Using simple_form 1.2.2 Using whois 2.3.0 Using activesupport 3.2.22 Using rack-cache 1.2 Using rack-test 0.6.3 Using warden 1.2.3 Using rack-ssl 1.3.4 Using sprockets 2.2.3 Using treetop 1.4.15 Using timezone_local 0.1.5 Using data_objects 0.10.16 Using dm-core 1.2.1 Using launchy 2.4.3 Using bcrypt-ruby 3.1.5 Using net-scp 1.2.1 Using net-sftp 2.1.2 Using net-ssh-gateway 1.2.0 Using nokogiri 1.6.6.2 Using rspec-expectations 2.0.1 Using rdoc 3.12.2 Using thin 1.6.3 Using ezprint 0.2.0 from https://github.com/mephux/ezprint.git (at rails3@c231df7) Using jammit 0.5.4 Using turn 0.9.7 Using test-unit 3.1.3 Using activemodel 3.2.22 Using delayed_job 2.1.4 Using rubycas-client 2.3.9 Using mail 2.5.4 Using do_mysql 0.10.17 Installing do_postgres 0.10.16 with native extensions Using dm-aggregates 1.2.0 Using dm-observer 1.2.0 Using dm-ar-finders 1.2.0 Using dm-constraints 1.2.0 Using dm-migrations 1.2.0 Using dm-serializer 1.2.2 Using dm-timestamps 1.2.0 Using dm-do-adapter 1.2.0 Using dm-is-read_only 0.3.0 from https://github.com/postmodern/dm-is-read_only.git (at master@43ffedc) Using dm-transactions 1.2.0 Using dm-validations 1.2.0 Using dm-visualizer 0.1.0 Using dm-zone-types 0.3 Using letter_opener 1.4.1 Using devise 1.5.4 Using dm-types 1.2.2 Using capistrano 2.14.1 Using xpath 2.0.0 Using rspec-mocks 2.0.1 Using actionpack 3.2.22 Using activerecord 3.2.22 Using activeresource 3.2.22 Using dm-activemodel 1.2.1 Gem::Ext::BuildError: ERROR: Failed to build gem native extension. **<------- THIS ERROR_**

current directory: /usr/local/lib/ruby/gems/2.3.0/gems/do_postgres-0.10.16/ext/do_postgres

/usr/local/bin/ruby -r ./siteconf20170518-15831-1wvg5qr.rb extconf.rb checking for main() in -lpq... yes checking for libpq-fe.h... yes checking for libpq/libpq-fs.h... yes checking for postgres.h... no extconf.rb failed Could not create Makefile due to some reason, probably lack of necessary libraries and/or headers. Check the mkmf.log file for more details. You may need configuration options.

Provided configuration options: --with-opt-dir --without-opt-dir --with-opt-include --without-opt-include=${opt-dir}/include --with-opt-lib --without-opt-lib=${opt-dir}/lib --with-make-prog --without-make-prog --srcdir=. --curdir --ruby=/usr/local/bin/$(RUBY_BASE_NAME) --with-pgsql-server-dir --without-pgsql-server-dir --with-pgsql-server-include --without-pgsql-server-include=${pgsql-server-dir}/include --with-pgsql-server-lib --without-pgsql-server-lib=${pgsql-server-dir}/lib --with-pgsql-client-dir --without-pgsql-client-dir --with-pgsql-client-include --without-pgsql-client-include=${pgsql-client-dir}/include --with-pgsql-client-lib --without-pgsql-client-lib=${pgsql-client-dir}/lib --with-pqlib --without-pqlib Could not find PostgreSQL build environment (libraries & headers): Makefile not created

To see why this extension failed to compile, please check the mkmf.log which can be found here:

/usr/local/lib/ruby/gems/2.3.0/extensions/x86_64-linux/2.3.0-static/do_postgres-0.10.16/mkmf.log

extconf failed, exit code 1 <----------- ANOTHER ERROR

Gem files will remain installed in /usr/local/lib/ruby/gems/2.3.0/gems/do_postgres-0.10.16 for inspection. Results logged to /usr/local/lib/ruby/gems/2.3.0/extensions/x86_64-linux/2.3.0-static/do_postgres-0.10.16/gem_make.out

An error occurred while installing do_postgres (0.10.16), and Bundler cannot continue. Make sure that gem install do_postgres -v '0.10.16' succeeds before bundling.