I\'m getting loads of warnings from generated files in my target
folder (e.g. Java code generated from XSDs or surefire reports) that I can\'t fix, and it\'s hi
Folders that are not source folders are not compiled by Eclipse. So you should not have Java error/warning for those.
For source folder, you already have the solution ('Ignore optional compile problems' parameter).
It turns out you can do this fairly simply (at least in Eclipse Kepler).
Open up the Preferences panel, either for Eclipse as a whole or for the project. Select the Validation pane (if you're using the project preferences panel, you may need to enable project-specific settings). Now go to the validator that's causing you problems (in my case, it was the HTML validator, but it depends on what you're doing) and click the button to edit its settings, which pops up another dialog.
In this dialog you want to make sure that there is an Exclude Group that excludes Folder: target. If there's no exclude group at all, add one with the button on the right. Then select the exclude group and Add Rule… to bring up another dialog/wizard. You want to add a Folder or file name, and in the next step pick the target folder to exclude (using the Browse Folder… button) and keeping the checkbox for using just the simple filename checked. If you're adding a global rule, it doesn't matter which target
folder you pick.
The OK/Apply back out of all the dialogs to apply the change you've made (or maybe add more exclusion rules). You'll need a rebuild so that the rule change is applied correctly, but that's straight-forward.