Re: Installing g95 on OS X

From: Gordon Sande (g.sande_at_worldnet.att.net)
Date: 10/19/04


Date: Tue, 19 Oct 2004 20:52:29 GMT


Dave Seaman wrote:
> On Tue, 19 Oct 2004 17:50:41 GMT, Gordon Sande wrote:
>
>
>
>>*** Hendrickson wrote:
>>
>>>Does anybody besides me see a problem here? *nix systems
>>>are apparently unusable by people with normal computer
>>>skills! This stuff is complicated beyond words. Jason
>>>gives a seven step program (with an error that's even
>>>obvious to me!) and Dave write a couple hundred lines
>>>of explanation/correction/improvements. And I see there
>>>are 3 or 4 follow-ups to his post.
>
>
>>>Maybe I just need another cup of coffee, but after 20+
>>>years of unix development(?), why is it so hard to
>>>install a $%^&ing compiler?
>
>
>
>>Good question!
>
>
> Agreed. But not all compilers require such fiddling. Commercial-quality
> compilers tend to come with fancy installers that make the process
> painless.
>

Painless is exactly what I have observed for several things that
I have installed on Mac Os X that are clearly Unix (as well as Mac).
fink/gfortran did not make it into that company.

>
>>I followed the recipe given for gfortran and found
>
>
>>0. I can only sudo fink ... from my admin account and not my
>> user account. Probably a good thing in the large except
>> I though the sudo/password fuss was intended to avoid
>> the the extra fuss.
>
>
> Using the 'sudo' command gives you root privileges. Do you want everyone
> on your machine to have root privileges? Maybe you have no other users
> to worry about, but the whole idea is that user accounts are for those
> who have only user privileges and no admin or root privileges.
>

SUDO requires that the sysadmin set up files so that the user gives his
account/password and proceeds. Mac Os X authentication asks for an
admin account/password and then proceeds. Much slicker. SUDO wants
someone to vouch for the user in advance and then for the user to
give a good account of himself. I have the impression that the usual
hack is to preapprove everyone for everything. Mac Os X authenticate
wants to hear about an admin account/password on the spot. Less
intrusive and less prone to the global bypass. SUDO makes sense
for admin of 100 user machines as in time shared Unices of yore.
Makes much less sense for a single user desktop microcomputer
where admin/user is more to prevent accidents.

>
>>1. I needed to fiddle a low level file because FINK was
>> not set to use UNSTABLE packages "out of the box".
>> The fix was in the FAQ under "Why doesn't it work"!
>> And there was some sort of problem with the path
>> settings for fink so it was /sw/bin/fink instead of
>> just fink.
>
>
> If fink fixed up your shell initialization to add /sw/bin to your PATH,
> which it should do by default, then all you need to do is open a new
> Terminal window and then use the fink command. It will work from that
> point on. The fink installer should have checked for that and printed a
> message about your shell initialization.
>

fink "out of the box" uses STABLE. One has to fiddle some file to get
it to look at UNSTABLE. Since gfortran is UNSTABLE one seems to be
told that it is not ready for prime time. The fink recipe as given
was for use with UNSTABLE and not as it arrives. The fink installation
reports that it is having trouble with paths which seems a bit curious
as it only has to deal with the Apple supplied Unix. Apple changed its
mind about the default shell so other aspects of account configuration
have undoubedly changed and the path problem goes with the territory.

>
>>2. The results have some sort of conflict between the Apple's
>> supplied X11 and the older do-it-yourself X11. The fixes
>> suggested in the diagnostics appear to do nothing. Why
>> does a compiler require X11?
>
>
> The compiler doesn't require X11, but some fink packages depend on X11.
> You can't get fink to build those packages unless you have X11 installed
> and configured as fink expects. Other fink packages are not affected.
>
>
>> Why does having the Apple
>> supplied Aqua compatible X11 grind things to a halt?
>
>
> It's been a while since I looked at this, but I think you just need to
> install the X11 SDK from the system install disks (it's an optional
> install) and fink should be happy.
>

Open Office plays nicely with Apple's X11. Why do the other
folks get upset with it? You are right that one has to install
it separately and that is exactly what fink/gfortran was so unhappy
to find. Installing the Aqua X11 is a double click and authenticate
painless exercise. Likewise Xcode. etc

>
>> (I am sure that if I wanted to be a full time sysadmin
>> the answer would be interesting but ...). Apple's slick
>> X11 arrived circa Os X.3 and the fink scripts are probably
>> older so I will have to wait for the fixes to work their way
>> through the system.
>
>
>>So now I do not have gfortran and I am reinforced in the notion
>>that if and only if I fiddled full with Unix/Open Software/etc
>>would I be able to get it to work. I will leave the explanation
>>of why a compiler needs X11 as one of the great mysteries of the
>>universe. It is clear that fink has a lot of ingenuity behind it
>>as does gfortran, but at the end of the session all I have is a
>>lot of wasted disk space that I may get around to clearing out.
>
>
> Some fink packages require X11 and some do not. That's a feature of the
> individual packages, not of fink or of the compiler. If a program
> expects to display things in X windows when you run it, then it's going
> to need access to X11 headers and libraries when you build it.
>

The fink installation scripts for gfortran are the things that want
an X11 and object to the existing one supplied by Apple. Net result
is that after
    "sudo fink install gfortran"
there is no gfortran after the reams and reams of compilations of
various X11 pieces. The only reason that makes sense to me fo the X11
stuff is that someone is trying to be helpful and it has backfired
badly. Perhaps gfortran only works for versions of Mac Os X that are
earlier than the version that came preinstalled. Not a helpful
situation.

>