Install Libomp - Homebrew is not being found on my terminal - homebrew

Im trying to install libomp on my mac using the following command:
brew install libomp
But everytime I get an error like this:
Warning: No available formula with the name "libomp".
==> Searching for similarly named formulae and casks...
Error: No formulae or casks found for libomp.
I already uninstall and install Homebrew twice, uninstall/install and updated the lightgbm package, and nothing seems to work.
I was able to install other packages so is not a problem with my computer or anything like that.
Does anyone know how can I fix that?

Run the following to ensure your Homebrew is up to date.
brew update
Then install libomp like this
brew install libomp
and updated the lightgbm package
I'm not sure if this means the lightgbm Python package, the lightgbm CLI installed via Homebrew, or something else...but either way, the presence of those things should not impact whether or not Homebrew is able to install libomp on your system.

Related

brew doctor warnings - delete or ignore?

After I installed Homebrew,
Then I try the brew doctor command, there comes warnings:
Could I know the reasons and How to fix it? Could I just ignore these warnings?
The files reported by brew doctor are added by a software (that you manually installed before installing Homebrew) that uses a library for the Tcl/Tk language.
Homebrew also provides a library for Tcl/Tk and the existing files will conflict with those installed by Homebrew if you install a package that requires the Tcl/Tk library.
You don't have to worry for now and, very important, don't try to "fix" anything (especially don't remove files).
What you can do to "fix" it is to find out what program installed those files (it was not installed using the App Store, you installed it manually) and see if Homebrew provides it. If it is a macOS GUI application then Homebrew doesn't provide it (it contains only command line applications, no GUI) but Homebrew Cask might do it.
Use
$ brew search app
or
$ brew cask search app
If you are lucky and you find it and you are pleased with the version provided by Homebrew then you can uninstall the application using the uninstaller it hopefully provides then reinstall it using Homebrew (or Homebrew Cask).
You can run brew doctor between uninstall and reinstall to make sure the uninstaller removed all the files listed in the output of brew doctor now.
As written at the beginning of brew doctor's output, you can safely ignore these warnings if everything you use Homebrew for works fine.

Warnings when running meld on Mac OS X Sierra

I've installed homebrew on my machine. Using brew I've installed meld. When I run it with git I get the following error:
Couldn't bind the translation domain. Some translations won't work.
'module' object has no attribute 'bindtextdomain'
2016-10-20 10:14:08.422 Python[22212:158273] *** WARNING: Method userSpaceScaleFactor in class NSView is deprecated on 10.7 and later. It should not be used in new applications. Use convertRectToBacking: instead.
(meld:22212): Gdk-WARNING **: GdkQuartzDisplay does not implement the monitor vfuncs
I don't understand how exactly brew works. In fact I never dug into its code, used it only to (un)install the software.
Did some online searches but there doesn't seem to be a solution to this. Has anyone figured it out?
Homebrew is simply a a package manager for MacOS. Unlike Linux, Mac doesn't always have all the external libraries you may need for things like wget, pip, etc out of the box. Homebrew tries to bridge this gap.
As for troubleshooting your issue, following Homebrew's troubleshooting steps helped me... You are probably just stuck in dependency hell, since Homebrew integrates alot of its libraries with Xcode (for me it was needing to update Xcode to latest): https://github.com/Homebrew/brew/blob/master/docs/Troubleshooting.md#troubleshooting
It's really important to keep thing up-to-date with brew update and then running brew doctor and brew prune resolved alot of issues for me as well.
If all else fails, homebrew seemed to have moved the meld formulae from homebrew/core to caskroom/cask. So I recall having to run the following command after running brew doctor and updating Xcode:
$ brew uninstall meld
$ brew install meld
Error: No available formula with the name "meld"
It was migrated from homebrew/core to caskroom/cask.
You can access it again by running:
brew tap caskroom/cask
$ brew tap caskroom/cask
$ brew cask install meld
==> Downloading https://github.com/yousseb/meld/releases/download/osx-9/meldmerge.dmg
######################################################################## 100.0%
==> Verifying checksum for Cask meld
==> Moving App 'Meld.app' to '/Applications/Meld.app'.
==> Linking Binary 'Meld' to '/usr/local/bin/meld'.
🍺 meld was successfully installed!

What is the exact command to install yum through brew?

I tried installing yum through brew install command. but it is not working with the message below. What is the problem? I can not find any good materials.
$ brew install "yum"
Error: No available formula with the name "yum"
==> Searching for similarly named formulae...
Error: No similarly named formulae found.
==> Searching taps...
Error: No formulae found in taps.
yum is a package manager for Red Hat Linux. It will not work on macOS. brew is a package manager for macOS
So instead of trying to install yum to install another piece of software, you might want to try to install this software using brew directly. But beware: the package names might not be the same. Use brew search to search for packages in brew, or maybe, even better, try and find specific instructions for macOS for the software you're trying to install.

Why can't brew find a specific known formula?

I'm trying to install bazel on my mac (10.11.5).
I can see that it is available through brew:
http://braumeister.org/formula/bazel
But when I run "brew install bazel", I get this:
Error: No available formula for bazel
Searching formulae...
Searching taps...
Why is this?
In my case, Homebrew was already up-to-date after running brew update and I still received the same error messages as the OP when trying to install xdebug:
$ brew update
Already up-to-date.
$ brew install php70-xdebug
Error: No available formula with the name "php70-xdebug"
Using Mark's suggestion from the comments on OP solved the problem:
$ brew search xdebug
homebrew/php/xdebug-osx homebrew/php/php70-xdebug
So now, running $ brew install homebrew/php/php70-xdebug, Homebrew found and installed the package.
You should update your brews, because it is indeed available. Run
brew update
brew install bazel
and then it should work.

brew upgrade Error: No such file or directory - /usr/local/Cellar/autocode

When trying to upgrade homebrew packages, it gives back an error as follows:
$ brew upgrade
Error: No such file or directory - /usr/local/Cellar/autocode
Trying to interact with the autocode package shows that there isn't such a package:
$ brew uninstall autocode
Error: No such keg: /usr/local/Cellar/autocode
How do I fix this?
autocode is the new name of the crystal formula. Instead of uninstalling and reinstalling the formula you can use brew migrate crystal which will move /usr/local/Cellar/crystal to /usr/local/Cellar/autocode and take care of everything for you.
Autocode is the current name of a formula that was previously called Crystal. The Homebrew formula was renamed October 2015. This error is likely showing up because crystal is installed.
It can be fixed with brew uninstall crystal. If Autocode is a dependency of something you use, the newer version can be installed with brew install autocode.

Resources