From 2cba64b258da668042fb79941dbcbfa721122980 Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Mon, 12 Apr 2021 10:17:01 +0100 Subject: [PATCH] Fix missing env var expansion in pos file generation. Fixes https://gitlab.com/kicad/code/kicad/issues/8178 --- pcbnew/exporters/gen_footprints_placefile.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pcbnew/exporters/gen_footprints_placefile.cpp b/pcbnew/exporters/gen_footprints_placefile.cpp index d125744923..78e4bfbf43 100644 --- a/pcbnew/exporters/gen_footprints_placefile.cpp +++ b/pcbnew/exporters/gen_footprints_placefile.cpp @@ -339,7 +339,8 @@ bool DIALOG_GEN_FOOTPRINT_POSITION::CreateAsciiFiles() // Create output directory if it does not exist. // Also transform it in absolute path. // Bail if it fails - wxFileName outputDir = wxFileName::DirName( m_plotOpts.GetOutputDirectory() ); + wxString path = ExpandEnvVarSubstitutions( m_plotOpts.GetOutputDirectory(), &Prj() ); + wxFileName outputDir = wxFileName::DirName( path ); wxString boardFilename = m_parent->GetBoard()->GetFileName(); m_reporter = &m_messagesPanel->Reporter();