-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Homebrew CI: set Python3_EXECUTABLE in cmake (#1110)
If the formula of the package being tested defines a python_cmake_arg method, then set Python3_EXECUTABLE when invoking cmake. Also append to CMAKE_ARGS variable. Signed-off-by: Steve Peters <[email protected]>
- Loading branch information
Showing
1 changed file
with
5 additions
and
1 deletion.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -123,7 +123,7 @@ if brew ruby -e "exit ! '${PROJECT_FORMULA}'.f.recursive_dependencies.map(&:name | |
fi | ||
# set cmake args if we are using qwt-qt5 | ||
if brew ruby -e "exit ! '${PROJECT_FORMULA}'.f.recursive_dependencies.map(&:name).keep_if { |d| d == 'qwt-qt5' }.empty?"; then | ||
CMAKE_ARGS='-DQWT_WIN_INCLUDE_DIR=/usr/local/opt/qwt-qt5/lib/qwt.framework/Headers -DQWT_WIN_LIBRARY_DIR=/usr/local/opt/qwt-qt5/lib' | ||
CMAKE_ARGS="${CMAKE_ARGS} -DQWT_WIN_INCLUDE_DIR=/usr/local/opt/qwt-qt5/lib/qwt.framework/Headers -DQWT_WIN_LIBRARY_DIR=/usr/local/opt/qwt-qt5/lib" | ||
fi | ||
# Workaround for [email protected]: set PATH | ||
if brew ruby -e "exit ! '${PROJECT_FORMULA}'.f.recursive_dependencies.map(&:name).keep_if { |d| d == 'osrf/simulation/[email protected]' }.empty?"; then | ||
|
@@ -147,6 +147,10 @@ fi | |
if brew ruby -e "exit ! '${PROJECT_FORMULA}'.f.recursive_dependencies.map(&:name).keep_if { |d| d == 'icu4c' }.empty?"; then | ||
export LIBRARY_PATH=${LIBRARY_PATH}:/usr/local/opt/icu4c/lib | ||
fi | ||
# set Python3_EXECUTABLE if this homebrew formula defines the python_cmake_arg method | ||
if brew ruby -e "exit '${PROJECT_FORMULA}'.f.respond_to?(:python_cmake_arg)"; then | ||
CMAKE_ARGS="${CMAKE_ARGS} -DPython3_EXECUTABLE=$(which python3)" | ||
fi | ||
|
||
# if we are using [email protected] (custom OR port), need to add dartsim library path since it is keg-only | ||
if brew ruby -e "exit ! '${PROJECT_FORMULA}'.f.recursive_dependencies.map(&:name).keep_if { |d| d == 'osrf/simulation/[email protected]' }.empty?"; then | ||
|