View Issue Details [ Jump to Notes ] | [ Print ] | ||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | ||||
0006286 | CMake | QtDialog | public | 2008-01-29 16:03 | 2008-02-20 08:34 | ||||
Reporter | Mike Jackson | ||||||||
Assigned To | Clinton Stimpson | ||||||||
Priority | normal | Severity | major | Reproducibility | always | ||||
Status | closed | Resolution | fixed | ||||||
Platform | OS | OS Version | |||||||
Product Version | |||||||||
Target Version | Fixed in Version | ||||||||
Summary | 0006286: QtDialog does not properly find cmake on OS X | ||||||||
Description | QtDialog properly sets the path to cmake in the constructor of QCmake.cxx. During the 'configure' operation, when cmake::AddPaths() is called the value of this->CMakeCommand is NOT checked first for a valid path and instead a new incorrect path is constructed. This blocks the QtDialog from being used on a daily basis. This will effect OS X systems. Suggested code to fix issue is in additional Information. | ||||||||
Additional Information | In the cmake.cxx file the top of the AddPaths() method should be changed to the following: // at the end of this CMAKE_ROOT and CMAKE_COMMAND should be added to the // cache int cmake::AddCMakePaths() { std::string cMakeSelf = this->CMakeCommand; if ( cMakeSelf.empty() == true) { // Find the cmake executable cMakeSelf = cmSystemTools::GetExecutableDirectory(); cMakeSelf += "/cmake"; cMakeSelf += cmSystemTools::GetExecutableExtension(); std::cout << "cmake::AddCMakePaths() cMakeSelf: " << cMakeSelf << std::endl; if(!cmSystemTools::FileExists(cMakeSelf.c_str())) { cmSystemTools::Error("CMake executable cannot be found at ", cMakeSelf.c_str()); return 0; } } | ||||||||
Tags | No tags attached. | ||||||||
Attached Files | |||||||||
Relationships | |
Relationships |
Notes | |
(0010334) Mike Jackson (reporter) 2008-01-29 16:06 |
The following should be added to the CMakeLists.txt file in the QtDialog directory. IF (APPLE) MESSAGE (STATUS "HELLO HELLO") FILE(MAKE_DIRECTORY ${EXECUTABLE_OUTPUT_PATH}/QtDialog.app/Contents/bin) SET (QTDIALOG_OS_X_BUNDLE_FILES ccmake cmake cmakexbuild cpack ctest DumpDocumentation OSXScriptLauncher ) FOREACH ( _file ${QTDIALOG_OS_X_BUNDLE_FILES} ) SET (dest "${EXECUTABLE_OUTPUT_PATH}/QtDialog.app/Contents/bin/${_file}") MESSAGE(STATUS " Copying ${dest}") ADD_CUSTOM_COMMAND ( TARGET QtDialog POST_BUILD COMMAND ${CMAKE_COMMAND} ARGS -E copy ${EXECUTABLE_OUTPUT_PATH}/${_file} ${dest} ) ENDFOREACH ( _file ${QTDIALOG_OS_X_BUNDLE_FILES} ) ENDIF (APPLE) This will ensure the binaries are properly copied into the Application bundle. |
(0010396) Clinton Stimpson (developer) 2008-02-06 11:24 |
I tried that patch for cmake.cxx, and it works if you always run QtDialog, but the makefile breaks if you have the makefile do a cmake run. One idea would be to have all the cmake apps call SetCMakeCommand with a full path (some do and some don't). Then the suggested cmake.cxx patch could be simplified, and just throw an error if CMakeCommand isn't set correctly. |
(0010400) Clinton Stimpson (developer) 2008-02-06 14:47 |
I actually changed Source/QtDialog/CMakeSetup.cxx (revision 1.12), so it reports to the cmake library the correct location of the cmake executables dir. There's no need to patch cmake.cxx. |
(0010550) Clinton Stimpson (developer) 2008-02-18 16:17 |
The finding of cmake was fixed. If you still have a problem with deployment, please make a separate bug for it. Someone else appears to have been working on that. |
(0010597) Mike Jackson (reporter) 2008-02-20 08:34 |
The latest CMake does indeed properly find cmake now. |
Notes |
Issue History | |||
Date Modified | Username | Field | Change |
2008-01-29 16:03 | Mike Jackson | New Issue | |
2008-01-29 16:06 | Mike Jackson | Note Added: 0010334 | |
2008-02-06 11:24 | Clinton Stimpson | Note Added: 0010396 | |
2008-02-06 13:16 | Alex Neundorf | Assigned To | => Clinton Stimpson |
2008-02-06 13:16 | Alex Neundorf | Status | new => assigned |
2008-02-06 14:47 | Clinton Stimpson | Note Added: 0010400 | |
2008-02-18 16:17 | Clinton Stimpson | Status | assigned => closed |
2008-02-18 16:17 | Clinton Stimpson | Note Added: 0010550 | |
2008-02-18 16:17 | Clinton Stimpson | Resolution | open => fixed |
2008-02-20 08:34 | Mike Jackson | Note Added: 0010597 |
Issue History |
Copyright © 2000 - 2018 MantisBT Team |