Skip to content

Commit

Permalink
Update cibuild.yml for GitHub Action
Browse files Browse the repository at this point in the history
  • Loading branch information
tx00100xt committed Oct 23, 2023
1 parent adabc1a commit f104fe2
Showing 1 changed file with 25 additions and 45 deletions.
70 changes: 25 additions & 45 deletions .github/workflows/cibuild.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ jobs:
make install
mv -f ${{github.workspace}}/SamTFE/Bin ${{github.workspace}}/x32/SamTFE
mv -f ${{github.workspace}}/SamTSE/Bin ${{github.workspace}}/x32/SamTSE
- name: Run Build XPLUS
shell: alpine.sh {0}
run: |
Expand All @@ -71,7 +70,9 @@ jobs:
mv -f ${{github.workspace}}/SamTSE/Mods/XPLUS/Bin ${{github.workspace}}/x32/SamTSE/Mods/XPLUS
echo "*** Create archive ***"
cd ${{github.workspace}}
cp -fr SamTFE/SE1_10b.gro x32/SamTFE
cp -fr SamTFE/ModEXT.txt x32/SamTFE
cp -fr SamTSE/SE1_10b.gro x32/SamTSE
cp -fr SamTSE/ModEXT.txt x32/SamTSE
tar -cJpvf SeriousSamClassicVk-${{ steps.date.outputs.time }}-alpine-x86-bin.tar.xz x32
Expand Down Expand Up @@ -141,7 +142,9 @@ jobs:
mv -f ${{github.workspace}}/SamTSE/Mods/XPLUS/Bin ${{github.workspace}}/x64/SamTSE/Mods/XPLUS
echo "*** Create archive ***"
cd ${{github.workspace}}
cp -fr SamTFE/SE1_10b.gro x64/SamTFE
cp -fr SamTFE/ModEXT.txt x64/SamTFE
cp -fr SamTSE/SE1_10b.gro x64/SamTSE
cp -fr SamTSE/ModEXT.txt x64/SamTSE
tar -cJpvf SeriousSamClassicVk-${{ steps.date.outputs.time }}-alpine-x86_64-bin.tar.xz x64
Expand Down Expand Up @@ -179,13 +182,11 @@ jobs:
- name: Show current date
run: |
echo "${{ steps.date.outputs.time }}"
- name: Prepare
run: |
cd ${{github.workspace}}
find . -name "CMakeLists.txt" -exec sed -i 's/-march=native/-mtune=generic/g' {} +
mkdir {x64,x64/SamTFE,x64/SamTFE/Mods,x64/SamTFE/Mods/XPLUS,x64/SamTSE,x64/SamTSE/Mods,x64/SamTSE/Mods/XPLUS,}
- name: Run Build
run: |
cd ${{github.workspace}}
Expand All @@ -207,10 +208,9 @@ jobs:
mv -f ${{github.workspace}}/SamTSE/Mods/XPLUS/Bin ${{github.workspace}}/x64/SamTSE/Mods/XPLUS
echo "*** Create archive ***"
cd ${{github.workspace}}
cp -fr SamTFE/ModEXT.txt x64/SamTFE
cp -fr SamTSE/ModEXT.txt x64/SamTSE
cp -fr {SamTFE/SE1_10b.gro,SamTFE/ModEXT.txt} x64/SamTFE
cp -fr {SamTSE/SE1_10b.gro,SamTSE/ModEXT.txt} x64/SamTSE
tar -cJpvf SeriousSamClassicVk-${{ steps.date.outputs.time }}-lnx-amd64-bin.tar.xz x64
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
Expand Down Expand Up @@ -250,7 +250,6 @@ jobs:
- name: Show current date
run: |
echo "${{ steps.date.outputs.time }}"
- name: MS Build SamTFE XPLUS
working-directory: SamTFE\Sources
run: |
Expand Down Expand Up @@ -279,7 +278,6 @@ jobs:
del SamTFE\Bin\*.lib
del SamTFE\Bin\*.map
copy SamTFE\Bin\*.* x32\SamTFE\Bin
- name: MS Build SamTSE XPLUS
working-directory: SamTSE\Sources
run: |
Expand Down Expand Up @@ -309,11 +307,12 @@ jobs:
del SamTSE\Bin\*.map
copy SamTSE\Bin\*.* x32\SamTSE\Bin
echo "*** Copy Data files ***"
copy SamTFE\SE1_10b.gro x32\SamTFE
copy SamTFE\ModEXT.txt x32\SamTFE
copy SamTSE\SE1_10b.gro x32\SamTSE
copy SamTSE\ModEXT.txt x32\SamTSE
echo "*** Create archive ***"
7z a -mx=9 SeriousSamClassicVk-${{ steps.date.outputs.time }}-win32-bin.7z x32
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
Expand Down Expand Up @@ -353,7 +352,6 @@ jobs:
- name: Show current date
run: |
echo "${{ steps.date.outputs.time }}"
- name: MS Build SamTFE XPLUS
working-directory: SamTFE\Sources
run: |
Expand Down Expand Up @@ -412,7 +410,9 @@ jobs:
del SamTSE\Bin\*.map
copy SamTSE\Bin\*.* x64\SamTSE\Bin
echo "*** Copy Data files ***"
copy SamTFE\SE1_10b.gro x64\SamTFE
copy SamTFE\ModEXT.txt x64\SamTFE
copy SamTSE\SE1_10b.gro x64\SamTSE
copy SamTSE\ModEXT.txt x64\SamTSE
echo "*** Create archive ***"
7z a -mx=9 SeriousSamClassicVk-${{ steps.date.outputs.time }}-win64-bin.7z x64
Expand Down Expand Up @@ -479,8 +479,8 @@ jobs:
mv -f ${{github.workspace}}/SamTSE/Bin ${{github.workspace}}/x64/SamTSE
mv -f ${{github.workspace}}/SamTFE/Mods/XPLUS/Bin ${{github.workspace}}/x64/SamTFE/Mods/XPLUS
mv -f ${{github.workspace}}/SamTSE/Mods/XPLUS/Bin ${{github.workspace}}/x64/SamTSE/Mods/XPLUS
cp -vfr SamTFE/ModEXT.txt x64/SamTFE
cp -vfr SamTSE/ModEXT.txt x64/SamTSE
cp -vfr {SamTFE/SE1_10b.gro,SamTFE/ModEXT.txt} x64/SamTFE
cp -vfr {SamTSE/SE1_10b.gro,SamTSE/ModEXT.txt} x64/SamTSE
echo "*** Create archive ***"
XZ_DEFAULTS="-T 10" tar --use-compress-program=xz -cpvf SeriousSamClassicVk-${{ steps.date.outputs.time }}-bsd-amd64-bin.tar.xz x64
Expand Down Expand Up @@ -549,8 +549,8 @@ jobs:
cp -vfr SamTSE/Sources/build-x64/{DedicatedServer,MakeFONT,SeriousSam} x64/SamTSE/Bin
cp -vfr SamTSE/Sources/build-x64-xplus/Debug/libEntitiesMP.dylib x64/SamTSE/Mods/XPLUS/Bin
cp -vfr SamTSE/Sources/build-x64-xplus/Debug/libGameMP.dylib x64/SamTSE/Mods/XPLUS/Bin
cp -vfr SamTFE/ModEXT.txt x64/SamTFE
cp -vfr SamTSE/ModEXT.txt x64/SamTSE
cp -vfr {SamTFE/SE1_10b.gro,SamTFE/ModEXT.txt} x64/SamTFE
cp -vfr {SamTSE/SE1_10b.gro,SamTSE/ModEXT.txt} x64/SamTSE
echo "*** Create archive ***"
XZ_DEFAULTS="-T 10" tar --use-compress-program=xz -cpvf SeriousSamClassicVk-${{ steps.date.outputs.time }}-macos-amd64-bin.tar.xz x64
Expand Down Expand Up @@ -617,13 +617,12 @@ jobs:
mv -f SeriousSamClassic-VK/SamTFE/Mods/XPLUS/Bin x32/SamTFE/Mods/XPLUS
mv -f SeriousSamClassic-VK/SamTSE/Mods/XPLUS/Bin x32/SamTSE/Mods/XPLUS
echo "*** Copy Data files ***"
cp -vfr SeriousSamClassic-VK/SamTFE/ModEXT.txt x32/SamTFE
cp -vfr SeriousSamClassic-VK/SamTSE/ModEXT.txt x32/SamTSE
cp -vfr SeriousSamClassic-VK/{SamTFE/SE1_10b.gro,SamTFE/ModEXT.txt} x32/SamTFE
cp -vfr SeriousSamClassic-VK/{SamTSE/SE1_10b.gro,SamTSE/ModEXT.txt} x32/SamTSE
echo "*** Create archive ***"
mv x32 armv7l
XZ_DEFAULTS="-T 10" tar --use-compress-program=xz -cpvf SeriousSamClassicVk-${{ steps.date.outputs.time }}-rpios-armv7l-bin.tar.xz armv7l
cp SeriousSamClassicVk-${{ steps.date.outputs.time }}-rpios-armv7l-bin.tar.xz Release/
- name: Prepare Release
run: |
sudo mv ${{github.workspace}}/Release/SeriousSamClassicVk-${{ steps.date.outputs.time }}-rpios-armv7l-bin.tar.xz ${{github.workspace}}/
Expand Down Expand Up @@ -691,13 +690,12 @@ jobs:
mv -f SeriousSamClassic-VK/SamTFE/Mods/XPLUS/Bin x64/SamTFE/Mods/XPLUS
mv -f SeriousSamClassic-VK/SamTSE/Mods/XPLUS/Bin x64/SamTSE/Mods/XPLUS
echo "*** Copy Data files ***"
cp -vfr SeriousSamClassic-VK/SamTFE/ModEXT.txt x64/SamTFE
cp -vfr SeriousSamClassic-VK/SamTSE/ModEXT.txt x64/SamTSE
cp -vfr SeriousSamClassic-VK/{SamTFE/SE1_10b.gro,SamTFE/ModEXT.txt} x64/SamTFE
cp -vfr SeriousSamClassic-VK/{SamTSE/SE1_10b.gro,SamTSE/ModEXT.txt} x64/SamTSE
echo "*** Create archive ***"
mv x64 aarch64
XZ_DEFAULTS="-T 10" tar --use-compress-program=xz -cpvf SeriousSamClassicVk-${{ steps.date.outputs.time }}-rpios-aarch64-bin.tar.xz aarch64
cp SeriousSamClassicVk-${{ steps.date.outputs.time }}-rpios-aarch64-bin.tar.xz Release/
- name: Prepare Release
run: |
sudo mv ${{github.workspace}}/Release/SeriousSamClassicVk-${{ steps.date.outputs.time }}-rpios-aarch64-bin.tar.xz ${{github.workspace}}/
Expand Down Expand Up @@ -734,15 +732,12 @@ jobs:
# Create an artifacts directory
setup: |
mkdir -p "${PWD}/artifacts"
# Mount the artifacts directory as /artifacts in the container
dockerRunArgs: |
--volume "${PWD}/artifacts:/artifacts"
# Pass some environment variables to the container
env: | # YAML, but pipe character is necessary
artifact_name: git-${{ matrix.distro }}_${{ matrix.arch }}
# The shell to run commands with in the container
shell: /bin/bash

