for example
file test--include.c:
-----
#include <sys/stat.h>
int main(){}
------
attempt to compile:
-----
>qcc test-include.c
----
gives following output:
----
/usr/include/x86_64-linux-gnu/sys/stat.h:206: warning: Basilisk C parse error near `const char *__restrict __file,
struct stat *__restrict __buf'
/usr/include/x86_64-linux-gnu/sys/stat.h:225: warning: Basilisk C parse error near `const char *__restrict __file,
struct stat64 *__restrict __buf'
/usr/include/x86_64-linux-gnu/sys/stat.h:235: warning: Basilisk C parse error near `int __fd, const char *__restrict __file,
struct stat *__restrict __buf, int __flag'
/usr/include/x86_64-linux-gnu/sys/stat.h:250: warning: Basilisk C parse error near `int __fd, const char *__restrict __file,
struct stat64 *__restrict __buf, int __flag'
/usr/include/x86_64-linux-gnu/sys/stat.h:260: warning: Basilisk C parse error near `const char *__restrict __file,
struct stat *__restrict __buf'
/usr/include/x86_64-linux-gnu/sys/stat.h:273: warning: Basilisk C parse error near `const char *__restrict __file,
struct stat64 *__restrict __buf'
/usr/include/asm-generic/int-ll64.h:23: warning: Basilisk C parse error near `
# 1 "/usr/include/x86_64-linux-gnu/bits/statx.h" 1 3 4
# 31 "/usr/include/x86_64-linux-gnu/bits/statx.h" 3 4
# 1 "/usr/include/linux/stat.h" 1 3 4
# 1 "/usr/include/linux/types.h" 1 3 4
# 1 "/usr/include/x86_64-linux-gnu/asm/types.h" 1 3 4
# 1 "/usr/include/asm-generic/types.h" 1 3 4
# 1 "/usr/include/asm-generic/int-ll64.h" 1 3 4
# 12 "/usr/include/asm-generic/int-ll64.h" 3 4
# 1 "/usr/include/x86_64-linux-gnu/asm/bitsperlong.h" 1 3 4
# 11 "/usr/include/x86_64-linux-gnu/asm/bitsperlong.h" 3 4
# 1 "/usr/include/asm-generic/bitsperlong.h" 1 3 4
# 12 "/usr/include/x86_64-linux-gnu/asm/bitsperlong.h" 2 3 4
# 13 "/usr/include/asm-generic/int-ll64.h" 2 3 4
typedef __signed__ char __s8;
typedef unsigned char __u8;
typedef __signed__ short __s16'
/usr/include/asm-generic/int-ll64.h:30: warning: Basilisk C parse error near `
typedef __signed__ int __s32;
typedef unsigned int __u32;
__extension__ typedef __signed__ long long __s64'
/usr/include/asm-generic/int-ll64.h:31: warning: Basilisk C parse error near `
__extension__ typedef unsigned long long __u64'
/usr/include/linux/types.h:28: warning: Basilisk C parse error near `
typedef __u64 __le64'
/usr/include/linux/types.h:29: warning: Basilisk C parse error near `
typedef __u64 __be64'
/usr/include/linux/stat.h:59: warning: Basilisk C parse error near `
__s64 tv_sec;
__u32 tv_nsec;
__s32 __reserved;'
/usr/include/linux/stat.h:129: warning: Basilisk C parse error near `
__u32 stx_mask;
__u32 stx_blksize;
__u64 stx_attributes;
__u32 stx_nlink;
__u32 stx_uid;
__u32 stx_gid;
__u16 stx_mode;
__u16 __spare0[1];
__u64 stx_ino;
__u64 stx_size;
__u64 stx_blocks;
__u64 stx_attributes_mask;
struct statx_timestamp stx_atime;
struct statx_timestamp stx_btime;
struct statx_timestamp stx_ctime;
struct statx_timestamp stx_mtime;
__u32 stx_rdev_major;
__u32 stx_rdev_minor;
__u32 stx_dev_major;
__u32 stx_dev_minor;
__u64 stx_mnt_id;
__u64 __spare2;
__u64 __spare3[12];'
/usr/include/x86_64-linux-gnu/bits/statx-generic.h:61: warning: Basilisk C parse error near `int __dirfd, const char *__restrict __path, int __flags,
unsigned int __mask, struct statx *__restrict __buf'
.qccQGDkfo/include-test.c:1:7: warning: line number out of range
include-test-cpp.c: warning: line number out of range
<built-in>: warning: line number out of range
/usr/include/stdc-predef.h:1:7: warning: line number out of range
/usr/include/x86_64-linux-gnu/bits/types.h:155:34: error: conflicting types for '__fsid_t'; have 'struct <anonymous>'
In file included from /usr/include/stdint.h:27,
from /usr/lib/gcc/x86_64-linux-gnu/11/include/stdint.h:9,
from include-test-cpp.c:6:
/usr/include/x86_64-linux-gnu/bits/types.h:155:26: note: previous declaration of '__fsid_t' with type '__fsid_t'
/usr/include/x86_64-linux-gnu/bits/types/struct_timespec.h:10:8: error: redefinition of 'struct timespec'
In file included from /usr/include/x86_64-linux-gnu/sys/select.h:39,
from /usr/include/x86_64-linux-gnu/sys/types.h:179,
from /usr/include/stdlib.h:394,
from /home/fedor/flood/basilisk-my/ast/std/stdlib.h:1:
/usr/include/x86_64-linux-gnu/bits/types/struct_timespec.h:10:8: note: originally defined here
----