mirror of
https://github.com/nillerusr/source-engine.git
synced 2025-02-09 21:54:19 +00:00
remade ci
This commit is contained in:
parent
974cf6d842
commit
5a22429e76
182
.github/workflows/build.yml
vendored
182
.github/workflows/build.yml
vendored
@ -1,111 +1,109 @@
|
|||||||
name: Build
|
name: Build
|
||||||
|
|
||||||
on: [push, pull_request]
|
on: [push, pull_request]
|
||||||
|
env:
|
||||||
|
WAF_FLAGS: -T debug --no-warns --prefix=build_hl2
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-linux-i386:
|
build-linux:
|
||||||
runs-on: ubuntu-latest
|
strategy:
|
||||||
|
matrix:
|
||||||
|
os: [ubuntu-latest]
|
||||||
|
bits: ['', '--64bits']
|
||||||
|
android: ['']
|
||||||
|
dedicated: ['', '-dl']
|
||||||
|
include:
|
||||||
|
- os: ubuntu-20.04
|
||||||
|
bits: ''
|
||||||
|
android: '--android=armeabi-v7a-hard,4.9,21 --use-togles'
|
||||||
|
dedicated: ''
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
|
env:
|
||||||
|
DEPS: libopenal-dev libpng-dev libjpeg-dev libfreetype6-dev libfontconfig1-dev libcurl4-gnutls-dev libsdl2-dev zlib1g-dev libbz2-dev libedit-dev
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
- name: Build linux-i386
|
with:
|
||||||
|
submodules: recursive
|
||||||
|
|
||||||
|
- name: Install common dependencies
|
||||||
|
run: sudo apt-get update && sudo apt-get install -y g++-multilib gcc-multilib
|
||||||
|
- name: Install 32bit dependencies
|
||||||
|
if: ${{ matrix.bits == '' && !matrix.android }}
|
||||||
run: |
|
run: |
|
||||||
scripts/build-ubuntu-i386.sh -u
|
sudo dpkg --add-architecture i386
|
||||||
|
sudo apt-get update
|
||||||
build-linux-amd64:
|
sudo apt-get install -y aptitude
|
||||||
runs-on: ubuntu-20.04
|
sudo aptitude install -y $(echo $DEPS | sed -r 's/[a-z0-9_\-]+/&:i386/g')
|
||||||
|
- name: Install Android dependencies
|
||||||
steps:
|
if: ${{ matrix.android != '' }}
|
||||||
- uses: actions/checkout@v2
|
|
||||||
- name: Build linux-amd64
|
|
||||||
run: |
|
run: |
|
||||||
scripts/build-ubuntu-amd64.sh -u
|
wget https://dl.google.com/android/repository/android-ndk-r10e-linux-x86_64.zip -o /dev/null
|
||||||
|
unzip android-ndk-r10e-linux-x86_64.zip
|
||||||
build-android-armv7a:
|
export NDK_HOME=$PWD/android-ndk-r10e/
|
||||||
runs-on: ubuntu-20.04
|
echo "NDK_HOME=$NDK_HOME" >> $GITHUB_ENV
|
||||||
|
echo "ANDROID_NDK_HOME=$NDK_HOME" >> $GITHUB_ENV
|
||||||
steps:
|
- name: Install 64bit dependencies
|
||||||
- uses: actions/checkout@v2
|
if: ${{ matrix.bits != '' }}
|
||||||
- name: Build android-armv7a
|
|
||||||
run: |
|
run: |
|
||||||
scripts/build-android-armv7a.sh
|
sudo apt-get install -y $DEPS
|
||||||
|
|
||||||
build-windows-i386:
|
- if: ${{ matrix.bits == '' && !matrix.android }}
|
||||||
runs-on: windows-2019
|
name: Set PKG_CONFIG_PATH
|
||||||
|
run: echo "PKG_CONFIG_PATH=/usr/lib/i386-linux-gnu/pkgconfig" >> $GITHUB_ENV
|
||||||
|
|
||||||
steps:
|
- name: Configure
|
||||||
- uses: actions/checkout@v2
|
run: ./waf configure ${{ matrix.bits }} ${{ matrix.android }} ${{ matrix.dedicated }} $WAF_FLAGS
|
||||||
- name: Build windows-i386
|
- name: Build ${{ matrix.os }}
|
||||||
run: |
|
run: ./waf install
|
||||||
git submodule init && git submodule update
|
- name: Tar binaries
|
||||||
./waf.bat configure -T debug -u
|
run: tar cvf build.tar build_hl2
|
||||||
./waf.bat build
|
- name: Upload artifact
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: Linux${{matrix.bits}}${{matrix.dedicated}}${{matrix.android}}.tar
|
||||||
|
path: build.tar
|
||||||
|
|
||||||
build-windows-amd64:
|
build-macos:
|
||||||
runs-on: windows-2019
|
strategy:
|
||||||
|
matrix:
|
||||||
|
dedicated: ['', '-dl']
|
||||||
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v2
|
|
||||||
- name: Build windows-amd64
|
|
||||||
run: |
|
|
||||||
git submodule init && git submodule update
|
|
||||||
./waf.bat configure -T debug -8 -u
|
|
||||||
./waf.bat build
|
|
||||||
|
|
||||||
build-dedicated-windows-i386:
|
|
||||||
runs-on: windows-2019
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v2
|
|
||||||
- name: Build dedicated windows-i386
|
|
||||||
run: |
|
|
||||||
git submodule init && git submodule update
|
|
||||||
./waf.bat configure -T debug -dl
|
|
||||||
./waf.bat build
|
|
||||||
|
|
||||||
build-dedicated-windows-amd64:
|
|
||||||
runs-on: windows-2019
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v2
|
|
||||||
- name: Build dedicated windows-amd64
|
|
||||||
run: |
|
|
||||||
git submodule init && git submodule update
|
|
||||||
./waf.bat configure -T debug -dl -8
|
|
||||||
./waf.bat build
|
|
||||||
|
|
||||||
build-dedicated-linux-i386:
|
|
||||||
runs-on: ubuntu-20.04
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v2
|
|
||||||
- name: Build dedicated linux-i386
|
|
||||||
run: |
|
|
||||||
scripts/build-ubuntu-i386.sh -dl
|
|
||||||
|
|
||||||
build-dedicated-linux-amd64:
|
|
||||||
runs-on: ubuntu-20.04
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v2
|
|
||||||
- name: Build dedicated linux-amd64
|
|
||||||
run: |
|
|
||||||
scripts/build-ubuntu-amd64.sh -dl
|
|
||||||
|
|
||||||
build-macos-amd64:
|
|
||||||
runs-on: macos-latest
|
runs-on: macos-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
submodules: recursive
|
||||||
|
|
||||||
|
- name: Install dependencies
|
||||||
|
run: brew install sdl2
|
||||||
|
|
||||||
|
- name: Configure
|
||||||
|
run: ./waf configure --64bits ${{ matrix.dedicated }} $WAF_FLAGS
|
||||||
- name: Build macos-amd64
|
- name: Build macos-amd64
|
||||||
run: |
|
run: ./waf install
|
||||||
scripts/build-macos-amd64.sh -u
|
- name: Tar binaries
|
||||||
|
run: tar cvf build.tar build_hl2
|
||||||
build-dedicated-macos-amd64:
|
- name: Upload artifact
|
||||||
runs-on: macos-latest
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: macOS--64bits${{matrix.dedicated}}.tar
|
||||||
|
path: build.tar
|
||||||
|
|
||||||
|
build-windows:
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
os: [windows-2019]
|
||||||
|
bits: ['', '--64bits']
|
||||||
|
dedicated: ['', '-dl']
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
- name: Build dedicated macos-amd64
|
with:
|
||||||
run: |
|
submodules: recursive
|
||||||
scripts/build-macos-amd64.sh -dl
|
|
||||||
|
- name: Configure
|
||||||
|
run: ./waf configure ${{ matrix.bits }} ${{ matrix.dedicated }} ${{ env.WAF_FLAGS }}
|
||||||
|
- name: Build ${{ matrix.os }}
|
||||||
|
run: ./waf install
|
||||||
|
|
||||||
|
108
.github/workflows/tests.yml
vendored
108
.github/workflows/tests.yml
vendored
@ -1,59 +1,87 @@
|
|||||||
name: Tests
|
name: Tests
|
||||||
|
|
||||||
on: [push, pull_request]
|
on: [push, pull_request]
|
||||||
|
env:
|
||||||
|
WAF_FLAGS: -T release --no-warns --prefix=build_tests -lt --sanitize=address,undefined
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
tests-linux-i386:
|
tests-linux:
|
||||||
runs-on: ubuntu-20.04
|
strategy:
|
||||||
|
matrix:
|
||||||
|
os: [ubuntu-latest, ubuntu-20.04]
|
||||||
|
bits: ['', '--64bits']
|
||||||
|
android: ['']
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
|
env:
|
||||||
|
DEPS: libbz2-dev
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
- name: Run tests linux-i386
|
with:
|
||||||
|
submodules: recursive
|
||||||
|
|
||||||
|
- name: Install common dependencies
|
||||||
|
run: sudo apt-get update && sudo apt-get install -y g++-multilib gcc-multilib
|
||||||
|
- name: Install 32bit dependencies
|
||||||
|
if: ${{ matrix.bits == '' && !matrix.android }}
|
||||||
run: |
|
run: |
|
||||||
scripts/tests-ubuntu-i386.sh
|
sudo dpkg --add-architecture i386
|
||||||
|
sudo apt-get update
|
||||||
tests-linux-amd64:
|
sudo apt-get install aptitude
|
||||||
runs-on: ubuntu-20.04
|
sudo aptitude install -y $(echo $DEPS | sed -r 's/[a-z0-9_\-]+/&:i386/g')
|
||||||
|
- name: Install 64bit dependencies
|
||||||
steps:
|
if: ${{ matrix.bits != '' }}
|
||||||
- uses: actions/checkout@v2
|
|
||||||
- name: Run tests linux-amd64
|
|
||||||
run: |
|
run: |
|
||||||
scripts/tests-ubuntu-amd64.sh
|
sudo apt-get install -y $DEPS
|
||||||
|
|
||||||
tests-macos-amd64:
|
- if: ${{ matrix.bits == '' && !matrix.android }}
|
||||||
|
name: Set PKG_CONFIG_PATH
|
||||||
|
run: echo "PKG_CONFIG_PATH=/usr/lib/i386-linux-gnu/pkgconfig" >> $GITHUB_ENV
|
||||||
|
|
||||||
|
- name: Configure
|
||||||
|
run: ./waf configure ${{ matrix.bits }} $WAF_FLAGS
|
||||||
|
- name: Build ${{ matrix.os }}
|
||||||
|
run: ./waf install
|
||||||
|
- name: Run tests
|
||||||
|
run: |
|
||||||
|
cd build_tests
|
||||||
|
LD_LIBRARY_PATH=bin/ ./unittest
|
||||||
|
|
||||||
|
tests-macos:
|
||||||
runs-on: macos-latest
|
runs-on: macos-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
- name: Run tests macos-amd64
|
with:
|
||||||
|
submodules: recursive
|
||||||
|
|
||||||
|
- name: Configure
|
||||||
|
run: ./waf configure --64bits $WAF_FLAGS
|
||||||
|
- name: Build macos-amd64
|
||||||
|
run: ./waf install
|
||||||
|
- name: Run tests
|
||||||
run: |
|
run: |
|
||||||
scripts/tests-macos-amd64.sh
|
cd build_tests
|
||||||
|
DYLD_LIBRARY_PATH=bin/ ./unittest
|
||||||
tests-windows-i386:
|
|
||||||
runs-on: windows-2019
|
|
||||||
|
|
||||||
|
tests-windows:
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
os: [windows-2019]
|
||||||
|
bits: ['', '--64bits']
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
- name: Run tests windows-i386
|
with:
|
||||||
|
submodules: recursive
|
||||||
|
|
||||||
|
- name: Configure
|
||||||
|
run: ./waf configure ${{ matrix.bits }} ${{ env.WAF_FLAGS }}
|
||||||
|
|
||||||
|
- name: Build ${{ matrix.os }}
|
||||||
|
run: ./waf install
|
||||||
|
- name: Run tests
|
||||||
run: |
|
run: |
|
||||||
git submodule init && git submodule update
|
cd build_tests
|
||||||
./waf.bat configure -T release -lt --prefix=out/
|
|
||||||
./waf.bat install
|
|
||||||
cd out
|
|
||||||
$env:Path = "bin";
|
$env:Path = "bin";
|
||||||
./unittest.exe
|
./unittest.exe
|
||||||
|
|
||||||
tests-windows-amd64:
|
|
||||||
runs-on: windows-2019
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v2
|
|
||||||
- name: Run tests windows-amd64
|
|
||||||
run: |
|
|
||||||
git submodule init && git submodule update
|
|
||||||
./waf.bat configure -T release -lt --prefix=out/ -8
|
|
||||||
./waf.bat install
|
|
||||||
cd out
|
|
||||||
$env:Path = "bin";
|
|
||||||
./unittest.exe
|
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
|
|
||||||
git submodule init && git submodule update
|
|
||||||
wget https://dl.google.com/android/repository/android-ndk-r10e-linux-x86_64.zip -o /dev/null
|
|
||||||
unzip android-ndk-r10e-linux-x86_64.zip
|
|
||||||
export ANDROID_NDK_HOME=$PWD/android-ndk-r10e/
|
|
||||||
export NDK_HOME=$PWD/android-ndk-r10e/
|
|
||||||
./waf configure -T debug --android=armeabi-v7a-hard,4.9,21 --use-togles --no-warns &&
|
|
||||||
./waf build
|
|
@ -1,8 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
|
|
||||||
git submodule init && git submodule update
|
|
||||||
|
|
||||||
brew install sdl2
|
|
||||||
|
|
||||||
./waf configure -T debug --64bits --no-warns $* &&
|
|
||||||
./waf build
|
|
@ -1,8 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
|
|
||||||
git submodule init && git submodule update
|
|
||||||
sudo apt-get update
|
|
||||||
sudo apt-get install -f -y libopenal-dev g++-multilib gcc-multilib libpng-dev libjpeg-dev libfreetype6-dev libfontconfig1-dev libcurl4-gnutls-dev libsdl2-dev zlib1g-dev libbz2-dev libedit-dev
|
|
||||||
|
|
||||||
./waf configure -T debug --64bits --no-warns $* &&
|
|
||||||
./waf build
|
|
@ -1,10 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
|
|
||||||
git submodule init && git submodule update
|
|
||||||
sudo dpkg --add-architecture i386
|
|
||||||
sudo apt-get update
|
|
||||||
sudo apt-get install -y aptitude
|
|
||||||
sudo aptitude install -y libopenal-dev:i386 g++-multilib gcc-multilib libpng-dev:i386 libjpeg-dev:i386 libfreetype6-dev:i386 libfontconfig1-dev:i386 libcurl4-gnutls-dev:i386 libsdl2-dev:i386 zlib1g-dev:i386 libbz2-dev:i386 libedit-dev:i386
|
|
||||||
|
|
||||||
PKG_CONFIG_PATH=/usr/lib/i386-linux-gnu/pkgconfig ./waf configure -T debug --no-warns $* &&
|
|
||||||
./waf build
|
|
@ -1,7 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
|
|
||||||
git submodule init && git submodule update
|
|
||||||
./waf configure -T release --sanitize=address,undefined --no-warns -lt -8 --prefix=out/ $* &&
|
|
||||||
./waf install &&
|
|
||||||
cd out &&
|
|
||||||
DYLD_LIBRARY_PATH=bin/ ./unittest || exit 1
|
|
@ -1,10 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
|
|
||||||
git submodule init && git submodule update
|
|
||||||
sudo apt-get update
|
|
||||||
sudo apt-get install -y libbz2-dev
|
|
||||||
|
|
||||||
./waf configure -T release --sanitize=address,undefined --no-warns -lt --prefix=out/ --64bits $* &&
|
|
||||||
./waf install &&
|
|
||||||
cd out &&
|
|
||||||
LD_LIBRARY_PATH=bin/ ./unittest
|
|
@ -1,11 +0,0 @@
|
|||||||
install#!/bin/sh
|
|
||||||
|
|
||||||
git submodule init && git submodule update
|
|
||||||
sudo dpkg --add-architecture i386
|
|
||||||
sudo apt-get update
|
|
||||||
sudo apt-get install -y g++-multilib gcc-multilib libbz2-dev:i386
|
|
||||||
|
|
||||||
PKG_CONFIG_PATH=/usr/lib/i386-linux-gnu/pkgconfig ./waf configure -T release --sanitize=address,undefined --no-warns -lt --prefix=out/ $* &&
|
|
||||||
./waf install &&
|
|
||||||
cd out &&
|
|
||||||
LD_LIBRARY_PATH=bin/ ./unittest
|
|
Loading…
x
Reference in New Issue
Block a user