Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

comment on

( #3333=superdoc: print w/replies, xml ) Need Help??

I recently wanted to make/test some changes to a module that contained an .xs component. As in the past when i wanted to test a change to a module i download the .tar.gx, (lets call it a.tar.gz) expanded it (tar -xvf a.tar.gz), changed to its directory (cd a/), make backups for diff (mv a.pm a.pm.bak ; mv a.xs a.xs.bak), and ran the makefile (perl Makefile.PL). All is well.

so i made my changes to a.xs, ran make, and ran make test, and all seemed well.

When i did this before with only a perl component i would then test my EXISTING application under the new code via perl -Iblib/lib ~/cvs/repository/app.pl but this did not seem to get my changes. I added a printf to the .xs code, ran make, and tested again. Nope sure didnt get the new .so file. Added an error to the .xs file and the make failed, removed the error and the make passed.

after a little more digging if found i needed to add blib/arch as an inc directory. Now on my ubuntu 14.04 box /usr/local/lib/perl/5.18.2/ has a.pm, and /usr/local/lib/perl/5.18.2/auto/a has a.so which is how I expected make to build my test directory. infact blib/lib/ has an auto and it has an a directory, directory, but all that i found in it was .exists. But instead i find (via playing with make test) the a.so file ends up under blib/arch/auto/a/a.so.

now that i know, i can test with perl -Iblib/lib -Iblib/arch ~/cvs/repository/app.pl, but like i said, it was unexpected. Is this because it was a ExtUtils::MakeMaker Makefile.PL? Or is it just common?

But what i learned most for this excursion was that if you like sausage, never visit a sausage factory.


In reply to Testing a metacpan dist with XS components by huck

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, 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, 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.
  • Log In?
    Username:
    Password:

    What's my password?
    Create A New User
    Chatterbox?
    and the web crawler heard nothing...

    How do I use this? | Other CB clients
    Other Users?
    Others chilling in the Monastery: (9)
    As of 2021-04-23 12:35 GMT
    Sections?
    Information?
    Find Nodes?
    Leftovers?
      Voting Booth?

      No recent polls found

      Notices?