Qmake installed but not linked - Using Brew - Mac - macos

I have installed Qmake using brew.
brew install qt
The results which the terminal brings is:
Warning: qt-4.8.6 already installed, it's just not linked
This is a problem with brew to install correct the things? because I am having the same "not linked" problem with PostgreSQL.
Thks
I found the problem:
The Brew can't write to the folder /usr/local/lib/
So I used the command: sudo chown -R $USER /usr/local/lib
I found a similar error here: Brew doctor says: "Warning: /usr/local/include isn't writable."
But this problem was with another folder permission.

The Brew can't write to the folder
/usr/local/lib/
So I used the command:
sudo chown -R $USER /usr/local/lib
After need uninstall and install qt again. (If you run reinstall the problem will continuous)
brew uninstall qt
brew install qt
I found a similar error here:
Brew doctor says: “Warning: /usr/local/include isn't writable.”
But this problem was with another folder permission.

Try
brew link qt
Which should tell brew to link the package.
If that doesn't work, someone else had a similar problem here: Error: The 'brew link' step did not complete successfully

Related

brew link php55 does not work

I tried to install php55 which works fine itself, but the linking does not work. Which means I cannot install any modules via brew.
$ brew link php55
Linking /usr/local/Cellar/php55/5.5.17... Error: No such file or directory - /usr/local/Cellar/php55/5.5.16/include/php
Brew tries to link 5.5.16 but it should use 5.5.17. I already reinstall php55 again a few times and used "brew cleanup" in between.
How can I link it correctly?
Remove it with "brew remove php55". It will automatically look at the other version afterwards. Don't forget to relink it with "brew unlink php55 && brew link php55".

Homebrew link issue on Mac OS X (10.7.5)

I'm having issues troubleshooting a link problem when installing Homebrew. I'm attempting to install it on Mac OS X (10.7.5). I have been unable to find a solution and could use help. The error I'm receiving is below.
tone$ brew link wget
Linking /usr/local/Cellar/wget/1.14... Warning: Could not link wget. Unlinking...
Error: Could not symlink file: /usr/local/Cellar/wget/1.14/share/man/man1/wget.1
Target /usr/local/share/man/man1/wget.1 already exists. You may need to delete it.
To force the link and overwrite all other conflicting files, do:
brew link --overwrite formula_name
To list all files that would be deleted:
brew link --overwrite --dry-run formula_name
I ran the following commands to get to this point
ruby -e "$(curl -fsSL https://raw.github.com/mxcl/homebrew/go)"
$ brew install wget

Unable to brew link qt

So I just installed qt via brew in Mac OS X. It was unable to link it however.
When I try to run brew link qt or brew link --overwrite qt I get back the following:
tonybeninate$ brew link --overwrite qt
Linking /usr/local/Cellar/qt/4.8.4... Warning: Could not link qt. Unlinking...
Error: Directory not empty - /usr/local/opt/qt
Anyone have any suggestions? I've also tried running brew link -n qt and removing any files/dirs that were conflicting to no avail.
Try brew cleanup.
Even with above command, you might get similar error. To fix it, change permissions with
sudo chown -R $(whoami) /usr/local
If you are on Mac High Sierra, use
sudo chown -R $(whoami) $(brew --prefix)/*
Follow this post for more permissions related changes
Once permissions are done, try brew cleanup and your command brew link --overwrite qt

Cannot install ruby-1.9.2 in Mac OSX 10.8.1 due to symlink error

First, I tried the common rvm install.
rvm install 1.9.2
However, the following error was shown:
The provided compiler '/usr/bin/gcc' is LLVM based, it is not yet fully supported by ruby and gems, please read `rvm requirements`.
Then I run
rvm requirements
and find these following part of output useful
Right now Ruby requires gcc to compile, but Xcode 4.2 and later no longer ship with gcc. Instead they ship with llvm-gcc (to which gcc is a symlink) and clang, neither of which are supported for building Ruby. Xcode 4.1 was the last version to ship gcc, which was /usr/bin/gcc-4.2.
Xcode 4.1 and earlier:
- Ruby will build fine.
Xcode 4.2 and later (including Command Line Tools for Xcode):
- If you have gcc-4.2 (and friends) from an earlier Xcode version, Ruby will build fine.
- If you don't have gcc-4.2, you have two options to get it:
* Install apple-gcc42 from Homebrew
* Install osx-gcc-installer
Homebrew:
If you are using Homebrew, you can install the apple-gcc42 and required libraries from homebrew/dupes:
brew update
brew tap homebrew/dupes
brew install autoconf automake apple-gcc42
rvm pkg install openssl
This can live side by side with an existing Xcode 4.2+ install or Command Line Tools for Xcode.
so I tried:
brew update
brew tap homebrew/dupes
brew install autoconf automake apple-gcc42
However, I got the following error
Warning: Could not link apple-gcc42. Unlinking...
Error: The `brew link` step did not complete successfully
The formula built, but is not symlinked into /usr/local
You can try again using `brew link apple-gcc42'
==> Summary
/usr/local/Cellar/apple-gcc42/4.2.1-5666.3: 104 files, 75M, built in 23 seconds
kanitw:shell.venturelab.com kanitw$ brew link apple-gcc42
Linking /usr/local/Cellar/apple-gcc42/4.2.1-5666.3... Warning: Could not link apple-gcc42. Unlinking...
Error: Could not symlink file: /usr/local/Cellar/apple-gcc42/4.2.1-5666.3/include/gcc
/usr/local/include is not writable. You should change its permissions.
What would be my best solution? I kinda remember from somewhere that I should not use sudo with brew since I will mess up the whole installation.
You can change /usr/local directory owner
sudo chown -R `whoami` /usr/local
But, if you have mysql installed, you mast fix its owner
sudo chown -R mysql:mysql /usr/local/mysql
You should run brew doctor and then change the permissions accordingly. There might be other issues.
Change the permissions of your /usr/local directory and try again.

Installing Postgresql on Mac Lion

I was doing an exercise from the ruby on rails tutorial which involves installing postgresql. Following the instructions from a rails cast linked in the tutorial, I did
brew install postgresql
This errored. On searching online, found a thread on a forum which suggested doing
brew unlink ossp-uuid && brew link ossp_uuid
I don't know what this is achieving. The command failed (I think the first part succeeded). The error:
Could not symlink file: /usr/local/Cellar/ossp-uuid/1.6.2/share/man/man3/uuid.3
/usr/local/share/man/man3 is not writable. You should change its permissions.
What is this about? Why do we need to create this symbolic link?
Thanks in advance!
You don't need sudo to work with brew read here.
The main problem is your own permission on /usr/local folder to execute these actions.Try this (make sure that you login as administrator role):
sudo chmod go+w /usr/local
Then try again:
brew unlink ossp-uuid && brew link ossp-uuid
and:
brew install postgresql
You likely need to use sudo before the command.
Alternatively, postgres can be installed from an installer from their site: Mac OS X installer
Postgresql is already installed on Lion.

Resources