https://bugs.winehq.org/show_bug.cgi?id=48911
Bug ID: 48911 Summary: Check for compilation warnings Product: Wine-Testbot Version: unspecified Hardware: x86 OS: Linux Status: NEW Severity: normal Priority: P2 Component: unknown Assignee: wine-bugs@winehq.org Reporter: fgouget@codeweavers.com Distribution: ---
Compiling Wine with -Werror is troublesome because it applies blindly to both wine-devel patches and patches submitted manually via the website. The sole purpose of the latter is often to just clarify some point for the development of another patch and are not meant to be submitted. Thus failing on warnings just makes running these quick tests more cumbersome.
So the best way forward would be for the TestBot to identify and report warnings but not fail the compilation and abort the tests when they occur.
So: 1. The builds should happen without -Werror.
2. GetLogLineCategory() should identify the warnings and add them to LogInfo but distinguish them from errors (replace IsNew with a Category field?).
3. Compare task.log to the reference build log to distinguish new warnings from old ones. This is necessary in case the compiler used by the TestBot produces warnings on the unpatched Wine tree. It will require storing the build logs in latest/ just like the TestBot already does for the reference WineTest reports.
4. LogInfo's will need to keep track of the number of new warnings which really means renaming the 'NewCount' field to avoid confusion.
5. The warnings should be saved in the errors files. The new line types could be 'w' and 'W' for old and new warnings respectively (then it would make sense to use e and E for errors).
6. This will let the WineRun*() scripts know about both warnings and errors. They can then decide what to do depending on the type of job and whether the warnings are new or not. - Old warnings would always be ignored. - If a build task has new warnings, instead of marking it as 'badbuild' it could be marked as 'completed' as usual but with a non-zero number of failures. This would probably allow running the tests on Windows but the patch would still be considered bad since the job would end up with a non-zero number of failures. - For Wine tasks the number of warnings would be added to the Failures field for the same overall result. - So in both cases the non-zero number of failures would only impact wine-devel patches.
7. The JobDetails page should show the warnings in summary mode and highlight them in the full build log. That would make it easy for developers to see the warnings on web-submitted jobs, and thus fix them before submitting the patch to wine-devel.