kicad-developers team mailing list archive
-
kicad-developers team
-
Mailing list archive
-
Message #32232
Re: Simulator towards 5.0
I sent the wrong patch before attached the correct now. Silently
compiling something else then what was expected is much much worse than
failing.
I do not see why anyone is even objecting to this? Where is the logic at
having a default build that does not correspond to any of the official
packages?!
If i build a software I expect to get the same as the official version,
unless i specify some custom options, currently I am not even getting
the same version as the official by reading the compilation steps in the
docs currently.
The error message for spice even details how to get the correct spice
library and with this even tells how to disable it if you wish to build
without it.
-Kristoffer
On 12/05/2017 06:31 PM, Simon Richter wrote:
Hi,
On 05.12.2017 17:30, Maciej Sumiński wrote:
When you build a program, do you always go through its build manual or
do you start with 'cmake .. && make'? I think there is no point
enforcing an optional dependency. Another good solution would be to
autodetect libngspice and enable the simulator if it is available.
With my packaging hat on: please don't. It is really annoying to find
out that a build dependency changed when users complain about entire
features going missing.
Simon
_______________________________________________
Mailing list: https://launchpad.net/~kicad-developers
Post to : kicad-developers@xxxxxxxxxxxxxxxxxxx
Unsubscribe : https://launchpad.net/~kicad-developers
More help : https://help.launchpad.net/ListHelp
>From c993c2df02b1402099cc2999c75f554f860da91a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Kristoffer=20=C3=96dmark?= <kristoffer.odmark90@xxxxxxxxx>
Date: Tue, 5 Dec 2017 14:33:10 +0100
Subject: [PATCH] Changed default compile-flags to match released packages This
makes it easier to build like in the the official packages added a message on
how to compile without spice support if needed
---
CMakeLists.txt | 28 +++++++++++++++++-----------
Documentation/development/compiling.md | 18 +++++++-----------
2 files changed, 24 insertions(+), 22 deletions(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index c70a34237..90dd8f99d 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -54,24 +54,24 @@ option( USE_WX_OVERLAY
"Use wxOverlay: Always ON for MAC (default OFF). Warning, this is experimental" )
option( KICAD_SCRIPTING
- "Build the Python scripting support inside KiCad binaries (default OFF)."
- )
+ "Build the Python scripting support inside KiCad binaries (default ON)."
+ ON )
option( KICAD_SCRIPTING_MODULES
"Build native portion of the pcbnew Python module: _pcbnew.{pyd,so} for OS command line use of Python."
- )
+ ON )
option( KICAD_SCRIPTING_WXPYTHON
- "Build wxPython implementation for wx interface building in Python and py.shell (default OFF)."
- )
+ "Build wxPython implementation for wx interface building in Python and py.shell (default ON)."
+ ON )
option( KICAD_SCRIPTING_ACTION_MENU
- "Build a tools menu with registred python plugins: actions plugins (default OFF)."
- )
+ "Build a tools menu with registred python plugins: actions plugins (default ON)."
+ ON )
option( KICAD_USE_OCE
- "Build tools and plugins related to OpenCascade Community Edition (default OFF)"
- )
+ "Build tools and plugins related to OpenCascade Community Edition (default ON)"
+ ON )
option( KICAD_INSTALL_DEMOS
"Install kicad demos and examples (default ON)"
@@ -97,7 +97,7 @@ endif()
option( BUILD_GITHUB_PLUGIN "Build the GITHUB_PLUGIN for pcbnew." ON )
-option( KICAD_SPICE "Build Kicad with internal Spice simulator." OFF )
+option( KICAD_SPICE "Build Kicad with internal Spice simulator." ON )
# Global setting: exports are explicit
set( CMAKE_CXX_VISIBILITY_PRESET "hidden" )
@@ -554,7 +554,13 @@ endif()
# Find ngspice library, required for integrated circuit simulator
if( KICAD_SPICE )
- find_package( ngspice REQUIRED )
+ find_package( ngspice )
+
+ if( NOT NGSPICE_FOUND )
+ message( FATAL_ERROR "Required ngspice library not found, to \
+ compile kicad without integrated circuit simulator, run cmake with \
+ -DKICAD_SPICE=OFF" )
+ endif()
endif()
# Find OpenCascade Community Edition, required for STEP plugin and tools
diff --git a/Documentation/development/compiling.md b/Documentation/development/compiling.md
index 43d388235..2646eb5e6 100644
--- a/Documentation/development/compiling.md
+++ b/Documentation/development/compiling.md
@@ -132,17 +132,17 @@ on macOS. This is enabled on macOS by default and disabled on all other platfor
## Scripting Support ## {#scripting_opt}
The KICAD_SCRIPTING option is used to enable building the Python scripting support into Pcbnew.
-This options is disabled by default.
+This options is enabled by default.
## Scripting Module Support ## {#scripting_mod_opt}
The KICAD_SCRIPTING_MODULES option is used to enable building and installing the Python modules
-supplied by KiCad. This option is disabled by default.
+supplied by KiCad. This option is enabled by default.
## wxPython Scripting Support ## {#wxpython_opt}
The KICAD_SCRIPTING_WXPYTHON option is used to enable building the wxPython interface into
-Pcbnew including the wxPython console. This option is disabled by default.
+Pcbnew including the wxPython console. This option is enabled by default.
## GitHub Plugin ## {#github_opt}
@@ -153,14 +153,14 @@ enabled by default.
The KICAD_SPICE option is used to control if the Spice simulator interface for Eeschema is built. When
this option is enabled, it requires [ngspice][] to be available as a shared library. This option is
-disabled by default.
+enabled by default.
## STEP/IGES support for the 3D viewer ## {#oce_opt}
The KICAD_USE_OCE is used for the 3D viewer plugin to support STEP and IGES 3D models. Build tools
and plugins related to OpenCascade Community Edition (OCE) are enabled with this option. When
enabled it requires [OCE][] to be available, and the location of the installed OCE library to be
-passed via the OCE_DIR flag. This option is disabled by default.
+passed via the OCE_DIR flag. This option is enabled by default.
## Demos and Examples ## {#demo_install_opt}
@@ -172,7 +172,7 @@ $PREFIX/share/kicad/demos by default.
## Python Scripting Action Menu Support ## {#python_action_menu_opt}
The KICAD_SCRIPTING_ACTION_MENU option allows Python scripts to be added directly to the Pcbnew
-menu. This option is disabled by default. Please note that this option is highly experimental
+menu. This option is enabled by default. Please note that this option is highly experimental
and can cause Pcbnew to crash if Python scripts create an invalid object state within Pcbnew.
## Setting the Build Version and Repository Name ## {#build_version_opt}
@@ -229,11 +229,7 @@ To perform a full build on Linux, run the following commands:
mkdir -p build/release
mkdir build/debug # Optional for debug build.
cd build/release
- cmake -DCMAKE_BUILD_TYPE=Release \
- -DKICAD_SCRIPTING=ON \
- -DKICAD_SCRIPTING_MODULES=ON \
- -DKICAD_SCRIPTING_WXPYTHON=ON \
- ../../
+ cmake -DCMAKE_BUILD_TYPE=Release ../../
make
sudo make install
--
2.15.1
Follow ups
References
-
Simulator towards 5.0
From: Kristoffer Ödmark, 2017-12-04
-
Re: Simulator towards 5.0
From: Tomasz Wlostowski, 2017-12-04
-
Re: Simulator towards 5.0
From: kristoffer Ödmark, 2017-12-04
-
Re: Simulator towards 5.0
From: Nick Østergaard, 2017-12-04
-
Re: Simulator towards 5.0
From: Kristoffer Ödmark, 2017-12-05
-
Re: Simulator towards 5.0
From: Nick Østergaard, 2017-12-05
-
Re: Simulator towards 5.0
From: Wayne Stambaugh, 2017-12-05
-
Re: Simulator towards 5.0
From: Nick Østergaard, 2017-12-05
-
Re: Simulator towards 5.0
From: Maciej Sumiński, 2017-12-05
-
Re: Simulator towards 5.0
From: Nick Østergaard, 2017-12-05
-
Re: Simulator towards 5.0
From: Maciej Sumiński, 2017-12-05
-
Re: Simulator towards 5.0
From: Simon Richter, 2017-12-05