Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re: Problems installing Devel::Cover on Strawberry, seems to work on Cygwin

by adamk (Chaplain)
on Mar 28, 2008 at 08:18 UTC ( #676927=note: print w/ replies, xml ) Need Help??


in reply to Problems installing Devel::Cover on Strawberry, seems to work on Cygwin

And if someone can give ME a clue before the end of the weekend, I'll see what I can do about enabling those flags in the new April Strawberry by default.


Comment on Re: Problems installing Devel::Cover on Strawberry, seems to work on Cygwin
Re^2: Problems installing Devel::Cover on Strawberry, seems to work on Cygwin
by jplindstrom (Monsignor) on Mar 28, 2008 at 14:26 UTC
    Well, adding the -Wl,--export-all-symbols option to ld sounds very promising I think, considering that it does work on Cygwin, and that that's one of the config diffs betwen Cygwin and Strawberry.

    I don't know how easy it would be to test that with Perl::Dist (which is the builder of Strawberry, no?), but presumably not very.

    /J

Re^2: Problems installing Devel::Cover on Strawberry, seems to work on Cygwin
by jplindstrom (Monsignor) on Mar 29, 2008 at 03:35 UTC
    I just built a Perl 5.10 with the link flags added to makefile.mk, but that didn't solve the problem with Devel::Cover.

    What did work was to add the following symbols to global.sym (two more than mentioned above):

    Perl_pp_nextstate Perl_pp_nextstate Perl_pp_setstate Perl_pp_setstate Perl_pp_dbstate Perl_pp_dbstate Perl_pp_entersub Perl_pp_entersub Perl_pp_cond_expr Perl_pp_and Perl_pp_andassign Perl_pp_or Perl_pp_orassign Perl_pp_xor Perl_pp_require Perl_pp_exec Perl_pp_dor Perl_pp_dorassign

    This may be wrong way to do this since the comment at the top of global.sym says it's auto generated by "make regen_headers". However there doesn't seem to be a make target for that, so I don't know. It's a workaround for this particular module anyway.

    Now, whether this is a good idea or not, I can't tell you. I have no clue about those issues.

    I do know, however, that I would very, very much like Devel::Cover to build on Windows.

    /J

      What did work was to add the following symbols to global.sym ....

      Seems that's one way to make those symbols public. Nice hack - though if you ever need to access a different private symbol, you'll have to rebuild perl again.

      I'm curious to know whether the Devel::Cover that you built with this hacked perl-5.10.0 will work on an unhacked perl-5.10.0. (Others would probably know the answer to that without needing to test it.) Have you tried that out ? If it works on the unhacked version of perl, then it could be handy for others if the binary of your build of Devel::Cover (either ppm package or just a tar.gz of blib) was made available.

      Cheers,
      Rob
        That did not work. Devel::Cover unsurprisingly needs access to the symbols during both build and run time. Tried it with a 5.8.8 because that's my existing installation with lots of modules I don't care to reinstall.

        Instead I patched the current installation by building a Perl 5.8.8 with the exported symbols, and then:

        cp perl58.dll \strawberry-perl\perl\bin\ cp lib\CORE\libperl58.a \strawberry-perl\perl\lib\CORE\

        This is clearly a hack, not a long-term solution.

        What that solution is I don't know. But I imagine either

        • officially promote those symbols to be public, since such an important module as Devel::Cover rely on them, or;
        • create an interface to allow Devel::Cover to instrument/inspect the internals the way it clearly needs to do to work its magic.

        Damn, that was a lot of yak shaving to start doing interesting things!

        /J

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://676927]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (18)
As of 2014-07-25 16:45 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (174 votes), past polls