Re: [CMake] Accepted way to add "-fPIC" onto CMAKE_CXX_FLAGS?

2012-06-19 Thread Stephen Kelly
Michael Jackson wrote: > Linux really wants to have -fPIC for some of my code and I am trying to > detect linux and then add this flag for my project but I am having no > luck. > > if (LINUX) > set(CMAKE_CXX_FLAGS ${CMAKE_CSS_FLAGS} "-fPIC") > endif() > > Is this NOT the way I should be doing th

Re: [CMake] Using the Microsoft compiler with "Unix Makefiles"

2012-06-19 Thread Michael Jackson
It can be done as Bill Hoffman seems to do this all the time. Let's wait to see what he says. I do know that it involves a lot of setup. -- Mike Jackson On Jun 19, 2012, at 1:05 AM, William R. Otte wrote: > Hi Brendan - > > On Jun 18, 2012, at 11:49 PM, Braden McDaniel wrote: > >> Is it poss

Re: [CMake] Using the Microsoft compiler with "Unix Makefiles"

2012-06-19 Thread Bill Hoffman
On 6/19/2012 6:49 AM, Michael Jackson wrote: It can be done as Bill Hoffman seems to do this all the time. Let's wait to see what he says. I do know that it involves a lot of setup. Yes, this is my preferred generator. I used cygwin gmake, but this one: http://www.cmake.org/files/cygwin/make

Re: [CMake] Adding "*.obj" geometry files...

2012-06-19 Thread Daniel Dekkers
Hi, Although with the VS2008 generator setting the HEADER_FILE_ONLY property works to exclude the files from the build, in VS2010 no such luck. Am I doing something wrong in the syntax? Or is it a known issue with VS2010? We're doing this: # Mark all resource files as HEADER_ONLY to avoid (for i

Re: [CMake] Adding "*.obj" geometry files...

2012-06-19 Thread Brad King
On 06/19/2012 09:13 AM, Daniel Dekkers wrote: > Although with the VS2008 generator setting the HEADER_FILE_ONLY property > works to exclude the files from the build, in VS2010 no such luck. > Am I doing something wrong in the syntax? Or is it a known issue with > VS2010? IIRC CMake 2.8.7 and earli

[CMake] Help with source_group and regex

2012-06-19 Thread Joseph Henry
Hi, My scenario is that I have many source files in different directories that are all going into the same lib. dir1/file1.h dir1/file1.cpp dir1/file1.inl dir2/file2.h dir2/file2.cpp dir2/file2.inl These files are listed in a variable SOURCES. what I want to do is add them to a source group us

Re: [CMake] Adding "*.obj" geometry files...

