diff options
author | A. Wilcox <AWilcox@Wilcox-Tech.com> | 2018-06-14 02:22:19 -0500 |
---|---|---|
committer | A. Wilcox <AWilcox@Wilcox-Tech.com> | 2018-06-14 02:22:56 -0500 |
commit | b1eb50599e4db7eb4501af75cbbfa22007081ea5 (patch) | |
tree | c94a34c882cc17adedd781e8c5f34349b2a62416 /system/readline | |
parent | b9e85bbdcf38547ef2ca4e5c2a6e6293bbcd2752 (diff) | |
download | packages-b1eb50599e4db7eb4501af75cbbfa22007081ea5.tar.gz packages-b1eb50599e4db7eb4501af75cbbfa22007081ea5.tar.bz2 packages-b1eb50599e4db7eb4501af75cbbfa22007081ea5.tar.xz packages-b1eb50599e4db7eb4501af75cbbfa22007081ea5.zip |
The New Plan
all pkgs needed to bootstrap -> system
others -> user
Diffstat (limited to 'system/readline')
-rw-r--r-- | system/readline/APKBUILD | 71 | ||||
-rw-r--r-- | system/readline/fix-ncurses-underlinking.patch | 11 |
2 files changed, 82 insertions, 0 deletions
diff --git a/system/readline/APKBUILD b/system/readline/APKBUILD new file mode 100644 index 000000000..d825c0c42 --- /dev/null +++ b/system/readline/APKBUILD @@ -0,0 +1,71 @@ +# Maintainer: Natanael Copa <ncopa@alpinelinux.org> +pkgname=readline +pkgver=7.0.003 +pkgrel=0 +_myver=${pkgver%.*} +pkgdesc="GNU readline library" +url="https://cnswww.cns.cwru.edu/php/chet/readline/rltop.html" +arch="all" +options="!check" +license="GPL" +depends= +makedepends_host="ncurses-dev" +subpackages="$pkgname-dev $pkgname-doc libhistory" +source="http://ftp.gnu.org/gnu/$pkgname/$pkgname-$_myver.tar.gz + fix-ncurses-underlinking.patch + " + +for _patch in $(seq -w 001 ${pkgver##*.}); do + _name=$pkgname${_myver//./}-$_patch + source="$source $_name.diff::http://ftp.gnu.org/gnu/$pkgname/$pkgname-$_myver-patches/$_name" +done + +builddir="$srcdir/$pkgname-$_myver" + +prepare() { + local i + cd "$builddir" + for i in $source; do + case ${i%::*} in + *.diff) msg ${i#*::}; patch -p0 -i "$srcdir"/${i%::*} || return 1;; + esac + done + default_prepare || return 1 + update_config_sub +} + +build() { + cd "$builddir" + ./configure \ + --build=$CBUILD \ + --host=$CHOST \ + --prefix=/usr \ + --mandir=/usr/share/man \ + --infodir=/usr/share/info \ + --enable-static \ + --enable-shared \ + || return 1 + make || return 1 +} + +package() { + make -C "$builddir" DESTDIR="$pkgdir" install || return 1 + # verfy that its not underlinked as upstream designed it + if ! readelf -d "$pkgdir"/usr/lib/libreadline.so | grep 'NEEDED.*ncurses'; then + error "readline needs to be linked against ncurses" + return 1 + fi + rmdir "$pkgdir"/usr/bin +} + +libhistory() { + pkgdesc="GNU History Library" + mkdir -p "$subpkgdir"/usr/lib || return 1 + mv "$pkgdir"/usr/lib/$subpkgname.* "$subpkgdir"/usr/lib || return 1 +} + +sha512sums="18243189d39bf0d4c8a76cddcce75243c1bae8824c686e9b6ba352667607e5b10c5feb79372a1093c1c388d821841670702e940df12eae94bcebdeed90047870 readline-7.0.tar.gz +325dcf74e9f463a74fb116cb6f3ff8d9708dbec24b423a778eeda3a5ac4fe6df131e0e99d034053ad356b01502894ecc8facc09160d4c29b2291bd95cff6b635 fix-ncurses-underlinking.patch +4402186905af8cd42c609d640c2e13b9ad61c7778e5a3fd2c2d9da301f0deab05b04d7836f31527262f44f406517823dbb18cb07f2c73931186c806b494699ec readline70-001.diff +13d1489578508d4d2c3a1618024198a709dbce74a6bbf0f6d7ec67d2419c55bfec9f0ca9de0ed93f129d21d5c3a94307ccdc49408455bbb301c5e3a772b03185 readline70-002.diff +eaf962a1480eb3870519017b81ecc5cef171e4c41fcf8c17da61ccbfd0379ed6bca85c17b03e2207ae4d51509f33fd010294c75f4bd0433a52118015d4160385 readline70-003.diff" diff --git a/system/readline/fix-ncurses-underlinking.patch b/system/readline/fix-ncurses-underlinking.patch new file mode 100644 index 000000000..2c3c823d3 --- /dev/null +++ b/system/readline/fix-ncurses-underlinking.patch @@ -0,0 +1,11 @@ +--- ./shlib/Makefile.in.orig ++++ ./shlib/Makefile.in +@@ -86,7 +86,7 @@ + SHOBJ_LIBS = @SHOBJ_LIBS@ + + SHLIB_XLDFLAGS = @LDFLAGS@ @SHLIB_XLDFLAGS@ +-SHLIB_LIBS = @SHLIB_LIBS@ ++SHLIB_LIBS = @SHLIB_LIBS@ -lncursesw + + SHLIB_DOT = @SHLIB_DOT@ + SHLIB_LIBPREF = @SHLIB_LIBPREF@ |