Skip to content

patchelf is now one call. Should fix the bug where only one path is p… #55

patchelf is now one call. Should fix the bug where only one path is p…

patchelf is now one call. Should fix the bug where only one path is p… #55

name: Build Linux
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
workflow_dispatch:
concurrency:
group: environment-lin-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: write
jobs:
build:
name: Build - ${{ matrix.config.os }}
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
- os: ubuntu-22.04
name: "Ubuntu GCC-11"
artifact: "ubuntu_gcc.7z"
build_type: "RelWithDebInfo"
cc: "clang-14"
cxx: "clang++-14"
archiver: "7z a"
generators: "Unix Makefiles"
build_dir: 'build'
steps:
- name: setup gcc-11
run: |
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-11 200 --slave /usr/bin/g++ g++ /usr/bin/g++-11 --slave /usr/bin/gcov gcov /usr/bin/gcov-11
- name: Setup Pragma
uses: Silverlan/pragma/github_actions/setup@master
with:
clone_url: "https://github.com/${{ github.repository }}.git"
- name: Clone pr_source repo
uses: GuillaumeFalourd/clone-github-repo-action@main
with:
owner: 'Slaweknowy'
branch: master
repository: 'pr_source'
submodule: true
access-token: ${{ secrets.PR_SOURCE_REPO_TOKEN }}
- name: Move repo to target location
run: |
mv pr_source ./pragma/modules/
- name: Build Pragma
uses: ./pragma/github_actions/build
id: build-pragma
with:
build-args: "--with-pfm --with-all-pfm-modules --with-vr --with-lua-debugger=0"
- name: Create Release Archive
shell: bash
run: |
curDir="$PWD"
# Add info file
cd "${{ steps.build-pragma.outputs.install-dir }}"
echo -e "ref: $GITHUB_REF \ncommit: $GITHUB_SHA\nbuild: $(date +"%Y-%m-%dT%H:%M:%SZ")" \
> ./git_info.txt
# Delete .git folders
find . -name ".git*" -exec rm -R {} \; 2>/dev/null || true
# Enable experimental updates
cd cfg
echo "pfm_enable_experimental_updates \"1\"" >> client.cfg
cd ..
tar -czvf pragma-lin64.tar.gz *
mv "${{ steps.build-pragma.outputs.install-dir }}/pragma-lin64.tar.gz" "$curDir/"
- name: Generate nightly tag description
shell: bash
run: |
curDate=$(date -u '+%Y-%m-%d %H:%M:%S %Z')
printf "This is an auto-generated pre-release, built from the latest version of the source code.\nIt includes all files necessary to run Pragma, as well as the latest version of the Pragma Filmmaker, however functionality and stability are **not** guaranteed.\n\nLatest release date: $curDate" > tag_text.txt
- name: Update nightly tag description
uses: softprops/[email protected]
with:
body_path: tag_text.txt
tag_name: nightly
prerelease: true
- name: Update nightly release
uses: pyTooling/Actions/releaser/composite@main
with:
tag: nightly
token: ${{ secrets.GITHUB_TOKEN }}
files: "pragma-lin64.tar.gz"
# Tests are currently not functional on Linux GitHub runners
#- name: Run Tests
# uses: ./pragma/github_actions/run_tests
# timeout-minutes: 10
# with:
# install-dir: "${{ steps.build-pragma.outputs.install-dir }}"
- name: Handle Error
uses: Silverlan/common_actions/action_handle_error@main
if: failure()