Hello, I'm looking for some advice on how to build an embedded perl interpreter on win7 x64 What I did so far is, cloned the perl github repo and built, tested and installed perl by doing the following in the win32 directory within a x64 Native Tools Command Prompt for VS 2017 Now, when trying to build an embedded perl with the same compiler VS2017 community and using the minimal sample
#include "pch.h" #include <EXTERN.h> #include <perl.h> static PerlInterpreter *my_perl; int main(int argc, char **argv, char **env) { my_perl = perl_alloc(); perl_construct(my_perl); perl_parse(my_perl, NULL, argc, argv, (char **)NULL); perl_run(my_perl); perl_destruct(my_perl); perl_free(my_perl); }
it builds the exe but crashes on perl_parse api function when executing it like this

embeddedperl test.pl.

Note, the lib directory as well as the perl.dll has been copied over to VS output directory from the previously created and installed perl interpreter. It looks like the issue is that it is looking for a path or perl module called MSWin32-x64-multi-thread like ...\EmbeddedPerl\x64\Debug\lib\MSWin32-x64-multi-thread. (revealed by procmon) but this hasn't been created. As I'm neither an experienced perl user nor c/c++ programmer, it is most likely that the issue raised from something stupid I did. I tried it with perl 5.30 as well as with the bleed branch from github but the result was the same. Similar code was working on linux ubuntu 19.04. Questions: Thank you Eko

In reply to Embedded perl on windows x64 by ekopalypse

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.