Skip to content

Commit e78527c

Browse files
committed
moved clang includes out of /usr/include
sharing a single root leads to an undesirable "clang" completion, and wasi-sdk keeps the include root separate as well
1 parent 22e380e commit e78527c

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

docker/.clangd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
Security:
2-
AccessibleDirectories: [ "/work/c", "/usr/include" ]
2+
AccessibleDirectories: [ "/work/c", "/usr/include", "/usr/lib/clang" ]
33

docker/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ COPY run.sh .
1414
ADD compile_flags.txt /etc/clangd/compile_flags.txt
1515
ADD .clang-tidy /work/.clang-tidy
1616
ADD .clangd /work/.clangd
17-
RUN cp -alf ./clang/includes /work/c && cp -alf clang/wasi-sdk/share/wasi-sysroot/include /usr && mkdir -p /usr/include/clang/15.0.0 && cp -alf clang/wasi-sdk/lib/clang/15.0.0/include /usr/include/clang/15.0.0
17+
RUN cp -alf ./clang/includes /work/c && cp -alf clang/wasi-sdk/share/wasi-sysroot/include /usr && mkdir -p /usr/lib/clang/15.0.0 && cp -alf clang/wasi-sdk/lib/clang/15.0.0/include /usr/lib/clang/15.0.0
1818
RUN addgroup -S appgroup && adduser -S appuser -G appgroup -h /app && chown appuser:appgroup /app
1919
RUN yarn && yarn build
2020
EXPOSE $PORT

docker/compile_flags.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
-xc
2-
-isystem/usr/include/clang/15.0.0/include
2+
-isystem/usr/lib/clang/15.0.0/include
33
-Wno-pointer-to-int-cast
44
-Wno-int-conversion
55
-Werror=implicit-function-declaration

0 commit comments

Comments
 (0)