Re: [CMake] Documentation for CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT missing?

2011-03-21 Thread Johannes Zarl
to be changed... Cheers, Johannes -- Johannes Zarl Virtual Reality Services Johannes Kepler University Informationsmanagement Altenbergerstrasze 69 4040 Linz, Austria Phone: +43 732 2468-8321 johannes.z...@jku.at http://vrc.zid.jku.at

Re: [CMake] CMake and include only libraries

2011-04-05 Thread Johannes Zarl
better at handling header files. And since this feature request has already been discussed in http://public.kitware.com/Bug/view.php?id=115, I'm content with it only being deferred, not dismissed... -- Johannes Zarl Virtual Reality Services Johannes Kepler University Informationsmanagement

Re: [CMake] Wiki: version compatibility matrix

2011-07-26 Thread Johannes Zarl
Apparently I forgot to add the list in my reply to Alexander, so here for all to read: Now that I'm back from my vacation, I'll get to it soonish (during August). Cheers, Johannes On 07/14/2011 at 14:03, Clifford Yapp cliffy...@gmail.com wrote: On Tue, Jul 12, 2011 at 4:58 PM, Alexander

Re: [CMake] Wiki: version compatibility matrix - please add feedback

2011-07-30 Thread Johannes Zarl
Hi, So I've started bringing the matrix up to date. Just to make sure I'm not reporting documentation-changes as real changes, please take a look at the following items and correct me where I'm wrong: Changes from 2.8.3 to 2.8.4: * get_cmake_property: previously

[CMake] Wiki: enabling Cite extension?

