Eclipse refuses to build my Android project. In the package explorer, the project root node has the little red error symbol, but nothing else inside of it has this symbol. The P
Make sure you have android: namespace identifier together with minSdkVersion attribute. Like this:
android:minSdkVersion="8"
.
When creating a project based on some Android sample projects (like BluetoothChat) the namespace gets omitted and confuses Lint. Then even clearing Lint Markers doesn't truly cure the issue as they reappear after running Lint again, which happens automatically pretty often.
Note: this was verified with samples revision 1 for API16
I have the same problem, and my solution is:
Right click on the project folder > Android tools > Clear Lint Markers
"Run Android Lint" makes some markers and the markers cause this error.
Try right clicking on the project folder > Android tools > fix properties
You should also check in the build properties that all your android libraries and things are checked and loading in the correct order. Right click on the project > Properties > Build
A simple Project -> Clean also fixed the issue for me.
"Clear Lint Markers" in the Accepted Answer removed the error temporarily, but it kept coming back every time I saved a file in the affected project.
To make it stop reporting that error, I had to disable the lint check altogether:
Right click project -> Properties -> Android Lint Preferences
Search for "minSdk" in the search box
Click on "UsesMinSdkAttributes"
Click the "Ignore All" button at the bottom.
Clean and rebuild the project, and Eclipse/ADT will no longer run the lint check for minSdk on your project.