tl;dr: I think I need guidance on how to specify <LIBPATH> in

perl Makefile.PL --with-libidn=<LIBPATH> --with-libidn-inc=<INCPATH>

Additional details:

Building Net::LibIDN using

perl Makefile.PL --with-libidn=/usr/local/lib --with-libidn-inc=/usr/local/include

yields the following error

ld: library not found for -lidn clang: error: linker command failed with exit code 1 (use -v to see in +vocation) ld: library not found for -lidn clang: error: linker command failed with exit code 1 (use -v to see in +vocation) This module requires GNU Libidn, which could not be found.

However, I do have GNU Libidn2 installed as follows

/usr/local/lib/libidn2.0.dylib /usr/local/lib/libidn2.a /usr/local/lib/libidn2.dylib /usr/local/lib/libidn2.la /usr/local/include/idna.h -> /usr/local/include/idn2.h /usr/local/include/idn2.h

For context, I ran into the same problem as this StackOverflower except I'm on macOS 10.14 Mojave and was able to make my way past

__test1.c:1:10: fatal error: 'idna.h' file not found #include <idna.h> ^~~~~~~~

by creating the symlink

/usr/local/include/idna.h

which points to

/usr/local/include/idn2.h

Thank you in advance for any pointers.


In reply to Net::LibIDN and GNU Libidn by mistersquid

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.