--- hw/xfree86/sdksyms.sh.orig 2015-04-04 17:38:46.756942409 +0300 +++ hw/xfree86/sdksyms.sh 2015-04-04 17:47:28.417349179 +0300 @@ -350,6 +350,23 @@ if (sdk) { n = 3; + # detect the following gcc5 cpp pattern and skip it: + # extern + # # 320 "../../include/os.h" 3 4 + # __attribute__((visibility("default"))) + # # 320 "../../include/os.h" + # Note in this case the "extern " or "extern void " always has + # a trailing space + if ($0 ~ "^extern.* $") { + getline; + getline; + getline; + getline; + n = 1; + while ($n == " ") + n++; + } + # skip attribute, if any while ($n ~ /^(__attribute__|__global)/ || # skip modifiers, if any