2012-06-19 Thread Daniel Dekkers
Hi Brad, We were already using 2.8.8. We tried the nightly build but still no effect. It's not just the obj files, it's xml, ttf, png, ... The VS2008 generator works fine, with the nightly build as well, but VS2010,.. no excludes. Thanks, Daniel -Oorspronkelijk bericht- Van: Brad King [m

Re: [CMake] Help with source_group and regex

2012-06-19 Thread Petr Kmoch
Hi Joseph. The following should work: FOREACH(dir dir1 dir2) SOURCE_GROUP(${dir}\\inc REGULAR_EXPRESSION "${dir}/.*\\.h") SOURCE_GROUP(${dir}\\src REGULAR_EXPRESSION "${dir}/.*\\.cpp") SOURCE_GROUP(${dir}\\inl REGULAR_EXPRESSION "${dir}/.*\\.inl") ENDFOREACH() Petr On Tue, Jun 19, 2012 at 5:

[CMake] Separate compiler and linker pdb

2012-06-19 Thread Michele Santullo
Hello, we recently converted our project to cmake but for some reason, as we generate for VS 2008 on Windows, we get the same path for both the compiler and the linker generated pdb files. The path is something like /bin/Debug/Project.pdb for both, so they overwrite each other causing vari

Re: [CMake] Adding "*.obj" geometry files...

2012-06-19 Thread Brad King
On 06/19/2012 11:28 AM, Daniel Dekkers wrote: > We were already using 2.8.8. We tried the nightly build but still no effect. > It's not just the obj files, it's xml, ttf, png, ... > The VS2008 generator works fine, with the nightly build as well, but > VS2010,.. no excludes. I just tried 2.8.8 and

Re: [CMake] Using the Microsoft compiler with "Unix Makefiles"

2012-06-19 Thread Braden McDaniel
On 6/19/12 8:33 AM, Bill Hoffman wrote: On 6/19/2012 6:49 AM, Michael Jackson wrote: It can be done as Bill Hoffman seems to do this all the time. Let's wait to see what he says. I do know that it involves a lot of setup. Yes, this is my preferred generator. I used cygwin gmake, but this one:

[CMake] make install builds more than it needs to

2012-06-19 Thread Leif Walsh
Why does `make install` build things that aren't installed? I would imagine it would only build targets that are mentioned in INSTALL(). -- Cheers, Leif -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep mes

Re: [CMake] make install builds more than it needs to

2012-06-19 Thread David Cole
'make install' for a CMake-generated makefile is typically equivalent to 'make all && make install' 'install' depends on 'all' and all typically includes things that are installed and not installed. On Tue, Jun 19, 2012 at 3:11 PM, Leif Walsh wrote: > Why does `make install` build things that

Re: [CMake] make install builds more than it needs to

2012-06-19 Thread Leif Walsh
How can I make it not do that? Sent from my iPhone On Jun 19, 2012, at 15:39, David Cole wrote: > 'make install' for a CMake-generated makefile is typically equivalent to > 'make all && make install' > > 'install' depends on 'all' and all typically includes things that are > installed and no

Re: [CMake] make install builds more than it needs to

2012-06-19 Thread David Cole
'make install' under the hood, by default, simply runs: cmake -P cmake_install.cmake You could add your own custom target (which would NOT depend on 'all') to execute the same command, or simply execute the raw command yourself. To do it with a custom target, you could do: add_custom_target

Re: [CMake] make install builds more than it needs to

2012-06-19 Thread Leif Walsh
awesome, thanks On Tue, Jun 19, 2012 at 3:54 PM, David Cole wrote: > 'make install' under the hood, by default, simply runs: > >   cmake -P cmake_install.cmake > > You could add your own custom target (which would NOT depend on 'all') to > execute the same command, or simply execute the raw comma

[CMake] problem: No test configuration file found!

2012-06-19 Thread Robert Ramey
I'm working through my first CMake/CTest project. My directory structure looks like safe_numerics/ CMakeLists.txt // #1 build/ // out of source build directory include/ examples/ doc/ tests/ CMakeLists.txt // #2 #1 looks like cmake_minimum_required(VERSION 2.6) p

Re: [CMake] problem: No test configuration file found!

2012-06-19 Thread David Cole
Do: include(CTest) instead of: enable_testing() Including CTest.cmake will automatically enable_testing(), but it also configures the "test configuration file" it's complaining about... HTH, David On Tue, Jun 19, 2012 at 5:19 PM, Robert Ramey wrote: > I'm working through my first CMake/CT

Re: [CMake] Adding "*.obj" geometry files...

2012-06-19 Thread Brad King
On 06/19/2012 04:27 PM, Daniel Dekkers wrote: > SET_TARGET_PROPERTIES(HeaderOnlyTest PROPERTIES RESOURCE "${RESOURCE_FILE}") Does removing this line fix it? -Brad -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please

Re: [CMake] Adding "*.obj" geometry files...

2012-06-19 Thread Daniel Dekkers
Nope :( -Oorspronkelijk bericht- Van: Brad King [mailto:brad.k...@kitware.com] Verzonden: dinsdag 19 juni 2012 22:45 Aan: Daniel Dekkers CC: 'j'; cmake@cmake.org; 'Bill Hoffman' Onderwerp: Re: [CMake] Adding "*.obj" geometry files... On 06/19/2012 04:27 PM, Daniel Dekkers wrote: > SET_TA

[CMake] Include directory issue ... -I are not separated?

2012-06-19 Thread Ateljevich, Eli
Hi everone. I am getting a funny include flag and I wonder if anyone can help. The project is in Fortran (though I don't think this matters) and the structure can be distilled to: /myproj /build /src /Hydro I do the build in /build in linux using "cmake -DCMAKE_Fortran_COMPILER .

[CMake] Another minor docs issue; no FILE(DIFFERENT ... ) documentation?

2012-06-19 Thread Doug
is FILE(DIFFERENT ...) depreciated or reserved for internal use or something? It doesnt turn up in the docs online or the internal docs in Source/cmFileCommand.h Definitely in Sources/cmFileCommand.cxx though: else if ( subCommand == "DIFFERENT" ) { return this->HandleDifferentCommand(a

[CMake] Generating Eclipse project failed ( MacOS + Eclipse CDT 3.7 + vtk )

2012-06-19 Thread Jana Sefcikova
Dear users, I am new in CMake and I followed tutorial http://www.vtk.org/Wiki/Eclipse_CDT4_Generator , downloaded latest c++ Eclipse , my cmake version is 2.8.7 I obtained following warning/error ? during cmake configuration of my project : "-- Could not determine Eclipse version, assuming at leas

[CMake] Compiler detection on mac

2012-06-19 Thread Jaime Frey
With cmake 2.8.8, if you have both cc/c++ and gcc/g++ in your path, cmake will choose to use gcc and c++. This is because the default search orders in CMakeDetermineCCompiler.cmake and CMakeDetermineCXXCompiler.cmake are different. Up until now, this hasn't been a problem for us, as cc/c++ and

Re: [CMake] Include directory issue ... -I are not separated?

2012-06-19 Thread Eric Noulard
2012/6/20 Ateljevich, Eli : > Hi everone. I am getting a funny include flag and I wonder if anyone can > help. The project is in Fortran (though I don't think this matters) and the > structure can be distilled to: > > /myproj >   /build >   /src >      /Hydro > > I do the build in /build in linux

[CMake] [CDash] dashboard missing uploaded builds

2012-06-19 Thread m.hergarden
Since a few days my cdash dashboard has stopped showing certain uploaded builds. In the logfiles of the sites I can see they have been uploaded successfully, and I do see the files on the cdash server in the backup directory. The database does not show them however. The weird part is that it do

Re: [CMake] problem: No test configuration file found!

2012-06-19 Thread m.hergarden
I think you could put the enable_testing() and add_test() statements in a file called CMakeTests.txt in your subdirectory and include that in your toplevel cmakelists.txt. That works for me anyway. I'm not sure if this is the official way it is supposed to be done though. Regards, Micha On 06