Commit Graph

628 Commits

Author SHA1 Message Date
Marek Roszko 7dfac51fe1 Silence cmake warning about lowercase string 2023-09-01 22:09:49 -04:00
Marek Roszko 87513b4a04 Change the sentry dsn to be build time defined
We ultimately don't want people running personal builds to turn on sentry and start sending us crash logs we can't decipher
2023-08-30 22:17:38 -04:00
Marek Roszko 4cb60bac1b guard out the currently broken wx version check 2023-08-23 22:06:11 -04:00
Seth Hillbrand f62775de40 Fix missing endif() 2023-08-23 15:23:04 -07:00
Seth Hillbrand db8e15ce88 Require wxWidgets 3.2
Removes old defines and work arounds for earlier wx versions and adds a
CMake requirement to use at least 3.2 (or the minimum matching wxPython
version)
2023-08-23 22:02:56 +00:00
Mark Roszko 4b6116cb30 Move opencascade min to 7.5.0 2023-08-19 02:26:45 +00:00
Johannes Maibaum 9ae44e3998 Add KICAD_BUILD_{NIGHTLY_,}FLATPAK CMake options 2023-06-22 18:04:32 +00:00
Alex d5edde799c Enable support for KICAD_SANITIZE_ADDRESS CMake flag on MSVC. 2023-06-10 02:09:09 +03:00
Marek Roszko 726b137fed Fix libcontext arm64 build and purge winfiber
The winfiber implementation ran into memory leak issues as it didnt exit the stack jumps correctly
and lets not mislead anyone by keeping it
2023-04-10 18:07:35 -04:00
Seth Hillbrand 5fcc1135a8 Revert "Modernizes search for Cairo, Fontconfig, Freetype, HarfBuzz and Pixman"
This reverts commit 9efd24a69d.

Breaks MSW builds, so this is a non-starter for now
2023-04-07 10:12:43 -07:00
Seth Hillbrand 2cd854af14 Move Spacemouse to advanced config
The spacemouse driver, particularly on Mac, is extremely unstable and
causes crashes even when not being used.  This places the interface
behind an advanced config flag to ensure that users can affirmatively
opt-in to the potential for crashes
2023-04-07 10:08:43 -07:00
Nimish Telang 9efd24a69d Modernizes search for Cairo, Fontconfig, Freetype, HarfBuzz and Pixman 2023-04-07 16:15:53 +00:00
Marek Roszko 23476683f6 Try and patch site patch detection
Use Steven Falco's suggested fix from fedora, it appears to behave fine on Windows
2023-04-01 13:42:41 -04:00
Nimish Telang f7bf3011fb Use bundled Find{CURL,ZLIB}.cmake 2023-03-24 12:54:52 +00:00
Ian McInerney 016c958021 Always build spice simulator support
The simulator has advanced considerably, and it is seeing lots of active
development, so make it a required part of KiCad. Additionally, the
build without the simulator has actually been broken for a while, so no
one clearly is building without ngspice right now.
2023-03-20 16:54:32 +00:00
Ian McInerney 8f2a453d07 Remove explicit Boost::system dependency from our cmake
Boost::system is only used transitively by the other Boost libraries, so
their CMake will include it when it is needed.
2023-03-11 13:29:58 +00:00
Ian McInerney e20b33cb66 Fix boost dependencies
* Add Boost::locale explicetly to the CMake since nanoodbc requires it
* Don't let nanoodbc add all Boost libraries to the link line, since it
  is used in common, and it was pulling the unit test framework into
  common then.
