[CMake] Can you add sources to a target library after add_library()?

2010-01-09 Thread Marcel Loose
Hi all, I've been searching the manuals, but couldn't find a way to add sources to a target library *after* the add_library() command, e.g., using set_target_properties()? Is this possible at all? Best regards, Marcel Loose. ___ Powered

Re: [CMake] intercomponent link dependencies?

2010-01-08 Thread Marcel Loose
libraries, then, iff the package was properly built (i.e. with the dependencies linked into the shared libs) you won't need to specify these indirect dependencies. Best regards, Marcel Loose. On Thu, 2010-01-07 at 21:20 +0100, Nico Schlömer wrote: Hi Ryan, thanks very much for your answer

Re: [CMake] Overriding CMAKE_C_FLAGS on a per-directory basis

2010-01-08 Thread Marcel Loose
this helps, Marcel Loose. On Fri, 2010-01-08 at 12:26 +0100, Ingolf Steinbach wrote: Hi, is it possible to override CMAKE_C_FLAGS on a per-directory basis? I have attempted to solve this by setting CMAKE_C_FLAGS to a different value than the default used in the project, but this modification

Re: [CMake] [Q] LINK_INTERFACE_LIBRARIES and the like

2009-12-23 Thread Marcel Loose
On Tue, 2009-12-22 at 16:22 +0100, Michael Wild wrote: On 22. Dec, 2009, at 15:52 , Marcel Loose wrote: Hi all, After reading, re-reading, and re-re-reading the manual, I still don't really get the concept of LINK_INTERFACE_LIBRARIES, IMPORTED_LINK_DEPENDENT_LIBRARIES

Re: [CMake] [Q] LINK_INTERFACE_LIBRARIES and the like

2009-12-23 Thread Marcel Loose
On Wed, 2009-12-23 at 09:59 +0100, Michael Wild wrote: On 23. Dec, 2009, at 9:52 , Marcel Loose wrote: On Tue, 2009-12-22 at 16:22 +0100, Michael Wild wrote: On 22. Dec, 2009, at 15:52 , Marcel Loose wrote: Hi all, After reading, re-reading, and re-re-reading the manual, I still

[CMake] Proposal: extra option PRIVATE for target_link_libraries

2009-12-23 Thread Marcel Loose
of this knowledge is already available in the diverse Modules/Platform macros, so my feeling is that this should be feasible. Best regards, Marcel Loose. ___ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com

Re: [CMake] Proposal: extra option PRIVATE for target_link_libraries

2009-12-23 Thread Marcel Loose
On Wed, 2009-12-23 at 13:09 +0100, Michael Wild wrote: On 23. Dec, 2009, at 12:08 , Marcel Loose wrote: Hi all, I suggested this in the quite long thread third party library dependencies, but it may have been overlooked. Hence, I started a new thread. Upon (re)reading

Re: [CMake] Proposal: extra option PRIVATE for target_link_libraries

2009-12-23 Thread Marcel Loose
On Wed, 2009-12-23 at 14:36 +0100, Alexander Neundorf wrote: On Wednesday 23 December 2009, Marcel Loose wrote: Hi all, I suggested this in the quite long thread third party library dependencies, but it may have been overlooked. Hence, I started a new thread. Upon (re)reading

Re: [CMake] Proposal: extra option PRIVATE for target_link_libraries

2009-12-23 Thread Marcel Loose
On Wed, 2009-12-23 at 14:12 +0100, Michael Wild wrote: On 23. Dec, 2009, at 13:28 , Marcel Loose wrote: On Wed, 2009-12-23 at 13:09 +0100, Michael Wild wrote: On 23. Dec, 2009, at 12:08 , Marcel Loose wrote: Hi all, I suggested this in the quite long thread third party library

Re: [CMake] Proposal: extra option PRIVATE for target_link_libraries

2009-12-23 Thread Marcel Loose
On Wed, 2009-12-23 at 15:06 +0100, Alexander Neundorf wrote: On Wednesday 23 December 2009, Marcel Loose wrote: ... Seems I must unconciously have felt that LINK_INTERFACE_LIBRARIES had something to do with the problem of overlinking I'm trying to solve right now. Funny, this morning I

[CMake] [Q] LINK_INTERFACE_LIBRARIES and the like

2009-12-22 Thread Marcel Loose
Hi all, After reading, re-reading, and re-re-reading the manual, I still don't really get the concept of LINK_INTERFACE_LIBRARIES, IMPORTED_LINK_DEPENDENT_LIBRARIES, and IMPORTED_LINK_INTERFACE_LIBRARIES. Is this mostly Windows-specific, or does it also apply for Linux? Best regards, Marcel

[CMake] Tiny FindJNI patch to set JNI_FOUND

2009-12-21 Thread Marcel Loose
Hi all, Here's a tiny patch for FindJNI, which also sets JNI_FOUND, as dictated by the CMake Find macros standard. Best regards, Marcel Loose. Index: FindJNI.cmake === RCS file: /cvsroot/CMake/CMake/Modules/FindJNI.cmake,v

