Hello!
Can you help me?
How include Keil C/C++ compiler in Eclipse IDE? Whether it is possible? Whether debugging with OpenOCD will earn?
Andrew You can explain how you should set up the three points. I can't find much documentation
Thanks
DS5 is Eclipse-based - perhaps you could look there for ideas...?
Hi Joldi,
I haven't tried the third option of using a non-Keil debugger with the output from the Keil compiler. However, setting up Eclipse as an edit/build environment is pretty easy. You can use the "Import" menu and select "Existing code as Makefile project" under the C/C++ category. At that point you can use the normal Eclipse method of setting up include paths and symbols to match your project (that part is a little tedious).
To launch a build from Eclipse you have to change to a custom build step and call a build script. I put mine in the same directory as the Keil project and call it build.cmd:
c:\keil\uv4\uv4.exe -b RSN.uvproj -o errors.txt type errors.txt
In the C/C++ Build settings for the project (right-click on the project) I uncheck "Use default build command" and enter "build.cmd" as the build command instead. Now, when I select "Build" for my project Eclipse will launch build.cmd and pipe errors.txt to the "Console" window.
The last step is to define a custom error parser for the armcc compiler output, which is a little different from gcc. In "Window|Preferences|C/C++|Build" you add an error parser with these definitions:
Error: (.*)\((\d+)\):\s+error:\s+(.*) Warning: (.*)\((\d+)\):\s+warning:\s+(.*) Info: (.*)\((\d+)\):\s+info(.*)
Finally, back in the "C/C++ Build" settings for your project you enable the newly created error parser.
Done!
For additional goodness I also have Subversion integrated into Eclipse so the only thing I do in Keil is debugging.
Andrew Q
Hi Andrew,
I followed, but I'm still having problems getting the KEIL compile console into eclipse.. any tips that you might have for me would be more than welcome.
Cheers!
Can you describe how much you've gotten to work? Do you have a batch file to build your project that works outside of Eclipse?
Andrew
ok, so, what's working:
- compiling from eclipse: when I do "Project->Build Project" the KEIL instance is started, i can see stuff compiling there,console output and all.
what's not working: - I don't see any of the KEIL console text in eclipse.
uhm, nevermind, working perfectly now. damn typo.
Hi,
I find myself in a similar situation needing to work with keil and I would very much prefer to use Eclipse instead. You said you can use Eclipse to debug the keil project. Can you explain step by step how did you manage to set eclipse in such a way. I am using Eclipse Helios.
Thank you, Criss