2023-03-11 13:29:45 +00:00
jean-pierre charras 4737e3b8a7 QA tests: link unit_test_framework library only with QA tests.
It fixes a link issue on W10/msys2 when building some .exe files
not related to QA tests, but have the unit_test_framework library linked
without this change..
2023-03-11 10:28:06 +01:00
Marek Roszko b4bb1f4b46 update vcpkg to get the arm64 compatible packages 2023-03-10 21:23:09 -05:00
Ian McInerney a6ebd60c3b CMake: Modernize Boost import to use imported targets 2023-03-10 16:38:35 +00:00
Mike Williams 671f555bc8 CMake: add flag to turn off spice QA tests (tests default to on) 2023-03-07 12:05:01 -05:00
Jon Evans 819b767635 Bump to requiring wxWidgets 3.2.0
By the time 8.0 is out, we will not be supporting any platforms
on wxWidgets older than 3.2.0
2023-03-05 21:07:57 -05:00
Ian McInerney 6803976ab3 Add flags to let GCC/Clang auto initialize trivial variables
GCC 12 and Clang include a flag allowing initialization of trivial
variables with a known pattern or with 0. Enable zero init by default in
everything but debug mode, and pattern init for debug mode. Also provide
an option to completely disable this, giving unitialized variables.

ADDED: Add compile flag -ftrivial-auto-var-init to build
2023-02-23 01:39:59 +00:00
aris-kimi 22bca5c2a0 Disable link maps by default and fix compile issue with lld linker
The link maps were actually disabled by default before
912f1d5cec, and required KICAD_MAKE_LINK_MAPS
to be provided to enable them. So switch back to disabling them by
default.

Also, The lld linker is unable to accept a single dash cref option, while
ld and gold can. Instead, use the double dash version that is supported
by all three.

xref: https://github.com/llvm/llvm-project/issues/60932

Co-authored-by: aris-kimi <aris_kimi@hotmail.com>
Co-authored-by: Ian McInerney <ian.s.mcinerney@ieee.org>
2023-02-22 23:18:36 +00:00
Jon Evans ad838e3d73 Revert part of bcb93e9a that broke Windows 2023-02-21 22:45:54 -05:00
Ian McInerney be19e967dc Remove WX_COMPATIBILITY flag
Some classes had been originally designed to be usable separate from wx,
but over time our uses of the classes have become entertwined with wx
features (e.g. colors), and various changes have also leaked wx into the
classes unguarded. So just remove the option to hide wx in those classes
to simplify the code.
2023-02-22 01:44:06 +00:00
Ian McInerney 301777f3c9 Cleanup condition for Linux-only CMake configs 2023-02-22 01:44:06 +00:00
Ian McInerney 912f1d5cec Modernize setting link map linker flags 2023-02-22 01:44:06 +00:00
Ian McInerney bcb93e9aa7 Modernize setting of compiler definitions in CMake
add_compile_definitions was added in 3.12, and our minimum is now
greater than that.
2023-02-22 01:44:06 +00:00
Christoph Moench-Tegeder 46a59aa2c3 CMakeLists.txt: do not use -ffloat-store on clang
According to it's User Manual, clang does not know about -ffloat-store.
This is corrobated by the FreeBSD i386 build (using LLVM 13 and 15,
depending on the base system version) failing early with an error
message complaining about this parameter being unknown.

See
https://pkg-status.freebsd.org/beefy17/data/main-i386-default/pb27279cba1ca_sed03776ca7/logs/kicad-7.0.0,2.log
for an example of the failure, and
https://clang.llvm.org/docs/UsersManual.html#controlling-floating-point-behavior
for the available floating point options on clang.
2023-02-21 20:45:27 +01:00
Ian McInerney 9dc357486f Cleanup organization of build options
Organize the build options into various categories to make finding them
in the main file easier.

Other changes:
* Removed KICAD_NETLIST_QA
* Renamed BUILD_SMALL_DEBUG_FILES to KICAD_BUILD_SMALL_DEBUG_FILES
2023-02-15 13:48:41 +00:00
Ian McInerney e3858294d4 Fix option description for ASAN and TSAN options 2023-02-15 13:48:41 +00:00
Marek Roszko 4665823089 Turn on and fix MSVC compliance mode issues
We want /permissive- to enable debug performance improvements in MSVC 17.5+.
This flag is also default under C++20 so we'll have to deal with these compile issues anyway at some point in the future.

