mirror of
https://github.com/accelerator74/l4dtoolz.git
synced 2025-09-19 04:06:09 +08:00
Update build scripts
This commit is contained in:
38
.github/workflows/l4d2-build.yml
vendored
38
.github/workflows/l4d2-build.yml
vendored
@ -45,7 +45,7 @@ jobs:
|
|||||||
echo "GITHUB_SHA_SHORT=${GITHUB_SHA::7}" >> $GITHUB_ENV
|
echo "GITHUB_SHA_SHORT=${GITHUB_SHA::7}" >> $GITHUB_ENV
|
||||||
|
|
||||||
- name: Install (Linux)
|
- name: Install (Linux)
|
||||||
if: runner.os == 'Linux'
|
if: startsWith(runner.os, 'Linux')
|
||||||
run: |
|
run: |
|
||||||
sudo dpkg --add-architecture i386
|
sudo dpkg --add-architecture i386
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
@ -54,59 +54,53 @@ jobs:
|
|||||||
echo "CXX=clang++" >> $GITHUB_ENV
|
echo "CXX=clang++" >> $GITHUB_ENV
|
||||||
|
|
||||||
- name: Add msbuild to PATH (Windows)
|
- name: Add msbuild to PATH (Windows)
|
||||||
if: runner.os == 'Windows'
|
if: startsWith(runner.os, 'Windows')
|
||||||
uses: microsoft/setup-msbuild@v1.0.2
|
uses: microsoft/setup-msbuild@v1.1
|
||||||
|
|
||||||
- name: Install (Windows)
|
- name: Install (Windows)
|
||||||
if: runner.os == 'Windows'
|
if: startsWith(runner.os, 'Windows')
|
||||||
shell: cmd
|
shell: cmd
|
||||||
run: |
|
run: |
|
||||||
:: See https://github.com/microsoft/vswhere/wiki/Find-VC
|
:: See https://github.com/microsoft/vswhere/wiki/Find-VC
|
||||||
for /f "usebackq delims=*" %%i in (`vswhere -latest -property installationPath`) do (
|
for /f "usebackq delims=*" %%i in (`vswhere -latest -property installationPath`) do (
|
||||||
call "%%i"\Common7\Tools\vsdevcmd.bat -arch=x86 -host_arch=x64
|
call "%%i"\Common7\Tools\vsdevcmd.bat -arch=x86 -host_arch=x64
|
||||||
)
|
)
|
||||||
|
|
||||||
:: Loop over all environment variables and make them global.
|
:: Loop over all environment variables and make them global.
|
||||||
for /f "delims== tokens=1,2" %%a in ('set') do (
|
for /f "delims== tokens=1,2" %%a in ('set') do (
|
||||||
echo>>"%GITHUB_ENV%" %%a=%%b
|
echo>>"%GITHUB_ENV%" %%a=%%b
|
||||||
)
|
)
|
||||||
|
|
||||||
- name: Checking out MM:Source
|
- name: Checking out MM:Source
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v3
|
||||||
with:
|
with:
|
||||||
repository: alliedmodders/metamod-source
|
repository: alliedmodders/metamod-source
|
||||||
ref: ${{ matrix.mm_branch }}
|
ref: ${{ matrix.mm_branch }}
|
||||||
path: metamod-${{ matrix.mm_version }}
|
path: metamod-${{ matrix.mm_version }}
|
||||||
|
|
||||||
- name: Checking out AMBuild
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
with:
|
|
||||||
repository: Accelerator74/ambuild
|
|
||||||
path: ambuild
|
|
||||||
|
|
||||||
- name: Setting up Python
|
- name: Setting up Python
|
||||||
uses: actions/setup-python@v2
|
uses: actions/setup-python@v4
|
||||||
with:
|
with:
|
||||||
python-version: '3.x'
|
python-version: '3.x'
|
||||||
|
|
||||||
- name: Setting up ambuild
|
- name: Setting up ambuild
|
||||||
working-directory: ambuild
|
run: |
|
||||||
run: python setup.py install
|
python -m pip install wheel
|
||||||
|
pip install git+https://github.com/accelerator74/ambuild
|
||||||
|
|
||||||
- name: Checking out hl2sdk-l4d2
|
- name: Checking out hl2sdk-l4d2
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v3
|
||||||
with:
|
with:
|
||||||
repository: alliedmodders/hl2sdk
|
repository: alliedmodders/hl2sdk
|
||||||
ref: l4d2
|
ref: l4d2
|
||||||
path: hl2sdk-l4d2
|
path: hl2sdk-l4d2
|
||||||
|
|
||||||
- name: Checking out own repository
|
- name: Checking out own repository
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v3
|
||||||
with:
|
with:
|
||||||
path: l4dtoolz
|
path: src
|
||||||
|
|
||||||
- name: Compiling L4DToolZ files
|
- name: Compiling ${{ github.event.repository.name }} files
|
||||||
working-directory: l4dtoolz
|
working-directory: src
|
||||||
run: |
|
run: |
|
||||||
mkdir build
|
mkdir build
|
||||||
cd build
|
cd build
|
||||||
@ -114,7 +108,7 @@ jobs:
|
|||||||
ambuild
|
ambuild
|
||||||
|
|
||||||
- name: Uploading package
|
- name: Uploading package
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: L4DToolZ-l4d2-${{ env.GITHUB_SHA_SHORT }}
|
name: L4DToolZ-l4d2-${{ env.GITHUB_SHA_SHORT }}
|
||||||
path: l4dtoolz/build/package
|
path: src/build/package
|
38
.github/workflows/l4d_build.yml
vendored
38
.github/workflows/l4d_build.yml
vendored
@ -45,7 +45,7 @@ jobs:
|
|||||||
echo "GITHUB_SHA_SHORT=${GITHUB_SHA::7}" >> $GITHUB_ENV
|
echo "GITHUB_SHA_SHORT=${GITHUB_SHA::7}" >> $GITHUB_ENV
|
||||||
|
|
||||||
- name: Install (Linux)
|
- name: Install (Linux)
|
||||||
if: runner.os == 'Linux'
|
if: startsWith(runner.os, 'Linux')
|
||||||
run: |
|
run: |
|
||||||
sudo dpkg --add-architecture i386
|
sudo dpkg --add-architecture i386
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
@ -54,59 +54,53 @@ jobs:
|
|||||||
echo "CXX=clang++" >> $GITHUB_ENV
|
echo "CXX=clang++" >> $GITHUB_ENV
|
||||||
|
|
||||||
- name: Add msbuild to PATH (Windows)
|
- name: Add msbuild to PATH (Windows)
|
||||||
if: runner.os == 'Windows'
|
if: startsWith(runner.os, 'Windows')
|
||||||
uses: microsoft/setup-msbuild@v1.0.2
|
uses: microsoft/setup-msbuild@v1.1
|
||||||
|
|
||||||
- name: Install (Windows)
|
- name: Install (Windows)
|
||||||
if: runner.os == 'Windows'
|
if: startsWith(runner.os, 'Windows')
|
||||||
shell: cmd
|
shell: cmd
|
||||||
run: |
|
run: |
|
||||||
:: See https://github.com/microsoft/vswhere/wiki/Find-VC
|
:: See https://github.com/microsoft/vswhere/wiki/Find-VC
|
||||||
for /f "usebackq delims=*" %%i in (`vswhere -latest -property installationPath`) do (
|
for /f "usebackq delims=*" %%i in (`vswhere -latest -property installationPath`) do (
|
||||||
call "%%i"\Common7\Tools\vsdevcmd.bat -arch=x86 -host_arch=x64
|
call "%%i"\Common7\Tools\vsdevcmd.bat -arch=x86 -host_arch=x64
|
||||||
)
|
)
|
||||||
|
|
||||||
:: Loop over all environment variables and make them global.
|
:: Loop over all environment variables and make them global.
|
||||||
for /f "delims== tokens=1,2" %%a in ('set') do (
|
for /f "delims== tokens=1,2" %%a in ('set') do (
|
||||||
echo>>"%GITHUB_ENV%" %%a=%%b
|
echo>>"%GITHUB_ENV%" %%a=%%b
|
||||||
)
|
)
|
||||||
|
|
||||||
- name: Checking out MM:Source
|
- name: Checking out MM:Source
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v3
|
||||||
with:
|
with:
|
||||||
repository: alliedmodders/metamod-source
|
repository: alliedmodders/metamod-source
|
||||||
ref: ${{ matrix.mm_branch }}
|
ref: ${{ matrix.mm_branch }}
|
||||||
path: metamod-${{ matrix.mm_version }}
|
path: metamod-${{ matrix.mm_version }}
|
||||||
|
|
||||||
- name: Checking out AMBuild
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
with:
|
|
||||||
repository: Accelerator74/ambuild
|
|
||||||
path: ambuild
|
|
||||||
|
|
||||||
- name: Setting up Python
|
- name: Setting up Python
|
||||||
uses: actions/setup-python@v2
|
uses: actions/setup-python@v4
|
||||||
with:
|
with:
|
||||||
python-version: '3.x'
|
python-version: '3.x'
|
||||||
|
|
||||||
- name: Setting up ambuild
|
- name: Setting up ambuild
|
||||||
working-directory: ambuild
|
run: |
|
||||||
run: python setup.py install
|
python -m pip install wheel
|
||||||
|
pip install git+https://github.com/accelerator74/ambuild
|
||||||
|
|
||||||
- name: Checking out hl2sdk-l4d
|
- name: Checking out hl2sdk-l4d
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v3
|
||||||
with:
|
with:
|
||||||
repository: alliedmodders/hl2sdk
|
repository: alliedmodders/hl2sdk
|
||||||
ref: l4d
|
ref: l4d
|
||||||
path: hl2sdk-l4d
|
path: hl2sdk-l4d
|
||||||
|
|
||||||
- name: Checking out own repository
|
- name: Checking out own repository
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v3
|
||||||
with:
|
with:
|
||||||
path: l4dtoolz
|
path: src
|
||||||
|
|
||||||
- name: Compiling L4DToolZ files
|
- name: Compiling ${{ github.event.repository.name }} files
|
||||||
working-directory: l4dtoolz
|
working-directory: src
|
||||||
run: |
|
run: |
|
||||||
mkdir build
|
mkdir build
|
||||||
cd build
|
cd build
|
||||||
@ -114,7 +108,7 @@ jobs:
|
|||||||
ambuild
|
ambuild
|
||||||
|
|
||||||
- name: Uploading package
|
- name: Uploading package
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: L4DToolZ-l4d-${{ env.GITHUB_SHA_SHORT }}
|
name: L4DToolZ-l4d-${{ env.GITHUB_SHA_SHORT }}
|
||||||
path: l4dtoolz/build/package
|
path: src/build/package
|
Reference in New Issue
Block a user