Slash Boxes
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

jonasbn (1153)

  reversethis-{gro.napc} {ta} {nbsanoj}
AOL IM: BJonasN (Add Buddy, Send Message)

Perl Programmer located in Copenhagen, Denmark. Active member of Copenhagen Perl Mongers.

Author of:

  • Business::DK::CPR
  • Business::DK::CVR
  • Business::DK::PO
  • Business::OnlinePayment::CashCow
  • Date::Holidays
  • Date::Holidays::Abstract
  • Date::Holidays::Super
  • Date::Pregnancy
  • Games::Bingo
  • Games::Bingo::Bot
  • Games::Bingo::Print
  • Module::Info::File
  • Module::Template::Setup
  • Test::Timer

and maintainer of:

  • Tie::Tools
  • XML::Conf
  • Workflow

Journal of jonasbn (1153)

Wednesday February 01, 2006
10:07 AM

PAR vs. Inline

[ #28543 ]

Me and Johan debugged and fixed a problem with PAR and Inline some time ago, then we both forgot about it - but all of a sudden the problem appeared again and Johan fixed it.

So this time I promised to send a bug report and a patch. This have been on my TODO list eversince the first round, but then I kind of forgot what the problem was and then it got harder to get the todo out of the way.

But luckily the problem reappeared and this time I can report it and I will do it while it is still fresh in my mind.

So the problem is getting PAR and Inline to work together. PAR moves some stuff around and when Inline wants to check the file is no longer there and things are not good.

So the problem is of course to find out whether this is a PAR or an Inline problem, one could argue PAR, but the workaround we have made is in Inline since this was the easiest.

So the workaround is checking for the environment variable PAR_INITIALIZED is set and if not letting Inline do what it has always done.

diff -b -B -w -u -r1.1
---   1 Feb 2006 11:12:52 -0000       1.1
+++   1 Feb 2006 15:03:02 -0000
@@ -453,10 +453,12 @@
     $o->{API}{modpname} = File::Spec->catdir(@modparts);
     my $suffix = $Config{dlext};
+    unless ($ENV{PAR_INITIALIZED}) {
     my $obj = File::Spec->catfile($realpath,'auto',$o->{API}{modpname},
     croak M30_error_no_obj($o->{CONFIG}{NAME}, $o->{API}{pkg},
                           $realpath) unless -f $obj;
+    }
     @{$o->{CONFIG}}{qw( PRINT_INFO

The workaround is somewhat weak, being based in the presence of an environment variable, but it works - I will let the Inline author decide on whether this really is a PAR problem.

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
More | Login | Reply
Loading... please wait.