In particular, MSVC becomes pedantic about ternary types.
See https://learn.microsoft.com/en-us/cpp/build/reference/permissive-standards-conformance?view=msvc-170#ambiguous-conditional-operator-arguments

MSFT cites https://cplusplus.github.io/CWG/issues/1805.html
2023-02-12 16:30:37 -05:00
Marek Roszko c4204624a9 Turn on the new crashpad wer module 2023-01-28 00:04:26 -05:00
Marek Roszko 8ab9934143 Use our own cmake module path variable to avoid conflicting with the main ones listy functional 2023-01-03 19:18:16 -05:00
Mark Roszko 7d1f25fbf1 Remove CPack configuration which is not used on any platform 2023-01-03 16:02:19 +00:00
Marek Roszko 020f8f61db Let's try fixing the doxygen-python again 2022-12-23 23:11:04 -05:00
Seth Hillbrand ebea4869a2 Set CMake policy for generated DEPFILEs
Thanks to @gyrosgeier for finding this solution
2022-12-21 12:08:32 -08:00
Seth Hillbrand 278ea3379f Bump CMake requirement to 3.21 2022-12-16 10:59:31 -08:00
Adam Wolf 98775afcba Support Apple Silicon on macOS
As part of supporting Apple Silicon, we've got to upgrade our embedded
Python to a version that comes with an Apple Silicon build. Python 3.9
suffices. This means we ignore python3.9 while fixing up bundles.

Apple requires all code to be signed on Apple Silicon. We've added signing
to the build. This has to be run after anything that adds to or modifies
the installed files. As of Cmake 3.14 (CMP0082), the install rules are run
in the order declared, so we are able to do this just by adding the
signing subdirectory last in the main CMakeLists.txt. By default, the
build will be signed "ad hoc", which does not require a developer to
create keys or get keys from Apple. We added some CMake variables to
control signing, KICAD_OSX_CODESIGN and KICAD_OSX_SIGNING_*.

In order to better support development, we've added some necessary cleanup
steps to KiCad that were performed externally in the release and nightly
build process, like removing any .pyc files and extra Python symlinks
erroneously introduced by fixup_bundle. We also adjusted "refix_rpaths" to
be more accurate. We should not need "wrangle_bundle" when building and
installing a local development copy of KiCad.
2022-12-09 23:48:31 +00:00
Seth Hillbrand 203f5538aa Correctly place static library spec 2022-11-22 05:45:26 -08:00
Seth Hillbrand 3b48f88bec Specify behavior for shared lib visibility 2022-11-22 05:43:53 -08:00
Seth Hillbrand 67e12d4ff6 Build QA without `NDEBUG` to get wxASSERTs
Also include minimum debug information to get basic backtrace while
keeping artifacts reasonable
2022-10-04 19:54:58 -07:00
Mark Roszko fb8a4c10f7 Shove kicad2step into pcbnew itself with a new cli 2022-10-04 01:53:37 +00:00
Seth Hillbrand 2a9b76c5ff Move warning setting to Warnings.cmake 2022-08-24 14:21:06 -07:00
Marek Roszko fc99b3ba95 Don't link gdiplus everywhere anymore
Tested on msys2 which is the only place it would have been buggy
CMake seems to share the gdiplus linkage with the other dependencies automatically now
2022-08-23 23:51:35 -04:00
Marek Roszko 2fd0103a09 Remove legacy cmake if statement 2022-08-23 22:18:00 -04:00
Seth Hillbrand 5475d46bc5 Silence GCC's extra warnings
GCC warned about ignored attributes that we use for clang and MSVC.
Removing the ignored attributes check keeps this quiet
2022-08-23 10:48:45 -07:00
Mark Roszko 952669e747 Bump swig minimum to 4.0 2022-08-22 15:22:26 +00:00
Seth Hillbrand 5ed7e28252 Remove KICAD_OCC build option
We don't really support builds without OCC these days.  Removing to
clear up build flags and settings
2022-08-18 17:06:29 -07:00