macOS: flatten symlinks from paths in GetExecutablePath
Fixes https://gitlab.com/kicad/code/kicad/-/issues/14430
This commit is contained in:
parent
d54e5b180b
commit
0422d2e70f
|
@ -27,6 +27,7 @@
|
||||||
#include <config.h>
|
#include <config.h>
|
||||||
#include <build_version.h>
|
#include <build_version.h>
|
||||||
#include <macros.h>
|
#include <macros.h>
|
||||||
|
#include <wx_filename.h>
|
||||||
|
|
||||||
// lowercase or pretty case depending on platform
|
// lowercase or pretty case depending on platform
|
||||||
#if defined( __WXMAC__ ) || defined( __WXMSW__ )
|
#if defined( __WXMAC__ ) || defined( __WXMSW__ )
|
||||||
|
@ -532,6 +533,7 @@ const wxString& PATHS::GetExecutablePath()
|
||||||
// bundle directory, e.g., /Applications/kicad.app/
|
// bundle directory, e.g., /Applications/kicad.app/
|
||||||
|
|
||||||
wxFileName fn( bin_dir );
|
wxFileName fn( bin_dir );
|
||||||
|
WX_FILENAME::ResolvePossibleSymlinks( fn );
|
||||||
|
|
||||||
if( fn.GetName() == wxT( "kicad" ) || fn.GetName() == wxT( "kicad-cli" ) )
|
if( fn.GetName() == wxT( "kicad" ) || fn.GetName() == wxT( "kicad-cli" ) )
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue