This commit is contained in:
Kovid Goyal 2021-09-24 12:03:51 +05:30
parent 03391b4f7a
commit 2fcfa8d3eb
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -239,7 +239,7 @@ def test_compile(
ldflags: Iterable[str] = (),
) -> bool:
src = src or 'int main(void) { return 0; }'
with tempfile.NamedTemporaryFile() as f:
with tempfile.NamedTemporaryFile(prefix='kitty-test-compile-') as f:
p = subprocess.Popen(
[cc] + list(cflags) + ([] if link_also else ['-c']) + ['-x', lang, '-o', f.name, '-'] +
[f'-l{x}' for x in libraries] + list(ldflags),