Linuxbrew-core: cmake: $(brew --prefix)/include : $(brew --prefix)/lib are not added to default configuration

Created on 14 Nov 2016  路  8Comments  路  Source: Homebrew/linuxbrew-core

For brewed cmake, including those location would be a sane default and absence of those location in default search paths seem like a bug to me.

outdated question stale

Most helpful comment

Ok, I will.

All 8 comments

Path configuration is done inside <cmake>/share/cmake/Modules/Platform/UnixPaths.cmake.

Probably, we should append homebrew paths there in postinstall step.

brew install gcc also resolves this issue, as it includes these two paths by default. That's my recommended solution. Does that work for you?

I need to check, but I believe find_package and friends search only in CMake paths, not in compiler ones. Because we have gcc installed and it doesn't work.

Ah, sad boat. I like autoconf because it checks whether your compiler can find the necessary headers and libraries.

Which formula are you attempting to build that's failing and led you to this solution?

It's not formulas, but using brewed cmake to build some research apps that are built with cmake.

Now that I've looked at its contents, yes, UnixPaths.cmake should definitely be customized for Linuxbrew. In particular all the default system paths that are not relevant for Linuxbrew should be removed. System libraries can cause a lot of havoc when a system library is found instead of the Linuxbrew library. Would you like to take a go at creating a PR to modify UnixPaths.cmake?

Ok, I will.

Was this page helpful?
0 / 5 - 0 ratings