Compiling with gnu-prolog???



I've had serious problems attempting to compile prolog to native code
using gnu-prolog. I've googled for hours, and read the manual, in
addition to trying things like setting paths, etc. Nothing has
worked. I figure someone else must have had the same difficulties (in
fact, I saw one guy posting on the net with identical problems, but he
got nothing useful), so I am posting hoping for a solution.

Anyway, cutting to the chase - when I "gplc pltest.pl" I get:

error trying to execute pl2wam: Invalid argument
Compilation failed

Strangely enough, I can successfully invoke each "sub-compiler" in the
chain of compilations necessary to produce assembly code, and I can
get the result of that compilation. For instance, it is complaining
about the pl2wam compiler above. However when I do "pl2wam pltest.pl"
I get the .wam file. But when I feed the .wam file into the compiler
I get the same error above except with the wam2ma compiler as the
problem. But I can invoke THAT "sub-compiler" and repeat the whole
process again on down.

Suffice to say that I can then get a .ma file, and then a .s file. In
other words, each time it complains about a "sub-compiler," I can
access that sub-compiler no problem. This is evidence that the path
is set correctly - it can always find the proper compiler no matter
what directory I am in.

I wouldn't bother posting (even though this whole process is a pain
that needs to be rectified), except that I don't know how to go
further (past the mingw-as "sub-compiler"). In other words, I don't
know how to compile or link the last file I can produce into an
executable.

Anyone know what the heck is going on? I'm running Win XP. I've
tried doing this from both a dos shell, and cygwin - same results.

Thanks.

.



Relevant Pages

  • Re: VB6, VB2005, or Something Else?
    ... The compiler generates the name mangling under the hood, or if you export these functions in a DLL. ... However you cannot use them safely from another language or other compiler vendors. ... As soon as you update to the new compiler it would either break compatibility or would have 2 name mangling hierarchies - internal and COM name mangling - which surely would lead to let's say interface mangling hell - in analogy to the DLL hell. ... E.g. the C++ compiler will emit native code, where it's not possible to generate IL code. ...
    (microsoft.public.vb.general.discussion)
  • Re: any JIT compilers for Prolog?
    ... to WAM bytecode and saves it in a file.wic ... in it were further compiled to native code (on Sparc ... I wouldn't name the above JIT: it is just a staged compiler whose last ...
    (comp.lang.prolog)
  • Re: Native Code vs PCode
    ... and start testing what is for you, the optimal compiler settings ... Public Const Units_MilliSeconds = &H0 ... If Then Exit Sub ... native code with and without the different optimization ...
    (microsoft.public.vb.general.discussion)
  • Re: Native Code vs PCode
    ... > Subject: Re: Native Code vs PCode ... There is no JIT compiler ... There is no more 'interpretation' than what goes on when a call to a method ...
    (microsoft.public.vb.general.discussion)
  • Re: Further evidence MS hasnt abandoned Win32 development
    ... > So what is the advantage of using native code? ... the unmanaged compiler. ... MC++ is your language of choice if you want full control of the .NET ... Gives seamless access to all unmanaged libraries, such as DLLs, ...
    (borland.public.delphi.non-technical)