Ruby Forum Mongrel > mongrel and fastthread on ruby 1.9?

Posted by Stephen Bannasch (Guest)
on 18.11.2007 07:22
(Received via mailing list)
Is anybody testing mongrel on ruby 1.9. I just tried installing
mongrel on trunk 1.9 and trunk rubygems and got this error compiling
fastthread:

/Users/stephen/dev/ruby/1.9_trunk/bin/ruby extconf.rb install mongrel 
--no-rdoc
creating Makefile

make
gcc -I.
-I/Users/stephen/dev/ruby/1.9_trunk/include/ruby-1.9/i686-darwin8.10.1
-I/Users/stephen/dev/ruby/1.9_trunk/include/ruby-1.9 -I.  -fno-common
-g -O2  -fno-common -pipe -fno-common  -c fastthread.c
fastthread.c:13:20: error: intern.h: No such file or directory
fastthread.c:349: error: static declaration of 'rb_mutex_locked_p'
follows non-static declaration
/Users/stephen/dev/ruby/1.9_trunk/include/ruby-1.9/ruby/intern.h:553:
error: previous declaration of 'rb_mutex_locked_p' was here
fastthread.c:366: error: static declaration of 'rb_mutex_try_lock'
follows non-static declaration
/Users/stephen/dev/ruby/1.9_trunk/include/ruby-1.9/ruby/intern.h:554:
error: previous declaration of 'rb_mutex_try_lock' was here
fastthread.c:406: error: static declaration of 'rb_mutex_lock'
follows non-static declaration
/Users/stephen/dev/ruby/1.9_trunk/include/ruby-1.9/ruby/intern.h:555:
error: previous declaration of 'rb_mutex_lock' was here
fastthread.c:463: error: static declaration of 'rb_mutex_unlock'
follows non-static declaration
/Users/stephen/dev/ruby/1.9_trunk/include/ruby-1.9/ruby/intern.h:556:
error: previous declaration of 'rb_mutex_unlock' was here
fastthread.c:524: error: static declaration of 'rb_mutex_synchronize'
follows non-static declaration
/Users/stephen/dev/ruby/1.9_trunk/include/ruby-1.9/ruby/intern.h:558:
error: previous declaration of 'rb_mutex_synchronize' was here
fastthread.c: In function 'wait_condvar':
fastthread.c:626: warning: passing argument 1 of 'rb_ensure' from
incompatible pointer type
make: *** [fastthread.o] Error 1
Posted by Evan Weaver (eweaver)
on 19.11.2007 01:34
(Received via mailing list)
No, we are not. Fastthread will almost certainly not work.

Evented Mongrel might have a better chance at working smoothly because
of all the threading changes.

Evan

On Nov 18, 2007 1:12 AM, Stephen Bannasch
Posted by Luis Lavena (luislavena)
on 19.11.2007 11:55
(Received via mailing list)
On Nov 18, 2007 3:12 AM, Stephen Bannasch
<stephen.bannasch@deanbrook.org> wrote:
> -I/Users/stephen/dev/ruby/1.9_trunk/include/ruby-1.9 -I.  -fno-common
> fastthread.c:406: error: static declaration of 'rb_mutex_lock'
> error: previous declaration of 'rb_mutex_synchronize' was here
> fastthread.c: In function 'wait_condvar':
> fastthread.c:626: warning: passing argument 1 of 'rb_ensure' from
> incompatible pointer type
> make: *** [fastthread.o] Error 1
> _______________________________________________
> Mongrel-users mailing list
> Mongrel-users@rubyforge.org
> http://rubyforge.org/mailman/listinfo/mongrel-users
>



--
Luis Lavena
Multimedia systems
-
Leaders are made, they are not born. They are made by hard effort,
which is the price which all of us must pay to achieve any goal that
is worthwhile.
Vince Lombardi
Posted by Luis Lavena (luislavena)
on 19.11.2007 11:58
(Received via mailing list)
On Nov 18, 2007 3:12 AM, Stephen Bannasch
<stephen.bannasch@deanbrook.org> wrote:
> Is anybody testing mongrel on ruby 1.9. I just tried installing
> mongrel on trunk 1.9 and trunk rubygems and got this error compiling
> fastthread:
>

