SWI-Prolog 9.3.6 is ready for download. This release mostly
marks completion of the first phase of transition to the new
data representation. @mgondan and @peter.ludemann spotted
and helped fixing some issues improving standard compliance
of the code base. This version will be distributed as Docker
image again.
New is the toplevel now separating the use of elipsis (write_term/2 max_depth option) from other toplevel write options. The keys ‘+’
and ‘-’ multiple (divide) the depth to which the output is printed 10
fold, while ‘w’ and ‘p’ toggle between using portray/1 or not.
A final big step is that I switched my development platform from
Ubuntu to Fedora Linux. Fedora Linux has better support for the
latest versions of the development tools (now gcc-14). In the past,
Ubuntu was better with proprietary software such as Slack, Zoom,
Spotify, etc. This problem is gone now that this software is mostly
distributed as snap or flatpak images. This was on my mind for a
while, but Ubuntu dropping installation support on LVM (Logical Volume
Manager) was a concrete and accute reason. CI and the website will
keep running on Ubuntu LTS and we will continue to create Ubuntu PPA
releases.
Enjoy --- Jan
SWI-Prolog Changelog since version 9.3.5
ENHANCED: Crash reports Avoid recursive crash reports and
only print the GC and shift stacks if the environment variable SWIPL_DEBUG_GC_STACK is set.
DOC: Add --sigalert=NUM to swipl --help.
FIXED: trie_gen_compiled/3: deal with small integer value
FIXED: trie_gen_compiled/2,3: add indirect data (big integers,
strings, rational)
FIXED: trie_gen_compiles/2,3: possible stack corruption
FIXED: #1277 crash in trie_gen_compiled/3.
CLEANUP: Avoid to undefined sanitizer warnings.
CLEANUP: Avoid UBSAN error Test for arity > 0
CLEANUP: workaround for an UBSAN error UBSAN complained about a left
shift of -1
CLEANUP: avoid UBSAN error in mkvmi.c The error is raised because we
have e5 -= 0 for e5 == NULL
Consequence is e4-- (which is fine) and e5 -= is_vmh which is either
a noop* for is_vmh == 0 or fine for is_vmh != 0 && e5 != NULL.
The noop case raises the error if e5 == NULL. * CLEANUP: Use unsigned int for variable table bitmap.
This avoids an officially undefined shift in C.
FIXED: Possibly undefined too large shift
FIXED: bf_set_si for -INT_MIN avoid undefined behavior raised by UBSAN
PORT: !1269 Deal with the type z_crc_t used by minizip zlib This
works around a type conflict over get_crc_table(). Some headers define
this as returning z_crc_t* without defining this type while others
(Fedora 40) defines the function as uint32_t* and defines z_crc_t.
This patch makes CMake check for the z_crc_t type and, if defined,
use this definition.
ADDED: qsave_program/2: --foreign=copy to copy DLLs for Windows.
ADDED: library(www_browser): support host relative links.
ENHANCED: Added toplevel options +, - to modify max_depth This option
also changes ‘w’ to merely drop portrayed(true) and p to add it.
DOC: write_term/2: document interaction between portrayed and
numbervars
FIXED: Do not name binding variables if the answer options to not
handle '$VAR'(N)
RELEASE: update-macports: verify we can download the source file This
avoids forgetting to update the source file as well as the CDN delay.
Package clib
CLEANUP: Use unsigned integers for bitmaps Avoids undefined shifts
and makes the code more readable.
Package http
ADDED: http_reply_from_files/3: option not_found(+Action) Using
not_found(404), reply using http_404/1 if the requested file does
not exist.
Package pldoc
ADDED: plDoc: support __text__ and **text** for strong.
ADDED: Support [Label](mailto:me@example.com) links in PlDoc
Package xpce
CLEANUP: Avoid relying on too big integer shift Also document that
the save format is not 64-bit robust. I do not know the consequences.
Probably it just limits the size of some objects.
All good on my Arch Linux laptop. I got one warning because I don’t have emacs installed, but that wasn’t a show stopper. “100% tests passed, 0 tests failed out of 83”.
I see Arch Linux’s pacman would install “extra/swi-prolog 9.2.4-1” so I’m thinking of going with it since then I’d automatically update once a month or so. The last time I used the distribution’s SWI-Prolog many years ago I recall there was a problem with it not having ODBC support, but since I’ve switched to having PostgreSQL communicating with swipl rather than vice-versa, that wouldn’t be a problem for me anymore.
This means something is wrong building unicode4pl.so. There should either be some warning above about this, or there is a missing dependency that causes the build order to be incorrect. That hasn’t been reported for a long time, but one never knows.
There is a simple way to find out by running ninja once more. If it happily continues and the result seems fine (see check_installation/0 and ctest), we are facing a dependency problem.
No luck with running ninja again. But I’ve decided that on the server to be conservative and rather go with pacman -S swi-prolog which installed version 9.2.4 with ODBC support no problem.
Not sure what I installed on my laptop that the server doesn’t have. I don’t bother with any X related stuff on the server since everything has to run in a terminal via ssh, so I’m guessing that caused the missing unicode4pl library.
Dropping xpce is surely a good thing for something that must run in the terminal. It is no reason why the utf8proc package does not build. This is rather curious as this is a completely self contained package, i.e., it has no dependencies. Could you run this and report any messages?
ninja -t clean utf8proc
ninja utf8proc
It should remove and rebuild 5 files and give no errors or warnings.
Thanks. Remains why it was not built in the first run Considering the clean, it built just 4 of the 5 files for this package!?
Yip. Also a bit conservative. At the moment, the stable version might indeed be more stable. Most of the time, the development releases have fewer issues
It’s really weird that it builds fine on one computer I have with Arch Linux installed but not on another. The problem one is a “minimalist” installation so some or other library is missing, but it’s beyond my knowledge to figure out what.
I used to be a “Linux from Scratch” guy, but as the xz hack debacle has shown, it’s become too complicated for anyone to understand how everything fits together anymore and what dangers lurk in various dependencies.
It was a missing dependency declaration. It turned up because the nightly builds for Windows were failing on the same issue. Pushed a fix (now only in the git version as 9.3.7 was just released )
I thought, once homebrew install --HEAD swi-prolog then
it will always upgrade with --HEAD (without --HEAD option). Anyway I will be careful whether it is the case.
% swipl --version
SWI-Prolog version 9.3.7 for arm64-darwin
%
I only followed the instructions here : https://www.swi-prolog.org/build/unix.html . So , I was in build directory. It is not said that this build directory must be deleted…
In some situations, cmake and/or ninja can get confused about what needs to be built; deleting the “build” directory ensures that everything is rebuilt.
It seems you do not have the libarchive dependency installed. Probably a missing dependency in homebrew. I think the recipe needs some maintenance. Any homebrew users willing to do that?