From 407cee6c557e06cfa9b04496af3a15fc13d0f002 Mon Sep 17 00:00:00 2001 From: Alex Bilger Date: Wed, 24 Jan 2024 11:21:55 +0100 Subject: [PATCH 1/5] Fix SofaPython3 fetching --- .github/workflows/ci.yml | 22 ++-------------------- 1 file changed, 2 insertions(+), 20 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 83ec19ae..cf4aa10e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,7 +16,6 @@ jobs: matrix: os: [ubuntu-20.04, macos-11, windows-2019] sofa_branch: [master] - python_version: ['3.8'] # Steps represent a sequence of tasks that will be executed as part of the job steps: @@ -44,23 +43,7 @@ jobs: sofa_root: ${{ github.workspace }}/sofa sofa_version: ${{ matrix.sofa_branch }} sofa_scope: 'standard' - sofa_with_sofapython3: 'false' - python_version: '${{ matrix.python_version }}' - pybind11_version: '2.6.2' - - - name: Install SofaPython3 - shell: bash - run: | - SofaPython3_ROOT="$GITHUB_WORKSPACE/SofaPython3" - mkdir -p "${{ runner.temp }}/sp3_tmp/zip" "${{ runner.temp }}/sp3_tmp/binaries" "$SofaPython3_ROOT" - url="https://github.com/sofa-framework/SofaPython3/releases/download" - url="${url}/release-${{ matrix.sofa_branch }}/SofaPython3_${{ matrix.sofa_branch }}_python-${{ matrix.python_version }}_for-SOFA-${{ matrix.sofa_branch }}_${{ runner.os }}.zip" - echo "Getting SofaPython3 from $url" - curl --output "${{ runner.temp }}/sp3_tmp/SofaPython3.zip" -L $url - unzip -qq "${{ runner.temp }}/sp3_tmp/SofaPython3.zip" -d "${{ runner.temp }}/sp3_tmp/binaries" - mv "${{ runner.temp }}"/sp3_tmp/binaries/SofaPython3_*/* "$SofaPython3_ROOT" - echo "SofaPython3_ROOT=$SofaPython3_ROOT" | tee -a $GITHUB_ENV - echo "SofaPython3_DIR=$SofaPython3_ROOT/lib/cmake/SofaPython3" | tee -a $GITHUB_ENV + sofa_with_sofapython3: 'true' - name: Checkout source code uses: actions/checkout@v2 @@ -74,8 +57,7 @@ jobs: -DCMAKE_BUILD_TYPE=Release \ -DCMAKE_INSTALL_PREFIX="$WORKSPACE_INSTALL_PATH" \ -DCMAKE_PREFIX_PATH="$SOFA_ROOT/lib/cmake" \ - -DPYTHON_ROOT=$PYTHON_ROOT -DPython_ROOT=$PYTHON_ROOT \ - -DPYTHON_EXECUTABLE=$PYTHON_EXE -DPython_EXECUTABLE=$PYTHON_EXE" + " if [ -e "$(command -v ccache)" ]; then cmake_options="$cmake_options -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache" fi From aa785d81d6c86f90e7bd3e23c0164d0ccc1e1f91 Mon Sep 17 00:00:00 2001 From: Alex Bilger Date: Thu, 8 Feb 2024 12:23:31 +0100 Subject: [PATCH 2/5] Restore Cmake variables related to Python --- .github/workflows/ci.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index cf4aa10e..1fc1eb25 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -57,7 +57,8 @@ jobs: -DCMAKE_BUILD_TYPE=Release \ -DCMAKE_INSTALL_PREFIX="$WORKSPACE_INSTALL_PATH" \ -DCMAKE_PREFIX_PATH="$SOFA_ROOT/lib/cmake" \ - " + -DPYTHON_ROOT=$PYTHON_ROOT -DPython_ROOT=$PYTHON_ROOT \ + -DPYTHON_EXECUTABLE=$PYTHON_EXE -DPython_EXECUTABLE=$PYTHON_EXE" if [ -e "$(command -v ccache)" ]; then cmake_options="$cmake_options -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache" fi From 63f5d918a06c219ed3b6b3e792c1adc9e3fba6c5 Mon Sep 17 00:00:00 2001 From: Alex Bilger Date: Tue, 12 Mar 2024 14:42:55 +0100 Subject: [PATCH 3/5] Update ci --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1fc1eb25..edf08c90 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,7 +14,7 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-20.04, macos-11, windows-2019] + os: [ubuntu-22.04, macos-12, windows-2022] sofa_branch: [master] # Steps represent a sequence of tasks that will be executed as part of the job @@ -38,7 +38,7 @@ jobs: - name: Setup SOFA and environment id: sofa - uses: sofa-framework/sofa-setup-action@v4 + uses: sofa-framework/sofa-setup-action@v5 with: sofa_root: ${{ github.workspace }}/sofa sofa_version: ${{ matrix.sofa_branch }} From 58f9497fe3854c67db60a0ae9a17edaf5d04dedc Mon Sep 17 00:00:00 2001 From: Alex Bilger Date: Tue, 12 Mar 2024 14:58:07 +0100 Subject: [PATCH 4/5] set python version to 3.10 --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index edf08c90..3c5c1225 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,6 +16,7 @@ jobs: matrix: os: [ubuntu-22.04, macos-12, windows-2022] sofa_branch: [master] + python_version: ['3.10'] # Steps represent a sequence of tasks that will be executed as part of the job steps: From 9c2529c153adf94dab68d1e692e71e587da9961a Mon Sep 17 00:00:00 2001 From: Alex Bilger Date: Tue, 12 Mar 2024 14:58:39 +0100 Subject: [PATCH 5/5] remove macos workaround --- .github/workflows/ci.yml | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3c5c1225..bdf6ee4f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -20,23 +20,6 @@ jobs: # Steps represent a sequence of tasks that will be executed as part of the job steps: - - name: (Mac) Workaround for homebrew - shell: bash - if: runner.os == 'macOS' - run: | - rm -f /usr/local/bin/2to3 - rm -f /usr/local/bin/idle3 - rm -f /usr/local/bin/pydoc3 - rm -f /usr/local/bin/python3 - rm -f /usr/local/bin/python3-config - rm -f /usr/local/bin/2to3-3.11 - rm -f /usr/local/bin/idle3.11 - rm -f /usr/local/bin/pydoc3.11 - rm -f /usr/local/bin/python3.11 - rm -f /usr/local/bin/python3.11-config - rm -f /usr/local/bin/go - rm -f /usr/local/bin/gofmt - - name: Setup SOFA and environment id: sofa uses: sofa-framework/sofa-setup-action@v5