Expand Down Expand Up @@ -770,15 +765,13 @@ jobs:
apk add git
;;
esac
# Produce a binary artifact and place it in the mounted volume
run: |
cd ${{github.workspace}}
cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=Release -DUSE_I386_NASM_ASM=FALSE
cd ${{github.workspace}}/build
make -j$(nproc || echo 4)
make install
- name: Get current date
id: date
uses: Kaven-Universe/github-action-current-date-time@v1
Expand All @@ -788,7 +781,6 @@ jobs:
- name: Show current date
run: |
echo "${{ steps.date.outputs.time }}"
- name: Make artifact
# Items placed in /artifacts in the container will be in
# ${PWD}/artifacts on the host.
Expand All @@ -801,8 +793,8 @@ jobs:
mv -f ${{github.workspace}}/SamTSE/Bin ${{github.workspace}}/riscv64/SamTSE
echo "*** Copy Data files ***"
echo "*** Copy Data files ***"
cp -vfr SamTFE/ModEXT.txt riscv64/SamTFE
cp -vfr SamTSE/ModEXT.txt riscv64/SamTSE
cp -vfr {SamTFE/SE1_10b.gro,SamTFE/ModEXT.txt} riscv64/SamTFE
cp -vfr {SamTSE/SE1_10b.gro,SamTSE/ModEXT.txt} riscv64/SamTSE
echo "*** Create archive ***"
tar -cJpvf SeriousSamClassicVk-${{ steps.date.outputs.time }}-lnx-riscv64-bin.tar.xz riscv64
Expand Down Expand Up @@ -838,15 +830,12 @@ jobs:
# Create an artifacts directory
setup: |
mkdir -p "${PWD}/artifacts"
# Mount the artifacts directory as /artifacts in the container
dockerRunArgs: |
--volume "${PWD}/artifacts:/artifacts"
# Pass some environment variables to the container
env: | # YAML, but pipe character is necessary
artifact_name: git-${{ matrix.distro }}_${{ matrix.arch }}
# The shell to run commands with in the container
shell: /bin/bash

