Fix rejection of default variables from exportpaths.cfg

Fix #7670
This commit is contained in:
Marek Roszko 2021-09-21 19:43:26 -04:00
parent 8ff20fd97b
commit a6fb687a0e
1 changed files with 6 additions and 3 deletions

View File

@ -459,7 +459,7 @@ bool S3D_RESOLVER::addPath( const SEARCH_PATH& aPath )
if( !path.DirExists() ) if( !path.DirExists() )
{ {
// suppress the message if the missing pathvar is the legacy KICAD6_3DMODEL_DIR variable // suppress the message if the missing pathvar is the legacy KICAD6_3DMODEL_DIR variable
if( aPath.m_Pathvar != "${KICAD6_3DMODEL_DIR}" && if( aPath.m_Pathvar != "${KIPRJMOD}" &&
aPath.m_Pathvar != "$(KICAD6_3DMODEL_DIR)" ) aPath.m_Pathvar != "$(KICAD6_3DMODEL_DIR)" )
{ {
wxString msg = _( "The given path does not exist" ); wxString msg = _( "The given path does not exist" );
@ -581,7 +581,10 @@ bool S3D_RESOLVER::readPathList( void )
continue; continue;
// never add on KICAD6_3DMODEL_DIR from a config file // never add on KICAD6_3DMODEL_DIR from a config file
if( !al.m_Alias.Cmp( "KICAD6_3DMODEL_DIR" ) ) if( !al.m_Alias.Cmp( "${KICAD6_3DMODEL_DIR}" ) )
continue;
if( !al.m_Alias.Cmp( "${KIPRJMOD}" ) )
continue; continue;
if( !getHollerith( cfgLine, idx, al.m_Pathvar ) ) if( !getHollerith( cfgLine, idx, al.m_Pathvar ) )