[pacman-dev] makepkg: package splitting
Miklos Vajna
vmiklos at frugalware.org
Wed Dec 10 09:59:06 EST 2008
On Mon, Dec 08, 2008 at 12:35:41PM +1000, Allan McRae <allan at archlinux.org> wrote:
> pkgname=('abs-core' 'abs-readme')
> pkgver=2.3
> pkgrel=1
> arch=('i686' 'x86_64')
> url="http://projects.archlinux.org/git/?p=abs.git"
> license=('GPL')
> source=(ftp://ftp.archlinux.org/other/abs/abs-${pkgver}.tar.gz)
> md5sums=('d6fd791aa487ba8bb5ff48c3ace20592')
>
> build() {
> cd ${srcdir}/abs
> make CONFDIR=/etc/ || return 1
>
> # change ABS tags for x86_64 to correct values
> if [ "$CARCH" = "x86_64" ]; then
> sed -i "s|i686|x86_64|g" ${pkgdir}/etc/abs.conf
> fi
> }
>
> package_abs-core() {
> pkgdesc="Utilities to download and work with the Arch Build System (ABS)"
> depends=('bash' 'rsync')
> backup=(etc/abs.conf)
>
> cd ${srcdir}/abs
> make CONFDIR=/etc/ DESTDIR=${pkgdir} install || return 1
> }
>
> package_abs-readme() {
> pkgdesc="ABS base directory and README file"
> depends=('abs')
> install=abs.install
>
> # Add readme file, and make base /var/abs path
> install -dm0755 ${pkgdir}/var/abs/local/
> install -Dm0644 ${srcdir}/abs/README ${pkgdir}/var/abs/README
> }
How does this allow one to define package-dependent dependencies?
Typically foo-python will have to depend on python, but foo won't.
Thanks.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://archlinux.org/pipermail/pacman-dev/attachments/20081210/b9ac56cb/attachment.pgp>
More information about the pacman-dev
mailing list