Re: [CMake] target_sources vs. PUBLIC_HEADER for libraries

2019-10-11 Thread Alex Turbov
Hi, On Fri, Oct 11, 2019 at 9:33 PM Michael Ellery wrote: > I’d like to make sure I understand two different aspects of header files > management for libraries: > > (1) typically you can add header files to target_sources, but it’s only > helpful for IDEs..so that the IDE will show the header fi

Re: [CMake] Shortcomings with exporting and importing targets

2019-07-25 Thread Alex Turbov
l in your project with one > in your generate config file. If you have complicated conditional > dependencies you might be able to use file(GENERATE to determine which > ones will be used. > > > On Thu, Jul 25, 2019 at 11:02 AM Alex Turbov wrote: > > > > > It is th

Re: [CMake] Shortcomings with exporting and importing targets

2019-07-25 Thread Alex Turbov
> It is than up to each project to generate an Config module that does the required find_package calls to re-locate ZLIB. Problems begin when mentioned dependencies are wrapped into generator expressions (e.g. $ or smth even more complicated) -- how do I know what `find_packages` to include to my

Re: [CMake] Using CMake for general scripting tasks?

2017-11-13 Thread Alex Turbov
Hi Sebastian, Particularly I've used CMake "scripts" in some "build configurations" at our CI server as a truly cross-platform scripting language for generic tasks like download archive, check sha/md5, unpack it, do some file operations... it works perfectly for Linux and Windows (it is why I chos

Re: [CMake] Configuration packages & versioning for parallel installations

2017-09-06 Thread Alex Turbov
Hi, On Thu, Sep 7, 2017 at 12:26 AM, Robert Dailey wrote: > First obvious question is: Should this even be a concern? Yes, definitely! > The > cmake-packages documentation doesn't really touch on versioning, but > there are a couple of concerns I see when you want users to be able to > ins

Re: [CMake] [cmake-developers] How should config packages handle components?

2017-09-06 Thread Alex Turbov
In my projects I always, have external dependencies with finder module providing exported (imported in my project) targets, so my targets (one per file) always have a list of `Vendor::target`. Some of them are mine (i.e. your type 2 -- built by the same project). I wrote a helper module and a func

Re: [CMake] [cmake-developers] How should config packages handle components?

2017-09-01 Thread Alex Turbov
in a different set of platform and generators. On Fri, Sep 1, 2017 at 9:49 PM, Robert Dailey wrote: > On Fri, Sep 1, 2017 at 1:40 PM, Alex Turbov wrote: > > Hi Robert, > > > > > > On Fri, Sep 1, 2017 at 9:21 PM, Robert Dailey > > wrote: > >> > >

Re: [CMake] [cmake-developers] How should config packages handle components?

2017-09-01 Thread Alex Turbov
Hi Robert, On Fri, Sep 1, 2017 at 9:21 PM, Robert Dailey wrote: > > One problem I thought of with the former (one big target.cmake with > all import targets in there) is that if you only ask for a subset of > components in find_package(), you will still get all of them since all > imports are d

[CMake] How to install custom target

2017-07-25 Thread Alex Turbov
Hi list, What is the "right" way to install a custom target, when you don't know the result file name? E.g. I have a sample project: cmake_minimum_required(VERSION 3.9) project(custom_target) add_custom_target( log ALL COMMAND ${CMAKE_COMMAND} -E environment > sample-$.log ) # install(

Re: [CMake] hang in FindDoxygen.cmake on ppc64le

2017-06-29 Thread Alex Turbov
> Linux does not understand '(' in name of files and directories; e.g. actually it does. (and Bash != Linux). Anyway, just like a space symbol, you can quote argument w/ braces: $ mkdir -p '/tmp/Just Test (it)' and everything will be fine. As for the code mentioned, all paths are quoted here, so

Re: [CMake] CPack: avoid creating unnecessary man dirs

2016-10-29 Thread Alex Turbov
set `CPACK_INSTALL_PREFIX` to `/usr`... by default it set to `CMAKE_INSTALL_PREFIX` which is `/usr/local` if you don't set it at `cmake` run On Sun, Oct 30, 2016 at 2:39 AM, Robert J. Hansen wrote: > > Use `|CPACK_RPM_EXCLUDE_FROM_AUTO_FILELIST_ADDITION` to add a man's dir > > to 'exclude' list

Re: [CMake] CPack: avoid creating unnecessary man dirs

2016-10-29 Thread Alex Turbov
Use `CPACK_RPM_EXCLUDE_FROM_AUTO_FILELIST_ADDITION` to add a man's dir to 'exclude' list, so RPM package wouldn't have a dir, but files from it... so it wouldn't conflict w/ `filesystem` package. On Sun, Oct 30, 2016 at 12:14 AM, Robert J. Hansen wrote: > I'm migrating a project from Autotools t

[CMake] How to do that w/o LOCATION property of a target...

2015-09-04 Thread Alex Turbov
Hi, in my project I have `add_executable()`. after that, in a current binary dir I need to render a `*.cmake` script (via `configure_file()`) to be running from `add_test()` (as `cmake -P`) which should start just the compiled executable via `execute_process()` and capture its output (to be proces