I am not familiar with perl and XS file. This promble is resolved. I
did not know the Inline::CPP how to do it , but I think something is
wrong in my programs.
Thank you and everyone that helped me.
Regards,
邬明辉 ( Minghui Wu )
From: "Sisyphus" <[EMAIL PROTECTED]>
To: 邬 明辉 <[EMAIL PROTECTED]>, <inline@perl.org>
Subject: Re: Inline::CPP build wrong about 'MODULE'
Date: Fri, 18 Aug 2006 22:51:11 +1000
----- Original Message -----
From: "邬 明辉" <[EMAIL PROTECTED]>
.
.
>
> /************* xs file
> #ifndef bool
> #include <iostream>
> #endif
> extern "C" {
> #include "EXTERN.h"
> #include "perl.h"
> #include "XSUB.h"
> #include "INLINE.h"
> }
> #ifdef bool
> #undef bool
> #include <iostream>
> #endif
> using namespace std;
>
> #include "dbAPI.H"
> #include "sesUtilInit.H"
> dbAPI *db=new dbAPI();MODULE = ntst_pl_34eb PACKAGE = main
> PROTOTYPES: DISABLE
>
> /************************************************
That's a strange XS file. I suspect that it's not valid.
Normally there would be (at least) one newline ("\n") between 'dbAPI
*db=new
dbAPI();' and 'MODULE = ntst_pl_34eb PACKAGE = main'.
I don't know much about C++, but I suspect that perl doesn't know how to
deal with the dbAPI* type - for which you may need to provide a typemap.
(If
you attend to that, then maybe the problem will be fixed ... then again,
maybe there's more to the problem.)
Anyway ... this info is provided in the spirit of "something to think
about
while you're waiting for the informed advice of the experts" :-)
Cheers,
Rob
_________________________________________________________________
与联机的朋友进行交流,请使用 MSN Messenger: http://messenger.msn.com/cn