[CMake] Different CMAKE_CXX_FLAGS for different executables

2011-03-24 Thread David Doria
Is there a way to explicitly set the CMAKE_CXX_FLAGS for a particular executable? That is, if I set CMAKE_CXX_FLAGS and then have a add_executable line, then change CMAKE_CXX_FLAGS and then have another add_executable, will the first set of CMAKE_CXX_FLAGS be applied to the first executable and

Re: [CMake] Different CMAKE_CXX_FLAGS for different executables

2011-03-24 Thread David Doria
On Thu, Mar 24, 2011 at 10:44 AM, David Doria daviddo...@gmail.com wrote: Is there a way to explicitly set the CMAKE_CXX_FLAGS for a particular executable? That is, if I set CMAKE_CXX_FLAGS and then have a add_executable line, then change CMAKE_CXX_FLAGS and then have another add_executable

Re: [CMake] Different CMAKE_CXX_FLAGS for different executables

2011-03-24 Thread David Doria
On Thu, Mar 24, 2011 at 11:31 AM, Yuri Timenkov y...@timenkov.ru wrote: Use COMPILE_FLAGS target property. Like this: set_target_properties(Exec2 PROPERTIES COMPILE_FLAGS /flag1 /flag2) You can see full list of properties in CMake documentation. Note that compiler flags may be also set for

Re: [CMake] Different CMAKE_CXX_FLAGS for different executables

2011-03-25 Thread David Doria
Could you post the output of make VERBOSE=1? On *nix, the following CMakeLists.txt works as expected: The output of make VERBOSE=1 contains: .../c++ -DUNIX -o .../SetTargetProperties.cxx.o -c .../SetTargetProperties.cxx It is working properly now. I must not have done a 'make clean'.

[CMake] set_target_properties not setting COMPILE_DEFINITIONS?

