deepfryed / ots

ruby bindings to open text summarizer

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Tried to install it on Windows but got an error

fearnowrath opened this issue · comments

I tried installing this gem on Windows 7 but got the following error:

C:\RailsInstaller\DevKit>gem install ots
Temporarily enhancing PATH to include DevKit...
Building native extensions.  This could take a while...
ERROR:  Error installing ots:
        ERROR: Failed to build gem native extension.

    current directory: C:/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/ots-
0.5.4/ext/ots
C:/RailsInstaller/Ruby2.2.0/bin/ruby.exe -r ./siteconf20160713-9640-1bgnt1m.rb e
xtconf.rb
*** 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=C:/RailsInstaller/Ruby2.2.0/bin/$(RUBY_BASE_NAME)
extconf.rb:3:in ``': No such file or directory - pkg-config --cflags  glib-2.0 (
Errno::ENOENT)
        from extconf.rb:3:in `<main>'

extconf failed, exit code 1

Gem files will remain installed in C:/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2
.0/gems/ots-0.5.4 for inspection.
Results logged to C:/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/extensions/x86
-mingw32/2.2.0/ots-0.5.4/gem_make.out

I have railsinstaller installed and it comes with devkit as well.

Any help would be appreciated.

This library primarily targets Linux and OSX (Darwin). I'm only going by mingw's faq:

http://www.mingw.org/wiki/FAQ

You need to get pkg-config and glib-2.0 installed before you can install the OTS gem -- you could optionally use a Linux VM and try it out there if installing the mingw OTS dependencies is too hard.