~ruther/guix-local

2c47027d02491d739706f89df934f9107366093e — Sughosha 1 year, 4 months ago 80065cb
gnu: carla: Make carla executable.

This commit allows lmms to launch carla.

* gnu/packages/audio.scm (carla)[arguments]<#:phases>: In make-carla-executable
phase, also make carla-control, carla-jack-multi, carla-jack-single,
carla-patchbay and carla-rack executable. In wrap-executables phase, also wrap
the other executables.

Change-Id: I42dee1070d467ca0aa292a4b5a412bece6c1a489
1 files changed, 23 insertions(+), 5 deletions(-)

M gnu/packages/audio.scm
M gnu/packages/audio.scm => gnu/packages/audio.scm +23 -5
@@ 6533,12 6533,30 @@ as is the case with audio plugins.")
                   (invoke "make" "features")))
               (add-after 'install 'make-carla-executable
                 (lambda _
                   (chmod (string-append #$output "/share/carla/carla") #o555)))
                   (with-directory-excursion (string-append #$output
                                                           "/share/carla")
                     (for-each (lambda (file)
                                 (chmod file #o555))
                               (list "carla"
                                     "carla-control"
                                     "carla-jack-multi"
                                     "carla-jack-single"
                                     "carla-patchbay"
                                     "carla-rack")))))
               (add-after 'install 'wrap-executables
                 (lambda _
                   (wrap-program (string-append #$output "/bin/carla")
                     `("GUIX_PYTHONPATH" ":" prefix
                       (,(getenv "GUIX_PYTHONPATH")))))))))
                 (lambda* (#:key inputs #:allow-other-keys)
                   ;; Wrap only those executable files that other programs
                   ;; (e.g. lmms) would call.
                   (with-directory-excursion #$output
                     (for-each (lambda (file)
                                 (when (and (executable-file? file)
                                            (not (symbolic-link? file))
                                            (not (string-suffix? ".py" file)))
                                   (wrap-program file
                                     `("GUIX_PYTHONPATH" ":" prefix
                                       (,(getenv "GUIX_PYTHONPATH"))))))
                               (append (find-files "share/carla/resources")
                                       (find-files "bin")))))))))
    (inputs
     (list alsa-lib
           ffmpeg