From c1eb744ff0a82cf6c8e3470ac10e2f417c7d9de2 Mon Sep 17 00:00:00 2001 From: Andrew Kaster Date: Mon, 18 May 2020 18:54:51 -0600 Subject: Build: Include headers from LibC, LibM, and LibPthread with -isystem Make sure that userspace is always referencing "system" headers in a way that would build on target :). This means removing the explicit include_directories of Libraries/LibC in favor of having it export its headers as SYSTEM. Also remove a redundant include_directories of Libraries in the 'serenity build' part of the build script. It's already set at the top. This causes issues for the Kernel, and for crt0.o. These special cases are handled individually. --- Kernel/CMakeLists.txt | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Kernel') diff --git a/Kernel/CMakeLists.txt b/Kernel/CMakeLists.txt index 6ef6d24296..f6684df8ce 100644 --- a/Kernel/CMakeLists.txt +++ b/Kernel/CMakeLists.txt @@ -161,6 +161,9 @@ if (${CMAKE_HOST_SYSTEM_NAME} MATCHES SerenityOS) else() include_directories(../Toolchain/Local/i686-pc-serenity/include/c++/10.1.0/) include_directories(../Toolchain/Local/i686-pc-serenity/include/c++/10.1.0/i686-pc-serenity/) + # FIXME: Many files include and + # With -nostdinc, this makes it interesting to include these headers properly + include_directories(../Libraries/LibC) endif() add_executable(Kernel ${SOURCES}) -- cgit v1.2.3