From f3213d5057e037f7e20e4ec04ba8e5bb2b944db8 Mon Sep 17 00:00:00 2001 From: Emil J Date: Tue, 22 Oct 2024 12:45:06 +0200 Subject: [PATCH] README: tell macOS users to use brew clang with LTO --- README.md | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 3845d2502..02495c71a 100644 --- a/README.md +++ b/README.md @@ -130,9 +130,15 @@ lld by enabling LTO: $ make ENABLE_LTO=1 +On macOS, LTO requires using clang from homebrew which isn't in PATH +rather than xcode clang. + +$ make ENABLE_LTO=1 CXX=$(brew --prefix)/opt/llvm/bin/clang++ + For other compilers and build configurations it might be necessary to make some changes to the config section of the -Makefile. +Makefile. It's also an alternative way to set the make variables +mentioned above. $ vi Makefile # ..or.. $ vi Makefile.conf