Fastthread corrected problems on Ruby 1.8 implementation of array,
mutex and synchronize.

These corrections where merged to trunk and are available under
--disable-fastthread option of configure.

Also, ruby 1.8.6 ships with these changes, so dependency of fastthread
is only required for ruby < 1.8.6

--
Luis Lavena
Multimedia systems
-
Leaders are made, they are not born. They are made by hard effort,
which is the price which all of us must pay to achieve any goal that
is worthwhile.
Vince Lombardi
Posted by Todd Fisher (Guest)
on 19.11.2007 15:53
Attachment: ruby19.patch (2,3 KB)
(Received via mailing list)
Here's an initial patch to support ruby 1.9
Posted by Luis Lavena (luislavena)
on 19.11.2007 16:12
(Received via mailing list)
On Nov 18, 2007 6:51 PM, Todd Fisher <todd.fisher@gmail.com> wrote:
> Here's an initial patch to support ruby 1.9
>

The patch you sent has nothing in relation to what Stephen is
commenting: he couldn't get mongrel installed as gem since fastthread
compile process failed.

Anyway, the support for 1.9 was discussed last month on #mongrel-dev
and the result was something like you attached.

But anyway, you need to manually build and install mongrel from source
since the gem dependency will remain there.

Hmn, second thought: maybe we could remove the "official" dependency
on fastthread and evaluate if the ruby version you're using is fixed?

In the same idea of cgi-eof-fix 
(long-name-of-gem-to-be-easily-remembered).

--
Luis Lavena
Multimedia systems
-
Leaders are made, they are not born. They are made by hard effort,
which is the price which all of us must pay to achieve any goal that
is worthwhile.
Vince Lombardi
Posted by Roger Pack (rogerdpack)
on 12.06.2008 07:52
> But anyway, you need to manually build and install mongrel from source
> since the gem dependency will remain there.
> 
> Hmn, second thought: maybe we could remove the "official" dependency
> on fastthread and evaluate if the ruby version you're using is fixed?
> 
> In the same idea of cgi-eof-fix 
> (long-name-of-gem-to-be-easily-remembered).

'twould indeed be a nice convenience to have a mongrel gem that built on 
ruby 1.9 :)

These days even checking it out from trunk yields errors.
-R
Posted by Roger Pack (rogerdpack)
on 12.06.2008 08:02
> These days even checking it out from trunk yields errors.
> -R

Anybody seen anything like this before?
/Users/rogerpack/dev/ruby_19_installed/lib/ruby/site_ruby/1.9.0/mongrel/handlers.rb:214: 
warning: else without rescue is useless
SyntaxError: 
/Users/rogerpack/dev/ruby_19_installed/lib/ruby/site_ruby/1.9.0/mongrel/handlers.rb:208: 
syntax error, unexpected ':', expecting keyword_then or ',' or ';' or 
'\n'
...te(modified_since) rescue nil : false
...                               ^
/Users/rogerpack/dev/ruby_19_installed/lib/ruby/site_ruby/1.9.0/mongrel/handlers.rb:209: 
syntax error, unexpected ':', expecting keyword_end
...                              : false

with 1.9?
-R
Posted by Roger Pack (rogerdpack)
on 12.06.2008 15:45
> SyntaxError: 
> /Users/rogerpack/dev/ruby_19_installed/lib/ruby/site_ruby/1.9.0/mongrel/handlers.rb:208: 
> syntax error, unexpected ':', expecting keyword_then or ',' or ';' or 
> '\n'

replacing those colons with 'then' seems to at least let it pass the 
syntax checker.
Now if I can just get merb and hpricot to work on 1.9...
Thanks!
-R