* [bug#31401] [PATCH] gnu: guile-dbi: Fix RPATH and dependencies.
@ 2018-05-10 10:11 Arun Isaac
2018-05-11 15:38 ` Ludovic Courtès
0 siblings, 1 reply; 3+ messages in thread
From: Arun Isaac @ 2018-05-10 10:11 UTC (permalink / raw)
To: 31401
Prior to this change, libguile-dbi.so was unable to find
libguile-dbd-sqlite3.so.
* gnu/packages/guile.scm (guile-dbi-bootstrap): New variable.
(guile-dbd-sqlite3)[propagated-inputs]: Remove guile-dbi.
[native-inputs]: Add guile-dbi-bootstrap.
(guile-dbi)[inputs]: Add guile-dbd-sqlite3.
[arguments]: Set RPATH using #:make-flags.
---
gnu/packages/guile.scm | 20 +++++++++++++++++---
1 file changed, 17 insertions(+), 3 deletions(-)
diff --git a/gnu/packages/guile.scm b/gnu/packages/guile.scm
index 38076081b..00b4f52ab 100644
--- a/gnu/packages/guile.scm
+++ b/gnu/packages/guile.scm
@@ -17,6 +17,7 @@
;;; Copyright © 2017 Nils Gillmann <ng0@n0.is>
;;; Copyright © 2017 Tobias Geerinckx-Rice <me@tobias.gr>
;;; Copyright © 2018 Maxim Cournoyer <maxim.cournoyer@gmail.com>
+;;; Copyright © 2018 Arun Isaac <arunisaac@systemreboot.net>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -1549,6 +1550,9 @@ provides access to that interface and its types from the Scheme level.")
'(#:configure-flags
(list (string-append
"--with-guile-site-dir=" %output "/share/guile/site/2.2"))
+ #:make-flags
+ (list (string-append "LDFLAGS=-Wl,-rpath=" %output "/lib:"
+ (assoc-ref %build-inputs "guile-dbd-sqlite3") "/lib"))
#:phases
(modify-phases %standard-phases
(add-after 'install 'patch-extension-path
@@ -1559,6 +1563,8 @@ provides access to that interface and its types from the Scheme level.")
(ext (string-append out "/lib/libguile-dbi")))
(substitute* dbi.scm (("libguile-dbi") ext))
#t))))))
+ (inputs
+ `(("guile-dbd-sqlite3" ,guile-dbd-sqlite3))) ; only shared library, no scheme files
(propagated-inputs
`(("guile" ,guile-2.2)))
(synopsis "Guile database abstraction layer")
@@ -1570,6 +1576,15 @@ programming interface is presented regardless of which database system is used.
It currently supports MySQL, Postgres and SQLite3.")
(license license:gpl2+)))
+(define-public guile-dbi-bootstrap
+ (package
+ (inherit guile-dbi)
+ (name "guile-dbi-bootstrap")
+ (inputs '())
+ (arguments
+ (substitute-keyword-arguments (package-arguments guile-dbi)
+ ((#:make-flags _) '(list))))))
+
(define-public guile-dbd-sqlite3
(package
(name "guile-dbd-sqlite3")
@@ -1584,12 +1599,11 @@ It currently supports MySQL, Postgres and SQLite3.")
"0rg71jchxd2y8x496s8zmfmikr5g8zxi8zv2ar3f7a23pph92iw2"))))
(build-system gnu-build-system)
(native-inputs
- `(("pkg-config" ,pkg-config)))
+ `(("pkg-config" ,pkg-config)
+ ("guile-dbi-bootstrap" ,guile-dbi-bootstrap))) ; only required for headers
(inputs
`(("sqlite" ,sqlite)
("zlib" ,(@ (gnu packages compression) zlib))))
- (propagated-inputs
- `(("guile-dbi" ,guile-dbi)))
(synopsis "Guile DBI driver for SQLite")
(home-page "https://github.com/jkalbhenn/guile-dbd-sqlite3")
(description
--
2.15.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [bug#31401] [PATCH] gnu: guile-dbi: Fix RPATH and dependencies.
2018-05-10 10:11 [bug#31401] [PATCH] gnu: guile-dbi: Fix RPATH and dependencies Arun Isaac
@ 2018-05-11 15:38 ` Ludovic Courtès
2018-05-14 13:55 ` bug#31401: " Arun Isaac
0 siblings, 1 reply; 3+ messages in thread
From: Ludovic Courtès @ 2018-05-11 15:38 UTC (permalink / raw)
To: Arun Isaac; +Cc: 31401
Hello,
Arun Isaac <arunisaac@systemreboot.net> skribis:
> Prior to this change, libguile-dbi.so was unable to find
> libguile-dbd-sqlite3.so.
>
> * gnu/packages/guile.scm (guile-dbi-bootstrap): New variable.
> (guile-dbd-sqlite3)[propagated-inputs]: Remove guile-dbi.
> [native-inputs]: Add guile-dbi-bootstrap.
> (guile-dbi)[inputs]: Add guile-dbd-sqlite3.
> [arguments]: Set RPATH using #:make-flags.
[...]
> +(define-public guile-dbi-bootstrap
You can probably s/define-public/define/. Otherwise LGTM, thanks!
Ludo’.
^ permalink raw reply [flat|nested] 3+ messages in thread
* bug#31401: [PATCH] gnu: guile-dbi: Fix RPATH and dependencies.
2018-05-11 15:38 ` Ludovic Courtès
@ 2018-05-14 13:55 ` Arun Isaac
0 siblings, 0 replies; 3+ messages in thread
From: Arun Isaac @ 2018-05-14 13:55 UTC (permalink / raw)
To: Ludovic Courtès; +Cc: 31401-done
>> +(define-public guile-dbi-bootstrap
>
> You can probably s/define-public/define/. Otherwise LGTM, thanks!
Pushed with the above change. Thanks!
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2018-05-14 13:57 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-05-10 10:11 [bug#31401] [PATCH] gnu: guile-dbi: Fix RPATH and dependencies Arun Isaac
2018-05-11 15:38 ` Ludovic Courtès
2018-05-14 13:55 ` bug#31401: " Arun Isaac
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.