Quantcast

can't locate library with find_library

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

can't locate library with find_library

Oliver-2
hi all,

I am running cmake 3 using EPEL install on RHEL 7. I also have installed "gflags", 



$rpm -ql gflags
/usr/bin/gflags_completions.sh
/usr/lib64/libgflags.so.2.1
/usr/lib64/libgflags_nothreads.so.2.1
/usr/share/doc/gflags-2.1.1
/usr/share/doc/gflags-2.1.1/AUTHORS.txt
/usr/share/doc/gflags-2.1.1/COPYING.txt
/usr/share/doc/gflags-2.1.1/ChangeLog.txt
/usr/share/doc/gflags-2.1.1/README.txt
 
but my check fails:

# glags 
find_library(GFLAGS_LIB NAMES gflags PATHS /usr/lib64 /usr/lib /usr/local/lib)

if (NOT GFLAGS_LIB) 
    message(STATUS "gflags is not present, you can still control logging through env settings")
    message(STATUS "    GLOG_logtostderr=1 ./your_application")
else()
    message(STATUS "gflags is present, you can controll logging through command line:")
    message(STATUS "    ./your_application --logtostderr=1")
endif()


what did I do wrong? thx.





--
Oliver

--

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:
http://public.kitware.com/mailman/listinfo/cmake
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: can't locate library with find_library

Nils Gladitz-2
On 22.03.2017 14:52, Oliver wrote:

> hi all,
>
> I am running cmake 3 using EPEL install on RHEL 7. I also have
> installed "gflags",
>
>
>
> $rpm -ql gflags
> /usr/bin/gflags_completions.sh
> /usr/lib64/libgflags.so.2.1
> /usr/lib64/libgflags_nothreads.so.2.1
> /usr/share/doc/gflags-2.1.1
> /usr/share/doc/gflags-2.1.1/AUTHORS.txt
> /usr/share/doc/gflags-2.1.1/COPYING.txt
> /usr/share/doc/gflags-2.1.1/ChangeLog.txt
> /usr/share/doc/gflags-2.1.1/README.txt
>

Did you also install the corresponding development package e.g.
"gflags-devel"?

Nils
--

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:
http://public.kitware.com/mailman/listinfo/cmake
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: can't locate library with find_library

Oliver-2
oh, no, silly me, I didn't.
that fixed the problem.

thx

Feiyi

On Wed, Mar 22, 2017 at 10:08 AM, Nils Gladitz <[hidden email]> wrote:
On <a href="tel:22.03.2017%2014" value="+12203201714" target="_blank">22.03.2017 14:52, Oliver wrote:
hi all,

I am running cmake 3 using EPEL install on RHEL 7. I also have installed "gflags",



$rpm -ql gflags
/usr/bin/gflags_completions.sh
/usr/lib64/libgflags.so.2.1
/usr/lib64/libgflags_nothreads.so.2.1
/usr/share/doc/gflags-2.1.1
/usr/share/doc/gflags-2.1.1/AUTHORS.txt
/usr/share/doc/gflags-2.1.1/COPYING.txt
/usr/share/doc/gflags-2.1.1/ChangeLog.txt
/usr/share/doc/gflags-2.1.1/README.txt


Did you also install the corresponding development package e.g. "gflags-devel"?

Nils



--
Oliver

--

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:
http://public.kitware.com/mailman/listinfo/cmake
Loading...