From a068f5886a8b1c35b7f3df931e902884ad642e1f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 12:58:44 +0200 Subject: [PATCH 01/34] Simplify workflow --- .github/workflows/main.yml | 126 ++++++++++++++++++++++++++++++++++ .github/workflows/release.yml | 68 ------------------ .github/workflows/wheels.yml | 109 ----------------------------- pyproject.toml | 2 +- python/src/homlib/version.py | 2 +- 5 files changed, 128 insertions(+), 179 deletions(-) delete mode 100644 .github/workflows/release.yml delete mode 100644 .github/workflows/wheels.yml diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index f6f964c..d87b493 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -111,3 +111,129 @@ jobs: with: name: ${{ matrix.config.artifact }} path: ${{ matrix.config.artifact }} + + build_wheels: + name: Build wheels for ${{ matrix.config.name }} + needs: [build] + runs-on: ${{ matrix.config.os }} + strategy: + fail-fast: false + matrix: + config: + - name: linux-intel + os: ubuntu-latest + env: + POSELIB_VERSION: "v2.0.5" + + steps: + - name: Checkout your project + uses: actions/checkout@v4 + with: + submodules: 'recursive' + + - name: Restore PoseLib cache + uses: actions/cache@v4 + id: cache-poselib + with: + path: ${{github.workspace}}/poselib-install + key: ${{ runner.os }}-poselib-${{ env.POSELIB_VERSION }} + + - name: Fail if cache miss + if: steps.cache-poselib.outputs.cache-hit != 'true' + run: | + echo "Cache miss for PoseLib. Build cannot proceed." + exit 1 + + - name: Build wheels + uses: pypa/cibuildwheel@v3.3.1 + env: + CIBW_PROJECT_REQUIRES_PYTHON: ">=3.10" + CIBW_ENVIRONMENT: | + BUILD_SHARED_LIBS="OFF" + CMAKE_CXX_FLAGS="-Wno-error" + CIBW_BUILD: ${{ github.event_name == 'pull_request' && 'cp310-*' || '' }} + CIBW_BEFORE_ALL_LINUX: | + yum install -y eigen3-devel + cp -r /project/poselib-install/* /usr/local/ + CIBW_ARCHS_LINUX: "native" + CIBW_BEFORE_ALL_WINDOWS: C:\vcpkg\vcpkg --triplet x64-windows install eigen3 + CIBW_ENVIRONMENT_WINDOWS: CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" + CIBW_ARCHS_WINDOWS: "native" + CIBW_BEFORE_ALL_MACOS: brew install eigen + CIBW_REPAIR_WHEEL_COMMAND_MACOS: "" + CIBW_SKIP: "*-musllinux_x86_64" + + - uses: actions/upload-artifact@v4 + with: + name: cibw-wheels-${{ matrix.config.name }}-${{ strategy.job-index }} + path: ./wheelhouse/*.whl + + build_sdist: + name: Build source distribution + needs: [build] + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + with: + persist-credentials: false + + - name: Build sdist + run: pipx run build --sdist + + - uses: actions/upload-artifact@v4 + with: + name: cibw-sdist + path: ./dist/*.tar.gz + + release: + name: Create GitHub Release + needs: [build, build_wheels, build_sdist] + if: startsWith(github.ref, 'refs/tags/v') + + runs-on: ubuntu-latest + steps: + - name: Download all artifacts + uses: actions/download-artifact@v4 + with: + path: artifacts + + - name: Display structure of downloaded files + run: ls -R artifacts + + - name: Create Release + uses: softprops/action-gh-release@v2 + with: + name: Release ${{ github.ref_name }} + tag_name: ${{ github.ref_name }} + body: | + ## Changes + + See the commits for details. + draft: false + prerelease: false + files: libHomLib-*.zip + generate_release_notes: true + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + + upload_pypi: + runs-on: ubuntu-latest + environment: pypi publisher + permissions: + id-token: write + if: startsWith(github.ref, 'refs/tags/v') + # or, alternatively, upload to PyPI on every tag starting with 'v' (remove on: release above to use this) + # if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v') + steps: + - uses: actions/download-artifact@v5 + with: + # unpacks all CIBW artifacts into dist/ + pattern: cibw-* + path: dist + merge-multiple: true + + - uses: pypa/gh-action-pypi-publish@release/v1 + # To test uploads to TestPyPI, uncomment the following: + # with: + # repository-url: https://test.pypi.org/legacy/ + diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml deleted file mode 100644 index dc87517..0000000 --- a/.github/workflows/release.yml +++ /dev/null @@ -1,68 +0,0 @@ -name: Release - -on: - workflow_run: - workflows: ["Build Wheels"] - types: - - completed - branches: - - main - tags: - - 'v*' - -jobs: - release: - name: Create GitHub Release - if: ${{ github.event.workflow_run.conclusion == 'success' && startsWith(github.event.workflow_run.head_ref, 'refs/tags/v') }} - permissions: - id-token: write - runs-on: ubuntu-latest - steps: - - name: Download all artifacts - uses: actions/download-artifact@v4 - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - run-id: ${{ github.event.workflow_run.id }} - path: artifacts - merge-multiple: true - - - name: Display structure of downloaded files - run: ls -R artifacts - - - name: Create Release - uses: softprops/action-gh-release@v2 - with: - name: Release ${{ github.ref_name }} - tag_name: ${{ github.ref_name }} - body: | - ## Changes - - See the commits for details. - draft: false - prerelease: false - files: artifacts/*.zip - generate_release_notes: true - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - upload_pypi: - name: Upload PyPI - runs-on: ubuntu-latest - environment: pypi publisher - permissions: - id-token: write - if: ${{ github.event.workflow_run.conclusion == 'success' && startsWith(github.event.workflow_run.head_ref, 'refs/tags/v') }} - steps: - - uses: actions/download-artifact@v5 - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - run-id: ${{ github.event.workflow_run.id }} - # unpacks all CIBW artifacts into dist/ - pattern: cibw-* - path: dist - merge-multiple: true - - - uses: pypa/gh-action-pypi-publish@release/v1 - # To test uploads to TestPyPI, uncomment the following: - # with: - # repository-url: https://test.pypi.org/legacy/ diff --git a/.github/workflows/wheels.yml b/.github/workflows/wheels.yml deleted file mode 100644 index 3684502..0000000 --- a/.github/workflows/wheels.yml +++ /dev/null @@ -1,109 +0,0 @@ -name: Build Wheels - -on: - workflow_run: - workflows: ["Build HomLib"] - types: - - completed - branches: - - main - tags: - - 'v*' - -jobs: - build_wheels: - if: ${{ github.event.workflow_run.conclusion == 'success' }} - name: Build wheels for ${{ matrix.config.name }} - runs-on: ${{ matrix.config.os }} - strategy: - fail-fast: false - matrix: - config: - - name: linux-intel - os: ubuntu-latest - env: - POSELIB_VERSION: "v2.0.5" - - steps: - - name: Checkout your project - uses: actions/checkout@v4 - with: - submodules: 'recursive' - - - name: Restore PoseLib cache - uses: actions/cache@v4 - id: cache-poselib - with: - path: ${{github.workspace}}/poselib-install - key: ${{ runner.os }}-poselib-${{ env.POSELIB_VERSION }} - - - name: Fail if cache miss - if: steps.cache-poselib.outputs.cache-hit != 'true' - run: | - echo "Cache miss for PoseLib. Build cannot proceed." - exit 1 - - - name: Build wheels - uses: pypa/cibuildwheel@v3.3.1 - env: - CIBW_PROJECT_REQUIRES_PYTHON: ">=3.10" - CIBW_ENVIRONMENT: | - BUILD_SHARED_LIBS="OFF" - CMAKE_CXX_FLAGS="-Wno-error" - CIBW_BUILD: ${{ github.event_name == 'pull_request' && 'cp310-*' || '' }} - CIBW_BEFORE_ALL_LINUX: | - yum install -y eigen3-devel - cp -r /project/poselib-install/* /usr/local/ - CIBW_ARCHS_LINUX: "native" - CIBW_BEFORE_ALL_WINDOWS: C:\vcpkg\vcpkg --triplet x64-windows install eigen3 - CIBW_ENVIRONMENT_WINDOWS: CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" - CIBW_ARCHS_WINDOWS: "native" - CIBW_BEFORE_ALL_MACOS: brew install eigen - CIBW_REPAIR_WHEEL_COMMAND_MACOS: "" - CIBW_SKIP: "*-musllinux_x86_64" - - - uses: actions/upload-artifact@v4 - with: - name: cibw-wheels-${{ matrix.config.name }}-${{ strategy.job-index }} - path: ./wheelhouse/*.whl - - build_sdist: - name: Build source distribution - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - with: - persist-credentials: false - - - name: Build sdist - run: pipx run build --sdist - - - uses: actions/upload-artifact@v4 - with: - name: cibw-sdist - path: ./dist/*.tar.gz - - combine_artifacts: - needs: [build_wheels, build_sdist] - runs-on: ubuntu-latest - steps: - - name: Download wheels from this workflow - uses: actions/download-artifact@v4 - with: - path: downloaded - merge-multiple: true - - name: Download library artifacts from main.yml - uses: actions/download-artifact@v4 - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - run-id: ${{ github.event.workflow_run.id }} - path: library - - name: Combine and upload - run: | - mkdir combined - cp -r library/* combined/ || true - cp -r downloaded/* combined/ || true - - uses: actions/upload-artifact@v4 - with: - name: combined-release-artifacts - path: combined/* \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index 08b7045..7ae5528 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "scikit_build_core.build" [project] name = "homlib" -version = "0.1.1-rc5" +version = "0.1.1-rc6" description = "State-of-the-art homography estimators." readme = "README.md" authors = [ diff --git a/python/src/homlib/version.py b/python/src/homlib/version.py index 5729925..c62157a 100644 --- a/python/src/homlib/version.py +++ b/python/src/homlib/version.py @@ -1 +1 @@ -__version__ = "0.1.1-rc5" +__version__ = "0.1.1-rc6" From a5903397afd26e42e8f1907a6ddd0d68877e923b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 13:00:14 +0200 Subject: [PATCH 02/34] fix --- .github/workflows/main.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index d87b493..7de9542 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -218,6 +218,7 @@ jobs: upload_pypi: runs-on: ubuntu-latest + needs: [build, build_wheels, build_sdist] environment: pypi publisher permissions: id-token: write From 24c7f835bd59b50ec74ee8b42a90503701238771 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 14:41:09 +0200 Subject: [PATCH 03/34] Fix versioning --- CMakeLists.txt | 32 ++++++++++++++++++++++++++++++-- pyproject.toml | 2 +- python/CMakeLists.txt | 1 + python/src/homlib/__init__.py | 2 +- python/src/homlib/version.py | 1 - python/src/main.cpp | 6 ++++++ 6 files changed, 39 insertions(+), 5 deletions(-) delete mode 100644 python/src/homlib/version.py diff --git a/CMakeLists.txt b/CMakeLists.txt index 2154796..88705bd 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,13 +1,41 @@ cmake_minimum_required(VERSION 3.15) -project(HomLib) +# ---------------------------------------------------------------------- +# Extract version from pyproject.toml +# ---------------------------------------------------------------------- +file(READ "${CMAKE_CURRENT_SOURCE_DIR}/pyproject.toml" PYPROJECT_CONTENT) +string(REGEX MATCH "version[ \t]*=[ \t]*[\"']([^\"']+)[\"']" _ ${PYPROJECT_CONTENT}) +set(PROJECT_VERSION_FULL ${CMAKE_MATCH_1}) + +if(NOT PROJECT_VERSION_FULL) + message(FATAL_ERROR "Version not found in pyproject.toml") +endif() + +message(STATUS "Project version: ${PROJECT_VERSION_FULL}") + +# ---------------------------------------------------------------------- +# Extract numeric version for CMake +# ---------------------------------------------------------------------- +# Look for the pattern "major.minor.patch" at the beginning +string(REGEX MATCH "^([0-9]+)\\.([0-9]+)\\.([0-9]+)" _ "${PROJECT_VERSION_FULL}") +if(CMAKE_MATCH_1) + set(VERSION_MAJOR ${CMAKE_MATCH_1}) + set(VERSION_MINOR ${CMAKE_MATCH_2}) + set(VERSION_PATCH ${CMAKE_MATCH_3}) + set(PROJECT_VERSION "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}") +else() + # Fallback if no numeric parts found + set(PROJECT_VERSION "0.0.0") +endif() + +project(HomLib VERSION ${PROJECT_VERSION} LANGUAGES CXX) if(NOT CMAKE_BUILD_TYPE) set(CMAKE_BUILD_TYPE "Release") endif() if(CMAKE_COMPILER_IS_GNUCXX) - message("USING GNUCXX compiler") + message(STATUS "USING GNUCXX compiler") SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wno-strict-aliasing") SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wextra -Wno-write-strings") SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-deprecated -ansi") diff --git a/pyproject.toml b/pyproject.toml index 7ae5528..29a1e2d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "scikit_build_core.build" [project] name = "homlib" -version = "0.1.1-rc6" +version = "0.1.1-rc7" description = "State-of-the-art homography estimators." readme = "README.md" authors = [ diff --git a/python/CMakeLists.txt b/python/CMakeLists.txt index c32f6f5..6a2023b 100644 --- a/python/CMakeLists.txt +++ b/python/CMakeLists.txt @@ -33,6 +33,7 @@ target_link_libraries(_core PRIVATE HomLib) target_link_libraries(_core PRIVATE PoseLib::PoseLib) target_include_directories(_core PRIVATE ${HOMLIB_INCLUDE_DIRS}) target_include_directories(_core PRIVATE ../thirdparty/RansacLib) +target_compile_definitions(_core PRIVATE HOMLIB_VERSION="${PROJECT_VERSION_FULL}") # The install directory is the output (wheel) directory install(TARGETS _core DESTINATION homlib) diff --git a/python/src/homlib/__init__.py b/python/src/homlib/__init__.py index 8a93f84..a21b2a0 100644 --- a/python/src/homlib/__init__.py +++ b/python/src/homlib/__init__.py @@ -2,6 +2,7 @@ from ._core import ( __doc__, + __version__, PoseData, estimate_fitzgibbon_cvpr_2001_one_sided, estimate_fitzgibbon_cvpr_2001_two_sided_equal, @@ -24,7 +25,6 @@ LORansacOptions, RansacStatistics, ) -from .version import __version__ __all__ = [ "__doc__", diff --git a/python/src/homlib/version.py b/python/src/homlib/version.py deleted file mode 100644 index c62157a..0000000 --- a/python/src/homlib/version.py +++ /dev/null @@ -1 +0,0 @@ -__version__ = "0.1.1-rc6" diff --git a/python/src/main.cpp b/python/src/main.cpp index aedf7e2..a9e2317 100644 --- a/python/src/main.cpp +++ b/python/src/main.cpp @@ -285,6 +285,12 @@ PYBIND11_MODULE(_core, m) { RansacStatistics )pbdoc"; + + #ifdef HOMLIB_VERSION + m.attr("__version__") = py::str(HOMLIB_VERSION); + #else + m.attr("__version__") = py::str("dev"); + #endif py::class_(m, "PoseData") .def( From 80cbf70c475a91d83d0c98884fe8bcf43fee3d0f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 14:41:17 +0200 Subject: [PATCH 04/34] README --- README.md | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index f5289dd..66173c9 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,8 @@ # HomLib ![GitHub release (latest by date)](https://img.shields.io/github/v/release/marcusvaltonen/HomLib) ![GitHub](https://img.shields.io/github/license/marcusvaltonen/HomLib) +![PyPI](https://img.shields.io/pypi/v/homlib) + C++ library for computing homographies with support in MATLAB and Python. @@ -108,10 +110,6 @@ Note: Solvers with known IMU data is not yet supported in the python package. $ pip install homlib ``` -(BELOW IS DEPREACATED) -The official python repository is [python-homlib](https://github.com/marcusvaltonen/python-homlib). -A pre-alpha release is available at PyPi, and can be installed using - ## About the solvers Many of the solvers were generated using the automatic generator proposed by Larsson et al. "Efficient Solvers for Minimal Problems by Syzygy-based From f299d6bed214c91ffa4856f0a8ebd52afbff4ad4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 14:55:16 +0200 Subject: [PATCH 05/34] Try a build for macOS --- .github/workflows/main.yml | 52 ++++++++++++++++++++++---------------- 1 file changed, 30 insertions(+), 22 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 7de9542..bb3e729 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -22,7 +22,12 @@ jobs: fail-fast: false matrix: config: - - { name: Linux, os: ubuntu-latest, artifact: 'libHomLib-linux.zip' } + - name: Linux + os: ubuntu-latest + artifact: 'libHomLib-linux.zip' + - name: macOS + os: macos-latest + artifact: 'libHomLib-macos.zip' env: POSELIB_VERSION: "v2.0.5" @@ -60,7 +65,7 @@ jobs: cmake .. -DCMAKE_INSTALL_PREFIX=${{github.workspace}}/poselib-install \ -DPOSELIB_BUILD_TESTS=OFF \ -DPOSELIB_BUILD_EXAMPLES=OFF - make -j$(nproc) + make -j $(getconf _NPROCESSORS_ONLN) make install - name: Configure project @@ -69,15 +74,17 @@ jobs: -B ${{github.workspace}}/${{env.BUILD_DIR}} \ -DCMAKE_PREFIX_PATH=${{github.workspace}}/poselib-install \ -DCMAKE_BUILD_TYPE=${{env.BUILD_CONFIGURATION}} \ + -DCMAKE_CXX_STANDARD=17 + - name: Compile and Install run: | cmake \ --build ${{github.workspace}}/${{env.BUILD_DIR}} \ --config ${{env.BUILD_CONFIGURATION}} \ - -j $(nproc) + -j $(getconf _NPROCESSORS_ONLN) - name: Execute Tests - run: ctest --test-dir ${{github.workspace}}/${{env.BUILD_DIR}}/tests -j $(nproc) --output-on-failure + run: ctest --test-dir ${{github.workspace}}/${{env.BUILD_DIR}}/tests -j $(getconf _NPROCESSORS_ONLN) --output-on-failure - name: Execute Examples run: ${{github.workspace}}/${{env.BUILD_DIR}}/examples/example @@ -94,13 +101,13 @@ jobs: run: | python -m pip install build python -m build --config-setting=cmake.args="-DCMAKE_PREFIX_PATH=${{github.workspace}}/poselib-install" - - - name: Install and test python pacakge + + - name: Install and test python package run: | python -m pip install pytest pytest-approvaltests numpy python -m pip install dist/*.whl python -m pytest -s python/tests - + - name: Package artifacts shell: bash run: | @@ -122,6 +129,17 @@ jobs: config: - name: linux-intel os: ubuntu-latest + cibw_env: | + BUILD_SHARED_LIBS="OFF" + CMAKE_CXX_FLAGS="-Wno-error" + CMAKE_PREFIX_PATH="/project/poselib-install" + - name: macos + os: macos-latest + cibw_env: | + BUILD_SHARED_LIBS="OFF" + CMAKE_CXX_FLAGS="-Wno-error" + CMAKE_PREFIX_PATH="$GITHUB_WORKSPACE/poselib-install" + env: POSELIB_VERSION: "v2.0.5" @@ -148,9 +166,7 @@ jobs: uses: pypa/cibuildwheel@v3.3.1 env: CIBW_PROJECT_REQUIRES_PYTHON: ">=3.10" - CIBW_ENVIRONMENT: | - BUILD_SHARED_LIBS="OFF" - CMAKE_CXX_FLAGS="-Wno-error" + CIBW_ENVIRONMENT: ${{ matrix.config.cibw_env }} CIBW_BUILD: ${{ github.event_name == 'pull_request' && 'cp310-*' || '' }} CIBW_BEFORE_ALL_LINUX: | yum install -y eigen3-devel @@ -159,7 +175,8 @@ jobs: CIBW_BEFORE_ALL_WINDOWS: C:\vcpkg\vcpkg --triplet x64-windows install eigen3 CIBW_ENVIRONMENT_WINDOWS: CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" CIBW_ARCHS_WINDOWS: "native" - CIBW_BEFORE_ALL_MACOS: brew install eigen + CIBW_BEFORE_ALL_MACOS: | + brew install eigen CIBW_REPAIR_WHEEL_COMMAND_MACOS: "" CIBW_SKIP: "*-musllinux_x86_64" @@ -184,12 +201,11 @@ jobs: with: name: cibw-sdist path: ./dist/*.tar.gz - + release: name: Create GitHub Release needs: [build, build_wheels, build_sdist] if: startsWith(github.ref, 'refs/tags/v') - runs-on: ubuntu-latest steps: - name: Download all artifacts @@ -207,7 +223,6 @@ jobs: tag_name: ${{ github.ref_name }} body: | ## Changes - See the commits for details. draft: false prerelease: false @@ -223,18 +238,11 @@ jobs: permissions: id-token: write if: startsWith(github.ref, 'refs/tags/v') - # or, alternatively, upload to PyPI on every tag starting with 'v' (remove on: release above to use this) - # if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v') steps: - uses: actions/download-artifact@v5 with: - # unpacks all CIBW artifacts into dist/ pattern: cibw-* path: dist merge-multiple: true - - uses: pypa/gh-action-pypi-publish@release/v1 - # To test uploads to TestPyPI, uncomment the following: - # with: - # repository-url: https://test.pypi.org/legacy/ - + - uses: pypa/gh-action-pypi-publish@release/v1 \ No newline at end of file From 8ecb7580d1769655fe68f54b4cc8cbc97a6d98b1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 15:02:46 +0200 Subject: [PATCH 06/34] minor --- .github/workflows/main.yml | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index bb3e729..66df656 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -62,9 +62,14 @@ jobs: git clone --branch ${{ env.POSELIB_VERSION }} https://github.com/PoseLib/PoseLib.git cd PoseLib mkdir build && cd build - cmake .. -DCMAKE_INSTALL_PREFIX=${{github.workspace}}/poselib-install \ - -DPOSELIB_BUILD_TESTS=OFF \ - -DPOSELIB_BUILD_EXAMPLES=OFF + cmake_args="-DCMAKE_INSTALL_PREFIX=${{github.workspace}}/poselib-install \ + -DPOSELIB_BUILD_TESTS=OFF \ + -DPOSELIB_BUILD_EXAMPLES=OFF" + # On macOS, disable warnings-as-errors for unused variables + if [[ "$(uname)" == "Darwin" ]]; then + cmake_args="$cmake_args -DCMAKE_CXX_FLAGS=-Wno-unused-variable" + fi + cmake .. $cmake_args make -j $(getconf _NPROCESSORS_ONLN) make install @@ -73,8 +78,7 @@ jobs: cmake \ -B ${{github.workspace}}/${{env.BUILD_DIR}} \ -DCMAKE_PREFIX_PATH=${{github.workspace}}/poselib-install \ - -DCMAKE_BUILD_TYPE=${{env.BUILD_CONFIGURATION}} \ - -DCMAKE_CXX_STANDARD=17 + -DCMAKE_BUILD_TYPE=${{env.BUILD_CONFIGURATION}} - name: Compile and Install run: | @@ -131,13 +135,11 @@ jobs: os: ubuntu-latest cibw_env: | BUILD_SHARED_LIBS="OFF" - CMAKE_CXX_FLAGS="-Wno-error" CMAKE_PREFIX_PATH="/project/poselib-install" - name: macos os: macos-latest cibw_env: | BUILD_SHARED_LIBS="OFF" - CMAKE_CXX_FLAGS="-Wno-error" CMAKE_PREFIX_PATH="$GITHUB_WORKSPACE/poselib-install" env: From c51d0eac86cd079c2afa4a010ef94db1e06f6d3c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 15:07:42 +0200 Subject: [PATCH 07/34] test --- .github/workflows/main.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 66df656..2050dad 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -67,10 +67,12 @@ jobs: -DPOSELIB_BUILD_EXAMPLES=OFF" # On macOS, disable warnings-as-errors for unused variables if [[ "$(uname)" == "Darwin" ]]; then + echo "Darwin build" cmake_args="$cmake_args -DCMAKE_CXX_FLAGS=-Wno-unused-variable" fi + cmake .. $cmake_args - make -j $(getconf _NPROCESSORS_ONLN) + make VERBOSE=1 -j $(getconf _NPROCESSORS_ONLN) make install - name: Configure project From 258c87cce2379e67023a23e7adfe722a0bc4e47c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 16:35:53 +0200 Subject: [PATCH 08/34] try again --- .github/workflows/main.yml | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 2050dad..3870518 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -62,16 +62,16 @@ jobs: git clone --branch ${{ env.POSELIB_VERSION }} https://github.com/PoseLib/PoseLib.git cd PoseLib mkdir build && cd build - cmake_args="-DCMAKE_INSTALL_PREFIX=${{github.workspace}}/poselib-install \ - -DPOSELIB_BUILD_TESTS=OFF \ - -DPOSELIB_BUILD_EXAMPLES=OFF" - # On macOS, disable warnings-as-errors for unused variables if [[ "$(uname)" == "Darwin" ]]; then - echo "Darwin build" - cmake_args="$cmake_args -DCMAKE_CXX_FLAGS=-Wno-unused-variable" + # On macOS, override -Werror with -Wno-error + EXTRA_CMAKE_ARGS="-DCMAKE_CXX_FLAGS=-Wno-error" + else + EXTRA_CMAKE_ARGS="" fi - - cmake .. $cmake_args + cmake .. -DCMAKE_INSTALL_PREFIX=${{github.workspace}}/poselib-install \ + -DPOSELIB_BUILD_TESTS=OFF \ + -DPOSELIB_BUILD_EXAMPLES=OFF \ + $EXTRA_CMAKE_ARGS make VERBOSE=1 -j $(getconf _NPROCESSORS_ONLN) make install From 200519346fca65c4dca83b542d38a40f15aabe21 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 16:46:59 +0200 Subject: [PATCH 09/34] update poselib version --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 3870518..2ac70bc 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -30,7 +30,7 @@ jobs: artifact: 'libHomLib-macos.zip' env: - POSELIB_VERSION: "v2.0.5" + POSELIB_VERSION: "a69263d5d8" steps: - name: Checkout your project From e6e3cdf16418463beb9b157e77fbc5d62ec4ee17 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 16:50:26 +0200 Subject: [PATCH 10/34] update --- .github/workflows/main.yml | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 2ac70bc..b83309e 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -13,6 +13,7 @@ on: env: BUILD_CONFIGURATION: Release BUILD_DIR: _build + POSELIB_VERSION: a69263d5d8 jobs: build: @@ -29,9 +30,6 @@ jobs: os: macos-latest artifact: 'libHomLib-macos.zip' - env: - POSELIB_VERSION: "a69263d5d8" - steps: - name: Checkout your project uses: actions/checkout@v4 @@ -144,9 +142,6 @@ jobs: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="$GITHUB_WORKSPACE/poselib-install" - env: - POSELIB_VERSION: "v2.0.5" - steps: - name: Checkout your project uses: actions/checkout@v4 From e0d2a94d03aff850174cc11b8483f36832c575d7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 16:53:37 +0200 Subject: [PATCH 11/34] new sha --- .github/workflows/main.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index b83309e..54131b2 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -57,8 +57,9 @@ jobs: - name: Build and install PoseLib if: steps.cache-poselib.outputs.cache-hit != 'true' run: | - git clone --branch ${{ env.POSELIB_VERSION }} https://github.com/PoseLib/PoseLib.git + git clone https://github.com/PoseLib/PoseLib.git cd PoseLib + git checkout ${{ env.POSELIB_VERSION }} mkdir build && cd build if [[ "$(uname)" == "Darwin" ]]; then # On macOS, override -Werror with -Wno-error From 6be8d551573be1b15c8a960b004f674310cd8dda Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 16:59:45 +0200 Subject: [PATCH 12/34] add cassert for appleclang --- HomLib/solvers/kukelova_cvpr_2015/get_kukelova_cvpr_2015.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/HomLib/solvers/kukelova_cvpr_2015/get_kukelova_cvpr_2015.cpp b/HomLib/solvers/kukelova_cvpr_2015/get_kukelova_cvpr_2015.cpp index a0d2a3e..b63e45d 100644 --- a/HomLib/solvers/kukelova_cvpr_2015/get_kukelova_cvpr_2015.cpp +++ b/HomLib/solvers/kukelova_cvpr_2015/get_kukelova_cvpr_2015.cpp @@ -20,6 +20,7 @@ #include "get_kukelova_cvpr_2015.hpp" #include +#include #include #include "solver_kukelova_cvpr_2015.hpp" #include "normalize2dpts.hpp" From 03bcc148ab21781a841b0d8778c9c01cbe9d584b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 17:27:02 +0200 Subject: [PATCH 13/34] Test moving to /usr/local on macOS as well --- .github/workflows/main.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 54131b2..d7cae03 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -177,6 +177,7 @@ jobs: CIBW_ARCHS_WINDOWS: "native" CIBW_BEFORE_ALL_MACOS: | brew install eigen + sudo cp -r $GITHUB_WORKSPACE/poselib-install/* /usr/local/ CIBW_REPAIR_WHEEL_COMMAND_MACOS: "" CIBW_SKIP: "*-musllinux_x86_64" From 443158bd3dd1f6f486e65b16b831ceea849a66c9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 17:34:13 +0200 Subject: [PATCH 14/34] remove debug --- .github/workflows/main.yml | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index d7cae03..63a4dae 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -61,17 +61,10 @@ jobs: cd PoseLib git checkout ${{ env.POSELIB_VERSION }} mkdir build && cd build - if [[ "$(uname)" == "Darwin" ]]; then - # On macOS, override -Werror with -Wno-error - EXTRA_CMAKE_ARGS="-DCMAKE_CXX_FLAGS=-Wno-error" - else - EXTRA_CMAKE_ARGS="" - fi cmake .. -DCMAKE_INSTALL_PREFIX=${{github.workspace}}/poselib-install \ -DPOSELIB_BUILD_TESTS=OFF \ - -DPOSELIB_BUILD_EXAMPLES=OFF \ - $EXTRA_CMAKE_ARGS - make VERBOSE=1 -j $(getconf _NPROCESSORS_ONLN) + -DPOSELIB_BUILD_EXAMPLES=OFF + make -j $(getconf _NPROCESSORS_ONLN) make install - name: Configure project From 239e42080c67e541a6e08b25a0880e7cd6a56b11 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 18:06:51 +0200 Subject: [PATCH 15/34] try windows --- .github/workflows/main.yml | 83 +++++++++++++++++++++++++++++--------- 1 file changed, 63 insertions(+), 20 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 63a4dae..2c15e27 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -29,6 +29,9 @@ jobs: - name: macOS os: macos-latest artifact: 'libHomLib-macos.zip' + - name: Windows + os: windows-latest + artifact: 'libHomLib-windows.zip' steps: - name: Checkout your project @@ -47,6 +50,13 @@ jobs: run: | brew install cmake eigen + - name: Install dependencies (Windows) + if: runner.os == 'Windows' + run: | + vcpkg install eigen3:x64-windows + env: + VCPKG_ROOT: C:\vcpkg + - name: Cache PoseLib build uses: actions/cache@v4 id: cache-poselib @@ -61,34 +71,53 @@ jobs: cd PoseLib git checkout ${{ env.POSELIB_VERSION }} mkdir build && cd build - cmake .. -DCMAKE_INSTALL_PREFIX=${{github.workspace}}/poselib-install \ - -DPOSELIB_BUILD_TESTS=OFF \ - -DPOSELIB_BUILD_EXAMPLES=OFF - make -j $(getconf _NPROCESSORS_ONLN) - make install + cmake_args="-DCMAKE_INSTALL_PREFIX=${{github.workspace}}/poselib-install \ + -DPOSELIB_BUILD_TESTS=OFF \ + -DPOSELIB_BUILD_EXAMPLES=OFF" + if [[ "$RUNNER_OS" == "Windows" ]]; then + cmake_args="$cmake_args -DCMAKE_TOOLCHAIN_FILE=C:\vcpkg\scripts\buildsystems\vcpkg.cmake" + fi + cmake .. $cmake_args + cmake --build . --config ${{env.BUILD_CONFIGURATION}} --parallel + cmake --install . --config ${{env.BUILD_CONFIGURATION}} + shell: bash - name: Configure project run: | - cmake \ - -B ${{github.workspace}}/${{env.BUILD_DIR}} \ - -DCMAKE_PREFIX_PATH=${{github.workspace}}/poselib-install \ - -DCMAKE_BUILD_TYPE=${{env.BUILD_CONFIGURATION}} + cmake_args="-B ${{github.workspace}}/${{env.BUILD_DIR}} \ + -DCMAKE_PREFIX_PATH=${{github.workspace}}/poselib-install \ + -DCMAKE_BUILD_TYPE=${{env.BUILD_CONFIGURATION}}" + if [[ "$RUNNER_OS" == "Windows" ]]; then + cmake_args="$cmake_args -DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake" + fi + cmake $cmake_args + shell: bash - name: Compile and Install run: | - cmake \ - --build ${{github.workspace}}/${{env.BUILD_DIR}} \ - --config ${{env.BUILD_CONFIGURATION}} \ - -j $(getconf _NPROCESSORS_ONLN) + cmake --build ${{github.workspace}}/${{env.BUILD_DIR}} --config ${{env.BUILD_CONFIGURATION}} --parallel + shell: bash - name: Execute Tests - run: ctest --test-dir ${{github.workspace}}/${{env.BUILD_DIR}}/tests -j $(getconf _NPROCESSORS_ONLN) --output-on-failure + run: ctest --test-dir ${{github.workspace}}/${{env.BUILD_DIR}}/tests --output-on-failure - - name: Execute Examples - run: ${{github.workspace}}/${{env.BUILD_DIR}}/examples/example + - name: Execute Example + shell: bash + run: | + if [[ "$RUNNER_OS" == "Windows" ]]; then + "${{github.workspace}}/${{env.BUILD_DIR}}/examples/${{env.BUILD_CONFIGURATION}}/example.exe" + else + "${{github.workspace}}/${{env.BUILD_DIR}}/examples/example" + fi - - name: Execute RANSAC Examples - run: ${{github.workspace}}/${{env.BUILD_DIR}}/examples/example_ransac + - name: Execute RANSAC Example + shell: bash + run: | + if [[ "$RUNNER_OS" == "Windows" ]]; then + "${{github.workspace}}/${{env.BUILD_DIR}}/examples/${{env.BUILD_CONFIGURATION}}/example_ransac.exe" + else + "${{github.workspace}}/${{env.BUILD_DIR}}/examples/example_ransac" + fi - name: Setup python uses: actions/setup-python@v5 @@ -98,7 +127,12 @@ jobs: - name: Build python package run: | python -m pip install build - python -m build --config-setting=cmake.args="-DCMAKE_PREFIX_PATH=${{github.workspace}}/poselib-install" + if [[ "$RUNNER_OS" == "Windows" ]]; then + python -m build --config-setting=cmake.args="-DCMAKE_PREFIX_PATH=${{github.workspace}}\\poselib-install" + else + python -m build --config-setting=cmake.args="-DCMAKE_PREFIX_PATH=${{github.workspace}}/poselib-install" + fi + shell: bash - name: Install and test python package run: | @@ -109,7 +143,11 @@ jobs: - name: Package artifacts shell: bash run: | - zip -r ${{ matrix.config.artifact }} ${{github.workspace}}/${{env.BUILD_DIR}} + if [[ "$RUNNER_OS" == "Windows" ]]; then + powershell -Command "Compress-Archive -Path '${{github.workspace}}\\${{env.BUILD_DIR}}' -DestinationPath ${{ matrix.config.artifact }}" + else + zip -r ${{ matrix.config.artifact }} ${{github.workspace}}/${{env.BUILD_DIR}} + fi - name: Upload artifact (for later release) uses: actions/upload-artifact@v4 @@ -135,6 +173,11 @@ jobs: cibw_env: | BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="$GITHUB_WORKSPACE/poselib-install" + - name: windows + os: windows-latest + cibw_env: | + BUILD_SHARED_LIBS="OFF" + CMAKE_PREFIX_PATH="${{github.workspace}}\\poselib-install" steps: - name: Checkout your project From 3645b2768fb0efaed95a6bd32d63732b41c4feef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 18:35:21 +0200 Subject: [PATCH 16/34] Fix Windows paths --- .github/workflows/main.yml | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 2c15e27..1fe8dcb 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -95,17 +95,29 @@ jobs: - name: Compile and Install run: | - cmake --build ${{github.workspace}}/${{env.BUILD_DIR}} --config ${{env.BUILD_CONFIGURATION}} --parallel + if [[ "$RUNNER_OS" == "Windows" ]]; then + build_path="${{github.workspace}}\\${{env.BUILD_DIR}}" + else + build_path="${{github.workspace}}/${{env.BUILD_DIR}}" + fi + cmake --build "$build_path" --config ${{env.BUILD_CONFIGURATION}} --parallel shell: bash - name: Execute Tests - run: ctest --test-dir ${{github.workspace}}/${{env.BUILD_DIR}}/tests --output-on-failure + run: | + if [[ "$RUNNER_OS" == "Windows" ]]; then + test_path="${{github.workspace}}\\${{env.BUILD_DIR}}\\tests" + else + test_path="${{github.workspace}}/${{env.BUILD_DIR}}/tests" + fi + ctest --test-dir "$test_path" --output-on-failure + shell: bash - name: Execute Example shell: bash run: | if [[ "$RUNNER_OS" == "Windows" ]]; then - "${{github.workspace}}/${{env.BUILD_DIR}}/examples/${{env.BUILD_CONFIGURATION}}/example.exe" + "${{github.workspace}}\\${{env.BUILD_DIR}}\\examples\\${{env.BUILD_CONFIGURATION}}\\example.exe" else "${{github.workspace}}/${{env.BUILD_DIR}}/examples/example" fi @@ -114,7 +126,7 @@ jobs: shell: bash run: | if [[ "$RUNNER_OS" == "Windows" ]]; then - "${{github.workspace}}/${{env.BUILD_DIR}}/examples/${{env.BUILD_CONFIGURATION}}/example_ransac.exe" + "${{github.workspace}}\\${{env.BUILD_DIR}}\\examples\\${{env.BUILD_CONFIGURATION}}\\example_ransac.exe" else "${{github.workspace}}/${{env.BUILD_DIR}}/examples/example_ransac" fi From 1548dce592589cc60d5663d42a7209a013bcf60b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 20:12:44 +0200 Subject: [PATCH 17/34] add windows stuff --- python/CMakeLists.txt | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/python/CMakeLists.txt b/python/CMakeLists.txt index 6a2023b..2c5b387 100644 --- a/python/CMakeLists.txt +++ b/python/CMakeLists.txt @@ -7,9 +7,14 @@ cmake_minimum_required(VERSION 3.15...3.27) project( ${SKBUILD_PROJECT_NAME} VERSION ${SKBUILD_PROJECT_VERSION} - LANGUAGES CXX) + LANGUAGES CXX +) -SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3 -ftree-vectorize -funroll-loops") +if(MSVC) + SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /bigobj") +else() + SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3 -ftree-vectorize -funroll-loops") +endif() # Find the module development requirements (requires FindPython from 3.17 or # scikit-build-core's built-in backport) @@ -34,6 +39,8 @@ target_link_libraries(_core PRIVATE PoseLib::PoseLib) target_include_directories(_core PRIVATE ${HOMLIB_INCLUDE_DIRS}) target_include_directories(_core PRIVATE ../thirdparty/RansacLib) target_compile_definitions(_core PRIVATE HOMLIB_VERSION="${PROJECT_VERSION_FULL}") - +if(MSVC) + target_compile_definitions(_core PRIVATE _USE_MATH_DEFINES) +endif() # The install directory is the output (wheel) directory install(TARGETS _core DESTINATION homlib) From d2bd4cdec6eb8731ab46a9a30cdd83640b46802b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 20:15:33 +0200 Subject: [PATCH 18/34] split build steps --- .github/workflows/main.yml | 72 +++++++++++++++++++++++++++++--------- 1 file changed, 56 insertions(+), 16 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 1fe8dcb..13d8c28 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -131,6 +131,61 @@ jobs: "${{github.workspace}}/${{env.BUILD_DIR}}/examples/example_ransac" fi + build_python: + name: Build Python for ${{ matrix.config.name }} + depends: [build] + runs-on: ${{ matrix.config.os }} + strategy: + fail-fast: false + matrix: + config: + - name: Linux + os: ubuntu-latest + artifact: 'libHomLib-linux.zip' + - name: macOS + os: macos-latest + artifact: 'libHomLib-macos.zip' + - name: Windows + os: windows-latest + artifact: 'libHomLib-windows.zip' + + steps: + - name: Checkout your project + uses: actions/checkout@v4 + with: + submodules: 'recursive' + + - name: Install dependencies (Linux) + if: runner.os == 'Linux' + run: | + sudo apt-get update + sudo apt-get install -y cmake build-essential libeigen3-dev + + - name: Install dependencies (macOS) + if: runner.os == 'macOS' + run: | + brew install cmake eigen + + - name: Install dependencies (Windows) + if: runner.os == 'Windows' + run: | + vcpkg install eigen3:x64-windows + env: + VCPKG_ROOT: C:\vcpkg + + - name: Restore PoseLib cache + uses: actions/cache@v4 + id: cache-poselib + with: + path: ${{github.workspace}}/poselib-install + key: ${{ runner.os }}-poselib-${{ env.POSELIB_VERSION }} + + - name: Fail if cache miss + if: steps.cache-poselib.outputs.cache-hit != 'true' + run: | + echo "Cache miss for PoseLib. Build cannot proceed." + exit 1 + - name: Setup python uses: actions/setup-python@v5 with: @@ -152,24 +207,9 @@ jobs: python -m pip install dist/*.whl python -m pytest -s python/tests - - name: Package artifacts - shell: bash - run: | - if [[ "$RUNNER_OS" == "Windows" ]]; then - powershell -Command "Compress-Archive -Path '${{github.workspace}}\\${{env.BUILD_DIR}}' -DestinationPath ${{ matrix.config.artifact }}" - else - zip -r ${{ matrix.config.artifact }} ${{github.workspace}}/${{env.BUILD_DIR}} - fi - - - name: Upload artifact (for later release) - uses: actions/upload-artifact@v4 - with: - name: ${{ matrix.config.artifact }} - path: ${{ matrix.config.artifact }} - build_wheels: name: Build wheels for ${{ matrix.config.name }} - needs: [build] + needs: [build, build_python] runs-on: ${{ matrix.config.os }} strategy: fail-fast: false From 950dbf3ecfecd447e0e3c35ac158ad72df15ce8a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 20:16:10 +0200 Subject: [PATCH 19/34] typo --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 13d8c28..c87dc32 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -133,7 +133,7 @@ jobs: build_python: name: Build Python for ${{ matrix.config.name }} - depends: [build] + needs: [build] runs-on: ${{ matrix.config.os }} strategy: fail-fast: false From e5e7d970c4f03dad1f459d4c2fad7c4a504abd18 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 21:28:41 +0200 Subject: [PATCH 20/34] debug windows --- .github/workflows/main.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index c87dc32..9717a70 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -201,6 +201,17 @@ jobs: fi shell: bash + - name: Debug built files + run: | + echo "=== Current directory ===" + ls -la + echo "=== Dist directory ===" + ls -la dist || echo "dist not found" + echo "=== Wheel files in root ===" + ls -la *.whl 2>/dev/null || echo "No wheel in root" + shell: bash + + - name: Install and test python package run: | python -m pip install pytest pytest-approvaltests numpy From 43fda44ba205a0c2bc71d83b783c07c2720df732 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Mon, 30 Mar 2026 23:30:58 +0200 Subject: [PATCH 21/34] wildcard expansion removed --- .github/workflows/main.yml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 9717a70..cdb43e5 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -214,9 +214,17 @@ jobs: - name: Install and test python package run: | + wheel_file=$(ls dist/*.whl 2>/dev/null | head -n1) + if [ -n "$wheel_file" ]; then + echo "Found wheel: $wheel_file" + else + echo "Did not find wheel in dist. Exiting.." + exit 1 + fi python -m pip install pytest pytest-approvaltests numpy - python -m pip install dist/*.whl + python -m pip install "$wheel_file" python -m pytest -s python/tests + shell: bash build_wheels: name: Build wheels for ${{ matrix.config.name }} From 5b1e0da9f4e38cba5e5d4ba2761cb5d14daeedd5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Tue, 31 Mar 2026 10:33:59 +0200 Subject: [PATCH 22/34] Test windows wheels --- .github/workflows/main.yml | 18 +++++------------- pyproject.toml | 1 + python/CMakeLists.txt | 2 ++ 3 files changed, 8 insertions(+), 13 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index cdb43e5..2ef1554 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -201,17 +201,6 @@ jobs: fi shell: bash - - name: Debug built files - run: | - echo "=== Current directory ===" - ls -la - echo "=== Dist directory ===" - ls -la dist || echo "dist not found" - echo "=== Wheel files in root ===" - ls -la *.whl 2>/dev/null || echo "No wheel in root" - shell: bash - - - name: Install and test python package run: | wheel_file=$(ls dist/*.whl 2>/dev/null | head -n1) @@ -248,7 +237,7 @@ jobs: os: windows-latest cibw_env: | BUILD_SHARED_LIBS="OFF" - CMAKE_PREFIX_PATH="${{github.workspace}}\\poselib-install" + CMAKE_PREFIX_PATH="D:\\poselib" steps: - name: Checkout your project @@ -279,7 +268,10 @@ jobs: yum install -y eigen3-devel cp -r /project/poselib-install/* /usr/local/ CIBW_ARCHS_LINUX: "native" - CIBW_BEFORE_ALL_WINDOWS: C:\vcpkg\vcpkg --triplet x64-windows install eigen3 + CIBW_BEFORE_ALL_WINDOWS: | + C:\vcpkg\vcpkg --triplet x64-windows install eigen3 + mkdir D:\poselib + xcopy /E /I %GITHUB_WORKSPACE%\poselib-install\* D:\poselib\ CIBW_ENVIRONMENT_WINDOWS: CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" CIBW_ARCHS_WINDOWS: "native" CIBW_BEFORE_ALL_MACOS: | diff --git a/pyproject.toml b/pyproject.toml index 29a1e2d..0058433 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -25,6 +25,7 @@ classifiers = [ wheel.packages = ["python/src/homlib"] wheel.expand-macos-universal-tags = true minimum-version = "build-system.requires" +cmake.build-verbose = true [tool.scikit-build.cmake.define] BUILD_EXAMPLES = "OFF" diff --git a/python/CMakeLists.txt b/python/CMakeLists.txt index 2c5b387..06e0a8b 100644 --- a/python/CMakeLists.txt +++ b/python/CMakeLists.txt @@ -16,6 +16,8 @@ else() SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3 -ftree-vectorize -funroll-loops") endif() +message(STATUS "CMAKE_PREFIX_PATH = ${CMAKE_PREFIX_PATH}") + # Find the module development requirements (requires FindPython from 3.17 or # scikit-build-core's built-in backport) find_package(Python REQUIRED COMPONENTS Interpreter Development.Module) From d787598b9f00352d35084a54929ab026767f2563 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Tue, 31 Mar 2026 11:06:42 +0200 Subject: [PATCH 23/34] typo --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 0058433..c85e54d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -25,7 +25,7 @@ classifiers = [ wheel.packages = ["python/src/homlib"] wheel.expand-macos-universal-tags = true minimum-version = "build-system.requires" -cmake.build-verbose = true +cmake.build.verbose = true [tool.scikit-build.cmake.define] BUILD_EXAMPLES = "OFF" From c9a726318785727c52abfe970a4cef01f9bf968c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Tue, 31 Mar 2026 11:17:05 +0200 Subject: [PATCH 24/34] ahhh ..... --- pyproject.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c85e54d..29a1e2d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -25,7 +25,6 @@ classifiers = [ wheel.packages = ["python/src/homlib"] wheel.expand-macos-universal-tags = true minimum-version = "build-system.requires" -cmake.build.verbose = true [tool.scikit-build.cmake.define] BUILD_EXAMPLES = "OFF" From 8c4e7e7f054cb4ac6b6c5fa66e1543a68abbcb91 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Tue, 31 Mar 2026 12:25:25 +0200 Subject: [PATCH 25/34] Fix environments --- .github/workflows/main.yml | 26 ++++++-------------------- 1 file changed, 6 insertions(+), 20 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 2ef1554..52cd07e 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -225,19 +225,10 @@ jobs: config: - name: linux-intel os: ubuntu-latest - cibw_env: | - BUILD_SHARED_LIBS="OFF" - CMAKE_PREFIX_PATH="/project/poselib-install" - name: macos os: macos-latest - cibw_env: | - BUILD_SHARED_LIBS="OFF" - CMAKE_PREFIX_PATH="$GITHUB_WORKSPACE/poselib-install" - name: windows os: windows-latest - cibw_env: | - BUILD_SHARED_LIBS="OFF" - CMAKE_PREFIX_PATH="D:\\poselib" steps: - name: Checkout your project @@ -262,21 +253,16 @@ jobs: uses: pypa/cibuildwheel@v3.3.1 env: CIBW_PROJECT_REQUIRES_PYTHON: ">=3.10" - CIBW_ENVIRONMENT: ${{ matrix.config.cibw_env }} + CIBW_ENVIRONMENT: BUILD_SHARED_LIBS="OFF" CIBW_BUILD: ${{ github.event_name == 'pull_request' && 'cp310-*' || '' }} - CIBW_BEFORE_ALL_LINUX: | - yum install -y eigen3-devel - cp -r /project/poselib-install/* /usr/local/ + CIBW_BEFORE_ALL_LINUX: yum install -y eigen3-devel + CIBW_ENVIRONMENT_LINUX: CMAKE_PREFIX_PATH="/project/poselib-install" CIBW_ARCHS_LINUX: "native" - CIBW_BEFORE_ALL_WINDOWS: | - C:\vcpkg\vcpkg --triplet x64-windows install eigen3 - mkdir D:\poselib - xcopy /E /I %GITHUB_WORKSPACE%\poselib-install\* D:\poselib\ + CIBW_BEFORE_ALL_WINDOWS: C:\vcpkg\vcpkg --triplet x64-windows install eigen3 CIBW_ENVIRONMENT_WINDOWS: CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" CIBW_ARCHS_WINDOWS: "native" - CIBW_BEFORE_ALL_MACOS: | - brew install eigen - sudo cp -r $GITHUB_WORKSPACE/poselib-install/* /usr/local/ + CIBW_BEFORE_ALL_MACOS: brew install eigen + CIBW_ENVIRONMENT_MACOS: CMAKE_PREFIX_PATH="$GITHUB_WORKSPACE/poselib-install" CIBW_REPAIR_WHEEL_COMMAND_MACOS: "" CIBW_SKIP: "*-musllinux_x86_64" From 88362c4077853dfc5e4f76ee59783819b4cc5092 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Tue, 31 Mar 2026 12:58:32 +0200 Subject: [PATCH 26/34] Test again --- .github/workflows/main.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 52cd07e..9a2989d 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -253,16 +253,15 @@ jobs: uses: pypa/cibuildwheel@v3.3.1 env: CIBW_PROJECT_REQUIRES_PYTHON: ">=3.10" - CIBW_ENVIRONMENT: BUILD_SHARED_LIBS="OFF" CIBW_BUILD: ${{ github.event_name == 'pull_request' && 'cp310-*' || '' }} CIBW_BEFORE_ALL_LINUX: yum install -y eigen3-devel - CIBW_ENVIRONMENT_LINUX: CMAKE_PREFIX_PATH="/project/poselib-install" + CIBW_ENVIRONMENT_LINUX: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="/project/poselib-install" CIBW_ARCHS_LINUX: "native" CIBW_BEFORE_ALL_WINDOWS: C:\vcpkg\vcpkg --triplet x64-windows install eigen3 - CIBW_ENVIRONMENT_WINDOWS: CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" + CIBW_ENVIRONMENT_WINDOWS: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="%GITHUB_WORKSPACE%\\poselib-install" CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" CIBW_ARCHS_WINDOWS: "native" CIBW_BEFORE_ALL_MACOS: brew install eigen - CIBW_ENVIRONMENT_MACOS: CMAKE_PREFIX_PATH="$GITHUB_WORKSPACE/poselib-install" + CIBW_ENVIRONMENT_MACOS: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="$GITHUB_WORKSPACE/poselib-install" CIBW_REPAIR_WHEEL_COMMAND_MACOS: "" CIBW_SKIP: "*-musllinux_x86_64" From fde1cd753f5b18d7d6108dc7ab4fb84d9a9bf8fe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Tue, 31 Mar 2026 13:49:23 +0200 Subject: [PATCH 27/34] faster debugging --- .github/workflows/main.yml | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 9a2989d..e39cb46 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -217,7 +217,7 @@ jobs: build_wheels: name: Build wheels for ${{ matrix.config.name }} - needs: [build, build_python] + # needs: [build, build_python] runs-on: ${{ matrix.config.os }} strategy: fail-fast: false @@ -249,6 +249,13 @@ jobs: echo "Cache miss for PoseLib. Build cannot proceed." exit 1 + - name: List PoseLib install (debug) + if: runner.os == 'Windows' + run: | + echo "Contents of ${{github.workspace}}/poselib-install:" + ls -R ${{github.workspace}}/poselib-install + shell: bash + - name: Build wheels uses: pypa/cibuildwheel@v3.3.1 env: @@ -258,7 +265,7 @@ jobs: CIBW_ENVIRONMENT_LINUX: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="/project/poselib-install" CIBW_ARCHS_LINUX: "native" CIBW_BEFORE_ALL_WINDOWS: C:\vcpkg\vcpkg --triplet x64-windows install eigen3 - CIBW_ENVIRONMENT_WINDOWS: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="%GITHUB_WORKSPACE%\\poselib-install" CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" + CIBW_ENVIRONMENT_WINDOWS: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="${{github.workspace}}/poselib-install" CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" CIBW_ARCHS_WINDOWS: "native" CIBW_BEFORE_ALL_MACOS: brew install eigen CIBW_ENVIRONMENT_MACOS: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="$GITHUB_WORKSPACE/poselib-install" From bae7926f86e526cba0fbdee07467b1cfe398fd5f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Tue, 31 Mar 2026 13:50:53 +0200 Subject: [PATCH 28/34] tmp --- .github/workflows/main.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index e39cb46..b4fbbae 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -252,8 +252,8 @@ jobs: - name: List PoseLib install (debug) if: runner.os == 'Windows' run: | - echo "Contents of ${{github.workspace}}/poselib-install:" - ls -R ${{github.workspace}}/poselib-install + echo "Contents of ${{github.workspace}}\\poselib-install:" + ls -R ${{github.workspace}}\\poselib-install shell: bash - name: Build wheels @@ -265,7 +265,7 @@ jobs: CIBW_ENVIRONMENT_LINUX: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="/project/poselib-install" CIBW_ARCHS_LINUX: "native" CIBW_BEFORE_ALL_WINDOWS: C:\vcpkg\vcpkg --triplet x64-windows install eigen3 - CIBW_ENVIRONMENT_WINDOWS: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="${{github.workspace}}/poselib-install" CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" + CIBW_ENVIRONMENT_WINDOWS: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="${{github.workspace}}\\poselib-install" CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" CIBW_ARCHS_WINDOWS: "native" CIBW_BEFORE_ALL_MACOS: brew install eigen CIBW_ENVIRONMENT_MACOS: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="$GITHUB_WORKSPACE/poselib-install" From dc416fcd5ca8f3830a9e8f51e752d9b8339494e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Tue, 31 Mar 2026 13:58:13 +0200 Subject: [PATCH 29/34] tmp --- .github/workflows/main.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index b4fbbae..8f8ddb7 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -252,8 +252,10 @@ jobs: - name: List PoseLib install (debug) if: runner.os == 'Windows' run: | - echo "Contents of ${{github.workspace}}\\poselib-install:" - ls -R ${{github.workspace}}\\poselib-install + workspace="${GITHUB_WORKSPACE//\\//}" + poselib_path="$workspace/poselib-install" + echo "Contents of $poselib_path:" + ls -R "$poselib_path" shell: bash - name: Build wheels From 95050ad6b7a8517f4aede416ecb4952d348d22f4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Tue, 31 Mar 2026 14:03:55 +0200 Subject: [PATCH 30/34] test --- .github/workflows/main.yml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 8f8ddb7..32de2f1 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -266,8 +266,11 @@ jobs: CIBW_BEFORE_ALL_LINUX: yum install -y eigen3-devel CIBW_ENVIRONMENT_LINUX: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="/project/poselib-install" CIBW_ARCHS_LINUX: "native" - CIBW_BEFORE_ALL_WINDOWS: C:\vcpkg\vcpkg --triplet x64-windows install eigen3 - CIBW_ENVIRONMENT_WINDOWS: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="${{github.workspace}}\\poselib-install" CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" + CIBW_BEFORE_ALL_WINDOWS: | + C:\vcpkg\vcpkg --triplet x64-windows install eigen3 + if not exist C:\poselib mkdir C:\poselib + xcopy /E /I "%GITHUB_WORKSPACE%\poselib-install\*" D:\poselib\ + CIBW_ENVIRONMENT_WINDOWS: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="D:\\poselib" CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" CIBW_ARCHS_WINDOWS: "native" CIBW_BEFORE_ALL_MACOS: brew install eigen CIBW_ENVIRONMENT_MACOS: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="$GITHUB_WORKSPACE/poselib-install" From 007802ad1bf9536aa3d27a3d690ed014d2588d93 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Tue, 31 Mar 2026 14:10:17 +0200 Subject: [PATCH 31/34] tmp --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 32de2f1..70d069d 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -268,7 +268,7 @@ jobs: CIBW_ARCHS_LINUX: "native" CIBW_BEFORE_ALL_WINDOWS: | C:\vcpkg\vcpkg --triplet x64-windows install eigen3 - if not exist C:\poselib mkdir C:\poselib + if not exist D:\poselib mkdir D:\poselib xcopy /E /I "%GITHUB_WORKSPACE%\poselib-install\*" D:\poselib\ CIBW_ENVIRONMENT_WINDOWS: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="D:\\poselib" CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" CIBW_ARCHS_WINDOWS: "native" From 4d3976472b7ead68db8a1a01c1bcd8e0079bbe59 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Tue, 31 Mar 2026 14:11:09 +0200 Subject: [PATCH 32/34] more debug --- .github/workflows/main.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 70d069d..54d5944 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -270,6 +270,7 @@ jobs: C:\vcpkg\vcpkg --triplet x64-windows install eigen3 if not exist D:\poselib mkdir D:\poselib xcopy /E /I "%GITHUB_WORKSPACE%\poselib-install\*" D:\poselib\ + dir D:\poselib CIBW_ENVIRONMENT_WINDOWS: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="D:\\poselib" CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" CIBW_ARCHS_WINDOWS: "native" CIBW_BEFORE_ALL_MACOS: brew install eigen From 20180232bf50e08f198da6ff01d0c76cf8999a4c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Tue, 31 Mar 2026 14:15:18 +0200 Subject: [PATCH 33/34] read docs.. --- .github/workflows/main.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 54d5944..8d09efb 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -266,10 +266,10 @@ jobs: CIBW_BEFORE_ALL_LINUX: yum install -y eigen3-devel CIBW_ENVIRONMENT_LINUX: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="/project/poselib-install" CIBW_ARCHS_LINUX: "native" - CIBW_BEFORE_ALL_WINDOWS: | - C:\vcpkg\vcpkg --triplet x64-windows install eigen3 - if not exist D:\poselib mkdir D:\poselib - xcopy /E /I "%GITHUB_WORKSPACE%\poselib-install\*" D:\poselib\ + CIBW_BEFORE_ALL_WINDOWS: > + C:\vcpkg\vcpkg --triplet x64-windows install eigen3 && + if not exist D:\poselib mkdir D:\poselib && + xcopy /E /I "%GITHUB_WORKSPACE%\poselib-install\*" D:\poselib\ && dir D:\poselib CIBW_ENVIRONMENT_WINDOWS: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="D:\\poselib" CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" CIBW_ARCHS_WINDOWS: "native" From 3a46d10a211c3991d99c0a3cd6269d6cae8055bc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcus=20Valtonen=20=C3=96rnhag?= Date: Tue, 31 Mar 2026 14:21:57 +0200 Subject: [PATCH 34/34] Remove debug stuff --- .github/workflows/main.yml | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 8d09efb..224ee7d 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -217,7 +217,7 @@ jobs: build_wheels: name: Build wheels for ${{ matrix.config.name }} - # needs: [build, build_python] + needs: [build, build_python] runs-on: ${{ matrix.config.os }} strategy: fail-fast: false @@ -249,15 +249,6 @@ jobs: echo "Cache miss for PoseLib. Build cannot proceed." exit 1 - - name: List PoseLib install (debug) - if: runner.os == 'Windows' - run: | - workspace="${GITHUB_WORKSPACE//\\//}" - poselib_path="$workspace/poselib-install" - echo "Contents of $poselib_path:" - ls -R "$poselib_path" - shell: bash - - name: Build wheels uses: pypa/cibuildwheel@v3.3.1 env: @@ -269,8 +260,7 @@ jobs: CIBW_BEFORE_ALL_WINDOWS: > C:\vcpkg\vcpkg --triplet x64-windows install eigen3 && if not exist D:\poselib mkdir D:\poselib && - xcopy /E /I "%GITHUB_WORKSPACE%\poselib-install\*" D:\poselib\ && - dir D:\poselib + xcopy /E /I "%GITHUB_WORKSPACE%\poselib-install\*" D:\poselib\ CIBW_ENVIRONMENT_WINDOWS: BUILD_SHARED_LIBS="OFF" CMAKE_PREFIX_PATH="D:\\poselib" CMAKE_TOOLCHAIN_FILE="C:\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake" CIBW_ARCHS_WINDOWS: "native" CIBW_BEFORE_ALL_MACOS: brew install eigen