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=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!mx02.eternal-september.org!.POSTED!not-for-mail From: Simon Wright Newsgroups: comp.lang.ada Subject: Re: Upgrade to gnat 2015 now project not linking Date: Wed, 30 Sep 2015 20:15:01 +0100 Organization: A noiseless patient Spider Message-ID: References: <9fe6d3f2-50e1-44a6-8ba0-2987d3792dd0@googlegroups.com> <5ba84353-987c-45b9-b5b5-cd7401074fe7@googlegroups.com> <8d12b995-a6e6-4ab7-ac04-33c611c2bdd0@googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: mx02.eternal-september.org; posting-host="82b7f55adeea1ed21a93abb5e24a046f"; logging-data="14566"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/pO75nvj8jvrqLdB0DgZzTzKCWGc5dyw4=" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (darwin) Cancel-Lock: sha1:EuwHHldra5lbCSy0xLo+58WgKiE= sha1:piINNR9Fk/Brfs0bPkisdhQsGzI= Xref: news.eternal-september.org comp.lang.ada:27880 Date: 2015-09-30T20:15:01+01:00 List-Id: Lucas Redding writes: > Hold fire! > > I was too quick to come to conclusion. -M does not generate a map file. > > I need to look into how to generate a map file in 2015. > > I'll be back. Gprbuild can do this. You should be able to say, in package Builder, something like package Builder is for Default_Switches ("ada") use ("--create-map-file=" & project'Project_Dir & project'Name & ".map"); end Builder; (that's one of mine; it assumes there's only one main program, named after the project, and works round the problem that the link is done in the build directory). assuming that the configuration is set up to know how to specify a map file; if not, you could try (for GNU ld) package Linker is for Map_File_Option use "-Wl,-Map,"; end Linker; It occurs to me one could try to combine these: package Linker is for Map_File_Option use "-Wl,-Map,project'Project_Dir"; end Linker; and package Builder is for Default_Switches ("ada") use ("--create-map-file"); end Builder; If this works, you could omit (this part of) package Builder and just use --create-map-file on the command line.