From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ricardo Wurmus Subject: [PATCH] gnu: Add highlight. Date: Sat, 3 Dec 2016 20:43:07 +0100 Message-ID: <20161203194307.19324-1-rekado@elephly.net> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:46239) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cDGE4-0002I7-Bo for guix-devel@gnu.org; Sat, 03 Dec 2016 14:44:01 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cDGE1-0003Xw-9c for guix-devel@gnu.org; Sat, 03 Dec 2016 14:44:00 -0500 Received: from sender163-mail.zoho.com ([74.201.84.163]:21459) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cDGE0-0003Xk-VO for guix-devel@gnu.org; Sat, 03 Dec 2016 14:43:57 -0500 List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: guix-devel@gnu.org * gnu/packages/pretty-print.scm (highlight): New variable. --- gnu/packages/pretty-print.scm | 46 ++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 45 insertions(+), 1 deletion(-) diff --git a/gnu/packages/pretty-print.scm b/gnu/packages/pretty-print.scm index 8ba9780..8819b8a 100644 --- a/gnu/packages/pretty-print.scm +++ b/gnu/packages/pretty-print.scm @@ -1,6 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2014 Eric Bavier ;;; Copyright © 2016 Efraim Flashner +;;; Copyright © 2016 Ricardo Wurmus ;;; ;;; This file is part of GNU Guix. ;;; @@ -31,7 +32,9 @@ #:use-module (gnu packages bison) #:use-module (gnu packages flex) #:use-module (gnu packages gperf) - #:use-module (gnu packages perl)) + #:use-module (gnu packages lua) + #:use-module (gnu packages perl) + #:use-module (gnu packages pkg-config)) (define-public a2ps (package @@ -197,6 +200,47 @@ seen in a terminal.") (license gpl3+) (properties '((ftp-directory . "/gnu/src-highlite"))))) +(define-public highlight + (package + (name "highlight") + (version "3.33") + (source + (origin + (method url-fetch) + (uri (string-append "http://www.andre-simon.de/zip/highlight-" + version ".tar.bz2")) + (sha256 + (base32 + "0g2whi6pxl640795vymikm82a1my841jmh7fiqzbrjpc9wsk1db4")))) + (build-system gnu-build-system) + (arguments + `(#:tests? #f ; no tests + #:make-flags + (let ((confdir (string-append %output "/share/highlight/config/"))) + (list (string-append "PREFIX=" %output) + (string-append "HL_CONFIG_DIR=" confdir) + (string-append "conf_dir=" confdir))) + #:phases + (modify-phases %standard-phases + (delete 'configure) + (add-after 'unpack 'fix-search-for-lua + (lambda _ + (substitute* "src/makefile" + (("(pkg-config.*)lua" _ prefix) + (string-append prefix "lua-5.3"))) + #t))))) + (inputs + `(("lua" ,lua) + ("boost" ,boost))) + (native-inputs + `(("pkg-config" ,pkg-config))) + (home-page "http://www.andre-simon.de/doku/highlight/en/highlight.php") + (synopsis "Convert code to documents with syntax highlighting") + (description "Highlight converts source code to HTML, XHTML, RTF, LaTeX, +TeX, SVG, BBCode and terminal escape sequences with colored syntax +highlighting. Language definitions and color themes are customizable.") + (license gpl3+))) + (define-public astyle (package (name "astyle") -- 2.10.2