Building embedded applications without swipl-ld
Stranz Jan-Marc <[email protected]>
| Newsgroups | gmane.comp.ai.prolog.swi |
|---|---|
| Message-ID | <9E0B7EF1EDF3FF49A8B173782CCEC62D04F0AC95@gea-exchange-01.net.gantner.com> |
I'm using "MinGW32" (version 3.20.0) and SWI-Prolog (version 6.4.1).
I trying to build an embedded c++ application without "swipl-ld".
The reason why doing so is, that I do all development with the "Eclipse IDE"; so I have to understand, how the build process works.
First I've tried to build manually a little test application "TestSWIProlog" (based on ../packages/cpp/likes.cpp) using "swipl-ld".
It works fine and I can also run this application.
Using the option "-v" all build steps are shown:
eval `swipl.exe --dump-runtime-variables`
CC="gcc"
PLBASE="c:/mingw/swipl-6.4.1"
PLARCH="i386-win32"
PLLIBS=""
PLLIB="-lswipl"
PLCFLAGS=""
PLLDFLAGS=""
PLSOEXT="dll"
PLTHREADS="yes"
g++ -c -D_REENTRANT -D__WINDOWS__ -D_WINDOWS -D__SWI_PROLOG__ -D__SWI_EMBEDDED__ -Ic:/mingw/swipl-6.4.1/include -o TestSWIProlog.obj TestSWIProlog.cpp
g++ -o TestSWIProlog.exe TestSWIProlog.obj -Lc:/mingw/swipl-6.4.1/lib -lswipl
swipl.exe -f none -F none -g true -t "consult(['likes.pl']),qsave_program('pltmp-904.exe',[goal=true,toplevel=prolog,init_file=none])"
% likes.pl compiled 0,02 sec, 19 clauses
% autoloading prolog_codewalk:must_be/2 from c:/mingw/swipl-6.4.1/library/error
% autoloading prolog_codewalk:portray_clause/1 from c:/mingw/swipl-6.4.1/library/listing
% autoloading prolog_codewalk:clause_info/4 from c:/mingw/swipl-6.4.1/library/prolog_clause
% autoloading prolog_codewalk:initialization_layout/4 from c:/mingw/swipl-6.4.1/library/prolog_clause
% autoloading prolog_debug:backtrace/1 from c:/mingw/swipl-6.4.1/library/prolog_stack
% autoloading error:assertion/1 from c:/mingw/swipl-6.4.1/library/debug
% autoloading record:member/2 from c:/mingw/swipl-6.4.1/library/lists
% autoloading qsave:current_foreign_library/2 from c:/mingw/swipl-6.4.1/library/shlib
% autoloading oset:reverse/2 from c:/mingw/swipl-6.4.1/library/lists
% autoloading prolog_codewalk:clause_name/2 from c:/mingw/swipl-6.4.1/library/prolog_clause
% Autoloader: iteration 1 resolved 10 predicates and loaded 10 files in 0,140 seconds. Restarting ...
% Autoloader: loaded 10 files in 2 iterations in 0,172 seconds
% halt
cat pltmp-904.exe >> TestSWIProlog.exe
chmod 777 TestSWIProlog.exe
rm TestSWIProlog.obj
rm pltmp-904.exe
When I do all the build steps manually I also get an executable "TestSWIProlog.exe", but it does not work.
Starting the application I always get an error:
SWI-Prolog: [FATAL ERROR:
Could not find system resources]
What does "swipl-ld" really?
Is there any "hidden" option or special build step I have to know?`
-------------- next part --------------
HTML attachment scrubbed and removed