From patchwork Wed Mar 23 18:48:50 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: M X-Patchwork-Id: 38030 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 6699327BBE9; Wed, 23 Mar 2022 18:50:53 +0000 (GMT) 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,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H5, RCVD_IN_MSPIKE_WL,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 B396D27BBEB for ; Wed, 23 Mar 2022 18:50:50 +0000 (GMT) Received: from localhost ([::1]:57156 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nX64H-00067x-VJ for patchwork@mira.cbaines.net; Wed, 23 Mar 2022 14:50:49 -0400 Received: from eggs.gnu.org ([209.51.188.92]:43968) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nX63X-0005Um-ED for guix-patches@gnu.org; Wed, 23 Mar 2022 14:50:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:52124) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nX63W-000377-RT for guix-patches@gnu.org; Wed, 23 Mar 2022 14:50:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nX63W-0001Fo-OE for guix-patches@gnu.org; Wed, 23 Mar 2022 14:50:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#54539] [PATCH 1/6] gnu: audacity: Move into new module to break cycles. References: <5a87d6f772ff7424cb6fccea7c45276bef7797aa.camel@telenet.be> In-Reply-To: <5a87d6f772ff7424cb6fccea7c45276bef7797aa.camel@telenet.be> Resent-From: Maxime Devos Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 23 Mar 2022 18:50:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 54539 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 54539@debbugs.gnu.org Cc: Maxime Devos Received: via spool by 54539-submit@debbugs.gnu.org id=B54539.16480613524695 (code B ref 54539); Wed, 23 Mar 2022 18:50:02 +0000 Received: (at 54539) by debbugs.gnu.org; 23 Mar 2022 18:49:12 +0000 Received: from localhost ([127.0.0.1]:46006 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nX62i-0001DY-8e for submit@debbugs.gnu.org; Wed, 23 Mar 2022 14:49:12 -0400 Received: from baptiste.telenet-ops.be ([195.130.132.51]:33940) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nX62Z-0001Ch-I3 for 54539@debbugs.gnu.org; Wed, 23 Mar 2022 14:49:04 -0400 Received: from localhost.localdomain ([IPv6:2a02:1811:8c09:9d00:3c5f:2eff:feb0:ba5a]) by baptiste.telenet-ops.be with bizsmtp id 9up12700i4UW6Th01up2o3; Wed, 23 Mar 2022 19:49:02 +0100 From: Maxime Devos Date: Wed, 23 Mar 2022 18:48:50 +0000 Message-Id: <20220323184855.25241-1-maximedevos@telenet.be> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r22; t=1648061342; bh=j7AIw2Ij5pJjRkyWDfBZx1Jgk82zP3FRUmeYnSP81A8=; h=From:To:Cc:Subject:Date; b=ZJ7J393a3jONvxq97dOSCEPV4i6p0FMrHwfIh1/FMtIpbdYuYUuzxqrcBsbCYUIHk 1YAyuP4/Zx0r/l1sFYt+ZAAZmbed9HwUTfKZB2yZgjOdn5890CKgwewQgYlW7A32Wa 6C4mUhnlrpd1b/0tWH1cRBiytbmX2r9psnZ4sGNo9+WDBDHoKRXFoCg1EQ7T/1VHNT +u+2pXVAj5wq+uhv2kNEJ6hr8C2FdRY68wquoPrbsW9v05oxOghXnYsVBt8nFXz8PQ EH3rsXi70ukol9X4WK86iAdk1f2dpXZMdKi2C9rUwgjb2hWoiAwmbUm0lNbRrpGBXr s/LPqusjLON4A== 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 Currently, there's a cycle between ncurses, linux, audio and music. By moving audacity to its own module, 'audio' does not have to import 'music' and 'linux' anymore. Looking at the output of "guix graph --type=module", there still appears to be cycles, so this commit will not sufficient by itself. * gnu/packages/audio.scm (audacity): Move to ... * gnu/packages/audacity.scm: This new module. Remove unneeded imports from the old module. Add a few comments to the old module to discourage re-importing the 'linux' and 'music' module in the future. * gnu/local.mk (GNU_SYSTEM_MODULES): Register new module. --- gnu/local.mk | 1 + gnu/packages/audio.scm | 140 ++--------------------------------------- 2 files changed, 5 insertions(+), 136 deletions(-) base-commit: 9a31942cabb5c73174aee96ecd873fcf89955a9d prerequisite-patch-id: f64e340873270246660f566eabe4af5e20ede85f diff --git a/gnu/local.mk b/gnu/local.mk index ad39e648f7..aab22d32d4 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -112,6 +112,7 @@ GNU_SYSTEM_MODULES = \ %D%/packages/assembly.scm \ %D%/packages/astronomy.scm \ %D%/packages/attr.scm \ + %D%/packages/audacity.scm \ %D%/packages/audio.scm \ %D%/packages/augeas.scm \ %D%/packages/authentication.scm \ diff --git a/gnu/packages/audio.scm b/gnu/packages/audio.scm index 13e0f02837..d74f8de1ab 100644 --- a/gnu/packages/audio.scm +++ b/gnu/packages/audio.scm @@ -90,14 +90,16 @@ #:use-module (gnu packages libbsd) #:use-module (gnu packages libffi) #:use-module (gnu packages libusb) - #:use-module (gnu packages linux) #:use-module (gnu packages llvm) + ;; Don't import that module here, otherwise a cycle would result. + ;; #:use-module (gnu packages linux) #:use-module (gnu packages machine-learning) #:use-module (gnu packages man) #:use-module (gnu packages maths) #:use-module (gnu packages mp3) ;taglib #:use-module (gnu packages multiprecision) - #:use-module (gnu packages music) + ;; Don't import that module here, otherwise a cycle would result. + ;; #:use-module (gnu packages music) #:use-module (gnu packages ncurses) #:use-module (gnu packages networking) #:use-module (gnu packages onc-rpc) @@ -122,7 +124,6 @@ #:use-module (gnu packages vim) ;xxd #:use-module (gnu packages web) #:use-module (gnu packages webkit) - #:use-module (gnu packages wxwidgets) #:use-module (gnu packages xiph) #:use-module (gnu packages xml) #:use-module (gnu packages xorg) @@ -761,139 +762,6 @@ record, edit, mix and master audio and MIDI projects. It is targeted at audio engineers, musicians, soundtrack editors and composers.") (license license:gpl2+))) -(define-public audacity - (package - (name "audacity") - (version "3.1.3") - (source - (origin - ;; If built from the release tag, Audacity will describe itself - ;; as an "Alpha test version" and suggest to users that they use - ;; the "latest stable released version". - (method url-fetch) - (uri (string-append "https://github.com/audacity/audacity/releases/download/" - "Audacity-" version "/audacity-" version - "-source.tar.gz")) - (sha256 - (base32 - "189agx11361k9j958s6q5bngnnfx0rwaf0dwbjxy6fwvsb1wv3px")) - (patches (search-patches "audacity-ffmpeg-fallback.patch")) - (modules '((guix build utils))) - (snippet - ;; Remove bundled libraries. - '(begin - (for-each - (lambda (dir) - (delete-file-recursively (string-append "lib-src/" dir))) - '("libsoxr" "libvamp" "lv2" "soundtouch" "sqlite" "twolame" - ;; FIXME: these libraries have not been packaged yet: - ;; "libnyquist" - ;; "libscorealign" - ;; "portburn" - ;; "portsmf" - ;; "portmixer" - - ;; FIXME: we have this library, but it differs in that the Slide - ;; class does not have a member "getInverseStretchedTime". - ;; "sbsms" - )) - #t)))) - (build-system cmake-build-system) - (inputs - (list wxwidgets-3.1 - gtk+ - alsa-lib - jack-1 - expat - lame - linux-libre-headers - flac - ffmpeg - libid3tag - libjpeg-turbo - libmad - ;;("libsbsms" ,libsbsms) ;bundled version is modified - libsndfile - soundtouch - soxr ;replaces libsamplerate - sqlite - twolame - vamp - libvorbis - lv2 - lilv ;for lv2 - suil ;for lv2 - portaudio - portmidi)) - (native-inputs - `(("autoconf" ,autoconf) - ("automake" ,automake) - ("gettext" ,gettext-minimal) ;for msgfmt - ("libtool" ,libtool) - ("pkg-config" ,pkg-config) - ("python" ,python) - ("which" ,which))) - (arguments - `(#:configure-flags - (list - "-Daudacity_conan_enabled=off" - "-Daudacity_lib_preference=system" - ;; TODO: enable this flag once we've packaged all dependencies - ;; "-Daudacity_obey_system_dependencies=on" - ;; disable crash reports, updates, ..., anything that phones home - "-Daudacity_has_networking=off") - #:imported-modules ((guix build glib-or-gtk-build-system) - ,@%cmake-build-system-modules) - #:modules - ((guix build utils) - (guix build cmake-build-system) - ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:)) - #:phases - (modify-phases %standard-phases - (add-after 'unpack 'fix-cmake-rpath - (lambda* (#:key outputs #:allow-other-keys) - (substitute* "CMakeLists.txt" - (("\\$ORIGIN/\\.\\./\\$\\{_PKGLIB\\}") - (string-append (assoc-ref outputs "out") "/lib/audacity")) - (("CMAKE_BUILD_WITH_INSTALL_RPATH [A-Z]*") - "CMAKE_BUILD_WITH_INSTALL_RPATH TRUE") - (("CMAKE_INSTALL_RPATH_USE_LINK_PATH [A-Z]*") - "CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE")) - (substitute* "src/CMakeLists.txt" - (("-Wl,--disable-new-dtags") "-Wl,--enable-new-dtags")))) - (add-after 'unpack 'comment-out-revision-ident - (lambda _ - (substitute* "src/CMakeLists.txt" - (("file\\( TOUCH \".*RevisionIdent\\.h\" \\)" directive) - (string-append "# " directive))) - (substitute* "src/AboutDialog.cpp" - (("(.*RevisionIdent\\.h.*)" include-line) - (string-append "// " include-line))))) - (add-after 'unpack 'use-upstream-headers - (lambda* (#:key inputs #:allow-other-keys) - (substitute* '("libraries/lib-files/FileNames.cpp") - (("\"/usr/include/linux/magic.h\"") "")))) - (add-after 'wrap-program 'glib-or-gtk-wrap - (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap))) - ;; The test suite is not "well exercised" according to the developers, - ;; and fails with various errors. See - ;; . - #:tests? #f)) - (native-search-paths - (list (search-path-specification - (variable "AUDACITY_MODULES_PATH") - (files '("lib/audacity/modules"))) - (search-path-specification - (variable "AUDACITY_PATH") - (files '("share/audacity"))))) - (home-page "https://www.audacityteam.org/") - (synopsis "Software for recording and editing sounds") - (description - "Audacity is a multi-track audio editor designed for recording, playing -and editing digital audio. It features digital effects and spectrum analysis -tools.") - (license license:gpl2+))) - (define-public audiofile (package (name "audiofile")