From patchwork Mon Jul 31 23:45:46 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: gemmaro X-Patchwork-Id: 52445 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id EAB8227BBE9; Tue, 1 Aug 2023 00:47:37 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, SPF_HELO_PASS autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id B554327BBEB for ; Tue, 1 Aug 2023 00:47:34 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qQcbS-0004fX-BI; Mon, 31 Jul 2023 19:47:06 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qQcbP-0004em-0c for guix-patches@gnu.org; Mon, 31 Jul 2023 19:47:03 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qQcbO-00044I-PU for guix-patches@gnu.org; Mon, 31 Jul 2023 19:47:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qQcbO-0000xP-L4 for guix-patches@gnu.org; Mon, 31 Jul 2023 19:47:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#64983] [PATCH 2/3] gnu: highlight: Use new package style. Resent-From: gemmaro Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 31 Jul 2023 23:47:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 64983 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 64983@debbugs.gnu.org Cc: gemmaro Received: via spool by 64983-submit@debbugs.gnu.org id=B64983.16908471853612 (code B ref 64983); Mon, 31 Jul 2023 23:47:02 +0000 Received: (at 64983) by debbugs.gnu.org; 31 Jul 2023 23:46:25 +0000 Received: from localhost ([127.0.0.1]:46868 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qQcan-0000wC-7A for submit@debbugs.gnu.org; Mon, 31 Jul 2023 19:46:25 -0400 Received: from mail-pl1-x634.google.com ([2607:f8b0:4864:20::634]:42184) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qQcal-0000vy-2J for 64983@debbugs.gnu.org; Mon, 31 Jul 2023 19:46:24 -0400 Received: by mail-pl1-x634.google.com with SMTP id d9443c01a7336-1bbc06f830aso32884755ad.0 for <64983@debbugs.gnu.org>; Mon, 31 Jul 2023 16:46:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1690847177; x=1691451977; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=py2n9f3I1+XI2vucN+p2xhRwa6EexOQaP4JsugfFQC8=; b=VfjdwrUC0Z2vfS8IrakjY0nPFwTuax0WnNj2WAt19c0rQdiqVivBalMHC9a6d/7nvW /B6CQxGlY+g0OWBXjL0EPAPybfoBI9Qdg5iH/rGdME4hW8HOcsmunutaqDZdphnU6k1h Qq2DBCId/bulCS/n6Mq12JVeJS6H40HjrkOtLnWsNSybjVxdQKSwIP6+0XtO1m4ZdBCR 2Eo1TQIO3iMj18QJe3RPEyFAvSHVKr1IFGyLlINuuLa4Yde4uIB/Mkp7bbAzfZa8Ikmq 5TEFkqth6CFQrZeXuy4rF62uGjG7fzNYGE/yADrE2Hot9uNEfb9r/kJIpRsRyj358tvR 0Fmg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1690847177; x=1691451977; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=py2n9f3I1+XI2vucN+p2xhRwa6EexOQaP4JsugfFQC8=; b=RY6YFM7glXINLTv47GbtPoR/fuDkNyOieE+7QoQhHWHw4dhCh5sK76q4q7oB31YBwM HWQik+1agN6HAj+5b6HFEc1d536+Ex9EnF0hOGPzk2yXHVxWFdCl2XybVziK2TdGHJdb es0jfcGGR+kY/ecNAjvF4ie7oQAxf39CUP5zXs9THmeR6ZQWck2YJf/bCBq6+hUR9Om7 3AJtH0u0gE08aj9jm07CWEmgND8OwkS9XSNfpsEVlguB3Ya1tyCzJxm+2QjsIW+ZsyND /cCvUW+kwP7PYS4G25LYG0fo7ExjmOgXzsDRIb1Ky8QeUO08TaCPvLCymh9kU1sYadQ1 H7iw== X-Gm-Message-State: ABy/qLa6Q+aRyt0q7PJz733DzJDjn/zbHuklMrIxm2pBe/J/ZIZS7jxW p6HLXqJmKhJLLP9qEPh8sNg7XbdkXyyHtA== X-Google-Smtp-Source: APBJJlEsP9JS86FH4ddtHvwV0GDqsINEy+WdyA2IPBSJCx65teooY3ReyT5luwgaVe6HjIn6WTYmNg== X-Received: by 2002:a17:902:ec90:b0:1bc:edd:e891 with SMTP id x16-20020a170902ec9000b001bc0edde891mr5978686plg.1.1690847177224; Mon, 31 Jul 2023 16:46:17 -0700 (PDT) Received: from mac.gemmaro.name ([240f:74:d1f0:1:ba1:e787:c9e:b1dc]) by smtp.gmail.com with ESMTPSA id s24-20020a63af58000000b0056368adf5e2sm3047837pgo.87.2023.07.31.16.46.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 31 Jul 2023 16:46:16 -0700 (PDT) From: gemmaro Date: Tue, 1 Aug 2023 08:45:46 +0900 Message-ID: <7008326f574879d4f79020313fb1bf54605b0cec.1690846546.git.gemmaro.dev@gmail.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: References: MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/packages/pretty-print.scm (highlight) Use new package style. [arguments]: Use G-expression. Drop trailing #t from phases. [source, inputs, native-inputs, description]: Reformat with guix style. --- gnu/packages/pretty-print.scm | 89 ++++++++++++++++++----------------- 1 file changed, 45 insertions(+), 44 deletions(-) diff --git a/gnu/packages/pretty-print.scm b/gnu/packages/pretty-print.scm index 9896824f01..1b2cf4becf 100644 --- a/gnu/packages/pretty-print.scm +++ b/gnu/packages/pretty-print.scm @@ -352,54 +352,55 @@ (define-public highlight (package (name "highlight") (version "4.7") - (source - (origin - (method url-fetch) - (uri (string-append "http://www.andre-simon.de/zip/highlight-" - version ".tar.bz2")) - (sha256 - (base32 "1cl21qpgy92w1x53vrn1bgq84mkh6fgayc9k38mz4xmz2yw01nv1")))) + (source (origin + (method url-fetch) + (uri (string-append "http://www.andre-simon.de/zip/highlight-" + version ".tar.bz2")) + (sha256 + (base32 + "1cl21qpgy92w1x53vrn1bgq84mkh6fgayc9k38mz4xmz2yw01nv1")))) (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) ; no configure script - (add-after 'unpack 'fix-search-for-lua - (lambda _ - (substitute* "src/makefile" - (("(LUA_PKG_NAME=).*" _ assignment) - (string-append assignment "lua-" ,(version-major+minor - (package-version lua)) - "\n"))) - (substitute* "extras/swig/makefile" - (("lua") (string-append "lua-" ,(version-major+minor - (package-version lua))))) - #t)) - (add-after 'install 'install-perl-bindings - (lambda* (#:key outputs #:allow-other-keys) - (let* ((perldir (string-append (assoc-ref outputs "out") - "/lib/perl5/site_perl/" - ,(package-version perl))) - (autodir (string-append perldir "/auto/highlight"))) - (with-directory-excursion "extras/swig" - (invoke "make" "perl") - (invoke "perl" "-I" "." "testmod.pl") - (install-file "highlight.pm" perldir) - (install-file "highlight.so" autodir)) - #t)))))) - (inputs - (list lua boost perl)) - (native-inputs - (list pkg-config swig)) + (list #: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) ;no configure script + (add-after 'unpack 'fix-search-for-lua + (lambda _ + (substitute* "src/makefile" + (("(LUA_PKG_NAME=).*" _ assignment) + (string-append assignment "lua-" + #$(version-major+minor (package-version + lua)) + "\n"))) + (substitute* "extras/swig/makefile" + (("lua") + (string-append "lua-" + #$(version-major+minor (package-version + lua))))))) + (add-after 'install 'install-perl-bindings + (lambda* (#:key outputs #:allow-other-keys) + (let* ((perldir (string-append (assoc-ref outputs + "out") + "/lib/perl5/site_perl/" + #$(package-version perl))) + (autodir (string-append perldir + "/auto/highlight"))) + (with-directory-excursion "extras/swig" + (invoke "make" "perl") + (invoke "perl" "-I" "." "testmod.pl") + (install-file "highlight.pm" perldir) + (install-file "highlight.so" autodir)))))))) + (inputs (list lua boost perl)) + (native-inputs (list pkg-config swig)) (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, + (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+)))