2009-11-16 19:07:36 +00:00
|
|
|
# Maintainer: Andreas Radke <andyrtr@archlinux.org>
|
|
|
|
# Contributor: judd <jvinet@zeroflux.org>
|
2009-10-08 03:40:19 +00:00
|
|
|
|
|
|
|
pkgname=readline
|
2009-11-16 19:07:36 +00:00
|
|
|
_patchlevel=004 #prepare for some patches
|
|
|
|
pkgver=6.0.$_patchlevel
|
|
|
|
pkgrel=1
|
2009-10-08 03:40:19 +00:00
|
|
|
pkgdesc="GNU readline library"
|
2009-11-16 19:07:36 +00:00
|
|
|
arch=('arm')
|
2009-10-08 03:40:19 +00:00
|
|
|
url="http://tiswww.case.edu/php/chet/readline/rltop.html"
|
|
|
|
license=('GPL')
|
|
|
|
groups=('base')
|
|
|
|
depends=('glibc' 'ncurses')
|
|
|
|
backup=("etc/inputrc")
|
2009-11-16 19:07:36 +00:00
|
|
|
source=(http://ftp.gnu.org/gnu/readline/readline-6.0.tar.gz
|
|
|
|
inputrc)
|
|
|
|
if [ $_patchlevel -gt 00 ]; then
|
|
|
|
for p in $(seq -w 01 $_patchlevel); do
|
|
|
|
source=(${source[@]} http://ftp.gnu.org/gnu/readline/readline-6.0-patches/readline60-$p)
|
|
|
|
done
|
|
|
|
fi
|
2009-10-08 03:40:19 +00:00
|
|
|
md5sums=('b7f65a48add447693be6e86f04a63019'
|
2009-11-16 19:07:36 +00:00
|
|
|
'e5fc955f56d9fa5beb871f3279b8fa8b'
|
|
|
|
'85c01ea031ad38a179053c67186bafed'
|
|
|
|
'4fad2a4ce987e3101229d0c8dfb0cd80'
|
|
|
|
'80967f663864983a889af2eb53aea177'
|
|
|
|
'dd5dd5ff7f7229714bf1c2e274ad2ae9')
|
2009-10-08 03:40:19 +00:00
|
|
|
|
|
|
|
build() {
|
2009-11-16 19:07:36 +00:00
|
|
|
cd ${srcdir}/${pkgname}-6.0
|
|
|
|
for p in ../readline60-*; do
|
|
|
|
[ -e "$p" ] || continue
|
|
|
|
msg "applying patch ${p}"
|
|
|
|
patch -Np0 -i ${p} || return 1
|
|
|
|
done
|
|
|
|
|
|
|
|
# Remove RPATH from shared objects (FS#14366)
|
|
|
|
sed -i 's|-Wl,-rpath,$(libdir) ||g' support/shobj-conf
|
|
|
|
|
|
|
|
# build with -fPIC for x86_64 (FS#15634)
|
|
|
|
[ $CARCH == "x86_64" ] && CFLAGS="$CFLAGS -fPIC"
|
|
|
|
|
|
|
|
./configure --prefix=/usr --libdir=/lib \
|
|
|
|
--mandir=/usr/share/man --infodir=/usr/share/info
|
2009-10-08 03:40:19 +00:00
|
|
|
make SHLIB_LIBS=-lncurses || return 1
|
2009-11-16 19:07:36 +00:00
|
|
|
make DESTDIR=${pkgdir} install || return 1
|
2009-10-08 03:40:19 +00:00
|
|
|
|
2009-11-16 19:07:36 +00:00
|
|
|
mkdir -p ${pkgdir}/etc
|
|
|
|
install -m644 ../inputrc ${pkgdir}/etc/inputrc || return 1
|
|
|
|
#FHS recommends only shared libs in /lib
|
|
|
|
mkdir -p $pkgdir/usr/lib
|
|
|
|
mv $pkgdir/lib/*.a $pkgdir/usr/lib
|
2009-10-08 03:40:19 +00:00
|
|
|
|
2009-11-16 19:07:36 +00:00
|
|
|
# to make the linker find the shared lib and fix compile issues
|
|
|
|
cd ${pkgdir}/usr/lib
|
|
|
|
ln -sv /lib/libreadline.so .
|
|
|
|
ln -sv /lib/libhistory.so .
|
2009-10-08 03:40:19 +00:00
|
|
|
|
2009-11-16 19:07:36 +00:00
|
|
|
rm -f ${pkgdir}/usr/share/info/dir
|
|
|
|
}
|