running a nL on nearlyfreespeech

Started by joejoe, August 25, 2020, 03:06:41 AM

Previous topic - Next topic

joejoe

I am using


#/usr/local/env/bin newlisp
(println "hihi")
(exit)


saved as an index.cgi w 755 chmod.



w only a 500 error on nearlyfreespeech.



When I type whereis newlisp, it shows:


$ whereis newlisp
newlisp:


I have done this before easily.



Now get:


$ newlisp
-bash: newlisp: command not found


Any tip on how to execute an index.cgi nL script w NFS?



Or if an easier place to up and run nL, please direct. Thought NFS was pretty straight.



Thank you!

rickyboy

#1
Your #! line looks wrong.
(λx. x x) (λx. x x)

joejoe

#2
No doubt,



I have tried a few -



#/usr/local/env/bin newlisp

!#/usr/local/bin/env newlisp

#!/usr/local/bin/env newlisp

#!/usr/bin/env newlisp

#!/usr/local/bin/newlisp



If whereis doesnt work, how best to find the right path?


whereis newlisp
newlisp:

joejoe

#3
Think they may have lost support?



$ newlisp

-bash: newlisp: command not found



Just submitted a request w NFS to know if it is still supported.



Found that as its been dropped from the bs d port, so no go, only compile from source.



https://members.nearlyfreespeech.net/forums/viewtopic.php?t=10566&highlight=newlisp">https://members.nearlyfreespeech.net/fo ... ht=newlisp">https://members.nearlyfreespeech.net/forums/viewtopic.php?t=10566&highlight=newlisp


QuoteNewlisp has been dropped from the FreeeBSD ports collection due to lack of support from the developer, so we are unable to offer it preinstalled.



We contacted the developer about this to see if we could facilitate a solution, but we were not successful. The developer recommends that anyone who wants to use newlisp compile it from source.

joejoe

#4
Any known hosts out of box nL friendly?



Thanks and for all!

Lutz

#5
When NearlyFreeSpeech.NET Support contacted me, we had a longer email exchange. This is the solution I offered:



lutz mueller <lutz.email@gmail.com>

Apr 17, 2020, 1:05 PM

to [NearlyFreeSpeech.NET
Hi Jeff,

You can find a current executable compiled and tested on your server here: http://www.newlisp.org/cgi-bin/newlisp

[newlisp /home/public/cgi-bin]$ ./newlisp
newLISP v.10.7.5 64-bit on BSD IPv4/6 UTF-8 libffi, options: newlisp -h

>

Best regards - Lutz


There where relying on newlisp to be compiled by the FreeBSD organization web site. But FreeBSD organization did not have updated to v10.7.5.



My own scripts on NearlyFreeSpeech.NET all use:



#!/home/public/cgi-bin/newlisp



in the .cgi files. You could just download:



http://www.newlisp.org/cgi-bin/newlisp">http://www.newlisp.org/cgi-bin/newlisp



and do the same.

joejoe

#6
Thank you Lutz!



I ran these and got pretty much there if it helps anyone. Will figure the rest.


mkdir cgi-bin
cd cgi-bin
wget http://www.newlisp.org/cgi-bin/newlisp
chmod 755 newlisp

./newlisp
Shared object "libreadline.so.7" not found, required by "newlisp"

wget ftp://ftp.gnu.org/gnu/readline/readline-8.0.tar.gz
tar zxvf readline-8.0.tar.gz
cd readline-8.0
./configure
make

make install
install: /usr/local/include/readline/readline.h: Read-only file system
*** Error code 71


Thanks for allow so much support for all distros and hosting options!

Lutz

#7
newLISP can be compiled without readline support by taking out: -DREADLINE from the compile line in the make file and take out: -lreadline and: -lncurses from the linkline in the make file.



Here is a new recompile without readline support:



http://www.newlisp.org/cgi-bin/newlisp">http://www.newlisp.org/cgi-bin/newlisp



compiled using: makefile_bsdLP64_utf8 and shouldn't complain about any library missing.



In case this still doesn't work, expand newlisp-10.7.5.tgz and recompile yourself on your server using:



make -f makefile_bsdLP64_utf8

joejoe

#8
Thank you Lutz!



I replaced the old with the new binary



http://www.newlisp.org/cgi-bin/newlisp">http://www.newlisp.org/cgi-bin/newlisp



I also am using your


#!/home/public/cgi-bin/newlisp

Everything worked immediately, and will keep note of your recompile without readline in mind too!



Much appreciated, Lutz!