From bdc41f7365b404ae24f961e3359dec9f08ad5696 Mon Sep 17 00:00:00 2001 From: Marek Roszko Date: Wed, 18 Nov 2020 19:22:00 -0500 Subject: [PATCH] Don't search hardcoded (and never valid on non-english) Windows paths --- common/gestfich.cpp | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/common/gestfich.cpp b/common/gestfich.cpp index 929b8d447a..7a69048afe 100644 --- a/common/gestfich.cpp +++ b/common/gestfich.cpp @@ -121,14 +121,15 @@ wxString FindKicadFile( const wxString& shortname ) return fullFileName; } +#if defined( __WINDOWS__ ) + // kicad can be installed highly portably on Windows, anywhere and concurrently + // either the "kicad file" is immediately adjacent to the exe or it's not a valid install + return shortname; +#endif + // Path list for KiCad binary files const static wxChar* possibilities[] = { -#if defined( __WINDOWS__ ) - wxT( "c:/kicad/bin/" ), - wxT( "d:/kicad/bin/" ), - wxT( "c:/Program Files/kicad/bin/" ), - wxT( "d:/Program Files/kicad/bin/" ), -#elif defined( __WXMAC__ ) +#if defined( __WXMAC__ ) // all internal paths are relative to main bundle kicad.app wxT( "Contents/Applications/pcbnew.app/Contents/MacOS/" ), wxT( "Contents/Applications/eeschema.app/Contents/MacOS/" ),