Cannot use python script in custom target #13907
-
I am actually trying to use the
i.e. it does not try to use the interpreter python3 which is present in the shebang of the sqlite2cpp.py script in this form (which, from what I understand, is understood by meson):
Note that the sqlite2cpp.py script has its executable bit unset (as the "permission denied" error proves it), which should trigger the execution of the script through the interpreter. (I am on Linux/Fedora, using meson 1.4.1, also tried meson 1.6.0, same) Am I doing something wrong? or is there a bug somewhere? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Maybe you need something like:
mentioned at the top of #10978 ? |
Beta Was this translation helpful? Give feedback.
-
Meson understands interpreter shebangs for scripts without the executable bit set, when going through find_program. More specifically, it's at the point where find_program finds a program that it parses this information. In your case, you use
But what does work is replacing: meson.override_find_program('sqlite2cpp', files('scripts/sqlite2cpp.py')) with: meson.override_find_program('sqlite2cpp', find_program('scripts/sqlite2cpp.py')) |
Beta Was this translation helpful? Give feedback.
Meson understands interpreter shebangs for scripts without the executable bit set, when going through find_program. More specifically, it's at the point where find_program finds …