Re: [CMake] Multiple calls to find_package(Boost) with different components

2009-12-21 Thread Marcel Loose
of a command-line person, so I have no experience with groups in the cmake-gui. Best regards, Marcel Loose. On Mon, 2009-12-21 at 10:37 +0100, Adolfo Rodríguez Tsouroukdissian wrote: Hi all, I have a use case where find_package(Boost COMPONENTS xxx) is called more than once, and each time

Re: [CMake] third party library dependencies

2009-12-21 Thread Marcel Loose
On Fri, 2009-12-18 at 08:54 -0800, Jed Brown wrote: On Fri, 18 Dec 2009 10:19:05 +0100, Marcel Loose lo...@astron.nl wrote: Hi Roman, Not in a portable way. I'm not too familiar with Windows, but on Linux you can do this when libA is a shared library that has its dependency on libB

Re: [CMake] third party library dependencies

2009-12-21 Thread Marcel Loose
On Mon, 2009-12-21 at 13:32 +0100, Michael Wild wrote: On 21. Dec, 2009, at 12:17 , Marcel Loose wrote: On Fri, 2009-12-18 at 08:54 -0800, Jed Brown wrote: On Fri, 18 Dec 2009 10:19:05 +0100, Marcel Loose lo...@astron.nl wrote: Hi Roman, Not in a portable way. I'm not too familiar

Re: [CMake] third party library dependencies

2009-12-21 Thread Marcel Loose
On Mon, 2009-12-21 at 14:43 +0100, Michael Wild wrote: On 21. Dec, 2009, at 14:16 , Marcel Loose wrote: On Mon, 2009-12-21 at 13:32 +0100, Michael Wild wrote: On 21. Dec, 2009, at 12:17 , Marcel Loose wrote: On Fri, 2009-12-18 at 08:54 -0800, Jed Brown wrote: On Fri, 18 Dec 2009 10

Re: [CMake] third party library dependencies

2009-12-18 Thread Marcel Loose
for this and let that macro set the variable A_LIBRARIES to contain both libA and libB. You can then use: find_package(A) target_link_libraries(${A_LIBRARIES}) Hope this helps, Marcel Loose. On Thu, 2009-12-17 at 12:18 -0500, Roman Shtylman wrote: Is there an easy way to setup link

Re: [CMake] third party library dependencies

2009-12-18 Thread Marcel Loose
/libboost_date_time-mt.so;/usr/lib64/libboost_regex-mt.so -- Configuring done -- Generating done So, in my case boost_regex is nicely added to boost_date_time. Best regards, Marcel Loose. On Fri, 2009-12-18 at 10:48 +0100, Adolfo Rodríguez Tsouroukdissian wrote: On Fri, Dec 18, 2009 at 10:19 AM

Re: [CMake] Acces macro/functions to subfolders

2009-12-17 Thread Marcel Loose
is that, for functions, ARGV and ARGN and ARGVn (n=1..) are real variables that have local scope. Best regards, Marcel Loose. ___ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep

Re: [CMake] How can I add gprof profiler to my CMakeLists.txt?

2009-12-15 Thread Marcel Loose
and linking. The command add_definitions() will only add this option during compilation. You should also add `-pg' to CMAKE_EXE_LINKER_FLAGS or to CMAKE_EXE_LINKER_FLAGS_[CMAKE_BUILD_TYPE], where CMAKE_BUILD_TYPE could be, e.g., `DEBUG'. HTH, Marcel Loose

Re: [CMake] Building tests only for make test

2009-12-15 Thread Marcel Loose
Hi Stefan, You found a typo. I'll fix that right away. Thanks. I've never tried to use the 'check' target with ctest, so I'm not sure whether it should work or not. Maybe someone else can comment on this. Best regards, Marcel Loose. On Mon, 2009-12-14 at 12:49 +0100, Dr. Stefan Sablatnög wrote

Re: [CMake] cmake -E create_symlink for Windows

2009-12-14 Thread Marcel Loose
stuff, it would fail in a noticeable way (the build would fail). If you call it from execute_process, you should be checking the return value as well. -Bill Just out of curiosity: how does Cygwin handle this whole symbolic link business? Marcel Loose

Re: [CMake] cmake -E create_symlink for Windows

2009-12-14 Thread Marcel Loose
On Mon, 2009-12-14 at 08:23 -0500, Bill Lorensen wrote: http://en.wikipedia.org/wiki/Symbolic_link#Cygwin_symbolic_links OK, that puts us back at square one. Why is it that CMake cannot use Windows shortcuts as an alternative to Unix symbolic links, whereas Cygwin can? Best regards, Marcel

Re: [CMake] cmake -E create_symlink for Windows