2011-08-04 Thread Johannes Zarl
Hi, Working on the version compatibility matrix (which is now up-to-date once again), I came to think that the Cite extension for MediaWiki (http://www.mediawiki.org/wiki/Extension:Cite) would allow the compatibility matrix to be much more compact (by moving additional notes from the matrix

[CMake] Wiki spam

2011-08-09 Thread Johannes Zarl
Hi, I just noticed that some spam pages seem to have been inserted into the wiki using these user accounts: http://www.cmake.org/Wiki/Special:Contributions/Carinsurancecarinsurancequotes http://www.cmake.org/Wiki/Special:Contributions/Sarawilliam30

Re: [CMake] Wiki: version compatibility matrix

2011-10-05 Thread Johannes Zarl
Hi, I'll probably get to it in the next 1-3 weeks... Cheers, Johannes On 10/05/2011 at 16:51, David Cole david.c...@kitware.com wrote: On Tue, Jul 12, 2011 at 4:58 PM, Alexander Neundorf a.neundorf-w...@gmx.net wrote: Hi, On Saturday 04 December 2010, Johannes Zarl wrote: Hello

Re: [CMake] Wiki: version compatibility matrix

2011-10-28 Thread Johannes Zarl
Hello David, I just finished the updated version for 2.8.6. Can you maybe check again with the wiki admins if the Cite extension can be added to the CMake wiki? Cheers, Johannes Ceterum censeo emendationem Cite esse immuniendam. On Wednesday 05 October 2011 16:51:43 David Cole wrote:

Re: [CMake] hear hear

2011-12-12 Thread Johannes Zarl
On Tuesday, 6. December 2011, 17:27:47, Daniel Dekkers wrote: On Dec 4, 2011, at 11:59 AM, Michael Jackson wrote: I think if the CMake community took a vote we could probably come up with an Exemplar Find*.cmake file that is good for someone trying to develop a new one. Yes please. And

Re: [CMake] shell level access to values of cmake variables

2011-12-20 Thread Johannes Zarl
Am Thursday, 10. November 2011, 18:48:06 schrieb vagn scott: is there something like cmake --dump-var PROJECT_NAME that would output the string hello_foo_baz As far as I know CMake doesn't do this out of the box. As long as you have a configured build tree and only want to

Re: [CMake] Wiki: version compatibility matrix

2012-01-02 Thread Johannes Zarl
Hi David, I guess I'll have time this week to update the matrix. In case the admin team would like to have a rationale for installing the Cite extension: Having the Cite extension would allow me to write the matrix in a more compact/less cluttered style. Thanks for lobbying for this issue!

Re: [CMake] Wiki: version compatibility matrix

2012-01-05 Thread Johannes Zarl
Hi David, This is great news! I have updated the matrix to use footnotes, and also added the 2.8.7 changes to it. The whole matrix now looks much more clearly: http://www.cmake.org/Wiki/CMake_Version_Compatibility_Matrix Cheers, Johannes On Tuesday 03 January 2012 17:25:31 David Cole wrote:

Re: [CMake] Revision header

2012-01-23 Thread Johannes Zarl
On Saturday, 21. January 2012, 22:51:01, Oliver Smith wrote: I have a script that generates a revision.h file, I've spent the morning trying to figure out how to make it so that ... any time CMake rebuilds any of the other targets, it starts by running the make-new-revision script. The idea

Re: [CMake] Compile CMakeCache.txt into shared library

2012-02-08 Thread Johannes Zarl
Hi, I'm not sure if I understand you correctly, but I would guess that in most cases you don't need to know _all_ cmake cache variables at runtime. If you really just need to know some specific variables, you would be much better off using a generated header file. See the documentation for

Re: [CMake] providing library information, what's the cmake way

2010-11-23 Thread Johannes Zarl
[5] http://modules.sourceforge.net/ -- Johannes Zarl Virtual Reality Services Johannes Kepler University Informationsmanagement Altenbergerstrasze 69 4040 Linz, Austria Phone: +43 732 2468-8321 johannes.z...@jku.at http://vrc.zid.jku.at

Re: [CMake] providing library information, what's the cmake way

2010-11-25 Thread Johannes Zarl
On Wednesday 24 November 2010 19:03:21 David Cole wrote: On Wed, Nov 24, 2010 at 12:58 PM, Tyler Roscoe ty...@cryptio.net wrote: On Wed, Nov 24, 2010 at 11:41:46AM -0500, David Cole wrote: On Wed, Nov 24, 2010 at 11:34 AM, Rolf Eike Beer e...@sf-mail.de wrote: So I think it is _really_

Re: [CMake] providing library information, what's the cmake way

2010-11-26 Thread Johannes Zarl
On Friday 26 November 2010 10:49:01 Eric Noulard wrote: From the information in http://www.cmake.org/Wiki/CMake_Released_Versions and using some shell-scripts to create the diffs between all neighbor-versions, it's not too much work to create a compatibility matrix for the documented

Re: [CMake] providing library information, what's the cmake way

2010-11-29 Thread Johannes Zarl
Sorry for the late response, but your mail was simply to long for a swift response... On 11/26/2010 at 05:47, Michael Hertling mhertl...@online.de wrote: On 11/24/2010 04:51 PM, Johannes Zarl wrote: About the components question again: I played around a bit, and I think I now more or less

Re: [CMake] providing library information, what's the cmake way

2010-11-29 Thread Johannes Zarl
On 11/29/2010 at 14:28, Johannes Zarl johannes.z...@jku.at wrote: On 11/26/2010 at 05:47, Michael Hertling mhertl...@online.de wrote: See [1] for a former discussion of several aspects regarding multi-component packages. [...] [1] http://www.mail-archive.com/cmake@cmake.org/msg28431.html

Re: [CMake] providing library information, what's the cmake way

2010-11-30 Thread Johannes Zarl
empty. Which is to be expected, given that Boost is mostly a headers-only library. Still, after your find_package call for Boost alone, you can use all Boost core libraries. -- Johannes Zarl Virtual Reality Services Johannes Kepler University Informationsmanagement Altenbergerstrasze 69 4040

Re: [CMake] providing library information, what's the cmake way

2010-12-01 Thread Johannes Zarl
their own stuff to these libraries. So this really isn't a fundamental difference between multi-component packages and multi single-component packages. -- Johannes Zarl Virtual Reality Services Johannes Kepler University Informationsmanagement Altenbergerstrasze 69 4040 Linz, Austria Phone: +43 732

Re: [CMake] providing library information, what's the cmake way

2010-12-03 Thread Johannes Zarl
On Wednesday 01 December 2010 17:57:45 Johannes Zarl wrote: Back to my proposed FPCHSA: My initial goal was to provide an interface which does as much work as possible for you, maybe at the price of restricted variable naming. So let's come up with a better interface: I do want to restrict

[CMake] Wiki: version compatibility matrix

2010-12-04 Thread Johannes Zarl
Hello, The compatibility matrix for different versions of cmake is now complete and awaits review: http://www.cmake.org/Wiki/CMake_Version_Compatibility_Matrix Apart from factual errors and things I might have missed, I am also interested if someone has a better idea for embedding the

Re: [CMake] Wiki: version compatibility matrix

2010-12-06 Thread Johannes Zarl
contribute your helper scripts to the CMake code base itself? (Somewhere under CMake/Utilities perhaps...) Sure, no problem. I don't have write-access to the code base, though. I'll just send it to you, if that's ok... Johannes -- Johannes Zarl Virtual Reality Services Johannes Kepler University

Re: [CMake] providing library information, what's the cmake way

2010-12-09 Thread Johannes Zarl
At this point of the discussion, I think that we need someone else to join. We both have made strong points for our viewpoints, and neither of us has a perfect solution. On Sunday 05 December 2010 12:48:49 Michael Hertling wrote: On 12/01/2010 05:57 PM, Johannes Zarl wrote: On 12/01/2010

[CMake] Weird behaviour of functions with list arguments

2010-12-11 Thread Johannes Zarl
Hello, I noticed that when defining a function, one can access lists as arguments using named arguments or ARGV0..ARGVn, but not using ARGV and ARGN. To elaborate, assuming the function list_as_args defined as follows: function(list_as_arg) message(STATUS ${ARGC} arguments, ARGV: ${ARGV})

[CMake] Component support in FindPackageHandleStandardArgs

2010-12-13 Thread Johannes Zarl
XXX_INCLUDE_DIR COMPONENTS COMPONENT YYY XXX_YYY_LIBRARY XXX_YYY_INCLUDE_DIR COMPONENT ZZZ XXX_ZZZ_LIBRARY XXX_ZZZ_INCLUDE_DIR ) The attached patch implements this syntax for FPHSA. Is this a desirable extension to FPHSA? Cheers, Johannes -- Johannes Zarl Virtual Reality Services

Re: [CMake] Weird behaviour of functions with list arguments

2011-01-19 Thread Johannes Zarl
On 01/18/2011 at 20:51, Alexander Neundorf a.neundorf-w...@gmx.net wrote: On Saturday 11 December 2010, Johannes Zarl wrote: So ARGV0 is not the same as the first argument of ARGV. Why? Is it that the ARGV and ARGN lists get flattened, but the ARGVx are assigned before that? How can I

Re: [CMake] Component support in FindPackageHandleStandardArgs

2011-01-19 Thread Johannes Zarl
On 01/18/2011 at 20:54, Alexander Neundorf a.neundorf-w...@gmx.net wrote: On Monday 13 December 2010, Johannes Zarl wrote: The three FPHSA calls from above could be written using this syntax as: FPHSA(XXX REQUIRED_VARS XXX_LIBRARY XXX_INCLUDE_DIR COMPONENTS COMPONENT YYY

[CMake] Documentation for CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT missing?

2011-03-07 Thread Johannes Zarl
Hi, I just wanted to read the documentation on CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT, but discovered that the variable is not listed in the cmake docs. Is there a reason for this? Should I open a bugreport on it? Cheers, Johannes -- Johannes Zarl Virtual Reality Services Johannes

Re: [CMake] newbie q - where do I put what in which CMakeLists file? out of source build

2011-03-09 Thread Johannes Zarl
evaluates to /path/to/tone12/build/src.) HTH, Johannes -- Johannes Zarl Virtual Reality Services Johannes Kepler University Informationsmanagement Altenbergerstrasze 69 4040 Linz, Austria Phone: +43 732 2468-8321 johannes.z...@jku.at http://vrc.zid.jku.at

Re: [CMake] Functions inherit parent variables?

2012-03-05 Thread Johannes Zarl
On Saturday 03 March 2012, 02:29:05, Robert Dailey wrote: Well you're really comparing apples to oranges. C++ nested scoping rules really have nothing to do with two separate functions sharing scoped variables. It doesn't even really serve as a good analogy, so I can't be 100% certain what you

Re: [CMake] Functions inherit parent variables?

2012-03-07 Thread Johannes Zarl
Drifting away from the original thread topic... On Tuesday 06 March 2012, 08:09:27, Michael Hertling wrote: IMO, the documentation of the PARENT_SCOPE flag is sufficiently clear: If PARENT_SCOPE is present, the variable will be set in the scope *above* the current scope. Each new directory

Re: [CMake] Wiki: version compatibility matrix

2012-04-23 Thread Johannes Zarl
, 2012 at 4:47 PM, Johannes Zarl johannes.z...@jku.at wrote: Hi David, This is great news! I have updated the matrix to use footnotes, and also added the 2.8.7 changes to it. The whole matrix now looks much more clearly: http://www.cmake.org/Wiki/CMake_Version_Compatibility_Matrix

Re: [CMake] Wiki: version compatibility matrix

2012-04-28 Thread Johannes Zarl
Hi David, I tried to upload the new matrix today, but the page on standard modules is too big (112kb): On my current internet connection I get a timeout before the upload finishes. Maybe you can do the upload? The text is available from https://github.com/jzarl/cmake-

Re: [CMake] Fwd: module and cmake

2012-05-19 Thread Johannes Zarl
Hello Paul, I don't know about your specific find_package file for FFTW, but we do use modules together with CMake, so I'll add my thoughts: As Eric already said, the modules command alters your environment. CMake doesn't know about shell modules, but most find_package commands provide some

[CMake] Disabling C for C++-only projects

2012-07-25 Thread Johannes Zarl
Hi, Out of curiosity (and thinking about saving a couple of seconds during the first cmake run) I tried just to use C++ as language for some KDE program. It turns out that without C enabled, standard modules like FindKDE, FindQt4 and FindJPEG don't run because they use the CheckSymbolExists

