Support $MAIN_DIR for the poor C++ users
This commit is contained in:
parent
26bc853d92
commit
ace7910a44
|
|
@ -537,6 +537,11 @@ read_args() {
|
|||
}
|
||||
#endif
|
||||
|
||||
if (_dtool_name.empty())
|
||||
if (!_binary_name.empty()) {
|
||||
set_environment_variable("MAIN_DIR", Filename(_binary_name).get_dirname());
|
||||
}
|
||||
|
||||
if (_dtool_name.empty()) {
|
||||
_dtool_name = _binary_name;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue