I'm getting a different error, which I can solve by putting #include <math.h>
at line 44 of CPP.pm (first thing in the .c file). I don't know if this will solve your problem as well... -----8<----- Microsoft (R) Program Maintenance Utility Version 6.00.8168.0 Copyright (C) Microsoft Corp 1988-1998. All rights reserved. mkdir blib mkdir blib\lib mkdir blib\arch mkdir blib\arch\auto mkdir blib\arch\auto\test_pl_8b0e mkdir blib\lib\auto mkdir blib\lib\auto\test_pl_8b0e D:\Perl\bin\Perl.exe -ID:\Perl\lib -ID:\Perl\lib D:\Perl\lib\ExtUtils/xsubpp -typemap D:\Perl\lib/ExtUtils/typemap -typemap D:/Perl/modules/Inline-CPP-0.24/_Inline/build/test_pl_8b0e/CPP.map test_pl_8b0e.xs > test_pl_8b0e.xsc && D:\Perl\bin\Perl.exe -ID:\Perl\lib -ID:\Perl\lib -MExtUtils::Command -e mv test_pl_8b0e.xsc test_pl_8b0e.c cl -TP -c -ID:/Perl/modules/Inline-CPP-0.24 -O1 -MD -DNDEBUG -DWIN32 -D_CONS OLE -DNO_STRICT -DHAVE_DES_FCRYPT -DPERL_IMPLICIT_CONTEXT -DPERL_IMPLICIT_SY S -DPERL_MSVCRT_READFIX -O1 -MD -DNDEBUG -DVERSION=\"0.00\" -DXS_VERSI ON=\"0.00\" -ID:\Perl\lib\CORE test_pl_8b0e.c Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 12.00.8168 for 80x86 Copyright (C) Microsoft Corp 1984-1998. All rights reserved. test_pl_8b0e.c D:\Microsoft Visual Studio\VC98\include\math.h(514) : error C2894: templates cannot be declared to have 'C' linkage NMAKE : fatal error U1077: 'cl' : return code '0x2' Stop. -----8<----- Patrick ----- Original Message ----- From: "Piers Harding" <[EMAIL PROTECTED]> To: "Constantine Elster" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Monday, August 12, 2002 9:09 AM Subject: Re: Inline CPP problem > > For what its worth - this works fine as is under Linux (RH 7.3). The > error that you are getting looks vaguely familiar of a compiler choice > error - are you sure that you are invoking a C++ compiler and not a C > one? > > Cheers. > > On Mon, Aug 12, 2002 at 02:55:35PM +0200, Constantine Elster wrote: > > Hi. > > > > I'm trying to use Inline CPP ver 0.24 and have a very strange problem: > > I take the examples from the aspn.activestate.com and they do not compile. > > > > For example the file is: > > -------------------------------------------------------- > > use Inline CPP => <<'END'; > > class JAxH { > > public: > > JAxH(char *x); > > SV* data(); > > private: > > SV *dat; > > }; > > > > JAxH::JAxH(char *x) { dat = newSVpvf("Just Another %s Hacker", x); } > > SV* JAxH::data() { return dat; } > > > > END > > print JAxH->new('Inline')->data(), "\n"; > > -------------------------------------------------------- > > > > but the example doesn't compile. The out.make is: > > > > Microsoft (R) Program Maintenance Utility Version 6.00.8168.0 > > Copyright (C) Microsoft Corp 1988-1998. All rights reserved. > > > > C:\Perl\bin\perl.exe -IC:\Perl\lib -IC:\Perl\lib > > C:\Perl\lib\ExtUtils/xsubpp -typemap C:\Perl\lib/ExtUtils/typemap -typemap > > Z:/my_dir/Tests/_Inline/build/inline_test_pl_6483/CPP.map > > inline_test_pl_6483.xs > inline_test_pl_6483.xsc && C:\Perl\bin\perl.exe > > -IC:\Perl\lib -IC:\Perl\lib -MExtUtils::Command -e mv > > inline_test_pl_6483.xsc inline_test_pl_6483.c > > cl -c -IZ:/my_dir/Tests -nologo -O1 -MD -DNDEBUG -DWIN32 > > -D_CONSOLE -DNO_STRICT -DHAVE_DES_FCRYPT -DPERL_IMPLICIT_CONTEXT > > -DPERL_IMPLICIT_SYS -DPERL_MSVCRT_READFIX -O1 -MD > -DNDEBUG -DVERSION=\"0.00\" -DXS_VERSION=\"0.00\" -IC:\Perl\lib\CORE > > inline_test_pl_6483.c > > inline_test_pl_6483.c > > inline_test_pl_6483.xs(4) : error C2059: syntax error : 'string' > > inline_test_pl_6483.xs(16) : error C2061: syntax error : identifier 'JAxH' > > inline_test_pl_6483.xs(16) : error C2059: syntax error : ';' > > inline_test_pl_6483.xs(16) : error C2449: found '{' at file scope (missing > > function header?) > > inline_test_pl_6483.xs(23) : error C2059: syntax error : '}' > > inline_test_pl_6483.xs(26) : error C2143: syntax error : missing '{' before '*' > > inline_test_pl_6483.xs(26) : error C2143: syntax error : missing '{' before ':' > > inline_test_pl_6483.xs(26) : error C2059: syntax error : ':' > > inline_test_pl_6483.c(39) : error C2143: syntax error : missing ')' before '*' > > inline_test_pl_6483.c(39) : error C2143: syntax error : missing '{' before '*' > > inline_test_pl_6483.c(39) : error C2143: syntax error : missing ';' before '*' > > > > and more....... > > > > > > PLEASE HELP!! > > > > Thanks. > > Constantine. > > > > > > > > > > Constantine Elster > > Qualcomm Israel Ltd. > > Phone +972 4 8506437 >