[CMake] Installing Python Modules with CMake
Is there some standard way in CMake to get a project-local install destination for python libraries, e.g.: ${CMAKE_INSTALL_PREFIX}/lib/python2.6/site-packages Is this something find modules typically provide? I can construct this name easily enough myself, but it involves querying the python executable for its version then regexing that string, and I feel like FindPythonLibs should do stuff like that for me. It would be nice to have something called, say, CMAKE_PYTHON_INSTALL_PREFIX set to this path in advance, so that I can just install python modules there. Or am I missing something? I couldn't fund much on installing python files in the docs. -Todd ___ 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] Finding Python Modules with CMake
Is there a way in CMake, once I find the python interpreter, to query for the availability of a particular module? e.g. say I want to make sure that the host's python installation has PyQt4, or numy, or something like that. Do I have to manually run the interpreter, try to import it, and check the return code, or is there a builtin for that? Something like this would be handy for the python modules: http://www.gnu.org/software/autoconf-archive/ax_python_module.html Again, I couldn't find much in the docs for this. -Todd ___ 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] Sign a deb file builded by cpack
Thank you Eric...I'll use dpkg-sig. Please let me know when the patch will be introduced. Regards On 02/01/2011 13:06, Eric Noulard wrote: 2011/1/2 Paolo Zaffinop.zaff...@yahoo.it: Dear all, first of all my best wishes at all for an happy new year. Do anyone know if there is a way to sign a deb package builded by cpack? Thank you very much. As far as I know there is built-in support for signing deb in CPackDeb. However using dpkg-sig : http://packages.debian.org/search?keywords=dpkg-sig or debsigs: http://packages.debian.org/search?keywords=debsigs Should work. Note that I would happily review a patch which makes it easier to sign deb package with some extra CPACK_DEBIAN_PACKAGE_xxx vars. ___ 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] Sign a deb file builded by cpack
2011/1/3 Paolo Zaffino p.zaff...@yahoo.it: Thank you Eric...I'll use dpkg-sig. Please let me know when the patch will be introduced. To be more clear: Adding this feature is not currently on my CMake TODO list. My previous remark was an invitation for YOU (or anyone else) to provide a patch. Then I'll be able to review it and may be merge it for next CMake release :-] To summarize, If you wan't the feature to be introduced in some future CMake version: 1) Open a bug tracker entry for that explaining your motivation 2) Attach your patch to the tracker 2) is optional but a provided patch improves the chance to get the feature inside CMake. -- Erk Membre de l'April - « promouvoir et défendre le logiciel libre » - http://www.april.org ___ 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] problem w/ find_package_ makefile does not always compile
At Sun, 2 Jan 2011 22:15:56 +0100, ny wrote: ** Apologies for double-posting my earlier message got truncated ** greetings! I spent enough time trying to make the software work, so I'd be happy to get some feedback:: I built research code written in (templated) c++, size is approximately ~15K lines. I am on a mac and do not use Cocoa(/xcode), straight from command line. Note that I choose to generate a Unix makefile, not an xcode project and I am on snow leopard 10.6.5 w/ g++ 4.2.1. The pain was that there were no makefile coming along w/ the project, so I had to translate the *.vcproj file from scratch to CMakelists and then convert it to makefile. My directories structure (directories marked w/ DIR_ else are files, indentation denotes deeper level):: DIR_4DMPU_exampleTest 4DMPU_example.cpp DIR_ann_1.1.2 DIR_cmake CMakeLists.txt FindANN.cmake Modules FindANN.cmake DIR_include DIR_mc4d_tables num_tet_table.cpp tet_table.cpp vert_table.cpp DIR_4DMPU_exampleTestBin In the cmake GUI I add: ANN_LIBRARY /Users/nikos/Downloads/4DMPU_exampleTest/ann_1.1.2/include ANN_INCLUDE_DIR /Users/nikos/Downloads/4DMPU_exampleTest/ann_1.1.2/lib/libANN.a My CMakeLists.txt is:: cmake_minimum_required(VERSION 2.8) project( 4DMPU_example ) SET (CMAKE_BUILD_TYPE DEBUG) set(SOURCE_FILES 4DMPU_example.cpp mc4d_tables/num_tet_table.cpp mc4d_tables/tet_table.cpp mc4d_tables/vert_table.cpp ) set(INCLUDE_FILES include/4dtables.h include/ann_helper.h ... # more headers include/Volume.h ann_1.1.2/include include/VolumeIO.h ) include_directories( ${PROJECT_SOURCE_DIR}/ann_1.1.2/include ${PROJECT_SOURCE_DIR}/ann_1.1.2/lib include ) INCLUDE(FindANN.cmake) IF(ANN_FOUND) INCLUDE_DIRECTORIES( ${ANN_INCLUDE_DIR} ) ENDIF(ANN_FOUND) set(LIBS ${LIBS} ${ANN_LIBRARY}) add_executable( 4DMPU_example ${SOURCE_FILES} ) target_link_libraries( 4DMPU_example ${LIBS} ) and the content of the FindANN.cmake:: FIND_LIBRARY(ANN_LIBRARY lANN ${PROJECT_SOURCE_DIR}/ann_1.1.2/lib ) FIND_PATH( ANN_INCLUDE_DIR ANN/ANN.h ANN/ANNperf.h ANN/ANNx.h ${PROJECT_SOURCE_DIR}/ann_1.1.2/include ) IF(ANN_LIBRARY) IF(ANN_INCLUDE_DIR) SET(ANN_FOUND TRUE) ENDIF(ANN_INCLUDE_DIR) ENDIF(ANN_LIBRARY) The project compiles fine this way. Now, the problem is that if I follow the advice below http://www.cmake.org/Wiki/CMake:How_To_Find_Libraries#Using_external_libraries_in_your_project and add the line set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_SOURCE_DIR}/cmake/Modules/) and, moreover, substitute include_directories( ${PROJECT_SOURCE_DIR}/ann_1.1.2/include ${PROJECT_SOURCE_DIR}/ann_1.1.2/lib include ) with find_package(ANN REQUIRED) include_directories(${ANN_INCLUDE_DIR} include ) into CMakeLists.txt I get a linking problem. I do not reproduce the message - the point is that the ANN library is not linked w/ my object files. Can anyone tell me what I am doing wrong in the 2nd case? Note also that in the 2nd case I explicitly add:: ANN_DIR /Users/nikos/Downloads/4DMPU_exampleTest/cmake/Modules in the cmake GUI. Thanks for any pointers N Hi, the problem is that you don't have a CMakeLists for your ANN library so 2 choices: 1. write a CMakeLists for ANN and then just add_subdirectory(ANN) and use the ANN_library target name to link with. 2. assume that ANN is a part of your project which you have done so far but the wrong way. you need to do the following: i- remove find_package(ANN REQUIRED) since as far as I know from ANN it doesn't ship with a .pc or FindANN.cmake file so you can't use find find_package(ANN REQUIRED) ii- set ANN_INCLUDE_DIR and ANN_LIBS_DIR and ANN_LIBRARIES to be user assigned values which you fill with cmake .. -DANN_INCLUDE_DIR=/path/to/ANN/install etc. Now I have submitted a while ago a CMakeLists.txt to the ANN library project and they didn't include it so if you want you can have a ANN subdirectory in your prject, place the CMakeLists.txt there and do as 1. I attach the file cmake_minimum_required(VERSION 2.6) project(ANN CXX) set(major 1) set(minor 1) set(revision 2) set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${ANN_SOURCE_DIR}/lib) set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${ANN_SOURCE_DIR}/bin) # the ANN library include_directories(include) include_directories(src) file(GLOB sources src/*.cpp) add_library(ANN SHARED ${sources}) set_target_properties(ANN PROPERTIES VERSION ${major}.${minor}.${revision} SOVERSION ${major} COMPILE_FLAGS -O3) # ANN test utility
[CMake] how to submit customized test report
Hi, I have a query about submission of customized test report which I had posted as part of some other post to the mailing list. For convenience I am posting only this specific query again. ctest_submit() line in my script.cmake was as follows : ctest_submit(FILES path_to_my_customizedTestReport.xml) Even if this says Submission successful I can not see customized report on CDASH. As above ctest_submit() did not work, I tried to put : SET(CTEST_EXTRA_SUBMIT_FILES path_to_my_customizedTestReport.xml) ctest_submit(PARTS ExtraFiles) This also says Submission successful but I could not find how to see any extra file on CDASH. Can you please let me know how : 1. to submit customized test report and 2. how to see extra submitted files on CDASH? Regards, Girish ___ 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] Installing Python Modules with CMake
On 01/03/2011 09:11 AM, Todd Gamblin wrote: Is there some standard way in CMake to get a project-local install destination for python libraries, e.g.: ${CMAKE_INSTALL_PREFIX}/lib/python2.6/site-packages Is this something find modules typically provide? I can construct this name easily enough myself, but it involves querying the python executable for its version then regexing that string, and I feel like FindPythonLibs should do stuff like that for me. It would be nice to have something called, say, CMAKE_PYTHON_INSTALL_PREFIX set to this path in advance, so that I can just install python modules there. Or am I missing something? I couldn't fund much on installing python files in the docs. -Todd I think you'll have to query Python yourself. Of course, this becomes difficult if you're cross-compiling, in which case you would need to parse the prefix/lib/pythonX.Y/config/Makefile file yourself and fetch all the relevant variables (datarootdir, BINDIR, DESTSHARED, LIBDEST, etc.) and then ask the user what prefix and exec_prefix he wants (presumably CMAKE_INSTALL_PREFIX maps to prefix, and usually exec_prefix is the same as prefix, but that's not always the case). Not sure how that works on Windows, though... I wouldn't rely too much on FindPythonLibs. The whole FindPython* is a sorry mess (IMHO) and needs some serious overhaul, but that is some major undertaking an apparently the suffering wasn't big enough so far for somebody to take action... 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] Finding Python Modules with CMake
On 01/03/2011 09:17 AM, Todd Gamblin wrote: Is there a way in CMake, once I find the python interpreter, to query for the availability of a particular module? e.g. say I want to make sure that the host's python installation has PyQt4, or numy, or something like that. Do I have to manually run the interpreter, try to import it, and check the return code, or is there a builtin for that? Something like this would be handy for the python modules: http://www.gnu.org/software/autoconf-archive/ax_python_module.html Again, I couldn't find much in the docs for this. -Todd No, there's no such thing. You're welcome to contribute it, though ;-) If you do, make sure it also works when cross-compiling (i.e. delegate the responsibility of answering these questions to the user). 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] problem w/ find_package_ makefile does not always compile
Thank you so much! Nikos Yiotis Chat Skype: nyiotis Contact Me [image: Linkedin]http://my.wisestamp.com/link?u=ws7c27w2vnrx4d2bsite=www.linkedin.com/in/yiotis On Mon, Jan 3, 2011 at 9:57 AM, Nizar Khalifa Sallem nksal...@laas.frwrote: At Sun, 2 Jan 2011 22:15:56 +0100, ny wrote: ** Apologies for double-posting my earlier message got truncated ** greetings! I spent enough time trying to make the software work, so I'd be happy to get some feedback:: I built research code written in (templated) c++, size is approximately ~15K lines. I am on a mac and do not use Cocoa(/xcode), straight from command line. Note that I choose to generate a Unix makefile, not an xcode project and I am on snow leopard 10.6.5 w/ g++ 4.2.1. The pain was that there were no makefile coming along w/ the project, so I had to translate the *.vcproj file from scratch to CMakelists and then convert it to makefile. My directories structure (directories marked w/ DIR_ else are files, indentation denotes deeper level):: DIR_4DMPU_exampleTest 4DMPU_example.cpp DIR_ann_1.1.2 DIR_cmake CMakeLists.txt FindANN.cmake Modules FindANN.cmake DIR_include DIR_mc4d_tables num_tet_table.cpp tet_table.cpp vert_table.cpp DIR_4DMPU_exampleTestBin In the cmake GUI I add: ANN_LIBRARY /Users/nikos/Downloads/4DMPU_exampleTest/ann_1.1.2/include ANN_INCLUDE_DIR /Users/nikos/Downloads/4DMPU_exampleTest/ann_1.1.2/lib/libANN.a My CMakeLists.txt is:: cmake_minimum_required(VERSION 2.8) project( 4DMPU_example ) SET (CMAKE_BUILD_TYPE DEBUG) set(SOURCE_FILES 4DMPU_example.cpp mc4d_tables/num_tet_table.cpp mc4d_tables/tet_table.cpp mc4d_tables/vert_table.cpp ) set(INCLUDE_FILES include/4dtables.h include/ann_helper.h ... # more headers include/Volume.h ann_1.1.2/include include/VolumeIO.h ) include_directories( ${PROJECT_SOURCE_DIR}/ann_1.1.2/include ${PROJECT_SOURCE_DIR}/ann_1.1.2/lib include ) INCLUDE(FindANN.cmake) IF(ANN_FOUND) INCLUDE_DIRECTORIES( ${ANN_INCLUDE_DIR} ) ENDIF(ANN_FOUND) set(LIBS ${LIBS} ${ANN_LIBRARY}) add_executable( 4DMPU_example ${SOURCE_FILES} ) target_link_libraries( 4DMPU_example ${LIBS} ) and the content of the FindANN.cmake:: FIND_LIBRARY(ANN_LIBRARY lANN ${PROJECT_SOURCE_DIR}/ann_1.1.2/lib ) FIND_PATH( ANN_INCLUDE_DIR ANN/ANN.h ANN/ANNperf.h ANN/ANNx.h ${PROJECT_SOURCE_DIR}/ann_1.1.2/include ) IF(ANN_LIBRARY) IF(ANN_INCLUDE_DIR) SET(ANN_FOUND TRUE) ENDIF(ANN_INCLUDE_DIR) ENDIF(ANN_LIBRARY) The project compiles fine this way. Now, the problem is that if I follow the advice below http://www.cmake.org/Wiki/CMake:How_To_Find_Libraries#Using_external_libraries_in_your_project and add the line set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_SOURCE_DIR}/cmake/Modules/) and, moreover, substitute include_directories( ${PROJECT_SOURCE_DIR}/ann_1.1.2/include ${PROJECT_SOURCE_DIR}/ann_1.1.2/lib include ) with find_package(ANN REQUIRED) include_directories(${ANN_INCLUDE_DIR} include ) into CMakeLists.txt I get a linking problem. I do not reproduce the message - the point is that the ANN library is not linked w/ my object files. Can anyone tell me what I am doing wrong in the 2nd case? Note also that in the 2nd case I explicitly add:: ANN_DIR /Users/nikos/Downloads/4DMPU_exampleTest/cmake/Modules in the cmake GUI. Thanks for any pointers N Hi, the problem is that you don't have a CMakeLists for your ANN library so 2 choices: 1. write a CMakeLists for ANN and then just add_subdirectory(ANN) and use the ANN_library target name to link with. 2. assume that ANN is a part of your project which you have done so far but the wrong way. you need to do the following: i- remove find_package(ANN REQUIRED) since as far as I know from ANN it doesn't ship with a .pc or FindANN.cmake file so you can't use find find_package(ANN REQUIRED) ii- set ANN_INCLUDE_DIR and ANN_LIBS_DIR and ANN_LIBRARIES to be user assigned values which you fill with cmake .. -DANN_INCLUDE_DIR=/path/to/ANN/install etc. Now I have submitted a while ago a CMakeLists.txt to the ANN library project and they didn't include it so if you want you can have a ANN subdirectory in your prject, place the CMakeLists.txt there and do as 1. I attach the file cmake_minimum_required(VERSION 2.6) project(ANN CXX) set(major 1) set(minor 1) set(revision 2) set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${ANN_SOURCE_DIR}/lib) set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${ANN_SOURCE_DIR}/bin) # the ANN library include_directories(include) include_directories(src) file(GLOB sources src/*.cpp) add_library(ANN SHARED ${sources}) set_target_properties(ANN
Re: [CMake] how to submit customized test report
What is the contents of path_to_my_customizedTestReport.xml? CDash only parses/recognizes the formats that ctest sends it. Is your file a replacement for Test.xml? Or do you mean to send additional data beyond what is found in Test.xml? Have you looked at the examples and schema found here? http://public.kitware.com/Wiki/CDash:XML HTH, David On Mon, Jan 3, 2011 at 4:31 AM, girish hilage girish_hil...@yahoo.comwrote: Hi, I have a query about submission of customized test report which I had posted as part of some other post to the mailing list. For convenience I am posting only this specific query again. ctest_submit() line in my script.cmake was as follows : ctest_submit(FILES path_to_my_customizedTestReport.xml) Even if this says Submission successful I can not see customized report on CDASH. As above ctest_submit() did not work, I tried to put : SET(CTEST_EXTRA_SUBMIT_FILES path_to_my_customizedTestReport.xml) ctest_submit(PARTS ExtraFiles) This also says Submission successful but I could not find how to see any extra file on CDASH. Can you please let me know how : 1. to submit customized test report and 2. how to see extra submitted files on CDASH? Regards, Girish ___ 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] Chasing up: XCode 3.2.4 and CMake 2.8.2, setting GCC version to 4.0
Hi All,i'm still having problems getting theCMAKE_XCODE_ATTRIBUTE_GCC_VERSION flag to properly force the compiler version I want to use for my project.I'm using XCode 3.2.5, on a Mac 10.6.3 machine - trying to target a Max OS X Tiger 10.4u build. I get compiler errors because the gcc-4.2 compiler is being used in the compiler-test stage of CMake.I thoughtCMAKE_XCODE_ATTRIBUTE_GCC_VERSION could be used to force the compiler setting to 4.0?My top level CMakeLists.txt file has this as its first few lines - is this the correct way to use this option? PROJECT( FileWave ) cmake_minimum_required(VERSION 2.6) set(CMAKE_XCODE_ATTRIBUTE_GCC_VERSION "4.0")The error I get after running an XCode based generator is:-- The C compiler identification is GNU-- The CXX compiler identification is GNU-- Checking whether C compiler has -isysroot-- Checking whether C compiler has -isysroot - yes-- Checking whether C compiler supports OSX deployment target flag-- Checking whether C compiler supports OSX deployment target flag - yes-- Check for working C compiler using: Xcode-- Check for working C compiler using: Xcode -- brokenCMake Error at /Users/john/CMake/Modules/CMakeTestCCompiler.cmake:52 (MESSAGE):The C compiler "/usr/bin/gcc-4.0" is not able to compile a simple testprogram.It fails with the following output: Change Dir: /Users/john/src/TRUNK/BuildSystem/Xcode/CMakeFiles/CMakeTmpRun Build Command:/Users/john/CMake/bin/cmakexbuild -projectCMAKE_TRY_COMPILE.xcodeproj build -target cmTryCompileExec -configurationDebug=== BUILD NATIVE TARGET cmTryCompileExec OF PROJECT CMAKE_TRY_COMPILE WITHCONFIGURATION Debug ===Check dependenciesGCC 4.2 is not compatible with the Mac OS X 10.4 SDK (file testCCompiler.c)GCC 4.2 is not compatible with the Mac OS X 10.4 SDK (file testCCompiler.c)** BUILD FAILED ** John Clayton---FileWave (Europe) GmbHSt. Gallerstrasse 1CH - 9500 WilPhone: +41 71 914 30 80Fax: +41 71 914 30 81Web:www.filewave.comSkype: johncclayton ___ 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 submit customized test report
Hi, Got the problem. I was trying to submit an old Test.xml file generated from some previous run of ctest and was using it after adding few xml tags in it. It was in the same format required by cdash. But, as the file was old it had old value for 'BuildStamp', and hence it was submitting it to the old date which I was not browsing in CDASH. So, I am now able to submit my own file to CDASH. But, the requirement is that I need to add few more tests in the testlist in Test.xml and then submit it. So, now I have to edit Test.xml generated by 'ctest' under directory : /home/girish/project/trunk/Testing/20110103-1027/ What I would like to know is, if there is any 'CTEST_' variable which would give me path of the Test.xml file that is generated by 'ctest'? Or is there any variable which will give me 'Experimental tag' which is shown in the output (Use Experimental tag: 20110103-1027) if we give -VV option to ctest, so that I can construct path to Test.xml? Or can we ask 'ctest' to generate Test.xml at some pre-specified path? Regards, Girish --- On Mon, 1/3/11, David Cole david.c...@kitware.com wrote: From: David Cole david.c...@kitware.com Subject: Re: [CMake] how to submit customized test report To: girish hilage girish_hil...@yahoo.com Cc: cmake@cmake.org Date: Monday, January 3, 2011, 12:10 PM What is the contents of path_to_my_customizedTestReport.xml? CDash only parses/recognizes the formats that ctest sends it. Is your file a replacement for Test.xml? Or do you mean to send additional data beyond what is found in Test.xml? Have you looked at the examples and schema found here? http://public.kitware.com/Wiki/CDash:XML HTH, David On Mon, Jan 3, 2011 at 4:31 AM, girish hilage girish_hil...@yahoo.com wrote: Hi, I have a query about submission of customized test report which I had posted as part of some other post to the mailing list. For convenience I am posting only this specific query again. ctest_submit() line in my script.cmake was as follows : ctest_submit(FILES path_to_my_customizedTestReport.xml) Even if this says Submission successful I can not see customized report on CDASH. As above ctest_submit() did not work, I tried to put : SET(CTEST_EXTRA_SUBMIT_FILES path_to_my_customizedTestReport.xml) ctest_submit(PARTS ExtraFiles) This also says Submission successful but I could not find how to see any extra file on CDASH. Can you please let me know how : 1. to submit customized test report and 2. how to see extra submitted files on CDASH? Regards, Girish ___ 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] Finding Python Modules with CMake
On Jan 3, 2011, at 2:17 AM, Todd Gamblin wrote: Is there a way in CMake, once I find the python interpreter, to query for the availability of a particular module? e.g. say I want to make sure that the host's python installation has PyQt4, or numy, or something like that. Do I have to manually run the interpreter, try to import it, and check the return code, or is there a builtin for that? Something like this would be handy for the python modules: http://www.gnu.org/software/autoconf-archive/ax_python_module.html Again, I couldn't find much in the docs for this. Yes. I wrote this function (which relies on PYTHON_EXEC pointing to the python executable): function(find_python_module module) string(TOUPPER ${module} module_upper) if(NOT PY_${module_upper}) if(ARGC GREATER 1 AND ARGV1 STREQUAL REQUIRED) set(${module}_FIND_REQUIRED TRUE) endif() # A module's location is usually a directory, but for binary modules # it's a .so file. execute_process(COMMAND ${PYTHON_EXEC} -c import re, ${module}; print re.compile('/__init__.py.*').sub('',${module}.__file__) RESULT_VARIABLE _${module}_status OUTPUT_VARIABLE _${module}_location ERROR_QUIET OUTPUT_STRIP_TRAILING_WHITESPACE) if(NOT _${module}_status) set(PY_${module_upper} ${_${module}_location} CACHE STRING Location of Python module ${module}) endif(NOT _${module}_status) endif(NOT PY_${module_upper}) find_package_handle_standard_args(PY_${module} DEFAULT_MSG PY_${module_upper}) endfunction(find_python_module) You can then write: find_python_module(PyQt4 REQUIRED) -- Mark Moll ___ 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] Help building static libs w/cmake 2.8 and llvm/clang on Windows
Build is eclipse-cdt/nmake on windows 7 C:\Program Files (x86)\CMake 2.8\bin\cmake.exe -E cmake_link_script CMakeFiles\MathFunctions.dir\link.txt --verbose=yes CMAKE_AR-NOTFOUND cr MathFunctions.lib CMakeFiles/MathFunctions.dir/mysqrt.c.ob Error running link command: The system cannot find the file specified I specified CMAKE_AR as llvm-ar in the cache. I looked at some earlier posts related to similar problems w/cmake 2.6 and dashes link executables and tried renaming llvm-ar to llvm_ar but still am having the same issue. ___ 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 find the path to the currently include() or find_package file()
I am using CMake 2.8 on Linux and Windows. When I include() or find_package() a .cmake file, is there a variable that I can use within the included .cmake file that will tell me its path? For example, # In CMakeLists.txt include(somePath/foo.cmake) Within somePath/foo.cmake, I want to include bar.cmake which is in the same directory as foo.cmake, # In somePath/foo.cmake include(${CMAKE_VARIABLE_THAT_IS_THE_ANSWER_TO_THIS_QUESTION}/bar.cmake) where ${CMAKE_VARIABLE_THAT_IS_THE_ANSWER_TO_THIS_QUESTION} = somePath, the path to foo.cmake, which is currently being evaluated. ___ 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 find the path to the currently include() or find_package file()
On 01/04/2011 05:47 AM, John McGehee wrote: I am using CMake 2.8 on Linux and Windows. When I include() or find_package() a .cmake file, is there a variable that I can use within the included .cmake file that will tell me its path? For example, # In CMakeLists.txt include(somePath/foo.cmake) Within somePath/foo.cmake, I want to include bar.cmake which is in the same directory as foo.cmake, # In somePath/foo.cmake include(${CMAKE_VARIABLE_THAT_IS_THE_ANSWER_TO_THIS_QUESTION}/bar.cmake) where ${CMAKE_VARIABLE_THAT_IS_THE_ANSWER_TO_THIS_QUESTION} = somePath, the path to foo.cmake, which is currently being evaluated. Use CMAKE_CURRENT_LIST_FILE in conjunction with GET_FILENAME_COMPONENT(): # In somePath/foo.cmake get_filename_component(somePath ${CMAKE_CURRENT_LIST_FILE} PATH) include(${somePath}/bar.cmake) 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
Re: [CMake] How to find the path to the currently include() or find_package file()
On 01/04/2011 07:41 AM, Michael Hertling wrote: On 01/04/2011 05:47 AM, John McGehee wrote: I am using CMake 2.8 on Linux and Windows. When I include() or find_package() a .cmake file, is there a variable that I can use within the included .cmake file that will tell me its path? For example, # In CMakeLists.txt include(somePath/foo.cmake) Within somePath/foo.cmake, I want to include bar.cmake which is in the same directory as foo.cmake, # In somePath/foo.cmake include(${CMAKE_VARIABLE_THAT_IS_THE_ANSWER_TO_THIS_QUESTION}/bar.cmake) where ${CMAKE_VARIABLE_THAT_IS_THE_ANSWER_TO_THIS_QUESTION} = somePath, the path to foo.cmake, which is currently being evaluated. Use CMAKE_CURRENT_LIST_FILE in conjunction with GET_FILENAME_COMPONENT(): Oops...or just CMAKE_CURRENT_LIST_DIR. ;| 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
Re: [CMake] Installing Python Modules with CMake
On 01/03/2011 06:23 PM, Todd Gamblin wrote: On Jan 3, 2011, at 1:34 AM, Michael Wild wrote: On 01/03/2011 09:11 AM, Todd Gamblin wrote: Is there some standard way in CMake to get a project-local install destination for python libraries, e.g.: ${CMAKE_INSTALL_PREFIX}/lib/python2.6/site-packages Is this something find modules typically provide? I can construct this name easily enough myself, but it involves querying the python executable for its version then regexing that string, and I feel like FindPythonLibs should do stuff like that for me. It would be nice to have something called, say, CMAKE_PYTHON_INSTALL_PREFIX set to this path in advance, so that I can just install python modules there. Or am I missing something? I couldn't fund much on installing python files in the docs. -Todd I think you'll have to query Python yourself. Of course, this becomes difficult if you're cross-compiling, in which case you would need to parse the prefix/lib/pythonX.Y/config/Makefile file yourself and fetch all the relevant variables (datarootdir, BINDIR, DESTSHARED, LIBDEST, etc.) and then ask the user what prefix and exec_prefix he wants (presumably CMAKE_INSTALL_PREFIX maps to prefix, and usually exec_prefix is the same as prefix, but that's not always the case). Not sure how that works on Windows, though... That's kind of difficult because if I have just 'python', I don't have the version yet, so how am I supposed to find the Makefile? Off the top of my head, the most portable way to do this would be to find the python-config (which you can get by appending -config to the exe path, even if it's just python and not pythonX.Y) and then: head -1 `which ${PYTHON_CONFIG}` | sed 's/.*\([0-9].[0-9]\)$/\1/' Or the equivalent in CMake using string(REGEXP ...). That will get you the version without running anything, and then you can go and find the Makefile. That only works on *NIX, on Windows there's AFAIK no python-config. So if you plan to cross-compile for Windows you might run into trouble. Probably it's best to not try being über-smart, and just leave it to the user to provide the information. In the non cross-compiled case, though, it would be nice to just have a module that gives you all the information from python-config. Better run ${PYTHON_EXECUTABLE} -c import sys; sys.stdout.write(sys.prefix+'\n') and similar, which also works on WIN32. -Todd I wouldn't rely too much on FindPythonLibs. The whole FindPython* is a sorry mess (IMHO) and needs some serious overhaul, but that is some major undertaking an apparently the suffering wasn't big enough so far for somebody to take action... I noticed you guys had a long discussion about finding Python 3. Did you come to any conclusions on this? It would be nice to have a python detection Find module that works if you *just* give it your python executable. I don't mind writing something like this up if no one else is up for it, but if I'm going to write it I'd like to make something that people will use. Thoughts? AFAIK, the issue hasn't been resolved. One of the big problems IMHO is, that FindPythonInterp and FindPythonLibs can report different python installations. Also, what should happen if the user manually changes the cache entry for the interpreter, but doesn't update the libraries? Also, some users of the module will just want the most recent version of Python, while others will specifically want the most recent 2.x version because their code isn't ready for python3. If you can come up with something that works well on all important platforms and is reasonably backwards compatible, you probably would make a lot of people happy ;-) 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-commits] CMake branch, next, updated. v2.8.3-1138-gcd1010a
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 cd1010a562140632b542d6dea01f929f35900f63 (commit) via 6529d7f67e05903ca29347c3220a0c91ce1f2905 (commit) from e44ca0b4fd97637a604f2c8786793e1e805f88c1 (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=cd1010a562140632b542d6dea01f929f35900f63 commit cd1010a562140632b542d6dea01f929f35900f63 Merge: e44ca0b 6529d7f Author: Ben Boeckel ben.boec...@kitware.com AuthorDate: Mon Jan 3 08:43:28 2011 -0500 Commit: CMake Topic Stage kwro...@kitware.com CommitDate: Mon Jan 3 08:43:28 2011 -0500 Merge topic 'dev/add_test-working-directory' into next 6529d7f Pass the expected value as the first argument http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=6529d7f67e05903ca29347c3220a0c91ce1f2905 commit 6529d7f67e05903ca29347c3220a0c91ce1f2905 Author: Ben Boeckel ben.boec...@kitware.com AuthorDate: Mon Jan 3 08:39:22 2011 -0500 Commit: Ben Boeckel ben.boec...@kitware.com CommitDate: Mon Jan 3 08:39:22 2011 -0500 Pass the expected value as the first argument When the path has regular expression special characters, the PASS_REGULAR_EXPRESSION value can fail to compile. diff --git a/Tests/TestsWorkingDirectory/CMakeLists.txt b/Tests/TestsWorkingDirectory/CMakeLists.txt index 01e6650..0fef19d 100644 --- a/Tests/TestsWorkingDirectory/CMakeLists.txt +++ b/Tests/TestsWorkingDirectory/CMakeLists.txt @@ -7,46 +7,32 @@ enable_testing() set(EXECUTABLE_OUTPUT_PATH ${CMAKE_BINARY_DIR}/bin) -add_test(NAME WorkingDirectory1 COMMAND WorkingDirectory) +add_test(NAME WorkingDirectory1 COMMAND WorkingDirectory ${CMAKE_BINARY_DIR}) set_tests_properties(WorkingDirectory1 PROPERTIES WORKING_DIRECTORY ${CMAKE_BINARY_DIR} - PASS_REGULAR_EXPRESSION Working directory: --${CMAKE_BINARY_DIR}-- ) string(REGEX REPLACE /[^/]*$ _parent_dir ${CMAKE_BINARY_DIR}) -add_test(NAME WorkingDirectory2 COMMAND WorkingDirectory) +add_test(NAME WorkingDirectory2 COMMAND WorkingDirectory ${_parent_dir}) set_tests_properties(WorkingDirectory2 PROPERTIES WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/.. - PASS_REGULAR_EXPRESSION Working directory: --${_parent_dir}-- ) get_filename_component(_default_cwd ${EXECUTABLE_OUTPUT_PATH} PATH) # FIXME: How to deal with /debug, /release, etc. with VS or XCode? if(${CMAKE_GENERATOR} MATCHES Makefiles) -add_test(WorkingDirectory3 ${EXECUTABLE_OUTPUT_PATH}/WorkingDirectory) -set_tests_properties(WorkingDirectory3 PROPERTIES - PASS_REGULAR_EXPRESSION Working directory: --${_default_cwd}-- -) +add_test(WorkingDirectory3 ${EXECUTABLE_OUTPUT_PATH}/WorkingDirectory ${_default_cwd}) endif() -add_test(NAME WorkingDirectory4 WORKING_DIRECTORY ${CMAKE_BINARY_DIR} COMMAND WorkingDirectory) -set_tests_properties(WorkingDirectory4 PROPERTIES - PASS_REGULAR_EXPRESSION Working directory: --${CMAKE_BINARY_DIR}-- -) +add_test(NAME WorkingDirectory4 WORKING_DIRECTORY ${CMAKE_BINARY_DIR} COMMAND WorkingDirectory ${CMAKE_BINARY_DIR}) string(REGEX REPLACE /[^/]*$ _parent_dir ${CMAKE_BINARY_DIR}) -add_test(NAME WorkingDirectory5 WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/.. COMMAND WorkingDirectory) -set_tests_properties(WorkingDirectory5 PROPERTIES - PASS_REGULAR_EXPRESSION Working directory: --${_parent_dir}-- -) +add_test(NAME WorkingDirectory5 WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/.. COMMAND WorkingDirectory ${_parent_dir}) # FIXME: How to deal with /debug, /release, etc. with VS or XCode? if(${CMAKE_GENERATOR} MATCHES Makefiles) -add_test(WorkingDirectory6 ${EXECUTABLE_OUTPUT_PATH}/WorkingDirectory WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/..) -set_tests_properties(WorkingDirectory6 PROPERTIES - PASS_REGULAR_EXPRESSION Working directory: --${_default_cwd}-- -) +add_test(WorkingDirectory6 ${EXECUTABLE_OUTPUT_PATH}/WorkingDirectory ${_default_cwd} WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/..) endif() diff --git a/Tests/TestsWorkingDirectory/main.c b/Tests/TestsWorkingDirectory/main.c index ad5eb30..19f2f14 100644 --- a/Tests/TestsWorkingDirectory/main.c +++ b/Tests/TestsWorkingDirectory/main.c @@ -60,7 +60,5 @@ int main(int argc, char *argv[]) char buf[2048]; const char *cwd = Getcwd(buf, sizeof(buf)); - fprintf(stdout, Working directory: --%s--, cwd); - - return 0; + return strcmp(cwd, argv[1]); } --- Summary of changes: Tests/TestsWorkingDirectory/CMakeLists.txt | 26 ++ Tests/TestsWorkingDirectory/main.c |4 +--- 2 files changed, 7 insertions(+), 23 deletions(-) hooks/post-receive --
[Cmake-commits] CMake branch, next, updated. v2.8.3-1141-g046775d
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 046775df9c04739f6e458b018c25b69d2ac89c65 (commit) via 89c25443a62de7a06fc0daa9f552a70aa9692aa0 (commit) via 5625dee390fc0c35755683b7302e49967107bbf0 (commit) from cd1010a562140632b542d6dea01f929f35900f63 (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=046775df9c04739f6e458b018c25b69d2ac89c65 commit 046775df9c04739f6e458b018c25b69d2ac89c65 Merge: cd1010a 89c2544 Author: Ben Boeckel ben.boec...@kitware.com AuthorDate: Mon Jan 3 08:51:49 2011 -0500 Commit: CMake Topic Stage kwro...@kitware.com CommitDate: Mon Jan 3 08:51:49 2011 -0500 Merge topic 'dev/strict-mode' into next 89c2544 Checking for a definition is a usage 5625dee Don't output to stderr in the GUI http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=89c25443a62de7a06fc0daa9f552a70aa9692aa0 commit 89c25443a62de7a06fc0daa9f552a70aa9692aa0 Author: Ben Boeckel ben.boec...@kitware.com AuthorDate: Mon Jan 3 08:47:04 2011 -0500 Commit: Ben Boeckel ben.boec...@kitware.com CommitDate: Mon Jan 3 08:47:04 2011 -0500 Checking for a definition is a usage diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx index 0913e0a..7044049 100644 --- a/Source/cmMakefile.cxx +++ b/Source/cmMakefile.cxx @@ -2176,6 +2176,7 @@ const char* cmMakefile::GetRequiredDefinition(const char* name) const bool cmMakefile::IsDefinitionSet(const char* name) const { const char* def = this-Internal-VarStack.top().Get(name); + this-Internal-VarUsageStack.top().insert(name); if(!def) { def = this-GetCacheManager()-GetCacheValue(name); http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=5625dee390fc0c35755683b7302e49967107bbf0 commit 5625dee390fc0c35755683b7302e49967107bbf0 Author: Ben Boeckel ben.boec...@kitware.com AuthorDate: Mon Jan 3 08:45:48 2011 -0500 Commit: Ben Boeckel ben.boec...@kitware.com CommitDate: Mon Jan 3 08:45:48 2011 -0500 Don't output to stderr in the GUI diff --git a/Source/QtDialog/QCMake.cxx b/Source/QtDialog/QCMake.cxx index 48871c2..182db0f 100644 --- a/Source/QtDialog/QCMake.cxx +++ b/Source/QtDialog/QCMake.cxx @@ -166,7 +166,6 @@ void QCMake::configure() this-CMakeInstance-CreateGlobalGenerator(this-Generator.toAscii().data())); this-CMakeInstance-LoadCache(); this-CMakeInstance-SetSuppressDevWarnings(this-SuppressDevWarnings); - std::cerr set warn uninitialized this-WarnUninitializedMode \n; this-CMakeInstance-SetWarnUninitialized(this-WarnUninitializedMode); this-CMakeInstance-SetWarnUnused(this-WarnUnusedMode); this-CMakeInstance-PreLoadCMakeFiles(); --- Summary of changes: Source/QtDialog/QCMake.cxx |1 - Source/cmMakefile.cxx |1 + 2 files changed, 1 insertions(+), 1 deletions(-) hooks/post-receive -- CMake ___ Cmake-commits mailing list Cmake-commits@cmake.org http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-commits
[Cmake-commits] CMake branch, next, updated. v2.8.3-1144-gb13c213
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 b13c21318c7551eb692b338f380bc30011346edc (commit) via edff9207ed82d241077d66b20087657f74e8b5b9 (commit) via 4e0681abd75fc3cde7b6a63b91015c8b0eaf8c76 (commit) from 046775df9c04739f6e458b018c25b69d2ac89c65 (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=b13c21318c7551eb692b338f380bc30011346edc commit b13c21318c7551eb692b338f380bc30011346edc Merge: 046775d edff920 Author: Brad King brad.k...@kitware.com AuthorDate: Mon Jan 3 09:18:04 2011 -0500 Commit: Brad King brad.k...@kitware.com CommitDate: Mon Jan 3 09:18:04 2011 -0500 Merge branch 'master' into next --- Summary of changes: Source/kwsys/kwsysDateStamp.cmake |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) hooks/post-receive -- CMake ___ Cmake-commits mailing list Cmake-commits@cmake.org http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-commits
[Cmake-commits] CMake branch, next, updated. v2.8.3-1148-g078e351
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 078e35166b13153c17989ee4bc178b1b77fdf357 (commit) via 6b0c7ded5777c5b4c703bbe59be5c6afcebb879d (commit) from c96ea14e3d75df08638948783c89ccc47a0ddb1a (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=078e35166b13153c17989ee4bc178b1b77fdf357 commit 078e35166b13153c17989ee4bc178b1b77fdf357 Merge: c96ea14 6b0c7de Author: Zach Mullen zach.mul...@kitware.com AuthorDate: Mon Jan 3 11:26:55 2011 -0500 Commit: Zach Mullen zach.mul...@kitware.com CommitDate: Mon Jan 3 11:26:55 2011 -0500 Merge branch 'negative-test-costs' into next http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=6b0c7ded5777c5b4c703bbe59be5c6afcebb879d commit 6b0c7ded5777c5b4c703bbe59be5c6afcebb879d Author: Zach Mullen zach.mul...@kitware.com AuthorDate: Mon Jan 3 11:25:46 2011 -0500 Commit: Zach Mullen zach.mul...@kitware.com CommitDate: Mon Jan 3 11:25:46 2011 -0500 Support explicitly set test costs in non-parallel testing. diff --git a/Source/CTest/cmCTestMultiProcessHandler.cxx b/Source/CTest/cmCTestMultiProcessHandler.cxx index 94614cf..f3a4457 100644 --- a/Source/CTest/cmCTestMultiProcessHandler.cxx +++ b/Source/CTest/cmCTestMultiProcessHandler.cxx @@ -428,7 +428,10 @@ void cmCTestMultiProcessHandler::ReadCostData() if(index == -1) continue; this-Properties[index]-PreviousRuns = prev; - if(this-Properties[index] this-Properties[index]-Cost == 0) + // When not running in parallel mode, don't use cost data + if(this-ParallelLevel 1 + this-Properties[index] + this-Properties[index]-Cost == 0) { this-Properties[index]-Cost = cost; } @@ -469,20 +472,19 @@ void cmCTestMultiProcessHandler::CreateTestCostList() { SortedTests.push_back(i-first); -//If the test failed last time, it should be run first, so max the cost -if(std::find(this-LastTestsFailed.begin(), - this-LastTestsFailed.end(), - this-Properties[i-first]-Name) - != this-LastTestsFailed.end()) +//If the test failed last time, it should be run first, so max the cost. +//Only do this for parallel runs; in non-parallel runs, avoid clobbering +//the test's explicitly set cost. +if(this-ParallelLevel 1 + std::find(this-LastTestsFailed.begin(), this-LastTestsFailed.end(), + this-Properties[i-first]-Name) != this-LastTestsFailed.end()) { this-Properties[i-first]-Cost = FLT_MAX; } } - if(this-ParallelLevel 1) -{ -TestComparator comp(this); -std::sort(SortedTests.begin(), SortedTests.end(), comp); -} + + TestComparator comp(this); + std::sort(SortedTests.begin(), SortedTests.end(), comp); } //- diff --git a/Tests/CMakeLists.txt b/Tests/CMakeLists.txt index 289e632..874ed15 100644 --- a/Tests/CMakeLists.txt +++ b/Tests/CMakeLists.txt @@ -1391,7 +1391,20 @@ ${CMake_BINARY_DIR}/bin/cmake -DVERSION=master -P ${CMake_SOURCE_DIR}/Utilities/ --output-log ${CMake_BINARY_DIR}/Tests/CTestTestScheduler/testOutput.log ) SET_TESTS_PROPERTIES(CTestTestScheduler PROPERTIES -PASS_REGULAR_EXPRESSION Start 1.*Start 2.*Start 3.*Start 4.*Start 4.*Start 3.*Start 2.*Start 1) +PASS_REGULAR_EXPRESSION Start 1.*Start 2.*Start 3.*Start 4.*Start 4.*Start 3.*Start 2.*Start 1 +RESOURCE_LOCK CostData) + + CONFIGURE_FILE( +${CMake_SOURCE_DIR}/Tests/CTestTestCostSerial/test.cmake.in +${CMake_BINARY_DIR}/Tests/CTestTestCostSerial/test.cmake +@ONLY ESCAPE_QUOTES) + ADD_TEST(CTestTestCostSerial ${CMAKE_CTEST_COMMAND} +-S ${CMake_BINARY_DIR}/Tests/CTestTestCostSerial/test.cmake -V +--output-log ${CMake_BINARY_DIR}/Tests/CTestTestCostSerial/testOutput.log +) + SET_TESTS_PROPERTIES(CTestTestCostSerial PROPERTIES +PASS_REGULAR_EXPRESSION Start 2.*Start 3.*Start 1.*Start 2.*Start 3.*Start 1 +RESOURCE_LOCK CostData) CONFIGURE_FILE( ${CMake_SOURCE_DIR}/Tests/CTestTestStopTime/test.cmake.in diff --git a/Tests/CTestTestCostSerial/CMakeLists.txt b/Tests/CTestTestCostSerial/CMakeLists.txt new file mode 100644 index 000..a9a5c25 --- /dev/null +++ b/Tests/CTestTestCostSerial/CMakeLists.txt @@ -0,0 +1,13 @@ +CMAKE_MINIMUM_REQUIRED (VERSION 2.6) +PROJECT (CTestTestCostSerial) +INCLUDE (CTest) + +ADD_EXECUTABLE (Sleep sleep.c) + +FOREACH (index RANGE 1 3) + ADD_TEST (TestSleep${index} Sleep) +ENDFOREACH (index RANGE 1 3) + +SET_TESTS_PROPERTIES(TestSleep1 PROPERTIES COST -500) +SET_TESTS_PROPERTIES(TestSleep2
[Cmake-commits] CMake branch, master, updated. v2.8.3-375-ga67fd72
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, master has been updated via a67fd7265978a3d8e0565671da651ddfdc6b6e98 (commit) from edff9207ed82d241077d66b20087657f74e8b5b9 (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=a67fd7265978a3d8e0565671da651ddfdc6b6e98 commit a67fd7265978a3d8e0565671da651ddfdc6b6e98 Author: Brad King brad.k...@kitware.com AuthorDate: Mon Jan 3 12:01:54 2011 -0500 Commit: Brad King brad.k...@kitware.com CommitDate: Mon Jan 3 12:03:03 2011 -0500 KWSys: Remove useless include sys/procfs.h (#11648) The header was included only under #ifdef __linux, but not all Linux distributions provide the header. SystemInformation uses no symbols from this header, so do not include it. diff --git a/Source/kwsys/SystemInformation.cxx b/Source/kwsys/SystemInformation.cxx index d727b32..f871075 100644 --- a/Source/kwsys/SystemInformation.cxx +++ b/Source/kwsys/SystemInformation.cxx @@ -66,7 +66,6 @@ #endif #ifdef __linux -# include sys/procfs.h # include sys/types.h # include unistd.h # include fcntl.h --- Summary of changes: Source/kwsys/SystemInformation.cxx |1 - 1 files changed, 0 insertions(+), 1 deletions(-) hooks/post-receive -- CMake ___ Cmake-commits mailing list Cmake-commits@cmake.org http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-commits
[Cmake-commits] CMake branch, next, updated. v2.8.3-1150-g77dfea4
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 77dfea4f2e9fd8a11f497a85fc03ce433c6e9deb (commit) via a67fd7265978a3d8e0565671da651ddfdc6b6e98 (commit) from 078e35166b13153c17989ee4bc178b1b77fdf357 (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=77dfea4f2e9fd8a11f497a85fc03ce433c6e9deb commit 77dfea4f2e9fd8a11f497a85fc03ce433c6e9deb Merge: 078e351 a67fd72 Author: Brad King brad.k...@kitware.com AuthorDate: Mon Jan 3 12:03:10 2011 -0500 Commit: Brad King brad.k...@kitware.com CommitDate: Mon Jan 3 12:03:10 2011 -0500 Merge branch 'master' into next --- Summary of changes: Source/kwsys/SystemInformation.cxx |1 - 1 files changed, 0 insertions(+), 1 deletions(-) hooks/post-receive -- CMake ___ Cmake-commits mailing list Cmake-commits@cmake.org http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-commits
[Cmake-commits] CMake branch, next, updated. v2.8.3-1152-g2a672c1
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 2a672c1206e6fbe8ef6b3a7998f6a361d1168018 (commit) via 7d691cab9b479b154653f49057724a7707015828 (commit) from 77dfea4f2e9fd8a11f497a85fc03ce433c6e9deb (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=2a672c1206e6fbe8ef6b3a7998f6a361d1168018 commit 2a672c1206e6fbe8ef6b3a7998f6a361d1168018 Merge: 77dfea4 7d691ca Author: Brad King brad.k...@kitware.com AuthorDate: Mon Jan 3 12:21:30 2011 -0500 Commit: CMake Topic Stage kwro...@kitware.com CommitDate: Mon Jan 3 12:21:30 2011 -0500 Merge topic 'linux-standard-base' into next 7d691ca ccmake: Port for LSB 4.0 (#11648) http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=7d691cab9b479b154653f49057724a7707015828 commit 7d691cab9b479b154653f49057724a7707015828 Author: Craig Scott craig.sc...@csiro.au AuthorDate: Mon Jan 3 12:15:41 2011 -0500 Commit: Brad King brad.k...@kitware.com CommitDate: Mon Jan 3 12:15:41 2011 -0500 ccmake: Port for LSB 4.0 (#11648) Use getmaxyx instead of getmax[xy]. Avoid using getattrs. diff --git a/Source/CursesDialog/form/frm_driver.c b/Source/CursesDialog/form/frm_driver.c index 0b53b5a..519d66d 100644 --- a/Source/CursesDialog/form/frm_driver.c +++ b/Source/CursesDialog/form/frm_driver.c @@ -357,8 +357,7 @@ static void Buffer_To_Window(const FIELD * field, WINDOW * win) assert(win field); - width = getmaxx(win); - height = getmaxy(win); + getmaxyx(win, height, width); for(row=0, pBuffer=field-buf; row height; @@ -390,13 +389,13 @@ static void Window_To_Buffer(WINDOW * win, FIELD * field) int pad; int len = 0; char *p; - int row, height; + int row, height, width; assert(win field field-buf ); pad = field-pad; p = field-buf; - height = getmaxy(win); + getmaxyx(win, height, width); for(row=0; (row height) (row field-drows); row++ ) { @@ -856,6 +855,8 @@ static int Display_Or_Erase_Field(FIELD * field, bool bEraseFlag) { WINDOW *win; WINDOW *fwin; + attr_t fwinAttrs; + short fwinPair; if (!field) return E_SYSTEM_ERROR; @@ -871,7 +872,12 @@ static int Display_Or_Erase_Field(FIELD * field, bool bEraseFlag) if (field-opts O_VISIBLE) Set_Field_Window_Attributes(field,win); else -wattrset(win,getattrs(fwin)); + { +/* getattrs() would be handy, but it is not part of LSB 4.0 */ +/* wattrset(win,getattrs(fwin)); */ +wattr_get(fwin, fwinAttrs, fwinPair, 0); +wattr_set(win, fwinAttrs, fwinPair, 0); + } werase(win); } diff --git a/Source/CursesDialog/form/frm_post.c b/Source/CursesDialog/form/frm_post.c index 5ead942..924fe6a 100644 --- a/Source/CursesDialog/form/frm_post.c +++ b/Source/CursesDialog/form/frm_post.c @@ -51,6 +51,7 @@ int post_form(FORM * form) WINDOW *formwin; int err; int page; + int height, width; if (!form) RETURN(E_BAD_ARGUMENT); @@ -62,7 +63,8 @@ int post_form(FORM * form) RETURN(E_NOT_CONNECTED); formwin = Get_Form_Window(form); - if ((form-cols getmaxx(formwin)) || (form-rows getmaxy(formwin))) + getmaxyx(formwin, height, width); + if ((form-cols width) || (form-rows height)) RETURN(E_NO_ROOM); /* reset form-curpage to an invald value. This forces Set_Form_Page --- Summary of changes: Source/CursesDialog/form/frm_driver.c | 16 +++- Source/CursesDialog/form/frm_post.c |4 +++- 2 files changed, 14 insertions(+), 6 deletions(-) hooks/post-receive -- CMake ___ Cmake-commits mailing list Cmake-commits@cmake.org http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-commits
[Cmake-commits] CMake branch, next, updated. v2.8.3-1154-ge207994
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 e207994883b65b3ddcfdbfec9c0068f59252d796 (commit) via 90b0f2c624e0df635abe551825befa729c2aa072 (commit) from 2a672c1206e6fbe8ef6b3a7998f6a361d1168018 (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=e207994883b65b3ddcfdbfec9c0068f59252d796 commit e207994883b65b3ddcfdbfec9c0068f59252d796 Merge: 2a672c1 90b0f2c Author: Bill Hoffman bill.hoff...@kitware.com AuthorDate: Mon Jan 3 14:07:14 2011 -0500 Commit: CMake Topic Stage kwro...@kitware.com CommitDate: Mon Jan 3 14:07:14 2011 -0500 Merge topic 'add_resource_support_to_intel' into next 90b0f2c Enable resource building with the intel compiler on windows. http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=90b0f2c624e0df635abe551825befa729c2aa072 commit 90b0f2c624e0df635abe551825befa729c2aa072 Author: Bill Hoffman bill.hoff...@kitware.com AuthorDate: Mon Jan 3 14:02:22 2011 -0500 Commit: Bill Hoffman bill.hoff...@kitware.com CommitDate: Mon Jan 3 14:02:22 2011 -0500 Enable resource building with the intel compiler on windows. diff --git a/Modules/Platform/Windows-Intel.cmake b/Modules/Platform/Windows-Intel.cmake index 444a60e..e7462ba 100644 --- a/Modules/Platform/Windows-Intel.cmake +++ b/Modules/Platform/Windows-Intel.cmake @@ -18,6 +18,10 @@ if(__WINDOWS_INTEL) endif() set(__WINDOWS_INTEL 1) +# make sure to enable languages after setting configuration types +ENABLE_LANGUAGE(RC) +SET(CMAKE_COMPILE_RESOURCE rc FLAGS /foOBJECT SOURCE) + SET(CMAKE_LIBRARY_PATH_FLAG -LIBPATH:) SET(CMAKE_LINK_LIBRARY_FLAG ) SET(WIN32 1) --- Summary of changes: Modules/Platform/Windows-Intel.cmake |4 1 files changed, 4 insertions(+), 0 deletions(-) hooks/post-receive -- CMake ___ Cmake-commits mailing list Cmake-commits@cmake.org http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-commits
[Cmake-commits] CMake branch, next, updated. v2.8.3-1156-g27920f2
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 27920f2ff7f657fb01e0b9c7164e95c1e982b643 (commit) via 51bb49357495ea2742858ffe9d76ab3f44efc06e (commit) from e207994883b65b3ddcfdbfec9c0068f59252d796 (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=27920f2ff7f657fb01e0b9c7164e95c1e982b643 commit 27920f2ff7f657fb01e0b9c7164e95c1e982b643 Merge: e207994 51bb493 Author: Zach Mullen zach.mul...@kitware.com AuthorDate: Mon Jan 3 14:42:30 2011 -0500 Commit: Zach Mullen zach.mul...@kitware.com CommitDate: Mon Jan 3 14:42:30 2011 -0500 Merge branch 'honor-explicit-zero-timeout' into next http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=51bb49357495ea2742858ffe9d76ab3f44efc06e commit 51bb49357495ea2742858ffe9d76ab3f44efc06e Author: Zach Mullen zach.mul...@kitware.com AuthorDate: Mon Jan 3 14:41:25 2011 -0500 Commit: Zach Mullen zach.mul...@kitware.com CommitDate: Mon Jan 3 14:41:25 2011 -0500 Test TIMEOUT property explicitly set to zero should be honored diff --git a/Source/CTest/cmCTestRunTest.cxx b/Source/CTest/cmCTestRunTest.cxx index 76ff23a..42a4cff 100644 --- a/Source/CTest/cmCTestRunTest.cxx +++ b/Source/CTest/cmCTestRunTest.cxx @@ -455,7 +455,8 @@ bool cmCTestRunTest::StartTest(size_t total) { return false; } - return this-ForkProcess(timeout, this-TestProperties-Environment); + return this-ForkProcess(timeout, this-TestProperties-ExplicitTimeout, + this-TestProperties-Environment); } //-- @@ -598,7 +599,7 @@ double cmCTestRunTest::ResolveTimeout() } //-- -bool cmCTestRunTest::ForkProcess(double testTimeOut, +bool cmCTestRunTest::ForkProcess(double testTimeOut, bool explicitTimeout, std::vectorstd::string* environment) { this-TestProcess = new cmProcess; @@ -619,12 +620,16 @@ bool cmCTestRunTest::ForkProcess(double testTimeOut, { timeout = testTimeOut; } - // always have at least 1 second if we got to here if (timeout = 0) { timeout = 1; } + // handle timeout explicitly set to 0 + if (testTimeOut == 0 explicitTimeout) +{ +timeout = 0; +} cmCTestLog(this-CTest, HANDLER_VERBOSE_OUTPUT, this-Index : Test timeout computed to be: timeout \n); diff --git a/Source/CTest/cmCTestRunTest.h b/Source/CTest/cmCTestRunTest.h index 66e6b7b..89456d5 100644 --- a/Source/CTest/cmCTestRunTest.h +++ b/Source/CTest/cmCTestRunTest.h @@ -63,8 +63,8 @@ private: void ExeNotFound(std::string exe); // Figures out a final timeout which is min(STOP_TIME, NOW+TIMEOUT) double ResolveTimeout(); - bool ForkProcess(double testTimeOut, - std::vectorstd::string* environment); + bool ForkProcess(double testTimeOut, bool explicitTimeout, + std::vectorstd::string* environment); void WriteLogOutputTop(size_t completed, size_t total); //Run post processing of the process output for MemCheck void MemCheckPostProcess(); diff --git a/Source/CTest/cmCTestTestHandler.cxx b/Source/CTest/cmCTestTestHandler.cxx index 6d1af2d..fdafb9b 100644 --- a/Source/CTest/cmCTestTestHandler.cxx +++ b/Source/CTest/cmCTestTestHandler.cxx @@ -2122,6 +2122,7 @@ bool cmCTestTestHandler::SetTestsProperties( if ( key == TIMEOUT ) { rtit-Timeout = atof(val.c_str()); +rtit-ExplicitTimeout = true; } if ( key == COST ) { @@ -2295,6 +2296,7 @@ bool cmCTestTestHandler::AddTest(const std::vectorstd::string args) test.WillFail = false; test.RunSerial = false; test.Timeout = 0; + test.ExplicitTimeout = false; test.Cost = 0; test.Processors = 1; test.PreviousRuns = 0; diff --git a/Source/CTest/cmCTestTestHandler.h b/Source/CTest/cmCTestTestHandler.h index 7049564..7aa8522 100644 --- a/Source/CTest/cmCTestTestHandler.h +++ b/Source/CTest/cmCTestTestHandler.h @@ -99,6 +99,7 @@ public: int PreviousRuns; bool RunSerial; double Timeout; +bool ExplicitTimeout; int Index; //Requested number of process slots int Processors; diff --git a/Tests/CMakeLists.txt b/Tests/CMakeLists.txt index 289e632..466adda 100644 --- a/Tests/CMakeLists.txt +++ b/Tests/CMakeLists.txt @@ -45,18 +45,18 @@ IF(BUILD_TESTING) SET(TEST_BUILD_DIRS) # Should the long tests be run? - OPTION(CMAKE_RUN_LONG_TESTS + OPTION(CMAKE_RUN_LONG_TESTS Should the long tests be run (such as Bootstrap).
[Cmake-commits] CMake branch, master, updated. v2.8.3-376-gc59ed29
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, master has been updated via c59ed2955294d6b8fe25926c95711f794284354f (commit) from a67fd7265978a3d8e0565671da651ddfdc6b6e98 (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=c59ed2955294d6b8fe25926c95711f794284354f commit c59ed2955294d6b8fe25926c95711f794284354f Author: KWSys Robot kwro...@kitware.com AuthorDate: Tue Jan 4 00:01:19 2011 -0500 Commit: KWSys Robot kwro...@kitware.com CommitDate: Tue Jan 4 00:11:01 2011 -0500 KWSys Nightly Date Stamp diff --git a/Source/kwsys/kwsysDateStamp.cmake b/Source/kwsys/kwsysDateStamp.cmake index 378e7bc..fec5e92 100644 --- a/Source/kwsys/kwsysDateStamp.cmake +++ b/Source/kwsys/kwsysDateStamp.cmake @@ -18,4 +18,4 @@ SET(KWSYS_DATE_STAMP_YEAR 2011) SET(KWSYS_DATE_STAMP_MONTH 01) # KWSys version date day component. Format is DD. -SET(KWSYS_DATE_STAMP_DAY 03) +SET(KWSYS_DATE_STAMP_DAY 04) --- Summary of changes: Source/kwsys/kwsysDateStamp.cmake |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) hooks/post-receive -- CMake ___ Cmake-commits mailing list Cmake-commits@cmake.org http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-commits