From e4c7cf1568aa72a76af23fca204af4f27c79adda Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kai=20Wasserb=C3=A4ch?= Date: Sat, 17 Sep 2022 11:53:26 +0200 Subject: [PATCH] chore(docs): rusticl: improve list of build dependencies MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit v2: - added more requirements for LLVM (thanks Mike Lothian (@FireBurn)). v3: - note the optional cases for rustfmt (thanks @LingMan) - remove the part about the SPIR-V target for LLVM (thanks Karol Herbst (@karolherbst)) v4: - added minimum version requirements (thanks Karol Herbst (@karolherbst)) Signed-off-by: Kai Wasserbäch Reviewed-by: Karol Herbst Part-of: --- docs/rusticl.rst | 27 +++++++++++++++++++++++---- 1 file changed, 23 insertions(+), 4 deletions(-) diff --git a/docs/rusticl.rst b/docs/rusticl.rst index 25306243d64..c162f81837c 100644 --- a/docs/rusticl.rst +++ b/docs/rusticl.rst @@ -1,10 +1,29 @@ Rusticl ======= -The easiest way to build Rusticl is by either installing ``rustc``, -``rustfmt`` and ``bindgen`` from your distribution or to simply use -rustup. Just make sure that the ``rustfmt`` and ``bindgen`` components -are installed. Then simply add ``-Dgallium-rusticl=true -Dllvm=enabled +To build Rusticl you need to satisfy the following build dependencies: + +- ``rustc`` +- ``rustfmt`` (highly recommended, but only *required* for CI builds + or when authoring patches) +- ``bindgen`` +- `LLVM `__ built with + ``libclc`` and ``-DLLVM_ENABLE_DUMP=ON``. +- `SPIRV-Tools `__ +- `SPIRV-LLVM-Translator + `__ for a + ``libLLVMSPIRVLib.so`` matching your version of LLVM, ie. if you're + using LLVM 15 (``libLLVM.so.15``), then you need a + ``libLLVMSPIRVLib.so.15``. + +The minimum versions to build Rusticl are: + +- Rust: 1.59 +- Meson: 0.61.4 +- LLVM: 11.0.0 (recommended: 15.0.0) +- SPIRV-Tools: any version (recommended: v2022.3) + +Afterwards you only need to add ``-Dgallium-rusticl=true -Dllvm=enabled -Drust_std=2021`` to your build options. Most of the code related to Mesa's C code lives inside ``/mesa``, with