Apache 2.x用のmod_fcgi.dllは全滅
2006/11/28にWindows環境でApache 2.2をインストールしてRuby on Railsをfcgiで動かそうとしていたときに、結局はApache 2.2は2.0からもヘッダ定義等が変更されて、2.0用のモジュールはバイナリ互換ではなくなってしまったのが原因で四苦八苦していたときの話し。
せっかく書き留めていたので、一応参考記録として残しておこうと思います。
そもそも、モジュールは下記の場所からダウンロードしたのだが、今日(2/23)確認してみると2.2用のDLLがあるので、今はそれを使えば問題ないんでしょう(試してません)。
http://www.apachelounge.com/download/
やはりオープンソースはソースからコンパイルが基本なのかなと再確認。Windows環境でバイナリが流通の基本というのに慣らされてしまっていることを改めて痛感。開発者のはしくれとしては、やはりLinux環境でソースからコンパイルするという基本に戻るのが正解かなとも思いますが... やっぱ、個人でWindowsの開発環境を整備するのはコストが結構かかりすぎですよね。
============
fcgidはApache 2.2用と書いてあったがなぜか動作せず。Loadmoduleではこけなくなったが、Apacheでcrashしてしまう模様。
gem install fcgi
をやると
Building native extensions. This could take a while…
*** 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=/usr/bin/ruby1.8
–with-fcgi-dir
–without-fcgi-dir
–with-fcgi-include=${fcgi-dir}/include
–with-fcgi-lib=${fcgi-dir}/lib
ERROR: While executing gem … (RuntimeError)
ERROR: Failed [...]
