Re: [CMake] pkg-config file format versus CMake packages

2018-05-31 Thread paul via CMake
On Thu, 2018-05-31 at 10:12 -0400, Brad King wrote: > On 05/25/2018 07:52 PM, Paul Fultz II wrote: > > What else is missing? > > The `.pc` format focuses on flat command-line strings that drop much > of the information used to generate them. For example, if library > A depends on library B then

Re: [CMake] Boost's CMAKE approach and the BUILD_INTERFACE generator expression

2017-10-27 Thread paul via CMake
On Fri, 2017-10-27 at 12:22 -0700, Wesley Smith wrote: > Boost's CMAKE page (http://bcm.readthedocs.io/en/latest/src/Building.html)  > says: > > So this will build the library named boost_filesystem, however, we need to > supply the dependencies to boost_filesystem and add the include

Re: [CMake] [CMAKE] Checking if a file exist at the installing process

2017-10-18 Thread paul via CMake
You can use install(CODE) or install(SCRIPT) to run custom cmake code at install time. The only caveat is the install location is actually `$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}` instead of just `${CMAKE_INSTALL_PREFIX}`. This can happen when the user calls `make DESTDIR=` or during cpack. On Wed,

Re: [CMake] Adding compile and build type tests to CMake/CTest

2017-09-07 Thread paul via CMake
On Thu, 2017-09-07 at 02:58 -0400, Edward Diener wrote: > On 9/6/2017 11:39 PM, P F via CMake wrote: > > > > The `add_test` function can run whatever command you want it to, including > > compiling a target: > > > > add_library(foo_compile_test STATIC EXCLUDE_FROM_ALL foo_compile_test.cpp) > >

[CMake] Interest in adding to CMake the CMakeGet module to get dependencies

2017-08-04 Thread paul via CMake
Hi, I have a written a cmake module to get dependencies using the cget protocol here: https://github.com/pfultz2/cmake-get This is different than `ExternelProject`: * `ExternelProject` happens only during build, which allows this module to work in both in config and script mode.  * In config

Re: [CMake] "Modern" approach to optional/multiple configurations?

2017-07-31 Thread paul via CMake
On Mon, 2017-07-24 at 10:46 +0100, Nicholas Devenish wrote: > Seen in the boost discussions on the CMake announcements: >   > > > The rest can be implemented straightforwardly as cache options so that > > > you can run cmake with options like > > > > > >   -Dvalgrind=OFF -Dtransactional-memory=ON

Re: [CMake] Evaluate generator expressions with install interface

2017-05-31 Thread paul via CMake
So if I do something like this: function(auto_pkgconfig TARGET) get_target_property(INCLUDE_DIRS ${TARGET} INTERFACE_INCLUDE_DIRECTORIES) string(REPLACE "$