Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gem install mecab fails on windows #7

Open
handrake opened this issue Oct 6, 2017 · 1 comment
Open

gem install mecab fails on windows #7

handrake opened this issue Oct 6, 2017 · 1 comment

Comments

@handrake
Copy link

handrake commented Oct 6, 2017

C:\Users\handrake>gem install mecab
Temporarily enhancing PATH for MSYS/MINGW...
Building native extensions.  This could take a while...
ERROR:  Error installing mecab:
        ERROR: Failed to build gem native extension.

    current directory: C:/Users/handrake/scoop/apps/ruby/current/gems/gems/mecab-0.996/ext/mecab
C:/Users/handrake/scoop/apps/ruby/current/bin/ruby.exe -r ./siteconf20171006-3004-1ifoez1.rb extconf.rb
checking for make... yes
*** 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:/Users/handrake/scoop/apps/ruby/current/bin/$(RUBY_BASE_NAME)
        --with-mecab-config
        --without-mecab-config
        --enable-mecab-config
        --disable-mecab-config
extconf.rb:12:in ``': No such file or directory - mecab-config --libs-only-L (Errno::ENOENT)
        from extconf.rb:12:in `<main>'

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

  C:/Users/handrake/scoop/apps/ruby/current/gems/extensions/x64-mingw32/2.4.0/mecab-0.996/mkmf.log

extconf failed, exit code 1

Gem files will remain installed in C:/Users/handrake/scoop/apps/ruby/current/gems/gems/mecab-0.996 for inspection.
Results logged to C:/Users/handrake/scoop/apps/ruby/current/gems/extensions/x64-mingw32/2.4.0/mecab-0.996/gem_make.out

After some research, it seems I need mecab-config binary from mecab package, but mecab installer version doesn't seem to come with it. Does it mean I have to build mecab itself from source in order to install mecab ruby?

Thank you very much in advance.

@markburns
Copy link
Owner

Hey sorry, I don't run Windows.
I'd be happy to accept a pull request to update the docs to make it easier if you manage to fix this.
Or to point at a more appropriate gem if you find a better solution for windows.
I believe there are a few possibly more up to date gems out there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants