Building Ruby (was Re: Ruby on Rails 2.0.2/Cygwin Bug)

View: New views
5 Messages — Rating Filter:   Alert me  

Building Ruby (was Re: Ruby on Rails 2.0.2/Cygwin Bug)

by Mike Boone :: Rate this Message:

| View Threaded | Show Only this Message

In reference to that /dev/urandom bug I encountered last week, I
thought I might try to build Ruby from source on Cygwin and see how it
works.

I downloaded Ruby 1.8.6-p111 off the ruby-lang.org website, unpacked
it, then ./configure and make. This fails with:

./missing/strftime.c:193: error: 'timezone' redeclared as different
kind of symbol
/usr/include/cygwin/time.h:33: error: previous declaration of
'timezone' was here
make: *** [strftime.o] Error 1

I'm not sure why that happens, and I'm not sure what's different about
the Cygwin Ruby package which works. Any ideas?

Incidentally, I downloaded the new development release of Ruby 1.9.0,
and it compiles just fine on Cygwin. It also runs my /dev/urandom bug
script without failing, and lseek is not called in the strace.

Mike Boone
http://boonedocks.net/mike/

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Re: Building Ruby (was Re: Ruby on Rails 2.0.2/Cygwin Bug)

by melvins :: Rate this Message:

| View Threaded | Show Only this Message

I had the same problem with you mike, what I did is I downloaded a stable-snapshot version of ruby, then I copy the missing/strftime.c file to hte 1.8.6 version,   run make again, then it now all works.


Mike Boone wrote:
In reference to that /dev/urandom bug I encountered last week, I
thought I might try to build Ruby from source on Cygwin and see how it
works.

I downloaded Ruby 1.8.6-p111 off the ruby-lang.org website, unpacked
it, then ./configure and make. This fails with:

./missing/strftime.c:193: error: 'timezone' redeclared as different
kind of symbol
/usr/include/cygwin/time.h:33: error: previous declaration of
'timezone' was here
make: *** [strftime.o] Error 1

I'm not sure why that happens, and I'm not sure what's different about
the Cygwin Ruby package which works. Any ideas?

Incidentally, I downloaded the new development release of Ruby 1.9.0,
and it compiles just fine on Cygwin. It also runs my /dev/urandom bug
script without failing, and lseek is not called in the strace.

Mike Boone
http://boonedocks.net/mike/

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

Re: Building Ruby (was Re: Ruby on Rails 2.0.2/Cygwin Bug)

by Mike Boone :: Rate this Message:

| View Threaded | Show Only this Message

On Jan 2, 2008 5:24 AM, melvins <enyasproject@...> wrote:
>
> I had the same problem with you mike, what I did is I downloaded a
> stable-snapshot version of ruby, then I copy the missing/strftime.c file to
> hte 1.8.6 version,   run make again, then it now all works.

This worked for me too. Both the 1.8.6 with the new strftime.c and the
stable-snapshot compile OK in Cygwin. However, they both also fail my
test /dev/urandom script. There must be something peculiar as to how
1.8.x builds in Cygwin that makes that script fail. Maybe now that I
have the source I could debug it, but I'm rusty on that.

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


RE: Building Ruby (was Re: Ruby on Rails 2.0.2/Cygwin Bug)

by Dave Korn :: Rate this Message:

| View Threaded | Show Only this Message

On 02 January 2008 10:25, melvins wrote:

> Mike Boone wrote:
>>
>> In reference to that /dev/urandom bug I encountered last week, I
>> thought I might try to build Ruby from source on Cygwin and see how it
>> works.
>>
>> I downloaded Ruby 1.8.6-p111 off the ruby-lang.org website, unpacked
>> it, then ./configure and make. This fails with:
>>
>> ./missing/strftime.c:193: error: 'timezone' redeclared as different kind
>> of symbol /usr/include/cygwin/time.h:33: error: previous declaration of
>> 'timezone' was here make: *** [strftime.o] Error 1
>>

> I had the same problem with you mike, what I did is I downloaded a
> stable-snapshot version of ruby, then I copy the missing/strftime.c file to
> hte 1.8.6 version,   run make again, then it now all works.

  For full explanation, see

http://cygwin.com/ml/cygwin/2007-12/msg00003.html


    cheers,
      DaveK
--
Can't think of a witty .sigline today....


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Re: Building Ruby (was Re: Ruby on Rails 2.0.2/Cygwin Bug)

by Corinna Vinschen-2 :: Rate this Message:

| View Threaded | Show Only this Message

On Jan  2 14:01, Dave Korn wrote:

> On 02 January 2008 10:25, melvins wrote:
> > Mike Boone wrote:
> >>
> >> In reference to that /dev/urandom bug I encountered last week, I
> >> thought I might try to build Ruby from source on Cygwin and see how it
> >> works.
> >>
> >> I downloaded Ruby 1.8.6-p111 off the ruby-lang.org website, unpacked
> >> it, then ./configure and make. This fails with:
> >>
> >> ./missing/strftime.c:193: error: 'timezone' redeclared as different kind
> >> of symbol /usr/include/cygwin/time.h:33: error: previous declaration of
> >> 'timezone' was here make: *** [strftime.o] Error 1
> >>
>
> > I had the same problem with you mike, what I did is I downloaded a
> > stable-snapshot version of ruby, then I copy the missing/strftime.c file to
> > hte 1.8.6 version,   run make again, then it now all works.
>
>   For full explanation, see
>
> http://cygwin.com/ml/cygwin/2007-12/msg00003.html

I've proposed a patch on comp.lang.ruby:
http://groups.google.com/group/comp.lang.ruby/msg/0e3f786c969bcd07


Corinna

--
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/