Install fcgi 0.8.8 on Ruby-1.8

J

Javier Abaroa

Hello,

I have tried to install the gem fcgi-0.8.8 for Ruby on Windows-Xp. I
have installed Fastcgi Development Kit on C:\fcgi directory and i have
compiled the source.

The source for fcgi is in "C:\fcgi\include" directory , and the
libfcgi.dll is in "c:\fcgi\libfcgi\release" directory.

When i try to install fcgi gem for ruby , i get the next error:


C:\Documents and Settings\USER>gem install fcgi -v 0.8.8 --
--with-fcgi-include=c:/fcgi/include
--with-fcgi-lib=c:/fcgi/libfcgi/release --remote
Building native extensions. This could take a while...
ERROR: Error installing fcgi:
ERROR: Failed to build gem native extension.

C:/Ruby/bin/ruby.exe extconf.rb --with-fcgi-include=c:/fcgi/include
--with-fcgi-lib=c:/fcgi/libfcgi/release --remote
checking for fcgiapp.h... yes
checking for FCGX_Accept() in -lfcgi... yes
creating Makefile

make
gcc -I. -I. -IC:/Ruby/lib/ruby/1.8/i386-mingw32 -I. -DHAVE_FCGIAPP_H
-Ic:/fcgi/include -g -O2 -c fcgi.c
fcgi.c: In function `fcgi_s_accept':
fcgi.c:82: error: `F_GETFL' undeclared (first use in this function)
fcgi.c:82: error: (Each undeclared identifier is reported only once
fcgi.c:82: error: for each function it appears in.)
make: *** [fcgi.o] Error 1


Gem files will remain installed in
C:/Ruby/lib/ruby/gems/1.8/gems/fcgi-0.8.8 for inspection.
Results logged to
C:/Ruby/lib/ruby/gems/1.8/gems/fcgi-0.8.8/ext/fcgi/gem_make.out

C:\Documents and Settings\USER>

So, i think i have missed any other global option for install the gem.I
don't know why the F_GETFL (function or variable) is undeclared. Can
someone help me?.

Thank you

Javier Abaroa.
 
J

Javier Abaroa

Hello, Brian, thank you by your answer.

The questions is, that i don't know how to make what you're saying.
Please watch my operating system is Windoes-Xp, and when y tried to
directly execute fcgi.rb in ruby , always i get the next error:

C:/Ruby/lib/ruby/site_ruby/1.8/fcgi.rb:11:in `trap': unsupported signal
SIGPIPE (ArgumentError)
from C:/Ruby/lib/ruby/site_ruby/1.8/fcgi.rb:11
from
C:/Ruby/lib/ruby/site_ruby/1.8rubygems/custom_require.rb:31:in
`gem_original_require'
from
C:/Ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
`require'
from -:3

I have tried to install over Ruby19, but things have been even worse.So
i have returned to install Ruby-1.86 (In Ruby1.9.1 i can't start
mongrel_rails and always get a buffer or cache error).

I have observed that one difference between an installed gem and a
uninstalled is that in C.\ruby\lib\ruby\gems\1.8\specifications, in case
of a installed gem exist the corr file to the extension gem and in case
of uninstalled don't.

Please. if you can show me how to install the pure fcgi.rb in a way that
it work for Apache2.2 in Windows-Xp, i will thank you so much.

Javier Abaroa.
 
B

Brian Candler

Javier said:
The questions is, that i don't know how to make what you're saying.

Sorry if I wasn't being clear. I simply meant copy fcgi.rb to your ruby
lib directory, or into your own application's lib directory.
Please watch my operating system is Windoes-Xp, and when y tried to
directly execute fcgi.rb in ruby , always i get the next error:

C:/Ruby/lib/ruby/site_ruby/1.8/fcgi.rb:11:in `trap': unsupported signal
SIGPIPE (ArgumentError)
from C:/Ruby/lib/ruby/site_ruby/1.8/fcgi.rb:11
from

OK, then that's a POSIX signal which doesn't exist in Windows. You'll
need to trim references to this out of the code.

However it does suggest that fcgi.rb hasn't been tested much (if at all)
under Windows. Maybe a cygwin build of ruby would be closer to what it
expects.

Otherwise, I suggest you do what most people do nowadays, and run your
web service as a standalone process (using mongrel, thin, unicorn etc)
and proxy to it from your apache instance using mod_proxy. With a
suitable config you can get static assets served directly from apache.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,743
Messages
2,569,478
Members
44,899
Latest member
RodneyMcAu

Latest Threads

Top