Re: [CMake] Good practice: using INTERFACE-libraries in FindABC.cmake?

2016-03-01 Thread Patrick Boettcher
On Mon, 29 Feb 2016 21:20:59 +0100 Stephen Kelly wrote: > Patrick Boettcher wrote: > > > I came across the INTERFACE-type of libraries when writing a > > FindModule.cmake-file for custom libraries installed by my > > project. > > You don't provide FindModules for your CMake-built libraries.

[CMake] Visual Studio and ExternalProject_Add

2016-03-01 Thread Kevin Brightwell
I've been having great success with using ExternalProject over the terrible git submodules. However, when using Visual Studio, the following error happens: Performing download step (git clone) for 'catch-lib' 2> Cloning into 'catch-lib'... 2> Note: checking out 'tags/v1.3.4'. 2> 2> You are in

[CMake] best way of parsing test results from ctest + valgrind

2016-03-01 Thread Aaron Boxer
Hello, I am just getting started on using valgrind memory analysis for my tests. When I run ctest with nightly memory check, I get an XML document, but it is very hard to read the results. What is the best way of reading this doc? Thanks! Aaron -- Powered by www.kitware.com Please keep messages

Re: [CMake] CMAKE_THREAD_LIBS_INIT

2016-03-01 Thread Aaron Boxer
OK, figured this one out too. Thank again, Caleb! On Tue, Mar 1, 2016 at 10:48 AM, Aaron Boxer wrote: > Hello, > I am getting link error "undefined reference to pthread_create" > > I have added ${CMAKE_THREAD_LIBS_INIT} in my cmake link line, > and I have added > > FIND_PACKAGE(Threads REQUIRED

[CMake] CMAKE_THREAD_LIBS_INIT

2016-03-01 Thread Aaron Boxer
Hello, I am getting link error "undefined reference to pthread_create" I have added ${CMAKE_THREAD_LIBS_INIT} in my cmake link line, and I have added FIND_PACKAGE(Threads REQUIRED). Here is a link to my cmake file: https://github.com/GrokImageCompression/opendcp/blob/master/libopendcp/CMakeList

Re: [CMake] CMAKE_DL_LIBS

2016-03-01 Thread Aaron Boxer
Thanks! I found the problem: I needed to add CMAKE_DL_LIBS to another static library that the main exe was linking to. Now this link error is gone. On Tue, Mar 1, 2016 at 9:55 AM, J. Caleb Wherry wrote: > That link looks fine to me. You might want to verify that the > CMAKE_DL_LIBS variable act

Re: [CMake] CMAKE_DL_LIBS

2016-03-01 Thread J. Caleb Wherry
That link looks fine to me. You might want to verify that the CMAKE_DL_LIBS variable actually contains what it should on your system (or a least contains what it should right before using it). You could explicitly add the "-dl" to that link statement and see if that works. That's what that variabl

Re: [CMake] CMAKE_DL_LIBS

2016-03-01 Thread J. Caleb Wherry
Most likely solution: missing the "-ldl" link lib which should solve your missing symbol issues. The DSO error is most likely caused by the above. However, there could be a problem with your linking order. I'd have to see the CMake file to be sure. Caleb On Tuesday, March 1, 2016, Aaron Boxer w

[CMake] CMAKE_DL_LIBS

2016-03-01 Thread Aaron Boxer
Hello! I have a CMAKE project that creates an executable that links with a static lib from a second CMAKE project. The static lib requires the dlopen and dlclose symbols. So, when I link the first project, I add ${CMAKE_DL_LIBS} to the CMake file. However, I still get an error about "undefined re

Re: [CMake] CMAKE_DL_LIBS

2016-03-01 Thread Aaron Boxer
On Tue, Mar 1, 2016 at 9:06 AM, Aaron Boxer wrote: > Hello! > I have a CMAKE project that creates an executable that links with a static > lib > from a second CMAKE project. The static lib requires the dlopen and dlclose > symbols. > > So, when I link the first project, I add ${CMAKE_DL_LIBS} to