Expand Down Expand Up @@ -874,15 +863,13 @@ jobs:
apk add git
;;
esac
# Produce a binary artifact and place it in the mounted volume
run: |
cd ${{github.workspace}}
cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=Release -DUSE_I386_NASM_ASM=FALSE
cd ${{github.workspace}}/build
make -j$(nproc || echo 4)
make install
- name: Get current date
id: date
uses: Kaven-Universe/github-action-current-date-time@v1
Expand All @@ -892,7 +879,6 @@ jobs:
- name: Show current date
run: |
echo "${{ steps.date.outputs.time }}"
- name: Make artifact
# Items placed in /artifacts in the container will be in
# ${PWD}/artifacts on the host.
Expand All @@ -905,8 +891,8 @@ jobs:
mv -f ${{github.workspace}}/SamTSE/Bin ${{github.workspace}}/ppc64le/SamTSE
echo "*** Copy Data files ***"
echo "*** Copy Data files ***"
cp -vfr SamTFE/ModEXT.txt ppc64le/SamTFE
cp -vfr SamTSE/ModEXT.txt ppc64le/SamTSE
cp -vfr {SamTFE/SE1_10b.gro,SamTFE/ModEXT.txt} ppc64le/SamTFE
cp -vfr {SamTSE/SE1_10b.gro,SamTSE/ModEXT.txt} ppc64le/SamTSE
echo "*** Create archive ***"
tar -cJpvf SeriousSamClassicVk-${{ steps.date.outputs.time }}-lnx-ppc64le-bin.tar.xz ppc64le
Expand Down Expand Up @@ -942,15 +928,12 @@ jobs:
# Create an artifacts directory
setup: |
mkdir -p "${PWD}/artifacts"
# Mount the artifacts directory as /artifacts in the container
dockerRunArgs: |
--volume "${PWD}/artifacts:/artifacts"
# Pass some environment variables to the container
env: | # YAML, but pipe character is necessary
artifact_name: git-${{ matrix.distro }}_${{ matrix.arch }}
# The shell to run commands with in the container
shell: /bin/bash

