Skip to content

Commit

Permalink
build: fix recently broken rpath to restore python wheel building (#4633
Browse files Browse the repository at this point in the history
)

Also, make the wheel workflow work on pushes when the branch name
contains the substring "python" or "wheel", and when any of the cmake
build files in src/cmake (which control building of dependencies,
among other things), even if none of the python bindings themselves
are touched. This means that if you suspect your work might cause a
wheel to break even though you're not modifying the python bindings
directly, you can ensure that the wheel workflow will run on CI simply
by naming your branch to contain one of those words.

Signed-off-by: Larry Gritz <[email protected]>
  • Loading branch information
lgritz authored Feb 12, 2025
1 parent 1fdc5d0 commit a440e4b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
10 changes: 7 additions & 3 deletions .github/workflows/wheel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,21 +14,25 @@ permissions:
on:
push:
# Workflow run on tags for v3 only, or pre-tagged pushes of release, or
# dev-3.* branches.
# dev-3.* branches. Also if the branch name itself contains the substrings
# 'wheel' or 'python'.
tags:
- v3.*
branches:
- release
- dev-3.*
- "*wheel*"
- "*python*"
pull_request:
# Workflow run on pull_request only when related files change.
# Workflow run on pull_request only when related files change, or when the
# branch name itself contains the substrings 'wheel' or 'python'.
paths:
- .github/workflows/wheel.yml
- pyproject.toml
- src/python/*.py
- src/python/*.h
- src/python/*.cpp
- src/cmake/pythonutils.cmake
- src/cmake/*.cmake
schedule:
# Nightly build
- cron: "0 8 * * *"
Expand Down
1 change: 1 addition & 0 deletions src/cmake/compiler.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -691,6 +691,7 @@ else ()
set(BASEPOINT $ORIGIN)
endif()
set (CMAKE_INSTALL_RPATH ${BASEPOINT}
${BASEPOINT}/${CMAKE_INSTALL_LIBDIR}
${BASEPOINT}/../${CMAKE_INSTALL_LIBDIR})
endif ()
# add the automatically determined parts of the RPATH that
Expand Down

0 comments on commit a440e4b

Please sign in to comment.