[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

FXRuby on OS X Tiger

Hans Fugal

5/7/2005 3:06:00 PM

I'm new to the OS X scene, and while I used Panther for a week or two
before getting Tiger, I never tried to get FXRuby working on Panther.

Darwin ports has rb-fxruby, which compiles and installs fine but dies
in the apparently famous way:

irb(main):002:0> require 'fox12'
dyld: NSLinkModule() error
dyld: Symbol not found: __ZTIN2FX5FXAppE
Referenced from:
/opt/local/lib/ruby/vendor_ruby/1.8/powerpc-darwin7.9.0/fox12.bundle
Expected in: flat namespace

Trace/BPT trap

Tiger comes with ruby 1.8.2:

$ /usr/bin/ruby --version
ruby 1.8.2 (2004-12-25) [powerpc-darwin8.0]

It does not come with Fox, so I installed it with darwin ports. Fox
works great (e.g. the calculator). I built FXRuby 1.2.6 from scratch,
which required the following:

# Could this be added to the default search path? or maybe use the
output of fox-config?
ruby install.rb config -- --with-fox-include=/opt/local/include/fox-1.2 --with-fox-lib=/opt/local/lib
# what's up with "-arch i386" in the generated Makefile?
sed -i 's/-arch i386//g' ext/fox12/Makefile
ruby install.rb setup
sudo ruby install.rb install

I get almost exactly the same error:

$ ruby -r fox12 -e 0
dyld: NSLinkModule() error
dyld: Symbol not found: __ZTIN2FX12FXObjectListE
Referenced from:
/usr/lib/ruby/site_ruby/1.8/powerpc-darwin8.0/fox12.bundle
Expected in: flat namespace

Trace/BPT trap


I'm willing to test, give ssh, whatever.

For the record, it looks like tk aqua works out of the box on Tiger.
Very nice. Unfortunately Tk is too slow for my little app (very large
drop-down menu). Now, I did install Tcl/Tk Aqua Batteries Included
before upgrading to Tiger, but I hadn't gotten ruby tk to work in
Panther, and it worked immediately upon upgrading to Tiger. So at worst
it would seem Tk is a matter of installing Tcl/Tk Aqua BI.

8 Answers

Richard Lyman

5/7/2005 4:04:00 PM

0

On 5/7/05, Hans Fugal <fugalh@gmail.com> wrote:
<snip>

Hans - have you checked out:

http://fox-toolkit.net/cgi-bin/wiki.pl?Supported...

or

http://fox-toolkit.net/cgi-bin/wiki.p...

-Rich



Richard Kilmer

5/7/2005 5:30:00 PM

0

Have you patched the rbconfig.rb file that comes with Tiger? It is
incorrectly configured to build native extensions out of the box for
OS X. See:

http://richkilmer.blogs.com/ether/2005/04/ruby_182_i...

and specifically the [UPDATE] section at the bottom. Note that the
script that was written removes the readline.dylib that is in /usr/
lib/ so you may want to run the script minus that line.

Best,

Rich

On May 7, 2005, at 11:09 AM, Hans Fugal wrote:

> I'm new to the OS X scene, and while I used Panther for a week or two
> before getting Tiger, I never tried to get FXRuby working on Panther.
>
> Darwin ports has rb-fxruby, which compiles and installs fine but dies
> in the apparently famous way:
>
> irb(main):002:0> require 'fox12'
> dyld: NSLinkModule() error
> dyld: Symbol not found: __ZTIN2FX5FXAppE
> Referenced from:
> /opt/local/lib/ruby/vendor_ruby/1.8/powerpc-darwin7.9.0/fox12.bundle
> Expected in: flat namespace
>
> Trace/BPT trap
>
> Tiger comes with ruby 1.8.2:
>
> $ /usr/bin/ruby --version
> ruby 1.8.2 (2004-12-25) [powerpc-darwin8.0]
>
> It does not come with Fox, so I installed it with darwin ports. Fox
> works great (e.g. the calculator). I built FXRuby 1.2.6 from scratch,
> which required the following:
>
> # Could this be added to the default search path? or maybe use the
> output of fox-config?
> ruby install.rb config -- > --with-fox-include=/opt/local/include/fox-1.2> --with-fox-lib=/opt/local/lib
> # what's up with "-arch i386" in the generated Makefile?
> sed -i 's/-arch i386//g' ext/fox12/Makefile
> ruby install.rb setup
> sudo ruby install.rb install
>
> I get almost exactly the same error:
>
> $ ruby -r fox12 -e 0
> dyld: NSLinkModule() error
> dyld: Symbol not found: __ZTIN2FX12FXObjectListE
> Referenced from:
> /usr/lib/ruby/site_ruby/1.8/powerpc-darwin8.0/fox12.bundle
> Expected in: flat namespace
>
> Trace/BPT trap
>
>
> I'm willing to test, give ssh, whatever.
>
> For the record, it looks like tk aqua works out of the box on Tiger.
> Very nice. Unfortunately Tk is too slow for my little app (very large
> drop-down menu). Now, I did install Tcl/Tk Aqua Batteries Included
> before upgrading to Tiger, but I hadn't gotten ruby tk to work in
> Panther, and it worked immediately upon upgrading to Tiger. So at
> worst
> it would seem Tk is a matter of installing Tcl/Tk Aqua BI.
>
>
>
>



Jaypee

5/7/2005 6:59:00 PM

0

Hans Fugal a écrit :
> I'm new to the OS X scene, and while I used Panther for a week or two
> before getting Tiger, I never tried to get FXRuby working on Panther.
>
> Darwin ports has rb-fxruby, which compiles and installs fine but dies
> in the apparently famous way:
>
As far as I know, there is no Cocoa/Aqua version of Fox on Mac OS X.
But Fox works perfectly as a X11 client app and I can run the
scribble.rb example, or the bundled calculator or shutterbug apps.
Regards,
Jean-Pierre

Hans Fugal

5/7/2005 9:34:00 PM

0

Thanks for that, I hadn't done it. That makes my sed step unnecessary,
but the end result is still the same.

Hans Fugal

5/8/2005 12:48:00 AM

0

>As far as I know, there is no Cocoa/Aqua version of Fox on Mac OS X.
>But Fox works perfectly as a X11 client app and I can run the
>scribble.rb example, or the bundled calculator or shutterbug apps.
>Regards,
>Jean-Pierre

Yeah, I'm expecting just X11, and I'd be happy with it. Thanks

Hans Fugal

5/8/2005 12:48:00 AM

0

>As far as I know, there is no Cocoa/Aqua version of Fox on Mac OS X.
>But Fox works perfectly as a X11 client app and I can run the
>scribble.rb example, or the bundled calculator or shutterbug apps.
>Regards,
>Jean-Pierre

Yeah, I'm expecting just X11, and I'd be happy with it. Thanks

Hans Fugal

5/8/2005 12:55:00 AM

0

> http://fox-toolkit.n... /wiki.pl?Mac_OS_X

The only thing new there was the idea to compile fox with
--disable-shared. I did that, and it changed the error to this:

irb(main):001:0> require 'fox12'
dyld: NSLinkModule() error
dyld: Symbol not found: _XcursorImageLoadCursor
Referenced from:
/usr/lib/ruby/site_ruby/1.8/powerpc-darwin8.0/fox12.bundle
Expected in: flat namespace

Trace/BPT trap

Which looks like the same thing with a different library. This is
beginning to feel like managing RPMs. ;-)

wxRuby also suggests on its wiki that you compile wxWidgets with
--disable-shared, so it seems like some pervasive problem with
extensions on OS X. Does anyone have OS X library/bundle know-how?

Lothar Scholz

5/8/2005 7:28:00 AM

0

Hello Jaypee,

J> As far as I know, there is no Cocoa/Aqua version of Fox on Mac OS X.
J> But Fox works perfectly as a X11 client app and I can run the
J> scribble.rb example, or the bundled calculator or shutterbug apps.
J> Regards,
J> Jean-Pierre

Sorry but this is not true. Of course if you only look at something
like "scribble.rb" then it might be true. Key handling is completely
wrong (Alt, Cmd aka Meta) wrong and Apples X11 server has huge
problems with generating the correct Z-order of windows and delivery
of mouse events (leave/enter). The latter may be a problem with FOX i
couldn't track down the source of this problem until now.


--
Best regards, emailto: scholz at scriptolutions dot com
Lothar Scholz http://www.ru...
CTO Scriptolutions Ruby, PHP, Python IDE 's