Re: CLISP on Haiku

Bruno Haible via clisp-devel <[email protected]> Wed, 23 Oct 2024 16:40:37 +0200
Newsgroups gmane.lisp.clisp.devel
Message-ID <4348787.1Npu3UUWeS@nimes>
Hi,

Alexandru Popa wrote:
> I installed
> necessary dependencies except *libffcall*, which does not (yet) exist in
> Haiku.

GNU libffcall 2.5 builds and works out-of-the-box on Haiku (both the x86
and the x86_64 versions).

> 2. Because Haiku does not have multi-user support, the user has
> administrative permissions. So, I issued:
> *export FORCE_UNSAFE_CONFIGURE=1*
> otherwise it complains about too many permissions.

Yes, this workaround is needed.

> 3. During configuring, it was one crash (recover-able), so I just saved
> report and continued. I will ask Haiku for help. The error was in program
> *conftest* (during "*checking for working re_compile pattern... *" onscreen
> message).

This configure test (whose source code is in gnulib/m4/regex.m4) tests
for known regex bugs in older glibcs. Since Haiku's libc descends from
glibc, it's likely to have some of these bugs.

> 4. After configuration I inspected *src/config.lisp* file and made the
> following changes:
> Because *vi* editor is not available by default, I changed:
> *(defparameter *editor* "vi" "The name of the editor.")*
> to:
> *(defparameter *editor* "nano" "The name of the editor.")*
> This is for console editor.

Ah, Haiku has a console editor actually! I didn't know :)

> If the GUI editor can also be considered, the
> "Haiku way" would be something like:
> *(defparameter *editor* "/boot/system/apps/Pe/Pe" "The name of the
> editor.")* ; Pe = Programmer's Editor for source code.
> or:
> *(defparameter *editor* "/boot/system/apps/StyledEdit" "The name of the
> editor.")* ; Default text editor of Haiku.

I would vote for Pe. If you are in Haiku land, do the Haiku way.

> After that, I added just after:
> *;; (setq *browser* :firefox)*
> the following:
> *(setq *browser* "/boot/system/apps/WebPositive")* ; Firefox is not yet
> ported to Haiku (the work is ongoing), and will probably not be official
> one. WebPositive is The Haiku Web Browser.

OK.

> 5. Building was successful and I could find *clisp* executable in *src*
> folder.
> - *make* - OK
> - *make check-tests* - 3 / 59 tests failed: *socket.erg*, *streams.erg* and
> *streamslong.erg*, maybe because of missing *libffcall*.
> - *make check-recompile* - OK
> - *make install* - OK
> - *make distrib* - OK

Nice!

> On the first try, CLISP works with Terminal application under Haiku. It
> fails to connect to *Slime* or *Sly* under *Emacs*, but this is probably
> the issue with Slime / Sly.

Sockets have been a known problem with BeOS. It is possible that for these
historical reason, they are still problematic with Haiku. I haven't looked
in detail.

> Can you please guide me how can I contribute to making CLISP available on
> Haiku?
> For now, is there some code I can modify to not being necessary to
> manually change *config.lisp* after configuration?

Step 1 is to provide source-code patches. You could provide your config.lisp,
for inclusion in the CLISP source code as cfghaiku.lisp. One could then make
it automatic, via a makemake.in rule.

Then, it depends what "make available on Haiku" means. Does it have a
package system, like so many other OSes do? If yes, then you could submit
libffcall and then CLISP there. Be sure to pick libffcall version 2.5
and CLISP git (https://gitlab.com/gnu-clisp/clisp) master branch.

Bruno





_______________________________________________
clisp-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/clisp-devel