Skip Menu |

This queue is for tickets about the Module-Build CPAN distribution.

Report information
The Basics
Id: 48834
Status: open
Priority: 0/
Queue: Module-Build

People
Owner: Nobody in particular
Requestors: dolmen [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Wishlist
Broken in: (no value)
Fixed in: (no value)



Subject: M::B::Compat : add AUTHOR generation from dist_author
The AUTHOR argument of EU::MM->WriteMakefile() could be generated from M::B dist_author. AUTHOR is a ExtUtils::MakeMaker argument supported since EUMM 6.06_03 (according to Changes, 2003-03-29). This would improve PPD and META.yml generation from a Makefile.PL created by Module::Build::Compat. ABSTRACT_FROM and META_MERGE could also be generated from M::B info.
Subject: Re: [rt.cpan.org #48834] M::B::Compat : add AUTHOR generation from dist_author
Date: Wed, 19 Aug 2009 12:05:07 -0700
To: bug-Module-Build [...] rt.cpan.org
From: Michael G Schwern <schwern [...] pobox.com>
Olivier 'dolmen' Mengué via RT wrote: Show quoted text
> The AUTHOR argument of EU::MM->WriteMakefile() could be generated from > M::B dist_author. > > AUTHOR is a ExtUtils::MakeMaker argument supported since EUMM 6.06_03 > (according to Changes, 2003-03-29). > > This would improve PPD and META.yml generation from a Makefile.PL > created by Module::Build::Compat. > > ABSTRACT_FROM and META_MERGE could also be generated from M::B info.
While its entirely possible to extend the Makefile.PL emulation, it is outside its scope (smoothing the transition from MakeMaker to Module::Build for module installers) for it to support distribution building which is an author only task. At this point there's no reason why you'd be building a dist with an emulated Makefile.PL rather than using the Build.PL. It will get things wrong. That said, why are you generating from the Makefile? In fact, I'd be in favor of stubbing out all the dist target emulation to avoid subtle bugs and us having to support it. -- Life is like a sewer - what you get out of it depends on what you put into it. - Tom Lehrer
Le Mer. Aoû. 19 15:05:35 2009, schwern@pobox.com a écrit : Show quoted text
> While its entirely possible to extend the Makefile.PL emulation, it is > outside > its scope (smoothing the transition from MakeMaker to Module::Build > for module > installers) for it to support distribution building which is an author > only > task. At this point there's no reason why you'd be building a dist > with an > emulated Makefile.PL rather than using the Build.PL. It will get > things wrong.
Here is a reason: EU::MM PPD generation is better than M::B. It looks like EU::MM has been upgraded to generate for PPM4 while M::B::PPMMaker is still at PPM3. Another reason: from a developer and packager that has to deal packaging CPAN modules for non-standard or old Perl platforms (such as proprietary Unixes), dealing with 2 packaging tools, each in multiple versions constantly evolving, is painful. See those slides of a talk I did at the French Perl Workshop for some tricks I'm using. http://o.mengue.free.fr/presentations/2009-fpw/Utiliser-le-CPAN-en-environnement-hostile.pdf Show quoted text
> That said, why are you generating from the Makefile? > > In fact, I'd be in favor of stubbing out all the dist target emulation > to > avoid subtle bugs and us having to support it.
What do you suggest instead? Using some tools based on META.yml content? Pointers to CPAN dists are welcome.
Subject: Re: [rt.cpan.org #48834] M::B::Compat : add AUTHOR generation from dist_author
Date: Thu, 20 Aug 2009 11:49:43 -0700
To: bug-Module-Build [...] rt.cpan.org
From: Michael G Schwern <schwern [...] pobox.com>
Olivier 'dolmen' Mengué via RT wrote: Show quoted text
> Here is a reason: EU::MM PPD generation is better than M::B. It looks > like EU::MM has been upgraded to generate for PPM4 while M::B::PPMMaker > is still at PPM3.
Fix Module::Build's PPD support. It'll be a hell of a lot easier than maintaining emulation and you are unlikely to see another upgrade to the PPM support in MakeMaker. Show quoted text
> Another reason: from a developer and packager that has to deal packaging > CPAN modules for non-standard or old Perl platforms (such as proprietary > Unixes), dealing with 2 packaging tools, each in multiple versions > constantly evolving, is painful.
A) Packagers don't need to make CPAN distributions, they build, test and install existing ones. In fact, making CPAN distributions is the opposite of what they do. B) As the person running the packaging tool you can select what version of the software to run. For the least pain use the latest. B1) MakeMaker's improved PPD support is relatively recent so you've already shown your willingness to manage versions of MB and MakeMaker. C) Using Makefile.PL emulation throws a THIRD packaging tool into the mix, Module::Build::Compat. Like all emulators it will never work quite right and we'll spend time chasing down bugs like this one. And then something in MakeMaker will change and it will fall out of sync. Emulation sucks. Show quoted text
> See those slides of a talk I did at the French Perl Workshop for some > tricks I'm using. > http://o.mengue.free.fr/presentations/2009-fpw/Utiliser-le-CPAN-en-environnement-hostile.pdf
Sorry, I can't follow the French. From what I could follow from the code, the makepl_arg suggestion is a bit much. Instead, configure the CPAN shell to use INSTALL_BASE and install a new MakeMaker immediately. Then you're done. Also the INSTALLHTML stuff was never released (ActiveState does their own thing which I have no control over). 5.8.9 and 5.10.0 come with a recent enough MakeMaker that this is not an issue. Show quoted text
>> That said, why are you generating from the Makefile? >> >> In fact, I'd be in favor of stubbing out all the dist target emulation >> to >> avoid subtle bugs and us having to support it.
> > What do you suggest instead? > Using some tools based on META.yml content? > Pointers to CPAN dists are welcome.
The dist targets for MakeMaker and Module::Build are so similar the code to deal with both of them is trivial. if( -e "Build.PL" ) { $config = "Build.PL"; $cmd = "Build"; } else { $config = "Makefile.PL"; $cmd = "make"; } system("perl $config"); system("$cmd disttest"); system("$cmd dist"); On the whole, I would rather spend effort making MakeMaker emulate Module::Build than the reverse. -- THIS I COMMAND!
Le Jeu. Aoû. 20 14:50:13 2009, schwern@pobox.com a écrit : Show quoted text
> B) As the person running the packaging tool you can select what > version of the > software to run. For the least pain use the latest.
Upgrading EU::MM and installing M::B on HP-UX is painful. Show quoted text
> B1) MakeMaker's improved PPD support is relatively recent so you've > already > shown your willingness to manage versions of MB and MakeMaker.
I have since discovered PPM::Make which seems to be the right way to create PPM packages. It extracts its information from META.yml. Show quoted text
> C) Using Makefile.PL emulation throws a THIRD packaging tool into the > mix, > Module::Build::Compat. Like all emulators it will never work quite > right and > we'll spend time chasing down bugs like this one. And then something > in > MakeMaker will change and it will fall out of sync. Emulation sucks. > >
> > See those slides of a talk I did at the French Perl Workshop for
> some > environnement-hostile.pdf > > Sorry, I can't follow the French. > > From what I could follow from the code, the makepl_arg suggestion is a > bit > much.
I had to do this to upgrade EU::MM up to a version that supports INSTALL_BASE. Show quoted text
> Instead, configure the CPAN shell to use INSTALL_BASE and > install a new > MakeMaker immediately. Then you're done. Also the INSTALLHTML stuff > was > never released (ActiveState does their own thing which I have no > control over).
I had a module that used it. Don't remember which. Show quoted text
> 5.8.9 and 5.10.0 come with a recent enough MakeMaker that this is not > an issue.
The HP-UX machines I'm using have 5.8.6 or 5.8.8. Show quoted text
> >> That said, why are you generating from the Makefile? > >> > >> In fact, I'd be in favor of stubbing out all the dist target
> emulation
> >> to > >> avoid subtle bugs and us having to support it.
> > > > What do you suggest instead? > > Using some tools based on META.yml content? > > Pointers to CPAN dists are welcome.
> > The dist targets for MakeMaker and Module::Build are so similar the > code to > deal with both of them is trivial.
... when your universe is Unix. Show quoted text
> if( -e "Build.PL" ) { > $config = "Build.PL"; > $cmd = "Build"; > } > else { > $config = "Makefile.PL"; > $cmd = "make"; > } > > system("perl $config"); > system("$cmd disttest"); > system("$cmd dist");
This does not work on Windows: No 'make' on ActivePerl, and SrawberryPerl's make is 'dmake'. Then you have to deal with argument escaping and so on. CPAN::Shell->install() seems the right way, once you have configured CPAN.pm manually. And it will break at the next upgrade (options added...). Show quoted text
> On the whole, I would rather spend effort making MakeMaker emulate > Module::Build than the reverse.
It would be better. But too many distributions (and usually the most critical ones) have custom make targets. Also Module::Install (which uses EU::MM and even patches the generated Makefile) got some traction, so it increases the problem.
Le Jeu. Aoû. 20 14:50:13 2009, schwern@pobox.com a écrit : Show quoted text
> Fix Module::Build's PPD support. It'll be a hell of a lot easier than > maintaining emulation and you are unlikely to see another upgrade to > the PPM support in MakeMaker.
My plan is to fix META.yml generation issues in EU::MM, then PPM::Make issues and then replace built-in PPD generation in M::B and EU::MM by PPM::Make usage (or at least a stub saying: "Deprecated. Use 'make_ppm'"). But now is vacation time (2 weeks).
Subject: Re: [rt.cpan.org #48834] M::B::Compat : add AUTHOR generation from dist_author
Date: Sun, 30 Aug 2009 12:21:51 -0700
To: bug-Module-Build [...] rt.cpan.org
From: Michael G Schwern <schwern [...] pobox.com>
Olivier 'dolmen' Mengué via RT wrote: Show quoted text
> Queue: Module-Build > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=48834 > > > Le Jeu. Aoû. 20 14:50:13 2009, schwern@pobox.com a écrit :
>> Fix Module::Build's PPD support. It'll be a hell of a lot easier than >> maintaining emulation and you are unlikely to see another upgrade to >> the PPM support in MakeMaker.
> > My plan is to fix META.yml generation issues in EU::MM, then PPM::Make > issues and then replace built-in PPD generation in M::B and EU::MM by > PPM::Make usage (or at least a stub saying: "Deprecated. Use 'make_ppm'"). > > But now is vacation time (2 weeks).
Next time PPM generation needs upgrading I think I'll just have MakeMaker use PPM::Make. -- "I went to college, which is a lot like being in the Army, except when stupid people yell at me for stupid things, I can hit them." -- Jonathan Schwarz
Subject: Re: [rt.cpan.org #48834] M::B::Compat : add AUTHOR generation from dist_author
Date: Sun, 30 Aug 2009 12:35:49 -0700
To: bug-Module-Build [...] rt.cpan.org
From: Michael G Schwern <schwern [...] pobox.com>
This has gotten a bit off topic and has drifted into general module installation issues. Let's yank it back. The question was if its worth the effort to have MB::Compat support building distributions. Do you have more to add to that or will fixing PPM support be enough? Olivier 'dolmen' Mengué via RT wrote: Show quoted text
> Queue: Module-Build > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=48834 > > > Le Jeu. Aoû. 20 14:50:13 2009, schwern@pobox.com a écrit :
>> B) As the person running the packaging tool you can select what >> version of the >> software to run. For the least pain use the latest.
> > Upgrading EU::MM and installing M::B on HP-UX is painful.
If so please report why its painful to the MakeMaker bug queue and we'll get it fixed. Show quoted text
>> From what I could follow from the code, the makepl_arg suggestion is a >> bit >> much.
> > I had to do this to upgrade EU::MM up to a version that supports > INSTALL_BASE.
This should not be necessary, MakeMaker will install itself with the new version you are installing. If it didn't please report it as a bug. Show quoted text
>>>> That said, why are you generating from the Makefile? >>>> >>>> In fact, I'd be in favor of stubbing out all the dist target
>> emulation
>>>> to >>>> avoid subtle bugs and us having to support it.
>>> What do you suggest instead? >>> Using some tools based on META.yml content? >>> Pointers to CPAN dists are welcome.
>> The dist targets for MakeMaker and Module::Build are so similar the >> code to >> deal with both of them is trivial.
> > ... when your universe is Unix. >
>> if( -e "Build.PL" ) { >> $config = "Build.PL"; >> $cmd = "Build"; >> } >> else { >> $config = "Makefile.PL"; >> $cmd = "make"; >> } >> >> system("perl $config"); >> system("$cmd disttest"); >> system("$cmd dist");
> > This does not work on Windows: No 'make' on ActivePerl, and > SrawberryPerl's make is 'dmake'.
Given that this report is about using MakeMaker over Module::Build to build distributions I'd count that as an argument against. Show quoted text
>> On the whole, I would rather spend effort making MakeMaker emulate >> Module::Build than the reverse.
> > It would be better. But too many distributions (and usually the most > critical ones) have custom make targets. Also Module::Install (which > uses EU::MM and even patches the generated Makefile) got some traction, > so it increases the problem.
This is off the topic of using MB::Compat to generate distributions. But to answer, if the custom make targets do not change the interface for installing a module then they're irrelevant. If they do you have a non-standard installation process and they will have to be dealt with individually no matter what they're written in. Module::Install uses a superset of the MakeMaker interface so it doesn't make a difference to the install process. -- 29. The Irish MPs are not after "Me frosted lucky charms". -- The 213 Things Skippy Is No Longer Allowed To Do In The U.S. Army http://skippyslist.com/list/
Le Dim. Aoû. 30 12:22:19 2009, schwern@pobox.com a écrit : Show quoted text
> > Next time PPM generation needs upgrading I think I'll just have > MakeMaker use > PPM::Make.
Well, suggesting PPM::Make was not a good idea as it has it's own issues. See RT#36798 https://rt.cpan.org/Ticket/Display.html?id=36798
Subject: Re: [rt.cpan.org #48834] M::B::Compat : add AUTHOR generation from dist_author
Date: Thu, 10 Sep 2009 16:38:58 -0700
To: bug-Module-Build [...] rt.cpan.org
From: Michael G Schwern <schwern [...] pobox.com>
Olivier 'dolmen' Mengué via RT wrote: Show quoted text
> Queue: Module-Build > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=48834 > > > Le Dim. Aoû. 30 12:22:19 2009, schwern@pobox.com a écrit :
>> Next time PPM generation needs upgrading I think I'll just have >> MakeMaker use >> PPM::Make.
> > Well, suggesting PPM::Make was not a good idea as it has it's own > issues. See RT#36798 > https://rt.cpan.org/Ticket/Display.html?id=36798
What?! Software has bugs?! Gadzooks and zounds! Its better they get fixed in one place than in N half-assed reimplementations. I'm having deja vu. -- I'm pale as Formica, social skills stunted small. But I'm accurate like a pica, I know the capital of Nepal. I'm the nemesis of error, dreadful diction fears my skills, more inquisitive than Jim Lehrer, snottier than Beverly Hills. -- I.L.O.P. Secret Rap http://goats.com/archive/020830.html
Le Jeu. Sep. 10 19:39:19 2009, schwern@pobox.com a écrit : Show quoted text
> > Well, suggesting PPM::Make was not a good idea as it has it's own > > issues. See RT#36798 > > https://rt.cpan.org/Ticket/Display.html?id=36798
> > What?! Software has bugs?! Gadzooks and zounds! > > Its better they get fixed in one place than in N half-assed > reimplementations. > > I'm having deja vu.
I agree. However the problem is that PPM::Make was designed from an other point of view: to create binary distribution from CPAN distributions. And so it connects to CPAN servers to retrieve index data about the distribution being built or its dependencies. On the other side, Module::Build is also useful to build distributions outside CPAN. So I'll fix PPD generation (See https://rt.cpan.org/Ticket/Display.html?id=49600 ).