Hmm - it now slowly dawns on me that adding -lperl should only happen when compiling extensions instead of being a compiler flag when compiling Perl itself. Surprisingly, the INSTALL document for Perl doesn't mention any appropriate linker flags that would apply only to after perl.o has been built.

As I've successfully built Perl (5.21.11, soon also 5.22.0-RC0) using cctools, my first suggestion would be to try the build using cctools instead of your compiler kit, just to see whether it is a problem with your build of Android or with the package or the environment. Slide 24 of this talk shows the command line I've used to compile Perl. Maybe that is already sufficient to make your compiler kit work with how Perl configures itself:

sh ./Configure -Dprefix=/storage/sdcard0/perl -des -Dusedevel -Dprefix=/data/local/perl-5.21.11/ -Dsysroot=/data/data/com.pdaxrom.cctools/root/cctools -Alibpth="/system/lib /vendor/lib" -Dman1dir=none -Dman3dir=none -Dsite1man=none -Dsite3man=none -Dvendorman1=none -Dvendorman3=none -DNO_LOCALE

Most likely, you will need to edit the -Dsysroot variable and likely you will want to set the prefix to something supported on your device.


In reply to Re^5: How To Link -lperl to Extensions During Build by Corion
in thread How To Link -lperl to Extensions During Build by cyd

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.