Suggest /usr/local/include instead of /usr/include
mattfbacon opened this issue · 3 comments
mattfbacon commented
The section in the readme which suggests manually installing the header to /usr/include
should really suggest using /usr/local/include
for this instead, because it is meant for this kind of manual installation of files.
sharkdp commented
Sounds good. Is /usr/local/include in the standard include path for gcc, clang, …?
mattfbacon commented
$ echo | gcc -E -Wp,-v -
ignoring nonexistent directory "/usr/lib/gcc/x86_64-pc-linux-gnu/13.2.1/../../../../x86_64-pc-linux-gnu/include"
#include "..." search starts here:
#include <...> search starts here:
/usr/lib/gcc/x86_64-pc-linux-gnu/13.2.1/include
/usr/local/include
/usr/lib/gcc/x86_64-pc-linux-gnu/13.2.1/include-fixed
/usr/include
End of search list.
# 0 "<stdin>"
# 0 "<built-in>"
# 0 "<command-line>"
# 1 "/usr/include/stdc-predef.h" 1 3 4
# 0 "<command-line>" 2
# 1 "<stdin>"
$ echo | clang -E -Wp,-v -
clang -cc1 version 16.0.6 based upon LLVM 16.0.6 default target x86_64-pc-linux-gnu
ignoring nonexistent directory "/usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/13.2.1/../../../../x86_64-pc-linux-gnu/include"
ignoring nonexistent directory "/include"
#include "..." search starts here:
#include <...> search starts here:
/usr/lib/clang/16/include
/usr/local/include
/usr/include
End of search list.
# 1 "<stdin>"
# 1 "<built-in>" 1
# 1 "<built-in>" 3
# 375 "<built-in>" 3
# 1 "<command line>" 1
# 1 "<built-in>" 2
# 1 "<stdin>" 2
Yes. It even comes before /usr/include, to allow overriding system stuff with local stuff.
sharkdp commented
Thank you. Fixed.