atlas-engineer / cl-electron

Lisp Interface to Electron.
BSD 3-Clause "New" or "Revised" License
16 stars 1 forks source link

Install `cl-electron' via NPM. Use standard build-tools. #43

Closed jmercouris closed 4 months ago

jmercouris commented 5 months ago

This is a standard installation method that should work on Ubuntu and other conforming operating systems including macOS.

This is a draft. I am still considering removing the usage of NPX and referencing the Electron binary via an absolute path.

aadcg commented 5 months ago

Will review as soon as I'll setup Ubuntu, thanks.

aadcg commented 4 months ago

Thanks for working on this PR @jmercouris.

I took over and fixed some minor things. I've tested the setup on macOS (relying on Nix for the CL dependencies) and Linux (Ubuntu, relying on Guix for the CL dependencies).

For reference, here's how I set {sly,slime}-lisp-implementations. The double slashes in CL_SOURCE_REGISTRY recursively register the directory.

(cl-electron-guix
 ("guix" "shell" "-m" "manifest.scm" "--" "sbcl")
 ;; To use the Guix Lisp dependencies versions, comment the env below.
 :env ("CL_SOURCE_REGISTRY=~/common-lisp//:~/common-lisp/nyxt/_build//"
       "LD_LIBRARY_PATH=/gnu/store/<hash>-libfixposix-0.4.3/lib")
 :directory "~/common-lisp/cl-electron/")
(cl-electron-nix
 ("nix-shell" "--run" "sbcl --dynamic-space-size 3072")
 :env ("CL_SOURCE_REGISTRY=~/common-lisp//:~/common-lisp/nyxt/_build//")
 :directory "~/common-lisp/cl-electron/")

Tests and examples seem to run smoothly on the platforms mentioned above.

I'd like run the checks mentioned above again in a clean environment (by removing the CL and Node.JS cache).

Also, I'm taking over https://github.com/atlas-engineer/nyxt/pull/3381 and I'd like to merge these 2 PRs at once. I.e., I'll work on https://github.com/atlas-engineer/nyxt/pull/3381 with the state of this PR, check whether everything's OK, and merge both.

aadcg commented 4 months ago

Thanks @jmercouris!

jmercouris commented 4 months ago

thank you!