Reputation: 861
I'm trying to configure Eclipse for developing Linux Kernel Modules under Ubuntu. So far I've added to Properties
> Paths and Symbols
> Includes
> GNU C
headers from directory /usr/src/'uname -r'/include
but it doesn't remove all the Syntax error
from my code.
After that, my code looks like this:
What else should I do to develop Kernel modules with pleasure?
Upvotes: 5
Views: 16522
Reputation: 1005
If you are building an Out-of-Tree kernel module, follow the steps in the CDT wiki (linked in @pjenney58's response).
The key difference is at Step 30 (Source Location->expand your project name).
In my project that took care of almost all the indexer markers complaining about syntax errors.
Upvotes: 1
Reputation: 316
If you're interested, those orange squigglies are actually indexer markers. Turn them off by going to window/preferences/general/editors/text editors/annotations, select c/c++indexer markers and uncheck 'text as'.
Also, this was posted on the Eclipse wiki: http://wiki.eclipse.org/HowTo_use_the_CDT_to_navigate_Linux_kernel_source
Upvotes: 4