gnu: emacs-ledger-mode: Simplify build.
* gnu/packages/finance.scm (emacs-ledger-mode) [build-system]: Use emacs-build-system instead of cmake. [arguments]: Remove modules and imported-modules; move patch-path phase to after unpack so that the substitution actually causes a change; remove generate-autoload phase as that's built into the build system; remove patch-site-dir as that only affected cmake things; set #:exclude to '() so we install ledger-test.el. [native-inputs]: Remove emacs-minimal. Signed-off-by: Nicolas Goaziou <mail@nicolasgoaziou.fr>master
parent
46eac03e72
commit
f84ce99dcc
|
@ -400,22 +400,13 @@ in ability, and easy to use.")
|
||||||
(file-name (git-file-name name version))
|
(file-name (git-file-name name version))
|
||||||
(sha256
|
(sha256
|
||||||
(base32 "1r5rcyxd6d1rqwamzpvqdbkbdf1zbj75aaciqijrklnm59ps244y"))))
|
(base32 "1r5rcyxd6d1rqwamzpvqdbkbdf1zbj75aaciqijrklnm59ps244y"))))
|
||||||
(build-system cmake-build-system)
|
(build-system emacs-build-system)
|
||||||
(arguments
|
(arguments
|
||||||
`(#:modules ((guix build cmake-build-system)
|
`(;; ledger-test.el is needed at runtime (but probably not for a good reason).
|
||||||
(guix build utils)
|
#:exclude '()
|
||||||
(guix build emacs-utils))
|
|
||||||
#:imported-modules (,@%cmake-build-system-modules
|
|
||||||
(guix build emacs-utils))
|
|
||||||
#:phases
|
#:phases
|
||||||
(modify-phases %standard-phases
|
(modify-phases %standard-phases
|
||||||
(add-after 'unpack 'patch-site-dir
|
(add-after 'unpack 'patch-path
|
||||||
(lambda _
|
|
||||||
(substitute* "CMakeLists.txt"
|
|
||||||
(("DESTINATION share/emacs/site-lisp/ledger-mode")
|
|
||||||
"DESTINATION share/emacs/site-lisp"))
|
|
||||||
#t))
|
|
||||||
(add-before 'build 'patch-path
|
|
||||||
(lambda* (#:key inputs #:allow-other-keys)
|
(lambda* (#:key inputs #:allow-other-keys)
|
||||||
(let ((ledger (assoc-ref inputs "ledger")))
|
(let ((ledger (assoc-ref inputs "ledger")))
|
||||||
(make-file-writable "ledger-exec.el")
|
(make-file-writable "ledger-exec.el")
|
||||||
|
@ -430,12 +421,6 @@ in ability, and easy to use.")
|
||||||
(invoke "makeinfo" "-o" target
|
(invoke "makeinfo" "-o" target
|
||||||
"../source/doc/ledger-mode.texi"))
|
"../source/doc/ledger-mode.texi"))
|
||||||
#t))
|
#t))
|
||||||
(add-after 'install 'generate-autoload
|
|
||||||
(lambda* (#:key outputs #:allow-other-keys)
|
|
||||||
(let* ((site-dir (string-append (assoc-ref outputs "out")
|
|
||||||
"/share/emacs/site-lisp")))
|
|
||||||
(emacs-generate-autoloads ,name site-dir))
|
|
||||||
#t))
|
|
||||||
(replace 'check
|
(replace 'check
|
||||||
(lambda _
|
(lambda _
|
||||||
(with-directory-excursion "../source/test"
|
(with-directory-excursion "../source/test"
|
||||||
|
@ -443,8 +428,7 @@ in ability, and easy to use.")
|
||||||
(inputs
|
(inputs
|
||||||
`(("ledger" ,ledger)))
|
`(("ledger" ,ledger)))
|
||||||
(native-inputs
|
(native-inputs
|
||||||
`(("emacs-minimal" ,emacs-minimal)
|
`(("texinfo" ,texinfo)))
|
||||||
("texinfo" ,texinfo)))
|
|
||||||
(home-page "https://ledger-cli.org/")
|
(home-page "https://ledger-cli.org/")
|
||||||
(synopsis "Command-line double-entry accounting program")
|
(synopsis "Command-line double-entry accounting program")
|
||||||
(description
|
(description
|
||||||
|
|
Reference in New Issue