Commit Graph

11 Commits

Author SHA1 Message Date
Hennadii Stepanov
c232486d84 Revert "cmake: Set ENVIRONMENT property for examples on Windows"
This reverts commit 116d2ab3df.
2024-09-18 18:13:44 +01:00
Sebastian Falbesoner
31f84595c4 Add ellswift usage example
This should hopefully be useful as orientation for users implementing
the key exchange part of BIP324. Conceptually the example is not very
different to the ECDH one, so a lot of code/comments are just copied
(e.g. context creation, secret key generation, shared secret comparison,
console output, cleanup with secret key clearing).
2024-06-25 17:11:20 +02:00
Hennadii Stepanov
116d2ab3df cmake: Set ENVIRONMENT property for examples on Windows
This change simplifies running examples on Windows, because the DLL
must reside either in the same folder where the executable is or
somewhere in PATH.
2023-07-14 08:42:48 +01:00
Hennadii Stepanov
cef373997c cmake, refactor: Use helper function instead of interface library
This change aims to simplify the following commit.
2023-07-14 08:41:26 +01:00
Hennadii Stepanov
ae9db95cea build: Introduce SECP256K1_STATIC macro for Windows users
It is a non-Libtool-specific way to explicitly specify the user's
intention to consume a static `libseck256k1`.

This change allows to get rid of MSVC linker warnings LNK4217 and
LNK4286. Also, it makes possible to merge the `SECP256K1_API` and
`SECP256K1_API_VAR` into one.
2023-07-03 13:57:11 +01:00
Hennadii Stepanov
755629bc03 cmake: Use full signature of add_test() command
An executable target in the `COMMAND` option will automatically be
replaced by the location of the executable created at build time.

This change fixes tests for Windows binaries using Wine.
2023-04-29 09:49:25 +01:00
Tim Ruffing
6b7e5b717d Merge bitcoin-core/secp256k1#1275: build: Fix C4005 "macro redefinition" MSVC warnings in examples
dc0657c762 build: Fix C4005 "macro redefinition" MSVC warnings in examples (Hennadii Stepanov)

Pull request description:

  This PR:
  - fixes C4005 "macro redefinition" MSVC warnings in examples
  - removes warning suppressions in both build systems, Autotools-based and CMake-based ones

ACKs for top commit:
  real-or-random:
    utACK dc0657c762

Tree-SHA512: fe3bb8f06b3ff1d51e5e20754a289e0e6b99ddf4c0bd4e6e4786e2558e71e043ab23ff7782a83a902df5db28d18ae65312674c373fdc49f5af252763a22bd0fb
2023-04-26 16:44:51 +01:00
Cory Fields
ef49a11d29 build: allow static or shared but not both 2023-04-17 16:25:27 +00:00
Hennadii Stepanov
dc0657c762 build: Fix C4005 "macro redefinition" MSVC warnings in examples 2023-04-13 12:23:30 +01:00
Hennadii Stepanov
8be82d4362 cmake: Rename project to "libsecp256k1" 2023-03-08 21:22:24 +00:00
Hennadii Stepanov
5468d70964 build: Add CMake-based build system
Co-authored-by: Tim Ruffing <crypto@timruffing.de>
2023-03-08 13:33:16 +00:00