vp-build/templates/readline/template
Juan RP 84222395b8 Provide some vars for use in template's targets.
These new vars are DESTDIR (by default XBPS_DESTDIR/pkgname-version),
SRCPKGDESTDIR (XBPS_DESTDIR/sourcepkg-version) and FILESDIR
(XBPS_TEMPLATESDIR/pkgname/files).

This simplifies packages that used them.

--HG--
extra : convert_revision : 287ea7128cb5df19870ca7aff0a3b8f99a11d63a
2009-03-11 06:31:56 +01:00

45 lines
1.5 KiB
Plaintext

pkgname=readline
readline_distver=5.2
readline_patchver=013
version=${readline_distver}.${readline_patchver}
distfiles=ftp://ftp.cwru.edu/pub/bash/$pkgname-$readline_distver.tar.gz
build_style=gnu_configure
make_build_args="SHLIB_LIBS=-lncurses"
short_desc="The GNU Readline Library"
maintainer="Juan RP <xtraeme@gmail.com>"
checksum=12e88d96aee2cd1192500356f0535540db499282ca7f76339fb4228c31249f45
long_desc="
The GNU Readline library provides a set of functions for use by
applications that allow users to edit command lines as they are
typed in. Both Emacs and vi editing modes are available. The
Readline library includes additional functions to maintain a list
of previously-entered command lines, to recall and perhaps reedit
those lines, and perform csh-like history expansion on previous
commands."
build_depends="ncurses-5.6"
run_depends="glibc-2.8 $build_depends"
pre_configure()
{
# Apply all patches for current version.
local URL="ftp://ftp.cwru.edu/pub/bash/$pkgname-$readline_distver-patches/"
local lver="readline52"
for p in $(seq -w 001 $readline_patchver); do
if [ ! -f "$XBPS_SRCDISTDIR/$lver-$p" ]; then
msg_normal "Fetching $pkgname-$version patch: $lver-$p."
cd $XBPS_SRCDISTDIR && $fetch_cmd $URL/$lver-$p || bye 1
fi
msg_normal "Applying patch: $lver-$p."
cd $wrksrc && patch -s -p0 < $XBPS_SRCDISTDIR/$lver-$p || bye 1
done
}
post_install()
{
# Move shared libs into /lib.
mkdir -p $DESTDIR/lib
mv $DESTDIR/usr/lib/lib*.so* $DESTDIR/lib
}