From 35f097542b4266ac0a964f4f74f6bc9e4653361a Mon Sep 17 00:00:00 2001 From: thunderbiscuit Date: Tue, 22 Mar 2022 14:01:39 -0400 Subject: [PATCH] Add documentation for plugin --- buildSrc/README.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 buildSrc/README.md diff --git a/buildSrc/README.md b/buildSrc/README.md new file mode 100644 index 0000000..dc90dfa --- /dev/null +++ b/buildSrc/README.md @@ -0,0 +1,16 @@ +# Readme +The purpose of this directory is to host a Gradle plugin that adds tasks for building the native binaries required by bdk-jvm/ bdk-android and building the language bindings files. + +The plugin is applied to the specific `build.gradle.kts` files in `bdk-jvm` and `bdk-android` through the `plugins` block: +```kotlin +plugins { + id("org.bitcoindevkit.plugin.generate-bdk-bindings") +} +``` + +It adds a series of tasks (`buildJvmBinary`, `moveNativeJvmLib`, `generateJvmBindings`) which are then brought together into an aggregate task called `buildJvmLib`. + +This task: +1. Builds the native JVM library (on your given platform) using `bdk-ffi` +2. Places it in the correct resource directory +3. Builds the bindings file