igor-krechetov / hsmcpp

C++ based Hierarchical / Finite State Machine library oriented for embedded and RTOS systems.
https://hsmcpp.readthedocs.io
MIT License
62 stars 7 forks source link

cmake findpython alternation #3

Closed yoowonsuk closed 1 year ago

yoowonsuk commented 1 year ago

Hi @igor-krechetov

There is no difference in function. but cmake can't find python3 interpreter in our build system (to be exact, Python_EXECUTABLE isn't specified and thus it uses host python3)

Platform information:

find_python is desirable, if not essential. https://stackoverflow.com/questions/72693284/findpython-vs-find-packagepython https://cmake.org/cmake/help/latest/module/FindPython.html

Also, can you expand a bit on what I commented about before and after? Thanks!

igor-krechetov commented 1 year ago

Hello @yoowonsuk , You are right. include(FindPython3) was not the correct way to add python module and your proposed option is better.

Unfortunately I did some changed on the main branch which messed up this pull request's commits. Can you please rebase to master and update PR so that it contains only 1 commit? Or I can just cherry-pick and push your fix manually without a PR.