perl Makefile.pl INC=-Ic:\libxml2\include LIBS=-Lc:\libxml2\lib

Get rid of the insane Makefile.PL that comes with the distro, and replace it with:
use ExtUtils::MakeMaker; WriteMakefile( NAME => 'XML::LibXML::Common', VERSION_FROM => 'Common.pm', # finds $VERSION AUTHOR => 'Christian Glahn <christian.glahn@uibk.ac.at>', ABSTRACT => 'Routines and Constants common for XML::LibXML an +d XML::GDOME', LIBS => '-lxml2', );
Then run perl Makefile.pl INC="-Ic:/libxml2/include" LIBS="-Lc:/libxml2/lib -lxml2"
Because there's now a space in the LIBS arg, you need to enclose that arg in double quotes. You don't really need double quotes around the INC arg (as it contains no spaces), but I always put them in anyway. Not sure if the backslashes need to be escaped or not - so I just use forward slashes as the path separator to avoid the worry.

That should now work if you're building against a dynamic library (dll). The dll does, of course, need to be in your path. (I'm finding that the module won't build against a static lib as it expects to find a dll ... and I haven't yet worked out why it has that expectation.)

Cheers,
Rob

In reply to Re: Error compiling XML::LibXML::Common by syphilis
in thread Error compiling XML::LibXML::Common by ScooterTrash

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.