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,ad829d3ec11d6354 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news3.google.com!news.glorb.com!newsfeed0.kamp.net!newsfeed.kamp.net!news.osn.de!diablo2.news.osn.de!news.belwue.de!newsfeed.ision.net!newsfeed2.easynews.net!ision!newsfeed.arcor.de!news.arcor.de!not-for-mail Date: Thu, 18 May 2006 14:15:30 +0200 From: Georg Bauhaus Organization: elsewhere User-Agent: Thunderbird 1.5 (Macintosh/20051201) MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Problem creating bindings - please help References: <1147934783.645893.274580@u72g2000cwu.googlegroups.com> <1147949508.476468.302020@j73g2000cwa.googlegroups.com> <1147951449.361205.317700@i40g2000cwc.googlegroups.com> <1147953724.850549.227110@j33g2000cwa.googlegroups.com> In-Reply-To: <1147953724.850549.227110@j33g2000cwa.googlegroups.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Message-ID: <446c655a$0$4497$9b4e6d93@newsread2.arcor-online.net> NNTP-Posting-Date: 18 May 2006 14:15:23 MEST NNTP-Posting-Host: 5938a5fe.newsread2.arcor-online.net X-Trace: DXC=We3DmBA`abe18V74W6`bolQ5U85hF6f;djW\KbG]kaMhVA=iV<7g:2eel2; Gerd wrote: > christoph.grein@eurocopter.com schrieb: > >> Gerd wrote: >>> The GNAT Users Guide say that the "_" and the "@16" is appended >>> automatically for "__stdcall" (as far as I understood). And the >>> function is declared as "__stdcall" in the header-file. >> External_Name and Link_Name in pragma Import are optional. But if you >> provide them, they must be exact (AFAICS). > > No. The Users guide say the "@nn" is always added, the "_" can be > dropped by specifying a link name, but is added if not specified in > external name. > FWIW, using ObjectAda and Windows function names it's the same, the external name of the function must be given without underscore and @suffix. Using gcc on Windows I get the same linker error when I try to "just" refer to a windows function in a simple C program.