Opencascade: fix min version: OCE=0.18, OCC=6.9.0

Fix also a few minor Coverity warnings.
This commit is contained in:
jean-pierre charras 2020-04-16 09:27:22 +02:00
parent 8dcbd1e6d2
commit 25d7c0cae2
4 changed files with 14 additions and 6 deletions

View File

@ -682,7 +682,7 @@ endif()
if( KICAD_USE_OCE )
set( OCC_LIBRARIES TKBinXCAF TKPCAF TKSTEP TKXDESTEP TKIGES TKXDEIGES )
find_package( OCE 0.16 REQUIRED ${OCC_LIBRARIES} )
find_package( OCE 0.18 REQUIRED ${OCC_LIBRARIES} )
elseif( KICAD_USE_OCC )
find_package(OpenCASCADE)
@ -691,10 +691,10 @@ elseif( KICAD_USE_OCC )
" KICAD_USE_OCC=True but OpenCASCADE was not found!\n"
"================================================================\n")
endif()
if( OCC_VERSION_STRING VERSION_LESS 6.8.0 )
if( OCC_VERSION_STRING VERSION_LESS 6.9.0 )
MESSAGE( FATAL_ERROR "================================================================\n"
"OpenCASCADE version ${OCC_VERSION_STRING} was found.\n"
" KiCad requires a minimum version of 6.8.0\n"
" KiCad requires a minimum version of 6.9.0\n"
"================================================================\n")
endif()
include_directories( SYSTEM ${OCC_INCLUDE_DIR} )

View File

@ -614,6 +614,11 @@ void SIM_PLOT_FRAME::addPlot( const wxString& aName, SIM_PLOT_TYPE aType, const
if( !plotPanel || plotPanel->GetType() != simType )
plotPanel = dynamic_cast<SIM_PLOT_PANEL*>( NewPlotPanel( simType ) );
wxASSERT( plotPanel );
if( !plotPanel ) // Something is wrong
return;
TRACE_DESC descriptor( *m_exporter, aName, aType, aParam );
bool updated = false;

View File

@ -1015,6 +1015,7 @@ double SHAPE_LINE_CHAIN::Area() const
SHAPE_LINE_CHAIN::POINT_INSIDE_TRACKER::POINT_INSIDE_TRACKER( const VECTOR2I& aPoint ) :
m_point( aPoint ),
m_finished( false ),
m_state( 0 ),
m_count( 0 )
{

View File

@ -41,6 +41,8 @@ class KICAD2STEP_FRAME;
class KICAD2MCAD_APP : public wxApp
{
public:
KICAD2MCAD_APP() : wxApp(), m_frame( nullptr ), m_Panel( nullptr )
{}
virtual bool OnInit() override;
virtual int OnRun() override;
virtual void OnInitCmdLine(wxCmdLineParser& parser) override;