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: border2.nntp.dca1.giganews.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!news.glorb.com!peer02.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!post02.iad.highwinds-media.com!fx01.iad.POSTED!not-for-mail From: agent@drrob1.com Newsgroups: comp.lang.ada Subject: Re: static linking Message-ID: References: User-Agent: ForteAgent/7.20.32.1218 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Complaints-To: abuse@easynews.com Organization: Forte - www.forteinc.com X-Complaints-Info: Please be sure to forward a copy of ALL headers otherwise we will be unable to process your complaint properly. Date: Sat, 04 Oct 2014 14:10:44 -0400 X-Received-Bytes: 1435 X-Received-Body-CRC: 2570179663 Xref: number.nntp.giganews.com comp.lang.ada:189390 Date: 2014-10-04T14:10:44-04:00 List-Id: On Sat, 04 Oct 2014 08:21:01 +0100, Simon Wright wrote: > >> Hi. I have written a small ada pgm under ubuntu. This program is >> working. But it only works on computers that I have already installed >> gnat. I am assuming that this is due to dynamic linking to a runtime >> library for ada. >> >> Is there a way to statically link an ada program so I do not have this >> issue? > > $ gnatbind --help > ... > -static Link against a static GNAT run time > -shared Link against a shared GNAT run time > ... > > $ gnatmake foo.adb -bargs -static > >(I guess -shared is default on your system; on Mac OS X it appears the >default is -static). Thanks. That worked.