From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,7812843c839294e4 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news4.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!nx02.iad01.newshosting.com!newshosting.com!newsfeed.icl.net!newsfeed.fjserv.net!news.tele.dk!news.tele.dk!small.news.tele.dk!news.astraweb.com!newsrouter-eu.astraweb.com!hwmnpeer01.ams!hw-filter.ams!newsfe02.ams.POSTED!40385e62!not-for-mail From: Per Sandberg User-Agent: Mozilla Thunderbird 1.0.7 (Windows/20050923) X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Calling a DLL from GNAT References: <1134999550.178141.213620@g44g2000cwa.googlegroups.com> In-Reply-To: <1134999550.178141.213620@g44g2000cwa.googlegroups.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Message-ID: <3XZpf.18169$524.18055@newsfe02.ams> X-Complaints-To: abuse@WWWSpace.NET NNTP-Posting-Date: Tue, 20 Dec 2005 13:36:15 MST Organization: @WWWSpace UseNET Date: Tue, 20 Dec 2005 21:37:04 +0100 Xref: g2news1.google.com comp.lang.ada:6946 Date: 2005-12-20T21:37:04+01:00 List-Id: If you are using .gpr files and a farly new GNAT then it may be possible to do it this way project externallib is for Source_Dirs use (); for Library_Dir use "relative path to dll from project file" for Library_Name use "what ever the basename of the dll is"; for library_kind use "dynamic"; end externallib; with "externallib"; project the_proj is end the_proj; It is all well described in "http://gcc.gnu.org/onlinedocs/gnat_ugn_unw/Stand_002dalone-Library-Projects.html#Stand_002dalone-Library-Projects" the GNAT users guide covering library projects. /Per markp wrote: > I am going to be provided a DLL of C functions that I need to interface > with in GNAT. I know how to call C functions from Ada. However, I'm not > sure how to link the DLL in with the Ada source code under the GPS > environment. Could anyone assist in this? > > Thank you. >