From stepheng@australia.edu Thu Nov 29 09:28:07 2001
Received: from australia.edu (gold.internet-media.net [216.15.179.130])
	by swi.psy.uva.nl (8.10.2+Sun/8.11.2) with SMTP id fAT8S5f26053
	for <prolog@swi.psy.uva.nl>; Thu, 29 Nov 2001 09:28:06 +0100 (MET)
Received: from arisu ([172.183.163.148]) by australia.edu ; Thu, 29 Nov 2001 17:05:02 -0600
From: "Stephen Gilmour" <stepheng@australia.edu>
To: <prolog@swi.psy.uva.nl>
Date: Thu, 29 Nov 2001 19:28:06 +1100
Message-ID: <DEEJLJFLMEODEOAGOLGLAEMOCBAA.stepheng@australia.edu>
MIME-Version: 1.0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Priority: 3 (Normal)
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0)
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200
In-Reply-To: <200111290742.fAT7gkV21423@gollem.swi.psy.uva.nl>
Importance: Normal
Subject: [SWIPL] Embedded prolog applications in C++

I have been trying to get the "likes" example of using prolog as an AI
server within a C++ application working but I keep coming up against
troubles.  I have in terms of compilers Visual C++ 4.0 and Cygwin with G++.
I didn't even know how to start with using plld in cooperation with VC++
(although this is ideal) so I've been trying to use cygwin.  Unfortunately
when I compile using make it gives a long list of errors.  I've trying
reducing the obvious problems by the following:

* copying entire pl directory into cygwin directories and moving the "likes"
project into bin directory of pl.
* installing SWI-Prolog.h into the cygwin include files directory
* copying all the files in the lib dir into the bin dir.

Even then I still get the following errors:


none@ARISU ~
$ cd prolog/bin

none@ARISU ~/prolog/bin
$ make
./plld -o all -ld g++ -goal true likes.cpp likes.pl
Bad command or file name
G__~1: /out:ctmp--980965: No such file or directory
G__~1: /nologo: No such file or directory
G__~1: likes.obj: No such file or directory
% likes.pl compiled 0.00 sec, 3,468 bytes
% halt
Could not open ctmp--980965: No such file or directory
*** C:\cygwin\home\none\prolog\bin\plld.exe exit status 1
make: *** [all] Error 1


What I'm trying to do is very hacky.  Just wondering if anyone has any nice
directions for getting this to work under cygwin or VC++ or can at least
help with this error message.

Thanks very much
Stephen Gilmour

