You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@axis.apache.org by Mark Whitlock <ma...@uk.ibm.com> on 2004/12/01 15:13:57 UTC

Autogenerating C bindings (1.5)




Hi,
I'm considering generating the C bindings from the C++ headers using a tool
run during every build.

The trace tool that instruments the code with entry/exit/catch trace
already parses our C++ headers and can parse method prototypes and know
which classes they are in. So it wouldn't be too hard for me to write
another tool that reuses these existing classes that generates the C
headers/implementation for the C bindings. This tool would be run during
every build and what it generated would not be committed to CVS. 90percent
of the work is already done in the trace tool. In fact it may be quicker
and more accurate to write the tool rather than write the headers and
functions manually. The tool would have to make the external C headers
easily human-readable and copy across the comments from the C++ headers.
The tool would also have to cope with special cases like mapping
contructors to create functions, special naming where the same method name
occurs in multiple classes, for instance.

The advantages of using a build tool are...
 - The C headers/implementation are always kept in step with the C++
headers/implementation so they are more accurate.
 - Committers don't have to maintain the C headers/implementation when they
change the C++ headers.

The advantages of manually creating the C bindings and checking them into
CVS are...
 - There is no extra tool to maintain that future committers may not be
familiar with.

Is this a good idea or not?
Mark
Mark Whitlock
IBM


Re: No commit messages!

Posted by sanjaya singharage <sa...@opensource.lk>.
Is there a web page somewhere that I can look at commit messages? Anybody
knows?

sanjaya.

----- Original Message -----
From: "sanjaya singharage" <sa...@opensource.lk>
To: "Apache AXIS C Developers List" <ax...@ws.apache.org>
Sent: Thursday, December 02, 2004 12:38 PM
Subject: No commit messages!


> I am not getting commit messages since some time. The last mail that I
have
> got from ws-axis-cvs@apache.org is on 24th Nov 2004. I am using outlook
> express.
> Any idea what could be wrong?
>
> sanjaya.
>
>
>



No commit messages!

Posted by sanjaya singharage <sa...@opensource.lk>.
I am not getting commit messages since some time. The last mail that I have
got from ws-axis-cvs@apache.org is on 24th Nov 2004. I am using outlook
express.
Any idea what could be wrong?

sanjaya.



Re: Autogenerating C bindings (1.5)

Posted by Samisa Abeysinghe <sa...@yahoo.com>.
I too think it is a great idea.
+1.

Samisa...

--- John Hawkins <HA...@uk.ibm.com> wrote:

> 
> 
> 
> 
> I think the proof could be in the pudding i.e. try it and see what happens.
> 
> Overall, I think it could be a great idea, if it'll work. !
> 
> +1
> 
> John Hawkins
> 
> 
> 
> 
>                                                                            
>              Mark                                                          
>              Whitlock/UK/IBM@I                                             
>              BMGB                                                       To 
>                                        axis-c-dev@ws.apache.org            
>              01/12/2004 14:13                                           cc 
>                                                                            
>                                                                    Subject 
>              Please respond to         Autogenerating C bindings (1.5)     
>               "Apache AXIS C                                               
>              Developers List"                                              
>                                                                            
>                                                                            
>                                                                            
>                                                                            
> 
> 
> 
> 
> 
> 
> 
> 
> Hi,
> I'm considering generating the C bindings from the C++ headers using a tool
> run during every build.
> 
> The trace tool that instruments the code with entry/exit/catch trace
> already parses our C++ headers and can parse method prototypes and know
> which classes they are in. So it wouldn't be too hard for me to write
> another tool that reuses these existing classes that generates the C
> headers/implementation for the C bindings. This tool would be run during
> every build and what it generated would not be committed to CVS. 90percent
> of the work is already done in the trace tool. In fact it may be quicker
> and more accurate to write the tool rather than write the headers and
> functions manually. The tool would have to make the external C headers
> easily human-readable and copy across the comments from the C++ headers.
> The tool would also have to cope with special cases like mapping
> contructors to create functions, special naming where the same method name
> occurs in multiple classes, for instance.
> 
> The advantages of using a build tool are...
>  - The C headers/implementation are always kept in step with the C++
> headers/implementation so they are more accurate.
>  - Committers don't have to maintain the C headers/implementation when they
> change the C++ headers.
> 
> The advantages of manually creating the C bindings and checking them into
> CVS are...
>  - There is no extra tool to maintain that future committers may not be
> familiar with.
> 
> Is this a good idea or not?
> Mark
> Mark Whitlock
> IBM
> 
> 
> 
> 



		
__________________________________ 
Do you Yahoo!? 
All your favorites on one personal page � Try My Yahoo!
http://my.yahoo.com 

Re: Autogenerating C bindings (1.5)

Posted by John Hawkins <HA...@uk.ibm.com>.



I think the proof could be in the pudding i.e. try it and see what happens.

Overall, I think it could be a great idea, if it'll work. !

+1

John Hawkins




                                                                           
             Mark                                                          
             Whitlock/UK/IBM@I                                             
             BMGB                                                       To 
                                       axis-c-dev@ws.apache.org            
             01/12/2004 14:13                                           cc 
                                                                           
                                                                   Subject 
             Please respond to         Autogenerating C bindings (1.5)     
              "Apache AXIS C                                               
             Developers List"                                              
                                                                           
                                                                           
                                                                           
                                                                           








Hi,
I'm considering generating the C bindings from the C++ headers using a tool
run during every build.

The trace tool that instruments the code with entry/exit/catch trace
already parses our C++ headers and can parse method prototypes and know
which classes they are in. So it wouldn't be too hard for me to write
another tool that reuses these existing classes that generates the C
headers/implementation for the C bindings. This tool would be run during
every build and what it generated would not be committed to CVS. 90percent
of the work is already done in the trace tool. In fact it may be quicker
and more accurate to write the tool rather than write the headers and
functions manually. The tool would have to make the external C headers
easily human-readable and copy across the comments from the C++ headers.
The tool would also have to cope with special cases like mapping
contructors to create functions, special naming where the same method name
occurs in multiple classes, for instance.

The advantages of using a build tool are...
 - The C headers/implementation are always kept in step with the C++
headers/implementation so they are more accurate.
 - Committers don't have to maintain the C headers/implementation when they
change the C++ headers.

The advantages of manually creating the C bindings and checking them into
CVS are...
 - There is no extra tool to maintain that future committers may not be
familiar with.

Is this a good idea or not?
Mark
Mark Whitlock
IBM