public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: IainS <developer@sandoe-acoustics.co.uk>
To: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
Cc: GCC Development <gcc@gcc.gnu.org>,
	        "fortran@gcc.gnu.org List" <fortran@gcc.gnu.org>
Subject: Re: [RFC, Patch, gfortran] make -static-libgfortran work on darwin.
Date: Tue, 10 Jun 2008 20:41:00 -0000	[thread overview]
Message-ID: <6EDD138A-8D45-47D5-A020-55DC67B1084A@sandoe-acoustics.co.uk> (raw)
In-Reply-To: <20080610195850.GH1722@ins.uni-bonn.de>


On 10 Jun 2008, at 20:58, Ralf Wildenhues wrote:

> * IainS wrote on Tue, Jun 10, 2008 at 09:42:29PM CEST:
>> On 10 Jun 2008, at 20:06, Ralf Wildenhues wrote:
>>
>>> Can the driver use path/to/libgfortran.a instead of '-Lpath/to
>>> -lgfortran' to avoid being hindered by missing -Bstatic/-Bdynamic?
>>
>> this doesn't appear to work. [I've unset DYLD_LIBRARY_PATH in the
>> following]
>>
>>  ./dst-powerpc/usr/bin/gfortran-4.4.0 helloi.F90 /Volumes/UFSScratch/
>> GCC/gcc-44-build/dst-powerpc/usr/lib/gcc/powerpc-apple-darwin8/4.4.0/
>> libgfortran.a -o helloif
>
> Well, what I meant was that on Dargin, gfortran could pass the  
> argument
>   path/to/libgfortran.a
>
> to collect2, instead of passing
>   -Bstatic -lgfortran -Bdynamic

I guess.. [I'll have to try this another day ]
you can do "-nodefaultlibs" and then specify all the libs by hand.   
That works (I originally did this).
It seems then that the driver has to replicate the multilibs stuff...

I'm not sure that it would produce less darwin-specific code than  
renaming the lib.

>> we could campaign for a different linker on OSX/Darwin I guess...
>
> What's the problem with just using the shared library?
> (Yeah, I knew that question was naive ... but hey, it works ;-)

I'm also happy to file a radar for missing Bstatic/Bdynamic.

>> We start to require that the end user has administration rights to
>> install into /usr simply in order to run a program?
>
> I'm not sure whether I understand this comment.  Isn't the link-time
> location of a shared library added to the search path anyway?
> (My experience with darwin is quite limited, so my memory may serve
> me wrong here.)

fortran is not part of any standard installation on OSX (yet..., of  
course, that could change).
On darwin 8 the gcc version is 4.0.1
I don't know whether the 4.2.1 version [from darwin 9] will be  
officially released
...  I've back-ported it (but, that's not an end-user thing)

if you want to deliver any different you have to choose
(a) the end user must install with admin rights  [to put stuff in / 
usr etc.]
(b) static linking of the missing bits

(b) is a lot simpler for me...

ttfn,
Iain

  reply	other threads:[~2008-06-10 20:41 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <A6664290-AFD1-4FCE-97E5-01DE56BB8B1D@sandoe-acoustics.co.uk>
2008-06-10 16:00 ` Fwd: " FX
2008-06-10 19:07   ` Ralf Wildenhues
2008-06-10 19:43     ` IainS
2008-06-10 19:59       ` Ralf Wildenhues
2008-06-10 20:41         ` IainS [this message]
2008-06-11  3:40         ` Peter O'Gorman
2008-06-10 20:15       ` Ralf Wildenhues
2008-06-10 16:12 ` FX
2008-06-10 16:40   ` IainS
2008-06-10 16:43   ` Dave Korn

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6EDD138A-8D45-47D5-A020-55DC67B1084A@sandoe-acoustics.co.uk \
    --to=developer@sandoe-acoustics.co.uk \
    --cc=Ralf.Wildenhues@gmx.de \
    --cc=fortran@gcc.gnu.org \
    --cc=gcc@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).