[#4567] Re: What's the biggest Ruby development? — Aleksi Niemel<aleksi.niemela@...>

Dave said:

18 messages 2000/08/23
[#4568] Q's on Marshal — Robert Feldt <feldt@...> 2000/08/23

[#4580] RubyUnit testcase run for different init params? — Robert Feldt <feldt@...> 2000/08/25

[#4584] Re: RubyUnit testcase run for different init params? — Dave Thomas <Dave@...> 2000/08/25

Robert Feldt <feldt@ce.chalmers.se> writes:

[#4623] Re: RubyUnit testcase run for different init params? — Robert Feldt <feldt@...> 2000/08/28

On Sat, 26 Aug 2000, Dave Thomas wrote:

[#4652] Andy and Dave's European Tour 2000 — Dave Thomas <Dave@...>

24 messages 2000/08/30
[#4653] Re: Andy and Dave's European Tour 2000 — matz@... (Yukihiro Matsumoto) 2000/08/30

Hi,

[#4657] Ruby tutorials for newbie — Kevin Liang <kevin@...> 2000/08/30

Hi,

[ruby-talk:4542] Re: a question about extension modules

From: Conrad Schneiker <schneik@...>
Date: 2000-08-22 07:40:04 UTC
List: ruby-talk #4542
Clemens Hintze wrote:
> 
> >>>>> "Jon" == Jon Aseltine <aseltine@cs.umass.edu> writes:
> 
>     Jon> I asked once, but perhaps I wasn't clear enough. Is it
>     Jon> possible to implement an extension module for a C++ library
>                                                    ^^^^^^^^^^^^^^^^^
> 
> And again, you are not clear enough (sorry to say!) ;-)
> 
>     Jon> (for example, TrollTech's QT library)? The README.EXT file
>     Jon> focuses on C libraries, not C++.
...
> If you want to do it manually, you have to pay attention to certain
> points. Roughly spoken, you have to wrap the C++ library to be useable
> under Plain C! Then you can also wrap it for Ruby! You couldn't use
> classes on the C interface side! And you have to look for name
> mangeling that a C++ compiler do. For example the Init_<extension>
> function has to use C linkage and naming instead of C++ one!
> 
> Then you have to write functions for every method you want to call!
> This because C cannot call the method of an instance. Last but not
> least you would have to compile you extension with a C++ compiler and
> do not forget to link-in the C++ runtime library (e.g. libstdc++).

I don't know much about these issues, but aren't various C++ interface
hassles one of the reasons for the increasing interest in Gnome/GTK
among non-C++ users?

FYI, there is a Ruby/Qt entry in the RAA. (And Ruby/GTK too.)

-- 
Conrad Schneiker
(This note is unofficial and subject to improvement without notice.)

In This Thread

Prev Next