core/pacman/PKGBUILD

78 lines
2.2 KiB
Bash
Raw Normal View History

2010-07-29 04:21:06 +08:00
#
# Chakra Packages for Chakra, part of chakra-project.org
#
# maintainer <manutortosa[at]chakra-project[dot]org>
2010-07-29 04:21:06 +08:00
2010-03-13 23:25:19 +08:00
pkgname=pacman
pkgver=4.1.2
pkgrel=4
2010-03-13 23:25:19 +08:00
pkgdesc="A library-based package manager with dependency support"
2012-12-08 06:24:31 +08:00
arch=('x86_64')
2010-03-13 23:25:19 +08:00
url="http://www.archlinux.org/pacman/"
license=('GPL')
2013-04-12 01:20:48 +08:00
groups=('base' 'base-devel')
depends=('bash>=4.2.042-1' 'glibc>=2.15-2' 'libarchive=3.1.2' 'curl>=7.28.1'
2013-04-12 01:31:16 +08:00
'gpgme' 'pacman-mirrorlist' )
2013-04-12 01:20:48 +08:00
checkdepends=('python2' 'fakechroot')
makedepends=('asciidoc' 'nettle')
optdepends=('fakeroot: for makepkg usage as normal user')
2013-04-12 01:20:48 +08:00
provides=('pacman-contrib')
conflicts=('pacman-contrib')
replaces=('pacman-contrib')
2010-03-13 23:25:19 +08:00
backup=(etc/pacman.conf etc/makepkg.conf)
install=pacman.install
options=(!libtool)
2013-04-12 01:20:48 +08:00
source=(ftp://ftp.archlinux.org/other/pacman/$pkgname-$pkgver.tar.gz{,.sig}
2013-04-13 01:58:27 +08:00
pacman.conf
2013-04-12 01:20:48 +08:00
makepkg.conf)
sha1sums=('ed9a40a9b532bc43e48680826d57518134132538'
'SKIP'
'0390fd27a62aadf0f7b5933632e858c442f2e167'
'3786881c265dbd90e47b793aa00b7cf9c8b01bc2')
2010-04-04 22:20:41 +08:00
2010-03-13 23:25:19 +08:00
build() {
cd $srcdir/$pkgname-$pkgver
./configure --prefix=/usr --sysconfdir=/etc \
2013-04-12 01:20:48 +08:00
--localstatedir=/var --enable-doc \
2013-04-13 02:29:51 +08:00
--with-scriptlet-shell=/bin/bash \
2013-04-12 01:20:48 +08:00
--with-ldconfig=/usr/bin/ldconfig
2011-02-07 00:25:02 +08:00
make
2013-04-12 01:20:48 +08:00
make -C contrib
2010-03-13 23:25:19 +08:00
}
check() {
make -C "$pkgname-$pkgver" check
}
2010-03-13 23:25:19 +08:00
package() {
cd $srcdir/$pkgname-$pkgver
2011-02-07 00:25:02 +08:00
make DESTDIR=$pkgdir install
2013-04-12 01:20:48 +08:00
make DESTDIR=$pkgdir -C contrib install
2010-03-13 23:25:19 +08:00
2013-04-12 01:20:48 +08:00
# install Arch specific stuff
install -dm755 $pkgdir/etc
2013-04-13 01:58:27 +08:00
install -m644 $srcdir/pacman.conf $pkgdir/etc/pacman.conf
2013-04-12 01:20:48 +08:00
2012-12-08 06:24:31 +08:00
mycarch="x86_64"
mychost="x86_64-unknown-linux-gnu"
2013-04-12 01:20:48 +08:00
myflags="-march=x86-64"
2012-12-08 06:24:31 +08:00
2011-02-07 00:25:02 +08:00
install -m644 $srcdir/makepkg.conf $pkgdir/etc/
# set things correctly in the default conf file
2010-03-13 23:25:19 +08:00
sed -i $pkgdir/etc/makepkg.conf \
-e "s|@CARCH[@]|$mycarch|g" \
-e "s|@CHOST[@]|$mychost|g" \
-e "s|@CARCHFLAGS[@]|$myflags|g"
2013-04-12 01:20:48 +08:00
# put bash_completion in the right location
install -dm755 ${pkgdir}/usr/share/bash-completion/completions
mv ${pkgdir}/etc/bash_completion.d/pacman \
${pkgdir}/usr/share/bash-completion/completions
rmdir ${pkgdir}/etc/bash_completion.d
2010-03-13 23:25:19 +08:00
2012-09-10 04:35:31 +08:00
for f in makepkg pacman-key; do
ln -s pacman "$pkgdir/usr/share/bash-completion/completions/$f"
done
2010-03-13 23:25:19 +08:00
}