fix _POSIX_C_SOURCE define in that one place that needs it
This commit is contained in:
parent
954bdbec6d
commit
45fc47b1b1
2 changed files with 7 additions and 6 deletions
|
@ -9,12 +9,12 @@ header = r"""\1/*
|
|||
* Copyright (c) 2011-2018, Lukas Weber <laochailan@web.de>.
|
||||
* Copyright (c) 2012-2018, Andrei Alexeyev <akari@alienslab.net>.
|
||||
*/
|
||||
\2\3
|
||||
\2\4\3
|
||||
#include "taisei.h"
|
||||
|
||||
"""
|
||||
|
||||
header_regex = re.compile(r'^(#if 0.*?\s#endif\s*)?(?:\s*?/\*.*?\*/)?(?:\s*?(\n#pragma once))?(?:\s*?#include "taisei.h")?(?:\s*?(\n#pragma once))?\s*', re.MULTILINE | re.DOTALL)
|
||||
header_regex = re.compile(r'^(#if 0.*?\s#endif\s*)?(?:\s*?/\*.*?\*/)?(?:\s*?(\n#pragma once))?(?:\s*?(\n// begin before-taisei-h\s*.*?\n.*?// end before-taisei-h\n?))?(?:\s*?#include "taisei.h")?(?:\s*?(\n#pragma once))?\s*', re.MULTILINE | re.DOTALL)
|
||||
|
||||
if __name__ == '__main__':
|
||||
for path in itertools.chain(*((pathlib.Path(__file__).parent.parent / 'src').glob(p) for p in ('**/*.[ch]', '**/*.[ch].in'))):
|
||||
|
|
|
@ -6,11 +6,12 @@
|
|||
* Copyright (c) 2012-2018, Andrei Alexeyev <akari@alienslab.net>.
|
||||
*/
|
||||
|
||||
#include "taisei.h"
|
||||
// begin before-taisei-h
|
||||
#undef _POSIX_C_SOURCE
|
||||
#define _POSIX_C_SOURCE 200809L
|
||||
// end before-taisei-h
|
||||
|
||||
#ifndef _POSIX_C_SOURCE
|
||||
#define _POSIX_C_SOURCE 2
|
||||
#endif
|
||||
#include "taisei.h"
|
||||
|
||||
#include "rwops_pipe.h"
|
||||
#include "util.h"
|
||||
|
|
Loading…
Reference in a new issue