[CMake] Ignore library flags now works in 2.4.8!
Hi, I just downloaded the new CMake version 2.4 patch 8. This command now works: SET(VS_MULTITHREADED_DEBUG_IGNORE_LIBRARY_FLAGS /NODEFAULTLIB:nafxcwd.lib /NODEFAULTLIB:libcmtd.lib ) I want to do the same thing for my release builds, kind of like: SET(VS_MULTITHREADED_RELEASE_IGNORE_LIBRARY_FLAGS /NODEFAULTLIB:nafxcw.lib /NODEFAULTLIB:libcmt.lib ) but that above command doesn't seem to do anything, the two libraries listed don't appear in my ignore library string for release builds. What's the proper command? Thanks, Mark ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Ignore library flags now works in 2.4.8!
Ah you're right, I had it paired with a call to: SET_TARGET_PROPERTIES(myapp PROPERTIES LINK_FLAGS_DEBUG ${VS_MULTITHREADED_DEBUG_IGNORE_LIBRARY_FLAGS}) which I overlooked - I added the same for the release version and it work. I haven't looked at this for a few months, sorry about the confusion, Thanks, Mark On Feb 18, 2008 4:08 PM, Bill Hoffman [EMAIL PROTECTED] wrote: Mark Wyszomierski wrote: Hi, I just downloaded the new CMake version 2.4 patch 8. This command now works: SET(VS_MULTITHREADED_DEBUG_IGNORE_LIBRARY_FLAGS /NODEFAULTLIB:nafxcwd.lib /NODEFAULTLIB:libcmtd.lib ) I want to do the same thing for my release builds, kind of like: SET(VS_MULTITHREADED_RELEASE_IGNORE_LIBRARY_FLAGS /NODEFAULTLIB:nafxcw.lib /NODEFAULTLIB:libcmt.lib ) but that above command doesn't seem to do anything, the two libraries listed don't appear in my ignore library string for release builds. What's the proper command? I don't see how that SET does anything other than set a variable. It must be how your project uses that variable. VS_MULTITHREADED_DEBUG_IGNORE_LIBRARY_FLAGS is not a variable that CMake looks at... 2.4.8 did fix the problem with multiple /NODEFAULTLIB lines not working. -Bill ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
[CMake] Ordering of libraries
Hi, Is there a way to get one of your libraries to be included in your project before default libraries? Tough to explain - I'm compiling specifically for visual studio 2005. When CMake is done creating the solution files, I can see the additional dependencies string looks like this: $(NOINHERIT) kernel32.lib user32.lib gdi32.lib winspool.lib shell32.lib ole32.lib oleaut32.lib uuid.lib comdlg32.lib advapi32.lib after advapi32.lib, any libs I chose to link to are also listed, using this command: target_link_libraries (myapp foo boo too) Is it possible to get some specific library I want BEFORE the first default lib included (in the above example, before kernel32.lib)? I normally wouldn't have to do this but ms has some bizarre bug where I needed to ignore two default libraries (done) but include them before all other system libraries...ok... Thanks, Mark ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
[CMake] question on linux release builds
Hi, Sorry if this is a duplicate message, forgot I wasn't subscribed to the list. When we create a linux build, and set the compile flag to 'release', no optimizations are actually performed, right? We need to pass that flag to 'make', right, something like: make -O2 otherwise, there's really no difference between that and a debug compilation, right? )other than different target libraries you specify in the CMake.txt file yourself) Thanks, Mark ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] question on linux release builds
Hi Olivier, Thanks, I do see that now with the advanced mode on. I am just confused on how this comes into use during actual compilation. I mean, my make file is generated in my project directory - but when I examine it, I don't see any mention about required libraries to link to, optimization level, etc. Shouldn't those be embedded inside the make file somehow? After CMake has generated the make file, I just go to the project dir through a console and type: make so how does make know what libs to link to, what optimization level to use if it's not stored in the make files? Thanks, Mark On Dec 18, 2007 11:18 AM, Olivier Delannoy [EMAIL PROTECTED] wrote: You can look for the flag being used using ccmake and displaying advance flags. If you do so you will see that the release build do use different flag than debug build. On Dec 18, 2007 4:05 PM, Mark Wyszomierski [EMAIL PROTECTED] wrote: Hi, Sorry if this is a duplicate message, forgot I wasn't subscribed to the list. When we create a linux build, and set the compile flag to 'release', no optimizations are actually performed, right? We need to pass that flag to 'make', right, something like: make -O2 otherwise, there's really no difference between that and a debug compilation, right? )other than different target libraries you specify in the CMake.txt file yourself) Thanks, Mark ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake -- Olivier Delannoy Ph.D. Student PRiSM Laboratory Versailles University, FRANCE ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] ignoring a specific library
Hi Philip, Thanks for your help. I down-graded to 2.4.6 but no luck. Here's my exact text: SET(VS_MULTITHREADED_DEBUG_IGNORE_LIBRARY_FLAGS /NODEFAULTLIB:nafxcwd.lib /NODEFAULTLIB:libcmtd.lib ) SET_TARGET_PROPERTIES(my_test_app PROPERTIES LINK_FLAGS_DEBUG ${VS_MULTITHREADED_DEBUG_IGNORE_LIBRARY_FLAGS}) After creating the solution files, I don't see anything in the ignore default library fields - any ideas? Thanks, Mark On 11/2/07, Philip Lowman [EMAIL PROTECTED] wrote: Mark Wyszomierski wrote: Is it possible to add an ignore library to CMakeLists.txt? This is specifically for a win32 project. I want to ignore: nafxcwd.lib libcmtd.lib Here's how I do this with CMake 2.4.6. Unfortunately passing more than one /NODEFAULTLIB arguments was broken in CMake 2.4.7 (see Bug #5455). In short, use the SET_TARGET_PROPERTIES() with the LINK_FLAGS or LINK_FLAGS_DEBUG, LINK_FLAGS_RELEASE, etc. options. SET(VS_MULTITHREADED_DEBUG_DLL_IGNORE_LIBRARY_FLAGS /NODEFAULTLIB:libc.lib /NODEFAULTLIB:libcmt.lib /NODEFAULTLIB:msvcrt.lib /NODEFAULTLIB:libcd.lib /NODEFAULTLIB:libcmtd.lib ) SET(VS_MULTITHREADED_RELEASE_DLL_IGNORE_LIBRARY_FLAGS /NODEFAULTLIB:libc.lib /NODEFAULTLIB:libcmt.lib /NODEFAULTLIB:libcd.lib /NODEFAULTLIB:libcmtd.lib /NODEFAULTLIB:msvcrtd.lib ) IF(MSVC) SET_TARGET_PROPERTIES(simulator-static PROPERTIES LINK_FLAGS_DEBUG ${VS_MULTITHREADED_DEBUG_DLL_IGNORE_LIBRARY_FLAGS}) SET_TARGET_PROPERTIES(simulator-static PROPERTIES LINK_FLAGS_RELWITHDEBINFO ${VS_MULTITHREADED_RELEASE_DLL_IGNORE_LIBRARY_FLAGS}) SET_TARGET_PROPERTIES(simulator-static PROPERTIES LINK_FLAGS_RELEASE ${VS_MULTITHREADED_RELEASE_DLL_IGNORE_LIBRARY_FLAGS}) SET_TARGET_PROPERTIES(simulator-static PROPERTIES LINK_FLAGS_MINSIZEREL ${VS_MULTITHREADED_RELEASE_DLL_IGNORE_LIBRARY_FLAGS}) ENDIF(MSVC) -- Philip Lowman Sr. Simulation Development Engineer, Modeling and Simulation Technology General Dynamics Land Systems http://www.gdls.com ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
[CMake] ignoring a specific library
Hi, Is it possible to add an ignore library to CMakeLists.txt? This is specifically for a win32 project. I want to ignore: nafxcwd.lib libcmtd.lib Thanks ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
[CMake] set environment variable
Hi, Is it possible to set an environment variable (linux) through CMake? Thanks, Mark ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] set environment variable
Hi David, I'm new to linux, do you mean that setting the env var like that through CMake will only affect my executables during run time- in other words the env var is only set for my exes? That's fine and what I need - Mark On 10/30/07, David Cole [EMAIL PROTECTED] wrote: Yes... SET(ENV{BLAH} blah value) ...but it only applies to the running process. The parent process environment remains unaffected by this type of SET. Then, to read env vars into cmake, use $ENV{BLAH} On 10/30/07, Mark Wyszomierski [EMAIL PROTECTED] wrote: Hi, Is it possible to set an environment variable (linux) through CMake? Thanks, Mark ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
[CMake] library names
Hi, I have a library project named lib_util. When using CMake to build the library (with g++), the output file is: liblib_util.a Now another sub project needs to link to that, and has the following in CMakeLists.txt: target_link_libraries(my_app, lib_util) but when compiling my_app, it seems somehow to be searching for: -llibutil during linking. How did that naming come about - isn't my CMakeLists.txt correct? Thanks, Mark ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] library names
You're right, I had one reference to libutil accidentally! Thanks, Mark On 10/29/07, Brandon Van Every [EMAIL PROTECTED] wrote: On 10/29/07, Mark Wyszomierski [EMAIL PROTECTED] wrote: Hi, I have a library project named lib_util. When using CMake to build the library (with g++), the output file is: liblib_util.a Now another sub project needs to link to that, and has the following in CMakeLists.txt: target_link_libraries(my_app, lib_util) but when compiling my_app, it seems somehow to be searching for: -llibutil during linking. How did that naming come about - isn't my CMakeLists.txt correct? Doesn't sound like it. :-) Sounds like you have a bug in your code somewhere. But if you really think your code is correct and CMake is the one removing the _ underscore, create a trivial reproducer for the problem in a few lines of code. If you've got an ironclad reproducer then make an entry in the bug tracker http://www.cmake.org/Bug . Cheers, Brandon Van Every ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] target path, or post build event?
Hi guys, First off, thanks for helping me with this. All the exes/libs I want to move will be built by CMake, in a post build event situation (ie. I generate the solution files/make file via CMake, open them in vc++, build the exes/libs, then want to move them to C:\test for example after done building). If I use the: INSTALL(TARGETS ${cmaketestTarget} DESTINATION ${dest}) that means the built exes/libs will only go to that 1 folder, right? They will no longer appear in their default build location - I'd like to have them appear in both. So I think I have to use the INSTALL (FILE) method as you guys suggested before, it looks like I just have to do something like: SET(CMAKE_INSTALL_PREFIX, C:\test); then build the INSTALL project everytime to make sure it copies the files there for me. Is that about right? Thanks, Mark On 10/25/07, KSpam [EMAIL PROTECTED] wrote: Mark, What do you have CMAKE_INSTALL_PREFIX set to? My guess is that it defaults to C:\Program Files\${PROJECT_NAME}. I do not develop on Windows, so I cannot say for sure. CMAKE_INSTALL_PREFIX is used to prefix the DESTINATION unless DESTINATION is specified as a full path. Alternately, you can set DESTINATION to a full path. Also, if cmaketest.exe is a target built by CMake, you might prefer to use: INSTALL(TARGETS ${cmaketestTarget} DESTINATION ${dest}) Justin On Thursday 25 October 2007 07:56:38 Mark Wyszomierski wrote: It seems to work, though is moving the file I want to copy into an unexpected location. Using the following: INSTALL(FILES debug/cmaketest.exe DESTINATION copy_file_test) I'm trying to move the file 'cmaketest.exe' located in a subdirectory called 'debug' into another subdirectory called 'copy_file_test'. The file actually gets copied to: C:\Program Files\CMAKETEST\copy_file_test though. The name of my project is CMakeTest. Any idea? Thanks, Mark ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
[CMake] target path, or post build event?
Hi, Is there some way to create an additional target for built binaries? Besides the default location (not sure where that's defined actually...) I'd like to have my projects all dump their build exes or libraries into 'C:\test' for example. Is it possible? Thanks, Mark ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] target path, or post build event?
Hi Justin, Thanks for replying. What runs the INSTALL code - is it executed by the CMake application when you're done configuring? Or do you manually run it yourself somehow? I tried adding this line to my CMakeLists.txt: INSTALL(FILES debug/cmaketest.exe DESTINATION ../copy_file_test) and I can see that a new solution file (for vc++ 2005) was added named INSTALL, but it has nothing underneath - not sure what I should be expecting it to look like? Thanks, Mark On 10/24/07, KSpam [EMAIL PROTECTED] wrote: Mark, The build location for libraries can be configured with LIBRARY_OUTPUT_PATH, and the build location for executables can be configured with EXECUTABLE_OUTPUT_PATH. I use the following lines in my projects: SET(EXECUTABLE_OUTPUT_PATH ${CMAKE_BINARY_DIR}/bin) SET(LIBRARY_OUTPUT_PATH ${CMAKE_BINARY_DIR}/lib) To put your executable and libraries in C:\test, I would suggest using the INSTALL command (cmake --help-command INSTALL). After building, you would just need to run the install target to move your executables and libraries out of the build directory and into the install directory of choice. The install directory is configured with the variable CMAKE_INSTALL_PREFIX. Justin On Wednesday 24 October 2007 10:49:37 Mark Wyszomierski wrote: Hi, Is there some way to create an additional target for built binaries? Besides the default location (not sure where that's defined actually...) I'd like to have my projects all dump their build exes or libraries into 'C:\test' for example. Is it possible? Thanks, Mark ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] including paths - basic
Thanks for the detailed answer Philip. I was able to get around this for my case by the feature included with target_libraries(debug | optimized) - luckily that's exactly what I needed. I understand what you're saying, maybe I can add an entry to the cmake wikipedia about it, Thanks, Mark On 10/21/07, Philip Lowman [EMAIL PROTECTED] wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Mark Wyszomierski wrote: Hi Mike, When I try CMAKE_BUILD_TYPE MATCHES Debug, it seems to never execute the contents of that IF statement (as if I am never CMake'ing a DEBUG build?). I don't know if CMAKE_BUILD_TYPE is the same thing as what's in the CMAKE_CONFIGURATION_TYPES field. I really need something like: IF (CMAKE_CONFIGURATION_TYPE MATCHES Debug) // include some library ELSE // ... ENDIF I'm not sure if that's the same thing? One common misconception (about CMake) is that it's always capable of doing what you think it should be doing. :) Part of the problem lies in the fact that CMake tries to support both single configuration type and multiple configuration type build tools simultaneously. The Makefile generator only supports one configuration type at a time (Debug, Release, etc.) which works out very nice as variables like CMAKE_BUILD_TYPE can be read at CMake time and used to change the configuration of the build. Take the following code for example... project(FOO) if(CMAKE_BUILD_TYPE MATCHES Debug) INCLUDE_DIRECTORIES(bar) else(CMAKE_BUILD_TYPE MATCHES Debug) INCLUDE_DIRECTORIES(top) endif(CMAKE_BUILD_TYPE MATCHES Debug) ADD_EXECUTABLE(foo foo.cc) Should do exactly what you want to do... When you set the CMAKE_BUILD_TYPE cache variable to Debug your Makefiles will add bar to the include path and vice versa if you don't define it. When you use a multiple configuration types generator like Visual Studio, however, the CMAKE_BUILD_TYPE variable will no longer exist. There is a hidden variable as you've discovered called CMAKE_CONFIGURATION_TYPES but this only describes the types of configurations which will show up in Visual Studio. There is no scripted support for dynamically changing project files to do different things using the configuration type of choice. You can introduce your own CACHE variables that change execution of CMake to do whatever you want but it would not work through the multiple build configuration feature of Visual Studio. You would basically have to use CMake to generate one solution files and then another set. There is limited support via the use of SET_TARGET_PROPERTIES to modify per configuration options that will work in Visual Studio but it's limited. Take the following which would change your generated .exe or .lib file for the target: SET_TARGET_PROPERTIES(foo PROPERTIES DEBUG_OUTPUT_NAME foodebug) SET_TARGET_PROPERTIES(foo PROPERTIES RELEASE_OUTPUT_NAME foorelease) So the short answer is, the code people post to the mailing list may or may not do what you want it to do... it all depends on what generator you are using. Sorry for any confusion, all of this probably should be documented somewhere in a CMake gotchas section. - -- Philip Lowman -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.7 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFHG9vZe0tOktX6RKkRAgJdAJwOSJXBcZwWAaPvtIPRpx+n/KVfVACfQaYI WVxF4ILsE4/q3ZjZBc6vMwM= =LfyP -END PGP SIGNATURE- ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
[CMake] defining preprocessor statements
Hi, How do we define a preprocessor statement - in win32 projects you usually need to see the following in the C/C++ - Preprocessor statements section: _WIN32, _WINDOWS ...etc so in the CMakeLists.txt, what syntax is used to put that into the generated project files? Thanks, Mark ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] defining preprocessor statements
Thanks Stefan. When I do that, I see the following text in the Preprocessor Definitions field (in vc++ 2005): ,WIN32,WINDOWS, I'm wondering if the leading and trailing commas will be a problem? Thanks, Mark On 10/20/07, Stefan Buschmann [EMAIL PROTECTED] wrote: Use ADD_DEFINITIONS: ADD_DEFINITIONS(-DWIN32 -DWINDOWS) - Stefan Mark Wyszomierski schrieb: Hi, How do we define a preprocessor statement - in win32 projects you usually need to see the following in the C/C++ - Preprocessor statements section: _WIN32, _WINDOWS ...etc so in the CMakeLists.txt, what syntax is used to put that into the generated project files? Thanks, Mark ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] including paths - basic
Hi Mike, When I try CMAKE_BUILD_TYPE MATCHES Debug, it seems to never execute the contents of that IF statement (as if I am never CMake'ing a DEBUG build?). I don't know if CMAKE_BUILD_TYPE is the same thing as what's in the CMAKE_CONFIGURATION_TYPES field. I really need something like: IF (CMAKE_CONFIGURATION_TYPE MATCHES Debug) // include some library ELSE // ... ENDIF I'm not sure if that's the same thing? Thanks, Mark On 10/19/07, Mike Jackson [EMAIL PROTECTED] wrote: IF ( CMAKE_BUILD_TYPE MATCHES Debug ) ADD_DEFINITIONS(-DDEBUG) ADD_DEFINITIONS(-Wall) ENDIF ( CMAKE_BUILD_TYPE MATCHES Debug ) -- Mike Jackson Senior Research Engineer Innovative Management Technology Services On Oct 19, 2007, at 9:34 AM, Mark Wyszomierski wrote: It works fine now that I try it - Is there any way to switch on debug and release builds? Something like: IF (DEBUG) include_directories(...) ELSE (DEBUG) include_directories(...) ENDIF (DEBUG) Thanks On 10/19/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: On Thursday 18 October 2007 19:32, Mark Wyszomierski wrote: Hi, I'm new to cmake, it looks great. Is it possible to include different paths conditionally, like: include_directories (${MY_PROJECT_SOURCE_DIR}/my_lib) IF (WIN32) include_directories (C:/my_stuff/lib/something) ELSE (WIN32) include_directories (/usr/lib/something) ENDIF (WIN32) The code looks good, do you have problems with it ? Alex ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] using SOURCE_GROUP
Whoops please ignore that - it works perfectly - I forgot I had commented the statements out, Thanks, Mark On 10/19/07, Mark Wyszomierski [EMAIL PROTECTED] wrote: Hi Neal, That doesn't seem to work for me - does 'subgroup' need to be created beforehand somehow? The following works for me: SOURCE_GROUP(Test FILES a.cpp a.h) but this doesn't seem to: SOURCE_GROUP(Source Files\\Test FILES a.cpp a.h) Thanks, Mark On 10/19/07, Neal Meyer [EMAIL PROTECTED] wrote: You just need to use the other slash SOURCE_GROUP( source\\subgroup FILES ${SOURCES} ) -Neal On 10/19/07, Mark Wyszomierski [EMAIL PROTECTED] wrote: Hi, Is it possible to create sub folders in the source tree for vc++ makes? I'm trying something like: IF (WIN32) SOURCE_GROUP(Source Files/Hello/ FILES a.cpp a.h AssocEchoSCP.cpp) ENDIF (WIN32) CMake automatically makes a source folder called Source Files, and I'd like to put a source folder nested under that, if possible, Thanks ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] using SOURCE_GROUP
Hi Neal, That doesn't seem to work for me - does 'subgroup' need to be created beforehand somehow? The following works for me: SOURCE_GROUP(Test FILES a.cpp a.h) but this doesn't seem to: SOURCE_GROUP(Source Files\\Test FILES a.cpp a.h) Thanks, Mark On 10/19/07, Neal Meyer [EMAIL PROTECTED] wrote: You just need to use the other slash SOURCE_GROUP( source\\subgroup FILES ${SOURCES} ) -Neal On 10/19/07, Mark Wyszomierski [EMAIL PROTECTED] wrote: Hi, Is it possible to create sub folders in the source tree for vc++ makes? I'm trying something like: IF (WIN32) SOURCE_GROUP(Source Files/Hello/ FILES a.cpp a.h AssocEchoSCP.cpp) ENDIF (WIN32) CMake automatically makes a source folder called Source Files, and I'd like to put a source folder nested under that, if possible, Thanks ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
[CMake] using SOURCE_GROUP
Hi, Is it possible to create sub folders in the source tree for vc++ makes? I'm trying something like: IF (WIN32) SOURCE_GROUP(Source Files/Hello/ FILES a.cpp a.h AssocEchoSCP.cpp) ENDIF (WIN32) CMake automatically makes a source folder called Source Files, and I'd like to put a source folder nested under that, if possible, Thanks ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
[CMake] including paths - basic
Hi, I'm new to cmake, it looks great. Is it possible to include different paths conditionally, like: include_directories (${MY_PROJECT_SOURCE_DIR}/my_lib) IF (WIN32) include_directories (C:/my_stuff/lib/something) ELSE (WIN32) include_directories (/usr/lib/something) ENDIF (WIN32) Can you keep added the include_directories statement? Thanks, Mark ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
[CMake] win32 rc files - or any other files besides cpp/cxx
Hi, I'm using cmake for a large project that has some win32 gui apps in it. In the main project folder I only include those sub projects if compiling for WIN32. That works fine. The win32 gui apps have a .rc file in a sub-folder named 'res'. How do you ask CMake to include those files in the resulting vc++ project? Thanks, Mark ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
[CMake] make file for win32 MDI application
Hi, When the application you're building the makefile for is an MDI application, how do you; 1) Set the sub system to be: Windows (/SUBSYSTEM:WINDOWS) in visual studio, this option is found under Project - Linker - System - Sub System if not set, the MDI (or any other GUI interface app) will have an identity crisis and become a console application. 2) Some default libs seem to be added to the linker settings even though not specified in the make file: kernel32.lib user32.lib gdi32.lib winspool.lib shell32.lib ole32.lib oleaut32.lib uuid.lib comdlg32.lib advapi32.lib linking to these libs in my MDI projects give produce a lot of linking errors. Is there any way to omit them? Thanks, Mark ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake