Commit Graph

613 Commits

Author SHA1 Message Date
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
Mark Roszko ca3b3572ca Get rid of the broken scripts install 2022-07-22 14:22:39 +00:00
Marek Roszko a9942a62ee CMakeModules -> cmake 2022-07-21 20:32:25 -04:00
Marek Roszko 47fe8ff8eb bitmaps and template are resources. 2022-07-21 20:14:10 -04:00
Marek Roszko 98d9911c7d Move /Documentation to /doxygen 2022-07-10 15:10:04 -04:00
Mike Williams eaac293ed6 CMake: Improve debugging support for clang build
Otherwise strings and such give errors in various debuggers.

See https://bugzilla.redhat.com/show_bug.cgi?id=1740927
2022-06-23 11:18:23 -04:00
Ian McInerney 9bb5beb264 Use symlink to pcbnew kiface for python module on Linux
Instead of installing an identical shared library into the Python
folder, just use a link to the existing library instead.

Fixes https://gitlab.com/kicad/code/kicad/issues/9974
2022-06-22 23:40:29 +01:00
Ian McInerney b51d8c9825 Introduce new CMake variable to store kiface install location 2022-06-22 23:40:25 +01:00
Seth Hillbrand 3ddd287004 Revert "Fixup python module install"
This reverts commit 6fd60c5561.

Worked only for a single make.  Second run fails due to missing file
2022-06-22 14:11:59 -07:00
Seth Hillbrand 6fd60c5561 Fixup python module install
INSTALL(FILE) does not handle setting linux-specific attributes in the
same way that INSTALL(TARGET) does.  This patch is suggested by
StefanBruens

Fixes https://gitlab.com/kicad/code/kicad/issues/9974
2022-06-22 13:29:08 -07:00
Fabien Corona 0d35d69f70 ADDED: Read IBIS files 2022-06-09 18:30:51 +00:00
Roberto Fernandez Bautista 80c8cfbbda Add PEGTL playground tool 2022-06-09 17:35:00 +01:00
Marek Roszko c34fb494b1 Reorder pybind11 to be after we find the interp and libs ourselves
Our python find module is patched for vcpkg and we want it to execute first.
2022-05-02 00:44:06 -04:00
Mark Roszko d16a3573f6 Remove errant phoenix message when disabled 2022-04-30 17:53:57 +00:00
Marek Roszko 8f63aea0c3 Bump boost minimum per previous discussion 2022-04-09 07:42:31 -04:00
Mark Roszko f0f33ef1d3 Introduce sentry for crash data collection 2022-04-02 01:21:55 +00:00