1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2025-09-09 17:44:14 +03:00

Use __linux__ macro in generated code

This commit is contained in:
Nick Wellnhofer
2017-09-29 13:00:50 +02:00
parent 4b4d3d8516
commit 03a238f954
2 changed files with 2 additions and 3 deletions

View File

@@ -8,8 +8,7 @@ addons:
matrix: matrix:
include: include:
# Try to emulate a C89 compiler on a POSIX system by disabling as many # Try to emulate a C89 compiler on a POSIX system by disabling as many
# GNU extensions as possible. -Dlinux is required to make the weak # GNU extensions as possible.
# pthread symbols work.
- compiler: gcc - compiler: gcc
env: CFLAGS="-O2 -std=c89 -D_POSIX_C_SOURCE=200809L" env: CFLAGS="-O2 -std=c89 -D_POSIX_C_SOURCE=200809L"
# clang with AddressSanitizer and UndefinedBehaviorSanitizer. # clang with AddressSanitizer and UndefinedBehaviorSanitizer.

View File

@@ -18,7 +18,7 @@
#ifdef IN_LIBXML #ifdef IN_LIBXML
#ifdef __GNUC__ #ifdef __GNUC__
#ifdef PIC #ifdef PIC
#ifdef linux #ifdef __linux__
#if (__GNUC__ == 3 && __GNUC_MINOR__ >= 3) || (__GNUC__ > 3) #if (__GNUC__ == 3 && __GNUC_MINOR__ >= 3) || (__GNUC__ > 3)
#include "libxml/c14n.h" #include "libxml/c14n.h"