--4Y142/9l9nQlBiaj
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable


Hi - my only experience with this is with Perl, but I would take a guess
that the process should be similar (someone else my know better).

Basically you would create a normal C extension for Ruby, but ensure
that your symbols are externalised (extern "C" { ... }), and then use
the c++ compiler.  Then create your subroutines as normal, and call out
to the C++ library functions (thatyou need to link in).
I've not tried it myself, but I would have thought that it could be made
to fly?

Cheers,

Piers Harding.


On Thu, May 05, 2005 at 11:14:07AM +0900, Derek Haskin wrote:
>=20
>=20
>=20
>=20
> Hi,
>=20
> Does any know how I would go about making calls to a set of APIs written =
in
> C++
>=20
> The reason is I want to use ruby to make direct calls to our source contr=
ol
> tool which is Harvest.
>=20
> thanks
> derek.
>=20
>=20
>=20
> <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<---->>>>>>>>>>>>>>>>>>>=
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
> Privileged/Confidential information may be contained in this message.
> If you are not the addressee indicated in this message (or responsible fo=
r delivery of the message to such person), you may not copy or deliver this=
 message to anyone.
> In such a case, you should destroy this message and kindly notify the sen=
der by reply e-mail or by telephone on (03) 9612-6999 or (61) 3 9612-6999.
> Please advise immediately if you or your employer does not consent to Int=
ernet e-mail for messages of this kind.
> Opinions, conclusions and other information in this message that do not r=
elate to the official business of Transurban Limited and CityLink Melbourne=
 Limited shall be understood as neither given nor endorsed by them.
> <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<---->>>>>>>>>>>>>>>>>>>=
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>=20

--=20
http://www.piersharding.com
http://search.cpan.org/~piers/


--4Y142/9l9nQlBiaj
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (GNU/Linux)

iD8DBQFCedjpGETamPT/o4ARApM4AJ420pJLReNFay+BJvRoW700GrrBRQCeMZdn
NTSQi7Majuk3hRUuZxg3pbQ=
=uMAK
-----END PGP SIGNATURE-----

--4Y142/9l9nQlBiaj--


Hi - my only experience with this is with Perl, but I would take a guess
that the process should be similar (someone else my know better).

Basically you would create a normal C extension for Ruby, but ensure
that your symbols are externalised (extern "C" { ... }), and then use
the c++ compiler.  Then create your subroutines as normal, and call out
to the C++ library functions (thatyou need to link in).
I've not tried it myself, but I would have thought that it could be made
to fly?

Cheers,

Piers Harding.


On Thu, May 05, 2005 at 11:14:07AM +0900, Derek Haskin wrote:
>=20
>=20
>=20
>=20
> Hi,
>=20
> Does any know how I would go about making calls to a set of APIs written =
in
> C++
>=20
> The reason is I want to use ruby to make direct calls to our source contr=
ol
> tool which is Harvest.
>=20
> thanks
> derek.
>=20
>=20
>=20
> <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<---->>>>>>>>>>>>>>>>>>>=
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
> Privileged/Confidential information may be contained in this message.
> If you are not the addressee indicated in this message (or responsible fo=
r delivery of the message to such person), you may not copy or deliver this=
 message to anyone.
> In such a case, you should destroy this message and kindly notify the sen=
der by reply e-mail or by telephone on (03) 9612-6999 or (61) 3 9612-6999.
> Please advise immediately if you or your employer does not consent to Int=
ernet e-mail for messages of this kind.
> Opinions, conclusions and other information in this message that do not r=
elate to the official business of Transurban Limited and CityLink Melbourne=
 Limited shall be understood as neither given nor endorsed by them.
> <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<---->>>>>>>>>>>>>>>>>>>=
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>=20

--=20
http://www.piersharding.com
http://search.cpan.org/~piers/

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (GNU/Linux)

iD8DBQFCedjpGETamPT/o4ARApM4AJ420pJLReNFay+BJvRoW700GrrBRQCeMZdn
NTSQi7Majuk3hRUuZxg3pbQ=
=uMAK
-----END PGP SIGNATURE-----