CPAN.pm still has an open issue with Module::Build with regard to
finding out the prerequisites of a distribution. I append the email
below where I asked the encompassing question: can I rely on the
contents of _build/prereqs?

Since then I have changed CPAN.pm in 1.88_63 to actually read
_build/prereqs. All CPAN seems to be conquered with this trick. All of
CPAN? Actually, one developer complained about it: Sendu Bala (CC'd)
who released SENDU/bioperl-1.5.2_100.tar.gz in December. He used some
heavy Module::Build subclassing wizardry, I did not try to understand
it.

I'd like to have this resolved before I release 1.89. Would it be
possible to make an interface decision for the prereqs?

Thanks,
-- 
andreas

>>>>> On Sun, 22 Oct 2006 14:16:39 +0200, [EMAIL PROTECTED] (Andreas J. Koenig) 
>>>>> said:

>>>>> On Tue, 3 Oct 2006 16:56:08 -0500, Ken Williams <[EMAIL PROTECTED]> said:
 >> On Oct 2, 2006, at 2:50 PM, Andreas J. Koenig wrote:

 >>> You're right, that was a surprisingly well working hack. Makefile.PL
 >>> wrote a *comment* into the Makefile that could be parsed out again.

 >> M::B does something similar, it writes a file called _build/prereqs
 >> that lists all the prereqs computed at runtime by the Build.PL script.

  > AHHHH, I didn't see the importance of this sentence when I first read
  > it. Now I was going through this thread again and it stands out so nicely.

  > Is this part of the API? I do not find it in Module::Build::API.

  > Can I take it for granted that _build/prereqs is available after
  > Build.PL has run and can I just eval its contents and get a hashref of
  > the prerequisites? Are subclassing developers instructed to not write
  > anything else into this file?

  > It seems to me this would solve my current problems wrt prereqs.

  > For the record, the problem I currently have is that the original
  > suggestion to use

  >                     $req  = Module::Build->current->requires();
  >                     $breq = Module::Build->current->build_requires();

  > can fail when the author has written a subclass of Module::Build. This
  > happened with Error.pm and HTML::Mason. CPAN 1.88_56 works around the
  > problem by falling back to the contents of META.yml. If I get
  > _build/prereqs for granted, we can doubtlessly do better.

  > Thanks,
  > -- 
  > andreas

Reply via email to