2009-12-13 Thread Marcel Loose
), because long before then, I, as a developer of the build environment, decided to use the presumed cross-platform command create_symlink, only to find out much later that it doesn't work on Windows. Best regards, Marcel Loose. ___ Powered

[CMake] cmake -E create_symlink for Windows

2009-12-11 Thread Marcel Loose
, Marcel Loose. ___ 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

Re: [CMake] cmake -E create_symlink for Windows

2009-12-11 Thread Marcel Loose
On Fri, 2009-12-11 at 14:51 +0100, Michael Wild wrote: On 11. Dec, 2009, at 14:27 , Marcel Loose wrote: Hi all, I was browsing the CMake sources for a problem I was facing with the creation of symlinks (on Unix that is) and I noticed that the SystemTools::CreateSymlink function

Re: [CMake] Building tests only for make test

2009-12-11 Thread Marcel Loose
Hi Stefan, I once dug into this issue, because I wanted to (more or less) emulate the GNU Autotools 'make check' feature. Have a look at http://www.cmake.org/Wiki/CMakeEmulateMakeCheck and see if that answers you question. Best regards, Marcel Loose. On Fri, 2009-12-11 at 15:53 +0100, Dr

[CMake] get_target_property CONFIG_LOCATION for custom target?

2009-12-09 Thread Marcel Loose
Hi all, I was trying to see whether I could retrieve the target location of a custom target using the CONFIG_LOCATION property of the given target, but to no avail. Is it possible to do this? Best regards, Marcel Loose. ___ Powered

Re: [CMake] get_target_property CONFIG_LOCATION for custom target?

2009-12-09 Thread Marcel Loose
Hi all, Found it in the manual, but not under get_target_property(). It's not possible. Sorry for the noise. Best regards, Marcel Loose. On Wed, 2009-12-09 at 15:09 +0100, Marcel Loose wrote: Hi all, I was trying to see whether I could retrieve the target location of a custom target using

[CMake] Is it safe to add properties to custom target?

2009-12-09 Thread Marcel Loose
Hi all, In fact the subject title says it all. Is it safe to do, for example: add_custom_target(myTarget) set_target_properties(myTarget PROPERTIES LOCATION ${CMAKE_CURRENT_BINARY_DIR}) It seems to work fine, but I'm not sure this is the right way to do it. Best regards, Marcel Loose

Re: [CMake] 32 bits compilation on x64 platform - how to find system libraries

2009-12-07 Thread Marcel Loose
a toolchain file. The only thing you have to do is instruct gcc/g++ to generate 32-bit objects/binaries, using the -m32 option, and tell CMake to look in lib instead of lib64 by setting the aforementioned property. Hope this helps. Best regards, Marcel Loose. On Mon, 2009-12-07 at 10:09 +0100

Re: [CMake] 32 bits compilation on x64 platform - how to find system libraries

2009-12-07 Thread Marcel Loose
On Mon, 2009-12-07 at 13:19 +0100, Mathieu Malaterre wrote: On Mon, Dec 7, 2009 at 11:43 AM, Marcel Loose lo...@astron.nl wrote: Hi Olivier, I think you need to set the global property FIND_LIBRARY_USE_LIB64_PATHS to OFF. BTW, I disagree with Mathieu that building 32-bit libraries

[CMake] FindHDF5 bug: HDF5_FOUND is not set

2009-12-07 Thread Marcel Loose
Hi all, I noticed that FindHDF5.cmake does not set HDF5_FOUND, although it says in the documentation of the file that it does. This is both with CMake 2.8 and with the CVS HEAD. Should I open an issue for this in the bug tracker, or is this bug too trivial for that. Best regards, Marcel Loose

[CMake] [Fwd: FindHDF5 bug: HDF5_FOUND is not set]

2009-12-07 Thread Marcel Loose
Hi all, Sorry for the noise. Must be the Monday morning blues. HDF5_FOUND is of course set by FPHSA. Don't know exactly what's going wrong in my script, but it certainly has nothing to do with FindHDF5.cmake. Best regards, Marcel Loose. ---BeginMessage--- Hi all, I noticed that FindHDF5

Re: [CMake] 32 bits compilation on x64 platform - how to find system libraries

2009-12-07 Thread Marcel Loose
On Mon, 2009-12-07 at 14:18 +0100, Olivier Pierard wrote: Marcel Loose wrote: On Mon, 2009-12-07 at 13:19 +0100, Mathieu Malaterre wrote: On Mon, Dec 7, 2009 at 11:43 AM, Marcel Loose lo...@astron.nl wrote: Hi Olivier, I think you need to set the global property

Re: [CMake] Conditional subdirectory build

2009-11-30 Thread Marcel Loose
Hi David, Why not use OPTION(...) for this, or if you really want to the equivalent: set(MYVAR ON CACHE BOOL My variable). Don't use FORCE, or you will overwrite any changes the user made. Best regards, Marcel Loose. On Sun, 2009-11-29 at 10:12 -0500, David Cole wrote: if(BUILD_PARAVIEW_PLUGIN

