Replies: 1 comment
-
Since 0.57.0, custom_target() supports the Running the /usr/bin/env program using run_command() at configure time using a modified env did nothing -- Unix doesn't allow you to define environment variables in a parent process by forking and executing a command, and even if it did, the /usr/bin/env program would just print a list of currently known environment variables to stdout. Before meson 0.57.0 you could have done:
That would make the custom_target run the env command, which would fork and modify the environment to set SRCPATH, and, since a command is provided, run that command instead of printing all known variables by default. As your overall objective is to run perl with a modified env at build time, this would work. (But I don't understand the purpose of setting ... As a matter of curiosity:
Why not fix the perl script? Scripts can be fixed. It doesn't take the ouptut file as an environment variable |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I am trying to generate some header/c files using a custom Perl script using curtom_target
here is the code snippet
The autogen script creates the files in the path where SRCPATH environment pointing to . that is how the perl script is written
I am unable make the meson snippet work for some reason. Could some one throw some light here ?
Beta Was this translation helpful? Give feedback.
All reactions