👷 use clang & mold by default

This commit is contained in:
Vladislav Nepogodin 2022-07-30 23:15:36 +04:00
parent 6b772b1a78
commit fec49d8db0
No known key found for this signature in database
GPG Key ID: B62C3D10C54D5DA9
2 changed files with 11 additions and 3 deletions

View File

@ -9,7 +9,7 @@ Fast and smooth installer for Arch based operating system.
Requirements Requirements
------------ ------------
* C++20 feature required (tested with GCC 11.1.0 and Clang 13(clang will not compile it with libstdc++ 11.1.0 because of c++20 standard ranges library) * C++20 feature required (tested with GCC 11.1.0 and Clang 13)
Any compiler which support C++20 standard should work. Any compiler which support C++20 standard should work.
###### ######
@ -19,7 +19,7 @@ This is tested on Arch Linux, but *any* recent Linux with latest C++20 compiler
```sh ```sh
sudo pacman -Sy \ sudo pacman -Sy \
base-devel cmake pkg-config make base-devel cmake pkg-config ninja clang mold llvm
``` ```
### Cloning the source code ### Cloning the source code
@ -62,7 +62,7 @@ pass `-DENABLE_DEVENV=OFF` to cmake or `-Ddevenv=false` to meson when configurin
* [Fast C++ logging library](https://github.com/gabime/spdlog) used for logging process of the installer. * [Fast C++ logging library](https://github.com/gabime/spdlog) used for logging process of the installer.
* [Parsing gigabytes of JSON per second](https://github.com/simdjson/simdjson) used for config deserialization. * [Parsing gigabytes of JSON per second](https://github.com/simdjson/simdjson) used for config deserialization.
* [Curl for People](https://github.com/libcpr/cpr) used for connection check and maybe in future fetching netinstall config from github. * [Curl for People](https://github.com/libcpr/cpr) used for connection check and maybe in future fetching netinstall config from github.
* [Ranges](https://github.com/ericniebler/range-v3) used for ranges support with clang. * [Ranges](https://github.com/ericniebler/range-v3) used for ranges support.
**Simple menu overview:** **Simple menu overview:**

View File

@ -63,7 +63,15 @@ for i in "$@"; do
esac esac
done done
export AR=llvm-ar
export CC=clang
export CXX=clang++
export NM=llvm-nm
export RANLIB=llvm-ranlib
cmake -S . -B ${_buildpath}/${_buildtype} \ cmake -S . -B ${_buildpath}/${_buildtype} \
-GNinja \
-DCMAKE_EXE_LINKER_FLAGS="-fuse-ld=mold" \
-DCMAKE_BUILD_TYPE=${_buildtype} \ -DCMAKE_BUILD_TYPE=${_buildtype} \
-DCMAKE_INSTALL_PREFIX=${_prefix} \ -DCMAKE_INSTALL_PREFIX=${_prefix} \
-DCMAKE_INSTALL_LIBDIR=${_libdir} -DCMAKE_INSTALL_LIBDIR=${_libdir}