Summary: | /usr/include/string.h:518:12: error: exception specification in declaration does not match previous declaration | ||
---|---|---|---|
Product: | Mesa | Reporter: | Vinson Lee <vlee> |
Component: | Mesa core | Assignee: | mesa-dev |
Status: | RESOLVED FIXED | QA Contact: | mesa-dev |
Severity: | normal | ||
Priority: | medium | CC: | krejzi, robclark |
Version: | git | Keywords: | bisected, regression |
Hardware: | x86-64 (AMD64) | ||
OS: | Linux (All) | ||
Whiteboard: | |||
i915 platform: | i915 features: |
Description
Vinson Lee
2016-09-27 16:49:00 UTC
*** Bug 98042 has been marked as a duplicate of this bug. *** /me shrugs.. I don't really have a setup for building with clang.. I guess the issue is introduction of #include "bitscan.h" in mtypes.h. Although bitscan.h was already used elsewhere, so not entirely sure why it worked before if this is breaking things. I guess something that someone who has a setup to build w/ clang will have to debug. I believe its because the ffs param in string.h is an int while the one in bitscan.h is unsigned. (In reply to Timothy Arceri from comment #3) > I believe its because the ffs param in string.h is an int while the one in > bitscan.h is unsigned. oh, yeah, probably should be int in bitscan.h then (still not entirely sure why this issue starts showing up now, but I guess it comes down to #include order and luck before) Fixed by: author Vinson Lee <vlee@freedesktop.org> commit 889ee4da05400687a6c5296a7632dc26f1d61924 util: Include string.h in bitscan.h. Fix build error with clang. Compiling src/compiler/glsl/link_varyings.cpp ... In file included from src/compiler/glsl/link_varyings.cpp:33: In file included from src/compiler/glsl/glsl_symbol_table.h:34: In file included from src/compiler/glsl/ir.h:33: In file included from src/compiler/glsl_types.h:29: /usr/include/string.h:518:12: error: exception specification in declaration does not match previous declaration extern int ffs (int __i) __THROW __attribute__ ((__const__)); ^ src/util/bitscan.h:51:13: note: expanded from macro 'ffs' ^ src/util/bitscan.h:96:18: note: previous declaration is here const int i = ffs(*mask) - 1; ^ src/util/bitscan.h:51:13: note: expanded from macro 'ffs' ^ Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=97952 Signed-off-by: Vinson Lee <vlee@freedesktop.org> Reviewed-by: Timothy Arceri <timothy.arceri@collabora.com> |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.