mirror of
https://github.com/systemd/systemd.git
synced 2024-11-23 02:03:37 +08:00
man/examples: set _GNU_SOURCE in source, rather than by compile option
Addresses https://github.com/systemd/systemd/pull/32057#issuecomment-2034408569.
This commit is contained in:
parent
5360b10f29
commit
040cb66458
@ -1,5 +1,6 @@
|
||||
/* SPDX-License-Identifier: MIT-0 */
|
||||
|
||||
#define _GNU_SOURCE 1
|
||||
#include <assert.h>
|
||||
#include <stdio.h>
|
||||
#include <unistd.h>
|
||||
|
@ -1,5 +1,6 @@
|
||||
/* SPDX-License-Identifier: MIT-0 */
|
||||
|
||||
#define _GNU_SOURCE 1
|
||||
#include <stdio.h>
|
||||
#include <stdint.h>
|
||||
#include <systemd/sd-hwdb.h>
|
||||
|
@ -1,5 +1,6 @@
|
||||
/* SPDX-License-Identifier: MIT-0 */
|
||||
|
||||
#define _GNU_SOURCE 1
|
||||
#include <poll.h>
|
||||
#include <time.h>
|
||||
#include <systemd/sd-journal.h>
|
||||
|
@ -1,5 +1,6 @@
|
||||
/* SPDX-License-Identifier: MIT-0 */
|
||||
|
||||
#define _GNU_SOURCE 1
|
||||
#include <errno.h>
|
||||
#include <syslog.h>
|
||||
#include <stdio.h>
|
||||
|
@ -306,10 +306,10 @@ default_args = [
|
||||
]
|
||||
|
||||
std_args_in = [
|
||||
[ '-std=c99', '-D_GNU_SOURCE', ],
|
||||
[ '-std=c11', '-D_GNU_SOURCE', ],
|
||||
[ '-std=c17', '-D_GNU_SOURCE', ],
|
||||
[ '-std=c23', '-D_GNU_SOURCE', ],
|
||||
[ '-std=c99', ],
|
||||
[ '-std=c11', ],
|
||||
[ '-std=c17', ],
|
||||
[ '-std=c23', ],
|
||||
[ '-std=gnu99', ],
|
||||
[ '-std=gnu11', ],
|
||||
[ '-std=gnu17', ],
|
||||
|
@ -7,6 +7,7 @@
|
||||
* This protocol is guaranteed to be stable as per:
|
||||
* https://systemd.io/PORTABILITY_AND_STABILITY/ */
|
||||
|
||||
#define _GNU_SOURCE 1
|
||||
#include <errno.h>
|
||||
#include <inttypes.h>
|
||||
#include <signal.h>
|
||||
|
@ -1,5 +1,6 @@
|
||||
/* SPDX-License-Identifier: MIT-0 */
|
||||
|
||||
#define _GNU_SOURCE 1
|
||||
#include <errno.h>
|
||||
#include <stdbool.h>
|
||||
#include <stddef.h>
|
||||
|
Loading…
Reference in New Issue
Block a user