Hi Rob,

Thanks for the hint. But the option -TP directs vc++ to handle all files as
C++. The problems are maros defined in lib\CORE\win32iop.h that redefine
standard C function declarations. The same functions (i.e. eof) are declared
in some standard classes but with a different signature. The preprocessor
output causing the errors istream.h(108 - 110):

class __declspec(dllimport) istream : virtual public ios {
        ...
    istream& win32_read(char *,int,);
    inline istream& win32_read(unsigned char *,int,);
    inline istream& win32_read(signed char *,int,);
        ...

Regards
Thomas

-----Original Message-----
From: Sisyphus [mailto:[EMAIL PROTECTED] 
Sent: Monday, February 21, 2005 10:02 PM
To: [EMAIL PROTECTED]
Cc: perl-win32-users@listserv.ActiveState.com
Subject: Re: Problem compiling VC++ module with XS

[EMAIL PROTECTED] wrote:
> Hi List,
>  
> I'm trying to compile a C++ XS module with MS VC++ 6.0. Due to defines 
> (redifinition of standard c funktions like eof) in win32iop.h several 
> VC++ standard headers throw errors:
> 
>  cl -c -I. -TP -MD -Zi -DNDEBUG -O1 -DVERSION=\"0.01\"
-DXS_VERSION=\"0.01\"
> "-ID:\Perl\lib\CORE" -DWIN32 MyPackage.c MyPackage.c

I *think* that if it's C++ code, then 'MyPackage.c' needs to be called
'MyPackage.cpp' with VC++ 6.0.

Cheers,
Rob
_______________________________________________
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to