Commit graph

14 commits

Author SHA1 Message Date
Chris Kay
d259e347e6 Add CMake package config file
This change enables automatic detection and consumption of Mbed TLS
library targets from within other CMake projects. By generating an
`MbedTLSConfig.cmake` file, consuming projects receive a more complete
view of these targets, allowing them to be used as dependencies which
properly inherit the transitive dependencies of the libraries.

This is fairly fragile, as it seems Mbed TLS's libraries do not appear
to properly model their dependencies on other targets, including
third-party dependencies. It is, however, sufficient for building and
linking the compiled Mbed TLS libraries when there are no third-party
dependencies involved. Further work is needed for more complex
use-cases, but this will likely meet the needs of most projects.

Resolves #298. Probably useful for #2857.

Signed-off-by: Chris Kay <chris.kay@arm.com>
2021-06-04 16:02:48 +01:00
Ronald Cron
f19f312aa6 cmake: Add 3rd party public include directories
Add the possibility to distinguish between public and
non-public include directories. Public directories are
the one to use to access definitions of 3rd party code
interfaces.

Signed-off-by: Ronald Cron <ronald.cron@arm.com>
2020-06-22 13:44:03 +02:00
Ronald Cron
00f5b8cd63 cmake: Compile everest code only if necessary
Compile everest code only if
MBEDTLS_ECDH_VARIANT_EVEREST_ENABLED is defined
in config.h

Signed-off-by: Ronald Cron <ronald.cron@arm.com>
2020-06-22 13:44:03 +02:00
okhowang(王沛文)
3c1b090e58 Use FindPython3 when cmake version >= 3.15.0
Signed-off-by: okhowang(王沛文) <okhowang@tencent.com>
2020-06-10 10:21:50 +08:00
Gilles Peskine
3bdd412d09 Invoke config.py instead of config.pl
git grep -Fl /config.pl | xargs sed -i -e 's!/config\.pl!/config.py!g'

Also:
* Change one comment in include/mbedtls/check_config.h.
* Change PERL to PYTHON in CMakeLists.txt.
2019-11-13 14:33:33 +00:00
Janos Follath
71dcefbb8a Remove Mbed Crypto headers from everest_inc
At this point Mbed TLS and Mbed Crypto headers with the same name,
including the Mbed Crypto headers in `everest_inc` breaks Mbed TLS
builds.
2019-08-21 13:01:18 +01:00
Christoph M. Wintersteiger
d64e1e1e1c 3rdparty: Fix Everest header installation 2019-08-19 13:37:46 +01:00
Christoph M. Wintersteiger
ec70771a71 3rdparty: fix paths in Everest build scripts 2019-08-19 13:37:46 +01:00
Christoph M. Wintersteiger
26b98e12c5 3rdparty: Fix newlines and trailing whitespace 2019-08-19 13:37:46 +01:00
Christoph M. Wintersteiger
6e0cac1f57 3rdparty: Fix Everest build to not depend on build-time macros 2019-08-19 13:37:46 +01:00
Christoph M. Wintersteiger
f21aba4cb2 3rdparty: Fix Everest platform detection for CMake 2019-08-19 13:37:46 +01:00
Christoph M. Wintersteiger
6ea2dea1c5 3rdparty: Add additional build facilities for 3rd-party code 2019-08-19 13:37:46 +01:00
Christoph M. Wintersteiger
ea24394c03 ECDH: Fix whitespace and permission problems 2019-08-19 13:36:44 +01:00
Christoph M. Wintersteiger
62dddd08fd Add new 3rdparty build scripts 2019-08-19 13:36:44 +01:00