[CMake] CMake and Eclipse Luna
I'm using CMake 3.02 through CMake GUI. I have a CMake project which I want to build using Eclipse Luna (the most recent eclipse). But the GUI doesn't present me with that option. I tried to use the latest one (Helios) but it seems that it won't work with this option. What should I do in order to build my project with Eclipse Luna Robert Ramey -- View this message in context: http://cmake.3232098.n2.nabble.com/CMake-and-Eclipse-Luna-tp7589778.html Sent from the CMake mailing list archive at Nabble.com. -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake
Re: [CMake] CMake and Eclipse Luna
On Tuesday, February 17, 2015 10:28:26 Robert Ramey wrote: I'm using CMake 3.02 through CMake GUI. I have a CMake project which I want to build using Eclipse Luna (the most recent eclipse). But the GUI doesn't present me with that option. I tried to use the latest one (Helios) but it seems that it won't work with this option. What should I do in order to build my project with Eclipse Luna Helios should be Ok (I'll update it soon to add Luna). What doesn't work ? Alex -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake
[CMake] Cmake(3.0.2) Eclipse project indexing issues under linux
Hi, After generating Eclipse projects and importing them, Eclipse is not indexing all source files. I have detailed the issue (so sorry for the long email) and the experiments I have performed to resolve the issue. I would be really glad if someone could point out, what is going wrong or is there some bug? Not to go in too much details, here is how my directory (project) structure looks like in order to explain the issue in more details: Sources: *$someDir/common/project_a/src/source_a.cpp* *$someDir/common/project_a/CMakeLists.tx*t - Project A is a common lib, uses by many tests *$someDir/tests/test_a/src/test_a.cpp* *$someDir/tests/test_a/CMakeLists.txt* - Includes the Project A using add_subdirectory and creates a share object Cmake build directories: *$someDir/cmakeOut/**common/project_a/* *$someDir/cmakeOut/tests/test_a/* Cmake generated everything without errors and building the project using make or Eclipse was not an issue. The issue is only when I import the project in Eclipse (version 4.3.2) by *Import - General - Existing Project - $someDir/cmakeOut/tests/test_a/*, the indexer does not seem to be working properly. It only indexes one source (test_a.cpp) whereas it should index two (test_a.cpp + sourc_a.cpp). this is just an example setup, in my actual project, only 1 source file gets indexed out of the 142 it should do. therefore it makes using Eclipse very hard! Now this is what I noticed with my experiments. *Experiment 1*: Change cmake version and compare I used the exact same files and folder structure but changed the cmake version to 2.8.10.2. The generated Eclipse project was able to index both the source files! This was mind boggling. I have to use the cmake 3.0.2 version, so I tried to narrow down the issue. When I did the diff of the .cproject created by the two cmake version I saw this: cmake 3.0.2 has this in the .cproject *pathentry kind=src path=[Source directory]/* pathentry excluding=*[Source directory]/|***/CMakeFiles/ kind=out path=/ cmake 2.8.10.2 has this in the .cproject pathentry excluding=**/CMakeFiles/ kind=out path=/ The rest of the file is similar (except cmake path, which is obvious). *Success Result*: If I delete the line *pathentry kind=src path=[Source directory]/ *from the .cproject and then import the project, indexing seems to be working!!! however I cant use this solution as my project is not checked in and every body using it needs to make this step manually. *Experiment 2*: Change the import method After a lot of googling I found out that someone was suggesting to import the project using this method (BTW, for totally different problem): *Import - C/C++ - Existing Code as Makefile Project - $someDir/cmakeOut/tests/test_a/ *. When I did this, it again works! Mind boggling yet again! Just by chance I found out that this method works because, by importing this way Eclipse somehow modifies the .cproject and removed the lines like I did in first experiment. *Conclusion*: So based on my experiments this line in the .cproject is causing an issue with indexing: *pathentry kind=src path=[Source directory]/* I know most likely my conclusion is not correct but I do not have any other explanation. Also I do not know why this line is actually the issue! Therfore I am writing to you all to understand the issue a bit better. Maybe the issue is elsewhere. Thanks in advance! -- Best Regards, Tushar Soni -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake
Re: [CMake] Cmake(3.0.2) Eclipse project indexing issues under linux
Hi, thanks for your detailled findings. Can you please create a ticket in the bug tracker with this, so it doesn't get lost ? http://public.kitware.com/Bug Thanks Alex On Monday, October 06, 2014 14:30:06 Tushar Soni wrote: Hi, After generating Eclipse projects and importing them, Eclipse is not indexing all source files. I have detailed the issue (so sorry for the long email) and the experiments I have performed to resolve the issue. I would be really glad if someone could point out, what is going wrong or is there some bug? Not to go in too much details, here is how my directory (project) structure looks like in order to explain the issue in more details: Sources: *$someDir/common/project_a/src/source_a.cpp* *$someDir/common/project_a/CMakeLists.tx*t - Project A is a common lib, uses by many tests *$someDir/tests/test_a/src/test_a.cpp* *$someDir/tests/test_a/CMakeLists.txt* - Includes the Project A using add_subdirectory and creates a share object Cmake build directories: *$someDir/cmakeOut/**common/project_a/* *$someDir/cmakeOut/tests/test_a/* Cmake generated everything without errors and building the project using make or Eclipse was not an issue. The issue is only when I import the project in Eclipse (version 4.3.2) by *Import - General - Existing Project - $someDir/cmakeOut/tests/test_a/*, the indexer does not seem to be working properly. It only indexes one source (test_a.cpp) whereas it should index two (test_a.cpp + sourc_a.cpp). this is just an example setup, in my actual project, only 1 source file gets indexed out of the 142 it should do. therefore it makes using Eclipse very hard! Now this is what I noticed with my experiments. *Experiment 1*: Change cmake version and compare I used the exact same files and folder structure but changed the cmake version to 2.8.10.2. The generated Eclipse project was able to index both the source files! This was mind boggling. I have to use the cmake 3.0.2 version, so I tried to narrow down the issue. When I did the diff of the .cproject created by the two cmake version I saw this: cmake 3.0.2 has this in the .cproject *pathentry kind=src path=[Source directory]/* pathentry excluding=*[Source directory]/|***/CMakeFiles/ kind=out path=/ cmake 2.8.10.2 has this in the .cproject pathentry excluding=**/CMakeFiles/ kind=out path=/ The rest of the file is similar (except cmake path, which is obvious). *Success Result*: If I delete the line *pathentry kind=src path=[Source directory]/ *from the .cproject and then import the project, indexing seems to be working!!! however I cant use this solution as my project is not checked in and every body using it needs to make this step manually. *Experiment 2*: Change the import method After a lot of googling I found out that someone was suggesting to import the project using this method (BTW, for totally different problem): *Import - C/C++ - Existing Code as Makefile Project - $someDir/cmakeOut/tests/test_a/ *. When I did this, it again works! Mind boggling yet again! Just by chance I found out that this method works because, by importing this way Eclipse somehow modifies the .cproject and removed the lines like I did in first experiment. *Conclusion*: So based on my experiments this line in the .cproject is causing an issue with indexing: *pathentry kind=src path=[Source directory]/* I know most likely my conclusion is not correct but I do not have any other explanation. Also I do not know why this line is actually the issue! Therfore I am writing to you all to understand the issue a bit better. Maybe the issue is elsewhere. Thanks in advance! -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake
Re: [CMake] cmake from eclipse has error but cmake from shell works fine??!? help!
On Monday 17 August 2009, Steve Mathers wrote: I have a relatively simple cmake file that has generated a great big Makefile (and associated CMake files) that compiles my project just fine when I invoke it from the bash shell, simply by typing 'make'. When I configure eclipse to do the same thing (simply calling make in the same directory) it also works fine the first time. however, if I edit some code in eclipse and fire up the debuger again, it halts with some error. the error is non-descriptive, something like 'error 2', even in VERBOSE mode. What could possibly be different in eclipse that could cause it to work the first time, but halt with an error the next time, when only a single file needs to be rebuilt? yet the exact same command 'make' from the shell works every time... I tried copying my entire shell path into the eclipse debug config path - it didnt help. You need to post some more information, otherwise we can't help. What is the error message ? 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 from eclipse has error but cmake from shell works fine??!? help!
I have a relatively simple cmake file that has generated a great big Makefile (and associated CMake files) that compiles my project just fine when I invoke it from the bash shell, simply by typing 'make'. When I configure eclipse to do the same thing (simply calling make in the same directory) it also works fine the first time. however, if I edit some code in eclipse and fire up the debuger again, it halts with some error. the error is non-descriptive, something like 'error 2', even in VERBOSE mode. What could possibly be different in eclipse that could cause it to work the first time, but halt with an error the next time, when only a single file needs to be rebuilt? yet the exact same command 'make' from the shell works every time... I tried copying my entire shell path into the eclipse debug config path - it didnt help. (I notice that some of the commands generated by the Makefil are very long, like 400 characters - would that cause something about the eclipse environment to barf? Im clutching at straws here...) thanks! __ Find local businesses and services in your area with Yahoo!7 Local. Get started: http://local.yahoo.com.au ___ 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 2.6.0 - eclipse CDT - lib project
On Fri, Jun 6, 2008 at 6:14 PM, Olivier Tournaire wrote: Hi all, I am currently tring to import a cmake generated project in eclipse. This project is a lib, and eclipse does not seem to be able to load it. Everything works fine when importing an executable project (FileImportGeneralExisting projectEnd). When importing my lib project, The end button in unavailable. Is it a known problem or am I doing something wrong ? Hello Olivier, I'm the author of the cmake eclipse generator, although I have to admit I have never tested this case... If you make it work manually and send me the .project/.cproject I can work with you to add this support to the generator. Another question : how to set in CMakeLists.txt an option to build on N cores ? That is to say the equivalent of the -j option (which is now also supported by MSVC, from 2005 version) ? I'll let someone else help with this. This has nothing to do with the eclipse generator since it is an extended generator based on the makefiles one. Hence, if it works for the makefile generator it should work in eclipse. Last one : is it possible to create a CMakeLists.txt which handles a Debug and a Release configuration in the same project in eclipse ? The usual way to do this as far as I know is that you create a build directory for each: workspace |_source |_debug_build |_release_build Then, you can do the following and import the two resulting projects: cd debug_build cmake -DCMAKE_BUILD_TYPE:STRING=Debug ../source cd release_build cmake -DCMAKE_BUILD_TYPE:STRING=Release ../source Hope this helps. --Miguel ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
[CMake] cmake 2.6.0 - eclipse CDT - lib project
Hi all, I am currently tring to import a cmake generated project in eclipse. This project is a lib, and eclipse does not seem to be able to load it. Everything works fine when importing an executable project (FileImportGeneralExisting projectEnd). When importing my lib project, The end button in unavailable. Is it a known problem or am I doing something wrong ? Another question : how to set in CMakeLists.txt an option to build on N cores ? That is to say the equivalent of the -j option (which is now also supported by MSVC, from 2005 version) ? Last one : is it possible to create a CMakeLists.txt which handles a Debug and a Release configuration in the same project in eclipse ? Best regards, Olivier ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] cmake 2.6.0 - eclipse CDT - lib project
There is an option in the Build settings of your Eclipse Project in the Behavior tab where you can tell eclipse to compile on N number of threads. You can also directly set the -j [n] option by using a custom build command. As far as Debug and Release in the same project, Not sure. Probably depends on how you set up the project. I think there is an Eclipse Project generator in CMake 2.6. Give that a try and see what happens. I usually use cmake to generate the makefiles, then have eclipse just use that make file to build. You should probably just setup 2 build directories for debug and release and then manually switch between them in eclipse project settings. Maybe in the project build configurations in the eclipse project you can setup 2 custom build commands and then just point each custom build command to each of the 2 directories. As far as the import of the Lib project, don't know. Again, I use the Makefile Project' in eclipse and find that works ok. Mike On Fri, Jun 6, 2008 at 6:14 PM, Olivier Tournaire [EMAIL PROTECTED] wrote: Hi all, I am currently tring to import a cmake generated project in eclipse. This project is a lib, and eclipse does not seem to be able to load it. Everything works fine when importing an executable project (FileImportGeneralExisting projectEnd). When importing my lib project, The end button in unavailable. Is it a known problem or am I doing something wrong ? Another question : how to set in CMakeLists.txt an option to build on N cores ? That is to say the equivalent of the -j option (which is now also supported by MSVC, from 2005 version) ? Last one : is it possible to create a CMakeLists.txt which handles a Debug and a Release configuration in the same project in eclipse ? Best regards, Olivier ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake -- Mike Jackson imikejackson _at_ gee-mail dot com ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] CMake and eclipse
I gave that plugin a try out and while it is nice to graphically see the structure of a CMake file there did not seem to be any actual project management or any other features that I could figure out. I work with CMake and Eclipse (On OS X and Linux 64) all day long. You have already heard from one individual on his project setup so I will throw mine in. http://www.cmake.org/Wiki/CMake:Eclipse_UNIX_Tutorial Basically I primarily use the terminal with cmake/ccmake to generate the makefiles for my system, then use Eclipse in Makefile Project mode to do the actual development of code and compilation. As long as you are using a compiler that Eclipse understands, Eclipse will parse the compiler output and display errors and warnings for you. I find this works very well for my needs. I do second the idea of using http://www.cthing.com/CMakeEd.asp for a nice CMake editor. Within eclipse there are ways to create External Tools that could possibly bootstrap the whole process if needed. When working with Eclipse I _strongly_ recommend you put your build directory inside the top level of your project. Eclipse seems to work better that way. In the latest CMake CVS there are eclipse project generators. You are welcome to give those a try to see if they gel with your project layout needs. My basic Project setup is: -Project -src // All source files -Resources // All extra files the project needs -Build // Run cmake from in here (cmake ../) This works for _me_ in my situation. My projects can be viewed here: http://titanium.imts.us/. Also, a small bit of advice for those new to CMake: Watch how you name files and folders that might be at the top level of your project. Sometimes it is tempting to do something like: -Project -src // All source files -Resources // All extra files the project needs -cmake // Cmake related files in here -Build // Run cmake from in here (cmake ../) Problem with that is at some point you _will_ accidentally run cmake from within the project directory. CMake creates _lots_ of its own files. All with Cmake somewhere in the name. If you also have a top level folder with CMake in the name it can be difficult to figure out which files/folders need to be trashed. This is why is use Resources and then put some of my special cmake files in that folder. Just FYI. Welcome to the cmake community. --- Mike Jackson On Feb 2, 2008, at 6:52 PM, Giualian Sander wrote: Hi gents, I'm new to cmake, and I've found a project called CMakeBuilder (www.cmakebuilder.com) across the internet. I'm a C++/Autohell developer from years (let's says decades !) And I found interesting the visual approach of this tool, especially for understanding CMake structure and syntax. Even if it's beta right now, I think it brings some easy to learn- capability to CMake Do anyone of you know about the upcoming features as described on eclipseplugincentral.com ? I'm currently in charge of a from scratch project, working with a lot of eclipse/C++ developers, and I'm not willing to maintain a AutoHell configuration on such a scale. Thought I'm conviced that CMake is the right choice for me, is such a plugin a good choice for me ? Thanks for your advices BRgds Giualian Sander ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] CMake and eclipse
Hi Mike, Thanks a lot for your advices, I perfectly understand your point of view but in my case I'm willing to bring some capabilities to a population of developers (not necessarily hackers), that can enables us to abstract from the lowest layers of computing (usually autohell-handled). Your contribution, unfortunately, do'nt help me... Using CMake the way your example suggest, seems to me irrelevant for a 3 lines Makefile just do the trick. I need CMake for much more complex purposes... BRgds 2008/2/3, Mike Jackson [EMAIL PROTECTED]: I gave that plugin a try out and while it is nice to graphically see the structure of a CMake file there did not seem to be any actual project management or any other features that I could figure out. I work with CMake and Eclipse (On OS X and Linux 64) all day long. You have already heard from one individual on his project setup so I will throw mine in. http://www.cmake.org/Wiki/CMake:Eclipse_UNIX_Tutorial Basically I primarily use the terminal with cmake/ccmake to generate the makefiles for my system, then use Eclipse in Makefile Project mode to do the actual development of code and compilation. As long as you are using a compiler that Eclipse understands, Eclipse will parse the compiler output and display errors and warnings for you. I find this works very well for my needs. I do second the idea of using http://www.cthing.com/CMakeEd.asp for a nice CMake editor. Within eclipse there are ways to create External Tools that could possibly bootstrap the whole process if needed. When working with Eclipse I _strongly_ recommend you put your build directory inside the top level of your project. Eclipse seems to work better that way. In the latest CMake CVS there are eclipse project generators. You are welcome to give those a try to see if they gel with your project layout needs. My basic Project setup is: -Project -src // All source files -Resources // All extra files the project needs -Build // Run cmake from in here (cmake ../) This works for _me_ in my situation. My projects can be viewed here: http://titanium.imts.us/. Also, a small bit of advice for those new to CMake: Watch how you name files and folders that might be at the top level of your project. Sometimes it is tempting to do something like: -Project -src // All source files -Resources // All extra files the project needs -cmake // Cmake related files in here -Build // Run cmake from in here (cmake ../) Problem with that is at some point you _will_ accidentally run cmake from within the project directory. CMake creates _lots_ of its own files. All with Cmake somewhere in the name. If you also have a top level folder with CMake in the name it can be difficult to figure out which files/folders need to be trashed. This is why is use Resources and then put some of my special cmake files in that folder. Just FYI. Welcome to the cmake community. --- Mike Jackson On Feb 2, 2008, at 6:52 PM, Giualian Sander wrote: Hi gents, I'm new to cmake, and I've found a project called CMakeBuilder ( www.cmakebuilder.com) across the internet. I'm a C++/Autohell developer from years (let's says decades !) And I found interesting the visual approach of this tool, especially for understanding CMake structure and syntax. Even if it's beta right now, I think it brings some easy to learn-capability to CMake Do anyone of you know about the upcoming features as described on eclipseplugincentral.com ? I'm currently in charge of a from scratch project, working with a lot of eclipse/C++ developers, and I'm not willing to maintain a AutoHell configuration on such a scale. Thought I'm conviced that CMake is the right choice for me, is such a plugin a good choice for me ? Thanks for your advices BRgds Giualian Sander ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] CMake and eclipse
So here are the problems you are going to run into with Eclipse and CMake. There is no proper integration between CMake and Eclipse. There is no plugin that can manage the CMake file and the C++ project together. In other words, Eclipse has 2 types of Projects: Managed C+ + and Makefile. If you let Eclipse manage your project it will produce makefiles. This is NOT what you want. If you tell Eclipse you want a Makefile project, then _you_ have to generate the makefile for Eclipse. You can also tell Eclipse which makefile to use when Eclipse runs make to build the project. This is done as a custom build command. I usually use make -C ${project_loc}/Build for mine. If you have true out of source builds your build command might be make -C ${project_loc}/.../ProjectBuild. Eclipse CDT indexing can be tricky to get right. Make sure you understand how Eclipse defines its Paths and Symbols entries. Also, if you could elaborate on your Complex purposes the cmake community will be eager to help you solve those issues and come up the cmake learning curve quickly as possible. If you are cross-compiling there are some entries on the wiki about that. Respectfully Mike Jackson On Feb 3, 2008, at 5:38 PM, Giualian Sander wrote: Hi Mike, Thanks a lot for your advices, I perfectly understand your point of view but in my case I'm willing to bring some capabilities to a population of developers (not necessarily hackers), that can enables us to abstract from the lowest layers of computing (usually autohell-handled). Your contribution, unfortunately, do'nt help me... Using CMake the way your example suggest, seems to me irrelevant for a 3 lines Makefile just do the trick. I need CMake for much more complex purposes... BRgds 2008/2/3, Mike Jackson [EMAIL PROTECTED]: I gave that plugin a try out and while it is nice to graphically see the structure of a CMake file there did not seem to be any actual project management or any other features that I could figure out. I work with CMake and Eclipse (On OS X and Linux 64) all day long. You have already heard from one individual on his project setup so I will throw mine in. http://www.cmake.org/Wiki/CMake:Eclipse_UNIX_Tutorial Basically I primarily use the terminal with cmake/ccmake to generate the makefiles for my system, then use Eclipse in Makefile Project mode to do the actual development of code and compilation. As long as you are using a compiler that Eclipse understands, Eclipse will parse the compiler output and display errors and warnings for you. I find this works very well for my needs. I do second the idea of using http://www.cthing.com/CMakeEd.asp for a nice CMake editor. Within eclipse there are ways to create External Tools that could possibly bootstrap the whole process if needed. When working with Eclipse I _strongly_ recommend you put your build directory inside the top level of your project. Eclipse seems to work better that way. In the latest CMake CVS there are eclipse project generators. You are welcome to give those a try to see if they gel with your project layout needs. My basic Project setup is: -Project -src // All source files -Resources // All extra files the project needs -Build // Run cmake from in here (cmake ../) This works for _me_ in my situation. My projects can be viewed here: http://titanium.imts.us/. Also, a small bit of advice for those new to CMake: Watch how you name files and folders that might be at the top level of your project. Sometimes it is tempting to do something like: -Project -src // All source files -Resources // All extra files the project needs -cmake // Cmake related files in here -Build // Run cmake from in here (cmake ../) Problem with that is at some point you _will_ accidentally run cmake from within the project directory. CMake creates _lots_ of its own files. All with Cmake somewhere in the name. If you also have a top level folder with CMake in the name it can be difficult to figure out which files/folders need to be trashed. This is why is use Resources and then put some of my special cmake files in that folder. Just FYI. Welcome to the cmake community. --- Mike Jackson On Feb 2, 2008, at 6:52 PM, Giualian Sander wrote: Hi gents, I'm new to cmake, and I've found a project called CMakeBuilder (www.cmakebuilder.com) across the internet. I'm a C++/Autohell developer from years (let's says decades !) And I found interesting the visual approach of this tool, especially for understanding CMake structure and syntax. Even if it's beta right now, I think it brings some easy to learn-capability to CMake Do anyone of you know about the upcoming features as described on eclipseplugincentral.com ? I'm currently in charge of a from scratch project, working with a lot of eclipse/C++ developers, and I'm not willing to maintain a AutoHell configuration
RE: [CMake] cmake support Eclipse
I also think that Cmake, Ant and Eclipse are complementary. Each does an excellent job for what it is designed to do. I would extend Mikes list of features for Cmake eclipse integration: 1) CMakeErrorParser: This would add cmake build errors to the Problem view in eclipse. This means that when make calls cmake during the build, if there are errors in the cmake file, these errors appear in the problem view. Double clicking on a cmake error in the list would bring the user to the location of the error in the approprte cmake file. I have a created a proof of concept plugin for this however I currently do not have time to finish it. If anyone is interested in looking at the code to do this send me an email and I will forward it on. 2) A Cmake ant task: This would allow developers to easily call cmake to generate make files from within an ant script. Cmake and make are great at building c++ (and other gcc languages), however for large build env with lots of project types ant is great at gluing it all together (as well as just building java). We have used ant to automate the build of our (500+) VC++ projects for the last three years. I am currently moving some of these projects to Cmake to support a unix port, my next phase is to integrate Cmake with our existing ant build. I am sure I can use an exec task but a dedicated task would be much nicer. Here is a rough outline of what I mean, there are probably some gaps here so don't be too critical. The first task cmake calls cmake to generate the make files or projects. The second task cmakebuild knows what build type cmake has generated and how to execute that build. Eg target name=buildCPlusPlus cmake srcdir=cplusplus/source bindir=cplusplus/buildoutput / cmakebuild bindir=cplusplus/buildoutput / /target Iain. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Mike Jackson Sent: 31 July 2007 15:42 To: Cmake Mailing List; Mike Jackson Subject: Re: [CMake] cmake support Eclipse These are my _thoughts_ on what I would like to see as a first cut at CMake/Eclipse integration. As someone has already done in the past day, basically have cmake generate a CDT Makefile project that sets up the .project/.cproject files for eclipse to invoke make on the makefiles that are generated by Cmake. I think this is going to be the best way to go about this due to limitations on how a ManagedMakefile project is used in Eclipse. Also, if the include paths can be preset in the eclipse project file based on what is in the CMakeLists.txt file this is one more added bonus. Add into the project file the exectuables so I don't have to add them in eclipse each time. Next, Implement the ccmake program as an Eclipse Plugin so that I can run ccmake from within eclipse. The interface that our windows brethren get with CMakeSetup would suffice for this. This plugin is written in Java and would use the Eclipse PDE as its project management. Version 3: Implement some CMake Wizards that would help a cmake newbie generate a basic CMakeLists.txt file. These wizards are just for basic projects and help to generate a properly working CMakeLists.txt file. After that the programmer can use the cmake documentation to enhance/add-to their cmake files. All this would be a great start. I agree with an earlier posting about trying to have eclipse use CMake for its project management. It is going to be a long difficult road. If the above it completed first, and done well, then you have a decent chance of getting the CDT project leads behind CMake. BTW, the project leads do embedded C/C ++ development so getting them to switch to CMake would be a great first step.. ;-) Again, these are just my thoughts on what I would like to see in an Eclipse Generator -- Mike Jackson Senior Research Engineer Innovative Management Technology Services ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
RE: [CMake] cmake support Eclipse
1) CMakeErrorParser... I have a created a proof of concept plugin for this however I currently do not have time to finish it. If anyone is interested in looking at the code to do this send me an email and I will forward it on. I am looking at the CMake Editor Plug-in. now and will submit my CMakeErrorParser as it stands as a patch for this. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Iain Hull Sent: 01 August 2007 10:12 To: Mike Jackson; Cmake Mailing List; Mike Jackson Subject: RE: [CMake] cmake support Eclipse I also think that Cmake, Ant and Eclipse are complementary. Each does an excellent job for what it is designed to do. I would extend Mikes list of features for Cmake eclipse integration: 1) CMakeErrorParser: This would add cmake build errors to the Problem view in eclipse. This means that when make calls cmake during the build, if there are errors in the cmake file, these errors appear in the problem view. Double clicking on a cmake error in the list would bring the user to the location of the error in the approprte cmake file. I have a created a proof of concept plugin for this however I currently do not have time to finish it. If anyone is interested in looking at the code to do this send me an email and I will forward it on. 2) A Cmake ant task: This would allow developers to easily call cmake to generate make files from within an ant script. Cmake and make are great at building c++ (and other gcc languages), however for large build env with lots of project types ant is great at gluing it all together (as well as just building java). We have used ant to automate the build of our (500+) VC++ projects for the last three years. I am currently moving some of these projects to Cmake to support a unix port, my next phase is to integrate Cmake with our existing ant build. I am sure I can use an exec task but a dedicated task would be much nicer. Here is a rough outline of what I mean, there are probably some gaps here so don't be too critical. The first task cmake calls cmake to generate the make files or projects. The second task cmakebuild knows what build type cmake has generated and how to execute that build. Eg target name=buildCPlusPlus cmake srcdir=cplusplus/source bindir=cplusplus/buildoutput / cmakebuild bindir=cplusplus/buildoutput / /target Iain. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Mike Jackson Sent: 31 July 2007 15:42 To: Cmake Mailing List; Mike Jackson Subject: Re: [CMake] cmake support Eclipse These are my _thoughts_ on what I would like to see as a first cut at CMake/Eclipse integration. As someone has already done in the past day, basically have cmake generate a CDT Makefile project that sets up the .project/.cproject files for eclipse to invoke make on the makefiles that are generated by Cmake. I think this is going to be the best way to go about this due to limitations on how a ManagedMakefile project is used in Eclipse. Also, if the include paths can be preset in the eclipse project file based on what is in the CMakeLists.txt file this is one more added bonus. Add into the project file the exectuables so I don't have to add them in eclipse each time. Next, Implement the ccmake program as an Eclipse Plugin so that I can run ccmake from within eclipse. The interface that our windows brethren get with CMakeSetup would suffice for this. This plugin is written in Java and would use the Eclipse PDE as its project management. Version 3: Implement some CMake Wizards that would help a cmake newbie generate a basic CMakeLists.txt file. These wizards are just for basic projects and help to generate a properly working CMakeLists.txt file. After that the programmer can use the cmake documentation to enhance/add-to their cmake files. All this would be a great start. I agree with an earlier posting about trying to have eclipse use CMake for its project management. It is going to be a long difficult road. If the above it completed first, and done well, then you have a decent chance of getting the CDT project leads behind CMake. BTW, the project leads do embedded C/C ++ development so getting them to switch to CMake would be a great first step.. ;-) Again, these are just my thoughts on what I would like to see in an Eclipse Generator -- Mike Jackson Senior Research Engineer Innovative Management Technology Services ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] cmake support Eclipse CDT
2007/7/31, Brandon Van Every [EMAIL PROTECTED]: On 7/30/07, Andreas Pakulat [EMAIL PROTECTED] wrote: Of course CDT still uses the java-written eclipse platform sdk, but it doesn't have anything else to do with Java. So you're writing a plugin in Java to integrate CMake with Eclipse. Well, don't you think you should use CMake to build the Java plugin? No certainly not. You are building an ECLIPSE plugin. You should use Eclipse for it. CMake may generate the project file for that but I think this should not be a primary target. If you use some non-CMake tool to build the CMake support, you risk CDT developers saying what is this lame CMake build system that can't even handle Java? We'd rather support Ant. The CMake vs Ant comparison is misleading. As far as I know Ant is not able to generate Visual Studio project files nor KDevelop project file or even Eclipse Project file either!! I think Ant will never go along this path. Ant is a better make geared toward java build and does not compare to CMake. When you build an Eclipse Plugin you SHOULD use Eclipse because it was built just for that (being extensible with plugin). Trying to get CMake into the middle seems awkward to me. Would you use CMake to build a GUI you build with Visual Studio or Glade? I'm an advocate of the right tool for the appropriate task don't try to get CMake do everything one may need. -- Erk ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] cmake support Eclipse
I have been following this thread and I guess it is time to chime it a bit with what I know. First my background. I used Eclipse since '03 for Java development then switched in mid '06 to C++ development with Eclipse/CDT so I have a fair amount of experience with Eclipse, Ant and about a year of full time CDT and CMake. I am just going to rattle off some answers/corrections to the various items that have been posted in this thread: Eclipse Plugin Development: Usually you develop a plugin for Eclipse using their PDE (Plugin Development Environment). This is almost certainly going to be written in Java with maybe a small JNI module if you absolutely need to jump across the Java/Native bridge to do something in the C++ world. Eclipse will manage the build of your plugin using what ever build mechanism Eclipse uses for Java. CDT Projects: There are 2 kinds of CDT projects; 'Managed Makefile' and 'Makefile'. In the 'Managed Makefile' project Eclipse basically does the project management for you and then creates a Makefile behind the scenes and then invokes that makefile to build your project. In a 'Makefile' project you bring your own makefile to the project. CDT just provides the IDE environment. The major downside to the 'Managed Makefile' project is that there is really only 1 'Target' in your project, so anything past a basic hello World or Hello Library is beyond the capability of CDT (at least how I understand it), which is why I am guess that most people use the Makefile project so they can have 1 project with lots of targets ( Library, Executable, Testing harness). Right Tool for the Right Job: As stated in previous messages, CMake is a great Generator of 'project files' ( Makefile, Xcode, VS, Nmake) for typically C/C++ projects. ( I have no experience with any other language + CMake). Ant is a just as awesome build system for Java. Use the right tool for the right job. If I am doing Java Dev, CMake will NEVER enter the picture. If I am doing C/C++ dev then Ant will NEVER enter the picture. If CMake generated an Ant xml file for java projects then you may be onto something. Cmake File Editing: There is a plugin at http://www.cthing.com/ CMakeEd.asp that adds a nice editor to Eclipse that makes editing CMake files easier. It offers syntax highlighting, command completion and integrated documentation. Very nicely done. Current CMake/Eclipse Integration: http://www.cmake.org/Wiki/ CMake:Eclipse (which I wrote) goes over the current state of affairs in using CMake with Eclipse. Generally after bootstrapping the process things are pretty smooth as cmake will make sure your makefiles are up to date if you change the CMakeLists.txt file. Where things are NOT smooth is if you are making MAJOR changes to your CMakeLists.txt files then I find that I need to use an external Terminal program to clean things out and re-invoke ccmake to set my project up again. On the Eclipse download page http://www.eclipse.org/downloads/ there is a specific selection to download just the base eclipse + CDT without all the extra java IDE stuff. This works rather nicely. If you need to have some XML editing capability (say for paraview development) then you can easily download the proper XML editors for that function. opinionCMake would have an extremely difficult time luring java developers from Ant or Maven to use Cmake for a build system and vice versa, Ant would have a difficult time luring c/c++ developers from cmake. Each party should concentrate on what they do best./opinion Sorry for top posting.. -- Mike Jackson Senior Research Engineer Innovative Management Technology Services On Jul 31, 2007, at 3:05 AM, Eric Noulard wrote: 2007/7/31, Brandon Van Every [EMAIL PROTECTED]: On 7/30/07, Andy Dingfelder [EMAIL PROTECTED] wrote: Building java apps it typically done using Maven or Ant, and I see no need to re-invent the wheel and use cmake to do that. I do. If you want Eclipse developer mindshare, then ultimately you want CMake to work as a Java build tool as well. I'm following this interesting thread and here I must say that I disagree. CMake I think should never became A Java build tool CMake may add java support which may end up in generating ant build files. Ant is a build tool which may be compared to make (ant is much much much nicer and powerful than make though) CMake (from my point of view) is a build tool GENERATOR. You may not need any of that at first, but you aren't going to get a snowball of support unless CMake is handling basic Java builds. That's the strategic risk. Strategically, if Ant figures out how to do C/C++, Ant already does, see cc Task: http://ant-contrib.sourceforge.net/cc.html and CMake doesn't figure out how to do Java, then CMake will lose in the Eclipse world. Not so sure, even if I'm no eclipse expert. If CMake is able to generate Eclipse project files
Re: [CMake] cmake support Eclipse
2007/7/31, Brandon Van Every [EMAIL PROTECTED]: On 7/31/07, Eric Noulard [EMAIL PROTECTED] wrote: 2007/7/31, Brandon Van Every [EMAIL PROTECTED]: and CMake doesn't figure out how to do Java, then CMake will lose in the Eclipse world. Not so sure, even if I'm no eclipse expert. If CMake is able to generate Eclipse project files and/or with eventual Ant build files then I'm pretty sure CMake will get in the Eclipse world very soon. Oh come on, you think anyone's going to bother to support such major tasks if CMake doesn't speak Java reasonably well? Yes I think a lot of Eclipse/CDT user won't ever need CMake Java support. I think you underestimate what Ant and the wealth of optional tasks are able to do, I suggest you go to http://ant.apache.org/manual/ and browse tasks. You'll see that high level ant tasks enables you to do ftp, ssh, scp, cvs, subversion, rpm building in a easy way. As far as I know CMake does not have those capabilities. ADD_CUSTOM_TARGET ADD_CUSTOM_TARGET and/or EXECUTE_PROCESS won't be as portable and as powerful as a custom Ant task can be. From within ADD_CUSTOM_TARGET you have limited programmatic possibility in comparison with Java used for custom ant task. From my experience I have to write platform specific ADD_CUSTOM_TARGET for different platforms, at least one for Windows and one for Un*x whereas custom ant task may be written in a java-portable fashion. Be assured I am a pro-cmake user, but I look at CMake and Ant with a different point if view. -- Erk ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] cmake support Eclipse
These are my _thoughts_ on what I would like to see as a first cut at CMake/Eclipse integration. As someone has already done in the past day, basically have cmake generate a CDT Makefile project that sets up the .project/.cproject files for eclipse to invoke make on the makefiles that are generated by Cmake. I think this is going to be the best way to go about this due to limitations on how a ManagedMakefile project is used in Eclipse. Also, if the include paths can be preset in the eclipse project file based on what is in the CMakeLists.txt file this is one more added bonus. Add into the project file the exectuables so I don't have to add them in eclipse each time. Next, Implement the ccmake program as an Eclipse Plugin so that I can run ccmake from within eclipse. The interface that our windows brethren get with CMakeSetup would suffice for this. This plugin is written in Java and would use the Eclipse PDE as its project management. Version 3: Implement some CMake Wizards that would help a cmake newbie generate a basic CMakeLists.txt file. These wizards are just for basic projects and help to generate a properly working CMakeLists.txt file. After that the programmer can use the cmake documentation to enhance/add-to their cmake files. All this would be a great start. I agree with an earlier posting about trying to have eclipse use CMake for its project management. It is going to be a long difficult road. If the above it completed first, and done well, then you have a decent chance of getting the CDT project leads behind CMake. BTW, the project leads do embedded C/C ++ development so getting them to switch to CMake would be a great first step.. ;-) Again, these are just my thoughts on what I would like to see in an Eclipse Generator -- Mike Jackson Senior Research Engineer Innovative Management Technology Services ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] cmake support Eclipse CDT
On 7/30/07, Andreas Pakulat [EMAIL PROTECTED] wrote: Of course CDT still uses the java-written eclipse platform sdk, but it doesn't have anything else to do with Java. So you're writing a plugin in Java to integrate CMake with Eclipse. Well, don't you think you should use CMake to build the Java plugin? If you use some non-CMake tool to build the CMake support, you risk CDT developers saying what is this lame CMake build system that can't even handle Java? We'd rather support Ant. We're talking about inculcating CMake into the Eclipse culture here. Cheers, Brandon Van Every ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] cmake support Eclipse
On 7/30/07, Andy Dingfelder [EMAIL PROTECTED] wrote: You are correct in your thoughts that the individual who writes a cmake plugin would need to know java. Yes as you point out there is always a risk that perhaps cmake will not be up to the task of large scale cross platform development and perhaps the individuals who work to get it integrated will get annoyed and not support it, but given the size of the CDT userbase I think there are enough eclipse using c++ users out there to take the risk. I am not familiar with all the ins and outs of cmake but I suspect it is up to the task, and any issues would just be implementation details to work out. What's a non-trivial Java app that's using a CMake build? Dart2 server perhaps? My thoughts were that ant was more java centric, whereas cmake is c++ centric and would be a better fit for the CDT. CMake only has to be elegant enough to address the needs of a CDT implementor. Which might be substantial, actually, I don't know. Eclipse is a big project. Cheers, Brandon Van Every ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] cmake support Eclipse
What's a non-trivial Java app that's using a CMake build? Dart2 server perhaps? I don't know any java apps that are built using cmake if thats what you mean. Building java apps it typically done using Maven or Ant, and I see no need to re-invent the wheel and use cmake to do that. All cmake needs to do to meet my needs is build C++ code, which it does very well from what I have seen. CMake only has to be elegant enough to address the needs of a CDT implementor. Which might be substantial, actually, I don't know. Eclipse is a big project. I do not see what the size of eclipse has to do with how cmake would work. The point I was making before is that the implementor who tries to integrate cmake into CDT would treat it the same way that the maven plugin developers treated maven... They made the plugin use the build system as is instead of trying to make it fit Eclipse, so that builds done from within the IDE could also still be done from the command line. In the same sense, I do not think cmake should change to meet Eclipse's needs, therefore the elegance of cmake is not the question. If cmake becomes more elegant, so much the better, but it should not be done to make the CDT better, it should be done for cmake as a whole. My vision for a cmake plugin would be as an administrative tool that eases the creation of the CMakeLists.txt file and the running of ccmake. Basically, there would be a GUI screen or wizard that would ask questions such as what OS you want to target, what files to include, and what toolchain to use, and then you could simply tell eclipse to do a build and it would use cmake to build all the appropriate targets. WARNING: This email and any attachments may be confidential and/or privileged. They are intended for the addressee only and are not to be read, used, copied or disseminated by anyone receiving them in error. If you are not the intended recipient, please notify the sender by return email and delete this message and any attachments. The views expressed in this email are those of the sender and do not necessarily reflect the official views of Landcare Research. SirTrack http://www.sirtrack.com ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] cmake support Eclipse
On 31.07.07 12:12:17, Andy Dingfelder wrote: My vision for a cmake plugin would be as an administrative tool that eases the creation of the CMakeLists.txt file and the running of ccmake. Basically, there would be a GUI screen or wizard that would ask questions such as what OS you want to target, what files to include, and what toolchain to use, and then you could simply tell eclipse to do a build and it would use cmake to build all the appropriate targets. There's one problem with this GUI approach: It never scales, especially for buildsystems such as CMake. I've written a good part of KDevelop3's QMake Manager (a GUI on top of the QMake buildsystem, which is more limited than CMake and the advanced features are also not so well known) and one thing I've learned is: You can provide a good GUI for beginners who just want to add a bunch of files and get a binary/library. Even adding includes and libraries can be made to work with a GUI (as in lists, editlines, fileselectors). But for real world complex projects that utilize such buildsystem to their full extent another approach seems much more promising (instead of trying to squeeze each aspect of the language into a GUI): Treat it as a language, that is let the user write the CMakeLists.txt files directly, but provide help in editing them. For CMake this means syntax highlighting, completion of macro's, suggesting possible options and so on. Andreas -- Do something unusual today. Pay a bill. ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] cmake support Eclipse
On 7/30/07, Andy Dingfelder [EMAIL PROTECTED] wrote: What's a non-trivial Java app that's using a CMake build? Dart2 server perhaps? I don't know any java apps that are built using cmake if thats what you mean. Looks like Dart2 is an Ant project. VTK has a Java wrapper but it doesn't use PROJECT(myproj Java) to do any of the wrapping. I do see one Java test in the CMake source tree that uses PROJECT(blah Java). It makes a Hello World with essentially one command, ADD_LIBRARY(hello A.java HelloWorld.java). I don't know beans about Java; is everything in Java a library? I guess you don't have binary executables, so no ADD_EXECUTABLE, but it seems funny to call hello a library. Building java apps it typically done using Maven or Ant, and I see no need to re-invent the wheel and use cmake to do that. I do. If you want Eclipse developer mindshare, then ultimately you want CMake to work as a Java build tool as well. You may not need any of that at first, but you aren't going to get a snowball of support unless CMake is handling basic Java builds. That's the strategic risk. Strategically, if Ant figures out how to do C/C++, and CMake doesn't figure out how to do Java, then CMake will lose in the Eclipse world. All cmake needs to do to meet my needs is build C++ code, which it does very well from what I have seen. You may want to look beyond your immediate needs though. You started this thread with thoughts of what's profitable to strategically invest in. I certainly wouldn't begrudge you knocking out *any* form of CMake Eclipse plugin. This is open source, so whatever turns you on. But some approaches are more likely to get accepted by large numbers of people than others. Bootstrapping CMake is more cool than using Ant to take care of what CMake is supposed to take care of. Coolness inspires. CMake only has to be elegant enough to address the needs of a CDT implementor. Which might be substantial, actually, I don't know. Eclipse is a big project. I do not see what the size of eclipse has to do with how cmake would work. I do not know what Java trickery one needs to do to build an Eclipse plugin. I hope it is easy and aesthetically satisfying when done with CMake. Cheers, Brandon Van Every ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
Hi Alex, There is a new class cmExternalMakefileProjectGenerator, which can be subclassed and be used to create project files for your prefered IDE. This is really cool! I have implemented such a makefile-based generator with additional IDE-files and it was quite annoying to set it up. Basically because you could not just reuse an existing makefile-generator and simply add the code to generate the IDE-files. I'll give it a try. Cheers! Marco ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
Hi, CMake cvs now makes adding generators for IDEs which work with external makefiles easier. There is a new class cmExternalMakefileProjectGenerator, which can be subclassed and be used to create project files for your prefered IDE. This is currently done that way with the KDevelop generator (for UNIX). The UNIX Makefile generator generates all the makefiles as usual, and after that the KDevelop generator runs and creates the xml project files for kdevelop which basically set up the directories, targets and source files part of this project. Since Eclipse supports also projects with existing makefiles, it should be not hard to write such an generator for this kind of Eclipse projects. Then you could simply run cmake -GMingw Makefile - Eclipse and you will get everything set up for Eclipse. If you are interested, it would be nice if you could go ahead and try it and ask if you have questions. Alex ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
Not sure if I am going to get the time to try it out in the near future, though it is good to see a generator for eclipse. Not sure if there will be any changes needed when Eclipse 3.3/CDT4.0 finally arrive in the next few weeks. Nice Effort though. Keep up the good work. -- Mike Jackson Senior Research Engineer Innovative Management Technology Services On Jun 21, 2007, at 1:25 PM, Alexander Neundorf wrote: Hi, CMake cvs now makes adding generators for IDEs which work with external makefiles easier. There is a new class cmExternalMakefileProjectGenerator, which can be subclassed and be used to create project files for your prefered IDE. This is currently done that way with the KDevelop generator (for UNIX). The UNIX Makefile generator generates all the makefiles as usual, and after that the KDevelop generator runs and creates the xml project files for kdevelop which basically set up the directories, targets and source files part of this project. Since Eclipse supports also projects with existing makefiles, it should be not hard to write such an generator for this kind of Eclipse projects. Then you could simply run cmake -GMingw Makefile - Eclipse and you will get everything set up for Eclipse. If you are interested, it would be nice if you could go ahead and try it and ask if you have questions. Alex ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
[CMake] Cmake with Eclipse
Dear all, I want to integrate cmake with the ECLIPSE IDE and cdt. To be honest I am a beginner and therefore I have not really an idea on how to handle it. I use MinGW with WinXP to develop under Windows. It would be very nice if somebody can help me on how to set up Eclipse to use cmake to generate the Makefiles for mingw and the g++ compiler. Thank you very much in advance. Joachim ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
2007/6/5, Joachim Zettler [EMAIL PROTECTED]: Dear all, I want to integrate cmake with the ECLIPSE IDE and cdt. To be honest I am a beginner and therefore I have not really an idea on how to handle it. I use MinGW with WinXP to develop under Windows. It would be very nice if somebody can help me on how to set up Eclipse to use cmake to generate the Makefiles for mingw and the g++ compiler. Did you you look at: http://www.cmake.org/Wiki/CMake_Editors_Support there is a nice paragraph on Using CMake from Eclipse CDT for CMake + mingw usage I think you may search the Mailing List archive which should contains many messages on the subject. -- Erk ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
http://www.cmake.org/Wiki/CMake_Editors_Support There is an entry for using CMake with Eclipse. The wiki article is written assuming Unix/Linux/OS X but there should be no reason why the same would not work for MinGW. Note I have NOT tried it. The basics are: 1: Use CMake on Windows to generate the MinGW Makefiles 2: Launch Eclipse and create a Standard C++ Makefile Project 3: Edit the Make settings to point to the mingw32make executable and the MakeFile generated by CMake. I will leave the rest as an exercise to the reader. -- Mike Jackson Senior Research Engineer Innovative Management Technology Services On Jun 5, 2007, at 9:03 AM, Joachim Zettler wrote: Dear all, I want to integrate cmake with the ECLIPSE IDE and cdt. To be honest I am a beginner and therefore I have not really an idea on how to handle it. I use MinGW with WinXP to develop under Windows. It would be very nice if somebody can help me on how to set up Eclipse to use cmake to generate the Makefiles for mingw and the g+ + compiler. Thank you very much in advance. Joachim ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
Dear all, thank you for your help up to now. I followed the tutorials you provided to me and made a Standard C++ makefile project. Afterwards I tried to adjust the make command but it is not working. Here you can find the command. mingw32-make -f build\Makefile The makefile is actually in a build folder and i generated it before with cmake -G MinGW Makefiles. Now it seems that the build\makefile is not working. Also build/makefile is wrong. I dont want to write the full path because it depends on which pc I actually work. Up to now I also create the makefile myself everytime I change something in the cmakelist.txt. I have read about an option to run external tools but I dont know exactly how to implement this so that cmake is running only when something cmakelist has changed. Is there also a possibility to choose between release and debug? In vc++ this was very easy to handle :) I know that some of the questions might be stupid but up to now I am still learning :) Thank you in advance. Joachim 2007/6/5, Mike Jackson [EMAIL PROTECTED]: http://www.cmake.org/Wiki/CMake_Editors_Support There is an entry for using CMake with Eclipse. The wiki article is written assuming Unix/Linux/OS X but there should be no reason why the same would not work for MinGW. Note I have NOT tried it. The basics are: 1: Use CMake on Windows to generate the MinGW Makefiles 2: Launch Eclipse and create a Standard C++ Makefile Project 3: Edit the Make settings to point to the mingw32make executable and the MakeFile generated by CMake. I will leave the rest as an exercise to the reader. -- Mike Jackson Senior Research Engineer Innovative Management Technology Services On Jun 5, 2007, at 9:03 AM, Joachim Zettler wrote: Dear all, I want to integrate cmake with the ECLIPSE IDE and cdt. To be honest I am a beginner and therefore I have not really an idea on how to handle it. I use MinGW with WinXP to develop under Windows. It would be very nice if somebody can help me on how to set up Eclipse to use cmake to generate the Makefiles for mingw and the g++ compiler. Thank you very much in advance. Joachim ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
On 6/5/07, Joachim Zettler [EMAIL PROTECTED] wrote: Dear all, thank you for your help up to now. I followed the tutorials you provided to me and made a Standard C++ makefile project. Afterwards I tried to adjust the make command but it is not working. Here you can find the command. mingw32-make -f build\Makefile The makefile is actually in a build folder and i generated it before with cmake -G MinGW Makefiles. Now it seems that the build\makefile is not working. Can you be more specific? What is the output of mingw32-make VERBOSE=1 ? Also build/makefile is wrong. I dont want to write the full path because it depends on which pc I actually work. CMake outputs absolute paths that only work in the target environment. You will have to generate new Makefiles on each specific machine you use. It's not wrong, it's a design choice. Many things can go wrong when you don't use absolute paths in a build. Up to now I also create the makefile myself everytime I change something in the cmakelist.txt. I have read about an option to run external tools but I dont know exactly how to implement this so that cmake is running only when something cmakelist has changed. Is there also a possibility to choose between release and debug? In vc++ this was very easy to handle :) I don't know how to do these things in Eclipse. Cheers, Brandon Van Every ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
Try the following: mingw32-make -f build\ instead of what you have. If the MinGW Make is like Unix Make then you need to provide the _directory_ where the makefile is located, not the path to the makefile itself. -- Mike Jackson Senior Research Engineer Innovative Management Technology Services On Jun 5, 2007, at 10:04 AM, Joachim Zettler wrote: Hi, here is the error i get in eclipse. Maybe it has to do with the all but i am absolutely not shure what this is :( Concerning cmake at all. If you execute mingw32-make -f Makefile directly from the command line in the build directory then everything is working just fine and the project is compiled. mingw32-make -f build\Makefile all build\Makefile:42: CMakeFiles/progress.make: No such file or directory mingw32-make: *** No rule to make target `CMakeFiles/ progress.make'. Stop. Hopefully you can give me some further hints. Best regards, Joachim 2007/6/5, Brandon Van Every [EMAIL PROTECTED] : On 6/5/07, Joachim Zettler [EMAIL PROTECTED] wrote: Dear all, thank you for your help up to now. I followed the tutorials you provided to me and made a Standard C++ makefile project. Afterwards I tried to adjust the make command but it is not working. Here you can find the command. mingw32-make -f build\Makefile The makefile is actually in a build folder and i generated it before with cmake -G MinGW Makefiles. Now it seems that the build\makefile is not working. Can you be more specific? What is the output of mingw32-make VERBOSE=1 ? Also build/makefile is wrong. I dont want to write the full path because it depends on which pc I actually work. CMake outputs absolute paths that only work in the target environment. You will have to generate new Makefiles on each specific machine you use. It's not wrong, it's a design choice. Many things can go wrong when you don't use absolute paths in a build. Up to now I also create the makefile myself everytime I change something in the cmakelist.txt. I have read about an option to run external tools but I dont know exactly how to implement this so that cmake is running only when something cmakelist has changed. Is there also a possibility to choose between release and debug? In vc++ this was very easy to handle :) I don't know how to do these things in Eclipse. Cheers, Brandon Van Every ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
2007/6/5, Joachim Zettler [EMAIL PROTECTED]: Hi, here is the error i get in eclipse. Maybe it has to do with the all but i am absolutely not shure what this is :( Concerning cmake at all. If you execute mingw32-make -f Makefile directly from the command line in the build directory then everything is working just fine and the project is compiled. Then you should indicates to eclipse external tools that the working directory should be build. You should be able to change the Build Directory mingw32-make -f build\Makefile all build\Makefile:42: CMakeFiles/progress.make: No such file or directory mingw32-make: *** No rule to make target `CMakeFiles/progress.make'. Stop. -- Erk ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
On Jun 5, 2007, at 9:41 AM, Joachim Zettler wrote: Dear all, thank you for your help up to now. I followed the tutorials you provided to me and made a Standard C++ makefile project. Afterwards I tried to adjust the make command but it is not working. Here you can find the command. mingw32-make -f build\Makefile The makefile is actually in a build folder and i generated it before with cmake -G MinGW Makefiles. Now it seems that the build \makefile is not working. Also build/makefile is wrong. I dont want to write the full path because it depends on which pc I actually work. Up to now I also create the makefile myself everytime I change something in the cmakelist.txt. I have read about an option to run external tools but I dont know exactly how to implement this so that cmake is running only when something cmakelist has changed. Is there also a possibility to choose between release and debug? In vc+ + this was very easy to handle :) In Eclipse, there is a Run Menu. In that Menu there is some sort of Option for External Tools. Go to that menu and there should be a Dialog window that Appears. Fill in the information about the path to cmake. The Working Directory should be something like $ {project_loc}/Build (adjust for windows paths) and the Arguments should be ../ This is covered in the Wiki Entry: If you edit your CMakeLists.txt file, then you will need to go back out to your terminal and rerun cmake. OR you can create an external program launch configuration and run cmake from within eclipse. To do this select the Run-External Tools-Show External Tools Dialog... menu. Create a new Program and call it Cmake. in the Location text field, type the absolute path to cmake (/usr/local/bin/cmake). If the Working Directory area insert the following: ${project_loc}/ Build and in the Arguments section insert the following: ../. In the Refresh Tab Select The project containing the selected resources. In the Common tab check the External Tools selection. This will put a shortcut in the Run menu for you. Click the Apply Button and then run. cmake will now run on your project directory. Try all that and let us know. I know that some of the questions might be stupid but up to now I am still learning :) Thank you in advance. Joachim 2007/6/5, Mike Jackson [EMAIL PROTECTED]: http://www.cmake.org/Wiki/CMake_Editors_Support There is an entry for using CMake with Eclipse. The wiki article is written assuming Unix/Linux/OS X but there should be no reason why the same would not work for MinGW. Note I have NOT tried it. The basics are: 1: Use CMake on Windows to generate the MinGW Makefiles 2: Launch Eclipse and create a Standard C++ Makefile Project 3: Edit the Make settings to point to the mingw32make executable and the MakeFile generated by CMake. I will leave the rest as an exercise to the reader. -- Mike Jackson Senior Research Engineer Innovative Management Technology Services On Jun 5, 2007, at 9:03 AM, Joachim Zettler wrote: Dear all, I want to integrate cmake with the ECLIPSE IDE and cdt. To be honest I am a beginner and therefore I have not really an idea on how to handle it. I use MinGW with WinXP to develop under Windows. It would be very nice if somebody can help me on how to set up Eclipse to use cmake to generate the Makefiles for mingw and the g+ + compiler. Thank you very much in advance. Joachim ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
Hi, here is the error i get in eclipse. Maybe it has to do with the all but i am absolutely not shure what this is :( Concerning cmake at all. If you execute mingw32-make -f Makefile directly from the command line in the build directory then everything is working just fine and the project is compiled. mingw32-make -f build\Makefile all build\Makefile:42: CMakeFiles/progress.make: No such file or directory mingw32-make: *** No rule to make target `CMakeFiles/progress.make'. Stop. Hopefully you can give me some further hints. Best regards, Joachim 2007/6/5, Brandon Van Every [EMAIL PROTECTED]: On 6/5/07, Joachim Zettler [EMAIL PROTECTED] wrote: Dear all, thank you for your help up to now. I followed the tutorials you provided to me and made a Standard C++ makefile project. Afterwards I tried to adjust the make command but it is not working. Here you can find the command. mingw32-make -f build\Makefile The makefile is actually in a build folder and i generated it before with cmake -G MinGW Makefiles. Now it seems that the build\makefile is not working. Can you be more specific? What is the output of mingw32-make VERBOSE=1 ? Also build/makefile is wrong. I dont want to write the full path because it depends on which pc I actually work. CMake outputs absolute paths that only work in the target environment. You will have to generate new Makefiles on each specific machine you use. It's not wrong, it's a design choice. Many things can go wrong when you don't use absolute paths in a build. Up to now I also create the makefile myself everytime I change something in the cmakelist.txt. I have read about an option to run external tools but I dont know exactly how to implement this so that cmake is running only when something cmakelist has changed. Is there also a possibility to choose between release and debug? In vc++ this was very easy to handle :) I don't know how to do these things in Eclipse. Cheers, Brandon Van Every ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
On 6/5/07, Joachim Zettler [EMAIL PROTECTED] wrote: Hi, here is the error i get in eclipse. please give the output with VERBOSE=1. Unless that's really just it? Maybe it has to do with the all but i am absolutely not shure what this is :( Concerning cmake at all. If you execute mingw32-make -f Makefile directly from the command line in the build directory then everything is working just fine and the project is compiled. mingw32-make -f build\Makefile all build\Makefile:42: CMakeFiles/progress.make: No such file or directory mingw32-make: *** No rule to make target `CMakeFiles/progress.make'. Stop. Hopefully you can give me some further hints. Best regards, Joachim 2007/6/5, Brandon Van Every [EMAIL PROTECTED] : On 6/5/07, Joachim Zettler [EMAIL PROTECTED] wrote: Dear all, thank you for your help up to now. I followed the tutorials you provided to me and made a Standard C++ makefile project. Afterwards I tried to adjust the make command but it is not working. Here you can find the command. mingw32-make -f build\Makefile The makefile is actually in a build folder and i generated it before with cmake -G MinGW Makefiles. Now it seems that the build\makefile is not working. Can you be more specific? What is the output of mingw32-make VERBOSE=1 ? Also build/makefile is wrong. I dont want to write the full path because it depends on which pc I actually work. CMake outputs absolute paths that only work in the target environment. You will have to generate new Makefiles on each specific machine you use. It's not wrong, it's a design choice. Many things can go wrong when you don't use absolute paths in a build. Up to now I also create the makefile myself everytime I change something in the cmakelist.txt. I have read about an option to run external tools but I dont know exactly how to implement this so that cmake is running only when something cmakelist has changed. Is there also a possibility to choose between release and debug? In vc++ this was very easy to handle :) I don't know how to do these things in Eclipse. Cheers, Brandon Van Every ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
Hehe, it works perfectly...thank you very much :) Now only one topic is still open :( The release and debug topic :) Hopefully I can handle this as fast as the last problems :) Thx a lot...you already saved my day :) Joachim 2007/6/5, Mike Jackson [EMAIL PROTECTED]: On Jun 5, 2007, at 9:41 AM, Joachim Zettler wrote: Dear all, thank you for your help up to now. I followed the tutorials you provided to me and made a Standard C++ makefile project. Afterwards I tried to adjust the make command but it is not working. Here you can find the command. mingw32-make -f build\Makefile The makefile is actually in a build folder and i generated it before with cmake -G MinGW Makefiles. Now it seems that the build\makefile is not working. Also build/makefile is wrong. I dont want to write the full path because it depends on which pc I actually work. Up to now I also create the makefile myself everytime I change something in the cmakelist.txt. I have read about an option to run external tools but I dont know exactly how to implement this so that cmake is running only when something cmakelist has changed. Is there also a possibility to choose between release and debug? In vc++ this was very easy to handle :) In Eclipse, there is a Run Menu. In that Menu there is some sort of Option for External Tools. Go to that menu and there should be a Dialog window that Appears. Fill in the information about the path to cmake. The Working Directory should be something like ${project_loc}/Build (adjust for windows paths) and the Arguments should be ../ This is covered in the Wiki Entry: If you edit your CMakeLists.txt file, then you will need to go back out to your terminal and rerun cmake. OR you can create an external program launch configuration and run cmake from within eclipse. To do this select the Run-External Tools-Show External Tools Dialog... menu. Create a new Program and call it Cmake. in the Location text field, type the absolute path to cmake (/usr/local/bin/cmake). If the Working Directory area insert the following: ${project_loc}/Build and in the Arguments section insert the following: ../. In the Refresh Tab Select The project containing the selected resources. In the Common tab check the External Tools selection. This will put a shortcut in the Run menu for you. Click the Apply Button and then run. cmake will now run on your project directory. Try all that and let us know. I know that some of the questions might be stupid but up to now I am still learning :) Thank you in advance. Joachim 2007/6/5, Mike Jackson [EMAIL PROTECTED]: http://www.cmake.org/Wiki/CMake_Editors_Support There is an entry for using CMake with Eclipse. The wiki article is written assuming Unix/Linux/OS X but there should be no reason why the same would not work for MinGW. Note I have NOT tried it. The basics are: 1: Use CMake on Windows to generate the MinGW Makefiles 2: Launch Eclipse and create a Standard C++ Makefile Project 3: Edit the Make settings to point to the mingw32make executable and the MakeFile generated by CMake. I will leave the rest as an exercise to the reader. -- Mike Jackson Senior Research Engineer Innovative Management Technology Services On Jun 5, 2007, at 9:03 AM, Joachim Zettler wrote: Dear all, I want to integrate cmake with the ECLIPSE IDE and cdt. To be honest I am a beginner and therefore I have not really an idea on how to handle it. I use MinGW with WinXP to develop under Windows. It would be very nice if somebody can help me on how to set up Eclipse to use cmake to generate the Makefiles for mingw and the g++ compiler. Thank you very much in advance. Joachim ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
On Tuesday 05 June 2007 10:34, Joachim Zettler wrote: Hehe, it works perfectly...thank you very much :) Now only one topic is still open :( The release and debug topic :) Hopefully I can handle this as fast as the last problems :) You need to set up a separate build tree for each different build type (by running cmake in each build tree separately). Bye Alex ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
On Jun 5, 2007, at 10:19 AM, Joachim Zettler wrote: Thx...now its running just fine. I had to change the build directory :) Now there is only the cmake thing left. Is it possible to tell eclipse that it should start cmake prior to starting the make process? I am not finding an option to automatically run cmake prior to every build. After you have properly setup an External Tool to run cmake from within Eclipse this becomes less of a need. I the early stages when first creating the CMakeLists.txt file constantly selecting the Run-External Tool-Cmake is a pain, but as your project stabilizes this becomes less of an issue. You might be able to write shell script that runs cmake, then make and then invoke that script instead of mingw32-make -C Build/ And what about the release and debug versions. Is there an eclipse switch to change it quickly? (I know this might be a little bit off- topic) Cmake handles Debug and Release differently than other systems. Basically you want to setup 2 build trees in your project, Say Build- Debug and Build-Release (Or just Debug and Release). I think in Eclipse 3.2 + CDT 3.1.2 you will have to manually switch the make command between each of the build folders to get the desired effect. In the newer versions of Eclipse (3.3RC2) CDT 4.0RC2 I think there is better support for configurations for Makefile projects. So basically you can setup a Debug configuration and point make to the Debug directory and a Release configuration and point the make command for that configuration to the Release directory. Let us know how things progress. I wrote most of the CMake/Eclipse wiki Entry and will update it with MinGW information if you have anything to add. I am updating the wiki entry at the moment to make things easier to find. Mike Jackson Thank you very much already. Joachim 2007/6/5, Eric Noulard [EMAIL PROTECTED]: 2007/6/5, Joachim Zettler [EMAIL PROTECTED]: Hi, here is the error i get in eclipse. Maybe it has to do with the all but i am absolutely not shure what this is :( Concerning cmake at all. If you execute mingw32-make -f Makefile directly from the command line in the build directory then everything is working just fine and the project is compiled. Then you should indicates to eclipse external tools that the working directory should be build. You should be able to change the Build Directory mingw32-make -f build\Makefile all build\Makefile:42: CMakeFiles/progress.make: No such file or directory mingw32-make: *** No rule to make target `CMakeFiles/ progress.make'. Stop. -- Erk ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
On 6/5/07, Joachim Zettler [EMAIL PROTECTED] wrote: Hehe, it works perfectly...thank you very much :) Now only one topic is still open :( The release and debug topic :) Hopefully I can handle this as fast as the last problems :) Creating release, debug, and other configurations all at once is CMake generator specific. For instance, the MSVC generators will produce Debug, Release, MinSizeRel, and RelWithDebugInfo. The MinGW generator doesn't, it's a single configuration generator. I think the Unix Makefiles generator is as well. I haven't done the drill of getting it to do different configurations, but I'm sure it's in the archives. Sorry I was a little slow on the make VERBOSE=1 comment, but keep it in mind for future bug reports. Cheers, Brandon Van Every ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
Hmm... this sounds difficult to implement into Eclipse, isnt it? So we have two different makefiles..one for release and one for debug. I thought I can handle this by just generating a Target with release and debug and then in the makefile there is a switch if to choose makefile.debug or makefile.release. Best regards, Joachim 2007/6/5, Alexander Neundorf [EMAIL PROTECTED]: On Tuesday 05 June 2007 10:34, Joachim Zettler wrote: Hehe, it works perfectly...thank you very much :) Now only one topic is still open :( The release and debug topic :) Hopefully I can handle this as fast as the last problems :) You need to set up a separate build tree for each different build type (by running cmake in each build tree separately). Bye Alex ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
On Tuesday 05 June 2007 10:41, Mike Jackson wrote: On Jun 5, 2007, at 10:19 AM, Joachim Zettler wrote: Thx...now its running just fine. I had to change the build directory :) Now there is only the cmake thing left. Is it possible to tell eclipse that it should start cmake prior to starting the make process? I am not finding an option to automatically run cmake prior to every build. After you have properly setup an External Tool to run cmake Why would you need to run cmake prior to every build ? You should only need to run it once, from there on the makefiles wil have the rules to rerun cmake automatically if required. Bye Alex ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
Thank you, now with all your input it should be clear to me how to set up the two development trees. I will keep you informed tomorrow. With best regards, Joachim 2007/6/5, Alexander Neundorf [EMAIL PROTECTED]: On Tuesday 05 June 2007 10:43, Joachim Zettler wrote: Hmm... this sounds difficult to implement into Eclipse, isnt it? Well, you need to create two makefile target trees and then build the targets in the tree you want. Alex ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] Cmake with Eclipse
Huh.. never noticed that.. or something about my setup was preventing it from working. So I just tried to change my CMakeLists.txt file and then just hit Command-B to build and Cmake reran. Good Job CMake Team !!. Never noticed that in the past. Thanks for Teaching me something today. -- Mike Jackson Senior Research Engineer Innovative Management Technology Services On Jun 5, 2007, at 10:52 AM, Alexander Neundorf wrote: On Tuesday 05 June 2007 10:41, Mike Jackson wrote: On Jun 5, 2007, at 10:19 AM, Joachim Zettler wrote: Thx...now its running just fine. I had to change the build directory :) Now there is only the cmake thing left. Is it possible to tell eclipse that it should start cmake prior to starting the make process? I am not finding an option to automatically run cmake prior to every build. After you have properly setup an External Tool to run cmake Why would you need to run cmake prior to every build ? You should only need to run it once, from there on the makefiles wil have the rules to rerun cmake automatically if required. Bye Alex ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
[CMake] CMake with Eclipse (cdt) - error parsing
Hi, We are currently using CMake and Eclipse (cdt) to port our windows product to unix (Solaris x86). I had to write a small Eclipse plugin to get our compile errors to appear in the Problems tab. This parsed the sun compliers exception messages and marked them as problems with file and location info. Now that I have this working I would like to write a similar plugin for CMake error messages. So I have a few questions for the list: * Is anybody else already doing this? * Can people send me some examples of real life cmake error messages that I can use for my unit tests? * Can anyone give me a diffinative pattern for all cmake errors? See my basic interpretation below. Cmake Error text example: CMake Error: Error in cmake code at C:/Devroot/UnixBranch2/BWCommon/./BWLib/BWInfra/CMakeLists.txt:94: Unknown CMake command LISTP. Structure: * First line: indicates an error * Second line: indicates file and line number * Third line: contains description Once this is done I will release the code on this mailing list as soon as it is usable, I will create a source forge project in the future, but I am very busy at the moment so realistically it will probably be a few months before I can set that up. Kind regards, Iain Hull. CR2 ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] CMake with Eclipse (cdt) - error parsing
I am using Eclipse with CMake but I just run the cmake part in an external terminal to build the makefiles, then just have Eclipse use those MakeFiles. Sounds like you are way further along than I am. -- Mike Jackson Senior Research Engineer Innovative Management Technology Services On Mar 15, 2007, at 10:30 AM, Iain Hull wrote: Hi, We are currently using CMake and Eclipse (cdt) to port our windows product to unix (Solaris x86). I had to write a small Eclipse plugin to get our compile errors to appear in the Problems tab. This parsed the sun compliers exception messages and marked them as problems with file and location info. Now that I have this working I would like to write a similar plugin for CMake error messages. So I have a few questions for the list: * Is anybody else already doing this? * Can people send me some examples of real life cmake error messages that I can use for my unit tests? * Can anyone give me a diffinative pattern for all cmake errors? See my basic interpretation below. Cmake Error text example: CMake Error: Error in cmake code at C:/Devroot/UnixBranch2/BWCommon/./BWLib/BWInfra/CMakeLists.txt:94: Unknown CMake command LISTP. Structure: * First line: indicates an error * Second line: indicates file and line number * Third line: contains description Once this is done I will release the code on this mailing list as soon as it is usable, I will create a source forge project in the future, but I am very busy at the moment so realistically it will probably be a few months before I can set that up. Kind regards, Iain Hull. CR2 ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
RE: [CMake] CMake with Eclipse (cdt) - error parsing
I do that too. But once my initial make files are generated I use eclipse to call make. The generated make files call cmake first, so edit my cmake files in eclipse and call make to update the make files and build. Iain. -Original Message- From: Mike Jackson [mailto:[EMAIL PROTECTED] Sent: 15 March 2007 15:10 To: Iain Hull Cc: cmake Subject: Re: [CMake] CMake with Eclipse (cdt) - error parsing I am using Eclipse with CMake but I just run the cmake part in an external terminal to build the makefiles, then just have Eclipse use those MakeFiles. Sounds like you are way further along than I am. -- Mike Jackson Senior Research Engineer Innovative Management Technology Services On Mar 15, 2007, at 10:30 AM, Iain Hull wrote: Hi, We are currently using CMake and Eclipse (cdt) to port our windows product to unix (Solaris x86). I had to write a small Eclipse plugin to get our compile errors to appear in the Problems tab. This parsed the sun compliers exception messages and marked them as problems with file and location info. Now that I have this working I would like to write a similar plugin for CMake error messages. So I have a few questions for the list: * Is anybody else already doing this? * Can people send me some examples of real life cmake error messages that I can use for my unit tests? * Can anyone give me a diffinative pattern for all cmake errors? See my basic interpretation below. Cmake Error text example: CMake Error: Error in cmake code at C:/Devroot/UnixBranch2/BWCommon/./BWLib/BWInfra/CMakeLists.txt:94: Unknown CMake command LISTP. Structure: * First line: indicates an error * Second line: indicates file and line number * Third line: contains description Once this is done I will release the code on this mailing list as soon as it is usable, I will create a source forge project in the future, but I am very busy at the moment so realistically it will probably be a few months before I can set that up. Kind regards, Iain Hull. CR2 ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake CR2 ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] CMake with Eclipse CDT (Was: No Subject)
Yep. Do it all the time. It isn't as integrated as I would like but it does work and work pretty good at that. Here is how I set up my dev env: CMake usually likes out of source builds BUT Eclipse has some problems if your build products are outside the project directory. I get around this by creating a Build Directory inside my top level project directory. This still basically protects the source code from contamination from all the build products. Next, run cmake or CMakeSetup (Depending what Platform you are on) at least once to boot strap the process. This will do the normal cmake things. Now, back in Eclipse setup a new Standard C/C++ Make Project using the top level folder as the Project folder. While you are go through the New Project Wizard there will be a dialog with a bunch of tabs, one of those tabs you can control the Make command. You do NOT want the default command as it will look for a Makefile at the top level of the project directory. Your Makefile is in ProjectLocation/Build/Makefile and so you want to put in your own make command that points to that location. The easiest and most general way to do this is with the following command: make -C ${project_loc}/Build The ${project_loc} is an eclipse variable that will find the absolute path to the project. Basically that is all that is needed. Finish with the New Project wizard and then try Building your project. It should all just work. You can add some more integration by creating a new External Tool that reruns cmake on your source directory. Again, go to the Run menu, select External Tools then External Tools... and a new dialog pops up. In the Location text field, put the full path to the cmake command. On my OS X box this happens to be /usr/local/bin/ cmake. In the Working Directory Text field put ${project_loc}/Build and in the Arguments section put ../. You can make selections in the other tabs as you see fit. If you go to the Common tab there is a check box that will make the command always available in the External Tools toolbar item. So, now when you change your CMakeLists.txt file, you can run this external tool which will rerun cmake. There is a way to have cmake run _every_ time you compile which would obviate the need to manually run cmake each time, but I didn't really like it running for no reason every time. Once I had settled on a cmakelists.txt file I no longer needed it to run every time. When I want to really Clean a project I usually jump to a terminal and do the cleaning and rerunning of ccmake from there. Again, you can setup an external tool to do this for you if you wanted. I have never taken the time. Lastly, The latest official Eclipse (3.2) and CDT (3.2.1) are pretty good and recent hardware (Intel dual cores are great but anything in the last few years is good) but if you have a large C/C++ project the code index can become quite large when dealing with projects like Qt, VTK and ITK. Your project folder will grow to over a gigabyte and the code completion will slow down after a while. You have two choices: Look for files that end with .pdom and delete them. This is where Eclipse stores the code completion index. The next time Eclipse starts up your project the files will be rebuilt. This will drop the size but eventually you will have to do this again. The other is to try the bleeding edge eclipse/cdt downloads. I am currently using Eclipse 3.3M5 and CDT 4.0M5 and the code completion is very fast now, the index is reasonably small and the syntax highlighting is just awesome. There are some bugs though as these are not stable releases but I have found them stable enough for everyday use. Hope all this helps. -- Mike Jackson Senior Research Engineer Innovative Management Technology Services PS: I have aspirations of writing a CMake syntax highlighting plugin for Eclipse but I lack the know how to do such a thing. Instead I wrote one for TextMate if you happen to be running OS X On Feb 26, 2007, at 7:54 AM, Alexander Ivash wrote: Hello, cmake. Is it possible to use cmake with eclipse for c++ projects ? -- Best regards, Alexander mailto:[EMAIL PROTECTED] software.com ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: [CMake] CMake with Eclipse CDT (Was: No Subject)
Hi, Original-Nachricht Datum: Mon, 26 Feb 2007 08:30:52 -0500 Von: Mike Jackson [EMAIL PROTECTED] An: Alexander Ivash [EMAIL PROTECTED] CC: cmake@cmake.org Betreff: Re: [CMake] CMake with Eclipse CDT (Was: No Subject) Yep. Do it all the time. It isn't as integrated as I would like but it does work and work pretty good at that. can you please put this in the CMake wiki, maybe under howtos/tutorials or editor support ? Thanks Alex -- Feel free - 5 GB Mailbox, 50 FreeSMS/Monat ... Jetzt GMX ProMail testen: www.gmx.net/de/go/mailfooter/promail-out ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake
Re: Re[2]: [CMake] CMake and Eclipse
Hi, What I found useful when using eclipse is adding 'VERBOSE=1' to make. Eclipse scans the output of the build process (enabled by default - 'discovery options' - 'enable build output scanner info discovery') on INCLUDE/LIBRARY directories and uses this for the code completion functionality. Cheers, Peter. On 2/26/07, Alexander Ivash [EMAIL PROTECTED] wrote: Hello, Alexander. You wrote 26 февраля 2007 г., 15:32:41: Von: Alexander Ivash [EMAIL PROTECTED] Hello, cmake. Is it possible to use cmake with eclipse for c++ projects ? You can have cmake create makefiles, and then use these makefiles with a makefile project in Eclipse (i.e. not a managed make project). If you're interested you could also try to find out whether it would make sense to add direct eclipse support to CMake Bye Alex Thank you for fast reply!.. All is working! -- Best regards, Alexander mailto:[EMAIL PROTECTED] ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake ___ CMake mailing list CMake@cmake.org http://www.cmake.org/mailman/listinfo/cmake