Re: [CMake] Disabling C for C++-only projects

2012-07-26 Thread Johannes Zarl
On Wednesday 25 July 2012 22:20:55 Clinton Stimpson wrote: On Wednesday, July 25, 2012 10:06:27 PM Johannes Zarl wrote: I'm wondering if this counts as a bug in FindQt4 and FindKDE, because after all these two projects are C++, so any platform test should IMO be using the same compiler

Re: [CMake] Disabling C for C++-only projects

2012-07-30 Thread Johannes Zarl
Am 26.07.2012, 17:53:01 schrieb Alexander Neundorf: On Thursday 26 July 2012, Johannes Zarl wrote: On Wednesday 25 July 2012 22:20:55 Clinton Stimpson wrote: This has already been fixed in FindQt4 since CMake 2.8.6. ...using cmake 2.8.9-rc1 from debian. if you use it together

Re: [CMake] Bug fix requests for the *next* release of CMake...

2012-08-13 Thread Johannes Zarl
http://public.kitware.com/Bug/view.php?id=12373 -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to

Re: [CMake] Total cmake newbie needs some help

2012-08-20 Thread Johannes Zarl
On Saturday, 18. August 2012, 00:16:41, Edgar wrote: I have these problems - 1) Cmake cannot find ZLIB 2) Cmake cannot find LIBPNG There are some .cmake files named FindALLEGRO, and FindFREETYPE, and those work properly. Do I need to create similar cmake files for zlib and libpng? Those

Re: [CMake] New wiki page CMake Live Cycle Considerations

2012-10-09 Thread Johannes Zarl
Thanks for the roses, Alex ;-) On Monday, 8. October 2012, 20:24:32, Alexander Neundorf wrote: Hi, I just found this new page in the cmake wiki and I think this is very useful information: http://www.cmake.org/Wiki/CMake_Live_Cycle_Considerations Please help keeping it up-to-date

Re: [CMake] New wiki page CMake Live Cycle Considerations

2012-10-09 Thread Johannes Zarl
On Tuesday, 9. October 2012, 12:25:51, Matt Williams wrote: On 8 October 2012 19:24, Alexander Neundorf a.neundorf-w...@gmx.net wrote: Hi, I just found this new page in the cmake wiki and I think this is very useful information: http://www.cmake.org/Wiki/CMake_Live_Cycle_Considerations

Re: [CMake] How to use CMAKE_POLICY?

2012-12-18 Thread Johannes Zarl
Sorry if I add to the confusion, but shouldn't set cmake_minimum_required automatically set all policies newer than the specified version to old? Johannes On Monday, 17. December 2012, 17:57:18, Alexander Neundorf wrote: On Monday 17 December 2012, David Cole wrote: I thought we wanted

Re: [CMake] The else() in CMAKE_TOOLCHAIN_FILE

2013-04-03 Thread Johannes Zarl
Hi, On Tuesday, 2. April 2013, 06:42:47, Ashi wrote: I think I find something to explain this: the config.cmake(the CMAKE_TOOLCHAIN_FILE) is reloaded several times. on first-load, the A is set, but on second-load and later-load, the A is not set. I think I can get around this problem when A

Re: [CMake] Compiling object files.

2013-04-03 Thread Johannes Zarl
Hi Daniel, On Wednesday, 3. April 2013, 16:06:36, Daniel Carrera wrote: Summary: How do I use CMake to compile object files? Or is this the wrong question to ask? (i.e. *should* I be compiling object files?) Short answer: normally you don't and you shouldn't add statements to compile object

Re: [CMake] CTest / CDash integration

2013-04-10 Thread Johannes Zarl
Probably someone else can give you a better answer, but I ended up doing the following: ctest \ --build-and-test $SOURCE_DIR $BUILD_DIR \ --build-generator Unix Makefiles --build-makeprogram make \ -j $PARALLEL_JOBS \ --build-options -DCMAKE_CXX_COMPILER=$CXX -DCMAKE_C_COMPILER=$CC \

Re: [CMake] The source directory

2013-04-18 Thread Johannes Zarl
Hi, On Thursday, 18. April 2013, 09:02:13, 中野佑香 wrote: $ tar -xvzf gromacs-4.6.1.tar.gz $ cd gromacs-4.6.1 $ mkdir build $ cd build $ cmake .. However, I got an error. --- CMake Error: The source directory

Re: [CMake] Wiki: version compatibility matrix

2013-05-27 Thread Johannes Zarl
Hi, Am 23.05.2013, 19:38:26 schrieb Alexander Neundorf: the matrix is getting a bit out of date, the last update is for 2.8.8. Can you try to create an updated version ? No problem, I'll do it somewhere in the next few weeks. Johannes -- Powered by www.kitware.com Visit other Kitware

Re: [CMake] Versioning and release/distribution management with cmake and git

