Subject: [v2] gnu: Audacity: Use glib-or-gtk-build-system instead of a wrapper.

From: Leo Famulari <[email-masked]>
Date: Mon, 1 Oct 2018 17:08:41 -0400

The reason the build failed unexpectedly with glib-or-gtk-build-system
is that that build system sets #:out-of-source #t by default, unlike the 
gnu-build-system.

The Audacity build process doesn't handle this properly when generating
Makefiles for the translations.

Audacity works for me with this patch. I haven't pushed yet because I
don't know why glib-or-gtk-build-system builds out of source by default,
so I don't know if it's really a good idea to do it this way.

* gnu/packages/audio.scm (audacity)[build-system]: Use glib-or-gtk-build-system.
[arguments]: Remove the 'wrap-program' phase. Set #:out-of-source #f.
---
 gnu/packages/audio.scm | 14 ++++----------
 1 file changed, 4 insertions(+), 10 deletions(-)

diff --git a/gnu/packages/audio.scm b/gnu/packages/audio.scm
index 446587273..933138e11 100644
--- a/gnu/packages/audio.scm
+++ b/gnu/packages/audio.scm
@@ -321,7 +321,7 @@ engineers, musicians, soundtrack editors and composers.")
               ;; "sbsms"
               ))
            #t))))
-    (build-system gnu-build-system)
+    (build-system glib-or-gtk-build-system)
     (inputs
      `(("wxwidgets" ,wxwidgets)
        ("gtk+" ,gtk+)
@@ -410,16 +410,10 @@ engineers, musicians, soundtrack editors and composers.")
                (("../lib-src/portmidi/porttime/porttime.h") "porttime.h"))
              (substitute* "src/prefs/MidiIOPrefs.cpp"
                (("../../lib-src/portmidi/pm_common/portmidi.h") "portmidi.h"))
-             #t))
-         (add-after 'install 'wrap-program
-           (lambda* (#:key inputs outputs #:allow-other-keys)
-             (wrap-program (string-append (assoc-ref outputs "out")
-                                          "/bin/audacity")
-               ;; For GtkFileChooserDialog.
-               `("GSETTINGS_SCHEMA_DIR" =
-                 (,(string-append (assoc-ref inputs "gtk+")
-                                  "/share/glib-2.0/schemas"))))
              #t)))
+       ;; The translation Makefile generation is performed improperly for
+       ;; out-of-tree builds.
+       #:out-of-source? #f
        ;; The test suite is not "well exercised" according to the developers,
        ;; and fails with various errors.  See
        ;; <http://sourceforge.net/p/audacity/mailman/message/33524292/>.
-- 
2.19.0