Install translations into macOS bundle.

This commit is contained in:
Adam Wolf 2021-02-20 17:54:40 -06:00 committed by Ian McInerney
parent b484c0787b
commit 90cb82b32d
2 changed files with 15 additions and 0 deletions

View File

@ -766,6 +766,18 @@ void PGM_BASE::SetLanguagePath()
wxLogTrace( traceLocale, "Adding locale lookup path: " + fn.GetPath() );
wxLocale::AddCatalogLookupPathPrefix( fn.GetPath() );
}
// Append path for macOS install
fn.RemoveLastDir();
fn.RemoveLastDir();
fn.RemoveLastDir();
fn.AppendDir( "internat" );
if( fn.IsDirReadable() )
{
wxLogTrace( traceLocale, "Adding locale lookup path: " + fn.GetPath() );
wxLocale::AddCatalogLookupPathPrefix( fn.GetPath() );
}
}
if( wxGetEnv( wxT( "KICAD_RUN_FROM_BUILD_DIR" ), nullptr ) )

View File

@ -1,6 +1,9 @@
if( UNIX AND KICAD_I18N_UNIX_STRICT_PATH )
set( KICAD_I18N_PATH ${CMAKE_INSTALL_PREFIX}/share/locale
CACHE PATH "Location of KiCad i18n files." )
elseif( APPLE )
set( KICAD_I18N_PATH ${KICAD_DATA}/internat
CACHE PATH "Location of KiCad i18n files." )
else()
# Default Unix inconvenient locale lookup path
set( KICAD_I18N_PATH share/kicad/internat