From patchwork Tue Aug 31 08:49:36 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hartmut Goebel X-Patchwork-Id: 32436 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 422C527BBE1; Tue, 31 Aug 2021 09:50:20 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_MSPIKE_H2,SPF_HELO_PASS autolearn=unavailable autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 5F1C727BBE1 for ; Tue, 31 Aug 2021 09:50:19 +0100 (BST) Received: from localhost ([::1]:42582 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mKzTG-0002D7-E2 for patchwork@mira.cbaines.net; Tue, 31 Aug 2021 04:50:18 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60630) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mKzT6-000270-Kx for guix-patches@gnu.org; Tue, 31 Aug 2021 04:50:08 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:49601) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mKzT6-00083B-8D for guix-patches@gnu.org; Tue, 31 Aug 2021 04:50:08 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mKzT6-0000yn-5c for guix-patches@gnu.org; Tue, 31 Aug 2021 04:50:08 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#50295] [PATCH 4/6] gnu: tryton modules: Unify native-inputs. Resent-From: Hartmut Goebel Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 31 Aug 2021 08:50:08 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 50295 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 50295@debbugs.gnu.org X-Debbugs-Original-To: 50295@debbugs.gnu.org, guix-patches@gnu.org Received: via spool by 50295-submit@debbugs.gnu.org id=B50295.16303998053716 (code B ref 50295); Tue, 31 Aug 2021 08:50:08 +0000 Received: (at 50295) by debbugs.gnu.org; 31 Aug 2021 08:50:05 +0000 Received: from localhost ([127.0.0.1]:32904 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mKzT1-0000xW-90 for submit@debbugs.gnu.org; Tue, 31 Aug 2021 04:50:04 -0400 Received: from mail-out.m-online.net ([212.18.0.10]:49901) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mKzSr-0000wF-PU for 50295@debbugs.gnu.org; Tue, 31 Aug 2021 04:49:54 -0400 Received: from frontend01.mail.m-online.net (unknown [192.168.8.182]) by mail-out.m-online.net (Postfix) with ESMTP id 4GzLV91yqQz1rk5h; Tue, 31 Aug 2021 10:49:53 +0200 (CEST) Received: from localhost (dynscan1.mnet-online.de [192.168.6.70]) by mail.m-online.net (Postfix) with ESMTP id 4GzLV91rbMz1qqkH; Tue, 31 Aug 2021 10:49:53 +0200 (CEST) X-Virus-Scanned: amavisd-new at mnet-online.de Received: from mail.mnet-online.de ([192.168.8.182]) by localhost (dynscan1.mail.m-online.net [192.168.6.70]) (amavisd-new, port 10024) with ESMTP id x13LK-DNCAh5; Tue, 31 Aug 2021 10:49:51 +0200 (CEST) Received: from hermia.goebel-consult.de (ppp-188-174-49-67.dynamic.mnet-online.de [188.174.49.67]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.mnet-online.de (Postfix) with ESMTPS; Tue, 31 Aug 2021 10:49:51 +0200 (CEST) Received: from lenashee.fritz.box (lenashee.goebel-consult.de [192.168.110.2]) by hermia.goebel-consult.de (Postfix) with ESMTP id 8171A6016F; Tue, 31 Aug 2021 10:49:44 +0200 (CEST) From: Hartmut Goebel Date: Tue, 31 Aug 2021 10:49:36 +0200 Message-Id: <1f28ea1b32ac9e4cb1d1b44ef70a5c14cadb9d99.1630398482.git.h.goebel@crazy-compilers.com> X-Mailer: git-send-email 2.30.2 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" X-getmail-retrieved-from-mailbox: Patches For testing, the tryton modules require a common set of native-input, which basically are the propagated-inputs of `trytond`. (Some modules leave out one or two of these, but most modules require all.) So to avoid redundant code, use a variable for defining this common set. This reduces the maintenance burden when more trytond modules are added. * gnu/packages/tryton.scm (%standard-trytond-native-inputs): New variable. (trytond-account, trytond-account-invoice, trytond-account-invoice-stock, trytond-account-product, trytond-analytic-account, trytond-company, trytond-country, trytond-currency, trytond-party, trytond-product, trytond-purchase, trytond-purchase-request, trytond-stock, trytond-stock-lot, trytond-stock-supply)[native-inputs]: Use it. native-inouts2 --- gnu/packages/tryton.scm | 198 ++++++---------------------------------- 1 file changed, 30 insertions(+), 168 deletions(-) diff --git a/gnu/packages/tryton.scm b/gnu/packages/tryton.scm index d7f03e9181..d9acc671e1 100644 --- a/gnu/packages/tryton.scm +++ b/gnu/packages/tryton.scm @@ -171,6 +171,20 @@ the build system." ;;; Tryton modules - please sort alphabetically ;;; +(define %standard-trytond-native-inputs + ;; native-inputs required by most of the tryton module for running the test + `(("python-dateutil" ,python-dateutil) + ("python-genshi" ,python-genshi) + ("python-lxml" ,python-lxml) + ("python-magic" ,python-magic) + ("python-passlib" ,python-passlib) + ("python-polib" ,python-polib) + ("python-proteus" ,python-proteus) + ("python-relatorio" ,python-relatorio) + ("python-sql" ,python-sql) + ("python-werkzeug" ,python-werkzeug) + ("python-wrapt" ,python-wrapt))) + (define-public trytond-account (package (name "trytond-account") @@ -183,16 +197,7 @@ the build system." (base32 "16ny67vcnxk9ngcxd56cfixm441vs9jxv3apmb16xsi47yk2xd7w")))) (build-system python-build-system) (arguments (tryton-arguments "account")) - (native-inputs - `(("python-genshi" ,python-genshi) - ("python-lxml" ,python-lxml) - ("python-magic" ,python-magic) - ("python-passlib" ,python-passlib) - ("python-polib" ,python-polib) - ("python-proteus" ,python-proteus) - ("python-relatorio" ,python-relatorio) - ("python-werkzeug" ,python-werkzeug) - ("python-wrapt" ,python-wrapt))) + (native-inputs `(,@%standard-trytond-native-inputs)) (propagated-inputs `(("python-dateutil" ,python-dateutil) ("python-simpleeval" ,python-simpleeval) @@ -223,16 +228,7 @@ most of accounting needs.") (base32 "0drccambg6855p7ai8654c7f9v85jzwicwpxmagyrr09qz6qzgcz")))) (build-system python-build-system) (arguments (tryton-arguments "account_invoice")) - (native-inputs - `(("python-genshi" ,python-genshi) - ("python-lxml" ,python-lxml) - ("python-magic" ,python-magic) - ("python-passlib" ,python-passlib) - ("python-polib" ,python-polib) - ("python-proteus" ,python-proteus) - ("python-relatorio" ,python-relatorio) - ("python-werkzeug" ,python-werkzeug) - ("python-wrapt" ,python-wrapt))) + (native-inputs `(,@%standard-trytond-native-inputs)) (propagated-inputs `(("python-dateutil" ,python-dateutil) ("python-sql" ,python-sql) @@ -267,18 +263,7 @@ term.") (base32 "02m6ikcc38ac41ddzg5xp5l9jz0k6j7j1g2xa62ki4v093yn4z5v")))) (build-system python-build-system) (arguments (tryton-arguments "account_invoice_stock")) - (native-inputs - `(("python-dateutil" ,python-dateutil) - ("python-genshi" ,python-genshi) - ("python-lxml" ,python-lxml) - ("python-magic" ,python-magic) - ("python-passlib" ,python-passlib) - ("python-polib" ,python-polib) - ("python-proteus" ,python-proteus) - ("python-relatorio" ,python-relatorio) - ("python-sql" ,python-sql) - ("python-werkzeug" ,python-werkzeug) - ("python-wrapt" ,python-wrapt))) + (native-inputs `(,@%standard-trytond-native-inputs)) (propagated-inputs `(("trytond" ,trytond) ("trytond-account-invoice" ,trytond-account-invoice) @@ -308,18 +293,7 @@ average price of the posted invoice lines that are linked to it.") (base32 "10bpbkkmllbh9lm5ajydmc5nvqm9bbdn9rmm03jqgik23s5kyx2z")))) (build-system python-build-system) (arguments (tryton-arguments "account_product")) - (native-inputs - `(("python-dateutil" ,python-dateutil) - ("python-genshi" ,python-genshi) - ("python-lxml" ,python-lxml) - ("python-magic" ,python-magic) - ("python-passlib" ,python-passlib) - ("python-polib" ,python-polib) - ("python-proteus" ,python-proteus) - ("python-relatorio" ,python-relatorio) - ("python-sql" ,python-sql) - ("python-werkzeug" ,python-werkzeug) - ("python-wrapt" ,python-wrapt))) + (native-inputs `(,@%standard-trytond-native-inputs)) (propagated-inputs `(("trytond" ,trytond) ("trytond-account" ,trytond-account) @@ -348,17 +322,7 @@ and category.") (base32 "10rn2rf1ji7d1gxmgca368yvabql1ahklqg7p8sh5bl79vn5qx5x")))) (build-system python-build-system) (arguments (tryton-arguments "analytic_account")) - (native-inputs - `(("python-dateutil" ,python-dateutil) - ("python-genshi" ,python-genshi) - ("python-lxml" ,python-lxml) - ("python-magic" ,python-magic) - ("python-passlib" ,python-passlib) - ("python-polib" ,python-polib) - ("python-proteus" ,python-proteus) - ("python-relatorio" ,python-relatorio) - ("python-werkzeug" ,python-werkzeug) - ("python-wrapt" ,python-wrapt))) + (native-inputs `(,@%standard-trytond-native-inputs)) (propagated-inputs `(("python-sql" ,python-sql) ("trytond" ,trytond) @@ -389,18 +353,7 @@ required to analyse accounting using multiple different axes.") (base32 "1bwy2rkgfw32cwhq5fh3rpy7bx425h44ap10i9kjx5ak86bfnpz9")))) (build-system python-build-system) (arguments (tryton-arguments "company")) - (native-inputs - `(("python-dateutil" ,python-dateutil) - ("python-genshi" ,python-genshi) - ("python-lxml" ,python-lxml) - ("python-magic" ,python-magic) - ("python-passlib" ,python-passlib) - ("python-polib" ,python-polib) - ("python-proteus" ,python-proteus) - ("python-relatorio" ,python-relatorio) - ("python-sql" ,python-sql) - ("python-werkzeug" ,python-werkzeug) - ("python-wrapt" ,python-wrapt))) + (native-inputs `(,@%standard-trytond-native-inputs)) (propagated-inputs `(("trytond" ,trytond) ("trytond-currency" ,trytond-currency) @@ -428,18 +381,7 @@ company and employee and extend the user model.") (build-system python-build-system) ;; Doctest contains one test that requires internet access. (arguments (tryton-arguments "country" "--no-doctest")) - (native-inputs - `(("python-dateutil" ,python-dateutil) - ("python-genshi" ,python-genshi) - ("python-lxml" ,python-lxml) - ("python-magic" ,python-magic) - ("python-passlib" ,python-passlib) - ("python-polib" ,python-polib) - ("python-proteus" ,python-proteus) - ("python-relatorio" ,python-relatorio) - ("python-sql" ,python-sql) - ("python-werkzeug" ,python-werkzeug) - ("python-wrapt" ,python-wrapt))) + (native-inputs `(,@%standard-trytond-native-inputs)) (propagated-inputs `(("python-pycountry" ,python-pycountry) ("trytond" ,trytond))) @@ -465,18 +407,9 @@ company and employee and extend the user model.") (build-system python-build-system) (arguments (tryton-arguments "currency")) (native-inputs - `(("python-dateutil" ,python-dateutil) - ("python-genshi" ,python-genshi) + `(,@%standard-trytond-native-inputs ("python-forex-python" ,python-forex-python) - ("python-lxml" ,python-lxml) - ("python-magic" ,python-magic) - ("python-passlib" ,python-passlib) - ("python-polib" ,python-polib) - ("python-proteus" ,python-proteus) - ("python-pycountry" ,python-pycountry) - ("python-relatorio" ,python-relatorio) - ("python-werkzeug" ,python-werkzeug) - ("python-wrapt" ,python-wrapt))) + ("python-pycountry" ,python-pycountry))) (propagated-inputs `(("python-sql" ,python-sql) ("trytond" ,trytond))) @@ -503,17 +436,7 @@ currency and rate.") (build-system python-build-system) ;; Doctest 'scenario_party_phone_number.rst' fails. (arguments (tryton-arguments "party" "--no-doctest")) - (native-inputs - `(("python-dateutil" ,python-dateutil) - ("python-genshi" ,python-genshi) - ("python-lxml" ,python-lxml) - ("python-magic" ,python-magic) - ("python-passlib" ,python-passlib) - ("python-polib" ,python-polib) - ("python-proteus" ,python-proteus) - ("python-relatorio" ,python-relatorio) - ("python-werkzeug" ,python-werkzeug) - ("python-wrapt" ,python-wrapt))) + (native-inputs `(,@%standard-trytond-native-inputs)) (propagated-inputs `(("python-sql" ,python-sql) ("python-stnum" ,python-stdnum) @@ -541,17 +464,7 @@ addresses.") (base32 "0x18ngpjyrdwjwg17bz98jph4jv5gcv0qc0p2kxpam4lqsy34ic2")))) (build-system python-build-system) (arguments (tryton-arguments "product")) - (native-inputs - `(("python-dateutil" ,python-dateutil) - ("python-genshi" ,python-genshi) - ("python-lxml" ,python-lxml) - ("python-magic" ,python-magic) - ("python-passlib" ,python-passlib) - ("python-polib" ,python-polib) - ("python-proteus" ,python-proteus) - ("python-relatorio" ,python-relatorio) - ("python-werkzeug" ,python-werkzeug) - ("python-wrapt" ,python-wrapt))) + (native-inputs `(,@%standard-trytond-native-inputs)) (propagated-inputs `(("python-sql" ,python-sql) ("python-stdnum" ,python-stdnum) @@ -579,17 +492,7 @@ Template and Product.") (base32 "0na74zijj46b12gypy9si3las02a96rh5ygl503c7razha61g1b0")))) (build-system python-build-system) (arguments (tryton-arguments "purchase")) - (native-inputs - `(("python-dateutil" ,python-dateutil) - ("python-genshi" ,python-genshi) - ("python-lxml" ,python-lxml) - ("python-magic" ,python-magic) - ("python-passlib" ,python-passlib) - ("python-polib" ,python-polib) - ("python-proteus" ,python-proteus) - ("python-relatorio" ,python-relatorio) - ("python-werkzeug" ,python-werkzeug) - ("python-wrapt" ,python-wrapt))) + (native-inputs `(,@%standard-trytond-native-inputs)) (propagated-inputs `(("python-sql" ,python-sql) ("trytond" ,trytond) @@ -624,18 +527,7 @@ Template and Product.") (build-system python-build-system) ;; Doctest 'scenario_purchase_request.rst' fails. (arguments (tryton-arguments "purchase_request" "--no-doctest")) - (native-inputs - `(("python-dateutil" ,python-dateutil) - ("python-genshi" ,python-genshi) - ("python-lxml" ,python-lxml) - ("python-magic" ,python-magic) - ("python-passlib" ,python-passlib) - ("python-polib" ,python-polib) - ("python-proteus" ,python-proteus) - ("python-relatorio" ,python-relatorio) - ("python-sql" ,python-sql) - ("python-werkzeug" ,python-werkzeug) - ("python-wrapt" ,python-wrapt))) + (native-inputs `(,@%standard-trytond-native-inputs)) (propagated-inputs `(("trytond" ,trytond) ("trytond-product" ,trytond-product) @@ -664,16 +556,7 @@ generated by other process from Tryton.") (base32 "0yb8kd3alwqkivrlpx0ni4jxv3x14i37lmwism9yi81xwchyrcjk")))) (build-system python-build-system) (arguments (tryton-arguments "stock")) - (native-inputs - `(("python-genshi" ,python-genshi) - ("python-lxml" ,python-lxml) - ("python-magic" ,python-magic) - ("python-passlib" ,python-passlib) - ("python-polib" ,python-polib) - ("python-proteus" ,python-proteus) - ("python-relatorio" ,python-relatorio) - ("python-werkzeug" ,python-werkzeug) - ("python-wrapt" ,python-wrapt))) + (native-inputs `(,@%standard-trytond-native-inputs)) (propagated-inputs `(("python-simpleeval" ,python-simpleeval) ("python-sql" ,python-sql) @@ -706,18 +589,7 @@ inventory to control and update stock levels.") (base32 "0w2f62cfzm7j8wnw8igmjslpxc1a8s82dkdizyvim5qhjg6mrsym")))) (build-system python-build-system) (arguments (tryton-arguments "stock_lot")) - (native-inputs - `(("python-dateutil" ,python-dateutil) - ("python-genshi" ,python-genshi) - ("python-lxml" ,python-lxml) - ("python-magic" ,python-magic) - ("python-passlib" ,python-passlib) - ("python-polib" ,python-polib) - ("python-proteus" ,python-proteus) - ("python-relatorio" ,python-relatorio) - ("python-sql" ,python-sql) - ("python-werkzeug" ,python-werkzeug) - ("python-wrapt" ,python-wrapt))) + (native-inputs `(,@%standard-trytond-native-inputs)) (propagated-inputs `(("trytond" ,trytond) ("trytond-product" ,trytond-product) @@ -743,17 +615,7 @@ inventory to control and update stock levels.") (base32 "01cgpxlznldrba79a3xmj4d0csyfc3ccgs66c490j8v8rdnqpbww")))) (build-system python-build-system) (arguments (tryton-arguments "stock_supply")) - (native-inputs - `(("python-dateutil" ,python-dateutil) - ("python-genshi" ,python-genshi) - ("python-lxml" ,python-lxml) - ("python-magic" ,python-magic) - ("python-passlib" ,python-passlib) - ("python-polib" ,python-polib) - ("python-proteus" ,python-proteus) - ("python-relatorio" ,python-relatorio) - ("python-werkzeug" ,python-werkzeug) - ("python-wrapt" ,python-wrapt))) + (native-inputs `(,@%standard-trytond-native-inputs)) (propagated-inputs `(("python-sql" ,python-sql) ("trytond" ,trytond)