Dear list,
Today I tried to build swipl on a fresh MSYS2 installation for Win64. I got quite far actually:
The usual pacman stuff
- pacman -Syu, then pacman -Su git, cmake, gcc, make, zlib-devel, ncurses-devel, gmp-devel, libedit-devel, openssl-devel, libarchive-devel, base-devel, libcrypt-devel
Then
- cd swipl-devel
- mkdir build
- cmake …
- make
- make install
- swipl
During compilation, an error message appeared, stating that ftello64, fseek64 etc. were not found. I made a little change around line 20 in src/minizip/ioapi.c
#if defined(__APPLE__) || defined(IOAPI_NO_64)
to
#if defined(__APPLE__) || defined(IOAPI_NO_64) || (defined(__MSYS__) && defined(__x86_64))
This made the compilation work, but I am very unsure if it is correct - it would obviously be better to have IOAPI_NO_64 set properly, whatever this is. The compilation reached 100%, although there were two blocks of red error messages, some issues with shared libraries that couldn’t be loaded.
ERROR: /home/Matthias/swipl-devel/build/home/library/archive.pl:96:
ERROR: /home/Matthias/swipl-devel/build/home/library/archive.pl:96: Initialization goal raised exception:
ERROR: '$open_shared_object'/3: No such file or directory
ERROR: /home/Matthias/swipl-devel/build/home/library/prolog_pack.pl:726:
ERROR: Exported procedure archive:archive_open_entry/2 is not defined
ERROR: /home/Matthias/swipl-devel/build/home/library/prolog_pack.pl:726:
ERROR: Exported procedure archive:archive_next_header/2 is not defined
ERROR: /home/Matthias/swipl-devel/build/home/library/prolog_pack.pl:726:
ERROR: Exported procedure archive:archive_close/1 is not defined
ERROR: /home/Matthias/swipl-devel/build/home/library/prolog_pack.pl:726:
ERROR: Exported procedure archive:archive_set_header_property/2 is not defined
And a second one related to http
ERROR: /home/Matthias/swipl-devel/build/home/library/crypto.pl:72:
ERROR: /home/Matthias/swipl-devel/build/home/library/crypto.pl:72: Initialization goal raised exception:
ERROR: '$open_shared_object'/3: No such file or directory
ERROR: /home/Matthias/swipl-devel/build/home/library/ssl.pl:67:
ERROR: Exported procedure crypto:rsa_private_decrypt/4 is not defined
(I skipped the rest)
After make install, I had to copy msys-swipl-8.dll to a folder where it could be found by the system.
So, there seem to be only minor issues with finding dlls, and the thing with the 64-bit fseek.
Best wishes,
Matthias