mirror of git://sourceware.org/git/glibc.git
conform: Use -dD instead of -dN on compiler invocation
clang does not support -dN. Reviewed-by: Sam James <sam@gentoo.org>
This commit is contained in:
parent
969d7cf899
commit
fe925cb045
|
@ -620,7 +620,7 @@ class HeaderTests(object):
|
||||||
out_file = os.path.join(self.temp_dir, 'namespace-out')
|
out_file = os.path.join(self.temp_dir, 'namespace-out')
|
||||||
with open(c_file, 'w') as c_file_out:
|
with open(c_file, 'w') as c_file_out:
|
||||||
c_file_out.write('#include <%s>\n' % self.header)
|
c_file_out.write('#include <%s>\n' % self.header)
|
||||||
cmd = ('%s %s -E %s -P -Wp,-dN > %s'
|
cmd = ('%s %s -E %s -P -Wp,-dD > %s'
|
||||||
% (self.cc, self.cflags_namespace, c_file, out_file))
|
% (self.cc, self.cflags_namespace, c_file, out_file))
|
||||||
subprocess.check_call(cmd, shell=True)
|
subprocess.check_call(cmd, shell=True)
|
||||||
bad_tokens = set()
|
bad_tokens = set()
|
||||||
|
@ -639,11 +639,11 @@ class HeaderTests(object):
|
||||||
# macros defined by user code including the
|
# macros defined by user code including the
|
||||||
# header.)
|
# header.)
|
||||||
continue
|
continue
|
||||||
match = re.match(r'#define (.*)', line)
|
match = re.match(r'#define (.*?[^\(\s]+)', line)
|
||||||
if match:
|
if match:
|
||||||
self.check_token(bad_tokens, match.group(1))
|
self.check_token(bad_tokens, match.group(1))
|
||||||
continue
|
continue
|
||||||
match = re.match(r'#undef (.*)', line)
|
match = re.match(r'#undef (.*?[^\(\s]+)', line)
|
||||||
if match:
|
if match:
|
||||||
bad_tokens.discard(match.group(1))
|
bad_tokens.discard(match.group(1))
|
||||||
continue
|
continue
|
||||||
|
|
Loading…
Reference in New Issue