From 41dd9794f34e34b57be986acaf6c4a3845442222 Mon Sep 17 00:00:00 2001 From: Johannes Löthberg Date: Mon, 22 Sep 2014 17:07:31 +0100 Subject: ncurses-git: import --- PKGBUILD | 81 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) create mode 100644 PKGBUILD (limited to 'PKGBUILD') diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 0000000..bf61487 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,81 @@ +pkgname=ncurses-git +pkgver=5.9.r170.g9ee3995 +pkgrel=1 + +pkgdesc='Unofficial git mirror of snapshots from ftp://invisible-island.net/ncurses/current/' +url='http://ncurses.scripts.mit.edu/?p=ncurses.git' +arch=('i686' 'x86_64') +license=('MIT') + +makedepends=('git') + +provides=('ncurses') +conflicts=('ncurses') + +source=('git://ncurses.scripts.mit.edu/ncurses.git') + +md5sums=('SKIP') + +pkgver() { + cd ncurses + git describe --tags | sed 's/^v//; s/-/.r/; s/-/./' +} + +prepare() { + mkdir ncurses-build + mkdir ncursesw-build +} + +build() { + cd ncursesw-build + + # add --enable-ext-colors and --enable-ext-mouse with next soname bump + ../ncurses/configure --prefix=/usr \ + --with-shared \ + --with-normal \ + --without-ada \ + --enable-widec \ + --without-debug \ + --enable-pc-files + + make + + # libraries for external binary support + cd "$srcdir"/ncurses-build + + ../ncurses/configure --prefix=/usr \ + --with-shared \ + --with-normal \ + --without-ada \ + --without-debug \ + --with-chtype=logn + make +} + +package() { + cd ncursesw-build + make DESTDIR="$pkgdir" install + + # fool packages looking to link to non-wide-character ncurses libraries + for lib in ncurses form panel menu; do + printf 'INPUT(-l%sw)\n' "$lib" > "$pkgdir"/usr/lib/lib"$lib".so + done + + for lib in ncurses ncurses++ form panel menu; do + ln -s "$lib"w.pc "$pkgdir"/usr/lib/pkgconfig/"$lib".pc + done + + # some packages look for -lcurses during build + printf 'INPUT(-lncursesw)\n' > "$pkgdir"/usr/lib/libcursesw.so + ln -s libncurses.so "$pkgdir"/usr/lib/libcurses.so + + # non-widec compatibility libraries + cd "$srcdir"/ncurses-build + for lib in ncurses form panel menu; do + install -Dm755 lib/lib"$lib".so.5.9 "$pkgdir"/usr/lib/lib"$lib".so.5.9 + ln -s lib"$lib".so.5.9 "$pkgdir"/usr/lib/lib"$lib".so.5 + done + + cd "$srcdir"/ncurses + install -Dm755 COPYING "$pkgdir"/usr/share/licenses/ncurses/COPYING +} -- cgit v1.2.3-70-g09d2