Toolchain: Support building the toolchain with Ninja (#2504)

This change allows users to use CMAKE_GENERATOR=Ninja ./BuildIt.sh

BuildIt.sh assumes the default cmake generator is Make. However,
the user may specify CMAKE_GENERATOR=Ninja, for example, to set the
default generator. Therefore, instead of calling make to build the
LibC target we should call cmake --build to use the correct generated
files.
This commit is contained in:
Paul Redmond 2020-06-05 03:31:10 -04:00 committed by GitHub
parent 7675812efd
commit 1a56fe714c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
Notes: sideshowbarker 2024-07-19 05:49:29 +09:00

View file

@ -229,7 +229,7 @@ pushd "$DIR/Build/"
mkdir -p "$BUILD" mkdir -p "$BUILD"
pushd "$BUILD" pushd "$BUILD"
CXXFLAGS="-DBUILDING_SERENITY_TOOLCHAIN" cmake .. CXXFLAGS="-DBUILDING_SERENITY_TOOLCHAIN" cmake ..
"$MAKE" LibC cmake --build . --target LibC
install -D Libraries/LibC/libc.a Libraries/LibM/libm.a Root/usr/lib/ install -D Libraries/LibC/libc.a Libraries/LibM/libm.a Root/usr/lib/
SRC_ROOT=$(realpath "$DIR"/..) SRC_ROOT=$(realpath "$DIR"/..)
for header in "$SRC_ROOT"/Libraries/Lib{C,M}/**/*.h; do for header in "$SRC_ROOT"/Libraries/Lib{C,M}/**/*.h; do