Re: [CMake] enable_language( ... OPTIONAL) causes error on second cmake run

2009-11-27 Thread Marcel Loose
AND CMAKE_Fortran_COMPILER MATCHES ^ $) set(CMAKE_Fortran_COMPILER CMAKE_Fortran_COMPILER-NOTFOUND) endif(DEFINED CMAKE_Fortran_COMPILER AND CMAKE_Fortran_COMPILER MATCHES ^$) I'll add this work-around to the notes for issue #9220. Best regards, Marcel Loose. On Thu, 2009-11-26 at 16:12 +0100, Marcel Loose wrote: Hi

Re: [CMake] enable_language( ... OPTIONAL) causes error or second cmake run

2009-11-27 Thread Marcel Loose
CMAKE_Fortran_COMPILER AND CMAKE_Fortran_COMPILER MATCHES ^ $) set(CMAKE_Fortran_COMPILER CMAKE_Fortran_COMPILER-NOTFOUND) endif(DEFINED CMAKE_Fortran_COMPILER AND CMAKE_Fortran_COMPILER MATCHES ^$) It seems to work OK, at least for me. Best regards, Marcel Loose. On Thu, 2009-11-26 at 12:01 -0800, Alan

Re: [CMake] enable_language( ... OPTIONAL) causes error or second cmake run

2009-11-26 Thread Marcel Loose
'enable_language(Fortran OPTIONAL)' and let CMake search for the Fortran compiler. Since there's no Fortran compiler installed, CMake will not find it. So far, so good. But, when I run CMake a second time, I get the error I reported. What's your thought on this? Best regards, Marcel Loose. On Wed

Re: [CMake] enable_language( ... OPTIONAL) causes error or second cmake run

2009-11-25 Thread Marcel Loose
${CMAKE_Fortran_COMPILER} the problem is solved. Or so it seems. Right, or wrong? Best regards, Marcel Loose. On Tue, 2009-11-24 at 19:48 +0100, Alexander Neundorf wrote: On Tuesday 24 November 2009, Marcel Loose wrote: Hi all, I've been experimenting a bit with enable_language() and stumbled upon

Re: [CMake] enable_language( ... OPTIONAL) causes error or second cmake run

2009-11-25 Thread Marcel Loose
Done, see Note 0018597 Best regards, Marcel Loose. On Wed, 2009-11-25 at 19:16 +0100, Alexander Neundorf wrote: On Wednesday 25 November 2009, Marcel Loose wrote: Hi Alex, Maybe I'm overlooking all kinds of side effects, but the problem is in line 6 of CMakeFortranInformation.cmake

[CMake] enable_language( ... OPTIONAL) causes error or second cmake run

2009-11-24 Thread Marcel Loose
) -- Configuring incomplete, errors occurred! Best regards, Marcel Loose. ___ 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

Re: [CMake] Double Substitution in IF Statement

2009-11-19 Thread Marcel Loose
Hi Aaron, If I run your script (using CMake 2.6.2) I get -- CONTAINS_LIB = TRUE as output. Isn't that what you expected? If not, then I'm missing the point of your macro LIST_CONTAINS. What version of CMake are you using? Best regards, Marcel Loose. On Wed, 2009-11-18 at 09:54 -0800

Re: [CMake] How to get ADD_DEFINITIONS variable?

2009-11-17 Thread Marcel Loose
dependent, as each add_subdirectory() creates a new scope. Hope this helps, Marcel Loose. On Tue, 2009-11-17 at 10:40 +0100, Sören Freudiger wrote: Hi @all In our project we are several times adding preprocessor defines via ADD_DEFINITIONS. Now I need to get these defines to add them

[CMake] Shouldn't FindHDF5 also set HDF5_INCLUDE_DIRS?

2009-11-13 Thread Marcel Loose
Hi all, According to the guidelines in the Modules/readme.txt file, each FindXXX.cmake file should define a non-cached XXX_INCLUDE_DIRS variable. I noticed that FindHDF5.cmake doesn't. Maybe this can be fixed before CMake 2.8.0? Best regards, Marcel Loose

Re: [CMake] ARGVn madness?!

2009-11-13 Thread Marcel Loose
Hi Brad, Michael, Your explanation makes sense. I hadn't run into this problem before, and assumed I could safely access ARGVn, whether or not n = ARGC. Turns out I was just lucky. I'll use ARGN instead. Thanks, Marcel Loose. On Fri, 2009-11-13 at 07:52 -0500, Brad King wrote: Michael Wild

Re: [CMake] Modification of a variable in a CMakeLists called with add_subdirectory

2009-11-09 Thread Marcel Loose
Hi Oliver, Use the option PARENT_SCOPE when setting the variable. HTH, Marcel Loose. On Mon, 2009-11-09 at 11:11 +0100, Olivier Pierard wrote: Hi, I'm facing another rather simple problem. I try to modify a variable defined in the main CMakeLists.txt within another one called