2013-09-25 Thread Johannes Zarl
Hi, On Monday, 23. September 2013, 23:41:19, Roger Leigh wrote: Another minor annoyance I've run into is that when I define a function and make use of a global variable, it appears to expand the variable during definition, rather than evaluating it when I call the function. Is it possible to

Re: [CMake] How to write a correct wrapper of MESSAGE()?

2013-10-09 Thread Johannes Zarl
I guess you search for something like this: function(info) set(msg) foreach(i RANGE ${ARGC}) set(msg ${msg}${ARGV${i}}) endforeach() message(STATUS [info] ${msg}) endfunction() message(Foo:bar;baz space FOO) info(Foo:bar;baz space FOO) message(two words) info(two words)

Re: [CMake] ARGC != list(LENGTH ARGV) and ARGV0 != list(GET ARGV 0)

2013-10-14 Thread Johannes Zarl
CMake will not expand a string into a list when passed as arguments. It would do when using a variable: While this is true, it's also not the whole truth (and I guess is that this is bothering Clark). Consider the following two function calls: foo1(a;b;c) foo2(a;b c) Of course cmake

Re: [CMake] How to write a correct wrapper of MESSAGE()?

2013-10-15 Thread Johannes Zarl
On Monday, 14. October 2013, 19:07:06, Matthew Woehlke wrote: The IN LISTS signature of foreach seems to do additional list splitting, leading to (foo;bar baz) appearing as 3 elements. Accessing the ARGV array by the positional indices (e.g. ${ARGV0}) prevents the splitting. Really?

[CMake] How to test for the usability of a target

2013-10-15 Thread Johannes Zarl
Hi, I'd like to make some code in my build system dependent on the existance of a target. Basically I'd like to write something like this: if(TARGET optional_lib) add_library(bar ${bar_srcs}) target_link_library(bar optional_lib) endif() The problem I have is that for a couple of reasons

Re: [CMake] How to test for the usability of a target

2013-10-16 Thread Johannes Zarl
On Wednesday, 16. October 2013, 01:22:09, Matthew Woehlke wrote: If you *REALLY* need to know about all your targets before you decide on linking, then you're going to have to implement multi-pass project parsing. This is possible - see e.g. VTK - but makes the configuration process much more

Re: [CMake] How to test for the usability of a target