2011-03-28 Thread David Doria
I have setup a list of definitions: SET(MAIN_BUILD_DEFINITIONS ${MAIN_BUILD_DEFINITIONS} UNIX;) SET(MAIN_BUILD_DEFINITIONS ${MAIN_BUILD_DEFINITIONS} PIXEL_DIMENSION=3;) I display them and apply them to my executable as follows: add_executable(ImageCompleter ${MainSources}) message(Main build

Re: [CMake] set_target_properties not setting COMPILE_DEFINITIONS?

2011-03-28 Thread David Doria
On Mon, Mar 28, 2011 at 2:28 PM, Yuri Timenkov y...@timenkov.ru wrote: Try prefixing definitions with -D I changed to: SET(MAIN_BUILD_DEFINITIONS ${MAIN_BUILD_DEFINITIONS} -DUNIX;) SET(MAIN_BUILD_DEFINITIONS ${MAIN_BUILD_DEFINITIONS} -DPIXEL_DIMENSION=3;) and I get: command-line: error: macro

Re: [CMake] set_target_properties not setting COMPILE_DEFINITIONS?

2011-03-28 Thread David Doria
On Mon, Mar 28, 2011 at 2:31 PM, David Doria daviddo...@gmail.com wrote: On Mon, Mar 28, 2011 at 2:28 PM, Yuri Timenkov y...@timenkov.ru wrote: Try prefixing definitions with -D I changed to: SET(MAIN_BUILD_DEFINITIONS ${MAIN_BUILD_DEFINITIONS} -DUNIX;) SET(MAIN_BUILD_DEFINITIONS

Re: [CMake] set_target_properties not setting COMPILE_DEFINITIONS?

2011-03-28 Thread David Doria
I looked at make VERBOSE=1 as you suggested and the -D's indeed are missing. Again, in my working small demo they show up properly. I guess something else in the CMakeLists.txt must be breaking this functionality? The full file is here: http://pastebin.com/SWZgmJ33 but none of the definitions set

Re: [CMake] set_target_properties not setting COMPILE_DEFINITIONS?

2011-03-28 Thread David Doria
No, the semicolons are removed by message() itself, you'll still see them if you enclose the ${} inside the quotes: message( DEFS: ${MAIN_BUILD_DEFINITIONS} ) You're right - the output now contains the semicolons. I tried enclosing the variable in quotes in the set_target_properties line as

Re: [CMake] set_target_properties not setting COMPILE_DEFINITIONS?

2011-03-29 Thread David Doria
On Tue, Mar 29, 2011 at 1:58 AM, Michael Hertling mhertl...@online.dewrote: On 03/29/2011 07:47 AM, Michael Hertling wrote: On 03/28/2011 08:23 PM, David Doria wrote: I have setup a list of definitions: SET(MAIN_BUILD_DEFINITIONS ${MAIN_BUILD_DEFINITIONS} UNIX;) SET

Re: [CMake] set_target_properties not setting COMPILE_DEFINITIONS?

2011-03-29 Thread David Doria
Did you do a make VERBOSE=1 to see what was being passed to the compiler? Yes, none of the definitions are being passed: http://pastebin.com/X0t0L4Jv http://pastebin.com/X0t0L4Jv David ___ Powered by www.kitware.com Visit other Kitware open-source

Re: [CMake] set_target_properties not setting COMPILE_DEFINITIONS?

2011-03-29 Thread David Doria
Can you create a standalone example of this to make it easier to debug? add_executable(foo foo.cxx) ... Bill, My standalone example works fine: http://pastebin.com/tGjX1AZ8 You can see that the UNIX and DAVID definitions are both passed. Maybe something is overriding the definitions in my

Re: [CMake] set_target_properties not setting COMPILE_DEFINITIONS?

2011-03-29 Thread David Doria
You might want to try running cmake --trace and see if something odd is happening when it is run. -Bill Here is the output of the trace: http://pastebin.com/MfTcNHFE It looks like the definitions list is being created and applied to the target, does it not? (see the last 10 lines of that

Re: [CMake] set_target_properties not setting COMPILE_DEFINITIONS?

2011-03-29 Thread David Doria
Most likely coming from here: /home/doriad/src/CMake/Modules/UsewxWidgets.cmake(72): SET(CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS} ${wxWidgets_CXX_FLAGS} ) I added: message(CMAKE_CXX_FLAGS: ${CMAKE_CXX_FLAGS}) and the output is: CMAKE_CXX_FLAGS: -pthread -ftemplate-depth-50 -Wall -Wno-deprecated

Re: [CMake] set_target_properties not setting COMPILE_DEFINITIONS?

2011-03-29 Thread David Doria
An inspection of your CMakeLists.txt file [1] and the outputs of make VERBOSE=1 [2,3] reveals the following goings-on: In [2], the lines 13 and 16 generate the object files CMakeFiles/Tech.dir/src/tech/Pch.cpp.o CMakeFiles/Tech.dir/src/tech/tech/Atomic.cpp.o and obviously, these are

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

2011-03-30 Thread David Doria
CMAKE_BUILD_TYPE should be a drop down box/fixed set of choices http://public.kitware.com/Bug/view.php?id=11806 http://public.kitware.com/Bug/view.php?id=11806 David ___ Powered by www.kitware.com Visit other Kitware open-source projects at

Re: [CMake] List of possible completion values

2011-03-30 Thread David Doria
On Wed, Mar 30, 2011 at 11:52 AM, Tim Gallagher tim.gallag...@gatech.eduwrote: Hi, Is there a way (and if not, how do I submit a feature request) to have a set of drop-down type options in the ccmake interface? The obvious example is for CMAKE_BUILD_TYPE, where something like hitting Enter

[CMake] Changing compiler

2011-04-20 Thread David Doria
I am trying to build ITK with a non-system-standard compiler. I did so by running: ccmake ../../src/ITK/ -DCMAKE_CXX_COMPILER=/home/doriad/src/gcc-4.5.2/bin/gcc/g++ However, I get: --- CMake Error at /usr/share/cmake/Modules/CMakeTestCXXCompiler.cmake:45 (MESSAGE): The C++

Re: [CMake] Changing compiler

2011-04-20 Thread David Doria
On Wed, Apr 20, 2011 at 9:04 AM, David Cole david.c...@kitware.com wrote: If you are setting the CXX compiler, you should also probably be setting the C compiler. I always use environment variables to do this:   export CC=/home/doriad/src/gcc-4.5.2/bin/gcc/gcc   export

Re: [CMake] Changing compiler

2011-04-21 Thread David Doria
Sounds like you must have gotten errors when you built gcc... Pore through the log of what happened during the gcc build maybe? Are you building gcc from source, or using some package manager to build it for you? (MacPorts, something else?) FYI - there was no problem all along with the

[CMake] Dynamic linking doesn't work after install

2011-04-22 Thread David Doria
I have created an executable like this: add_executable(ImageCompleter ${AppSources}) target_link_libraries(ImageCompleter ${LibrariesAlwaysUsed}) INSTALL( TARGETS ImageCompleter RUNTIME DESTINATION ${INSTALL_DIR} ) When I run the one that is created with 'make', it works fine.

Re: [CMake] Dynamic linking doesn't work after install

2011-04-22 Thread David Doria
I think the CMake page on RPATHs might be what you are looking for. http://www.cmake.org/Wiki/CMake_RPATH_handling Marcus Yea I read that, but I didn't really follow/see how to fix this problem. Surely there is a just copy the executable option? David

[CMake] Documentation suggestion

2011-05-01 Thread David Doria
On this page: http://www.cmake.org/cmake/help/cmake-2-8-docs.html there are many See XYZ statements. E.g. - else: Starts the else portion of an if block. else(expression) See the if command. - It would be very helpful if these were linked to the anchor of that command, e.g.: See

[CMake] If syntax

2011-05-01 Thread David Doria
According to this: http://www.cmake.org/cmake/help/cmake-2-8-docs.html#command:if the syntax is: if(expression) ... elseif(expression2) ... else(expression) ... endif(expression) I was recently made aware that: if(expression) ... elseif(expression2) ...

Re: [CMake] Documentation suggestion

2011-05-02 Thread David Doria
what about Doxyen[1]? Kind regards, Benjamin What do you think Dave C? As a side-effect it would then look like other Kitware based projects (ITK, VTK etc) which all use Doxygen. David ___ Powered by www.kitware.com Visit other Kitware open-source

[CMake] Running two executables sequentially in a test

2011-05-02 Thread David Doria
I am trying to run an executable that produces an output image, then compare this image to a baseline using a separate Compare executable. Is it possible to do this in a single add_test command? I tried separating the two executables with a semicolon, but that doesn't seem to work.

Re: [CMake] Running two executables sequentially in a test

2011-05-02 Thread David Doria
On Mon, May 2, 2011 at 1:31 PM, David Cole david.c...@kitware.com wrote: If it's supposed to be one test from ctest's point of view, you should write a script that makes 2 execute_process calls, and run the script as the add_test command. I tried to write a function that runs to executables,

Re: [CMake] Running two executables sequentially in a test

2011-05-02 Thread David Doria
On Mon, May 2, 2011 at 1:57 PM, David Cole david.c...@kitware.com wrote: script.cmake: execute_process(x) execute_process(y) CMakeLists.txt: add_test(NAME MyTest COMMAND ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_SOURCE_DIR}/script.cmake) Or, configure the script into the build tree if you need

