Hi, I have a rather (to me) esoteric question, something perhaps tailor-made for the Perl Monks vaults of arcane knowledge. I'm attempting to embed the Perl Interpreter in some C code, and am having some problems... While I can get the code to compile (itself, no simple task) I get the following error when I run the executable:
Can't load module File::Glob, dynamic loading not available in this pe +rl. (You may need to build a new perl executable which either supports dynamic loading or has the File::Glob module statically linked into +it.) Compilation failed in require at search.pl line 6.
Hmmm, does this require DynaLoader? And - if so - how and where do I include it? I assume in my compile statement, but nothing I'm trying (e.g.)
cc codeGen.c -o codeGen -L/usr/local/lib /opt/perl/lib/5.6.1/PA-RISC1 +.1-thread-multi/auto/DynaLoader/DynaLoader.a -L/opt /perl/lib/5.6.1/PA-RISC1.1-thread-multi/CORE -lperl -lnsl -lnm -lmallo +c -ldld -lm -lpthread -lc -lndir -lcrypt -lsec -I/usr/local/ include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/opt/perl/lib/5.6 +.1/PA-RISC1.1-thread-multi/CORE
seems to be working. Unfortunately, I seem to be at a loss as to how to proceed. Thanks! MatthewFrancis

In reply to Embedding Perl Interpreter/DynaLoader by MatthewFrancis

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.