2013-10-21 Thread Johannes Zarl
On Wednesday, 16. October 2013, 19:45:32, Alexander Neundorf wrote: On Tuesday 15 October 2013, Johannes Zarl wrote: I'd like to make some code in my build system dependent on the existance of a target. Basically I'd like to write something like this: if(TARGET optional_lib

Re: [CMake] How to write a correct wrapper of MESSAGE()?

2013-10-21 Thread Johannes Zarl
On Thursday, 17. October 2013, 07:12:51, Clark WANG wrote: When I'm using CMake more and more I find it's not a real serious language. It's so tricky. I can see why you are frustrated. I don't think it's all bad though. Hopefully CMake3 will be used for some language cleanups at the expense of

[CMake] Wiki update needed: CMake/Tutorials/How to create a ProjectConfig.cmake file

2013-11-13 Thread Johannes Zarl
Hi, I noticed that the tutorial for creating ProjectConfig files[1] in the wiki is not really up to date anymore. To be precise, the CMakePackageConfigHelpers cmake module is not mentioned on the page. The main author of the tutorial goes by the username Themiwi. @Themiwi: if you are reading

Re: [CMake] CMake and shared|static/release|debug?

2014-02-05 Thread Johannes Zarl
Hi, On Tuesday, 4. February 2014, 23:41:55, Littlefield, Tyler wrote: I've tried this a few different ways and ran into issues. If someone wouldn't mind pointing out where I'm going wrong, I would appreciate it. (for example if there's a better way to do what I'm trying). It would help if you

Re: [CMake] Overriding found jpeg

2014-02-06 Thread Johannes Zarl
On Thursday, 6. February 2014, 13:30:54, Ramin Kamal wrote: Thanks! I tried that, but it still finds the system library. Here's my test setup: I tried with basically the same steps, and it works for me. % cd /usr/lib % cp libjpeg.* /tmp/myjpeg/lib/ [...] -- Found JPEG:

Re: [CMake] Explanation....

2014-04-14 Thread Johannes Zarl
Hello Theo, On Friday, 11. April 2014, 14:20:36, Theodore Papadopoulo wrote: ::-B-:: - This shows that B is indeed parsed as OPTIONAL A A- Fine I'm in the else part of the if OPTIONAL HERE - Fine. ... I guess OPTIONAL should read TOTO. You say it's fine, but it's probably

Re: [CMake] Explanation....

2014-04-16 Thread Johannes Zarl
Hi, On Monday, 14. April 2014, 19:23:19, Theodore Papadopoulo wrote: if (${arg} STREQUAL TOTO) - if (TOTO STREQUAL TOTO) - if (B STREQUAL B) What I do not follow is why there is an implicit evaluation of TOTO into B (in both this case or the next I explicitely asked for a string

Re: [CMake] Explanation....

2014-04-16 Thread Johannes Zarl
On Wednesday, 16. April 2014, 12:03:30, Rolf Eike Beer wrote: Instead of ``${var} STREQUAL VALUE'', write: IF ( var MATCHES ^VALUE$ ) NO, please don't! I try hard to kill all those as it requires compiling a regular expression for a simple string match. Just change it to something

Re: [CMake] Explanation....

2014-04-24 Thread Johannes Zarl
On Wednesday, 23. April 2014, 18:54:39, Matthew Woehlke wrote: if ( ${arg} STREQUAL TOTO) set( TOTO evil) You sure? When I checked, this did not work. Also, the following gives me a syntax error: set ( foo Evil!) message( ${ foo}) Syntax error in cmake code at

Re: [CMake] Explanation....

2014-04-28 Thread Johannes Zarl
On Thursday, 24. April 2014, 17:34:40, Matthew Woehlke wrote: On 2014-04-24 04:53, Johannes Zarl wrote: On Wednesday, 23. April 2014, 18:54:39, Matthew Woehlke wrote: if ( ${arg} STREQUAL TOTO) set( TOTO evil) You sure? When I checked, this did not work. Are *you* sure? :-) Yes

[CMake] Typo in cmake-packages(7)

2014-07-28 Thread Johannes Zarl
Hi, In cmake-packages(7) [1], there is a typo that prevents the example from working correctly. The command configure_file(cmake/ClimbingStatsConfig.cmake ${CMAKE_CURRENT_BINARY_DIR}/ClimbingStats/ClimbingStatsConfig.cmake COPY_ONLY ) should use COPYONLY, not COPY_ONLY. Cheers,

Re: [CMake] Install path for package files

2014-10-06 Thread Johannes Zarl
As is also written in the stackoverflow answer, this information can be found in the cmake documentation for find_package[1]: prefix/ (W) prefix/(cmake|CMake)/ (W) prefix/name*/

Re: [CMake] 2 libs stuck together !

2014-10-15 Thread Johannes Zarl
Hi, It would be a lot easier to help you if you tried to minimize the CMakeLists.txt file before posting it to the list. The file as you posted it contains many unrelated stuff and even commented-out lines. Not wanting to look at the whole thing as it is, my advice to you is to search for the

Re: [CMake] Is this the proper way to define a package config?

2014-10-23 Thread Johannes Zarl
Hi, Assuming you are not a boost developer / your changes won't be upstreamed, then creating a BoostConfig.cmake file won't do you much good. If someone wants to use your project, he/she will have to patch the locally installed boost version to include a BoostConfig.cmake file. You might want

[CMake] Diagnostics for unclosed generator expressions?

2014-11-17 Thread Johannes Zarl
Hi, Today I learned the hard way that cmake does not provide any diagnostic about unclosed generator expressions. Consider the following: add_test( NAME generator_expression_unclosed COMMAND ${CMAKE_COMMAND} -E echo $0:Unclosed expression gives a warning? ) cmake happily accepts this

Re: [CMake] 64 bit build of wxWidgets-2.8.12 is not found

2014-12-15 Thread Johannes Zarl
Hello Robert, I don't have a test-environment handy, but it seems like FindwxWidgets checks for the vc_x64 library directory prefix, not for vc_amd64: # /usr/share/cmake-3.0/Modules/FindwxWidgets.cmake:511: if(MINGW) set(WX_LIB_DIR_PREFIX gcc) elseif(CMAKE_CL_64)

Re: [CMake] CMake Version Compatibility Matrix

2015-03-02 Thread Johannes Zarl
Hi, Is there any chance that the version compatibility matrix will be updated for cmake 3.x features? Short answer: no. Longer answer: I've written and maintained the compatibility matrix before. The reasons I've stopped maintaining the page: (1) Distilling the changes between versions is

Re: [CMake] ExternalProject: how to avoid reinstalling after 'make clean'?

2015-04-28 Thread Johannes Zarl
Hi Cedric, This is something that ExternalProject cannot really do for you in an automatic/safe way. When you do a make clean, you wipe out all knowledge about the installed package. However, you can implement this yourself: Before you do the ExternalProject_Add(eigen ...) call, you can call

Re: [CMake] cmp0065

2016-07-06 Thread Johannes Zarl
Hi, On Wednesday 06 July 2016 08:43:44 you wrote: > > #if defined(WIN32) > > #endif > > not WIN32 that way... as in add_executable( something WIN32 ... ) (or not > WIN32) I'm not sure I can follow. I thought you want to have compile time definitions like "-DSOMETHING" for GCC or "/DSOMETHING"

Re: [CMake] Check_include_file is supposed make a definition?

2015-06-10 Thread Johannes Zarl-Zierl
On Wednesday 10 June 2015 00:48:06 J Decker wrote: CHECK_INCLUDE_FILE(stdint.h HAVE_STDINT_H) is this supposed to create some sort of ADD_DEFINITION( -DHAVE_STDINT_H) ? No. if not what else do I have to do to make that work? IF(HAVE_STDINT_H) ADD_DEFINITION(HAVE_STDINT_H) ENDIF() If you

Re: [CMake] How does :: actually works?

2015-06-11 Thread Johannes Zarl-Zierl
Hi, I tried several times now to find documentation about how to define and use target names which seem to have namespaces, like Qt ones. For example: add_executable( MyProject::some_target ... ) AFAIK target namespaces are intended for imported targets, not regular targets: A NAMESPACE

Re: [CMake] How does :: actually works?

2015-06-15 Thread Johannes Zarl-Zierl
On Monday 15 June 2015 16:40:10 Klaim - Joël Lamotte wrote: So far I didn't get what imported targets helps with, so I'm a bit lost on the usefulness of namespaces but I am sure that I am missing something. Imported targets improve the handling of find_package stuff. In the old days, the

Re: [CMake] How does :: actually works?

2015-06-16 Thread Johannes Zarl-Zierl
On Monday 15 June 2015 22:43:41 you wrote: Just a last question: I assume that most find module scripts distributed with cmake are not using this feature at the moment, right? Sadly, no. After reading your explaination I looked at documentation for FindBoost and FindGTest which are both

Re: [CMake] using source files in build directory

2015-10-23 Thread Johannes Zarl-Zierl
Hi, For header files, that's quite a normal thing to do - you just need to add the CMAKE_CURRENT_BINARY_DIR to your include directories. For .cpp files, you can write your target so that it is referencing the source file in the binary directory. I.e.: configure_file(

Re: [CMake] C++11 flag not being added

2015-10-13 Thread Johannes Zarl-Zierl
Hi, CXX_STANDARD is a target property, not a global one. You can either set CXX_STANDARD for every target that needs it, or set it globally by changing the default value. You can do the latter by setting the variable CMAKE_CXX_STANDARD before defining any target that depends on it:

Re: [CMake] General cross platform stating place

2015-09-08 Thread Johannes Zarl-Zierl
Hi, On Monday 07 September 2015 23:47:35 Aaron Gray wrote: > cmake_minimum_required(VERSION 2.6) Just as a side note: if you need to support cmake 2.6, that's fine. However, if you are starting a new project and do not *need* to limit yourself to cmake 2.6, develop for a cmake version that as

Re: [CMake] Best way to handle application data path for local run vs. installation

2015-12-03 Thread Johannes Zarl-Zierl
> > I.e. it could be replaced with a string of the same length or a > > shorter one, but not a longer one. > > > > CMake works around this by extending the build RPATH artificially with > > ":" at the end I think, patchelf works around this by making the whole > > executable one page bigger if

Re: [CMake] Version compatibility?

2016-04-25 Thread Johannes Zarl-Zierl
Hi Rob, I've stopped working on it when 3.0 came out. Since the whole thing was very much manual work (diff'ing documentation pages and checking whether some change was only better documentation or a real change in cmake), it was too much effort to continue long-term. Johannes On Saturday