[CMake] CMake Error: RPATH_CHANGE

2009-11-09 Thread Marcel Loose
(CMAKE_INSTALL_DO_STRIP) Both cmake 2.6.4 and 2.8.0-rc5 show this behaviour, which looks like a bug to me. Best regards, Marcel Loose. ___ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Re: [CMake] string(RANDOM) bug?

2009-11-06 Thread Marcel Loose
Hi David, I submitted a bug report: http://www.cmake.org/Bug/view.php?id=9851 Best regards, Marcel Loose. On Thu, 2009-11-05 at 11:14 -0500, David Cole wrote: The problem is that srand is called *each* time that STRING(RANDOM is invoked... And it is based on the current time stamp

Re: [CMake] infinite loop when trying to change the compiler in CMakeLists.txt

2009-11-05 Thread Marcel Loose
on the name of the build directory. Hope this helps, Marcel Loose. On Thu, 2009-11-05 at 11:36 -0700, Will Dicharry wrote: I think the best way to do that is with an initial cache via the -C flag to cmake. Then you can set the initial CMAKE_LANG_COMPILER option in a CMake file and start with that file

Re: [CMake] [CTest] Access test data from c++ code

2009-11-04 Thread Marcel Loose
Hi Thomas, It depends. I would prefer to keep a clean source tree and put any generated file in the build tree. That way you could (in principle) run cmake from a read-only source tree. But it's not wrong the way you do it. Regards, Marcel Loose. On Tue, 2009-11-03 at 17:38 +0100, Thomas wrote

[CMake] Is it safe to use add_definitions() before the first project() command?

2009-11-04 Thread Marcel Loose
Hi all, Well the title says it all. Is it safe to use add_definitions() before the first project() command, or am I entering the realm of undefined behaviour then? Best regards, Marcel Loose. ___ Powered by www.kitware.com Visit other Kitware open

[CMake] Are variable names guaranteed to be case-sensitive?

2009-11-04 Thread Marcel Loose
Hi all, Title says it all (again). I noticed, simply by trying out, that on Linux variable names are case sensitive. I.e. 'foo' and 'FOO' are two different variables. Is it safe to assume that this is, and will always be, the case on any platform? Best regards, Marcel Loose

[CMake] Building statically linked executables

2009-11-04 Thread Marcel Loose
linking and find_library(), which can be found at http://www.mail-archive.com/cmake@cmake.org/msg21106.html Best regards, Marcel Loose. ___ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource

Re: [CMake] FindBoost: FIND_PACKAGE ( Boost COMPONENTS filesystem )

2009-11-04 Thread Marcel Loose
system) endif() # Assume wave depends on system for Boost 1.36 if(${_boost_maj}.${_boost_min} VERSION_GREATER 1.36) list(APPEND Boost_wave_DEPENDENCIES system) endif() Does that make any sense? Best regards, Marcel Loose. On Wed, 2009-11-04 at 11:14 -0500, Philip Lowman wrote: Mathieu, It's

Re: [CMake] Regular Expression weirdness (2.6 2.8RC3)

2009-10-28 Thread Marcel Loose
*not* be any of the characters 'c', 'o', 'n', 'f', 'i', or 'g'; finally the name should end in '.h'. So, HDR1 does not contain cspacedef.h because the last character before the '.h' is an 'f', which is one of the forbidden characters in the glob expression. HTH, Marcel Loose. On Tue, 2009-10-27 at 23:55

Re: [CMake] Depending on all and custom targets

2009-10-09 Thread Marcel Loose
add_custom_target(complete DEPENDS extras) you're telling CMake that target 'complete' depends on the _file_ 'extras'. The correct way to do this is to use add_dependencies: add_custom_target(complete) add_dependencies(complete extras) HTH, Marcel Loose. On Fri, 2009-10-09 at 12:47 +0200, jens persson wrote

[CMake] Extra blank lines with SEND_ERROR and FATAL_ERROR ?!

2009-10-05 Thread Marcel Loose
CMake Error at CMakeLists.txt:5 (message): Line one Line two Line three -- Configuring incomplete, errors occurred! As can be seen, SEND_ERROR and FATAL_ERROR add extra blank lines. Best regards, Marcel Loose. ___ Powered by www.kitware.com

Re: [CMake] Trouble with parallel builds for targets created by add_executable, target_link_libraries, and add_library

2009-09-30 Thread Marcel Loose
MAKEFLAGS=-j4 $ make all make install Best regards, Marcel Loose. ___ 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

Re: [CMake] How to not evaluate variable names ?

2009-09-30 Thread Marcel Loose
about: file(WRITE /tmp/dummy.xml args=\\${serverConfigChanged}\\n) That works for me. You must escape the double quotes () and the dollar sign ($). Best regards, Marcel Loose. ___ Powered by www.kitware.com Visit other Kitware open-source projects

