Skip to content

Commit

Permalink
(conan-io#5643) Boost.python requires numpy. Fix function _run_python…
Browse files Browse the repository at this point in the history
…_script().

* Boost.python requires numpy. Fix function _run_python_script(), was broken when script returns empty output.

* Boost: implement PR conan-io#5643 feedback from @SSE4. Remove numpy check, needs more investigation
  • Loading branch information
wdobbe authored and madebr committed Jun 21, 2021
1 parent c635047 commit a2d7e50
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion recipes/boost/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -528,10 +528,11 @@ def _run_python_script(self, script):
except ConanException:
self.output.info("(failed)")
return None
output = output.getvalue().strip()
output = output.getvalue()
# Conan is broken when run_to_output = True
if "\n-----------------\n" in output:
output = output.split("\n-----------------\n", 1)[1]
output = output.strip()
return output if output != "None" else None

def _get_python_path(self, name):
Expand Down

0 comments on commit a2d7e50

Please sign in to comment.