Re: [CMake] Running two executables sequentially in a test

2011-05-02 Thread David Doria
On Mon, May 2, 2011 at 2:27 PM, Tyler ty...@cryptio.net wrote: You could use -D flags (cmake -Dvar=value -P script.cmake). That seems reasonable. I tried it: CMakeLists.txt - cmake_minimum_required(VERSION 2.6) PROJECT(Test) ENABLE_TESTING() ADD_EXECUTABLE(Test1 Test1.cxx)

[CMake] Library numeric extension?

2011-06-16 Thread David Doria
I added a simple: target_link_libraries(myprogram geotiff) to my CMakeLists.txt file. I have a libgeotiff.so in a directory on my LD_LIBRARY_PATH. The code compiled, but when I tried to run it, I got an error that I was missing libgeotiff.so.2. I made a symlink from libgeotiff.so.2 to

Re: [CMake] Library numeric extension?

2011-06-17 Thread David Doria
On Fri, Jun 17, 2011 at 4:30 PM, Eric Sokolowsky esok@gmail.com wrote: You didn't specify your development environment so I'm just guessing here. Under Linux, you usually have to install a development package in order to link to libraries. If you are compiling your own libgeotiff you might

[CMake] FindITK doesn't find an installed ITK?

2011-07-08 Thread David Doria
Hi all, If I build ITK in /home/doriad/build/ITK, and then in my .bashrc add: export ITK_DIR=/home/doriad/build/ITK when I start a new terminal and configure a project that needs ITK, it is found no problem - all is well. However, if I then install ITK (make install) to /home/doriad/bin (set

[CMake] FFTW_FOUND is true even if it is not found?

2011-08-22 Thread David Doria
Using this FindFFTW.cmake: http://code.google.com/p/qmcpack/source/browse/trunk/CMake/FindFFTW.cmake?spec=svn4506r=4506 FFTW_FOUND is true even though: FFTW_INCLUDE_DIR = FFTW_INCLUDE_DIR-NOTFOUND FFTW_LIBRARIES = FFTW_LIBRARIES_NOTFOUND Can anyone explain that? Thanks, David

Re: [CMake] FFTW_FOUND is true even if it is not found?

2011-08-22 Thread David Doria
From just that module, I do not have a reasonable explanation... What does this code output, when placed: (1) directly after the find_package(FFTW) call? (2) at the very bottom of your CMakeLists.txt file...?  message(STATUS FFTW_INCLUDE_DIR='${FFTW_INCLUDE_DIR}')  message(STATUS

[CMake] VS2010 Express generator?

2011-11-11 Thread David Doria
I am using CMake 2.8.6 and am hoping to generate a project for VS2010 Express. Which generator should I use? I tried Visual Studio 10, but when I configure I get all kinds of errors about the compiler not working. I can try to transcribe these if necessary, but I thought there might be an easier

[CMake] QtCreator generator?

2011-11-11 Thread David Doria
I saw a discussion about this back in March, but I didn't see any conclusions/resolutions. Is there a way to generate a QtCreator project using CMake? I tried the CMake support that was built into QtCreator itself, but it seems very awkward (you couldn't view/set variables, etc). Thanks, David

Re: [CMake] QtCreator generator?

2011-11-11 Thread David Doria
I think it's true that QtCreator knows how to connect to a CMake build tree generated with the CodeBlocks - Unix Makefiles generator. I tried to use this generator, but I get errors like cmake_c_compiler_env_var is undefined. Shouldn't it find the compiler for the VS2010Express installation?

Re: [CMake] QtCreator generator?

2011-11-11 Thread David Doria
On Fri, Nov 11, 2011 at 12:42 PM, Alexander Neundorf a.neundorf-w...@gmx.net wrote: On Friday 11 November 2011, David Doria wrote: I think it's true that QtCreator knows how to connect to a CMake build tree generated with the CodeBlocks - Unix Makefiles generator. I tried to use

Re: [CMake] QtCreator generator?

2011-11-11 Thread David Doria
Ok. one more: how exactly did you run cmake ? From the command line or cmake-gui ? From the CMake-GUI. Which generator did you choose ? It should be the CodeBlocks - NMake Makefiles one. I had chosen CodeBlocks - Unix Makefiles. I just tried again with CodeBlocks - NMake Makefiles, and I

Re: [CMake] QtCreator generator?

2011-11-11 Thread David Doria
That is the best way I have found to run CMake on Windows when multiple Visual Studios are installed. There is a Command Prompt short cut called Visual Studio Command Prompt that will have all the compiler paths setup for you. What I do is launch that command prompt then issue cmake-gui.exe

[CMake] Workflow of a collaborative project in Visual Studio+CMake

2011-11-11 Thread David Doria
I typically work in KDevelop which has CMake support, so if another developer pushes some new files and changes to the CMakeLists.txt of my project, I simply 'git pull' the project and then click Build and it knows exactly what to do - it runs CMake and then builds the project. However, when

Re: [CMake] QtCreator generator?

2011-11-11 Thread David Doria
On Fri, Nov 11, 2011 at 5:56 PM, John Drescher dresche...@gmail.com wrote: There should have been a *.sln file that you open.? Not for a Code Blocks -NMake Makefile project. John Ok, I guess I am getting my two threads confused. *To use QtCreator* The consensus is to use the Code Blocks -

Re: [CMake] QtCreator generator?

2011-11-11 Thread David Doria
*To use QtCreator* The consensus is to use the Code Blocks - NMake Generator. This has generated successfully a .cbp file (Code Block Project, I'm assuming). However, QtCreator seems unaware that this is a project and just opens it as plain text? How do I now open this project in

[CMake] Automatically pull in dependencies from QtDesigner plugins

2011-12-04 Thread David Doria
I have created a QT widget, MyWidget, and a QtDesigner plugin for MyWidget. Now I want to use MyWidget in bigger project, MyProject. I created a ui file for MyProject with QtDesigner and add a MyWidget in the designer. Now when I try to compile MyProject, I get (of course) error: can't find

Re: [CMake] Automatically pull in dependencies from QtDesigner plugins

2011-12-05 Thread David Doria
On Sun, Dec 4, 2011 at 11:34 AM, Michael Jackson mike.jack...@bluequartz.net wrote: Do you have MyWidget packaged as a true library, or did you just create the Designer Plugin and then have a loose .cpp/.h file?  The is a project called Qwt* that has a similar setup. It has a Designer

Re: [CMake] New type of cache variable: lists

2011-12-06 Thread David Doria
On Tue, Dec 6, 2011 at 4:19 PM, Robert Dailey rcdai...@gmail.com wrote: Has anyone thought of creating a LIST type for cache variables? In CMake GUI on Windows, this would be represented by a combo-box or drop-down box that allows the user to pick one item out of a list of available items. Is

[CMake] FindQtMobility

2011-12-14 Thread David Doria
It looks like this find script has been written for kde: http://old.nabble.com/Review-Request%3A-Add-a-FindQtMobility.cmake-file-td31823359.html I don't see it included in src/cmake/Modules - any plans to include it with CMake? David -- Powered by www.kitware.com Visit other Kitware

[CMake] Running coverage analysis

2012-01-02 Thread David Doria
I found this wiki page: http://www.vtk.org/Wiki/CTest/Coverage#Coverage_With_C.2B.2B that explains the flags that are necessary. I set up a demo project here and it compiles: http://www.vtk.org/Wiki/CTest/Coverage/Example However, how do you actually run the coverage analysis? I ran 'ctest'

Re: [CMake] Running coverage analysis

2012-01-03 Thread David Doria
On Tue, Jan 3, 2012 at 9:52 AM, David Cole david.c...@kitware.com wrote: To actually run the coverage testing, you need to have tests added with add_test in your CMakeLists file, then you need to run a ctest -S script that calls ctest_coverage, or use one of the predefined coverage dashboard

[CMake] Multiple tests in a single file

2012-01-06 Thread David Doria
Does CTest have a mechanism to run man mini-tests in a single file? I'm looking for something equivalent to the UnitTest++ syntax: TEST(YourTestName) {} TEST(YourOtherTestName){} int main(){  return UnitTest::RunAllTests();} Of course you could do something like: int YourTestName() { } int

Re: [CMake] Multiple tests in a single file

2012-01-06 Thread David Doria
On Fri, Jan 6, 2012 at 5:54 PM, Jean-Christophe Fillion-Robin jchris.filli...@kitware.com wrote: Hi David, Not too long ago I was browsing the project of a friend who worked on BTK (The toolkit used by Mokka, a motion kinematic kinetic analyser) [1]. I noticed that he is using cxxtest [2]

[CMake] Windows 64 bit version?

2010-09-05 Thread David Doria
I don't see a 64 bit Windows binary here: http://www.cmake.org/cmake/resources/software.html Is the link missing? Or does this not exist for some reason? Thanks, David ___ Powered by www.kitware.com Visit other Kitware open-source projects at

[CMake] Auto re-configuring until cache stops changing

2010-09-05 Thread David Doria
Lately I've been making a class full of students use CMake. Without exception, I've had to explain why you have to configure twice to build VTK. I imagine they are a representative sample of the Level 0 CMake user - they just want the project they are trying to build to work with default options,

Re: [CMake] Windows 64 bit version?

2010-09-05 Thread David Doria
It does not exist and it is not needed. The 32 bit cmake executable will work fine with 64 bit windows and 64 bit compilers. John Will do, thanks John. Maybe a note about this can be added to the website? Windows 64 bit | Use 32bit CMake David

Re: [CMake] Auto re-configuring until cache stops changing

2010-09-07 Thread David Doria
On Mon, Sep 6, 2010 at 9:18 AM, David Cole david.c...@kitware.com wrote: The Generate button should be enabled after the first configure. It's not enabled because the prevailing theory of the day was that you shouldn't allow generate unless there were *no* *new* cache entries after the most

Re: [CMake] Auto re-configuring until cache stops changing

2010-09-10 Thread David Doria
OK... good. I was just clarifying for the readers of the thread why we will not be auto-configuring-for-multiple-iterations... Ever. :-) Ok, so is the voting over? There didn't seem to be much participation (as expected...). Where does it go from here? David

Re: [CMake] Auto re-configuring until cache stops changing

2010-09-10 Thread David Doria
On Fri, Sep 10, 2010 at 10:25 AM, David Cole david.c...@kitware.com wrote: I think we're too close to the first release candidate of CMake 2.8.3 to be adding features at this point. But this is a great candidate for an early change immediately after the 2.8.3 release. If we get it into 'next'

[CMake] CPack general question and example

2010-11-15 Thread David Doria
I just heard about CPack and started playing with it. I tried to make an RPM of a simple VTK program: http://www.cmake.org/Wiki/CMake/CPackExample When I run 'make package', I get an error: CPack Error: Problem copying the package:

Re: [CMake] CPack general question and example

2010-11-15 Thread David Doria
You need  INSTALL commands for everything you want to be in the package For your example: ADD_EXECUTABLE(DistanceBetweenPoints DistanceBetweenPoints.cxx) INSTALL(TARGETS DistanceBetweenPoints DESTINATION bin) # Add this for CPack to work Then both make install and make package will work

Re: [CMake] CPack general question and example

2010-11-16 Thread David Doria
Great, it's working. The only thing that was required was: SET(CPACK_DEBIAN_PACKAGE_MAINTAINER David Doria) Here is the working example: http://www.cmake.org/Wiki/CMake/CPack/Examples/Linux/DEB The page you sent (http://www.vtk.org/Wiki/CMake:CPackPackageGenerators#DEB_.28UNIX_only.29) has

[CMake] BundleUtilities

2010-11-16 Thread David Doria
Hi all, I found the Qt example here: http://www.itk.org/Wiki/BundleUtilitiesExample http://www.itk.org/Wiki/images/2/25/QtTest-Package-Example.zip The two INSTALL commands seem fairly complicated - is there not a way to do all of that in the project-to-be-included's cmake configuration so that

[CMake] Compiling header files

2010-11-16 Thread David Doria
I am trying to use ADD_LIBRARY to create a .lib file from a collection of .cpp and .h files. If I do: ADD_LIBRARY(LibraryName AllOfTheCPPFiles.cpp) and then try to link against that library, I get many missing-function type linker errors. I looked in the .h files and many of them have actual

Re: [CMake] BundleUtilities

2010-11-16 Thread David Doria
On Tue, Nov 16, 2010 at 1:35 PM, Michael Jackson mike.jack...@bluequartz.net wrote: I think we used Qt as a basis because lots of people at the time were asking for it. Probably the simplest to demonstrate would be an example that builds a dynamic library and an executable that uses that

Re: [CMake] Compiling header files

2010-11-16 Thread David Doria
Ryan, The issue is that these headers are only used internally to this collection of files, so I don't want to have to include them in my code. Here is a skeleton: The files I've been given -- External.h External.cpp Internal.h (used by External) Internal.cpp My files

Re: [CMake] Compiling header files

2010-11-16 Thread David Doria
Hm, it works correctly in Linux, but I still get a bunch of error LNK2019: unresolved external symbol errors in Windows. The only difference I see is that the .lib file gets created in a subdirectory of bin/ bin/Debug/OSC.lib (or bin/Release/OSC.lib) vs the .a file which gets created in bin

Re: [CMake] Compiling header files

2010-11-16 Thread David Doria
Also use VS IDE to make sure the library is listed. The library is indeed listed in Additional Dependencies of the linker for the executable target. What symbols? Try running dumpbin /symbols OSC.lib. I figured it out - I had to link to winmm to get the symbol: symbol __imp__timeGetTime and

Re: [CMake] BundleUtilities

2010-11-16 Thread David Doria
Is the goal simply to copy ...VTK/bin/libvtkHybrid.a into the package? I tried this: INSTALL(CODE \${VTK_DIR}/bin/libvtkHybrid.a) But I get: Parse error. Expected a command name, got unquoted argument with text ${VTK_DIR}/bin/libvtkHybrid.a. I made a home for this here:

Re: [CMake] BundleUtilities

2010-11-17 Thread David Doria
Tyler, You seem to be right in that I should not escape the $, but I DID need to add DESTINATION bin. Without it, I got a: CMake Error at CMakeLists.txt:23 (INSTALL): install FILES given no DESTINATION! This seems to work: INSTALL(FILES ${VTK_DIR}/bin/libvtkHybrid.a DESTINATION bin) The

Re: [CMake] BundleUtilities

2010-11-17 Thread David Doria
On Wed, Nov 17, 2010 at 9:32 AM, Michael Jackson mike.jack...@bluequartz.net wrote: I tool a little different approach in my own projects. I end up configuring a shell script that gets run at install time (OS X Only). Inside that shell script are all the copying to the CMAKE_INSTALL_PREFIX,

Re: [CMake] BundleUtilities

2010-11-17 Thread David Doria
BundleUtilities is meant to be a more general approach to packaging 3rd party libraries. It will look at an executable, and find all of its dependencies (the ones necessary to make the program execute) and copy the non-system dependencies into your install directory. Clint, Great, this is

Re: [CMake] BundleUtilities

2010-11-17 Thread David Doria
The goal is simply this: - given: -- an executable target, that happens to be a bundle app on the Mac -- a full path to that bundle in the install tree -- a list of plugins that you have also already installed in the bundle -- a list of directories where to find libraries that your

[CMake] CTest cannot determine repository type

2010-11-18 Thread David Doria
When configuring ParaView (and other applications), I see this: CTest cannot determine repository type. Please set UPDATE_TYPE to 'cvs' or 'svn'. CTest update will not work. Is CTest aware of git? Thanks, David ___ Powered by www.kitware.com Visit

Re: [CMake] Concise Example of BundleUtilities for Windows

2010-12-26 Thread David Doria
On Sat, Dec 11, 2010 at 12:23 PM, Michael Jackson mike.jack...@bluequartz.net wrote: I did find that section. what I am a bit confused about is this:  ParaView includes its own version of BundleUtilities.cmake? Why?  ParaView includes its own version of GetPrerequisites.cmake? Why? Is

[CMake] Creating a library

2009-02-18 Thread David Doria
If I have many executables in the same project (ie same CMakeLists.txt file), it seems like I shouldn't have to do this: set(Sources File1.cpp File1.cpp ) ADD_EXECUTABLE(Test1 Test1.cpp ${Sources}) ADD_EXECUTABLE(Test2 Test2.cpp ${Sources}) because it is compiling File1 and File2 twice when

Re: [CMake] Creating a library

2009-02-18 Thread David Doria
Hoffman bill.hoff...@kitware.com wrote: David Doria wrote: If I have many executables in the same project (ie same CMakeLists.txt file), it seems like I shouldn't have to do this: set(Sources File1.cpp File1.cpp ) ADD_EXECUTABLE(Test1 Test1.cpp ${Sources}) ADD_EXECUTABLE(Test2 Test2.cpp

[CMake] How does find_package work?

2009-02-25 Thread David Doria
To include VXL, I do this: FIND_PACKAGE(VXL REQUIRED) INCLUDE(${VXL_CMAKE_DIR}/UseVXL.cmake) How can I make my projects work like that? Say I have a /Projects/Images folder that has a project including a CMakeLists.txt file. Then I start a project /Projects/NewProject and I want to use some

[CMake] Linking to a library with a -

2009-04-15 Thread David Doria
When I add a line like this: TARGET_LINK_LIBRARIES(MyProject boost_program_options-mt) in my link.txt file, -lboost_program_options gets produced instead (without the -mt), and therefore the library cannot be found. I've been creating a symlink with the name without the -mt and that works, but

Re: [CMake] Linking to a library with a -

2009-04-15 Thread David Doria
ions.cpp.o -o BoostProgramOptions -rdynamic -L/home/doriad/bin/boost/lib -lboos t_program_options -Wl,-rpath,/home/doriad/bin/boost/lib Thanks, David On Wed, Apr 15, 2009 at 9:12 AM, Brad King brad.k...@kitware.com wrote: David Doria wrote

Re: [CMake] Linking to a library with a -

2009-04-15 Thread David Doria
to boost_program_options-mt. Thanks, David On Wed, Apr 15, 2009 at 11:36 AM, Tyler Roscoe ty...@cryptio.net wrote: On Wed, Apr 15, 2009 at 11:09:43AM -0400, David Doria wrote: TARGET_LINK_LIBRARIES(MultipleLists boost_program_options-mt) Sort of a long shot, but did you try putting quotes around

Re: [CMake] Linking to a library with a -

2009-04-15 Thread David Doria
and the morning and report back if there are any problem - sorry for the mix up! Thanks, David On Wed, Apr 15, 2009 at 11:49 AM, Andreas Pakulat ap...@gmx.de wrote: On 15.04.09 11:09:43, David Doria wrote: I'm using Fedora 10. The KDevelop3 and normal makefile generator produce the same

[CMake] display default build type

2009-04-23 Thread David Doria
If in my CMakeLists.txt file I have: PROJECT(CMakeDemo) set(CMAKE_BUILD_TYPE DEBUG) ADD_EXECUTABLE(CMakeDemo cmakedemo.cpp) when I run ccmake on the directory and press 'c' to configure, the CMAKE_BUILD_TYPE field is still empty. Have I not set it properly? Or do you have to turn on show

[CMake] Automating configure and generate?

2009-06-22 Thread David Doria
Is there a way to automatically (in a bash script, for example) configure and generate using defaults from a CMakeLists.txt file? That is, automate doing the following: ccmake ../CMakeLists.txt press 'c' twice press 'g' Thanks, David ___ Powered by

[CMake] Set default build type in CMakeLists.txt

2009-06-22 Thread David Doria
I thought I could set the default build type with the following: SET(CMAKE_BUILD_TYPE debug) PROJECT(Test) ADD_EXECUTABLE(Test Test.cpp) However, when I run ccmake and then press 'c', the CMAKE_BUILD_TYPE field is still empty. Is it set and just not showing up? Or has it not been set properly?

Re: [CMake] Automating configure and generate?

2009-06-22 Thread David Doria
On Mon, Jun 22, 2009 at 11:49 AM, Phil Smith p...@voltage.com wrote: I don’t use ccmake, but wouldn’t just *cmake* followed by *make* do what you want? That’s what we do (wrapped in a ton of other stuff that cleans up the environment etc., but essentially it comes down to just those two

Re: [CMake] Set default build type in CMakeLists.txt

2009-06-22 Thread David Doria
You may also need to use FORCE: if(NOT CMAKE_BUILD_TYPE) set(CMAKE_BUILD_TYPE Release CACHE STRING Choose the type of build, options are: Debug Release RelWithDebInfo MinSizeRel. FORCE) endif(NOT CMAKE_BUILD_TYPE) James ___

Re: [CMake] Set default build type in CMakeLists.txt

2009-06-24 Thread David Doria
Because if you want to use FORCE you need to have a doc string. Note the [] grouping. If you don't provide a doc string it will not get the right number of arguments. set(variable value [[CACHE type docstring [FORCE]] | PARENT_SCOPE]) I've wanted the ability to set cache variables and

[CMake] CMake ignores CPLUS_INCLUDE_PATH?

2009-10-19 Thread David Doria
Before using CMake, I would set paths that I wanted g++ to search for header files by adding them to CPLUS_INCLUDE_PATH. Is there a way to get CMake to search the paths specified by this variable? Could this be default behavior? Thanks, David ___

Re: [CMake] CMake ignores CPLUS_INCLUDE_PATH?

2009-10-19 Thread David Doria
You can use $ENV{CPLUS_INCLUDE_PATH} to get the contents of the path. I tried to do this: INCLUDE_DIRECTORIES(${INCLUDE_DIRECTORIES} $ENV{CPLUS_INCLUDE_PATH}) but it still doesn't find the files (which it DOES find if I specify the path directly, ie. INCLUDE_DIRECTORIES(${INCLUDE_DIRECTORIES}

Re: [CMake] CMake ignores CPLUS_INCLUDE_PATH?

2009-10-19 Thread David Doria
On Mon, Oct 19, 2009 at 4:31 PM, Eric Noulard eric.noul...@gmail.com wrote: 2009/10/19 David Doria daviddo...@gmail.com: You can use $ENV{CPLUS_INCLUDE_PATH} to get the contents of the path. I tried to do this: INCLUDE_DIRECTORIES(${INCLUDE_DIRECTORIES} $ENV{CPLUS_INCLUDE_PATH}) I think

[CMake] Mediawiki CMake syntax highlighting

2009-11-29 Thread David Doria
I was wondering if there was any talk of adding cmake script support to mediawiki's source lang=X capability. It looks terrible if you just use text: http://www.cmake.org/Wiki/Paraview_Make_building_Paraview_plugin_optional And to make it look nice, you have to drastically alter the code (manual

Re: [CMake] Mediawiki CMake syntax highlighting

2009-11-30 Thread David Doria
I wrote a cmake highlighting for geshi earlier this year, if you install the geshi plugin for mediawiki, and place the attached file in your geshi folder, you should be able to get highlighting like so: source lang=cmake project(test) /source There are a few bugs, such as nested variables

[CMake] FindOpenCV.cmake

2009-12-11 Thread David Doria
What is the process for getting a library added to cmake? The instructions for installing OpenCV have the user download FindOpenCV.cmake and put it in their cmake/modules directory http://opencv.willowgarage.com/wiki/Getting_started?action=AttachFiledo=viewtarget=FindOpenCV.cmake Can this be

Re: [CMake] Mediawiki CMake syntax highlighting

2010-01-05 Thread David Doria
On Mon, Nov 30, 2009 at 8:17 AM, David Cole david.c...@kitware.com wrote: I forwarded it along... We'll see if it works good and let you know. Just following up - any luck with this? Thanks, David ___ Powered by www.kitware.com Visit other Kitware

Re: [CMake] Mediawiki CMake syntax highlighting

2010-01-06 Thread David Doria
, Jan 5, 2010 at 11:31 PM, David Doria daviddo...@gmail.com wrote: On Mon, Nov 30, 2009 at 8:17 AM, David Cole david.c...@kitware.com wrote: I forwarded it along... We'll see if it works good and let you know. Just following up - any luck with this? Thanks, David Excellent, it seems

[CMake] Qt qmake not found

2010-01-08 Thread David Doria
I am trying to use: FIND_PACKAGE(Qt4 REQUIRED) However, I get: CMake Error at /usr/share/cmake/Modules/FindQt4.cmake:1625 (MESSAGE): Qt qmake not found! I am using Fedora 11. I did yum install qt* qmake* but nothing changed. Any suggestions? Thanks, David

Re: [CMake] Qt qmake not found

2010-01-08 Thread David Doria
On Fri, Jan 8, 2010 at 9:50 PM, Tyler Roscoe ty...@cryptio.net wrote: On Fri, Jan 08, 2010 at 09:30:14PM -0500, David Doria wrote: I am trying to use: FIND_PACKAGE(Qt4 REQUIRED) However, I get:  CMake Error at /usr/share/cmake/Modules/FindQt4.cmake:1625 (MESSAGE):    Qt qmake not found! I

Re: [CMake] Qt qmake not found

2010-01-08 Thread David Doria
On Fri, Jan 8, 2010 at 10:07 PM, Mike Jackson mike.jack...@bluequartz.net wrote: You installed qt version 3 instead of qt version 4. Sudo apt-get install qt4-dev.  Or something like that. Mike Sent from my iPod On Jan 8, 2010, at 21:59, David Doria daviddo...@gmail.com wrote: On Fri, Jan

Re: [CMake] Qt qmake not found

2010-01-08 Thread David Doria
On Fri, Jan 8, 2010 at 10:10 PM, David Doria daviddo...@gmail.com wrote: On Fri, Jan 8, 2010 at 10:07 PM, Mike Jackson mike.jack...@bluequartz.net wrote: You installed qt version 3 instead of qt version 4. Sudo apt-get install qt4-dev.  Or something like that. Mike Sent from my iPod

Re: [CMake] Qt qmake not found

2010-01-09 Thread David Doria
On Sat, Jan 9, 2010 at 12:20 PM, Clinton Stimpson clin...@elemtech.com wrote: One last thing (hopefully). What's the trick to making it find: QT_PHONON_INCLUDE_DIR automatically? I set it to /usr/include/phonon and it works - but why wouldn't cmake find this? Thanks, David Maybe a

[CMake] Does cmake check CPLUS_INCLUDE_PATH?

2010-03-02 Thread David Doria
Does CMAKE_INCLUDE_PATH import things from CPLUS_INCLUDE_PATH? I messed with some system variables trying to get something unrelated to work, and now cmake complains that it can't find iostream.h when I try to build VTK. I definitely have some paths on CPLUS_INCLUDE_PATH that contain iostream.h -

  1   2   >