gnu: emacs-edbi: Adjust to changes in emacs-build-system.
authorLeo Prikler <leo.prikler@student.tugraz.at>
Sat, 17 Apr 2021 17:06:32 +0000 (19:06 +0200)
committerLeo Prikler <leo.prikler@student.tugraz.at>
Sat, 1 May 2021 13:56:40 +0000 (15:56 +0200)
* gnu/packages/emacs-xyz.scm (emacs-edbi)[patch-path]: Execute after unpack.
[wrap-edbi-bridge]: New phase (after wrap).  Find edbi-bridge in elpa-directory.

gnu/packages/emacs-xyz.scm

index b9212ae..44f85f1 100644 (file)
@@ -21593,17 +21593,21 @@ asynchronous communications, the RPC response is fairly good.")
        `(#:include '("\\.el$" "\\.pl$")
          #:phases
          (modify-phases %standard-phases
-           (add-after 'install 'patch-path
-             (lambda* (#:key inputs outputs #:allow-other-keys)
-               (let ((perl (assoc-ref inputs "perl"))
-                     (dir (string-append  (assoc-ref outputs "out")
-                                          "/share/emacs/site-lisp")))
-                 (substitute* (string-append dir  "/edbi.el")
+           (add-after 'unpack 'patch-path
+             (lambda* (#:key inputs #:allow-other-keys)
+               (let ((perl (assoc-ref inputs "perl")))
+                 (substitute* "edbi.el"
                    (("\"perl\"") (string-append "\"" perl "/bin/perl\"")))
-                 (chmod (string-append dir "/edbi-bridge.pl") #o555)
-                 (wrap-program (string-append dir "/edbi-bridge.pl")
-                   `("PERL5LIB" ":" prefix (,(getenv "PERL5LIB"))))
-                 #t))))))
+                 #t)))
+           (add-after 'wrap 'wrap-edbi-bridge
+             (lambda* (#:key inputs outputs #:allow-other-keys)
+               (let* ((out (assoc-ref outputs "out"))
+                      (bridge (string-append (elpa-directory out)
+                                             "/edbi-bridge.pl")))
+                 (chmod bridge #o555)
+                 (wrap-program bridge
+                   `("PERL5LIB" ":" prefix (,(getenv "PERL5LIB")))))
+               #t)))))
       (synopsis "Database Interface for Emacs Lisp")
       (description "This program connects the database server through Perl's
 DBI, and provides DB-accessing API and the simple management UI.")