Browse Source

* Fix a link issue issues on Windows, probably related toircular gal<->common dependency.

The fix used in commit 1e4abac57 to build kicad binary does not work for pcb_calculator.
So I used a ugly but basic trick to force linking some undefined functions found in gal lib.
This issue could be msys2 specific.
pull/15/head
jean-pierre charras 6 years ago
parent
commit
0359ffb6c7
  1. 2
      kicad/CMakeLists.txt
  2. 5
      pcb_calculator/pcb_calculator_frame.cpp

2
kicad/CMakeLists.txt

@ -76,7 +76,7 @@ else()
target_link_libraries( kicad
common
gal
common
common #repeated due to a circular dependancy bewteen gal and common
${wxWidgets_LIBRARIES}
${GDI_PLUS_LIBRARIES}
)

5
pcb_calculator/pcb_calculator_frame.cpp

@ -24,6 +24,7 @@
#include <pcb_calculator.h>
#include <UnitSelector.h>
#include <bitmaps.h>
#include <geometry/shape_poly_set.h>
#define KEYWORD_FRAME_POSX wxT( "Pcb_calculator_Pos_x" )
@ -53,7 +54,6 @@ PCB_CALCULATOR_FRAME::PCB_CALCULATOR_FRAME( KIWAY* aKiway, wxWindow* aParent ) :
PCB_CALCULATOR_FRAME_BASE( aParent )
{
SetKiway( this, aKiway );
m_currTransLine = NULL;
m_currTransLineType = DEFAULT_TYPE;
m_currAttenuator = NULL;
@ -61,6 +61,9 @@ PCB_CALCULATOR_FRAME::PCB_CALCULATOR_FRAME( KIWAY* aKiway, wxWindow* aParent ) :
m_TWMode = TW_MASTER_CURRENT;
m_TWNested = false;
SHAPE_POLY_SET dummy; // A ugly trick to force the linker to include
//some methods in code and avoid link errors
// Populate transline list ordered like in dialog menu list
const static TRANSLINE_TYPE_ID tltype_list[8] =
{

Loading…
Cancel
Save