Open PortAudio-admin opened 17 years ago
Comment by Anonymous on Assembla
[Trac: Originally commented by jf_menard on 2007-09-07 04:33:35]
Someone should commit this patch to SVN.
Comment by @RossBencina
I'm not sure the PA_API_CC macro format used here is sufficent to cover calling conventions on all platforms. I've seen other calling convention macros that take the return types as parameters. Also need to resolve how this interacts with doxygen.
The question is not so much with whether we need what this patch does -- it's whether this patch does it the best way for all platforms.
Should review other code bases for guidance. (python libs?)
Comment by @RossBencina
The patch included a number of unrelated doc comment typo corrections. These have now been committed as r1594.
Comment by @RossBencina
Recent list discussion have identified the following issues and open questions (not sure this is exhaustive yet):
__declspec(import)
and calling convention). Python uses macros like PA_API_FUNC(RETURNTYPE) that can insert code before and after the return type.__stdcall
is the defacto standard but we will need to explore name mangling issues.Comment by @RossBencina
TRAC migration: propagating ticket status from TRAC
Comment by @RossBencina
Ticket58.patch (26.8 KB) - added to Trac by jf_menard 4 years ago: SVN patch for ticket #58
Related #285
This would also be helpful when binding to languages that require you to specify the calling convention when calling a method in a shared library (such as C#), cause without that bindings have to assume the calling convention compilers default to.
Issue created by Anonymous on Assembla
[Trac: Originally reported by jf_menard on 2007-09-07 04:33:35]
[Trac: Originally assigned to jf_menard]
Use a define for API calling convention. This is required if static-linked with another calling convention.
Declare a struct packing in public headers. Required to ensure consistent packing across projects (in VS2005).
We are reviewing this ticket on the mailing list. A summary of discussions is here: http://www.portaudio.com/trac/wiki/StructPackingAndApiCallingConvention