From patchwork Fri Oct 21 21:10:56 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "\\(" X-Patchwork-Id: 43779 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 1456727BBE9; Sat, 22 Oct 2022 00:41:21 +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=-3.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS, URIBL_BLOCKED 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 DB20127BBEA for ; Sat, 22 Oct 2022 00:41:17 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1om0Df-0004EI-J3; Fri, 21 Oct 2022 18:10:23 -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 1olzJD-0007Tt-6U for guix-patches@gnu.org; Fri, 21 Oct 2022 17:12:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1olzJC-0002NA-W9 for guix-patches@gnu.org; Fri, 21 Oct 2022 17:12:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1olzJC-0000a3-R0 for guix-patches@gnu.org; Fri, 21 Oct 2022 17:12:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#55903] [PATCH v13 01/42] gnu: Add go-github-com-zenhack-go-notmuch. References: In-Reply-To: Resent-From: "(" Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 21 Oct 2022 21:12:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 55903 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 55903@debbugs.gnu.org Cc: "\(unmatched-parenthesis" Received: via spool by 55903-submit@debbugs.gnu.org id=B55903.16663867112041 (code B ref 55903); Fri, 21 Oct 2022 21:12:02 +0000 Received: (at 55903) by debbugs.gnu.org; 21 Oct 2022 21:11:51 +0000 Received: from localhost ([127.0.0.1]:39111 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1olzJ0-0000Wb-1d for submit@debbugs.gnu.org; Fri, 21 Oct 2022 17:11:51 -0400 Received: from knopi.disroot.org ([178.21.23.139]:33386) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1olzIw-0000Vy-Ew for 55903@debbugs.gnu.org; Fri, 21 Oct 2022 17:11:47 -0400 Received: from localhost (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id AF8834E898; Fri, 21 Oct 2022 23:11:44 +0200 (CEST) X-Virus-Scanned: SPAM Filter at disroot.org Received: from knopi.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id FqCvyzYxLKYE; Fri, 21 Oct 2022 23:11:43 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1666386702; bh=HIyEquwvbvVdb5rFCZ3yMwORLqYwX/d3ZnVAXQv5UvE=; h=From:To:Cc:Subject:Date; b=a8e7wuau1tbVMQ7qXJkH9R9ijiwCS09pSdY6OokSMX90svy6opIAexhGkF2J38mFq SW6W0wGS0Es/OVG48hefCbDH914lOr6lN/3Z+HOANrZLWotrj1h7xYlVUb9kbU1EiY DTnJ1MKItlVETbFzX6rUbm4bac8VF8A9iIXOk2x/MrJYj3YE8wPtihyJLbwYj3YHZz BSjPQFHVLBNJnR2mvztBQ2pZMAPD+1gG8CDs8s0YbiLUgI+RKB1V52hGCZfRCCYHkA WxIueHWXHXjIwpADLwOHY1Ju0SMYVNgOttPl0AZQCsgXMdEexrg9KY8hMDucfw7cbc c6T8NO6suQylw== Date: Fri, 21 Oct 2022 22:10:56 +0100 Message-Id: <20221021211137.3296-1-paren@disroot.org> 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: , Sender: "Guix-patches" Reply-to: "\(" X-ACL-Warn: , "\( via Guix-patches" X-Patchwork-Original-From: "\( via Guix-patches" via From: "\\(" Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches From: "(unmatched-parenthesis" * gnu/packages/golang.scm (notmuch-fixtures): New variable here... (go-github-com-zenhack-go-notmuch): ...and here. --- gnu/packages/golang.scm | 52 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) base-commit: 78d4a08ac3a1de481bc56eef967a2e5ed2a912d5 diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index ecef5e275e..e74185973c 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -37,6 +37,7 @@ ;;; Copyright © 2022 muradm ;;; Copyright © 2022 Dhruvin Gandhi ;;; Copyright © 2022 Nicolas Graves +;;; Copyright © 2022 ( ;;; ;;; This file is part of GNU Guix. ;;; @@ -62,6 +63,7 @@ (define-module (gnu packages golang) #:use-module (guix download) #:use-module (guix git-download) #:use-module (guix packages) + #:use-module (guix gexp) #:use-module (guix build-system gnu) #:use-module (guix build-system trivial) #:use-module (guix build-system go) @@ -74,6 +76,7 @@ (define-module (gnu packages golang) #:use-module (gnu packages glib) #:use-module (gnu packages gnupg) #:use-module (gnu packages lua) + #:use-module (gnu packages mail) #:use-module (gnu packages mp3) #:use-module (gnu packages password-utils) #:use-module (gnu packages pcre) @@ -10325,6 +10328,55 @@ (define-public go-github-com-disintegration-imaging (resize, rotate, crop, brightness/contrast adjustments, etc.).") (license license:expat))) +(define notmuch-fixtures + (origin + (method url-fetch) + (uri "http://notmuchmail.org/releases/test-databases/database-v1.tar.xz") + (sha256 + (base32 + "1lk91s00y4qy4pjh8638b5lfkgwyl282g1m27srsf7qfn58y16a2")))) + +(define-public go-github-com-zenhack-go-notmuch + (package + (name "go-github-com-zenhack-go-notmuch") + (version "0.0.0-20211022191430-4d57e8ad2a8b") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/zenhack/go.notmuch") + (commit (go-version->git-ref version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1j2s5smjf7pp7i72dw12sm9iz961y3cy8nkm7hmrg53f6wna57h9")))) + (build-system go-build-system) + (arguments + (list #:import-path "github.com/zenhack/go.notmuch" + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-notmuch-path + (lambda* (#:key inputs import-path #:allow-other-keys) + (substitute* (find-files (string-append + "src/" import-path) + "\\.go$") + (("// #cgo LDFLAGS:.*$") + (string-append + "// #cgo LDFLAGS: -lnotmuch " + "-L" #$(this-package-input "notmuch") "/lib\n" + "// #cgo CFLAGS: " + "-I" #$(this-package-input "notmuch") "/include\n"))))) + (add-before 'check 'unpack-test-fixtures + (lambda* (#:key inputs import-path #:allow-other-keys) + (invoke "tar" "xf" #$notmuch-fixtures "-C" + (string-append "src/" import-path "/fixtures"))))))) + (inputs (list notmuch)) + (home-page "https://github.com/zenhack/go.notmuch") + (synopsis "Go bindings to libnotmuch") + (description + "The notmuch package provides a Go language binding to the notmuch +email library.") + (license license:gpl3+))) + ;;; ;;; Avoid adding new packages to the end of this file. To reduce the chances ;;; of a merge conflict, place them above by existing packages with similar