guix-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Packaging leiningen (feedback desired)


From: alex . ter . weele
Subject: Packaging leiningen (feedback desired)
Date: Mon, 06 Feb 2017 22:30:04 -0500

If anyone's around, I would appreciate some feedback. I'm trying to
package leiningen, a build tool for clojure projects. The recommended
way to manually install leiningen is to use a script that will download
a .jar
(https://github.com/technomancy/leiningen/blob/stable/bin/lein#L65). This
is also the recommended way to bootstrap: use an older version of
leiningen to build the newer version
(https://github.com/technomancy/leiningen/blob/stable/CONTRIBUTING.md#bootstrapping).

Other distributions, even Nix, use this approach for their leiningen
package. Download the .jar and the "lein" script and put them in the
appropriate places
(https://github.com/technomancy/leiningen/wiki/Packaging).
  * 
https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/tools/build-managers/leiningen/default.nix
  * 
https://gitweb.gentoo.org/repo/gentoo.git/tree/dev-java/leiningen-bin/leiningen-bin-2.7.1.ebuild

Anyway, I'm trying to do this right, so my plan is to make a
leiningen-bootstrap package (based on an old version of leiningen) that
will be built "manually", then using that to build a modern
leiningen. Is this the right idea?

I'm also running into some problems with either the clojure or the
icedtea packages, manifesting as "Could not find or load main class":

bash-4.4$ guix environment --ad-hoc clojure
bash-4.4$ java -cp $GUIX_ENVIRONMENT/share/java/ clojure.main
bash: java: command not found
bash-4.4$ exit
bash-4.4$ guix environment clojure
bash-4.4$ java -cp clojure-1.8.0.jar clojure.main
Error: Could not find or load main class clojure.main
bash-4.4$ file clojure-1.8.0.jar 
clojure-1.8.0.jar: Zip archive data, at least v1.0 to extract
bash-4.4$ clojure
bash: clojure: command not found

(I'm trying to emulate https://clojure.org/guides/getting_started here.)

It is unclear to me how the current clojure package is meant to be
used. Could someone clarify that? Ricardo, I believe you reviewed the
patch to add the package...any ideas?

Thanks,
Alex



reply via email to

[Prev in Thread] Current Thread [Next in Thread]