Expand Down Expand Up @@ -978,15 +961,13 @@ jobs:
apk add git
;;
esac
# Produce a binary artifact and place it in the mounted volume
run: |
cd ${{github.workspace}}
cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=Release -DUSE_I386_NASM_ASM=FALSE
cd ${{github.workspace}}/build
make -j$(nproc || echo 4)
make install
- name: Get current date
id: date
uses: Kaven-Universe/github-action-current-date-time@v1
Expand All @@ -996,7 +977,6 @@ jobs:
- name: Show current date
run: |
echo "${{ steps.date.outputs.time }}"
- name: Make artifact
# Items placed in /artifacts in the container will be in
# ${PWD}/artifacts on the host.
Expand All @@ -1008,13 +988,13 @@ jobs:
mv -f ${{github.workspace}}/SamTFE/Bin ${{github.workspace}}/s390x/SamTFE
mv -f ${{github.workspace}}/SamTSE/Bin ${{github.workspace}}/s390x/SamTSE
echo "*** Copy Data files ***"
cp -vfr SamTFE/ModEXT.txt s390x/SamTFE
cp -vfr SamTSE/ModEXT.txt s390x/SamTSE
cp -vfr {SamTFE/SE1_10b.gro,SamTFE/ModEXT.txt} s390x/SamTFE
cp -vfr {SamTSE/SE1_10b.gro,SamTSE/ModEXT.txt} s390x/SamTSE
echo "*** Create archive ***"
tar -cJpvf SeriousSamClassicVk-${{ steps.date.outputs.time }}-lnx-s390x-bin.tar.xz s390x
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: SeriousSamClassicVk-${{ steps.date.outputs.time }}-lnx-s390x-bin.tar.xz
path: SeriousSamClassicVk-${{ steps.date.outputs.time }}-lnx-s390x-bin.tar.xz
path: SeriousSamClassicVk-${{ steps.date.outputs.time }}-lnx-s390x-bin.tar.xz

0 comments on commit f104fe2

Please sign in to comment.