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=-0.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,cc857abf49a1372e X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news1.google.com!proxad.net!213.200.89.82.MISMATCH!tiscali!newsfeed1.ip.tiscali.net!feed.news.tiscali.de!newsfeed01.sul.t-online.de!newsmm00.sul.t-online.de!t-online.de!news.t-online.com!not-for-mail From: Martin Krischik Newsgroups: comp.lang.ada Subject: Re: DLLs with GNAT? Date: Fri, 14 Jan 2005 17:51:00 +0100 Organization: None Message-ID: <1875595.ZbNz8ekifv@linux1.krischik.com> References: <41E1465F.7B44DBC3@alfred-hilscher.de> <1881492.MXiprNB4H5@linux1.krischik.com> <41E7F265.18334E9E@alfred-hilscher.de> Reply-To: martin@krischik.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit X-Trace: news.t-online.com 1105778784 02 7593 l08XrjLlmRETxyM 050115 08:46:24 X-Complaints-To: usenet-abuse@t-online.de X-ID: TDYia8ZZ8eM9VNiYKd6ziJUMsbWqqun7JU03M7DnKUAznXBLHuCw4o User-Agent: KNode/0.8.0 Xref: g2news1.google.com comp.lang.ada:7796 Date: 2005-01-14T17:51:00+01:00 List-Id: Alfred Hilscher wrote: > function DLLMain (hInstDLL : Win32.Winnt.HANDLE; > dwReason : Win32.DWORD; > lpvReserved : Win32.LPVOID) return Win32.BOOL; > private > pragma Export (C, Init_API); > pragma Export (C, Finish_API); > pragma Export (C, Factorial); > pragma Export (C, DllMain); > end API; Having seen your source I can give you a more excact URL: http://cvs.sourceforge.net/viewcvs.py/adacl/CUnicode/Include/NT/ada_dll.ads?view=markup look for the pragma export of DllMain! And for good friends of yours advocating C language: if you acidently used __cdecl on DllMain it would not have worked in C either. Or if __cdecl is default and you forget to use __stdcall. And of corse, same if you forget to use either export "C" or __stdcall when using C++. A little mistake which can happen to anybody in any programming language. With Regards Martin -- mailto://krischik@users.sourceforge.net http://www.ada.krischik.com