Merge pull request #302937 from nat-418/update-picolisp

picolisp 20.6 -> 24.3.30

authored by 7c6f434c and committed by GitHub 375367fb ae88d86b

+33 -50
+33 -50
pkgs/development/interpreters/picolisp/default.nix
··· 1 - { lib, stdenv, fetchurl, jdk, w3m, openssl, makeWrapper }: 1 + { 2 + clang, 3 + fetchurl, 4 + lib, 5 + libffi, 6 + llvm, 7 + makeWrapper, 8 + openssl, 9 + pkg-config, 10 + readline, 11 + stdenv 12 + }: 2 13 3 - stdenv.mkDerivation rec { 4 - pname = "picoLisp"; 5 - version = "20.6"; 14 + stdenv.mkDerivation { 15 + pname = "PicoLisp"; 16 + version = "24.3.30"; 6 17 src = fetchurl { 7 - url = "https://www.software-lab.de/${pname}-${version}.tgz"; 8 - sha256 = "0l51x98bn1hh6kv40sdgp0x09pzg5i8yxbcjvm9n5bxsd6bbk5w2"; 18 + url = "https://www.software-lab.de/picoLisp-24.3.tgz"; 19 + sha256 = "sha256-FB43DAjHBFgxdysoLzBXLxii52a2CCh1skZP/RTzfdc="; 9 20 }; 21 + 10 22 nativeBuildInputs = [ makeWrapper ]; 11 - buildInputs = [openssl] ++ lib.optional stdenv.is64bit jdk; 12 - patchPhase = '' 13 - sed -i "s/which java/command -v java/g" mkAsm 23 + buildInputs = [ clang libffi llvm openssl pkg-config readline ]; 24 + sourceRoot = ''pil21''; 25 + buildPhase = '' 26 + cd src 27 + make 28 + ''; 14 29 15 - ${lib.optionalString stdenv.isAarch32 '' 16 - sed -i s/-m32//g Makefile 17 - cat >>Makefile <<EOF 18 - ext.o: ext.c 19 - \$(CC) \$(CFLAGS) -fPIC -D_OS='"\$(OS)"' \$*.c 20 - ht.o: ht.c 21 - \$(CC) \$(CFLAGS) -fPIC -D_OS='"\$(OS)"' \$*.c 22 - EOF 23 - ''} 24 - ''; 25 - sourceRoot = ''picoLisp/src${lib.optionalString stdenv.is64bit "64"}''; 26 - postBuild = '' 27 - cd ../src; make gate 28 - ''; 29 30 installPhase = '' 30 31 cd .. 31 - 32 - mkdir -p "$out/share/picolisp" "$out/lib" "$out/bin" 33 - cp -r . "$out/share/picolisp/build-dir" 34 - ln -s "$out/share/picolisp/build-dir" "$out/lib/picolisp" 32 + mkdir -p "$out/lib" "$out/bin" "$out/man" 33 + cp -r . "$out/lib/picolisp/" 35 34 ln -s "$out/lib/picolisp/bin/picolisp" "$out/bin/picolisp" 36 - ln -s "$out/lib/picolisp/bin/httpGate" "$out/bin/httpGate" 37 - 38 - 39 - makeWrapper $out/bin/picolisp $out/bin/pil \ 40 - --prefix PATH : ${w3m}/bin \ 41 - --add-flags "$out/lib/picolisp/lib.l" \ 42 - --add-flags "@lib/misc.l" \ 43 - --add-flags "@lib/btree.l" \ 44 - --add-flags "@lib/db.l" \ 45 - --add-flags "@lib/pilog.l" 46 - 47 - mkdir -p "$out/share/emacs" 48 - ln -s "$out/lib/picolisp/lib/el" "$out/share/emacs/site-lisp" 35 + ln -s "$out/lib/picolisp/bin/pil" "$out/bin/pil" 36 + ln -s "$out/lib/picolisp/man/man1/pil.1" "$out/man/pil.1" 37 + ln -s "$out/lib/picolisp/man/man1/picolisp.1" "$out/man/picolisp.1" 38 + substituteInPlace $out/bin/pil --replace /usr $out 49 39 ''; 50 40 51 41 meta = with lib; { 52 - # darwin: build times out 53 - broken = (stdenv.isLinux && stdenv.isAarch64) || stdenv.isDarwin; 54 - description = "A simple Lisp with an integrated database"; 42 + description = "A pragmatic programming language."; 55 43 homepage = "https://picolisp.com/"; 56 44 license = licenses.mit; 57 - maintainers = with maintainers; [ raskin ]; 45 + maintainers = with maintainers; [ nat-418 ]; 58 46 platforms = platforms.all; 59 47 }; 60 - 61 - passthru = { 62 - updateInfo = { 63 - downloadPage = "https://www.software-lab.de/down.html"; 64 - }; 65 - }; 66 48 } 49 +