Thank you Marc.

That's interesting, I was not aware that they were relinked. I thought they
were just copied.

I guess I'll have to provide the install directory to pick the libraries
found in the install directory instead of the build directory?

Regards,
Saad

On Fri, Jan 12, 2018 at 2:57 AM CHEVRIER, Marc <[email protected]>
wrote:

> Hi,
>
>
>
> During install step, installed libraries and executables are relinked to
> generate binaries without absolute paths so installed artifacts are
> independent from your build tree.
>
>
>
> During build step, build binaries are used as well as absolute paths so
> produced binaries can be used during build step (i.e. launching an
> executable produced) without requirements regarding paths settings (i.e.
> PATH or LD_LIBRARY_PATH).
>
>
>
>
>
> *From: *CMake <[email protected]> on behalf of Saad Khattak <
> [email protected]>
> *Date: *Thursday 11 January 2018 at 19:44
> *To: *Cmake Mailing List <[email protected]>
> *Subject: *[CMake] Get find_package to choose INSTALLed libraries instead
> of libraries in the build folder
>
>
>
> Hi,
>
>
>
> I would like find_package(MyLib) to link find the libraries found in the
> INSTALL folder instead of the build folder.
>
>
>
> Currently, when I do a find_package(MyLib) and then
> target_link_libraries(target MyLib) the paths all point to MyLib's build
> folder and not the folder where MyLib's library/headers were installed.
>
>
>
> Thank you,
>
> Saad
>
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
https://cmake.org/mailman/listinfo/cmake

Reply via email to