Has libswipl.lib disappeared?

Using SWIPL for the first time in a while, and trying to build and link a C++ exe that makes use of SWI. I used to link against what was (for me) the static lib:

C:\Program Files\swipl\lib\libswipl.lib

Has this lib now disappeared from the latest version of SWI? If so, does that mean I have to compile and run executables using DLLs?

Seems these have vanished in the current build process :frowning: I don’t know the exact status regarding generating a .lib file using MinGW which is used to compile SWI-Prolog for Windows. MinGW doesn’t need a .lib file and can directly link to the .dll. It is a bit unclear why MSVC can’t do that. I found a link on how to use MS tools to generate the .lib from a .dll

Haven’t tested. If I recall well, in the old days MinGW was used to produce a .def file and subsequently the real MS lib.exe was used to generate the .lib. It is rather troublesome and probably illegal to include installing lib.exe in the build Docker.

There are lots of posts related to this issue. If anyone has the right answer, please share.

Well, looking back through the archives, I came across Alan Baljeu’s suggestion to copy libswipl.dll.a into the lib folder and rename its extension to become libswipl.lib.

This appears to have worked.

1 Like

Thanks. Now I see the .dll.a files are not included in the distribution. I’ll see whether that can be fixed easily. Alternatively, MinGW seems to be able to generate .def files. Well, .ddl.a might be the best start.