Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Pascal Misc > Re: gpctypes.h
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 5 of 5 Topic 739 of 814
Post > Topic >>

Re: gpctypes.h

by Waldek Hebisch <hebisch@[EMAIL PROTECTED] > May 29, 2007 at 01:22 AM

In comp.lang.pascal.misc Louie <jlrn77@[EMAIL PROTECTED]
> wrote:
> On May 28, 8:50 am, Waldek Hebisch <hebi...@[EMAIL PROTECTED]
> wrote:
> >
> > If C source requires 'gpctypes.h' then 'gpctypes.h' should be
considered
> > part of C source -- if you miss it the source you get is incomplete.
> >
> > You should first ask provider of C source about 'gpctypes.h'.  If
> > that fails you will have to re-create 'gpctypes.h', but that depends
> > on C source: we can not just guess what C source expects.
> >
> 
> I was afraid that something like this would happen...
> 
> What about compiling the GPCtypes.pas distributed with GPC and then

I do not see GPCtypes.pas in my GPC installation.

> making a call from within GCC? Has anyone tried to include Pascal
> libraries into GCC programs?
> 

Sure.  GPC has very simple mapping between C and Pascal types.  But
the catch is that both in C and in Pascal you may define your own
types.  Translating type definitions between  C and Pascal is not
hard.  However, since neither C compiler can can read Pascal nor Pascal
compiler can read C one has to do translation by hand (or use
some extra tool, but I can not recommend any).

GPC distribution contains an example (gpc_c_c.c + corresponding
Pascal files) of linking Pascal routines to C.

-- 
                              Waldek Hebisch
hebisch@[EMAIL PROTECTED]

 




 5 Posts in Topic:
gpctypes.h
Louie <jlrn77@[EMAIL P  2007-05-27 15:46:59 
Re: gpctypes.h
CBFalconer <cbfalconer  2007-05-27 21:46:27 
Re: gpctypes.h
Waldek Hebisch <hebisc  2007-05-28 13:50:25 
Re: gpctypes.h
Louie <jlrn77@[EMAIL P  2007-05-28 14:54:39 
Re: gpctypes.h
Waldek Hebisch <hebisc  2007-05-29 01:22:34 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sun Sep 7 13:19:35 CDT 2008.