17 stdenv.mkDerivation rec {
23 "https://ftp.regressive.org/snobol4/snobol4-${version}.tar.gz"
24 # fallback for when the current version is moved to the old folder
25 "https://ftp.regressive.org/snobol4/old/snobol4-${version}.tar.gz"
27 hash = "sha256-kSRNZ9TinSqtzlZVvUOC/6tExiSn6krWQRQn86vxdTU=";
30 outputs = [ "out" "man" "doc" ];
32 # gzip used by Makefile to compress man pages
33 nativeBuildInputs = [ gnum4 gzip ];
34 # enable all features (undocumented, based on manual review of configure script)
35 buildInputs = [ bzip2 libffi openssl readline sqlite tcl xz zlib ]
37 ++ lib.optional stdenv.isLinux gdbm;
38 configureFlags = lib.optional (tcl != null) "--with-tcl=${tcl}/lib/tclConfig.sh";
40 # INSTALL says "parallel make will fail"
41 enableParallelBuilding = false;
43 patches = [ ./fix-paths.patch ];
45 # configure does not support --sbindir and the likes (as introduced by multiple-outputs.sh)
46 # so man, doc outputs must be handled manually
47 preConfigurePhases = [ "prePreConfigurePhase" ];
48 prePreConfigurePhase = ''
49 preConfigureHooks="''${preConfigureHooks//_multioutConfig/}"
50 prependToVar configureFlags --mandir="$man"/share/man
54 description = "The Macro Implementation of SNOBOL4 in C";
56 An open source port of Macro SNOBOL4 (The original Bell Telephone Labs implementation, written in SIL macros) by Phil Budne.
57 Supports full SNOBOL4 language plus SPITBOL, [Blocks](https://www.regressive.org/snobol4/blocks/) and other extensions.
59 homepage = "https://www.regressive.org/snobol4/csnobol4/";
60 license = licenses.bsd2;
61 platforms = platforms.all;
62 maintainers = with maintainers; [ xworld21 ];