Is this a problem with VS.net or something? I've never done that with any of 
my C++ extensions and they've all worked fine on VC++ 6.

If it is a problem, though, I'll make the changes.

J

Shane Caraveo wrote:

> J Smith wrote:
>> Attached is a patch to ext_skel that adds an optional argument (--cpp)
>> that will create a PHP extension in C++ rather than C. Also attached is
>> skeleton.cpp, which basically mirrors ext/skeleton/skeleton.c with a few
>> modifications for using C++. I could've just made some changes to
>> skeleton.c and done some sed work in the ext_skel script, but I think
>> it's clearer to have them separated into two files.
>> 
>> The ext_skel patch is based on the current HEAD.
>> 
>> Comments?
>> 
>> J
> 
> skeleton.h also needs to be dealt with.  If you do not, visual studio
> will export symbols as c++ symbols and the extension will not work.
> Simple solution is to have
> 
> #ifdef __cplusplus
> extern "C" {
> #endif
> 
> at the top of skeleton.h, and close it at the bottom.
> 
> Shane


-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to