OpenSSL3: Add error output for problems regarding loading modules #41
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Ubuntu Build | |
on: [push] | |
env: | |
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.) | |
BUILD_TYPE: Release | |
REPO_DIR : ${{github.workspace}} | |
BUILD_DIR: ${{github.workspace}}/bin/builddir | |
BOOST_VERSION: "1.83.0" | |
BOOST_PLATFORM_VERSION: "22.04" | |
jobs: | |
build: | |
runs-on: ${{ matrix.os }} | |
permissions: | |
contents: read | |
strategy: | |
matrix: | |
include: | |
- os: ubuntu-22.04 | |
COMPILER_CC: gcc-12 | |
COMPILER_PP: g++-12 | |
USE_PCH: ON | |
EXTRA_BUILD: "" | |
- os: ubuntu-22.04 | |
COMPILER_CC: clang | |
COMPILER_PP: clang++ | |
USE_PCH: ON | |
EXTRA_BUILD: "-DBUILD_EXTRACTORS=ON -DBUILD_AHBOT=ON -DBUILD_PLAYERBOT=ON " | |
- os: ubuntu-22.04 | |
COMPILER_CC: clang | |
COMPILER_PP: clang++ | |
USE_PCH: OFF | |
EXTRA_BUILD: "" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
path: ${{env.REPO_DIR}} | |
- name: Create Build Environment | |
run: | | |
echo "GITHUB_SHORT_REV=$(git rev-parse --short HEAD)" >> $GITHUB_ENV | |
echo "ARCHIVE_FILENAME=${{ github.event.repository.name }}-$(git rev-parse --short HEAD).zip" >> $GITHUB_ENV | |
echo "CC=${{matrix.COMPILER_CC}}" >> $GITHUB_ENV | |
echo "CXX=${{matrix.COMPILER_PP}}" >> $GITHUB_ENV | |
cmake -E make_directory ${{ env.BUILD_DIR }} | |
- name: Install Boost | |
uses: MarkusJx/[email protected] | |
id: install-boost | |
with: | |
# REQUIRED: Specify the required boost version | |
# A list of supported versions can be found here: | |
# https://github.com/MarkusJx/prebuilt-boost/blob/main/versions-manifest.json | |
boost_version: ${{env.BOOST_VERSION}} | |
# OPTIONAL: Specify a platform version | |
platform_version: ${{env.BOOST_PLATFORM_VERSION}} | |
# OPTIONAL: Specify a toolset | |
toolset: ${{env.COMPILER_CC}} | |
# OPTIONAL: Specify an architecture | |
arch: x86 | |
# NOTE: If a boost version matching all requirements cannot be found, | |
# this build step will fail | |
- name: Configure | |
env: | |
USE_PCH: ${{ matrix.USE_PCH }} | |
EXTRA_BUILD: ${{ matrix.EXTRA_BUILD }} | |
BOOST_ROOT: ${{ steps.install-boost.outputs.BOOST_ROOT }} | |
run: cmake -DBoost_ARCHITECTURE=-x64 -DPCH=${{env.USE_PCH}} -DCMAKE_INSTALL_PREFIX=/home/runner/work ${{env.EXTRA_BUILD}}-B ${{env.BUILD_DIR}} -S ${{env.REPO_DIR}} | |
- name: Build | |
env: | |
MAKEFLAGS: "-j8" | |
run: | | |
cmake --build ${{env.BUILD_DIR}} --config ${{env.BUILD_TYPE}} | |
cmake --install ${{env.BUILD_DIR}} | |
notify: | |
name: Send Notification to Discord on Failure | |
runs-on: ubuntu-22.04 | |
permissions: | |
contents: none | |
needs: # make sure the notification is sent AFTER the jobs you want included have completed | |
- build | |
if: failure() | |
steps: | |
- name: Setup Environmental Variables | |
run: | | |
echo "GIT_BRANCH=${GITHUB_REF#refs/heads/}" >> $GITHUB_ENV | |
echo "GIT_SHORT_SHA=`echo ${GITHUB_SHA} | cut -c1-8`" >> $GITHUB_ENV | |
- name: Notify | |
uses: rjstone/[email protected] | |
with: | |
severity: error | |
description: | | |
**Linux Build Failed** | |
details: | | |
- **Branch:** ${{env.GIT_BRANCH}} | |
- **Pusher:** ${{github.event.pusher.name}} | |
- **Author:** ${{github.event.head_commit.author.name}} | |
- **Commit:** [${{github.repository}}/${{env.GIT_SHORT_SHA}}](${{github.server_url}}/${{ github.repository }}/commit/${{github.sha}}) | |
- **Build Log:** [actions/runs/${{github.run_id}}](${{github.server_url}}/${{github.repository}}/actions/runs/${{github.run_id}}) | |
footer: CMaNGOS Developers Notified! | |
webhookUrl: ${{ secrets.DISCORD_WEBHOOK }} |