Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/use action to install specific cmake version #708

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 5 additions & 8 deletions .github/workflows/build-client.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,11 @@ jobs:
run: |
echo "build-output-dir=${{ github.workspace }}/build" >> "$GITHUB_OUTPUT"
echo "hunter-dir=${{ github.workspace }}/.hunter" >> "$GITHUB_OUTPUT"
echo "cmake-version=3.27.9" >> "$GITHUB_OUTPUT"
echo "cmake-install-dir=/opt/cmake-3.27.9" >> "$GITHUB_OUTPUT"
- uses: lukka/[email protected]
if: runner.os == 'Linux'
with:
cmakeVersion: 3.27.9

- name: Dependencies Linux
if: runner.os == 'Linux'
Expand All @@ -62,10 +65,6 @@ jobs:
wget https://raw.githubusercontent.com/microsoft/msquic/main/src/inc/msquic_posix.h
wget https://raw.githubusercontent.com/microsoft/msquic/main/src/inc/quic_sal_stub.h
sudo mv msquic.h msquic_posix.h quic_sal_stub.h /usr/include/
wget --output-document=/tmp/cmake.sh https://github.com/Kitware/CMake/releases/download/v${{ steps.strings.outputs.cmake-version }}/cmake-${{ steps.strings.outputs.cmake-version }}-linux-x86_64.sh
sudo mkdir ${{ steps.strings.outputs.cmake-install-dir }}
sudo sh /tmp/cmake.sh --skip-license --prefix=${{ steps.strings.outputs.cmake-install-dir }}
sudo ln --symbolic --force ${{ steps.strings.outputs.cmake-install-dir }}/bin/cmake /usr/local/bin/cmake
- name: Cache Hunter Dependencies
uses: actions/[email protected]
Expand All @@ -86,8 +85,6 @@ jobs:
choco install directx-sdk
- name: Configure CMake
# Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make.
# See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type
run: >
cmake --version;
cmake -B ${{ steps.strings.outputs.build-output-dir }}
Expand Down
12 changes: 4 additions & 8 deletions .github/workflows/cross-compile-client.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,13 @@ jobs:
run: |
echo "build-output-dir=${{ github.workspace }}/build" >> "$GITHUB_OUTPUT"
echo "hunter-dir=${{ github.workspace }}/.hunter" >> "$GITHUB_OUTPUT"
echo "cmake-version=3.27.9" >> "$GITHUB_OUTPUT"
echo "cmake-install-dir=/opt/cmake-3.27.9" >> "$GITHUB_OUTPUT"
COMMIT_HASH=${{ github.sha }}
echo "version=sha.${COMMIT_HASH:0:8}" >> "$GITHUB_OUTPUT"

- uses: lukka/[email protected]
with:
cmakeVersion: 3.27.9

- name: Dependencies
run: |
sudo apt update
Expand All @@ -38,10 +40,6 @@ jobs:
mingw-w64 \
mingw-w64-tools \
ninja-build
wget --output-document=/tmp/cmake.sh https://github.com/Kitware/CMake/releases/download/v${{ steps.strings.outputs.cmake-version }}/cmake-${{ steps.strings.outputs.cmake-version }}-linux-x86_64.sh
sudo mkdir ${{ steps.strings.outputs.cmake-install-dir }}
sudo sh /tmp/cmake.sh --skip-license --prefix=${{ steps.strings.outputs.cmake-install-dir }}
sudo ln --symbolic --force ${{ steps.strings.outputs.cmake-install-dir }}/bin/cmake /usr/local/bin/cmake
git clone --depth 1 --branch openssl-3.0.12 https://github.com/openssl/openssl.git
cd openssl
./Configure mingw --cross-compile-prefix=i686-w64-mingw32- --prefix=/usr/i686-w64-mingw32
Expand All @@ -55,8 +53,6 @@ jobs:
key: ubuntu-latest-hunter-cache

- name: Configure CMake
# Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make.
# See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type
run: >
cmake --version;
cmake -B ${{ steps.strings.outputs.build-output-dir }}
Expand Down
Loading