Tim Ruffing 222ecaf661
Merge bitcoin-core/secp256k1#1284: cmake: Some improvements using PROJECT_IS_TOP_LEVEL variable
71f746c057a66d5ae0dfdb5d439bc49592c0d16e cmake: Include `include` directory for subtree builds (Hennadii Stepanov)
5431b9decdbbdf30c5c5f2aed4b59662f5c681a2 cmake: Make `SECP256K1_INSTALL` default depend on `PROJECT_IS_TOP_LEVEL` (Hennadii Stepanov)
162608cc982538906e775d0c549aff2de5dee413 cmake: Emulate `PROJECT_IS_TOP_LEVEL` for CMake<3.21 (Hennadii Stepanov)

Pull request description:

  This PR:
  1. Emulates [`PROJECT_IS_TOP_LEVEL`](https://cmake.org/cmake/help/latest/variable/PROJECT_IS_TOP_LEVEL.html) variable for CMake versions where it is not available.
  2. Makes the `SECP256K1_INSTALL` option dependent on `PROJECT_IS_TOP_LEVEL` (a [follow up](https://github.com/bitcoin-core/secp256k1/pull/1263#issuecomment-1516564300) of https://github.com/bitcoin-core/secp256k1/pull/1263).
  3. Makes integration of this project as a subtree easier. A top project can `#include <secp256k1.h>` with no additional `target_include_directories()` commands. For example, see https://github.com/hebasto/secp256k1-CMake-example/tree/subtree.

ACKs for top commit:
  theuni:
    utACK 71f746c057a66d5ae0dfdb5d439bc49592c0d16e.

Tree-SHA512: 8ccdbcc94b26f36e772611ebaab0f2846debd6ad20f9e361be31a8d2128a14273acb692b0631026e12cc6cdef6d445dce0fd3beb4f71af47b46dfcf840a18879
2023-04-27 15:17:38 +01:00
..
2022-11-07 16:37:24 -05:00
2021-08-20 11:11:26 -04:00
2021-08-20 11:11:26 -04:00
2021-08-20 11:11:26 -04:00
2020-12-18 00:24:22 +02:00
2020-12-18 00:24:22 +02:00
2023-04-20 16:07:56 -04:00
2022-12-07 10:54:50 +00:00
2022-03-25 11:32:14 +01:00
2022-11-07 16:37:24 -05:00
2022-11-07 16:37:24 -05:00
2023-02-28 15:54:00 -05:00
2023-03-07 09:10:36 -05:00
2023-02-28 15:54:00 -05:00
2021-12-18 16:12:34 -05:00
2020-12-18 00:24:22 +02:00
2020-12-18 00:24:22 +02:00
2020-12-18 00:24:22 +02:00
2021-01-23 14:48:35 -05:00