build: Suppress compilation warnings from capnproto headers

We now treat capnproto headers as system headers when included in other
tools, which suppresses any warnings generated from them. This keeps the
build process clean and warning free
diff --git a/libs/EXTERNAL/CMakeLists.txt b/libs/EXTERNAL/CMakeLists.txt
index 15c5988..38a14d7 100644
--- a/libs/EXTERNAL/CMakeLists.txt
+++ b/libs/EXTERNAL/CMakeLists.txt
@@ -35,4 +35,11 @@
     endif()
 
     add_subdirectory(capnproto EXCLUDE_FROM_ALL)
+
+    #Some capnproto kj headers (e.g. filesystem.h) generate warnings, treat them as system headers to suppress warnings
+    #We suppress them here since we include the capnproto sub-tree as is and do not modify its CMakeLists.txts
+    target_include_directories(kj SYSTEM INTERFACE
+      $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/capnproto/c++/src>
+      $<INSTALL_INTERFACE:include>
+    )
 endif()