Justin
Justin

Reputation: 86789

Problems installing Thin on windows 7 x86

I'm having problems getting thin working on my Windows 7 machine (I've already installed eventmachine v0.8.1):

>gem install thin --ignore-dependencies
checking for main() in -lc... no
creating Makefile

make
'make' is not recognized as an internal or external command, operable program or batch file.

Are there not meant to be precompiled binaries available for thin?

Upvotes: 1

Views: 2833

Answers (4)

Justin
Justin

Reputation: 86789

I've worked around the lack of precompiled binaries by installing a compiler:

  1. I iInstalled MinGW to C:\MinGW (see here for installation instructions)
  2. I then installed MSYS to C:\msys\1.0
  3. I then added c:\MinGW\bin and C:\msys\1.0\bin to my %PATH%
  4. Finally I ran gem install thin and amazingly it all worked!

I hope this helps out some other poor Windows ruby developer! :-)

Upvotes: 1

Brent Matzelle
Brent Matzelle

Reputation: 4093

There actually are pre-built binaries for particular versions of Thin but you need to know which ones. To get the latest pre-built win32 version do the following:

  1. Go to the RubyGems Thin page
  2. Look under the "Versions" section for a version that has "x86-mswin32" to the right of it. (As of today versions 1.2.11, 1.2.10, etc all have win32 binaries)
  3. Run the following following "gem install" command with the version of Thin included with the "-v" flag:

gem install thin -v 1.2.11

Here are the results from my installation:

c:\>gem install thin -v 1.2.11
Successfully installed thin-1.2.11-x86-mswin32
1 gem installed
Installing ri documentation for thin-1.2.11-x86-mswin32... 
Updating ri class cache with 3611 classes... 
Installing RDoc documentation for thin-1.2.11-x86-mswin32...

Upvotes: 1

Roger_S
Roger_S

Reputation: 529

A binary for thin is in fact available (and apparently one has been since ver 1.2.2).

However, I couldn't install thin on Windows 7 with Ruby 1.9.2 (p290) because of its dependency on EventMachine.

Running gem install thin --ignore-dependencies was what was needed to get thin itself installed.

Just wanted to add this note for some other ruby on Windows user.

Upvotes: 0

Jörg W Mittag
Jörg W Mittag

Reputation: 369594

Apparently, there aren't any pre-built binaries.

You will need a C compiler installed. If you installed Ruby via the RubyInstaller, that is going to be really easy, if you used the One-Click Installer, it's goint to be a PITA.

See also: problems installing thin on Windows, which contains an answer by the RubyInstaller and One-Click Installer maintainer.

Upvotes: 2

Related Questions