@m3tti In SBCL, that's what I've done, with a shell script to start it or you can just call it from REPL. I have Ideas for using ECL.
In Chez Scheme supposedly I can make a universal binary and then just include the runtime blob, but in practice it's fiddly work on each platform, so right now Mac works great, others are tough.
Kawa Scheme was a little setup work and then I can just make a jar that works everywhere, I bet ABCL is similar.
#lisp #scheme #ecl
Need help from Lisp wizards — looks like I'm missing something simple and obvious (but not so obvious for beginner). I'm trying to build (with ECL) the simple program, which uses ql:quickload to load parse-number, then prints "Hello world". It builds without errors, but resulting binary could not be executed — it prints error message about unknown "ql:quickload" function.
QuickLisp was installed like described in the official documentation. It works in SBCL, it works in ECL REPL and it has the necessary lines in the ~/.eclrc:
;;; The following lines added by ql:add-to-init-file:
#-quicklisp
(let ((quicklisp-init (merge-pathnames "quicklisp/setup.lisp"
(user-homedir-pathname))))
(when (probe-file quicklisp-init)
(load quicklisp-init)))
(ql:quickload '(:slite) :silent t)
The program, itself, runs successfully if I just evaluate the next code in the REPL:
(ql:quickload '(:parse-number) :silent t)
(defpackage :test
(:use :cl))
(in-package :test)
(defun toplevel ()
(print "Hello world"))
(progn
(toplevel)
(ext:quit))
And it compiles:
ecl --eval '(progn (compile-file "test.lisp" :system-p t) (c:build-program "test" :lisp-files '"'"'("test.o")) (quit))'
;;; Loading #P"/home/drag0n/quicklisp/setup.lisp"
;;; Loading #P"/usr/local/lib/ecl-24.5.10/asdf.fas"
;;;
;;; Compiling test.lisp.
;;; OPTIMIZE levels: Safety=2, Space=0, Speed=3, Debug=0
;;;
;;; Finished compiling test.lisp.
;;;
But doesn't print "Hello world":
./test
Condition of type: UNDEFINED-FUNCTION
The function QUICKLISP-CLIENT::QUICKLOAD is undefined.
No restarts available.
Top level in: #<process TOP-LEVEL 0x8295a3f80>.
>
Just use a #ProgrammingLanguage that isn’t popular (e.g. #Haskell or some #Lisp dialect) to write your code, but publish human-readable intermediate form of that code in the public code repositories (e.g. the C programming language). Share the actual source code privately with trusted contributors in non-public branches, and require GPG signatures on actual contributions.
You could argue that not sharing source code is against the GPL, but the GPL does allow you to share the code as a hard copy printed on paper and sent over snail mail. Or you can just wait until the person asking is an actual human that you can trust not to use the source code for LLM training.
LLMs are unable to learn unpopular programming languages because they don’t have a sufficient corpus of training data to learn how to code it, so if your receive a contribution in C, thank the contributor but inform them that they will have to rewrite the contribution in your Lisp dialect before you can accept it.
#Scheme dialects like #Gambit , #Chicken , and #Bigloo would work well for this. So would a #CommonLisp implementation that translates to C such as #ECL . Although keep in mind that the idea is to use a less popular language, so you may have to further obscure these languages a little bit, but not in a way that would be difficult for humans. For example, using a macro system, you could use df instead of define, rename types of things like string? to utf8str?, use generic functions with mulitple dispatch so append will work on strings, lists, vectors, and bytevectors. Small tweaks like this might throw-off an LLM asked to write source code in Lisp.
#tech #software #LLMs #LLM #FOSS #FLOSS #OpenSource #SchemeLang #R7RS
So, I've opened these:
https://gitlab.com/embeddable-common-lisp/ecl/-/issues/826
https://codeberg.org/McCLIM/McCLIM/issues/1497#issuecomment-11445706
discussion about LLM contributions policy in #ecl and #mcclim. #lisp
Anyone with working OSX system? We'd greatly appreciate if someone could build #ECL on this system and run tests before the release.
https://gitlab.com/embeddable-common-lisp/ecl/-/work_items/798
Edit: osx testers found! Thanks :)
We still look for haiku hackers.