summaryrefslogtreecommitdiff
path: root/Documentation
diff options
context:
space:
mode:
authorAndrew Kaster <akaster@serenityos.org>2022-12-17 15:39:53 -0700
committerAndrew Kaster <andrewdkaster@gmail.com>2022-12-17 22:21:43 -0700
commit75f7a164a6aa592d1f28a9e8feb412d610f7a968 (patch)
treee8e82d9f178b5d07e187fe15cc5754572729bbf1 /Documentation
parent37517ba8bba274360b51c52d10154c37fbe38f73 (diff)
downloadserenity-75f7a164a6aa592d1f28a9e8feb412d610f7a968.zip
Documentation: Clarify that clang can be used as a host compiler
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/BuildInstructions.md4
-rw-r--r--Documentation/BuildInstructionsMacOS.md18
2 files changed, 16 insertions, 6 deletions
diff --git a/Documentation/BuildInstructions.md b/Documentation/BuildInstructions.md
index 7fd39087be..3d38c6d7dc 100644
--- a/Documentation/BuildInstructions.md
+++ b/Documentation/BuildInstructions.md
@@ -11,7 +11,9 @@ sudo apt install build-essential cmake curl libmpfr-dev libmpc-dev libgmp-dev e2
```
Optional: `fuse2fs` for [building images without root](https://github.com/SerenityOS/serenity/pull/11224).
-#### GCC 12
+#### GCC 12 or Clang 13
+
+A host compiler that supports C++20 features is required for building host tools, the newer the better. Tested versions include gcc-12 and clang-13.
On Ubuntu gcc-12 is available in the repositories of 22.04 (Jammy) and later.
If you are running an older version, you will either need to upgrade, or find an alternative installation source.
diff --git a/Documentation/BuildInstructionsMacOS.md b/Documentation/BuildInstructionsMacOS.md
index eae2b3e4fa..6920179660 100644
--- a/Documentation/BuildInstructionsMacOS.md
+++ b/Documentation/BuildInstructionsMacOS.md
@@ -13,7 +13,7 @@ Make sure you also have all the following dependencies installed:
```console
# core
-brew install coreutils e2fsprogs qemu bash gcc@12 imagemagick ninja cmake ccache rsync zstd
+brew install coreutils e2fsprogs qemu bash imagemagick ninja cmake ccache rsync zstd
# (option 1) fuse + ext2
brew install m4 autoconf automake libtool
@@ -24,14 +24,22 @@ Toolchain/BuildFuseExt2.sh
brew install genext2fs
```
+If you have Xcode version 13 or older, also install a newer host compiler from homebrew. Xcode 14 is known to work.
+
+```console
+brew install llvm@15
+# OR
+brew install gcc@12
+```
+
+# Notes
+
If you're building on M1 Mac and have Homebrew installed in both Rosetta and native environments,
you have to make sure that required packages are installed only in one of the environments. Otherwise,
these installations can conflict during the build process, which is manifested in hard to diagnose issues.
Building on M1 natively without Rosetta is recommended, as the build process should be faster without Rosetta
overhead.
-Notes:
+Installing macfuse for the first time requires enabling its system extension in System Preferences and then restarting your machine. The output from installing macfuse with brew says this, but it's easy to miss.
-- Installing macfuse for the first time requires enabling its system extension in System Preferences and then restarting
- your machine. The output from installing macfuse with brew says this, but it's easy to miss.
-- It's important to make sure that Xcode is not only installed but also accordingly updated, otherwise CMake will run into incompatibilities with GCC.
+It's important to make sure that Xcode is not only installed but also accordingly updated, otherwise CMake will run into incompatibilities with GCC.