Re: [CMake] Trouble with parallel builds for targets c reated by add_executable, target_link_libraries , and add_library

2009-09-30 Thread Marcel Loose
On Wednesday 30 September 2009 21:16:10 Alexander Neundorf wrote: On Wednesday 30 September 2009, Marcel Loose wrote: On Tue, 2009-09-29 at 19:46 -0400, Bill Hoffman wrote: Alan W. Irwin wrote: On 2009-09-29 16:36-0400 Bill Hoffman wrote: make -j N is only supported with the all

Re: [CMake] INTERNAL vs. STATIC cache variables

2009-09-28 Thread Marcel Loose
On Fri, 2009-09-25 at 21:12 +0200, Alexander Neundorf wrote: On Friday 25 September 2009, Marcel Loose wrote: Hi all, Is there a difference in precedence between INTERNAL and STATIC cache variables? For example, what happens if I (accidentally) define an INTERNAL cache variable

[CMake] INTERNAL vs. STATIC cache variables

2009-09-25 Thread Marcel Loose
of undefined behavior? Best regards, Marcel Loose. ___ 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

[CMake] What changes to the cache file, if any, will trigger a rerun of CMake?

2009-09-23 Thread Marcel Loose
was wondering whether it is possible to force a re-run of CMake when one or more OPTION variables are changed in the cache *during* a CMake run. Best regards, Marcel Loose. ___ Powered by www.kitware.com Visit other Kitware open-source projects at http

Re: [CMake] What changes to the cache file, if any , will trigger a rerun of CMake?

2009-09-23 Thread Marcel Loose
On Wednesday 23 September 2009 17:45:39 Tyler Roscoe wrote: On Wed, Sep 23, 2009 at 03:02:31PM +0200, Marcel Loose wrote: What changes to the cache file (CMakeCache.txt) will trigger a rerun of CMake. AFAIK changes to CMAKE_LANG_COMPILER will do this, but are there other situations? Don't

Re: [CMake] Updated FindThreads.cmake in tracker

2009-09-22 Thread Marcel Loose
On Mon, 2009-09-21 at 23:25 -0400, Philip Lowman wrote: On Mon, Sep 21, 2009 at 6:07 AM, Marcel Loose lo...@astron.nl wrote: On Sun, 2009-09-20 at 19:32 -0400, Philip Lowman wrote: On Sun, Sep 20, 2009 at 3:02 PM, Hendrik Sattler I'm hesitant

Re: [CMake] Updated FindThreads.cmake in tracker

2009-09-21 Thread Marcel Loose
. Marcel Loose ___ 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

Re: [CMake] add_subdirectory and build directory

2009-09-15 Thread Marcel Loose
. Regards, Marcel Loose. On Mon, 2009-09-14 at 16:28 +0200, Pierre-Julien Villoud wrote: Sorry I did not reply to you... I actually use the target_link_libraries and the add_dependencies which is useless if using the target_link_libraries (I think ?) So I really wonder why my objects

Re: [CMake] add_subdirectory and build directory

2009-09-15 Thread Marcel Loose
HelloMath and libMaths, the latter due to the link dependency. The library libmMaths is not up-to-date as you suggest; it hasn't been built yet! * Finally, in directory Math, you're building libMaths again, but now it's up-to-date, so nothing needs to be done. Best regards, Marcel Loose. On Tue

[CMake] Difficult 'make install' problem

2009-09-14 Thread Marcel Loose
/subsys_1, the result would be the same as if I had subsequently typed 'make install' in the directories part_1/part_1a, part_1/part_1b, part_1/part_1c, and part_2/part_2a. Does anyone know how I could achieve this in CMake? Best regards, Marcel Loose

[CMake] Make project name a target

2009-09-11 Thread Marcel Loose
in a macro is not a solution, because AFAIK CMake *must* see a 'project' command in the top-level CMakeLists.txt file; a 'myproject' macro, wrapping the 'project' command, will not do. Any comments? Best regards, Marcel Loose. ___ Powered by www.kitware.com

Re: [CMake] Make project name a target

2009-09-11 Thread Marcel Loose
into problems. Is there a nifty trick to wrap the 'project' command? I never succeeded in doing that. Best regards, Marcel Loose. On Fri, 2009-09-11 at 07:09 -0400, David Cole wrote: When you say make the project name a target what do you mean by that? (1) internally create a CMake target

Re: [CMake] add_subdirectory and build directory

2009-09-11 Thread Marcel Loose
to judge what, if anything, is going wrong. Best regards, Marcel Loose. On Fri, 2009-09-11 at 15:12 +0200, Pierre-Julien Villoud wrote: Hi everyone, After unsuccessfully looking for an answer on Google, I contact you. I have a question regarding the use of add_subdirectory. When

Re: [CMake] add_subdirectory and build directory

