[PPL-devel] Re: Problems with SWI-Prolog interface

Matthew Mundell mattm at comp.leeds.ac.uk
Wed Jun 8 14:09:56 CEST 2005


P M Hill <hill at comp.leeds.ac.uk> writes:

> On Wed, 8 Jun 2005, Matthew Mundell wrote:
>
>> Roberto Bagnara <bagnara at cs.unipr.it> writes:
>>
>>> Matthew Mundell wrote:
>>>> So any idea why plld only finds libpl when -lpl is given explicitly?
>>>
>>> Because the installation of SWI-Prolog you are using is broken.
>>> If you try the following command on your machine you will get
>>>
>>> $ pl -dump-runtime-variables
>>> CC="/usr/local/gcc-3.4.3/bin/gcc";
>>> PLBASE="/usr/local/pl/lib/pl-5.4.7";
>>> PLARCH="i686-linux";
>>> PLLIBS="-ldl -lreadline -lncurses -lm ";
>>> PLLIB="";
>>> PLLDFLAGS="-export-dynamic  -O3";
>>> PLSOEXT="so";
>>> PLVERSION="50407";
>>> PLSHARED="yes";
>>> PLTHREADS="no";
>>>
>>> If you do the same on any machine with a decently installed
>>> version of SWI-Prolog, you will get, instead
>>>
>>> $ pl -dump-runtime-variables
>>> CC="gcc";
>>> PLBASE="/usr/local/lib/pl-5.4.7";
>>> PLARCH="i686-linux";
>>> PLLIBS="-ldl -lreadline -lncurses -lm -lrt ";
>>> PLLIB="-lpl";
>>> PLLDFLAGS="-export-dynamic  -O3 -pthread";
>>> PLSOEXT="so";
>>> PLVERSION="50407";
>>> PLSHARED="yes";
>>> PLTHREADS="yes";
>>>
>>> Notice the difference concerning the value of `PLLIB'.
>>> My advice is to erase your installation of SWI-Prolog completely
>>> and then re-install it again from the sources with a standard
>>> ./configure ; make ; sudo make install
>>
>> Thanks Roberto.  I've rebuilt SWI in /usr/not-backed-up and PLLIB only
>> contains -lpl if --enable-mt is passed to configure.  So I think that
>> if the existing SWI installation is rebuilt with multi-threading then
>> the PPL interface will compile.  I doubt that a standard ./configure
>> will work, even from a fresh set of source.
>
> On cspcx97 (my new notebook)
>
> $ pl -dump-runtime-variables
> CC="gcc";
> PLBASE="/usr/local/lib/pl-5.4.7";
> PLARCH="i686-linux";
> PLLIBS="-ldl -lreadline -lncurses -lm -lrt ";
> PLLIB="-lpl";
> PLLDFLAGS="-export-dynamic  -O3 -pthread";
> PLSOEXT="so";
> PLVERSION="50407";
> PLSHARED="yes";
> PLTHREADS="yes";
>
> is ok with the standard ./configure ; make ; sudo make install !

Yes, sorry, the top-level configure script forces --enable-mt onto the
src directory's configure script, and I'd originally asked Graham to
prevent this (with --disable-mt).

>
> Pat



More information about the PPL-devel mailing list