From jan@swi.psy.uva.nl  Wed Apr 26 20:33:46 2000
Received: from gollem.swi.psy.uva.nl (root@gollem [145.18.152.30])
	by swi.psy.uva.nl (8.9.3/8.9.3) with ESMTP id UAA07123;
	Wed, 26 Apr 2000 20:33:46 +0200 (MET DST)
Received: (from jan@localhost)
	by gollem.swi.psy.uva.nl (8.9.3/8.9.3/SuSE Linux 8.9.3-0.1) id UAA23331;
	Wed, 26 Apr 2000 20:33:47 +0200
Date: Wed, 26 Apr 2000 20:33:47 +0200
Message-Id: <200004261833.UAA23331@gollem.swi.psy.uva.nl>
From: Jan Wielemaker <jan@swi.psy.uva.nl>
Subject: Re: .dll made in C++ compiler
To: Joon Heo <heo@cae.wisc.edu>, prolog@swi.psy.uva.nl
In-Reply-To: Joon Heo's message of Wed, 26 Apr 2000 09:41:10 -0500 (CDT)
Phone: +31 - 20 - 525 6121

> 
> 
> I tried to combine a dll module into prolog environment, but it was not
> successful with the following messages.  Another dll, which was compiled
> in C compiler, was all right, though. 
> 
> ************************************************************
> Yes
> ?- load_foreign_library(blunderdll).
> [WARNING: blunderdll: failed to call entry point install]
> 
> No
> ************************************************************
> 
> I am wondering if SWI-Prolog can not integrate dll made in C++ environment
> or there are any other problems.  It will be very much appreciated if
> anybody answer the question.  

Using C++ is ok, but

	* When using the plain interface the install() and uninstall()
	  functions must be declared external "C" to avoid C++ name-mangling.

	* Or use the real C++ interface from

		ftp:swi.psy.uva.nl/pub/SWI-Prolog/BETA/cpp.tgz

	Regards --- Jan

