2023-07-19 03:18:34 -04:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
# Build the LCPU addon for the reccomended environment
|
2023-07-19 06:31:07 -04:00
|
|
|
# and install it into the proper directory gmod wants native modules to be.
|
2023-07-19 03:18:34 -04:00
|
|
|
|
|
|
|
set -x
|
|
|
|
|
2023-07-24 06:50:18 -04:00
|
|
|
# where your game server is
|
|
|
|
GS_PATH="/home/lily/gs/gmod"
|
2023-07-19 03:18:34 -04:00
|
|
|
|
2023-07-24 06:50:18 -04:00
|
|
|
cmake -Wno-dev -GNinja -S native -B module_build -DCMAKE_BUILD_TYPE=Release
|
|
|
|
ninja -C module_build
|
|
|
|
|
|
|
|
[[ ! -d "$GS_PATH/garrysmod/lua/bin" ]] && {
|
|
|
|
mkdir -p $GS_PATH/garrysmod/lua/bin
|
2023-07-19 03:18:34 -04:00
|
|
|
}
|
|
|
|
|
2023-07-24 06:50:18 -04:00
|
|
|
cp -v module_build/projects/lcpu/*.dll $GS_PATH/garrysmod/lua/bin
|