A1A2A3A4
A1A2A3A4

Reputation: 453

Exclude library directory from being search for by CMake

I have two different locations for the same library .so file and need to prevent CMake from searching for both locations. How can I do something like this with something similar to but opposite in effect of the include_directories macro in my CMakeLists.txt?

Upvotes: 1

Views: 1879

Answers (1)

arrowd
arrowd

Reputation: 34401

Documentation lists directories order, in which CMake performs search. As you can see, CMake would always pick up library from /usr/lib or /usr/local/lib unless you set NO_CMAKE_SYSTEM_PATH.

You can play with HINTS until you get desired effect, but it'd better if you explain why you need such thing in the first place.

Upvotes: 1

Related Questions