Re: [CMake] FW: cmake newbie questions
On Wed, Jul 23, 2008 at 10:01 PM, Phil Smith [EMAIL PROTECTED] wrote: Thanks...that's a good suggestion; I think I've done it, but I'm at that point where I *think* I've done everything, and may have gone in circles. How do I tell it It's a make build without using the GUI? There must be some variable to set, but it's not listed on the website. Look for CMAKE_GENERATOR in CMakeCache.txt John ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] CMake, ITK, VTK, and Qt 4
This question involves the interaction of several different toolkits during the CMake configuration process, so I apologize if this is the wrong venue. I'm receiving the error: Warning: CMake is forcing CMAKE_CXX_RELEASE_FLAGS to /MD /O2 /Ob2 /DNDEBUG -DQT_NO_DEBUG to match that imported from VTK I believe this is a harmless warning that is basically saying cmake will generate a project for your app with compatible settings from what you compiled VTK. ...when building the InsightApplications repository (with VTK support turned on). This message only appears when VTK is built with Qt support; with Qt support in VTK disabled there's no problem. This message also appears in CMake with our in-house application that uses ITK/VTK/Qt. So far we've been hitting Cancel to ignore the warning, apparently without consequence (the app compiles and runs correctly). This appears unrelated the particular build configuration; I typically build both ITK and VTK in both release and debug modes and rely on the cmake generated project to resolve the correct library set at link time. This works fine in both release and debug modes without Qt enabled in VTK. Again, even with Qt enabled, the generated project appears correct despite the warning. Any thoughts? The applicable software versions are: CMake 2.4.8 VTK 5.0.4 ITK 3.4 and 3.6 (both tested) Qt 4.3.4 Windows Vista with VS 2005 standard I have got Qt 4.3.X + VTK 5.X.X + ITK 3.6 to work fine but I am not using CMake 2.4.8. I am instead using CMake 2.7.X which I downloaded of the nightly windows cvs build. I am using this with visual C++ 2003. John ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Issues with VS2005 Pro, CMake 2.4.8, Win XP, ParaView
Also, to embellish on my last email, I used the dependencywalker utility to discover that the MSVCR80.dll could not be found. I don't really know where to look for it either. (VS Newbie).. That is because it is hidden in cryptic folders off your windows install: C:\WINXP\WinSxS\x86_Microsoft.VC80.CRT_1fc8b3b9a1e18e3b_8.0.50727.1433_x-ww_5cf844d2 ... John ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Executable extension (MSVC)
What are the flags used in MSVC to create a .com file? I assume you need a very old version of msvc to support 16 bit compiles. Microsoft compilers have not supported this since version 4.X I believe which was more than 10 years ago. John ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Executable extension (MSVC)
On Wed, May 14, 2008 at 9:20 AM, PCJohn [EMAIL PROTECTED] wrote: Dear cmakers, I really need to set executable extension to .com instead to standard .exe (using MSVC). Is it possible to do that, or do I need to not use cmake for win32 platform? Reasons: I planned to port InventorTools utilities (http://merlin.fit.vutbr.cz/wiki/index.php/Open_Inventor_Tools) to cmake, I am using dual gui/console behaviour (like the one described at http://www.codeguru.com/Cpp/W-D/console/redirection/article.php/c3955). In short: two executable exists - utility.com and utility.exe. If I type utility or utility.com in windows console, I can work with the application as with ordinary console application. When I run utility.exe (started from Explorer or by shortcut, or Windows gui), I get normal Windows application - no annoying console, just gui. This can not be realized in single executable. utility.com always opens console, even when started from gui, and utility.exe never communicate through console - as given by nature of Windows :( . Just both of them can do the thing. I know for a fact that this is not correct. I have written my own single windows applications that have a gui and a console and it is a .exe. Link the gui application with subsystem console. John ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Executable extension (MSVC)
I know for a fact that this is not correct. I have written my own single windows applications that have a gui and a console and it is a .exe. Link the gui application with subsystem console. Ok. I found what I do. I have a post build step (in a vc6 project .dsp) that changes the subsystem to console after the build. PostBuild_Cmds=editbin /SUBSYSTEM:CONSOLE $(TARGETPath) John ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
[CMake] moc not being run successfully (every time) in Visual Studio 2003
I am running CMake-2.7.2008.04.21 and under Visual Studio moc does not run correctly all the time for my QT4 projects. Here is the error: -- Build started: Project: LungAnalysis, Configuration: Debug Win32 -- Generating qrc_LungAnalysis.cxx Generating moc_textwidget.cxx moc: Cannot open options file specified with @ Usage: moc [options] header-file -ofile write output to file rather than stdout -Idiradd dir to the include path for header files -E preprocess only; do not generate meta object code -Dmacro[=def] define macro, with optional definition -Umacro undefine macro -i do not generate an #include statement -ppath path prefix for included file -f[file] force #include, optional file name -nwdo not display warnings -v display version of moc Project : error PRJ0019: A tool returned an error code from Generating moc_textwidget.cxx Build log was saved at file://x:\VC.NET\Libraries\MyCode\LungAnalysis\LungAnalysis.dir\Debug\BuildLog.htm LungAnalysis - 1 error(s), 0 warning(s) -- Skipped Build: Project: ALL_BUILD, Configuration: Debug Win32 -- Project configuration skipped because it is not selected in this solution configuration -- Done -- Build: 0 succeeded, 1 failed, 1 skipped If I run moc directly from the project directory all is fine: [x:\vc.net\libraries\mycode\lunganalysis]moc @moc_textwidget.cxx_parameters [x:\vc.net\libraries\mycode\lunganalysis]moc @moc_mainwindow.cxx_parameters I ran through the Qt tutorial building everything (in my own folder) using CMake to generate Visual Studio 2003 projects. For the 14 projects in the tutorial 3 or 4 of them failed with this error. Some of the times exiting Visual C++ and restarting it caused it to work correctly but others it failed the same way. Here is an example CMakeLists.txt (Please note I just started using CMake, QT and ITK last week ...) PROJECT(LungAnalysis) IF(WIN32) CMAKE_MINIMUM_REQUIRED(VERSION 2.5 FATAL_ERROR) ENDIF(WIN32) SET (LIBRARY_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin CACHE INTERNAL Single output directory for building all libraries.) SET (EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin CACHE INTERNAL Single output directory for building all executables.) FIND_PACKAGE( Qt4 REQUIRED ) FIND_PACKAGE( ITK REQUIRED ) INCLUDE_DIRECTORIES( ${QT_INCLUDE_DIR} ) INCLUDE( ${QT_USE_FILE} ${ITK_USE_FILE} ) SET( UPMC_LA_SRCS ./main.cxx ./mainwindow.cxx ./textwidget.cxx ) SET( UPMC_LA_MOC_HDR ./mainwindow.h ./textwidget.h ) # and finally an resource file SET( UPMC_LA_RCS ./rc/LungAnalysis.qrc ) # this command will generate rules that will run rcc on all files from UPMC_LA_RCS # in result UPMC_LA_RC_SRCS variable will contain paths to files produced by rcc QT4_ADD_RESOURCES( UPMC_LA_RC_SRCS ${UPMC_LA_RCS} ) # and finally this will run moc: QT4_WRAP_CPP( UPMC_LA_MOC_SRCS ${UPMC_LA_MOC_HDR} ) LINK_LIBRARIES ( LungAnalysis ${QT_LIBRARIES} ) IF(COMMAND cmake_policy) cmake_policy(SET CMP0003 NEW) endif(COMMAND cmake_policy) ADD_EXECUTABLE( LungAnalysis ${UPMC_LA_SRCS} ${UPMC_LA_MOC_SRCS} ${UPMC_LA_MOC_HDR} ${UPMC_LA_RC_SRCS} ) Thanks in Advance, John ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake