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-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,5d33a8597dd959af,start X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-01-20 11:27:19 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!logbridge.uoregon.edu!newsfeed.stueberl.de!newspeer1-gui.server.ntli.net!ntli.net!newsfep4-win.server.ntli.net.POSTED!53ab2750!not-for-mail From: "chris.danx" User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.3a) Gecko/20021212 X-Accept-Language: en, en-us MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: C to Ada Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Message-ID: Date: Mon, 20 Jan 2003 19:28:56 +0000 NNTP-Posting-Host: 80.4.69.150 X-Complaints-To: abuse@ntlworld.com X-Trace: newsfep4-win.server.ntli.net 1043090838 80.4.69.150 (Mon, 20 Jan 2003 19:27:18 GMT) NNTP-Posting-Date: Mon, 20 Jan 2003 19:27:18 GMT Organization: ntl Cablemodem News Service Xref: archiver1.google.com comp.lang.ada:33248 Date: 2003-01-20T19:28:56+00:00 List-Id: -- Apologise if this appears twice, these news servers are a pita!!! Hi, How do you map something like this to Ada (for a binding)? It's probable that I'll only be working with GNAT on the Linux front (it's all there is), so a GNAT specific option although not ideal, is acceptable. /* Open the shared object FILE and map it in; return a handle that can be passed to `dlsym' to get symbol values from it. */ extern void *dlopen (__const char *__file, int __mode) __THROW; I know rougly how to map the __file, and __mode params but am not sure how to deal with the void * or in this case the throw. This is taken from dlfcn.h which is the header for dynamic library support in Linux. If anyone already has a (GMGPL) binding to this library and they'd like to share, please let me know, it'll save me making one. In any event how do you translate this C code so it can be called from Ada? After I get a wee thin binding working, I'm going to make it a little thicker and toss it into the open. Cheers, Chris -- for personal replies change spamoff to chris