简体   繁体   中英

How can I embed Perl Interpreter inside a C++ application making DLL?

I need a DLL built in C++ having Perl interpreter inside it and a Perl library exiftool by Phil Harvey being called by C++ functions.

I want to do it on Windows 7 with Visual Studio 2010 VC++ installed. Which Perl distribution is best for this task: Strawberry or ActiveState Perl ? Also, which Perl compilation command: nmake or dmake?

In the end the final deliverable should be a DLL. This can be imported into any program C etc and the DLL functions will be called which will internally be calling Phil Harvey's exiftool library functions/arguments/switches.

If you've got Perl installed, the first thing you should do is look at the manpage for perlembed, ie "man perlembed" on Unix systems. Since you are on Windows, you are better off looking at the official Perl documentation on the web for "perlembed" .

There's a specific section on Win32 on that information page. As for the specifics and caveats of including perl as a DLL, I'm not much help there.

这可能有点过大,但是SWIG页面提到了从NMAKE以及扩展的Visual Studio访问Perl。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM