* gnu/packages/ncurses.scm (stfl): New variable. --- gnu/packages/ncurses.scm | 50 +++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 49 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/ncurses.scm b/gnu/packages/ncurses.scm index 9799167..468cd99 100644 --- a/gnu/packages/ncurses.scm +++ b/gnu/packages/ncurses.scm @@ -3,6 +3,7 @@ ;;; Copyright © 2014 Mark H Weaver <[email protected]> ;;; Copyright © 2015 Leo Famulari <[email protected]> ;;; Copyright © 2016 ng0 <[email protected]> +;;; Copyright © 2016 Efraim Flashner <[email protected]> ;;; ;;; This file is part of GNU Guix. ;;; @@ -26,7 +27,8 @@ #:use-module (guix build-system gnu) #:use-module (guix build-system perl) #:use-module (gnu packages) - #:use-module (gnu packages perl)) + #:use-module (gnu packages perl) + #:use-module (gnu packages swig)) (define-public ncurses (let ((patch-makefile-phase @@ -207,3 +209,49 @@ curses widgets, such as dialog boxes.") "@code{Curses} is the interface between Perl and the curses library of your system.") (license (package-license perl)))) + +(define-public stfl + (package + (name "stfl") + (version "0.24") + (source + (origin + (method url-fetch) + (uri (string-append "http://www.clifford.at/stfl/stfl-" + version ".tar.gz")) + (sha256 + (base32 + "1460d5lc780p3q38l3wc9jfr2a7zlyrcra0li65aynj738cam9yl")))) + (build-system gnu-build-system) + (arguments + '(#:tests? #f ; no test target + #:phases + (modify-phases %standard-phases + ;; there is no configure script so we get to do it manually + (replace 'configure + (lambda* (#:key outputs #:allow-other-keys) + (substitute* "Makefile" + (("\\$\\(prefix\\)") (assoc-ref outputs "out"))) + (setenv "DESTDIR" "") + #t)) + ;; in our ncurses, the headers are in /include + (add-before 'build 'patch-ncursesw + (lambda _ + (substitute* '("stfl_internals.h") + (("ncursesw/") "")) + #t)) + (add-after 'install 'install-missing-symlink + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (lib (string-append out "/lib"))) + ;; newsbeuter looks for libstfl.so.0 + (symlink "libstfl.so" + (string-append lib "/libstfl.so.0")))))))) + (inputs + `(("ncurses" ,ncurses) + ("swig" ,swig))) + (home-page "http://www.clifford.at/stfl/") + (synopsis "Structured terminal forms library") + (description "Stfl is a library which implements a curses-based widget +set for text terminals.") + (license lgpl3+))) -- 2.10.2
