Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Ruby > cross-compiling ruby

Reply
Thread Tools

cross-compiling ruby

 
 
Dan Hinz
Guest
Posts: n/a
 
      09-28-2005
--=-90UWnLEkDTPdEhDU6X7J
Content-Type: text/plain
Content-Transfer-Encoding: 7bit

I have an application on a stand-alone pwba. The platform has a linux
kernel on it but no compiler. The way we build apps for it is to use a
cross-compiler. I would like to install ruby there in order to create
some scriptable testing facilities.

When I tried to cross-compile ruby using the standard configure
mechanism it fails saying that it can't check setpgrp when
cross-compiling. I cheated and removed that check from configure but
then had other problems with ext/extmk.rb.

So, finally the question. Before I go off and spend a lot of time at it,
has anyone explored what it will take to cross-compile ruby? For what
it's worth the host is x86 and the target is ppc.

-dwh-
--
I not only live each endless day in grief, but live each day
thinking about living each day in grief.
-- C.S. Lewis

Daniel W. Hinz Xerox Corp: XOG/SEBU/MCD/EIDC/ISM&D
MS: 111-03J e-mail: http://www.velocityreviews.com/forums/(E-Mail Removed)
800 Phillips Road TEL: 585.422.8078
Webster, NY 14580

--=-90UWnLEkDTPdEhDU6X7J--


 
Reply With Quote
 
 
 
 
nobuyoshi nakada
Guest
Posts: n/a
 
      09-29-2005
Hi,

At Thu, 29 Sep 2005 03:19:01 +0900,
Dan Hinz wrote in [ruby-talk:158117]:
> When I tried to cross-compile ruby using the standard configure
> mechanism it fails saying that it can't check setpgrp when
> cross-compiling. I cheated and removed that check from configure but
> then had other problems with ext/extmk.rb.


$ ac_cv_func_setpgrp_void=yes ./configure CC=$cross_cc

--
Nobu Nakada


 
Reply With Quote
 
 
 
 
Kero
Guest
Posts: n/a
 
      10-01-2005
> So, finally the question. Before I go off and spend a lot of time at it,
> has anyone explored what it will take to cross-compile ruby? For what
> it's worth the host is x86 and the target is ppc.


Ruby needs a lot of headerfiles to compile all libraries. Your best bet
for those is to set up a "cross-root" with all libs and includes that
you need.

/cross/
/cross/usr/include/
/cross/usr/lib/
....

If you have a packaging system for the target platform, it may be as
easy as `pkg -dest /cross` (assuming pkg runs on your compiling
machine; in my case (ipkg for familiar-linux on arm4) it did).

This will never solve the issue with setpgrep and friends, since the
resulting testprogram can't be executed locally. It's a shame ./configure
has no option to override those cross-compiling things. See the other
followup for a solution to some of those.

--

I had the luck to have a networked machine available with a huge NFS
mount on it with the dev environment; in other words, I could compile
natively.

Because of that, I do not know how various ruby libraries with
extconf.rb and such will react in such a /cross environment.

+--- Kero ------------------------- kero@chello@nl ---+
| all the meaningless and empty words I spoke |
| Promises -- The Cranberries |
+--- M38c --- http://members.chello.nl/k.vangelder ---+
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Ruby extension (C++) on OS X [ruby 1.8.2] and Google-Sketchup [ruby 1.8.5] Nicholas Ruby 3 01-28-2007 01:48 AM
The Ruby Edge - Digg for Ruby and Ruby On Rails roschler Ruby 0 10-15-2006 11:35 PM
ruby-talk, comp.lang.ruby, ruby-talk-google Phrogz Ruby 4 09-06-2006 06:43 PM
#!/usr/bin/ruby , #!/usr/bin/ruby -w , #!/usr/bin/ruby -T?, #!/usr/bin/ruby -T1... anne001 Ruby 1 04-23-2006 03:02 PM
[ANN] ruby-freedb, ruby-serialport, ruby-mp3info moved to Rubyforge guillaume.pierronnet@ratp.fr Ruby 0 08-31-2003 11:57 PM



Advertisments