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: a07f3367d7,fea50f781bb229dc X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,UTF8 Path: g2news2.google.com!news4.google.com!feeder3.cambriumusenet.nl!feed.tweaknews.nl!193.201.147.78.MISMATCH!feeder.news-service.com!85.214.198.2.MISMATCH!eternal-september.org!.POSTED!not-for-mail From: Ludovic Brenta Newsgroups: comp.lang.ada Subject: Re: About static libraries and Debian policy Date: Sun, 16 May 2010 12:31:16 +0200 Organization: A noiseless patient Spider Message-ID: <87mxw0cf4b.fsf@ludovic-brenta.org> References: <85f51aeb-cac9-4591-921a-a7f50c8ef142@a21g2000yqn.googlegroups.com> <1pup1z7a4f1pq$.of30sejrqe4m.dlg@40tude.net> <87hbmae33k.fsf@ludovic-brenta.org> <87sk5sdega.fsf@ludovic-brenta.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Date: Sun, 16 May 2010 10:31:16 +0000 (UTC) Injection-Info: mx02.eternal-september.org; posting-host="nHQ58sdsUWLzBSs89yL2wQ"; logging-data="4391"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+oL7/qmLU/9Tj+lWEgc0vH" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) Cancel-Lock: sha1:wJZQansgZaDNtyyIwap5874/31A= sha1:3DWphFhpCTFIxD0EoJ3rzp0TIEs= Xref: g2news2.google.com comp.lang.ada:11659 Date: 2010-05-16T12:31:16+02:00 List-Id: Simon Wright writes on comp.lang.ada: > Thanks for that, I'm sure it'll help. As an alternative, could use one > of the GNAT.OS_Lib.Spawn calls? Probably. Other improvements are probably possible, too. I haven't worked on this in a long, long time (since the GNAT 3.15p days, in fact). > I notice that towards the end the comment says > > + -- version dependant variants for the option names. Therefore our > + -- implementation spawns a shell script that does normalization of > + -- the option and then executes addr2line and communicates with it > + -- through a bidirectional pipe. > > but it looks to me as though it spawns addr2line drectly? > > + char *const argv[] = { "addr2line", > + exe_name, > + "--demangle=gnat", > + "--functions", > + "--basenames", > + NULL }; > + char *const envp[] = { NULL }; > + if (execve("/usr/bin/addr2line", argv, envp) < 0) { > + CLOSE1; CLOSE2; > + } The comment was the original from Jürgen Pfeifer. I changed the implementation to not use a shell script but I forgot to update the comment. -- Ludovic Brenta.