me
/
guix
Archived
1
0
Fork 0

gnu: lepton-eda: Update to 1.9.18-20220529.

* gnu/packages/engineering.scm (lepton-eda): Update to 1.9.18-20220529.
[inputs]: Add guile-readline.
[arguments]: Adjust build phase 'fix-dynamic-link; add build phase 'fix-tests.
master
Ricardo Wurmus 2023-03-20 23:58:26 +01:00
parent fa0c6defeb
commit d2ae00530b
No known key found for this signature in database
GPG Key ID: 197A5888235FACAC
1 changed files with 36 additions and 23 deletions

View File

@ -298,7 +298,7 @@ utilities.")
(package (package
(inherit geda-gaf) (inherit geda-gaf)
(name "lepton-eda") (name "lepton-eda")
(version "1.9.14-20210407") (version "1.9.18-20220529")
(home-page "https://github.com/lepton-eda/lepton-eda") (home-page "https://github.com/lepton-eda/lepton-eda")
(source (origin (source (origin
(method git-fetch) (method git-fetch)
@ -307,7 +307,7 @@ utilities.")
(commit version))) (commit version)))
(sha256 (sha256
(base32 (base32
"0kyq0g6271vlwraw98637fn8bq2l6q4rll6748nn8rwsmfz71d0m")) "06plrcab3s2rpyf0qv2gzc1yp33627xi8105niasgixckk6glnc2"))
(file-name (git-file-name name version)))) (file-name (git-file-name name version))))
(arguments (arguments
(list (list
@ -328,28 +328,40 @@ utilities.")
"CFLAGS=-fcommon")) "CFLAGS=-fcommon"))
#:phases #:phases
#~(modify-phases %standard-phases #~(modify-phases %standard-phases
(add-after 'unpack 'fix-tests
(lambda _
;; For logs and auto-compilation
(setenv "HOME" "/tmp")
;; Ensure that readline is found by lepton-shell
(substitute* "script.in"
(("\\(eval-when \\(expand load eval\\)" m)
(string-append "
(add-to-load-path \"" #$(this-package-input "guile-readline")
"/share/guile/site/3.0\")
(set! %load-compiled-path (cons \""
#$(this-package-input "guile-readline")
"/lib/guile/3.0/site-ccache/"
"\" %load-compiled-path))
" m)))))
(add-before 'build 'fix-dynamic-link (add-before 'build 'fix-dynamic-link
(lambda* (#:key inputs outputs #:allow-other-keys) (lambda* (#:key inputs #:allow-other-keys)
(substitute* "libleptongui/scheme/schematic/ffi.scm.in" (substitute* "liblepton/scheme/lepton/ffi/lib.scm"
(("@LIBLEPTONGUI@") (("\"liblepton\"")
(string-append #$output "/lib/libleptongui.so"))) (string-append "\"" #$output "/lib/liblepton.so" "\""))
(substitute* '("libleptongui/scheme/schematic/ffi/gtk.scm.in" (("\"libleptonattrib\"")
"utils/attrib/lepton-attrib.scm") (string-append "\"" #$output "/lib/libleptonattrib.so" "\""))
(("@LIBGTK@") (("\"libleptongui\"")
(search-input-file inputs "/lib/libgtk-3.so"))) (string-append "\"" #$output "/lib/libleptongui.so" "\""))
(substitute* '("libleptongui/scheme/schematic/ffi/gobject.scm.in") (("\"libglib-2.0\"")
(("@LIBGOBJECT@") (string-append
(search-input-file inputs "/lib/libgobject-2.0.so"))) "\"" (search-input-file inputs "/lib/libglib-2.0.so") "\""))
(substitute* "liblepton/scheme/lepton/ffi.scm.in" (("\"libgobject-2.0\"")
(("@LIBLEPTON@") (string-append
(string-append #$output "/lib/liblepton.so"))) "\"" (search-input-file inputs "/lib/libgobject-2.0.so") "\""))
(substitute* "utils/attrib/lepton-attrib.scm" (("\"libgtk-3\"")
(("@LIBLEPTONATTRIB@") (string-append
(string-append (assoc-ref outputs "out") "\"" (search-input-file inputs "/lib/libgtk-3.so") "\"")))
"/lib/libleptonattrib.so")))
(substitute* "liblepton/scheme/lepton/log.scm.in"
(("@LIBGLIB@")
(search-input-file inputs "/lib/libglib-2.0.so")))
;; For finding libraries when running tests before installation. ;; For finding libraries when running tests before installation.
(setenv "LIBLEPTONGUI" (setenv "LIBLEPTONGUI"
@ -408,6 +420,7 @@ utilities.")
gtk+ gtk+
gtksheet gtksheet
guile-3.0 guile-3.0
guile-readline
shared-mime-info shared-mime-info
m4 m4
pcb)) pcb))