* [PATCH] Fix Ardour build.
@ 2015-05-11 18:27 Ricardo Wurmus
2015-05-11 19:14 ` Ludovic Courtès
0 siblings, 1 reply; 2+ messages in thread
From: Ricardo Wurmus @ 2015-05-11 18:27 UTC (permalink / raw)
To: Guix-devel
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: 0001-gnu-ardour-Extract-RUNPATH-phase.patch --]
[-- Type: text/x-patch, Size: 3697 bytes --]
From d17b74b96eb96fa20a0b685983bff0283325878d Mon Sep 17 00:00:00 2001
From: Ricardo Wurmus <rekado@elephly.net>
Date: Mon, 11 May 2015 20:24:59 +0200
Subject: [PATCH] gnu: ardour: Extract RUNPATH phase.
* gnu/packages/audio.scm (ardour-rpath-phase): New procedure.
* gnu/packages/audio.scm (ardour, ardour-3): Generate version-dependent build
phase with ardour-rpath-phase.
---
gnu/packages/audio.scm | 44 +++++++++++++++++++++++++-------------------
1 file changed, 25 insertions(+), 19 deletions(-)
diff --git a/gnu/packages/audio.scm b/gnu/packages/audio.scm
index 543fe49..e15381b 100644
--- a/gnu/packages/audio.scm
+++ b/gnu/packages/audio.scm
@@ -21,6 +21,7 @@
#:use-module (guix packages)
#:use-module (guix download)
#:use-module (guix git-download)
+ #:use-module (guix utils)
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix build-system gnu)
#:use-module (guix build-system waf)
@@ -128,6 +129,22 @@ attacks, performing pitch detection, tapping the beat and producing MIDI
streams from live audio.")
(license license:gpl3+)))
+(define (ardour-rpath-phase major-version)
+ `(lambda* (#:key outputs #:allow-other-keys)
+ (let ((libdir (string-append (assoc-ref outputs "out")
+ "/lib/ardour" ,major-version)))
+ (substitute* "wscript"
+ (("linker_flags = \\[\\]")
+ (string-append "linker_flags = [\""
+ "-Wl,-rpath="
+ libdir ":"
+ libdir "/backends" ":"
+ libdir "/engines" ":"
+ libdir "/panners" ":"
+ libdir "/surfaces" ":"
+ libdir "/vamp" "\"]"))))
+ #t))
+
(define-public ardour-3
(package
(name "ardour")
@@ -158,24 +175,7 @@ namespace ARDOUR { const char* revision = \"3.5-403-gec2cb31\" ; }"))))
(modify-phases %standard-phases
(add-after
'unpack 'set-rpath-in-LDFLAGS
- (lambda _
- (substitute* "wscript"
- (("linker_flags = \\[\\]")
- (string-append "linker_flags = [\""
- "-Wl,-rpath="
- (assoc-ref %outputs "out")
- "/lib/ardour3/" ":"
- (assoc-ref %outputs "out")
- "/lib/ardour3/backends" ":"
- (assoc-ref %outputs "out")
- "/lib/ardour3/engines" ":"
- (assoc-ref %outputs "out")
- "/lib/ardour3/panners" ":"
- (assoc-ref %outputs "out")
- "/lib/ardour3/surfaces" ":"
- (assoc-ref %outputs "out")
- "/lib/ardour3/vamp" "\"]")))
- #t)))
+ ,(ardour-rpath-phase (version-prefix version 1))))
#:tests? #f ; no check target
#:python ,python-2))
(inputs
@@ -246,7 +246,13 @@ namespace ARDOUR { const char* revision = \"4.0\" ; }"))))
(sha256
(base32
"0a8bydc24xv0cahdqfaxdmi1f43cyr9psiyshxpbrkdqw2c7a4xi"))
- (file-name (string-append name "-" version))))))
+ (file-name (string-append name "-" version))))
+ (arguments
+ (substitute-keyword-arguments (package-arguments ardour-3)
+ ((#:phases phases)
+ `(modify-phases ,phases
+ (replace 'set-rpath-in-LDFLAGS
+ ,(ardour-rpath-phase (version-prefix version 1)))))))))
(define-public azr3
(package
--
2.1.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] Fix Ardour build.
2015-05-11 18:27 [PATCH] Fix Ardour build Ricardo Wurmus
@ 2015-05-11 19:14 ` Ludovic Courtès
0 siblings, 0 replies; 2+ messages in thread
From: Ludovic Courtès @ 2015-05-11 19:14 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: Guix-devel
Ricardo Wurmus <rekado@elephly.net> skribis:
> From d17b74b96eb96fa20a0b685983bff0283325878d Mon Sep 17 00:00:00 2001
> From: Ricardo Wurmus <rekado@elephly.net>
> Date: Mon, 11 May 2015 20:24:59 +0200
> Subject: [PATCH] gnu: ardour: Extract RUNPATH phase.
>
> * gnu/packages/audio.scm (ardour-rpath-phase): New procedure.
> * gnu/packages/audio.scm (ardour, ardour-3): Generate version-dependent build
> phase with ardour-rpath-phase.
Sure, LGTM.
Ludo’.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-05-11 19:14 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-11 18:27 [PATCH] Fix Ardour build Ricardo Wurmus
2015-05-11 19:14 ` Ludovic Courtès
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).