eagleas / clamav

ClamAV Ruby bindings
25 stars 9 forks source link

Error on clamav install #8

Closed jhonathas closed 7 years ago

jhonathas commented 7 years ago

Hello,

I try to install the gem and gives error. I installed clamav the brew. And they did successfully freshclam.

The error I have is:

Building native extensions. This could take a while... ERROR: Error installing clamav: ERROR: Failed to build gem native extension.

current directory: /Users/jhonathas/.asdf/installs/ruby/2.3.0/lib/ruby/gems/2.3.0/gems/clamav-0.4.1/ext/clamav

/Users/jhonathas/.asdf/installs/ruby/2.3.0/bin/ruby -r ./siteconf20161024-5705-1qy2kwl.rb extconf.rb checking for clamav.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=/Users/jhonathas/.asdf/installs/ruby/2.3.0/bin/$(RUBY_BASE_NAME) --with-clamav-dir --without-clamav-dir --with-clamav-include --without-clamav-include=${clamav-dir}/include --with-clamav-lib --without-clamav-lib=${clamav-dir}/lib

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

/Users/jhonathas/.asdf/installs/ruby/2.3.0/lib/ruby/gems/2.3.0/extensions/x86_64-darwin-16/2.3.0/clamav-0.4.1/mkmf.log

extconf failed, exit code 1

Gem files will remain installed in /Users/jhonathas/.asdf/installs/ruby/2.3.0/lib/ruby/gems/2.3.0/gems/clamav-0.4.1 for inspection. Results logged to /Users/jhonathas/.asdf/installs/ruby/2.3.0/lib/ruby/gems/2.3.0/extensions/x86_64-darwin-16/2.3.0/clamav-0.4.1/gem_make.out

yoshitsugu commented 7 years ago

@jhonathas hi. I faced similar error but I can install with following options

gem install clamav -- --with-clamav-include=/usr/local/Cellar/clamav/0.99.2_1/include --with-clamav-lib=/usr/local/Cellar/clamav/0.99.2_1/lib --with-cppflags=-I/usr/local/opt/openssl/include

I hope this can help you.

jhonathas commented 7 years ago

Hmmm, I'll test, thanks for the tip. Just as I want to test, I will give a return.

diegonogueira commented 7 years ago

Thanks!

jhonathas commented 7 years ago

Thanks!