From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id 2C7rHJg5m18ZWgAA0tVLHw (envelope-from ) for ; Thu, 29 Oct 2020 21:52: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 mp2 with LMTPS id KAHDGJg5m1+2IQAAB5/wlQ (envelope-from ) for ; Thu, 29 Oct 2020 21:52: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 6618B94043B for ; Thu, 29 Oct 2020 21:52:23 +0000 (UTC) Received: from localhost ([::1]:48600 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kYFqG-0000uP-Rn for larch@yhetil.org; Thu, 29 Oct 2020 17:52:20 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40498) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kYFpy-0000tN-MP for guix-patches@gnu.org; Thu, 29 Oct 2020 17:52:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:43667) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kYFpy-00059U-Cp for guix-patches@gnu.org; Thu, 29 Oct 2020 17:52:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kYFpy-0004iI-Ac for guix-patches@gnu.org; Thu, 29 Oct 2020 17:52:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#44275] [PATCH] gnu: Add python-pydub. Resent-From: Leo Famulari Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 29 Oct 2020 21:52:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44275 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Tanguy Le Carrour Cc: 44275@debbugs.gnu.org Received: via spool by 44275-submit@debbugs.gnu.org id=B44275.160400826518051 (code B ref 44275); Thu, 29 Oct 2020 21:52:02 +0000 Received: (at 44275) by debbugs.gnu.org; 29 Oct 2020 21:51:05 +0000 Received: from localhost ([127.0.0.1]:55213 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYFp3-0004h4-3h for submit@debbugs.gnu.org; Thu, 29 Oct 2020 17:51:05 -0400 Received: from wout2-smtp.messagingengine.com ([64.147.123.25]:40353) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kYFp0-0004gT-ED for 44275@debbugs.gnu.org; Thu, 29 Oct 2020 17:51:03 -0400 Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.west.internal (Postfix) with ESMTP id 73D62300; Thu, 29 Oct 2020 17:50:56 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute3.internal (MEProxy); Thu, 29 Oct 2020 17:50:56 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=famulari.name; h=date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=mesmtp; bh=9tC/HF1V1eYZU51B/z7NtRBG 0+b2939hESHhvOMp+7Q=; b=S60T11s8JQXXTGm0jgaPYdrk9t2P3/TewqCh8C9v SSzW5lW58I5MmiV91TUYPFjE6am/0ONVSvZzAQmmyGhllOxrm8wYF9twf65WSjvw k9McC0esaP5VaL0HddGGz8xq9yVhmsn6XvqwoIpup+zJMQgkFGWPHYdt8CeGk3fF B1Y= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; bh=9tC/HF 1V1eYZU51B/z7NtRBG0+b2939hESHhvOMp+7Q=; b=K/e9/0y02+s4OnzsTn0tjg wKNP592V0vGEKySnCP5CIbpRr7/DeqwROIA+ejBve4I5fUIRALYqzAaGRkKX8ypY hBcbmvY7HnFJE7o33yd54fgIFEQk0+ULvtNk4kSh3lsbz5mtBK0Tt+RznST5hgcP qQ/ziVyAkaQtdjbdBooqASescpzC8gWfhmPDnrOfIY/+nhuu20rNWZQgB6q0eX6q FjGCe9RXllPMAJmpnGq4Gxi1bPXoKUCwt5YTYxoKBjVNzO1HKqPa4sfjmWl0qdhx P4NCclOseQ7e1Y/NUWzjx5vaUAybGPxCJeT7cN7LLtczN6WWZ+e7nqKMXaN7JtVw == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedujedrleefgdduhedvucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepfffhvffukfhfgggtuggjsehgtderredttddvnecuhfhrohhmpefnvghoucfh rghmuhhlrghrihcuoehlvghosehfrghmuhhlrghrihdrnhgrmhgvqeenucggtffrrghtth gvrhhnpeefgfefvedtieehkefgieeffefhfeeifeejheeitefhgeevfefhtddvhfeuveeh ieenucffohhmrghinhepphihughusgdrtghomhenucfkphepjeefrddugedurdduvdejrd dugeeinecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhep lhgvohesfhgrmhhulhgrrhhirdhnrghmvg X-ME-Proxy: Received: from localhost (c-73-141-127-146.hsd1.pa.comcast.net [73.141.127.146]) by mail.messagingengine.com (Postfix) with ESMTPA id 584C73064683; Thu, 29 Oct 2020 17:50:55 -0400 (EDT) Date: Thu, 29 Oct 2020 17:50:53 -0400 From: Leo Famulari Message-ID: <20201029215053.GA11109@jasmine.lan> References: <20201028085654.18295-1-tanguy@bioneland.org> <20201028163450.GE12095@jasmine.lan> <20201029082657.xb3we5aqncp7qqci@rafflesia> <20201029141427.GB8956@jasmine.lan> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="AhhlLboLdkugWU4S" Content-Disposition: inline In-Reply-To: <20201029141427.GB8956@jasmine.lan> 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=famulari.name header.s=mesmtp header.b=S60T11s8; dkim=fail (rsa verify failed) header.d=messagingengine.com header.s=fm1 header.b=K/e9/0y0; dmarc=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: -2.11 X-TUID: /w+uLCW7OMPh --AhhlLboLdkugWU4S Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Thu, Oct 29, 2020 at 10:14:27AM -0400, Leo Famulari wrote: > Okay, I will take a look at the scipy thing today. I decided to let scipy be propagated since it's normal for Python things to be propagated. But I still think we should hard-code the reference to ffmpeg. I looked at the code, and it finds ffmpeg-related programs in 'pydub/utils.py', in the functions get_encoder_name(), get_player_name(), and get_prober_name(). I think it should be sufficient to substitute any mention of the words "ffmpeg", "ffplay", and "ffprobe" with the full store-path of those programs. I included a diff on your patch. You can see exactly what it does by adding (error "Stopping...") after the substitute*, building with --keep-failed, and then looking at the 'pydub/utils.py' file. diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 3c2d882003e..47ec542e6d1 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -16696,9 +16696,24 @@ ignoring formatting changes.") "0sfwfq7yjv4bl3yqbmizszscafvwf4zr40hzbsy7rclvzyznh333")))) (build-system python-build-system) (home-page "http://pydub.com") + (arguments + `(#:phases + (modify-phases %standard-phases + (add-after 'unpack 'patch-ffmpeg-references + (lambda* (#:key inputs #:allow-other-keys) + (let* ((ffmpeg-store-item (assoc-ref inputs "ffmpeg")) + (ffmpeg (string-append ffmpeg-store-item "/bin/ffmpeg")) + (ffplay (string-append ffmpeg-store-item "/bin/ffplay")) + (ffprobe (string-append ffmpeg-store-item "/bin/ffprobe"))) + (substitute* "pydub/utils.py" + (("ffmpeg") ffmpeg) + (("ffplay") ffplay) + (("ffprobe") ffprobe)) + #t)))))) + (inputs + `(("ffmpeg" ,ffmpeg))) (propagated-inputs - `(("ffmpeg" ,ffmpeg) - ("python-scipy" ,python-scipy))) + `(("python-scipy" ,python-scipy))) (synopsis "Manipulate audio with an simple and easy high level interface") (description "@code{pydub} makes it easy to manipulate audio. It relies on --AhhlLboLdkugWU4S Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEsFFZSPHn08G5gDigJkb6MLrKfwgFAl+bOT0ACgkQJkb6MLrK fwhA7A//XPKxPB8OjVk/RIK3LSWe8nrnOkimu1nEt1YalsluhH9P7WHiqRPEP3rZ d4SjfWVGq/NlwFLPclIGZtY3ptKLM/L/ucqfDjK5MttyHOASJ3mdQxMkerH/tysz aKmbGl+uCfBuC8wHlW9s+fdTeUzjelI2Fxumd0nIXxVTe+CELenrjTUxZY2gI+IH D+BsxepRrIDfflJPn1rplM9BGpVGzLIT0FX9tsUW74UxmmCn6QhPTQbcbrEFDDF+ rIfU407h/AldsJlJPrjRGsqbT9K8UiZows8cU4BxisGFrHDxFOc7Jw/6tzg9XYPF j+q2ZnrSQ9V5uZENrPDxsn4paa7HXfhm6RQ721gHxRIhO9Zef5ubAadZQ0L1GAwN 4fMb1pNLwPIJR2VtSboYTi50hN0UFjIkEgGSpoP6e6ZJT1JchSKX8v5/vjjebdyh 6ehtVlFEe969js1PMjp2a1YdH4tqp9JqOv4zREVW/Kio+G8+lsZNfLxTDQo5kjw9 sbkgkZTfsvZEkuTLEhN1+KRznD9c744A+6OWJWaBAOVI0s9mmu5y+u0JuKhj0G9V c+KqmPLtcm1k1xtB8och39CB3VjUNxT5cpt2N+iNZpdbYX/RVHmScw7VvkKRMHoo UvfecOZxGIYLDmzOE18FkePX9vIxMSfv2t+FoZX7es/jik5LEmE= =SiXq -----END PGP SIGNATURE----- --AhhlLboLdkugWU4S--