0

I have Apple's Command Line Tools installed but that doesn't include gfortran. I have therefore installed gcc from homebrew (which includes gfortran)

brew install gcc

But then I get this warning

Warning: gcc-6.2.0 already installed, it's just not linked

So I try to link it

brew link gcc

with this result

Linking /usr/local/Cellar/gcc/6.2.0...
Error: Could not symlink share/man/man7/fsf-funding-6.7
/usr/local/share/man/man7 is not writable.

And here I'm stuck. I don't know how to resolve this error. How can I link gcc, or even better, why isn't it linked from the beginning?

ADH89
  • 43
  • 1
  • 8
  • 1
    This probably happens because of insufficient permissions. Look at this [post](http://stackoverflow.com/questions/14527521/brew-doctor-says-warning-usr-local-include-isnt-writable) – blackpen Sep 12 '16 at 01:06

1 Answers1

1

In the linked question I found this answer https://stackoverflow.com/a/37790578/2161477 which solved my problem.

As mentioned by blackpen in the comments, the problem arises due to insufficient permissions

sudo chown -R $(whoami) /usr/local
Community
  • 1
  • 1
ADH89
  • 43
  • 1
  • 8