mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-12 19:18:20 +00:00
Use ninja instead of makefiles
This commit is contained in:
parent
1afd1a32d1
commit
e31f255a65
12
.github/workflows/build.yaml
vendored
12
.github/workflows/build.yaml
vendored
|
@ -17,8 +17,7 @@ jobs:
|
||||||
os: [ubuntu-latest, macOS-latest, windows-latest, ubuntu-18.04]
|
os: [ubuntu-latest, macOS-latest, windows-latest, ubuntu-18.04]
|
||||||
include:
|
include:
|
||||||
- os: ubuntu-latest
|
- os: ubuntu-latest
|
||||||
cmake-args: -G "Unix Makefiles"
|
cmake-args: -G Ninja
|
||||||
build-args: --parallel
|
|
||||||
package-file: DDNet-*-linux_x86_64.tar.xz
|
package-file: DDNet-*-linux_x86_64.tar.xz
|
||||||
fancy: true
|
fancy: true
|
||||||
env:
|
env:
|
||||||
|
@ -26,7 +25,7 @@ jobs:
|
||||||
CXXFLAGS: -Werror
|
CXXFLAGS: -Werror
|
||||||
- os: ubuntu-18.04
|
- os: ubuntu-18.04
|
||||||
cmake-path: /usr/bin/
|
cmake-path: /usr/bin/
|
||||||
cmake-args: -G "Unix Makefiles"
|
cmake-args: -G Ninja
|
||||||
package-file: DDNet-*-linux_x86_64.tar.xz
|
package-file: DDNet-*-linux_x86_64.tar.xz
|
||||||
fancy: false
|
fancy: false
|
||||||
env:
|
env:
|
||||||
|
@ -34,8 +33,7 @@ jobs:
|
||||||
CXXFLAGS: -Werror
|
CXXFLAGS: -Werror
|
||||||
GTEST_FILTER: -*SQLite*
|
GTEST_FILTER: -*SQLite*
|
||||||
- os: macOS-latest
|
- os: macOS-latest
|
||||||
cmake-args: -G "Unix Makefiles"
|
cmake-args: -G Ninja
|
||||||
build-args: --parallel
|
|
||||||
package-file: DDNet-*-macos.dmg
|
package-file: DDNet-*-macos.dmg
|
||||||
fancy: false
|
fancy: false
|
||||||
env:
|
env:
|
||||||
|
@ -59,7 +57,7 @@ jobs:
|
||||||
if: contains(matrix.os, 'ubuntu')
|
if: contains(matrix.os, 'ubuntu')
|
||||||
run: |
|
run: |
|
||||||
sudo apt-get update -y
|
sudo apt-get update -y
|
||||||
sudo apt-get install pkg-config cmake libfreetype6-dev libnotify-dev libsdl2-dev libsqlite3-dev -y
|
sudo apt-get install pkg-config cmake ninja-build libfreetype6-dev libnotify-dev libsdl2-dev libsqlite3-dev -y
|
||||||
|
|
||||||
- name: Prepare Linux (fancy)
|
- name: Prepare Linux (fancy)
|
||||||
if: contains(matrix.os, 'ubuntu') && matrix.fancy
|
if: contains(matrix.os, 'ubuntu') && matrix.fancy
|
||||||
|
@ -80,7 +78,7 @@ jobs:
|
||||||
if: contains(matrix.os, 'macOS')
|
if: contains(matrix.os, 'macOS')
|
||||||
run: |
|
run: |
|
||||||
brew update || true
|
brew update || true
|
||||||
brew install pkg-config sdl2 python3
|
brew install pkg-config sdl2 python3 ninja
|
||||||
brew upgrade freetype
|
brew upgrade freetype
|
||||||
pip3 install dmgbuild
|
pip3 install dmgbuild
|
||||||
sudo rm -rf /Library/Developer/CommandLineTools
|
sudo rm -rf /Library/Developer/CommandLineTools
|
||||||
|
|
6
.github/workflows/clang-tidy.yml
vendored
6
.github/workflows/clang-tidy.yml
vendored
|
@ -20,11 +20,11 @@ jobs:
|
||||||
- name: Install clang-tidy
|
- name: Install clang-tidy
|
||||||
run: |
|
run: |
|
||||||
sudo apt-get update -y
|
sudo apt-get update -y
|
||||||
sudo apt-get install pkg-config cmake libfreetype6-dev libnotify-dev libsdl2-dev libsqlite3-dev clang-tidy -y
|
sudo apt-get install pkg-config cmake ninja-build libfreetype6-dev libnotify-dev libsdl2-dev libsqlite3-dev clang-tidy -y
|
||||||
- name: Build with clang-tidy
|
- name: Build with clang-tidy
|
||||||
run: |
|
run: |
|
||||||
mkdir clang-tidy
|
mkdir clang-tidy
|
||||||
cd clang-tidy
|
cd clang-tidy
|
||||||
cmake -G "Unix Makefiles" -DCMAKE_CXX_CLANG_TIDY="clang-tidy;-warnings-as-errors=*" -DCMAKE_C_CLANG_TIDY="clang-tidy;-warnings-as-errors=*" -DCMAKE_BUILD_TYPE=Debug -Werror=dev -DCMAKE_RUNTIME_OUTPUT_DIRECTORY_RELEASE=. ..
|
cmake -G Ninja -DCMAKE_CXX_CLANG_TIDY="clang-tidy;-warnings-as-errors=*" -DCMAKE_C_CLANG_TIDY="clang-tidy;-warnings-as-errors=*" -DCMAKE_BUILD_TYPE=Debug -Werror=dev -DCMAKE_RUNTIME_OUTPUT_DIRECTORY_RELEASE=. ..
|
||||||
cmake --build . --config Debug --parallel --target everything -- --keep-going
|
cmake --build . --config Debug --target everything -- -k 0
|
||||||
|
|
||||||
|
|
2
.github/workflows/codeql-analysis.yaml
vendored
2
.github/workflows/codeql-analysis.yaml
vendored
|
@ -55,7 +55,7 @@ jobs:
|
||||||
run: |
|
run: |
|
||||||
mkdir release
|
mkdir release
|
||||||
cd release
|
cd release
|
||||||
cmake -G "Ninja" -DCMAKE_BUILD_TYPE=RelWithDebInfo -DANTIBOT=ON -DMYSQL=ON -DWEBSOCKETS=ON ..
|
cmake -G Ninja -DCMAKE_BUILD_TYPE=RelWithDebInfo -DANTIBOT=ON -DMYSQL=ON -DWEBSOCKETS=ON ..
|
||||||
cmake --build . --config RelWithDebInfo --target everything
|
cmake --build . --config RelWithDebInfo --target everything
|
||||||
|
|
||||||
- name: Perform CodeQL Analysis
|
- name: Perform CodeQL Analysis
|
||||||
|
|
6
.github/workflows/style.yml
vendored
6
.github/workflows/style.yml
vendored
|
@ -19,11 +19,11 @@ jobs:
|
||||||
- name: Prepare
|
- name: Prepare
|
||||||
run: |
|
run: |
|
||||||
sudo apt-get update -y
|
sudo apt-get update -y
|
||||||
sudo apt-get install clang-format imagemagick ddnet-tools shellcheck pkg-config cmake libfreetype6-dev libnotify-dev libsdl2-dev libsqlite3-dev pylint3 python3-clang -y
|
sudo apt-get install clang-format imagemagick ddnet-tools shellcheck pkg-config cmake ninja-build libfreetype6-dev libnotify-dev libsdl2-dev libsqlite3-dev pylint3 python3-clang -y
|
||||||
mkdir release
|
mkdir release
|
||||||
cd release
|
cd release
|
||||||
cmake -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=Release -DDOWNLOAD_GTEST=OFF -DCMAKE_RUNTIME_OUTPUT_DIRECTORY_RELEASE=. ..
|
cmake -G Ninja -DCMAKE_BUILD_TYPE=Release -DDOWNLOAD_GTEST=OFF -DCMAKE_RUNTIME_OUTPUT_DIRECTORY_RELEASE=. ..
|
||||||
cmake --build . --config Release --target dilate --parallel
|
cmake --build . --config Release --target dilate
|
||||||
- name: Check clang-format
|
- name: Check clang-format
|
||||||
run: clang-format -version
|
run: clang-format -version
|
||||||
- name: Check fix_style
|
- name: Check fix_style
|
||||||
|
|
Loading…
Reference in a new issue