From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id MzWJGsD6hF++SAAA0tVLHw (envelope-from ) for ; Tue, 13 Oct 2020 00:54:24 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id QBckFsD6hF9oUgAA1q6Kng (envelope-from ) for ; Tue, 13 Oct 2020 00:54:24 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 28C979402AF for ; Tue, 13 Oct 2020 00:54:24 +0000 (UTC) Received: from localhost ([::1]:53954 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kS8a7-0001Kp-23 for larch@yhetil.org; Mon, 12 Oct 2020 20:54:23 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59936) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kS8Zn-0001JA-MV for guix-patches@gnu.org; Mon, 12 Oct 2020 20:54:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:32914) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kS8Zn-0007qm-CU for guix-patches@gnu.org; Mon, 12 Oct 2020 20:54:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kS8Zn-00039p-Au for guix-patches@gnu.org; Mon, 12 Oct 2020 20:54:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#43970] [PATCH 4/5] gnu: Add python-pyzbar. Resent-From: Vinicius Monego Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 13 Oct 2020 00:54:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 43970 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 43970@debbugs.gnu.org Cc: Vinicius Monego Received: via spool by 43970-submit@debbugs.gnu.org id=B43970.160255044112112 (code B ref 43970); Tue, 13 Oct 2020 00:54:03 +0000 Received: (at 43970) by debbugs.gnu.org; 13 Oct 2020 00:54:01 +0000 Received: from localhost ([127.0.0.1]:44458 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kS8Zk-00039D-SZ for submit@debbugs.gnu.org; Mon, 12 Oct 2020 20:54:01 -0400 Received: from mout02.posteo.de ([185.67.36.66]:52049) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kS8Zj-00038s-Mm for 43970@debbugs.gnu.org; Mon, 12 Oct 2020 20:54:00 -0400 Received: from submission (posteo.de [89.146.220.130]) by mout02.posteo.de (Postfix) with ESMTPS id 141BE2400FB for <43970@debbugs.gnu.org>; Tue, 13 Oct 2020 02:53:54 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1602550434; bh=KYl1z8J5o3YniBwWzItdoyXqMiNWizGsPq0v3kET0UY=; h=From:To:Cc:Subject:Date:From; b=Q3S5JNeuuMbfa3K6c00nbbbLUQIif9ZZKOWqLfEgJjMZpqiGngvf+72bsA+hRgTsI Y3gZ1eH8+BNHxHnH4+Gmh+ut6jb/FbcRCDaqAnZSZ+sQgFtcDWsPnwyIlsllpyFp9o j9LhJB54tflj/c1KL0RpAtDDGHV2TJl45BxGDmXrPZcKmo86KLQtFNP3Kkwucacx9P SV0iAbLIsX+R0mPz+o/cTHpo+xG0KX0MwAso9LnzbuJwWJP+WOum++zSHGOTOOUSwG 5J1ZuwuPBg0BQXJMAPMRtWhj+CuPbPcXkpHfrcRNE6gD9lLsKWBNRcp/Tw6ZBbU/BK 02chuQ2DJS8JQ== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4C9H9X5hCLz6tmD; Tue, 13 Oct 2020 02:53:52 +0200 (CEST) From: Vinicius Monego Date: Mon, 12 Oct 2020 21:53:24 -0300 Message-Id: <20201013005325.23880-3-monego@posteo.net> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20201013005325.23880-1-monego@posteo.net> References: <20201013005325.23880-1-monego@posteo.net> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -1.7 (-) X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=fail (rsa verify failed) header.d=posteo.net header.s=2017 header.b=Q3S5JNeu; dmarc=fail reason="SPF not aligned (strict)" header.from=posteo.net (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Spam-Score: 5.09 X-TUID: KCBSNqDQXEVR * gnu/packages/python-xyz.scm (python-pyzbar): New variable. --- gnu/packages/python-xyz.scm | 53 +++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index aa87e94d82..44ce6eb7f3 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -106,6 +106,7 @@ #:use-module (gnu packages) #:use-module (gnu packages algebra) #:use-module (gnu packages adns) + #:use-module (gnu packages aidc) #:use-module (gnu packages attr) #:use-module (gnu packages backup) #:use-module (gnu packages bash) @@ -17364,6 +17365,58 @@ Week instances stringify to this form.") (define-public python2-isoweek (package-with-python2 python-isoweek)) +(define-public python-pyzbar + (package + (name "python-pyzbar") + (version "0.1.8") + (source + (origin + ;; There's no source tarball on PyPI. + (method git-fetch) + (uri (git-reference + (url "https://github.com/NaturalHistoryMuseum/pyzbar") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1fqlfg5p2v9lzzzi0si2sz54lblprk6jjjhjw54b64lp58c1yhsl")))) + (build-system python-build-system) + (arguments + `(#:phases + (modify-phases %standard-phases + (add-after 'unpack 'remove-failing-test + (lambda _ + ;; This tests if find_library was called once, but we remove + ;; the call in the stage below to make the library find libzbar. + (delete-file "pyzbar/tests/test_zbar_library.py") + #t)) + (add-before 'build 'set-library-file-name + (lambda* (#:key inputs #:allow-other-keys) + (let ((libzbar (assoc-ref inputs "zbar"))) + (substitute* "pyzbar/zbar_library.py" + (("find_library\\('zbar'\\)") + (string-append "'" libzbar "/lib/libzbar.so.0'"))) + #t)))))) + (native-inputs + `(("pkg-config" ,pkg-config) + ("python-numpy" ,python-numpy) + ("python-pillow" ,python-pillow))) + (inputs + `(("zbar" ,zbar))) + (home-page "https://github.com/NaturalHistoryMuseum/pyzbar/") + (synopsis "Read one-dimensional barcodes and QR codes") + (description + "Read one-dimensional barcodes and QR codes using the zbar library. + +Features: + +@itemize +@item Pure python +@item Works with PIL / Pillow images, OpenCV / numpy ndarrays, and raw bytes +@item Decodes locations of barcodes +@item No dependencies, other than the zbar library itself +@end itemize") + (license license:expat))) + (define-public python-tokenize-rt (package (name "python-tokenize-rt") -- 2.20.1