[cmake-developers] [CMake 0012574]: package name for the nameless component in DEB should not include the -unspecified extension
The following issue has been SUBMITTED. == http://www.itk.org/Bug/view.php?id=12574 == Reported By:kitts_82 Assigned To: == Project:CMake Issue ID: 12574 Category: CPack Reproducibility:always Severity: minor Priority: normal Status: new == Date Submitted: 2011-11-11 03:13 EST Last Modified: 2011-11-11 03:13 EST == Summary:package name for the nameless component in DEB should not include the -unspecified extension Description: The common package names for an package called myapp would be as follows myapp-data - contains mostly architecture independent readonly data required by the application. myapp-lib - contains libraries used by the application and those which may be used other applications myapp - Contains the main application and depends on the lib and data components myapp-dev - contains header files required for development Currently, the data, lib and dev component packages can be be generated by cpack. However, the myapp package that has no extension cannot be created as cpack autmatically adds the -unspecified extension to the package name. The attached patch ensures that the nameless component is indeed nameless in the finally generated package. == Issue History Date ModifiedUsername FieldChange == 2011-11-11 03:13 kitts_82 New Issue 2011-11-11 03:13 kitts_82 File Added: 0001-Even-through-the-file-name-has-Unpecified-in-it-let-.patch == -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers
[cmake-developers] PATCH Offending entry when using FindBISON.cmake with bison++
Hi, I've just found out that use of FindBISON.cmake shipped with CMake 2.8 on system where bison++ is default bison executable (e.g. Debian Linux) will result in corrupted CMakeCache.txt file and parse error due to Offending entry As FindBISON.cmake logic used to obtain installed bison executable version is tailored to match only the message used in GNU Bison it fails on absolutely different Bison++ version message and whole version message including \n characters is stored into BISON_VERSION which is then dumped into CMakeCache.txt, so everything after first \n character makes Offending entry. Attached patch fixes this by adding regexp for bison++. Regards, Ondrej --- FindBISON.cmake.orig2011-07-08 14:21:44.0 +0200 +++ FindBISON.cmake 2011-11-11 19:37:12.544611500 +0100 @@ -67,8 +67,17 @@ IF(NOT ${BISON_version_result} EQUAL 0) MESSAGE(SEND_ERROR Command \${BISON_EXECUTABLE} --version\ failed with output:\n${BISON_version_error}) ELSE() -STRING(REGEX REPLACE ^bison \\(GNU Bison\\) ([^\n]+)\n.* \\1 - BISON_VERSION ${BISON_version_output}) +# Bison++ +IF(${BISON_version_output} MATCHES ^bison\\+\\+) + STRING(REGEX REPLACE ^bison\\+\\+ Version ([^,]+).* \\1 +BISON_VERSION ${BISON_version_output}) +# GNU Bison +ELSEIF(${BISON_version_output} MATCHES ^bison[^+]) + STRING(REGEX REPLACE ^bison \\(GNU Bison\\) ([^\n]+)\n.* \\1 +BISON_VERSION ${BISON_version_output}) +ELSE() + SET(BISON_VERSION unknown) +ENDIF() ENDIF() # internal macro -- Ondrej Balaz -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers
[cmake-developers] [CMake 0012575]: I'm getting a Link error on Linux when I use CMake 2.8.6 or 2.8.5. If use CMake 2.6.3, with the exact same configuration, the l
The following issue has been SUBMITTED. == http://public.kitware.com/Bug/view.php?id=12575 == Reported By:David Bjornbak Assigned To: == Project:CMake Issue ID: 12575 Category: CMake Reproducibility:always Severity: major Priority: normal Status: new == Date Submitted: 2011-11-11 18:55 EST Last Modified: 2011-11-11 18:55 EST == Summary:I'm getting a Link error on Linux when I use CMake 2.8.6 or 2.8.5. If use CMake 2.6.3, with the exact same configuration, the l Description: I'm getting a Link error on Linux when I use CMake 2.8.6 or 2.8.5. If use CMake 2.6.3, with the exact same configuration, the link works. I did a diff on the build.make from 2.8.6 and 2.6.3 and found when I use cmake 2.8.6 On Linux adding headers to ..._EXTERNAL_OBJECTS for executables under the build.make. The following is the link error I get, it looks for a header but, the link.txt does need it and the diff on build.make that looks like is causing this. Link Error Message nux_x86_64/lib/libeemdump.so /hped/builds/tools/google-breakpad/784/lib.linux_x86_64/release/libbreakpad.a /hped/builds/tools/google-breakpad/78 4/lib.linux_x86_64/release/libbreakpad_client.a /hped/builds/tools/google-breakpad/784/lib.linux_x86_64/release/libbreakpad_server.a /gfs/sr/blu efin/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease/linux_x86_64/lib/libplugin_manager.so /hped/builds/tools/qt/4.7.4/linux_x86_6 4/lib/libQtCore.so /hped/builds/tools/cryptopp/5.6.0_0/linux_x86_64/release/libcryptopp.a /hped/builds/tools/boost/boost_1_45_0/lib.linux_x86_64 /release/libboost_date_time.a /hped/builds/tools/boost/boost_1_45_0/lib.linux_x86_64/release/libboost_filesystem.a /hped/builds/tools/boost/boos t_1_45_0/lib.linux_x86_64/release/libboost_program_options.a /hped/builds/tools/boost/boost_1_45_0/lib.linux_x86_64/release/libboost_system.a /h ped/builds/tools/boost/boost_1_45_0/lib.linux_x86_64/release/libboost_thread.a /hped/builds/tools/stl/5.2.1/lib.linux_x86_64/libstlport_gcc.so - Wl,-rpath,/hped/builds/tools/qt/4.7.4/linux_x86_64/lib:/hped/builds/tools/stl/5.2.1/lib.linux_x86_64:/gfs/sr/bluefin/d1/build/hped/builds/sr/dev XXX/rcupgrd_int/build/64bitrelease/linux_x86_64/lib:/release: msgs_eesofpvm_multitool.h:4:19: fatal error: Diag.h: No such file or directory compilation terminated. make[3]: *** [/gfs/sr/bluefin/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease/linux_x86_64/bin/eesofpvm_multitool] Error 1 make[3]: Leaving directory `/hfs/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease' make[2]: *** [projects/simsys/source/eesofpvm_multitool/CMakeFiles/eesofpvm_multitool.dir/all] Error 2 Diff with the build.make file, notice the file msgs_eesofpvm_multitool.h eesofpvm_multitool_EXTERNAL_OBJECTS = --- eesofpvm_multitool_EXTERNAL_OBJECTS = \ /hfs/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease/projects/simsys/source/eesofpvm_multitool/msgs_eesofpvm_multitool.h 498d482 /gfs/sr/bluefin/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease/linux_x86_64/bin/eesofpvm_multitool: /hped/builds/tools/qt/4.7.4 /linux_x86_64/lib/libQtCLucene.so 500,502d483 /gfs/sr/bluefin/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease/linux_x86_64/bin/eesofpvm_multitool: /usr/X11R6/lib64/libXext.so /gfs/sr/bluefin/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease/linux_x86_64/bin/eesofpvm_multitool: /usr/X11R6/lib64/libX11.so /gfs/sr/bluefin/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease/linux_x86_64/bin/eesofpvm_multitool: /usr/lib64/libm.so 519a501 /gfs/sr/bluefin/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bit release/linux_x86_64/bin/eesofpvm_multitool: projects/simsys/source/eeso fpvm_multitool/msgs_eesofpvm_multitool.h Attached is the diff under the CMakefiles area between 2.6.3 and 2.8.6 == Issue History Date ModifiedUsername FieldChange == 2011-11-11 18:55 David Bjornbak New Issue 2011-11-11 18:55 David Bjornbak File Added: diff.log == -- 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
[cmake-developers] [PATCH 0/3] The CMake Ninja generator.
Hi, These patches add the Ninja generator to CMake, which I am now proposing for inclusion in mainline. The generator should work with the current 'master' branch of Ninja from: https://github.com/martine/ninja The generator passes the CMake test suite on Linux (Debian testing) and FreeBSD 9.0-RC1, and I have been regularly using it myself with LLVM and Clang for about 2 months. I have also successfully tested it with the build systems for OpenCV, Bullet Physics, BRL-CAD, kdelibs and Path64. Some performance numbers for no-op builds (2.0GHz dual core laptop, Debian testing): CMake: Unix Makefiles: 0.6s Ninja: 0.042s kdelibs: Unix Makefiles: 9.8s Ninja: 2.5s [1] LLVM/Clang/Polly: Unix Makefiles: 2.9s Ninja: 0.18s BRL-CAD: Unix Makefiles: 19s Ninja: 0.40s Path64: Unix Makefiles: 3.9s Ninja: 0.25s Note that this generator is *nix only (it relies on POSIX shell functionality), and will only be built on *nix platforms. I am not interested in Windows support, but I understand that others have expressed an interest in adding support. I made some minor changes to the ExternalProject module as well as some of the tests to make them work with the generator, and added explanations for those changes as comments. I separated out the changes to kwsys, so that they can be applied separately. This patch series is also available from my git repository: git://github.com/pcc/CMake.git ninja-generator-pr Please review! Thanks, -- Peter [1] The disproportionately large Ninja run time here seems to be caused by a large number of required invocations of the 'automoc' command. -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers
[cmake-developers] [PATCH 1/3] Add SystemTools::TrimWhitespace function
--- Source/kwsys/SystemTools.cxx| 15 +++ Source/kwsys/SystemTools.hxx.in |5 + 2 files changed, 20 insertions(+), 0 deletions(-) diff --git a/Source/kwsys/SystemTools.cxx b/Source/kwsys/SystemTools.cxx index 1bf19c0..c14eb38 100644 --- a/Source/kwsys/SystemTools.cxx +++ b/Source/kwsys/SystemTools.cxx @@ -1195,6 +1195,21 @@ kwsys_stl::string SystemTools::UpperCase(const kwsys_stl::string s) return n; } +// Returns a string that has whitespace removed from the start and the end. +kwsys_stl::string SystemTools::TrimWhitespace(const kwsys_stl::string s) +{ + kwsys_stl::string::const_iterator start = s.begin(); + while(start != s.end() *start == ' ') +++start; + if (start == s.end()) +return ; + + kwsys_stl::string::const_iterator stop = s.end()-1; + while(*stop == ' ') +--stop; + return kwsys_stl::string(start, stop+1); +} + // Count char in string size_t SystemTools::CountChar(const char* str, char c) { diff --git a/Source/kwsys/SystemTools.hxx.in b/Source/kwsys/SystemTools.hxx.in index 04f1978..c03b8bc 100644 --- a/Source/kwsys/SystemTools.hxx.in +++ b/Source/kwsys/SystemTools.hxx.in @@ -129,6 +129,11 @@ public: static kwsys_stl::string UpperCase(const kwsys_stl::string); /** + * Returns a string that has whitespace removed from the start and the end. + */ + static kwsys_stl::string TrimWhitespace(const kwsys_stl::string s); + + /** * Count char in string */ static size_t CountChar(const char* str, char c); -- 1.7.5.3 -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers
Re: [CMake] CMake stripping /SUBSYSTEM out of LINK_FLAGS
Hi, it reaches the linker. I can't simply add WIN32 to add_executable() because I want debug builds to use the console sub-system and release builds to use the windows subsystem. I have three questions: I don't have a solution in cmake, but I worked around this using code from here: http://www.halcyon.com/~ast/dload/guicon.htm. It shows how to open a console window and redirect the output. It also has the benefit that the debug build is closer to release builds and that the entry point definition is more in line with the windows documentation (SUBSYSTEM:WINDOWS - WinMain, SUBSYSTEM:CONSOLE - main). Best regards, Jens -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Issue with check_include_file() and GL/glxproto.h
On 11/11/2011 04:13 AM, Michael Hertling wrote: On 11/10/2011 11:22 PM, Eric Noulard wrote: If this is the case then it is a GL/glxproto.h design mistake not CMake mistake. Absolutely, try to compile the following program by hand; it's the same the CHECK_INCLUDE_FILE() macro tries to compile, too: #includeGL/glxproto.h int main(void){return 0;} It will fail with the same error message, i.e. the GL/glxproto.h header is not self-sufficient; if intentionally or accidentally, I don't know. It's this failure that makes CHECK_INCLUDE_FILE() report the header as non-existent, or better as not compilable. I just sent them an e-mail so that they will be aware of the issue. This is true but the documentation tells you more about the macro cmake --help-module CheckIncludeFile says an optional third argument is the CFlags to add to the compile line or you can use CMAKE_REQUIRED_FLAGS which clearly states that it does a compilation. Indeed, CHECK_INCLUDE_FILE() means: Check if a header is *functional*. Ok, will use find_file instead. The thing you want is probably if(DEFINED VARIABLE) message(FATAL_ERROR VARIABLE already defined :${VARIABLE} aborting) endif() Yeah, thanks. I think it's not the responsability of check_include_file to do such job but you can do that in your CMakeLists.txt With FIND_FILE/PATH() looking for a header, the user must have the possibility to make them no-ops by presetting the result variable, so these functions must not overwrite a valid path. However, with CHECK_INCLUDE_FILE(), the user can't define a header as working; thus, there is no need to protect an already defined variable from being overwritten, IMO. Moreover, the user must have the chance to reuse the same variable for this purpose again without having the configuration terminate. OTOH, one usually uses an individually named variable for each header, e.g. HAVE_GL_GLXPROTO_H, as you do, which is most certainly not reused for anything at all. Ok but as I didn't understand why check_include_file was failing, I tried many things like simple then double quoting GL/glxproto.h and also tried a different variable name. I took HAVE_UNISTDE_H because I knew HAVE_UNISTD_H was working. With HAVE_UNISTDE_H, check_include_file seemed to work (it wasn't true, this variable name was simply defined before elsewhere) so in the end, I believed some variable names were allowed and others not. So to avoid the same mistake, I thought a message (at least a STATUS one) wouldn't hurt. IF(${VARIABLE} MATCHES ^${VARIABLE}$) fails : is it intended ? I do not understand In which case does it fail? Actually, every time. Here is the beginning of my modified CheckIncludeFile.cmake : MACRO(CHECK_INCLUDE_FILE INCLUDE VARIABLE) message(STATUS ${VARIABLE}) IF(${VARIABLE} MATCHES ^${VARIABLE}$) message(STATUS ${VARIABLE} matches ^${VARIABLE}$) and I only have the following output -- HAVE_SYS_TIME_H -- HAVE_SYS_TYPES_H -- HAVE_SYS_RESOURCE_H -- HAVE_SYS_STAT_H -- HAVE_UNISTD_H -- HAVE_FCNTL_H -- HAVE_GL_GLXPROTO_H CMake Error at CMakeLists.txt:117 (message): [..] So the first IF is failing, skipping the whole macro. If I add a # before this IF (and the corresponding ENDIF), check_include_file does its jobs and even finds the other headers : [...] -- HAVE_FCNTL_H -- HAVE_FCNTL_H matches ^HAVE_FCNTL_H$ -- Looking for fcntl.h -- Looking for fcntl.h - found -- HAVE_GL_GLXPROTO_H -- HAVE_GL_GLXPROTO_H matches ^HAVE_GL_GLXPROTO_H$ -- Looking for GL/glxproto.h -- Looking for GL/glxproto.h - not found Any idea ? -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Visual Studio 10 property pages for single source file gone with CMake 2.8.5 and 2.8.6
Update: I think users can work around this issue (#12570, empty property pages in VS10), by having the directory where to build the binaries on a separate drive (different from the drive that has the source files). Please let me know if you think that's not a good idea! Or if it does not work on your VS10 installation! - Original Message - From: Niels Dekker - address until 2014 To: cmake at cmake.org Sent: Thursday, November 10, 2011 17:29 Subject: Re: [CMake] Visual Studio 10 property pages for single source file gone with CMake 2.8.5 and 2.8.6 Thanks for your feedback so far on this subject. I have just reported the issue: 0012570: VS10 property pages for single source file gone http://public.kitware.com/Bug/view.php?id=12570 If you have any more comment or suggestion, please feel free to add a note to the report! A patch is highly appreciated, of course :-) Kind regards, Niels -- Niels Dekker http://www.xs4all.nl/~nd/dekkerware Scientific programmer at LKEB, Leiden University Medical Center -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Visual Studio 10 property pages for single source file gone with CMake 2.8.5 and 2.8.6
Separate drive may not be an option for some/many. I, for instance, don't use partitions, but I use CMakeas as main builder for my projects. So, I feel the pain of reloading, thus It's easier/quicker for me to close solution, rerun CMake, reopen solution. -- Mateusz Łoskot Sent from my mobile (excuse me for not quoting or top-posting possible) -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Visual Studio 10 property pages for single source file gone with CMake 2.8.5 and 2.8.6
Update: I think users can work around this issue (#12570, empty property pages in VS10), by having the directory where to build the binaries on a separate drive (different from the drive that has the source files). Mateusz Loskot wrote: Separate drive may not be an option for some/many. I, for instance, don't use partitions, but I use CMakeas as main builder for my projects. In order to work around http://public.kitware.com/Bug/view.php?id=12570 I think it should be sufficient to have a different drive *letter* when specifying where to build the binaries than the drive letter(s) of the path names of the source files. So I guess one might work around this issue by mapping a new drive letter to the build/bin directory, even while this directory might be located at the same physical drive as the source files. Right? Kind regards, Niels -- Niels Dekker http://www.xs4all.nl/~nd/dekkerware Scientific programmer at LKEB, Leiden University Medical Center -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Visual Studio 10 property pages for single source file gone with CMake 2.8.5 and 2.8.6
In order to work around http://public.kitware.com/Bug/view.php?id=12570 I think it should be sufficient to have a different drive *letter* when specifying where to build the binaries than the drive letter(s) of the path names of the source files. So I guess one might work around this issue by mapping a new drive letter to the build/bin directory, even while this directory might be located at the same physical drive as the source files. Right? You could also probably use the subst command to substitute the root drive. John -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
[CMake] Static Library output problem
Hello everyone! First, I need to thank you all the CMake developers for their awesome work!!! I try to build a static and a shared libraries. I set the LIBRARY_OUTPUT_DIRECTORY for each library target like this: set_target_properties(${sharedLib} PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/lib/${CMAKE_SYSTEM_NAME}-${CMAKE_SYSTEM_PROCESSOR}/${CMAKE_BUILD_TYPE}) set_target_properties(${staticLib} PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/lib/${CMAKE_SYSTEM_NAME}-${CMAKE_SYSTEM_PROCESSOR}/${CMAKE_BUILD_TYPE}) The shared library is built in the correct directory but the static is built in PROJECT_BINARY_DIR. I try to switch the order of the set_target_properties method but no changes. I don't why it doesn't work. Did anyone have any ideas? I attached my CMakeLists.txt file. Thanks, Romain PS: I'm on Ubuntu 11.10 64bits, with cmake 2.8.5 (installed from the deb package). cmake_minimum_required(VERSION 2.8) project(XmlParser) find_package(CxxTest) IF(CYGWIN) unset(WIN32) ENDIF() # The version number set(XmlParser_VERSION_MAJOR 1) set(XmlParser_VERSION_MINOR 0) set(XmlParser_VERSION_REVISION b) set(XmlParser_VERSION ${XmlParser_VERSION_MAJOR}.${XmlParser_VERSION_MINOR}${XmlParser_VERSION_REVISION}) # configure a header file to pass some of the CMake settings # to the source code configure_file( ${PROJECT_SOURCE_DIR}/include/XmlParserConfig.h.in ${PROJECT_BINARY_DIR}/include/XmlParserConfig.h ) include_directories(include ${PROJECT_BINARY_DIR}/include) file(GLOB SOURCE_FILES src/*.cpp include/template/*.hpp ) file(GLOB INCLUDE_FILES include/*.h ${PROJECT_BINARY_DIR}/include/*.h ) set(xmlParserSharedLib xmlParser) set(xmlParserStaticLib xmlParserStatic) add_library(${xmlParserStaticLib} STATIC ${SOURCE_FILES}) add_library(${xmlParserSharedLib} SHARED ${SOURCE_FILES}) set_target_properties(${xmlParserStaticLib} PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/lib/${CMAKE_SYSTEM_NAME}-${CMAKE_SYSTEM_PROCESSOR}/${CMAKE_BUILD_TYPE}) set_target_properties(${xmlParserSharedLib} PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/lib/${CMAKE_SYSTEM_NAME}-${CMAKE_SYSTEM_PROCESSOR}/${CMAKE_BUILD_TYPE}) #install(TARGETS ${xmlParserSharedLib} ${xmlParserStaticLib} DESTINATION lib) #install(FILES ${INCLUDE_FILES} DESTINATION include) if(CXXTEST_FOUND) set(xmlParser_test_include ${PROJECT_SOURCE_DIR}/unitary-test/include) set(xmlParser_test_src unitary-test/src) set(xmlParser_test_build unitary-test/build) set(CXXTEST_USE_PYTHON TRUE) include_directories(${CXXTEST_INCLUDE_DIR}) set(XmlElementTest ${xmlParser_test_build}/XmlElementTest) CXXTEST_ADD_TEST(${XmlElementTest} ${xmlParser_test_src}/XmlElementTest.cpp ${xmlParser_test_include}/XmlElementTest.h) target_link_libraries(${XmlElementTest} ${xmlParserStaticLib}) endif() -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Static Library output problem
On 11/11/2011 03:18 PM, Romain LEGUAY wrote: Hello everyone! First, I need to thank you all the CMake developers for their awesome work!!! I try to build a static and a shared libraries. I set the LIBRARY_OUTPUT_DIRECTORY for each library target like this: set_target_properties(${sharedLib} PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/lib/${CMAKE_SYSTEM_NAME}-${CMAKE_SYSTEM_PROCESSOR}/${CMAKE_BUILD_TYPE}) set_target_properties(${staticLib} PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/lib/${CMAKE_SYSTEM_NAME}-${CMAKE_SYSTEM_PROCESSOR}/${CMAKE_BUILD_TYPE}) The shared library is built in the correct directory but the static is built in PROJECT_BINARY_DIR. I try to switch the order of the set_target_properties method but no changes. I don't why it doesn't work. Did anyone have any ideas? I attached my CMakeLists.txt file. Thanks, Romain PS: I'm on Ubuntu 11.10 64bits, with cmake 2.8.5 (installed from the deb package). For static libraries, all the variables and properties use the ARCHIVE name (e.g. ARCHIVE_OUTPUT_DIRECTORY). HTH Michael -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Static Library output problem
On 11.11.11 15:18:05, Romain LEGUAY wrote: Hello everyone! First, I need to thank you all the CMake developers for their awesome work!!! I try to build a static and a shared libraries. I set the LIBRARY_OUTPUT_DIRECTORY for each library target like this: See the documentation for the LIBRARY_OUTPUT_DIRECTORY, it only applies to shared libraries on non-dll platforms (*nix usually). For a static library you need to set ARCHIVE_OUTPUT_DIRECTORY. Andreas -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Static Library output problem
Ok thanks for your quick answers! It works perfectly now! Why don't we have just one variables for the library? With set_target_properties, we can define for each library the path. Romain Le 11/11/2011 15:38, Andreas Pakulat a écrit : On 11.11.11 15:18:05, Romain LEGUAY wrote: Hello everyone! First, I need to thank you all the CMake developers for their awesome work!!! I try to build a static and a shared libraries. I set the LIBRARY_OUTPUT_DIRECTORY for each library target like this: See the documentation for the LIBRARY_OUTPUT_DIRECTORY, it only applies to shared libraries on non-dll platforms (*nix usually). For a static library you need to set ARCHIVE_OUTPUT_DIRECTORY. Andreas -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Adding a new language
According to http://caml.inria.fr/pub/docs/manual-ocaml/manual022.html, it does: -o exec-file Specify the name of the output file produced by the compiler. The default output name is a.out under Unix and camlprog.exe under Windows. If This manpage describes all kinds of uses and in practice the -o only applies to the case whre you use ocamlc to link your program (notice how it says -o exec file rather than -o output-file), but it seems ignored when using it to just compile one file. I guess part of the reason is that in that case there is more than one output (it generates a .cmo and a .cmi file for each input file), so it wouldn't be clear what to do with this single output file name. So using set (CMAKE_OCaml_COMPILE_OBJECT CMAKE_OCaml_COMPILER -c -o OBJEJCT SOURCE) does not work? Nope, Stefan -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Adding a new language
I'm trying to use cmake for a project using OCaml, so I'm trying to add support for a new language. Just in case you weren't aware of that. There has been [several] discussions on the ML in the past concerning CMake OCaml support at least this one: http://www.cmake.org/pipermail/cmake/2010-March/035740.html I've seen those, yes. But they don't seem to give me any answer. Stefan -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Visual Studio 10 property pages for single source file gone with CMake 2.8.5 and 2.8.6
In order to work around http://public.kitware.com/Bug/view.php?id=12570 I think it should be sufficient to have a different drive *letter* when specifying where to build the binaries than the drive letter(s) of the path names of the source files. John Drescher wrote: You could also probably use the subst command to substitute the root drive. Thanks, John. My build/bin directory is at D:\Build. When I do 'subst B: D:\', and open a VS10 .sln file from B:\Build, Visual Studio 2010 allows me to view the C/C++ properties of individual source files. Cool! I think I'll add 'subst B: D:\' to my system startup :-) Kind regards, Niels -- Niels Dekker http://www.xs4all.nl/~nd/dekkerware Scientific programmer at LKEB, Leiden University Medical Center -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Visual Studio 10 property pages for single source file gone with CMake 2.8.5 and 2.8.6
On 11 November 2011 13:54, Niels Dekker - address until 2014 niels_dekker_address_until_2...@xs4all.nl wrote: Update: I think users can work around this issue (#12570, empty property pages in VS10), by having the directory where to build the binaries on a separate drive (different from the drive that has the source files). Mateusz Loskot wrote: Separate drive may not be an option for some/many. I, for instance, don't use partitions, but I use CMakeas as main builder for my projects. In order to work around http://public.kitware.com/Bug/view.php?id=12570 I think it should be sufficient to have a different drive *letter* when specifying where to build the binaries than the drive letter(s) of the path names of the source files. So I guess one might work around this issue by mapping a new drive letter to the build/bin directory, even while this directory might be located at the same physical drive as the source files. Right? I guess it's feasible. I'll try this approach when I have a free moment. Thanks. Best regards, -- Mateusz Loskot, http://mateusz.loskot.net -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] cdt generator and subclipse?
On Friday 11 November 2011, Dan Kegel wrote: On Thu, Nov 10, 2011 at 2:32 PM, Dan Kegel d...@kegel.com wrote: http://www.cmake.org/Wiki/Eclipse_CDT4_Generator says the cdt generator should work with subclipse if you set -DECLIPSE_CDT4_GENERATE_SOURCE_PROJECT=TRUE on the commandline when running cmake, but it doesn't seem to be working here. It's working now, though I don't think I changed anything; must have been user error. One thing that wasn't clear to me before - when things are working properly, when you do File / Import / General / Add Existing Project to Workspace on the parent directory of both build and source, it will pick up both projects, and connect them to svn properly. What did you do ? Can you please explain exactly ? I'd really like to know. Alex -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Where are tests located?
On Thu, Nov 10, 2011 at 4:33 PM, EXT-York, Gantry gantry.y...@boeing.com wrote: OK, so if I'm trying to add a test do I just add_executable( run_main.pl IMPORTED ) set_property( TARGET test_script1 PROPERTY IMPORTED_LOCATION ${CMAKE_CURRENT_SOURCE_DIR}/run_main.pl ) add_test( test1 run_main.pl) If run_main.pl is #!/usr/bin/perl system main --val 24 Main could be in the build tree if it comes from main.cxx or it could be in the source tree if it is a script. How does cmake know where main is at? -Original Message- From: David Cole [mailto:david.c...@kitware.com] Sent: Thursday, November 10, 2011 1:09 PM To: EXT-York, Gantry Cc: cmake@cmake.org Subject: Re: [CMake] Where are tests located? When you add an IMPORTED target, CMake does not know where the imported target is AT ALL until you tell it. After: add_executable(run_main.pl IMPORTED) You need: set_property(TARGET run_main.pl PROPERTY IMPORTED_LOCATION ${CMAKE_CURRENT_SOURCE_DIR}/run_main.pl) See docs here: http://cmake.org/cmake/help/cmake-2-8-docs.html#command:set_property http://cmake.org/cmake/help/cmake-2-8-docs.html#prop_tgt:IMPORTED_LOCATION HTH, David On Thu, Nov 10, 2011 at 3:00 PM, EXT-York, Gantry gantry.y...@boeing.com wrote: When I do an add_executable( run_main.pl IMPORTED) add_test( test1 run_main.pl) How does it know where run_main.pl is located when you do an out of source build? It seems to look in . Releases Debug MinSizeRel RelWithDebInfo Deployment Development which are directories that I don't even see existing. And if run_main.pl is just #!/usr/bin/perl system ../exec/main How does it know if ../exec/main is in the src tree or the build tree? If main is a C binary, it would be in the build tree, if it is just a script it would be in the source tree. Gantry York Chandler, Arizona -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake If I were running a perl script as a test, here's how I would write the CMakeLists.txt file: cmake_minimum_required(VERSION 2.8) project(perl_test) include(CTest) find_package(Perl) message(PERL_EXECUTABLE='${PERL_EXECUTABLE}') add_test(NAME test1 COMMAND ${PERL_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/run_main.pl) By default the working directory will be in CMAKE_CURRENT_BINARY_DIR when the test runs. You can control it on a per-test basis by adding the WORKING_DIRECTORY keyword to the add_test command if you know in the CMakeLists file which test has main in the source tree and which test has main.exe in the binary tree. Something like this: add_test(NAME test_of_script COMMAND ${PERL_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/run_main.pl WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}) add_test(NAME test_of_exe COMMAND ${PERL_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/run_main.pl WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}) However, CMake has no idea where main is, and for that matter, neither does perl unless you tell it. I would recommend structuring the perl script so that it takes in a directory argument of where to look for the main script or executable. Then you could use an expression like this to pass it along to the perl script: add_test(NAME test_passing_dir COMMAND ${PERL_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/run_main.pl --dir $TARGET_FILE_DIR:main WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}) Of course, use the actual target name for the target that produces main in that last example, not the actual string main. CMake enforces name uniqueness among all targets in the whole tree. Hopefully, this sheds a little more light on things for you. HTH, David -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Where are tests located?
On Thu, Nov 10, 2011 at 4:41 PM, EXT-York, Gantry gantry.y...@boeing.com wrote: If I'm in a traversed subdirectory, is there a different variable other than ${CMAKE_CURRENT_SOURCE_DIR} that I should be using? This doesn't seem to work. Gantry York Chandler, Arizona -Original Message- From: cmake-boun...@cmake.org [mailto:cmake-boun...@cmake.org] On Behalf Of EXT-York, Gantry Sent: Thursday, November 10, 2011 2:34 PM To: David Cole Cc: cmake@cmake.org Subject: Re: [CMake] Where are tests located? OK, so if I'm trying to add a test do I just add_executable( run_main.pl IMPORTED ) set_property( TARGET test_script1 PROPERTY IMPORTED_LOCATION ${CMAKE_CURRENT_SOURCE_DIR}/run_main.pl ) add_test( test1 run_main.pl) If run_main.pl is #!/usr/bin/perl system main --val 24 Main could be in the build tree if it comes from main.cxx or it could be in the source tree if it is a script. How does cmake know where main is at? -Original Message- From: David Cole [mailto:david.c...@kitware.com] Sent: Thursday, November 10, 2011 1:09 PM To: EXT-York, Gantry Cc: cmake@cmake.org Subject: Re: [CMake] Where are tests located? When you add an IMPORTED target, CMake does not know where the imported target is AT ALL until you tell it. After: add_executable(run_main.pl IMPORTED) You need: set_property(TARGET run_main.pl PROPERTY IMPORTED_LOCATION ${CMAKE_CURRENT_SOURCE_DIR}/run_main.pl) See docs here: http://cmake.org/cmake/help/cmake-2-8-docs.html#command:set_property http://cmake.org/cmake/help/cmake-2-8-docs.html#prop_tgt:IMPORTED_LOCATION HTH, David On Thu, Nov 10, 2011 at 3:00 PM, EXT-York, Gantry gantry.y...@boeing.com wrote: When I do an add_executable( run_main.pl IMPORTED) add_test( test1 run_main.pl) How does it know where run_main.pl is located when you do an out of source build? It seems to look in . Releases Debug MinSizeRel RelWithDebInfo Deployment Development which are directories that I don't even see existing. And if run_main.pl is just #!/usr/bin/perl system ../exec/main How does it know if ../exec/main is in the src tree or the build tree? If main is a C binary, it would be in the build tree, if it is just a script it would be in the source tree. Gantry York Chandler, Arizona -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake CMAKE_SOURCE_DIR is the value of the top level source tree that you give to cmake (or cmake-gui, or ccmake) when you configure a build tree. CMAKE_CURRENT_SOURCE_DIR starts out as CMAKE_SOURCE_DIR in the top level CMakeLists.txt file, and then changes value as subdirectories are traversed via add_subdirectory. HTH, David -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
[CMake] Specifying library build path for simulator and device for an iOS target in Xcode
Hi, We are building a lib and an example app in Xcode (4.2) targeting iOS (5.0). The top-level CMakeLists.txt recurses into lib and example: PROJECT(Suite) ADD_SUBDIRECTORY(MyLibrary) ADD_SUBDIRECTORY(MyExample) The lib is built in the traditional way… PROJECT(MyLib) … ADD_LIBRARY( ${MYLIB_SOURCES} ) As is the example: PROJECT(MyExample) … ADD_EXECUTABLE(MyExample MACOS_BUNDLE ${MYEXAMPLE_SOURCES}) TARGET_LINK_LIBRARIES( MyExample MyLib) ADD_DEPENDENCIES(MyExample MyLib) But during linking of the example, MyExample expects the built lib to be in: path/to/build/MyLibrary/Debug/ While Xcode will build to path/to/build/MyLibrary/Debug-iphonesimulator/ or path/to/build/MyLibrary/Debug-iphoneos/ depending on the scheme you select. Anyone know how to get inbetween, letting CMake know there is this -iphoneos or -iphonesimulator postfix needed. Thanks, Daniel -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Specifying library build path for simulator and device for an iOS target in Xcode
On Fri, Nov 11, 2011 at 11:12 AM, Daniel Dekkers d.dekk...@cthrough.nl wrote: Hi, We are building a lib and an example app in Xcode (4.2) targeting iOS (5.0). The top-level CMakeLists.txt recurses into lib and example: PROJECT(Suite) ADD_SUBDIRECTORY(MyLibrary) ADD_SUBDIRECTORY(MyExample) The lib is built in the traditional way… PROJECT(MyLib) … ADD_LIBRARY( ${MYLIB_SOURCES} ) As is the example: PROJECT(MyExample) … ADD_EXECUTABLE(MyExample MACOS_BUNDLE ${MYEXAMPLE_SOURCES}) TARGET_LINK_LIBRARIES( MyExample MyLib) ADD_DEPENDENCIES(MyExample MyLib) But during linking of the example, MyExample expects the built lib to be in: path/to/build/MyLibrary/Debug/ While Xcode will build to path/to/build/MyLibrary/Debug-iphonesimulator/ or path/to/build/MyLibrary/Debug-iphoneos/ depending on the scheme you select. Anyone know how to get inbetween, letting CMake know there is this -iphoneos or -iphonesimulator postfix needed. Thanks, Daniel -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake Are you using CMake 2.8.6? Is the following line in your top level CMakeLists.txt file? set(CMAKE_XCODE_EFFECTIVE_PLATFORMS -iphoneos;-iphonesimulator) If not, try both of those and let me know if it's still wrong. The effective platform stuff is new in 2.8.6, and there are probably still some rough edges for complex projects... HTH, David -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
[CMake] VS2010 Express generator?
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 answer first. Thanks, David -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Specifying library build path for simulator and device for an iOS target in Xcode
Thanks. You saved the day (again). Works perfectly. On Nov 11, 2011, at 5:22 PM, David Cole wrote: On Fri, Nov 11, 2011 at 11:12 AM, Daniel Dekkers d.dekk...@cthrough.nl wrote: Hi, We are building a lib and an example app in Xcode (4.2) targeting iOS (5.0). The top-level CMakeLists.txt recurses into lib and example: PROJECT(Suite) ADD_SUBDIRECTORY(MyLibrary) ADD_SUBDIRECTORY(MyExample) The lib is built in the traditional way… PROJECT(MyLib) … ADD_LIBRARY( ${MYLIB_SOURCES} ) As is the example: PROJECT(MyExample) … ADD_EXECUTABLE(MyExample MACOS_BUNDLE ${MYEXAMPLE_SOURCES}) TARGET_LINK_LIBRARIES( MyExample MyLib) ADD_DEPENDENCIES(MyExample MyLib) But during linking of the example, MyExample expects the built lib to be in: path/to/build/MyLibrary/Debug/ While Xcode will build to path/to/build/MyLibrary/Debug-iphonesimulator/ or path/to/build/MyLibrary/Debug-iphoneos/ depending on the scheme you select. Anyone know how to get inbetween, letting CMake know there is this -iphoneos or -iphonesimulator postfix needed. Thanks, Daniel -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake Are you using CMake 2.8.6? Is the following line in your top level CMakeLists.txt file? set(CMAKE_XCODE_EFFECTIVE_PLATFORMS -iphoneos;-iphonesimulator) If not, try both of those and let me know if it's still wrong. The effective platform stuff is new in 2.8.6, and there are probably still some rough edges for complex projects... HTH, David -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] VS2010 Express generator?
You just need to install a PlatformSDK to go with VS 2010 Express. Search the mailing list for prior discussions of this fact. On Fri, Nov 11, 2011 at 11:36 AM, David Doria daviddo...@gmail.com wrote: 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 answer first. Thanks, David -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] VS2010 Express generator?
On 11 November 2011 16:36, David Doria daviddo...@gmail.com wrote: 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 answer first. Are you sure these errors are related to CMake issues? Your report would be clearer if you added the actual errors. VS2010 EE support should be sound in 2.8.6 It has been in upstream way before 2.8.6 release. http://www.cmake.org/pipermail/cmake/2010-May/036900.html Best regards, -- Mateusz Loskot, http://mateusz.loskot.net -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] VS2010 Express generator?
Am Freitag, 11. November 2011, 17:41:34 schrieb David Cole: You just need to install a PlatformSDK to go with VS 2010 Express. Search the mailing list for prior discussions of this fact. Last time I tried, VS10Express included the PlatformSDK. HS -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Adding a new language
Am Freitag, 11. November 2011, 15:55:12 schrieb Stefan Monnier: According to http://caml.inria.fr/pub/docs/manual-ocaml/manual022.html, it does: -o exec-file Specify the name of the output file produced by the compiler. The default output name is a.out under Unix and camlprog.exe under Windows. If This manpage describes all kinds of uses and in practice the -o only applies to the case whre you use ocamlc to link your program (notice how it says -o exec file rather than -o output-file), but it seems ignored when using it to just compile one file. I guess part of the reason is that in that case there is more than one output (it generates a .cmo and a .cmi file for each input file), so it wouldn't be clear what to do with this single output file name. You did cut the part where it says: If the -c option is given, specify the name of the object file produced for the next source file that appears on the command line. So if the help says that -o is supposed to do something sensible when used with -c but it doesn't, I'd suggest to file a bug. Note that the order of arguments may be important. HS -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
[CMake] QtCreator generator?
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 -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] QtCreator generator?
On Fri, Nov 11, 2011 at 1:08 PM, David Doria daviddo...@gmail.com wrote: 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 -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake I think it's true that QtCreator knows how to connect to a CMake build tree generated with the CodeBlocks - Unix Makefiles generator. Somebody out there, please correct me if I'm wrong. I don't use QtCreator myself, but I think that's the way to do it. I've heard rumor you can simply open the top level CMakeLists.txt file in QtCreator, too, and it knows how to find all the source based on that. Don't know if it will generate a build tree for you if there's not one to start with... HTH, David C. -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] QtCreator generator?
On Friday 11 November 2011, David Cole wrote: On Fri, Nov 11, 2011 at 1:08 PM, David Doria daviddo...@gmail.com wrote: 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). I think that's true for all project files generated by cmake. You set up most things in the CMakeLists.txt, and then use what cmake generates as project files. Thanks, David -- I think it's true that QtCreator knows how to connect to a CMake build tree generated with the CodeBlocks - Unix Makefiles generator. Somebody out there, please correct me if I'm wrong. I don't use QtCreator myself, but I think that's the way to do it. I've heard rumor you can simply open the top level CMakeLists.txt file in QtCreator, too, and it knows how to find all the source based on that. When opening a project from a CMakeLists.txt in CodeBlocks, it runs cmake on the CMakeLists.txt with the CodeBlocks generator, and loads the resulting codeblocks project file. The one which parses the cmake files itself and reimplements most cmake commands is KDevelop4. Alex -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
[CMake] CMake + Cygwin + MSVC Toolchain problems
I have been generating for Visual Studio, but I decided to try setting up my Cygwin environment to point to the MSVC tool chain. So far it's worked wonderfully, but one of my targets is failing and I don't understand Makefiles very well so I have no idea what the problem is. Note that I'm doing an out of source build. Here is the error I get: common/exchange/gdexchsrvcommon/CMakeFiles/gdwincommon.dir/depend.make:25: *** target pattern contains no `%'. Stop. make[1]: *** [common/exchange/gdexchsrvcommon/CMakeFiles/gdwincommon.dir/all] Error 2 make: *** [all] Error 2 Is this enough information or do you need some more info? About 20 dependent targets prior to this one compiled just fine. - Robert Dailey -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] CMake + Cygwin + MSVC Toolchain problems
At line 25 in the depend.make file in question, I have this: common/exchange/gdexchsrvcommon/CMakeFiles/gdwincommon.dir/gdcomhelpers.cpp.obj: C:/Program\ Files/Microsoft\ SDKs/Windows/v6.0A/Include/SCardErr.h - Robert Dailey On Fri, Nov 11, 2011 at 1:17 PM, Robert Dailey rcdai...@gmail.com wrote: I have been generating for Visual Studio, but I decided to try setting up my Cygwin environment to point to the MSVC tool chain. So far it's worked wonderfully, but one of my targets is failing and I don't understand Makefiles very well so I have no idea what the problem is. Note that I'm doing an out of source build. Here is the error I get: common/exchange/gdexchsrvcommon/CMakeFiles/gdwincommon.dir/depend.make:25: *** target pattern contains no `%'. Stop. make[1]: *** [common/exchange/gdexchsrvcommon/CMakeFiles/gdwincommon.dir/all] Error 2 make: *** [all] Error 2 Is this enough information or do you need some more info? About 20 dependent targets prior to this one compiled just fine. - Robert Dailey -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] CMake + Cygwin + MSVC Toolchain problems
Based on this URL: http://cygwin.com/ml/cygwin/2006-07/msg00376.html Seems like this happens because I am using windows-style paths in Cygwin. I don't know how to make it use different paths though. - Robert Dailey On Fri, Nov 11, 2011 at 1:19 PM, Robert Dailey rcdai...@gmail.com wrote: At line 25 in the depend.make file in question, I have this: common/exchange/gdexchsrvcommon/CMakeFiles/gdwincommon.dir/gdcomhelpers.cpp.obj: C:/Program\ Files/Microsoft\ SDKs/Windows/v6.0A/Include/SCardErr.h - Robert Dailey On Fri, Nov 11, 2011 at 1:17 PM, Robert Dailey rcdai...@gmail.com wrote: I have been generating for Visual Studio, but I decided to try setting up my Cygwin environment to point to the MSVC tool chain. So far it's worked wonderfully, but one of my targets is failing and I don't understand Makefiles very well so I have no idea what the problem is. Note that I'm doing an out of source build. Here is the error I get: common/exchange/gdexchsrvcommon/CMakeFiles/gdwincommon.dir/depend.make:25: *** target pattern contains no `%'. Stop. make[1]: *** [common/exchange/gdexchsrvcommon/CMakeFiles/gdwincommon.dir/all] Error 2 make: *** [all] Error 2 Is this enough information or do you need some more info? About 20 dependent targets prior to this one compiled just fine. - Robert Dailey -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Generating for cygwin
Do you have a sample bash script I could look at? I'm not sure what environment variables need to be setup in my Cygwin environment. Thanks! - Robert Dailey On Thu, Nov 10, 2011 at 10:05 PM, Bill Hoffman bill.hoff...@kitware.comwrote: On 11/10/2011 5:14 PM, Robert Dailey wrote: I think my incorrect subject is symbolic of the fact that I don't know what I'm looking for ;) So you're basically saying that from cmake-gui on Windows, point C and CXX to cl.exe? I did this but got a big fat error message: I also said in my previous email that the environment had to be setup correctly. You have to run cmake-gui in an environment where cl is in the path and all of the other environment variables that VS requires to run from the command line are set. In addition cygwin needs to be in the PATH with the correct make.exe. The way to do that is to: 1. create the bash script that exports all the env you need for cl to run. 2. source that script. 3. run cmake-gui from that shell. The other option is to put all of those variables into the windows OS environment, but I don't recommend that. -Bill -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] QtCreator generator?
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? David -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] QtCreator generator?
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 this generator, but I get errors like cmake_c_compiler_env_var is undefined. Shouldn't it find the compiler for the VS2010Express installation? Please post the full output from cmake, this makes helping much easier. Thanks Alex -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] QtCreator generator?
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 this generator, but I get errors like cmake_c_compiler_env_var is undefined. Shouldn't it find the compiler for the VS2010Express installation? Please post the full output from cmake, this makes helping much easier. Sure thing - here you go: CMake Error: CMake was unable to find a build program corresponding to Unix Makefiles. CMAKE_MAKE_PROGRAM is not set. You probably need to select a different build tool. CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly. Missing variable is: CMAKE_C_COMPILER_ENV_VAR CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly. Missing variable is: CMAKE_C_COMPILER CMake Error: Could not find cmake module file:C:/Test/TestITK/build/CMakeFiles/CMakeCCompiler.cmake CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly. Missing variable is: CMAKE_CXX_COMPILER_ENV_VAR CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly. Missing variable is: CMAKE_CXX_COMPILER CMake Error: Could not find cmake module file:C:/Test/TestITK/build/CMakeFiles/CMakeCXXCompiler.cmake CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage Configuring incomplete, errors occurred! Thanks, David -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] QtCreator generator?
On Friday 11 November 2011, David Doria wrote: 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 this generator, but I get errors like cmake_c_compiler_env_var is undefined. Shouldn't it find the compiler for the VS2010Express installation? Please post the full output from cmake, this makes helping much easier. Sure thing - here you go: Ok. one more: how exactly did you run cmake ? From the command line or cmake-gui ? Which generator did you choose ? It should be the CodeBlocks - NMake Makefiles one. This then needs to be run from a terminal which has the VisualStudio environment variables set. Then cmake should know what to look for (nmake) and halso find it. Or is this different with VS2010Express ? (I have never used this) Alex -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
[CMake] How to build ccmake.exe on Windows?
I'm using Cygwin with the MSVC toolchain and I need ccmake.exe. I can't use the one from the Cygwin package manager because it's older than the version I'm using. I'd like to build it myself through Visual Studio like I did with cmake and cmake-gui if possible. Any help? - Robert Dailey -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] How to build ccmake.exe on Windows?
According to the root CMakeLists.txt in cmake, there is no way to do this on Windows. I'll probably have to build it through Cygwin itself, assuming UNIX is truthy when using Cygwin. # Use curses? IF (UNIX) # there is a bug in the Syllable libraries which makes linking ccmake fail, Alex IF(NOT ${CMAKE_SYSTEM_NAME} MATCHES syllable) SET(CURSES_NEED_NCURSES TRUE) FIND_PACKAGE(Curses QUIET) IF (CURSES_LIBRARY) OPTION(BUILD_CursesDialog Build the CMake Curses Dialog ccmake ON) ELSE (CURSES_LIBRARY) MESSAGE(Curses libraries were not found. Curses GUI for CMake will not be built.) SET(BUILD_CursesDialog 0) ENDIF (CURSES_LIBRARY) ELSE(NOT ${CMAKE_SYSTEM_NAME} MATCHES syllable) SET(BUILD_CursesDialog 0) ENDIF(NOT ${CMAKE_SYSTEM_NAME} MATCHES syllable) ELSE (UNIX) SET(BUILD_CursesDialog 0) ENDIF (UNIX) - Robert Dailey On Fri, Nov 11, 2011 at 2:21 PM, Robert Dailey rcdai...@gmail.com wrote: I'm using Cygwin with the MSVC toolchain and I need ccmake.exe. I can't use the one from the Cygwin package manager because it's older than the version I'm using. I'd like to build it myself through Visual Studio like I did with cmake and cmake-gui if possible. Any help? - Robert Dailey -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] How to build ccmake.exe on Windows?
On Fri, Nov 11, 2011 at 3:24 PM, Robert Dailey rcdai...@gmail.com wrote: According to the root CMakeLists.txt in cmake, there is no way to do this on Windows. I'll probably have to build it through Cygwin itself, assuming UNIX is truthy when using Cygwin. # Use curses? IF (UNIX) # there is a bug in the Syllable libraries which makes linking ccmake fail, Alex IF(NOT ${CMAKE_SYSTEM_NAME} MATCHES syllable) SET(CURSES_NEED_NCURSES TRUE) FIND_PACKAGE(Curses QUIET) IF (CURSES_LIBRARY) OPTION(BUILD_CursesDialog Build the CMake Curses Dialog ccmake ON) ELSE (CURSES_LIBRARY) MESSAGE(Curses libraries were not found. Curses GUI for CMake will not be built.) SET(BUILD_CursesDialog 0) ENDIF (CURSES_LIBRARY) ELSE(NOT ${CMAKE_SYSTEM_NAME} MATCHES syllable) SET(BUILD_CursesDialog 0) ENDIF(NOT ${CMAKE_SYSTEM_NAME} MATCHES syllable) ELSE (UNIX) SET(BUILD_CursesDialog 0) ENDIF (UNIX) - Robert Dailey On Fri, Nov 11, 2011 at 2:21 PM, Robert Dailey rcdai...@gmail.com wrote: I'm using Cygwin with the MSVC toolchain and I need ccmake.exe. I can't use the one from the Cygwin package manager because it's older than the version I'm using. I'd like to build it myself through Visual Studio like I did with cmake and cmake-gui if possible. Any help? BTW, there is a cmake in cygwin setup. I believe it is recommended to use that instead of the windows cmake.exe John -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] QtCreator generator?
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 get a message box that says: mspdb100.dll is missing. This then needs to be run from a terminal which has the VisualStudio environment variables set. Since I am running the GUI, I'd have to set the global Windows environment variables, right? Which variables do I need to set? Thanks for your help so far - we'll get to the bottom of this. I'll post a tutorial on the wiki once we get it working. I'd imagine this is a pretty common setup. David -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] cdt generator and subclipse?
On Fri, Nov 11, 2011 at 3:58 PM, Alexander Neundorf a.neundorf-w...@gmx.net wrote: What did you do ? Can you please explain exactly ? I'd really like to know. I can't explain my previous problem - must have been stupid user error, like being in wrong directory. - Dan -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] How to build ccmake.exe on Windows?
UNIX is ON for cygwin based builds. (However, WIN32 is not ON any longer. It used to be, but the cygwin guys didn't want it that way, so now WIN32 is OFF.) Assuming you are in a directory named CMake which is the CMake source tree, you can do the following to produce a cygwin based CMake (in a raw cygwin env with no Visual Studio stuff in it): mkdir ../CMake-build cd ../CMake-build ../CMake/bootstrap make Then you can use that cmake or ccmake in the cygwin environment. HTH, David On Fri, Nov 11, 2011 at 3:28 PM, John Drescher dresche...@gmail.com wrote: On Fri, Nov 11, 2011 at 3:24 PM, Robert Dailey rcdai...@gmail.com wrote: According to the root CMakeLists.txt in cmake, there is no way to do this on Windows. I'll probably have to build it through Cygwin itself, assuming UNIX is truthy when using Cygwin. # Use curses? IF (UNIX) # there is a bug in the Syllable libraries which makes linking ccmake fail, Alex IF(NOT ${CMAKE_SYSTEM_NAME} MATCHES syllable) SET(CURSES_NEED_NCURSES TRUE) FIND_PACKAGE(Curses QUIET) IF (CURSES_LIBRARY) OPTION(BUILD_CursesDialog Build the CMake Curses Dialog ccmake ON) ELSE (CURSES_LIBRARY) MESSAGE(Curses libraries were not found. Curses GUI for CMake will not be built.) SET(BUILD_CursesDialog 0) ENDIF (CURSES_LIBRARY) ELSE(NOT ${CMAKE_SYSTEM_NAME} MATCHES syllable) SET(BUILD_CursesDialog 0) ENDIF(NOT ${CMAKE_SYSTEM_NAME} MATCHES syllable) ELSE (UNIX) SET(BUILD_CursesDialog 0) ENDIF (UNIX) - Robert Dailey On Fri, Nov 11, 2011 at 2:21 PM, Robert Dailey rcdai...@gmail.com wrote: I'm using Cygwin with the MSVC toolchain and I need ccmake.exe. I can't use the one from the Cygwin package manager because it's older than the version I'm using. I'd like to build it myself through Visual Studio like I did with cmake and cmake-gui if possible. Any help? BTW, there is a cmake in cygwin setup. I believe it is recommended to use that instead of the windows cmake.exe John -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] CMake + Cygwin + MSVC Toolchain problems
On 11/11/2011 2:25 PM, Robert Dailey wrote: Based on this URL: http://cygwin.com/ml/cygwin/2006-07/msg00376.html Seems like this happens because I am using windows-style paths in Cygwin. I don't know how to make it use different paths though. It is because the cygwin make is broken. Did you try the one that I sent the link for on www.cmake.org/files? -Bill -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] cdt generator and subclipse?
On Friday 11 November 2011, Dan Kegel wrote: On Fri, Nov 11, 2011 at 3:58 PM, Alexander Neundorf a.neundorf-w...@gmx.net wrote: What did you do ? Can you please explain exactly ? I'd really like to know. I can't explain my previous problem - must have been stupid user error, like being in wrong directory. - Dan So you imported the source project (and the build project), and now svn works for the source project ? Or does it also work in the build project, e.g. in the [Source directory] linked resource ? Alex -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] QtCreator generator?
On Friday 11 November 2011, David Doria wrote: 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 get a message box that says: mspdb100.dll is missing. This then needs to be run from a terminal which has the VisualStudio environment variables set. Since I am running the GUI, I'd have to set the global Windows environment variables, right? Which variables do I need to set? I think you have to run the GUI from a terminal where the variables are set up already. There was usually such an entry in the start menu. I don't know whether this is also the case with VSExpress. Alex -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] QtCreator generator?
On Nov 11, 2011, at 4:44 PM, Alexander Neundorf wrote: On Friday 11 November 2011, David Doria wrote: 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 get a message box that says: mspdb100.dll is missing. This then needs to be run from a terminal which has the VisualStudio environment variables set. Since I am running the GUI, I'd have to set the global Windows environment variables, right? Which variables do I need to set? I think you have to run the GUI from a terminal where the variables are set up already. There was usually such an entry in the start menu. I don't know whether this is also the case with VSExpress. Alex -- 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 from there and then CMake will know what compilers I want. Note that there are actually 2 different Visual Studio command prompts: one for 32 bit compiles (Win32) and one for the 64 bit compiles (Win64) Mike Jackson -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] cdt generator and subclipse?
On Fri, Nov 11, 2011 at 9:42 PM, Alexander Neundorf a.neundorf-w...@gmx.net wrote: So you imported the source project (and the build project), and now svn works for the source project ? Right (I think). The symptom was that the source project would not import. Now it does, reliably. Or does it also work in the build project, e.g. in the [Source directory] linked resource ? Nope, wasn't using the linked resource. I'm running into a new problem related to multiple source projects, though; I'll post about that soon. - Dan -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] QtCreator generator?
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 from there and then CMake will know what compilers I want. Note that there are actually 2 different Visual Studio command prompts: one for 32 bit compiles (Win32) and one for the 64 bit compiles (Win64) Mike Jackson Great - that worked! It successfully generated a Code Blocks -NMake Makefile project when I ran cmake-gui from the VS2010E terminal. However, now when I open VS2010E and go to open - project, there is no .vcproj file. How do I open this project in VS2010E? Thanks, David -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
[CMake] Workflow of a collaborative project in Visual Studio+CMake
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 working with Visual Studio, do I have to 'git pull', then go open cmake-gui from the VS2010E terminal, re-configure and re-generate the project, then reimport the VS2010E project, then build? This seems horribly awkward. And the reverse appears to have the same problem - if working inside VS I add a file to the VS project, how do I 'export' this addition back to the git repo? Thanks, David -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] QtCreator generator?
There should have been a *.sln file that you open.? ___ Mike JacksonPrincipal Software Engineer BlueQuartz SoftwareDayton, Ohio mike.jack...@bluequartz.net www.bluequartz.net On Nov 11, 2011, at 5:23 PM, David Doria wrote: 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 from there and then CMake will know what compilers I want. Note that there are actually 2 different Visual Studio command prompts: one for 32 bit compiles (Win32) and one for the 64 bit compiles (Win64) Mike Jackson Great - that worked! It successfully generated a Code Blocks -NMake Makefile project when I ran cmake-gui from the VS2010E terminal. However, now when I open VS2010E and go to open - project, there is no .vcproj file. How do I open this project in VS2010E? Thanks, David -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Workflow of a collaborative project in Visual Studio+CMake
It is worse and better. 1: CMake will generate the VS projects and solutions every time it needs to run. DO NOT EDIT the generated VS projects and solutions. Add the requirements to the CMake files. 2: If you are on VS2007/VS2008 and you do a git pull and then switch to VS and click build a cmake check is run FIRST. If anything is different the new solution and project files are generated and then the build continues. You will get a dialog asking if you want to reload all of the projects. Things are pretty nice. 3: If you are on VS2010 there is now a long standing bug that seems to have no solution where you basically have to do the following: Close the VS solution git pull run cmake to regenerate the solution and projects Open the Solution and Compile. Yep. Sucks. Purchased VS2010 last year and have yet to use it because of that bug. If we (the cmake community**) were to actually figure out how to solve the problem then VS2010 would be as seamless as VS2008. Here is hoping for the future. ** I have kept track of the bug. Kitware and others have put a lot of time into trying to fix the bug. It just seams to be one of those elusive fixes that there just may not be a solution to. -- Mike Jackson www.bluequartz.net On Nov 11, 2011, at 5:30 PM, David Doria wrote: 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 working with Visual Studio, do I have to 'git pull', then go open cmake-gui from the VS2010E terminal, re-configure and re-generate the project, then reimport the VS2010E project, then build? This seems horribly awkward. And the reverse appears to have the same problem - if working inside VS I add a file to the VS project, how do I 'export' this addition back to the git repo? Thanks, David -- -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] QtCreator generator?
There should have been a *.sln file that you open.? Not for a Code Blocks -NMake Makefile project. John -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
[CMake] Multiple source directory scenario and cdt generator
In http://www.cmake.org/pipermail/cmake/2011-November/047250.html I wrote I can't reorganize the source tree on the developers, so I'm making do by putting the enclosing CMakeLists.txt next to all the projects: toplevel/trunk/CMakeLists.txt which is checked out to toplevel/CMakeLists.txt It does add_subdirectory(../libfoo libfoo) add_subdirectory(../libbar libbar) add_subdirectory(../baz baz) This has the possible advantage that one can have multiple top levels (say, one for server code, and one for client). I don't know how many shops suffer from this svn layout, but I'll probably add an example covering it anyway for completeness once I'm sure it doesn't explode in practice. Right, well, I found out where it explodes in practice. Here's an example: http://code.google.com/p/winezeug/source/browse/trunk/cmake_examples/ex7/ The problem comes when using the cdt generator. We can't use -DECLIPSE_CDT4_GENERATE_SOURCE_PROJECT=TRUE since there are more than one source project, but the source project that generates is really trivial, so I generate one for each source directory myself with a bit of shell: for dir in demo libsrc do sed s/PROJNAME/_$dir/ ../skeleton.project ../$dir/.project done before or after running cmake. It all works great, the source projects all show up, the project builds... BUT when you edit a source file and tell eclipse to rebuild, it just sits there. It doesn't know that the source projects are related to the build project. It looks like adding a link does the trick: --- .project.old2011-11-11 22:51:56.797674441 + +++ .project2011-11-11 22:52:25.380913484 + @@ -113,5 +113,11 @@ type2/type location/home/dank/winezeug/cmake_examples/ex7/demo/location /link + link + name[Source directory 2]/name + type2/type + location/home/dank/winezeug/cmake_examples/ex7/libsrc/location + /link + /linkedResources /projectDescription After I add those lines to the .project, saved changes in libsrc do seem to cause a rebuild the next time you click build project. So, I guess to support this style of project, the cdt generator should call cmExtraEclipseCDT4Generator::AppendLinkedResource() once for each call in my outer CMakeLists.txt like add_subdirectory(../libsrc libsrc). I have no idea how to make that happen inside the cdt generator. I could kludge it in the shell script that runs cmake, but then it would break whenever the project was updated and cmake rebuilt the project automatically. Was http://public.kitware.com/Bug/view.php?id=9978 / https://github.com/rpavlik/CMake/commit/10aece0d8199409fbb695478eab2c60545fcf310 related at all? - Dan -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] QtCreator generator?
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 - 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 QtCreator? *To use Visual Studio 2010 Express* If the VS PlatformSDK that David Cole mentioned is installed properly, does a Visual Studio 2010 Express generator appear in the list of generators? If not, which one am I supposed to use? Thanks, David -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] QtCreator generator?
Am Samstag, 12. November 2011, 00:05:20 schrieb 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 - 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 QtCreator? Open the CMakeLists.txt and adjust the build dir to the one you created. Christian -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] QtCreator generator?
*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 QtCreator? Open the CMakeLists.txt and adjust the build dir to the one you created. Christian, I don't follow - the build dir should be specified in the cmake-gui, not in the CMakeLists.txt file, right? I thought by creating a project for QtCreator, we could then delete the CMakeLists.txt altogether and the project would still work? David -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Multiple source directory scenario and cdt generator
On Fri, Nov 11, 2011 at 11:01 PM, Dan Kegel d...@kegel.com wrote: I have no idea how to make that happen inside the cdt generator. I could kludge it in the shell script that runs cmake, but then it would break whenever the project was updated and cmake rebuilt the project automatically. OK, the following shell script is a kludgy prototype of what I think I need, it seems to work for me. Set top to the parent directory of all the peers, src to the directory containing the master CMakeLists.txt, and run this after running cmake. (Presumably inside cdt there's some more artful way of detecting CMakeLists.txt instances that are outside the normal tree, and which need this special treatment.) # Generate null projects for each source directory by hand # rather than asking the cdt generator to do it, since # it can't handle more than one projnames=`grep '^[^#]*add_subdirectory(\.\.' $SRC/CMakeLists.txt | sed 's,.*/,,;s, .*,,' | sort -u` for dir in $projnames do sed s/PROJNAME/_$dir/ $SRC/skeleton.project ../$dir/.project done # And now link those directories to the binary project # so changes in them cause Eclipse to know the binary project # needs rebuilding. # FIXME: this needs to be inside the cdt generator, else # the links will be lost when cmake regenerates itself on # CMakeLists.txt changes sed '/\/linkedResources/,$d' .project .newproject for dir in $projnames do cat .newproject _EOF_ link name[_$dir]/name type2/type location$top/$dir/location /link _EOF_ done sed '1,/\/link/d' .project .newproject mv .project .oldproject mv .newproject .project -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
[CMake] cmake 2.8.6 On Linux , link error and added headers to ..._EXTERNAL_OBJECTS for executables
I'm getting a Link error on Linux when I use CMake 2.8.6 or 2.8.5. If use CMake 2.6.3, with the exact same configuration, the link works. I did a diff on the build.make from 2.8.6 and 2.6.3 and found when I use cmake 2.8.6 On Linux adding headers to ..._EXTERNAL_OBJECTS for executables under the build.make. The following is the link error I get, it looks for a header but, the link.txt does need it and the diff on build.make that looks like is causing this. Link Error Message nux_x86_64/lib/libeemdump.so /hped/builds/tools/google-breakpad/784/lib.linux_x86_64/release/libbreakpad.a /hped/builds/tools/google-breakpad/78 4/lib.linux_x86_64/release/libbreakpad_client.a /hped/builds/tools/google-breakpad/784/lib.linux_x86_64/release/libbreakpad_server.a /gfs/sr/blu efin/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease/linux_x86_64/lib/libplugin_manager.so /hped/builds/tools/qt/4.7.4/linux_x86_6 4/lib/libQtCore.so /hped/builds/tools/cryptopp/5.6.0_0/linux_x86_64/release/libcryptopp.a /hped/builds/tools/boost/boost_1_45_0/lib.linux_x86_64 /release/libboost_date_time.a /hped/builds/tools/boost/boost_1_45_0/lib.linux_x86_64/release/libboost_filesystem.a /hped/builds/tools/boost/boos t_1_45_0/lib.linux_x86_64/release/libboost_program_options.a /hped/builds/tools/boost/boost_1_45_0/lib.linux_x86_64/release/libboost_system.a /h ped/builds/tools/boost/boost_1_45_0/lib.linux_x86_64/release/libboost_thread.a /hped/builds/tools/stl/5.2.1/lib.linux_x86_64/libstlport_gcc.so - Wl,-rpath,/hped/builds/tools/qt/4.7.4/linux_x86_64/lib:/hped/builds/tools/stl/5.2.1/lib.linux_x86_64:/gfs/sr/bluefin/d1/build/hped/builds/sr/dev XXX/rcupgrd_int/build/64bitrelease/linux_x86_64/lib:/release: msgs_eesofpvm_multitool.h:4:19: fatal error: Diag.h: No such file or directory compilation terminated. make[3]: *** [/gfs/sr/bluefin/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease/linux_x86_64/bin/eesofpvm_multitool] Error 1 make[3]: Leaving directory `/hfs/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease' make[2]: *** [projects/simsys/source/eesofpvm_multitool/CMakeFiles/eesofpvm_multitool.dir/all] Error 2 Diff with the build.make file, notice the file msgs_eesofpvm_multitool.h eesofpvm_multitool_EXTERNAL_OBJECTS = --- eesofpvm_multitool_EXTERNAL_OBJECTS = \ /hfs/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease/projects/simsys/source/eesofpvm_multitool/msgs_eesofpvm_multitool.h 498d482 /gfs/sr/bluefin/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease/linux_x86_64/bin/eesofpvm_multitool: /hped/builds/tools/qt/4.7.4 /linux_x86_64/lib/libQtCLucene.so 500,502d483 /gfs/sr/bluefin/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease/linux_x86_64/bin/eesofpvm_multitool: /usr/X11R6/lib64/libXext.so /gfs/sr/bluefin/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease/linux_x86_64/bin/eesofpvm_multitool: /usr/X11R6/lib64/libX11.so /gfs/sr/bluefin/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease/linux_x86_64/bin/eesofpvm_multitool: /usr/lib64/libm.so 519a501 /gfs/sr/bluefin/d1/build/hped/builds/sr/devXXX/rcupgrd_int/build/64bitrelease/linux_x86_64/bin/eesofpvm_multitool: projects/simsys/source/eeso fpvm_multitool/msgs_eesofpvm_multitool.h ++David-Bjornbak; -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] QtCreator generator?
But said he was trying to own it in visual studio express. Mike J On Friday, November 11, 2011, 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 -- _ Mike Jackson mike.jack...@bluequartz.net BlueQuartz Softwarewww.bluequartz.net Principal Software Engineer Dayton, Ohio -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
[CMake] CMAKE_RUNTIME_OUTPUT_DIRECTORY best practice for Windows and Visual Studio
Hi, I have a CMake-based project which builds several shared libraries and executables. There are various run-time dependencies between those shared libraries and executables. On Windows, I use Visual Studio for development, so I have CMake-generated .sln with projects. loaded into the IDE. I build. Then, I'd like to run one of executables (e.g. test.exe) which links against the DLLs also built by the project. Obviously, it is necessary to deal with the run-time search path. At the moment, I simplify things by outputting all .exe and .dll binaries to common directory, so programs can find required DLLs: set(MYPRJOUTDIR ${PROJECT_BINARY_DIR}/bin/${CMAKE_BUILD_TYPE}) set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${MYPRJOUTDIR}) This is also required to launch such executables under debugger. However, I have heard opinions it is some kind of a hack unnatural to CMake. On Linux, I do the same, but I imagine I could make use of rpath [1] as CMake provides some degree of support in this area [2]. On Windows, there is no such concept as rpath. Isolated Applications [3] seems to be the closest idea available there. Is it a good idea to have all-in-one CMAKE_RUNTIME_OUTPUT_DIRECTORY? Is there any CMake best practice for dealing with run-time search path on Windows? For example, automatically setting PATH in project - Configuration Properties - Debugging - Environment. [1] http://en.wikipedia.org/wiki/Rpath [2] http://www.vtk.org/Wiki/CMake_RPATH_handling [3] http://msdn.microsoft.com/en-us/library/aa375190%28VS.85%29.aspx -- Mateusz Loskot, http://mateusz.loskot.net -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Using CTest with a different dashboard
On 11/09/2011 06:06 PM, EXT-York, Gantry wrote: I'm looking for suggestions from someone who has used CTest to report results to a dashboard other than CDash. I'd like to be able to simply type gmake test TESTOPTS=-report then have CTest traverse all the directories and run the defined tests. Not only would I like it to run these tests, but I'd like it to run it through a wrapper script that I use to report the results to a different dashboard. I've tried this with set( TEST_WRAPPER /full/path/to/test_wrapper ) ... add_test( unit_test1 ) # syntax 1 add_test( /full/path/to/test_wrapper --report unit_test2 )# syntax 2 add_test( ${TEST_WRAPPER} ${TESTOPTS} unit_test3 )# syntax 3 There are several problems I've noticed with this: Syntax 1 works fine. It knows where the name unit_test1 is located and runs, but since it isn't run through the wrapper script, nothing is reported to our dashboard. Actually, this can't work as it misses the test's name. Moreover, you should use the more powerful ADD_TEST(NAME ... COMMAND ...) signature. Syntax 2 works does not work. All the arguments are quoted. -report fails as an option because of the quotes, and unit_test2 is treated as a string not as a name of a CMake object with a location. Use generator expressions to refer to a target as a parameter for a test: ADD_TEST(... COMMAND path/to/wrapper --report $TARGET_FILE:unit_test2) AFAIK, CMake recognizes a target only as the command's first argument. Syntax 3 is just a variation of syntax 2 and also fails, but it is preferable to define the wrapper script in the highest level CMakeLists.txt file and have that value carried through to sub directories. Absolutely, and if the script is not contained in or generated by your project, use FIND_PROGRAM() to locate it and to populate the variable. So I tried this set( TEST_WRAPPER /full/path/to/test_wrapper_report ) ... add_test( ${TEST_WRAPPER_REPORT} ${CURRENT_DIR}/ unit_test4 ) # syntax 4 I modified the test wrapper to report without having to specify the -report option. In this case, everything seemed to work, but the return/exit value coming back from the wrapper script was wrong. It seems that something is going on in the CTest framework that changes this value. Instead of getting a value like -1, 0, 1, I was getting a value like 32844. I verified that unit_test4 returned the correct return status to the wrapper script and the wrapper script returned the correct return status when run outside of the CTest framework. Usually, it should be possible to specify any arguments to a test driver as arguments behind ADD_TEST()'s COMMAND clause, and there should also be no issues w.r.t. quotes. Thus, you might try anew with generator expressions and correctly set up ADD_TEST() commands, and report if it still doesn't work. Regards, Michael -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
[CMake] ifort,icc,icpc: ld: cannot find -lcilkrts
Dear experts, our problem is that cmake sets automatically linking libraries for C,C++ and with Intel compilers (Fortran,C,C++) we are getting these problems ( first observed here https://repo.ctcc.no/CDash/viewBuildError.php?buildid=5283 ) : . . . Linking Fortran executable dirac.x /people/disk2/ilias/bin/cmake_install/bin/cmake -E cmake_link_script CMakeFiles/dirac.x.dir/link.txt --verbose=1 /people/disk2/magnus/intel/composerxe-2011.2.137/bin/intel64/ifort-static -Wl,-E -w -assume byterecl -DVAR_IFORT -g -traceback -static-libgcc -static-intel -i8 -O0 CMakeFiles/dirac.x.dir/main/main.F90.o -o dirac.x -i_dynamic lib/libdirac.a lib/libxcfun.a -ldecimal -lcilkrts -lstdc++ -lirc ld: cannot find -lcilkrts make[3]: *** [dirac.x] Error 1 . Manual linking without the -lcilkrts flag works: il...@fe6.dcsc.sdu.dk:~/QCH_Work/qch_progs/dirac_git/trunk/build_ompi_ifort_icc_ilp64_static/./people/disk2/magnus/intel/composerxe-2011.2.137/bin/intel64/ifort -static -Wl,-E -w -assume byterecl -DVAR_IFORT -g -traceback -static-libgcc -static-intel -i8 -O0 CMakeFiles/dirac.x.dir/main/main.F90.o -o dirac.x -i_dynamic lib/libdirac.a lib/libxcfun.a -ldecimal -lstdc++ -lirc il...@fe6.dcsc.sdu.dk:~/QCH_Work/qch_progs/dirac_git/trunk/build_ompi_ifort_icc_ilp64_static/. The problematic cilkrts library is set automatically within CMAKE_C_IMPLICIT_LINK_LIBRARIES CMAKE_CXX_IMPLICIT_LINK_LIBRARIES variables, as found: il...@fe6.dcsc.sdu.dk:~/QCH_Work/qch_progs/dirac_git/trunk/build_ompi_ifort_icc_ilp64_static/.grep cilkrts * */* . CMakeFiles/CMakeCCompiler.cmake:SET(CMAKE_C_IMPLICIT_LINK_LIBRARIES imf;svml;m;ipgo;decimal;cilkrts;stdc++;irc;c;irc_s;dl;c) CMakeFiles/CMakeCXXCompiler.cmake:SET(CMAKE_CXX_IMPLICIT_LINK_LIBRARIES imf;svml;m;ipgo;decimal;cilkrts;stdc++;irc;c;irc_s;dl;c) . . Please how to remove cilkrts or any other parameter from CMAKE_LANG_IMPLICIT_LINK_LIBRARIES, http://www.cmake.org/cmake/help/cmake-2-8-docs.html#variable:CMAKE_LANG_IMPLICIT_LINK_LIBRARIES ? We have cmake version 2.8.4 and Intel is Intel(R) 64, Version 12.0.2.137 Build 20110112. Yours, M.Ilias -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
[Cmake-commits] CMake branch, next, updated. v2.8.6-1835-g621055b
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project CMake. The branch, next has been updated via 621055bbdacc566683ff67967c65cc1da33aed6a (commit) via f30f9a500c5e5aeb053c41307dab9987735570dd (commit) from a0cadefcf9ebd1a5ee51155de232c7c564eab617 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log - http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=621055bbdacc566683ff67967c65cc1da33aed6a commit 621055bbdacc566683ff67967c65cc1da33aed6a Merge: a0cadef f30f9a5 Author: Brad King brad.k...@kitware.com AuthorDate: Fri Nov 11 16:51:36 2011 -0500 Commit: CMake Topic Stage kwro...@kitware.com CommitDate: Fri Nov 11 16:51:36 2011 -0500 Merge topic 'FindBISON-version-regex' into next f30f9a5 FindBISON: Fix bison++ version parsing to avoid Offending entry http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=f30f9a500c5e5aeb053c41307dab9987735570dd commit f30f9a500c5e5aeb053c41307dab9987735570dd Author: Ondrej Balaz on...@blami.net AuthorDate: Fri Nov 11 19:13:55 2011 + Commit: Brad King brad.k...@kitware.com CommitDate: Fri Nov 11 16:50:23 2011 -0500 FindBISON: Fix bison++ version parsing to avoid Offending entry I've just found out that use of FindBISON.cmake shipped with CMake 2.8 on system where bison++ is default bison executable (e.g. Debian Linux) will result in corrupted CMakeCache.txt file and parse error due to Offending entry As FindBISON.cmake logic used to obtain installed bison executable version is tailored to match only the message used in GNU Bison it fails on absolutely different Bison++ version message and whole version message including \n characters is stored into BISON_VERSION which is then dumped into CMakeCache.txt, so everything after first \n character makes Offending entry. diff --git a/Modules/FindBISON.cmake b/Modules/FindBISON.cmake index e855a27..25fd51d 100644 --- a/Modules/FindBISON.cmake +++ b/Modules/FindBISON.cmake @@ -67,8 +67,17 @@ IF(BISON_EXECUTABLE) IF(NOT ${BISON_version_result} EQUAL 0) MESSAGE(SEND_ERROR Command \${BISON_EXECUTABLE} --version\ failed with output:\n${BISON_version_error}) ELSE() -STRING(REGEX REPLACE ^bison \\(GNU Bison\\) ([^\n]+)\n.* \\1 - BISON_VERSION ${BISON_version_output}) +# Bison++ +IF(${BISON_version_output} MATCHES ^bison\\+\\+) + STRING(REGEX REPLACE ^bison\\+\\+ Version ([^,]+).* \\1 +BISON_VERSION ${BISON_version_output}) +# GNU Bison +ELSEIF(${BISON_version_output} MATCHES ^bison[^+]) + STRING(REGEX REPLACE ^bison \\(GNU Bison\\) ([^\n]+)\n.* \\1 +BISON_VERSION ${BISON_version_output}) +ELSE() + SET(BISON_VERSION unknown) +ENDIF() ENDIF() # internal macro --- Summary of changes: Modules/FindBISON.cmake | 13 +++-- 1 files changed, 11 insertions(+), 2 deletions(-) hooks/post-receive -- CMake ___ Cmake-commits mailing list Cmake-commits@cmake.org http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-commits