[pacman-dev] makepkg patch - simple pkg class feature

K. Piche kpiche at rogers.com
Wed Jan 9 23:10:18 EST 2008


On Tue, 2008-01-08 at 17:44 -0600, Dan McGee wrote:
> On Jan 8, 2008 5:28 PM, Roman Kyrylych <roman.kyrylych at gmail.com> wrote:
> > 2007/12/27, K. Piche <kpiche at rogers.com>:
> >
> > > Hi,
> > >
> > > I hope everyone had a great holiday!
> > >
> > > Perl module PKGBUILDs tend to be a mess and some build() functions are
> > > not "standard".  Now with the new upcoming perl policy all of the
> > > PKGBUILDs need to be "standardized" again.  To help combat this problem
> > > I hacked up a package class feature where all the functions and package
> > > defaults are set in a class file and sourced before the package is
> > > built.  The class file can define a set of build functions to call
> > > instead of just build().
> > >
> > > Some advantages:
> > > - standardization of package types, even AUR packages could be uniform
> > > - code in makepkg could be moved to a class so that it could easily be
> > > override by people doing non-standard things: no man pages, i585 ports
> > > - anything set in the PKGBUILD takes precedence over the class
> > > - defined build functions can be optional (see the sample perl class)
> > >
> > > The patch is backwards compatible with non-class PKGBUILDs and I have
> > > been using my classy makepkg for 5 days.
> > >
> > > Attached is the patch, a perl class, and sample PKGBUILD for
> > > Sys::Syslog.  Right now the class file has to be in the same directory
> > > as the PKGBUILD.
> > >
> > > Happy New Year!
> > >
> >
> > Dan, Aaron, is this in your working trees somewhere?
> > Otherwise it would be better to create a feature request on Flyspray
> > so it won't get lost.
> 
> Sorry that I haven't responded. At first glance, I like this idea. I
> want to queue it up for 3.2 after some discussion and looking at it if
> no one else objects. I've just been a bit busy worrying about release
> fixes so I haven't had time to review this.

That's why I didn't ask...  :)

> -Dan
> 
> _______________________________________________
> pacman-dev mailing list
> pacman-dev at archlinux.org
> http://archlinux.org/mailman/listinfo/pacman-dev
-- 
K. Piche <kpiche at rogers.com>





More information about the pacman-dev mailing list