Re: [CMake] cmp0065

2016-07-06 Thread Johannes Zarl-Zierl
Hi, On Tuesday 05 July 2016 23:46:16 J Decker wrote: > https://cmake.org/cmake/help/v3.4/policy/CMP0065.html > while I like the idea it suggests, I don't use the flags for -rdynamic so > this is meaningless to me I'm not sure I understood you correctly, but if the policy is meaningless to you,

Re: [CMake] libsndfile in windows

2017-03-21 Thread Johannes Zarl-Zierl
On Dienstag, 21. März 2017 15:24:13 CET you wrote: > > Did you try asking on the libsndfile mailing list? > I did .but there was no response . Ok then. > I had written cmakelists.txt to compile and build . > I was able to successfully built it in linux , but in windows I was not > able to do it

Re: [CMake] libsndfile in windows

2017-03-21 Thread Johannes Zarl-Zierl
Hi, On Dienstag, 21. März 2017 10:57:42 CET aishwarya selvaraj wrote: > I'm very new to all this , So Could anyone please guide me on what to do > next . Did you try asking on the libsndfile mailing list? They are more likely to know about the issue you're dealing with. Try here:

Re: [CMake] Should configuration package files define module package variables?

2017-08-28 Thread Johannes Zarl-Zierl
Hi, On Freitag, 25. August 2017 11:21:50 CEST Robert Dailey wrote: > However, what I'm wondering is even though the import targets should > contain all information about include directories, libraries, etc, > should I still define the typical Foo_INCLUDE_DIRS, Foo_LIBRARIES > variables? This

