From 4be2334ac92a8377def0e54c2b1c804295146a4f Mon Sep 17 00:00:00 2001 From: Andrey Akhmichin <15944199+nekonomicon@users.noreply.github.com> Date: Thu, 7 Dec 2023 05:32:10 +0500 Subject: [PATCH] Update README.md. --- README.md | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 706fa58a..68c838cd 100644 --- a/README.md +++ b/README.md @@ -186,7 +186,14 @@ cmake --build build Note that the libraries built this way might be not compatible with Steam Half-Life. If you have such issue you can configure it to build statically with c++ and gcc libraries: ``` -cmake .. -DCMAKE_C_FLAGS="-static-libstdc++ -static-libgcc" +cd build +cmake .. -DCMAKE_CXX_FLAGS="-static-libstdc++ -static-libgcc" +``` + +Alternatively, you can avoid libstdc++/libgcc_s linking using small libsupc++ library and optimization build flags instead: +``` +cd build +cmake .. -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=gcc -DCMAKE_C_FLAGS="-O3" -DCMAKE_CXX_FLAGS="-O3 -lsupc++" ``` To ensure portability it's still better to build using Steam Runtime or another chroot of some older distro.