From 1876171efda3cf69e0671b9f80afe6a4bae47e94 Mon Sep 17 00:00:00 2001 From: Arnaud Sautaux Date: Wed, 11 Jun 2025 08:26:02 +0200 Subject: [PATCH] Update source.md according to Filesystem Hierarchy Standard According to https://refspecs.linuxfoundation.org/FHS_3.0/fhs/ch04s09.html it is recommended to install to `/usr/local` instead of `/usr` --- site/en/install/source.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/site/en/install/source.md b/site/en/install/source.md index 97bedb7444..911d599b44 100644 --- a/site/en/install/source.md +++ b/site/en/install/source.md @@ -70,7 +70,7 @@ package sources: sudo apt-get update && sudo apt-get install -y llvm-17 clang-17 -Now that `/usr/lib/llvm-17/bin/clang` is the actual path to clang in this case. +Now that `/usr/local/lib/llvm-17/bin/clang` is the actual path to clang in this case. Alternatively, you can download and unpack the pre-built [Clang + LLVM 17](https://github.com/llvm/llvm-project/releases/tag/llvmorg-17.0.2). @@ -88,13 +88,13 @@ Below is an example of steps you can take to set up the downloaded Clang + LLVM -1. Copy the extracted contents (directories and files) to `/usr` (you may need +1. Copy the extracted contents (directories and files) to `/usr/local` (you may need sudo permissions, and the correct directory may vary by distribution). This effectively installs Clang and LLVM, and adds it to the path. You should not have to replace anything, unless you have a previous installation, in which case you should replace the files:
-    cp -r clang+llvm-17.0.2-x86_64-linux-gnu-ubuntu-22.04/* /usr
+    cp -r clang+llvm-17.0.2-x86_64-linux-gnu-ubuntu-22.04/* /usr/local
     
1. Check the obtained Clang + LLVM 17 binaries version: @@ -102,7 +102,7 @@ Below is an example of steps you can take to set up the downloaded Clang + LLVM clang --version -1. Now that `/usr/bin/clang` is the actual path to your new clang. You can run +1. Now that `/usr/local/bin/clang` is the actual path to your new clang. You can run the `./configure` script or manually set environment variables `CC` and `BAZEL_COMPILER` to this path.