MSVC: don't set python home when running from build dir
This allows you to specify your python home via the environment and get a working python setup when running in-place.
This commit is contained in:
parent
bbe315bcb8
commit
1ab17dd2e7
|
@ -179,7 +179,10 @@ bool pcbnewInitPythonScripting( const char* aStockScriptingPath, const char* aUs
|
|||
pyHome.Normalize();
|
||||
|
||||
// MUST be called before Py_Initialize so it will to create valid default lib paths
|
||||
Py_SetPythonHome( pyHome.GetFullPath().c_str() );
|
||||
if( !wxGetEnv( wxT( "KICAD_RUN_FROM_BUILD_DIR" ), nullptr ) )
|
||||
{
|
||||
Py_SetPythonHome( pyHome.GetFullPath().c_str() );
|
||||
}
|
||||
#endif
|
||||
|
||||
Py_Initialize();
|
||||
|
|
Loading…
Reference in New Issue