2009-09-11 Thread Marcel Loose
A. Anyway, you may want to post your CMakeLists.txt files, so that people can spot what you might be doing wrong. At the moment, I can only make some wild guesses. Best regards, Marcel Loose. On Fri, 2009-09-11 at 17:34 +0200, Pierre-Julien Villoud wrote: Hi and thanks for your answer... Here

Re: [CMake] Make project name a target

2009-09-11 Thread Marcel Loose
below. Look at the line printing PROJECT_NAME. But you'll notice a significant difference in output anyway. Best regards, Marcel Loose. CMakeLists.txt with direct call of project() command: $ pwd /home/loose/work/cmake/build $ cat ../proj

Re: [CMake] FindPythonLibs should set PYTHON_INCLUDE_DIR instead of PYTHON_INCLUDE_PATH

2009-09-09 Thread Marcel Loose
On Mon, 2009-09-07 at 22:01 +0200, Alexander Neundorf wrote: On Monday 07 September 2009, Marcel Loose wrote: Hi all, In fact the subject line says it all. To be compliant with the naming conventions proposed in the Modules/readme.txt file, FindPythonLibs should set PYTHON_INCLUDE_DIR

Re: [CMake] FindPythonLibs should set PYTHON_INCLUDE_DIR instead of PYTHON_INCLUDE_PATH

2009-09-09 Thread Marcel Loose
On Wed, 2009-09-09 at 09:26 +0200, Marcel Loose wrote: On Mon, 2009-09-07 at 22:01 +0200, Alexander Neundorf wrote: On Monday 07 September 2009, Marcel Loose wrote: Hi all, In fact the subject line says it all. To be compliant with the naming conventions proposed in the Modules

Re: [CMake] Let CMake convert CMAKE_MODULE_PATH to absolute path

2009-09-07 Thread Marcel Loose
On Fri, 2009-09-04 at 21:48 +0200, Alexander Neundorf wrote: On Tuesday 25 August 2009, Marcel Loose wrote: Hi all, I've been bitten by this more than once. When specifying a module path on the command line, you must not forget to make this an absolute path, otherwise calling a macro

Re: [CMake] FindThreads: the odd one out?

2009-09-07 Thread Marcel Loose
On Fri, 2009-09-04 at 21:55 +0200, Alexander Neundorf wrote: On Sunday 30 August 2009, Philip Lowman wrote: On Fri, Aug 28, 2009 at 4:29 AM, Marcel Loose lo...@astron.nl wrote: Hi all, Up till now I've been using the not officially supported and released FindPthreads.cmake macro

[CMake] FindPythonLibs should set PYTHON_INCLUDE_DIR instead of PYTHON_INCLUDE_PATH

2009-09-07 Thread Marcel Loose
for PYTHON_INCLUDE_DIR. Best regards, Marcel Loose. ___ 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

[CMake] Howto byte-compile python files during install

2009-09-03 Thread Marcel Loose
Hi all, What is the best way to make sure that Python files are byte-compiled at install time? I couldn't find a pre- or post-install hook in the install() command. Best regards, Marcel Loose. ___ Powered by www.kitware.com Visit other Kitware open

Re: [CMake] Fwd: generating CTest tests

2009-08-31 Thread Marcel Loose
Hi John, How do you get these CPU times printed. I've never seen these before. Or is that a Windows thingy, that doesn't work on Linux? Best regards, Marcel Loose. On Fri, 2009-08-28 at 14:14 -0400, John Drescher wrote: 1Performing Post-Build Event... 1Start processing tests 1Test project X

[CMake] FindThreads: the odd one out?

2009-08-28 Thread Marcel Loose
by CMake itself to preset compiler and linker flags, and that these were not to be used outside. Could someone shed a light on this? Best regards, Marcel Loose. ___ Powered by www.kitware.com Visit other Kitware open-source projects at http

Re: [CMake] How to build 2 targets from the same source, differing in -D_SWITCHES_ only

2009-08-27 Thread Marcel Loose
Hi Eike, I think the only safe and reliable way to do this is create several build directories, e.g. build/type_1 and build/type_2. When running cmake in build/type_1, you should add -D_TYPE1_ to the preprocessor flags; same for build/type_2. Best regards, Marcel Loose. On Thu, 2009-08-27 at 12

[CMake] Let CMake convert CMAKE_MODULE_PATH to absolute path

2009-08-25 Thread Marcel Loose
module path to an absolute path, before putting it in the cache? Best regards, Marcel Loose. ___ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic

Re: [CMake] add_custom_command using CMAKE_CXX_FLAGS

2009-08-25 Thread Marcel Loose
the enable_language(foo) command. Hope this helps. Best regards, Marcel Loose. On Mon, 2009-08-24 at 13:38 -0400, John Smith wrote: On Aug 24, 2009, at 12:48 PM, Tyler Roscoe wrote: On Sun, Aug 23, 2009 at 09:03:22PM -0400, John Smith wrote: I am using the following test case in an attempt

Re: [CMake] Possible to clean files of one target library only?

2009-08-20 Thread Marcel Loose
-projects. Best regards, Marcel Loose. ___ 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

Re: [CMake] Tests without CTest (was Re: Custom target bug...)

2009-08-20 Thread Marcel Loose
should work for that as well. Cheers, Tim Hi Tim, Did you read this http://www.cmake.org/Wiki/CMakeEmulateMakeCheck Wiki page and this http://www.mail-archive.com/cmake@cmake.org/msg19936.html thread on the mailing list? Best regards, Marcel Loose

Re: [CMake] CMake Digest, Vol 64, Issue 50

2009-08-20 Thread Marcel Loose
Hi Steve, Unless you're using make's -j option, there should not be any concurrency issues. Check the command line and your MAKEFLAGS variable. Best regards, Marcel Loose. On Wed, 2009-08-19 at 17:31 -0700, Steve Mathers wrote: Hi Michael. that option is what I am already doing, which is why

[CMake] CMake Python support

2009-08-19 Thread Marcel Loose
with the Python sources. If Python were a fully supported programming language, then you could write the CMakeLists.txt files more or less the same way as for other languages (e.g., like Java). It's just a thought, and maybe I'm overlooking all kinds of potential pitfalls. Best regards, Marcel Loose

Re: [CMake] CMake Python support

2009-08-19 Thread Marcel Loose
reply. Best regards, Marcel Loose. On Wed, 2009-08-19 at 10:02 +0200, Hendrik Sattler wrote: Zitat von Marcel Loose lo...@astron.nl: Would it be worthwhile to add Python as a valid language to the project() method? Or is it better to use the currently available FindPython-like scripts. My

Re: [CMake] CMake Python support

2009-08-19 Thread Marcel Loose
Hi Philip, I guess Python 2.x will be around for some time, before Python 3 really becomes mainstream. So I think it should be possible to select a 2.x version, even if 3.x is available. Best regards, Marcel Loose. On Wed, 2009-08-19 at 08:34 -0400, Philip Lowman wrote: Speaking

[CMake] Useful feature: join_arguments() ?

2009-08-14 Thread Marcel Loose
have brewn their join_arguments() macro (or whatever they called it) in the past, and so did I. But it feels like such a fundamental operation that I think it deserves to be a built-in command. Best regards, Marcel Loose. ___ Powered by www.kitware.com

Re: [CMake] How to pass -D options when compiling assembly files using gcc?

2009-08-10 Thread Marcel Loose
On Fri, 2009-07-24 at 22:16 +0200, Alexander Neundorf wrote: On Monday 13 July 2009, Michael Wild wrote: On 13. Jul, 2009, at 10:28, Eric Noulard wrote: 2009/7/12 Marcel Loose lo...@astron.nl: Hi Eric, Thanks, I'll try that tomorrow. Another option that occurred to me today

[CMake] How to catch CMake Error get_directory_property

2009-08-10 Thread Marcel Loose
like get_directory_property() to return FALSE or NOTFOUND when it cannot find the requested directory, so that I can take appropriate action myself. Is that somehow possible? Best regards, Marcel Loose. ___ Powered by www.kitware.com Visit other Kitware

Re: [CMake] Globbing expression

2009-07-14 Thread Marcel Loose
that's not yet built. Just use target_link_libraries() judiciously. Best regards, Marcel Loose. On Mon, 2009-07-13 at 14:08 +0200, Arnaud Devalkeneer wrote: Thanks a lot Marcel. Another should be : - make a second GLOB expression gathering all libraries you do not need - make a LIST

[CMake] CMAKE_FIND_ROOT_PATH and cross-compilation

2009-07-14 Thread Marcel Loose
more info on that. Is this the variable I'm looking for? And if so, is it a boolean? Best regards, Marcel Loose. ___ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep

[CMake] Querying global property in FindXXX.cmake: good or bad?

2009-07-14 Thread Marcel Loose
FindXXX macro only check for all indirect dependencies when that property is FALSE. Good idea or bad idea? Best regards, Marcel Loose. ___ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource

Re: [CMake] Globbing expression

2009-07-13 Thread Marcel Loose
Hi Arnaud, Your mixing globbing with regular expressions. AFAIK it is not possible to do this with one statement. I would just glob for all *.so files and then use string(REGEX REPLACE ...) to replace occurrences of '^libA.* \.so' with an empty string. Best regards, Marcel Loose. On Mon, 2009

Re: [CMake] How to pass -D options when compiling assembly files using gcc?

2009-07-12 Thread Marcel Loose
On Sun, 2009-07-12 at 00:09 +0200, Eric Noulard wrote: 2009/7/11 Marcel Loose lo...@astron.nl: Hi Bill, The problem is not in the invocation of gcc. That works fine. The problem is that I lose the preprocessor definitions that were added with add_definitions() when compiling assembly

<    1   2   3   4   5   >