Re: [CMake] Using find_package() portably?

2017-11-22 Thread Johannes Zarl-Zierl
On Mittwoch, 22. November 2017 11:32:22 CET Carsten Fuchs wrote: > That is, follow-up question: near the "..." above, we have got a target > "libjpeg", but how do I get the variables JPEG_INCLUDES, JPEG_LIBRARIES > etc. that `find_package(JPEG)` normally provides so that the last line > with the

Re: [CMake] Using find_package() portably?

2017-11-29 Thread Johannes Zarl-Zierl
Hello Carsten, On Samstag, 25. November 2017 11:46:44 CET Carsten Fuchs wrote: > Thanks for your reply, but how can I proceed from here? > > In order to be able to write in the parent script something that works > in either case, that is, > > target_link_libraries(main_program ) Well, that's

Re: [CMake] Contribute Find-module to CMake vs Config-file to upstream

2018-05-22 Thread Johannes Zarl-Zierl
Hi Mateusz, On Montag, 21. Mai 2018 19:39:16 CEST Mateusz Loskot wrote: > The FindLZ4 discussion basically ended with suggestion from Brad that, > instead of adding Find-module to CMake, I should approach LZ4 project > and add Config-file to the library itself. > Then I argued taht Config-files

Re: [CMake] Contribute Find-module to CMake vs Config-file to upstream

2018-05-23 Thread Johannes Zarl-Zierl
On Dienstag, 22. Mai 2018 11:13:18 CEST Brad King wrote: > > not be much more work for the maintainer as pkg-config files. > > There is a proposal here: > > https://mwoehlke.github.io/cps/ This looks quite promising! Do you know whether there's a shared interest on the pkg-config and

Re: [CMake] conditions and included subprojects

2018-06-11 Thread Johannes Zarl-Zierl
T_OPTION not being defined at all - like in a standalone build! > > > > > > > > > > > > One way would be to have an additional option or variable > > BUILDING_MAINPROJECT which is set to ON or TRUE in the main project > > and can be checked.

Re: [CMake] Changes to cmake_minimum_required() for 3.12

2018-07-02 Thread Johannes Zarl-Zierl
gt; I've updated the merge request to incorporate this feedback. > > https://gitlab.kitware.com/cmake/cmake/merge_requests/2180 -- Johannes Zarl-Zierl Information management JOHANNES KEPLER UNIVERSITY LINZ Altenberger Straße 69 4040 Linz, Austria P +43 732 2468 3898 johannes.zarl-zi...@j

Re: [CMake] simple find_package example

2018-08-07 Thread Johannes Zarl-Zierl
Am Dienstag, 7. August 2018, 14:48:26 CEST schrieb Randy Heiland: > Hmm, well if that's the case, how does one generate the HelloConfig.cmake > file? The official documentation is here: https://cmake.org/cmake/help/latest/manual/cmake-packages.7.html > Although, for my particular situation, my

Re: [CMake] Querying project dependencies from the UNIX command-line

2018-07-18 Thread Johannes Zarl-Zierl
Hi Ardi, Am Mittwoch, 18. Juli 2018, 11:31:50 CEST schrieb ardi: > For example, I'd like to type "somecommand /path/to/someproject" at > the UNIX command line, and get this output: > [...] > Furthermore, if another command could show optional requisites, it > would be really great:

Re: [CMake] Recommandations for public custom macro/functions installation

2018-04-17 Thread Johannes Zarl-Zierl
Hi David, On Dienstag, 17. April 2018 11:58:12 CEST David Demelier wrote: > I personally do not want to prefix all my options in my project with > the project name prefix, I think that would be a bit ugly, and I do > want this macro to build and install the documentation. Just replying to this

Re: [CMake] Recommandations for public custom macro/functions installation

2018-04-17 Thread Johannes Zarl-Zierl
On Dienstag, 17. April 2018 13:48:39 CEST David Demelier wrote: > On Tue, 2018-04-17 at 12:25 +0200, Johannes Zarl-Zierl wrote: > > Just replying to this topic of your message: you may want to > > reconsider. The > > cmake gui allows you to group options automatically b

Re: [CMake] find_package Config vs Module mode

2018-10-20 Thread Johannes Zarl-Zierl
Hi Joachim, Am Samstag, 20. Oktober 2018, 13:22:04 CEST schrieb Joachim Wuttke: > If Config mode is the newer, preferred way to find a package, I would expect > find_package to first try Config mode, and only fall back to Module mode if > no config scripts can be found. However, according to the