Upgrade from 9.2.9 to 10.0.2 missing "system resources"

I’m struggling to upgrade swipl 9.2.9 to 10.0.2 on FreeBSD 14.3. After a successful build and installation of the package, when I try to run swipl via CLI only (without GUI or X, which is how I normally use swipl).

# swipl

FATAL: could not find SWI-Prolog home
Tried source: environment $SWI_HOME_DIR or $SWIPL
Found /usr/local/lib/swipl/bin/amd64-freebsd/swipl: no such directory
Tried source: using “swipl.home” from “/usr/local/lib/swipl/bin/amd64-freebsd/swipl”
Found /usr/local/lib/swipl: no ABI file
Tried source: compiled in
Found /usr/local/lib/swipl: no ABI file

I’ve reduced swipl as much as possible but still obtain the original FATAL messages. I have:
CMAKE_ARGS= -DSWIPL_PACKAGES_PYTHON=OFF -DSWIPL_PACKAGES_GUI=OFF -DSWIPL_PACKAGES_TIPC=OFF
-DSWIPL_PACKAGES_JAVA=OFF -DSWIPL_PACKAGES_X=OFF
-DUSE_GMP=OFF -DMULTI_THREADED=ON -DSWIPL_PACKAGES_ODBC=OFF
-DCURSES_NEED_NCURSES=OFF -DCURSES_NEED_WIDE=OFF
CMAKE_ARGS+= -DINSTALL_DOCUMENTATION=OFF -DBUILD_TESTING=OFF

After reviewing

  • the build installation notes for Debian, Redhat, Arch and “other systems”
  • the manual for installation guideance.
  • it seems that the ABI file was introduced for 9.3.15 per Ann: SWI-Prolog 9.3.16

Fortunately the search mechanism on discourse provided Updated search for Prolog installation I suspect that this is required?

swipl --abi-version > /usr/local/lib/swipl/bin/amd64-freebsd/ABI

Yay! But now, after 5 hours trying to upgrade, I have no idea where to start with this FATAL ERROR;

# swipl

[FATAL ERROR: at Tue Apr 28 12:54:42 2026
Could not find system resources at /usr/local/lib/swipl/bin/amd64-freebsd]
Abort trap

I need help…? What is the system resources that a CLI-only swipl requires?

Please disregard my earlier PR, as the solution was to:

swipl --abi-version > /usr/local/lib/swipl/ABI

The hints were in

Tried source: environment $SWI_HOME_DIR or $SWIPL
Found /usr/local/lib/swipl: no ABI file
Tried source: using “swipl.home” from “/usr/local/lib/swipl/bin/amd64-freebsd/swipl”
Found /usr/local/lib/swipl: no ABI file
Tried source: compiled in
Found /usr/local/lib/swipl: no ABI file

Once the ABI file is created in the correct location, swipl starts correctly without needing to set any environment variables. So for those that come across a similar problem, at least for the FreeBSD package the necessary files are boot.prc and the new ABI file in /usr/local/lib/swipl.

I needed to refer to an earlier version of swipl to find what it thinks is the home, via

/usr/local/lib/swipl/bin/amd64-freebsd/swipl --home

/usr/local/lib/swipl

:slightly_smiling_face:

Of course, I’ll share this key step with the FreeBSD swipl maintainer @diamondbox.dk

Finding the home has not changed AFAIK, except there is a verbose mode :slight_smile: . Also, whether some dir is the home used to be simply checking for boot.prc, but now we check the ABI file to see whether the Prolog system and the home are compatible. This saves a lot of trouble we used to have where a new swipl found an old home, after which pretty much anything between completely functioning and an immediate hard crash could follow. Notably the “almost works” could be nasty to diagnose :frowning: