octopress / docs

Source for the octopress.org documentation website
24 stars 30 forks source link

Bundle install - fails on windows #52

Closed dazinator closed 9 years ago

dazinator commented 9 years ago

I have tried to install Octopress today on Windows 8.1

During the install I got this:

C:\Users\darrell.tunnell\Source\Repos\dazinator.github.io>bundle install
Fetching gem metadata from https://rubygems.org/...........
Fetching version metadata from https://rubygems.org/...
Fetching dependency metadata from https://rubygems.org/..
Resolving dependencies...
Installing rake 10.4.2
Installing RedCloth 4.2.9
Installing blankslate 2.1.2.4
Installing hitimes 1.2.2
Installing timers 4.0.1
Installing celluloid 0.16.0
Installing chunky_png 1.3.4

Gem::InstallError: The 'fast-stemmer' native gem requires installed build tools.

Please update your PATH to include build tools or download the DevKit
from 'http://rubyinstaller.org/downloads' and follow the instructions
at 'http://github.com/oneclick/rubyinstaller/wiki/Development-Kit'
An error occurred while installing fast-stemmer (1.0.2), and Bundler cannot
continue.
Make sure that `gem install fast-stemmer -v '1.0.2'` succeeds before bundling.

So I installed the build tools. I tried again and got this:

C:\Users\darrell.tunnell\Source\Repos\dazinator.github.io>bundle install
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 10.4.2
Using RedCloth 4.2.9
Using blankslate 2.1.2.4
Using hitimes 1.2.2
Using timers 4.0.1
Using celluloid 0.16.0
Using chunky_png 1.3.4

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

C:/Ruby193/bin/ruby.exe -r ./siteconf20150528-1132-13jp7fp.rb extconf.rb
creating Makefile

make clean
Makefile:165: *** target pattern contains no `%'. Stop.

make
Makefile:165: *** target pattern contains no `%'. Stop.

make failed, exit code 2

Gem files will remain installed in C:/Ruby193/lib/ruby/gems/1.9.1/gems/fast-stem
mer-1.0.2 for inspection.
Results logged to C:/Ruby193/lib/ruby/gems/1.9.1/extensions/x86-mingw32/1.9.1/fa
st-stemmer-1.0.2/gem_make.out
An error occurred while installing fast-stemmer (1.0.2), and Bundler cannot
continue.
Make sure that gem install fast-stemmer -v '1.0.2' succeeds before bundling.

I have raised an issue over here https://github.com/romanbsd/fast-stemmer/issues/10 and someone with a similar issue just trying to install jekyll on windows here: https://talk.jekyllrb.com/t/jekyll-error-failed-to-build-gem-native-extension/430/2

I'm not that familiar with ruby, but is there anything you might be able to suggest to help me get past this problem?

dazinator commented 9 years ago
imathis commented 9 years ago

I'm sorry I don't have access to a Windows machine to test a solution. This is definitely something to do with installing fast-stemmer on Windows, and not something that I can fix by changing Octopress. Hopefully they'll be able to help you understand what to do or release a fix which works for Windows.

I'm going to close this issue as it's not something I can help with, but if you hear back from them with a solution that I can incorporate somehow, please do let me know.

dazinator commented 9 years ago

I have found a solution! Raised an issue with fast-stemmer and they didn't know either, and likewise don;t have access to a windows environment. Eventually discovered this is actually an issue with RubyGems on windows. The solution is to downgrade RubyGems becuase they haven't fixed it yet as of the latest version.

gem update --system 2.3.0

The issue is found here: https://github.com/rubygems/rubygems/issues/977

imathis commented 9 years ago

Well I'll be. Glad you found it! Thanks for posting back :)

dazinator commented 9 years ago

I have documented the windows install process. I know you have moved on to the bigger and brighter OctoPress 3.0 now, but if you could perhaps put a link on the 2.0 octopress install instructions to this wiki page: https://github.com/imathis/octopress/wiki/Installation-Instructions-2.0-on-Windows it might save others some pain haha