From 431675933a5ada7676a0d590a9fc98971cae3eaf Mon Sep 17 00:00:00 2001 From: Dick Hollenbeck Date: Tue, 3 Jun 2014 10:59:52 -0500 Subject: [PATCH] remove global g_UserLibDirBuffer which was a project specific global, and no longer used with FP_LIB_TABLE support. --- CMakeLists.txt | 1 + TODO.txt | 4 +++- common/common.cpp | 1 - cvpcb/CMakeLists.txt | 5 ----- cvpcb/cfg.cpp | 8 +------- cvpcb/cvframe.cpp | 1 - cvpcb/cvpcb_mainframe.h | 1 - ...fig.cpp => dialog_cvpcb_config.cpp.notused} | 0 ..._config.h => dialog_cvpcb_config.h.notused} | 0 ...cpp => dialog_cvpcb_config_fbp.cpp.notused} | 0 ...fbp => dialog_cvpcb_config_fbp.fbp.notused} | 0 eeschema/dialogs/dialog_eeschema_config.cpp | 3 +-- include/common.h | 3 --- pcbnew/pcbnew_config.cpp | 2 -- template/kicad.pro | 18 ------------------ 15 files changed, 6 insertions(+), 41 deletions(-) rename cvpcb/dialogs/{dialog_cvpcb_config.cpp => dialog_cvpcb_config.cpp.notused} (100%) rename cvpcb/dialogs/{dialog_cvpcb_config.h => dialog_cvpcb_config.h.notused} (100%) rename cvpcb/dialogs/{dialog_cvpcb_config_fbp.cpp => dialog_cvpcb_config_fbp.cpp.notused} (100%) rename cvpcb/dialogs/{dialog_cvpcb_config_fbp.fbp => dialog_cvpcb_config_fbp.fbp.notused} (100%) diff --git a/CMakeLists.txt b/CMakeLists.txt index 575ddf773d..1cef80fdb2 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -212,6 +212,7 @@ if( CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang" ) # Defeat ELF's ability to use the GOT to replace locally implemented functions # with ones from another module. + # https://bugs.launchpad.net/kicad/+bug/1322354 set( CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${TO_LINKER},-Bsymbolic" ) set( CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} ${TO_LINKER},-Bsymbolic" ) endif() diff --git a/TODO.txt b/TODO.txt index 690c07e01c..671d0b0ee7 100644 --- a/TODO.txt +++ b/TODO.txt @@ -69,4 +69,6 @@ Dick's Final TODO List: https://blueprints.launchpad.net/kicad/+spec/modular-kicad Issues as a result of minimal testing: - Kicad project manager will crash when requesting help file. + If eeschema launched from C++ project manager does not find all libraries, + then the dialog showing the names of missing libraries is not visible, + probably because the wxFrame parent is not yet visible. diff --git a/common/common.cpp b/common/common.cpp index f52e6469b9..40b2df4ee0 100644 --- a/common/common.cpp +++ b/common/common.cpp @@ -59,7 +59,6 @@ */ bool g_ShowPageLimits = true; -wxString g_UserLibDirBuffer; EDA_UNITS_T g_UserUnit; EDA_COLOR_T g_GhostColor; diff --git a/cvpcb/CMakeLists.txt b/cvpcb/CMakeLists.txt index 626c41867b..521e21a5c8 100644 --- a/cvpcb/CMakeLists.txt +++ b/cvpcb/CMakeLists.txt @@ -21,11 +21,6 @@ include_directories( set( CVPCB_DIALOGS - - # These 2 still use search paths, which don't exist in footprint land. -# dialogs/dialog_cvpcb_config.cpp -# dialogs/dialog_cvpcb_config_fbp.cpp - dialogs/dialog_display_options.cpp dialogs/dialog_display_options_base.cpp ../pcbnew/dialogs/dialog_fp_lib_table.cpp diff --git a/cvpcb/cfg.cpp b/cvpcb/cfg.cpp index 1764a7f871..b0b1778ed2 100644 --- a/cvpcb/cfg.cpp +++ b/cvpcb/cfg.cpp @@ -49,18 +49,12 @@ PARAM_CFG_ARRAY& CVPCB_MAINFRAME::GetProjectFileParameters() m_projectFileParams.push_back( new PARAM_CFG_BASE( GROUP_PCB_LIBS, PARAM_COMMAND_ERASE ) ); - m_projectFileParams.push_back( new PARAM_CFG_LIBNAME_LIST( - wxT( "LibName" ), &m_ModuleLibNames, GROUP_PCB_LIBS ) ); - m_projectFileParams.push_back( new PARAM_CFG_LIBNAME_LIST( wxT( "EquName" ), &m_AliasLibNames, GROUP_CVP_EQU ) ); m_projectFileParams.push_back( new PARAM_CFG_WXSTRING( wxT( "NetIExt" ), &m_NetlistFileExtension ) ); - m_projectFileParams.push_back( new PARAM_CFG_FILENAME( - wxT( "LibDir" ), &m_UserLibraryPath, GROUP_PCB_LIBS ) ); - return m_projectFileParams; } @@ -81,7 +75,7 @@ void CVPCB_MAINFRAME::LoadProjectFile( const wxString& aFileName ) if( m_NetlistFileExtension.IsEmpty() ) m_NetlistFileExtension = wxT( "net" ); - // Force it to be loaded on demand. + // Force FP_LIB_TABLE to be loaded on demand. prj.ElemClear( PROJECT::ELEM_FPTBL ); } diff --git a/cvpcb/cvframe.cpp b/cvpcb/cvframe.cpp index 7079e40287..88b3aa688c 100644 --- a/cvpcb/cvframe.cpp +++ b/cvpcb/cvframe.cpp @@ -45,7 +45,6 @@ #include #include #include -#include #include #include diff --git a/cvpcb/cvpcb_mainframe.h b/cvpcb/cvpcb_mainframe.h index 7b136746a9..359c7e20b9 100644 --- a/cvpcb/cvpcb_mainframe.h +++ b/cvpcb/cvpcb_mainframe.h @@ -67,7 +67,6 @@ public: wxFileName m_NetlistFileName; wxArrayString m_ModuleLibNames; wxArrayString m_AliasLibNames; - wxString m_UserLibraryPath; wxString m_NetlistFileExtension; wxString m_DocModulesFileName; FOOTPRINT_LIST m_footprints; diff --git a/cvpcb/dialogs/dialog_cvpcb_config.cpp b/cvpcb/dialogs/dialog_cvpcb_config.cpp.notused similarity index 100% rename from cvpcb/dialogs/dialog_cvpcb_config.cpp rename to cvpcb/dialogs/dialog_cvpcb_config.cpp.notused diff --git a/cvpcb/dialogs/dialog_cvpcb_config.h b/cvpcb/dialogs/dialog_cvpcb_config.h.notused similarity index 100% rename from cvpcb/dialogs/dialog_cvpcb_config.h rename to cvpcb/dialogs/dialog_cvpcb_config.h.notused diff --git a/cvpcb/dialogs/dialog_cvpcb_config_fbp.cpp b/cvpcb/dialogs/dialog_cvpcb_config_fbp.cpp.notused similarity index 100% rename from cvpcb/dialogs/dialog_cvpcb_config_fbp.cpp rename to cvpcb/dialogs/dialog_cvpcb_config_fbp.cpp.notused diff --git a/cvpcb/dialogs/dialog_cvpcb_config_fbp.fbp b/cvpcb/dialogs/dialog_cvpcb_config_fbp.fbp.notused similarity index 100% rename from cvpcb/dialogs/dialog_cvpcb_config_fbp.fbp rename to cvpcb/dialogs/dialog_cvpcb_config_fbp.fbp.notused diff --git a/eeschema/dialogs/dialog_eeschema_config.cpp b/eeschema/dialogs/dialog_eeschema_config.cpp index f4f01e4043..61fa686e63 100644 --- a/eeschema/dialogs/dialog_eeschema_config.cpp +++ b/eeschema/dialogs/dialog_eeschema_config.cpp @@ -57,8 +57,7 @@ private: SCH_EDIT_FRAME* m_Parent; bool m_LibListChanged; bool m_LibPathChanged; - wxString m_UserLibDirBufferImg; // Copy of original g_UserLibDirBuffer - + wxString m_UserLibDirBufferImg; // event handlers, overiding the fbp handlers void Init(); diff --git a/include/common.h b/include/common.h index f7d222adc6..304fdf44a0 100644 --- a/include/common.h +++ b/include/common.h @@ -384,9 +384,6 @@ private: void setMargins(); }; -/// Default user lib path can be left void, if the standard lib path is used -extern wxString g_UserLibDirBuffer; - extern bool g_ShowPageLimits; ///< true to display the page limits extern EDA_UNITS_T g_UserUnit; ///< display units diff --git a/pcbnew/pcbnew_config.cpp b/pcbnew/pcbnew_config.cpp index 00452262ce..45ee46192e 100644 --- a/pcbnew/pcbnew_config.cpp +++ b/pcbnew/pcbnew_config.cpp @@ -301,8 +301,6 @@ PARAM_CFG_ARRAY PCB_EDIT_FRAME::GetProjectFileParameters() pca.push_back( new PARAM_CFG_FILENAME( wxT( "PageLayoutDescrFile" ), &BASE_SCREEN::m_PageLayoutDescrFileName ) ); - pca.push_back( new PARAM_CFG_FILENAME( wxT( "LibDir" ), &g_UserLibDirBuffer, GROUP_PCB_LIBS ) ); - pca.push_back( new PARAM_CFG_FILENAME( wxT( "LastNetListRead" ), &m_lastNetListRead ) ); pca.push_back( new PARAM_CFG_BOOL( wxT( "UseCmpFile" ), &m_useCmpFileForFpNames, true ) ); diff --git a/template/kicad.pro b/template/kicad.pro index 80e5d98dbd..f5795a5b16 100644 --- a/template/kicad.pro +++ b/template/kicad.pro @@ -68,21 +68,3 @@ SolderMaskMinWidth=0.000000000000 DrawSegmentWidth=0.200000000000 BoardOutlineThickness=0.100000000000 ModuleOutlineThickness=0.150000000000 -[pcbnew/libraries] -LibDir= -LibName1=sockets -LibName2=connect -LibName3=discret -LibName4=pin_array -LibName5=divers -LibName6=smd_capacitors -LibName7=smd_resistors -LibName8=smd_crystal&oscillator -LibName9=smd_dil -LibName10=smd_transistors -LibName11=libcms -LibName12=display -LibName13=led -LibName14=dip_sockets -LibName15=pga_sockets -LibName16=valves