39 lines
1.5 KiB
Plaintext
39 lines
1.5 KiB
Plaintext
/*
|
|
* readline — line editing and history for interactive programs (bash,
|
|
* and later anything with a REPL).
|
|
*
|
|
* Static-only: bash links it in, so no runtime lib resolution is needed
|
|
* in the store. --with-curses makes it link the terminal library; the
|
|
* store ncurses is found via the resolved include/lib paths, and its
|
|
* libtinfo.a (wide symlink) satisfies readline's -ltinfo.
|
|
*/
|
|
package "readline" {
|
|
const version = "8.3"
|
|
const source = "https://ftp.gnu.org/gnu/readline/readline-${version}.tar.gz"
|
|
sha256 = "fe5383204467828cd495ee8d1d3c037a7eba1389c22bc6a041f627976f9061cc"
|
|
license = "GPL-3.0-or-later"
|
|
|
|
provides = ["libreadline.a", "readline"]
|
|
|
|
depends = [
|
|
{ name = "ncurses" },
|
|
{ name = "make" },
|
|
]
|
|
|
|
prepare {
|
|
curl -L -o readline-${version}.tar.gz ${source}
|
|
echo "fe5383204467828cd495ee8d1d3c037a7eba1389c22bc6a041f627976f9061cc readline-${version}.tar.gz" | sha256sum -c -
|
|
tar xf readline-${version}.tar.gz --strip-components=1
|
|
ROOT=$KAPPA_ROOT; [ -z $ROOT ] && ROOT=/usr/local/kappa; if [ -d $ROOT/temp/ncurses/destdir/usr ]; then echo $ROOT/temp/ncurses/destdir/usr; else echo $ROOT/bin/$(grep '^ncurses ' $ROOT/db/installed | tail -1 | cut -d' ' -f3)/usr; fi > ncurses.path
|
|
}
|
|
|
|
build {
|
|
CPPFLAGS=-I$(cat ncurses.path)/include LDFLAGS=-L$(cat ncurses.path)/lib ./configure --prefix=${prefix} --disable-shared --with-curses
|
|
make -j${jobs}
|
|
}
|
|
|
|
install {
|
|
make DESTDIR=${destdir} install
|
|
}
|
|
}
|