求助关于VS2008调用perl脚本文件的问题,高手请指教。
perl脚本文件已经由十分权威的大公司编写的,应该没有问题的,为测试怎样用那个perl脚本件怎么用,所以写了下面的程式:#include "EXTERN.h"
#include "perl.h"
static PerlInterpreter *my_perl;
int main()
{
int argc;
char **argv;
char **env;
char *embedding[] = {"","C:\\Program Files\\Broadcom Corporation\\NFC Test Tool\\Scripts\\test_rw_read.pl",""};
//char *embedding[] = {"","C:\\Perl\\eg\\example.pl",""};
//char *embedding[] = {"","C:\\Perl\\eg\\test_rw_read.pl",""};
argv=embedding;
PERL_SYS_INIT3(&argc,&argv,&env);
my_perl = perl_alloc();
perl_construct(my_perl);
PL_exit_flags |= PERL_EXIT_DESTRUCT_END;
perl_parse(my_perl, NULL, argc, argv, (char **)NULL);
perl_run(my_perl);
perl_destruct(my_perl);
perl_free(my_perl);
PERL_SYS_TERM();
}
结果如下:
Can't load module Win32::OLE,dynamic loading not avalidable in this perl.
<You may need to build a new perl executable which either supports
dynamic losding or has the Win32::OLE module statically linked into it.>
at BRCM_NFC_SCRIPT.pm line 3
//以下是说在脚本的哪个地方调用出错在此就省略了
。
。
。
//最后一句是
请按任意键继续...
PS:以上的英文说明在下可以看懂,Win32::OLE是网上下载的并注册,如果有哪位高手调用过脚本并因为不能动态打开脚本而后又解决了的请多多指教。