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,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,d084d53a77fc8e59 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,UTF8 Path: g2news1.google.com!news2.google.com!npeer03.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!nntp.club.cc.cmu.edu!feeder.erje.net!news2.arglkargh.de!news.mixmin.net!aioe.org!not-for-mail From: =?utf-8?Q?Yannick_Duch=C3=AAne_=28Hibou57?= =?utf-8?Q?=29?= Newsgroups: comp.lang.ada Subject: Re: GPR: project hierarchy and file names Date: Thu, 19 Aug 2010 09:07:11 +0200 Organization: Ada At Home Message-ID: References: NNTP-Posting-Host: Fm6yFlaQ123yo2ThPIeWHA.user.speranza.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed; delsp=yes Content-Transfer-Encoding: Quoted-Printable X-Complaints-To: abuse@aioe.org X-Notice: Filtered by postfilter v. 0.8.2 User-Agent: Opera Mail/10.61 (Win32) Xref: g2news1.google.com comp.lang.ada:13501 Date: 2010-08-19T09:07:11+02:00 List-Id: Le Thu, 19 Aug 2010 05:23:47 +0200, Yannick Duch=C3=AAne (Hibou57) = a =C3=A9crit: Tip about foreign object files. An interesting detail I've noticed while trying to setup this project = hierarchy: it seems using =E2=80=9Cpragma Linker_Options ("...")=E2=80=9D= is not the best = thing to do, not resilient. Until now I always did this way to link to = foreign object files, but this was not working anymore, because building= = from the topmost project, at link stage, GCC was unable to find these = object files (which was not automatically moved as I first supposed). Better place it in a library linker options (and turn the project into a= = library). I may guess it work like this: with a Linker_Options given as a pragma i= n = a source file, the linked object file path is relative to the topmost = project, whatever is the location of the source file containing the = Linker_Options pragma; while with a linker option given in a project fil= e, = it is always relative to the original project file. The latter is neatly= = easier to handle.