diff --git a/secp256k1-bitcoinj/build.gradle b/secp256k1-bitcoinj/build.gradle index 266dbe0..93522fa 100644 --- a/secp256k1-bitcoinj/build.gradle +++ b/secp256k1-bitcoinj/build.gradle @@ -13,7 +13,7 @@ dependencies { api("org.bitcoinj:bitcoinj-core:0.17-alpha3"); implementation project(':secp256k1-bouncy') - implementation project(':secp256k1-foreign') + implementation project(':secp256k1-ffm') } jar { diff --git a/secp256k1-bitcoinj/src/main/java/org/bitcoinj/secp256k1/bitcoinj/WitnessMaker.java b/secp256k1-bitcoinj/src/main/java/org/bitcoinj/secp256k1/bitcoinj/WitnessMaker.java index ee1bfca..8580c0e 100644 --- a/secp256k1-bitcoinj/src/main/java/org/bitcoinj/secp256k1/bitcoinj/WitnessMaker.java +++ b/secp256k1-bitcoinj/src/main/java/org/bitcoinj/secp256k1/bitcoinj/WitnessMaker.java @@ -18,7 +18,7 @@ import org.bitcoinj.secp256k1.api.P256K1XOnlyPubKey; import org.bitcoinj.secp256k1.api.P256k1PubKey; import org.bitcoinj.secp256k1.api.Secp256k1; -import org.bitcoinj.secp256k1.foreign.PubKeyPojo; +import org.bitcoinj.secp256k1.ffm.PubKeyPojo; import java.math.BigInteger; import java.nio.ByteBuffer; diff --git a/secp256k1-bitcoinj/src/test/java/org/bitcoinj/secp256k1/bitcoinj/AddressTest.java b/secp256k1-bitcoinj/src/test/java/org/bitcoinj/secp256k1/bitcoinj/AddressTest.java index d59340e..9df74a2 100644 --- a/secp256k1-bitcoinj/src/test/java/org/bitcoinj/secp256k1/bitcoinj/AddressTest.java +++ b/secp256k1-bitcoinj/src/test/java/org/bitcoinj/secp256k1/bitcoinj/AddressTest.java @@ -27,7 +27,7 @@ import org.bitcoinj.secp256k1.bouncy.Bouncy256k1; import org.bitcoinj.secp256k1.bouncy.BouncyPrivKey; import org.bitcoinj.secp256k1.bouncy.BouncyPubKey; -import org.bitcoinj.secp256k1.foreign.PubKeyPojo; +import org.bitcoinj.secp256k1.ffm.PubKeyPojo; import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; import org.junit.jupiter.params.ParameterizedTest; diff --git a/secp256k1-examples-java/build.gradle b/secp256k1-examples-java/build.gradle index eb1eab0..202d6e9 100644 --- a/secp256k1-examples-java/build.gradle +++ b/secp256k1-examples-java/build.gradle @@ -12,7 +12,7 @@ ext.moduleName = 'org.bitcoinj.secp256k1.examples' dependencies { implementation project(':secp256k1-api') runtimeOnly project(':secp256k1-bouncy') - runtimeOnly project(':secp256k1-foreign') + runtimeOnly project(':secp256k1-ffm') } jar { diff --git a/secp256k1-examples-kotlin/build.gradle b/secp256k1-examples-kotlin/build.gradle index 35fc24a..dc2d774 100644 --- a/secp256k1-examples-kotlin/build.gradle +++ b/secp256k1-examples-kotlin/build.gradle @@ -6,7 +6,7 @@ plugins { dependencies { implementation project(':secp256k1-api') runtimeOnly project(':secp256k1-bouncy') - runtimeOnly project(':secp256k1-foreign') + runtimeOnly project(':secp256k1-ffm') } tasks.withType(JavaCompile).configureEach { diff --git a/secp256k1-foreign/build.gradle b/secp256k1-ffm/build.gradle similarity index 89% rename from secp256k1-foreign/build.gradle rename to secp256k1-ffm/build.gradle index ae4fe6e..9a84f8c 100644 --- a/secp256k1-foreign/build.gradle +++ b/secp256k1-ffm/build.gradle @@ -6,7 +6,7 @@ tasks.withType(JavaCompile).configureEach { //options.release = 22 } -ext.moduleName = 'org.bitcoinj.secp256k1.foreign' +ext.moduleName = 'org.bitcoinj.secp256k1.ffm' dependencies { api project(':secp256k1-api') diff --git a/secp256k1-foreign/src/main/java/module-info.java b/secp256k1-ffm/src/main/java/module-info.java similarity index 85% rename from secp256k1-foreign/src/main/java/module-info.java rename to secp256k1-ffm/src/main/java/module-info.java index 00de324..37380f1 100644 --- a/secp256k1-foreign/src/main/java/module-info.java +++ b/secp256k1-ffm/src/main/java/module-info.java @@ -18,8 +18,8 @@ requires org.bitcoinj.secp256k1.api; requires org.jspecify; - exports org.bitcoinj.secp256k1.foreign; - exports org.bitcoinj.secp256k1.foreign.jextract; + exports org.bitcoinj.secp256k1.ffm; + exports org.bitcoinj.secp256k1.ffm.jextract; - provides org.bitcoinj.secp256k1.api.Secp256k1Provider with org.bitcoinj.secp256k1.foreign.ForeignProvider; + provides org.bitcoinj.secp256k1.api.Secp256k1Provider with org.bitcoinj.secp256k1.ffm.ForeignProvider; } diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/CompressedPubKeyPojo.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/CompressedPubKeyPojo.java similarity index 96% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/CompressedPubKeyPojo.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/CompressedPubKeyPojo.java index 783529c..24461dd 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/CompressedPubKeyPojo.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/CompressedPubKeyPojo.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.bitcoinj.secp256k1.foreign; +package org.bitcoinj.secp256k1.ffm; import org.bitcoinj.secp256k1.api.CompressedPubKeyData; diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/CompressedSignaturePojo.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/CompressedSignaturePojo.java similarity index 97% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/CompressedSignaturePojo.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/CompressedSignaturePojo.java index 715769f..a687117 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/CompressedSignaturePojo.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/CompressedSignaturePojo.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.bitcoinj.secp256k1.foreign; +package org.bitcoinj.secp256k1.ffm; import org.bitcoinj.secp256k1.api.CompressedSignatureData; diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/ForeignProvider.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/ForeignProvider.java similarity index 95% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/ForeignProvider.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/ForeignProvider.java index eff1eaf..81c9a57 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/ForeignProvider.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/ForeignProvider.java @@ -1,4 +1,4 @@ -package org.bitcoinj.secp256k1.foreign; +package org.bitcoinj.secp256k1.ffm; import org.bitcoinj.secp256k1.api.Secp256k1; import org.bitcoinj.secp256k1.api.Secp256k1Provider; diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/OpaqueKeyPair.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/OpaqueKeyPair.java similarity index 93% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/OpaqueKeyPair.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/OpaqueKeyPair.java index 67dc96d..a5feccb 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/OpaqueKeyPair.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/OpaqueKeyPair.java @@ -13,13 +13,13 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.bitcoinj.secp256k1.foreign; +package org.bitcoinj.secp256k1.ffm; import org.bitcoinj.secp256k1.api.P256K1KeyPair; import org.bitcoinj.secp256k1.api.P256k1PrivKey; import org.bitcoinj.secp256k1.api.P256k1PubKey; -import org.bitcoinj.secp256k1.foreign.jextract.secp256k1_h; -import org.bitcoinj.secp256k1.foreign.jextract.secp256k1_pubkey; +import org.bitcoinj.secp256k1.ffm.jextract.secp256k1_h; +import org.bitcoinj.secp256k1.ffm.jextract.secp256k1_pubkey; import java.lang.foreign.MemorySegment; import java.security.spec.ECPoint; diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/PrivKeyPojo.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/PrivKeyPojo.java similarity index 98% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/PrivKeyPojo.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/PrivKeyPojo.java index 1876e01..c404af2 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/PrivKeyPojo.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/PrivKeyPojo.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.bitcoinj.secp256k1.foreign; +package org.bitcoinj.secp256k1.ffm; import org.bitcoinj.secp256k1.api.P256k1PrivKey; diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/PrivKeySegment.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/PrivKeySegment.java similarity index 96% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/PrivKeySegment.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/PrivKeySegment.java index 3ed7fb5..1d18ab1 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/PrivKeySegment.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/PrivKeySegment.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.bitcoinj.secp256k1.foreign; +package org.bitcoinj.secp256k1.ffm; import org.bitcoinj.secp256k1.api.P256k1PrivKey; diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/PubKeyPojo.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/PubKeyPojo.java similarity index 96% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/PubKeyPojo.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/PubKeyPojo.java index 9eab5db..280a799 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/PubKeyPojo.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/PubKeyPojo.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.bitcoinj.secp256k1.foreign; +package org.bitcoinj.secp256k1.ffm; import org.bitcoinj.secp256k1.api.P256k1PubKey; diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/PubKeySegment.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/PubKeySegment.java similarity index 96% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/PubKeySegment.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/PubKeySegment.java index 39fd239..954f300 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/PubKeySegment.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/PubKeySegment.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.bitcoinj.secp256k1.foreign; +package org.bitcoinj.secp256k1.ffm; import org.bitcoinj.secp256k1.api.P256k1PubKey; diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/Secp256k1Foreign.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/Secp256k1Foreign.java similarity index 96% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/Secp256k1Foreign.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/Secp256k1Foreign.java index 4b47635..65504df 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/Secp256k1Foreign.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/Secp256k1Foreign.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.bitcoinj.secp256k1.foreign; +package org.bitcoinj.secp256k1.ffm; import org.bitcoinj.secp256k1.api.CompressedPubKeyData; import org.bitcoinj.secp256k1.api.CompressedSignatureData; @@ -24,11 +24,11 @@ import org.bitcoinj.secp256k1.api.Result; import org.bitcoinj.secp256k1.api.Secp256k1; import org.bitcoinj.secp256k1.api.SignatureData; -import org.bitcoinj.secp256k1.foreign.jextract.secp256k1_ecdsa_signature; -import org.bitcoinj.secp256k1.foreign.jextract.secp256k1_h; -import org.bitcoinj.secp256k1.foreign.jextract.secp256k1_keypair; -import org.bitcoinj.secp256k1.foreign.jextract.secp256k1_pubkey; -import org.bitcoinj.secp256k1.foreign.jextract.secp256k1_xonly_pubkey; +import org.bitcoinj.secp256k1.ffm.jextract.secp256k1_ecdsa_signature; +import org.bitcoinj.secp256k1.ffm.jextract.secp256k1_h; +import org.bitcoinj.secp256k1.ffm.jextract.secp256k1_keypair; +import org.bitcoinj.secp256k1.ffm.jextract.secp256k1_pubkey; +import org.bitcoinj.secp256k1.ffm.jextract.secp256k1_xonly_pubkey; import java.lang.foreign.Arena; import java.lang.foreign.MemorySegment; @@ -38,9 +38,9 @@ import java.security.spec.ECPoint; import static java.lang.foreign.ValueLayout.JAVA_BYTE; -import static org.bitcoinj.secp256k1.foreign.jextract.secp256k1_h.C_POINTER; -import static org.bitcoinj.secp256k1.foreign.jextract.secp256k1_h.SECP256K1_EC_UNCOMPRESSED; -import static org.bitcoinj.secp256k1.foreign.jextract.secp256k1_h.secp256k1_schnorrsig_sign32; +import static org.bitcoinj.secp256k1.ffm.jextract.secp256k1_h.C_POINTER; +import static org.bitcoinj.secp256k1.ffm.jextract.secp256k1_h.SECP256K1_EC_UNCOMPRESSED; +import static org.bitcoinj.secp256k1.ffm.jextract.secp256k1_h.secp256k1_schnorrsig_sign32; /** * diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/SignaturePojo.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/SignaturePojo.java similarity index 97% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/SignaturePojo.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/SignaturePojo.java index 5bdfda7..269f758 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/SignaturePojo.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/SignaturePojo.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package org.bitcoinj.secp256k1.foreign; +package org.bitcoinj.secp256k1.ffm; import org.bitcoinj.secp256k1.api.SignatureData; diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_context_set_error_callback$fun.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_context_set_error_callback$fun.java similarity index 90% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_context_set_error_callback$fun.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_context_set_error_callback$fun.java index c579ca6..719f881 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_context_set_error_callback$fun.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_context_set_error_callback$fun.java @@ -15,17 +15,10 @@ */ // Generated by jextract -package org.bitcoinj.secp256k1.foreign.jextract; +package org.bitcoinj.secp256k1.ffm.jextract; import java.lang.invoke.*; import java.lang.foreign.*; -import java.nio.ByteOrder; -import java.util.*; -import java.util.function.*; -import java.util.stream.*; - -import static java.lang.foreign.ValueLayout.*; -import static java.lang.foreign.MemoryLayout.PathElement.*; /** * {@snippet lang=c : diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_context_set_illegal_callback$fun.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_context_set_illegal_callback$fun.java similarity index 90% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_context_set_illegal_callback$fun.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_context_set_illegal_callback$fun.java index 166a719..ae7e08c 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_context_set_illegal_callback$fun.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_context_set_illegal_callback$fun.java @@ -15,17 +15,10 @@ */ // Generated by jextract -package org.bitcoinj.secp256k1.foreign.jextract; +package org.bitcoinj.secp256k1.ffm.jextract; import java.lang.invoke.*; import java.lang.foreign.*; -import java.nio.ByteOrder; -import java.util.*; -import java.util.function.*; -import java.util.stream.*; - -import static java.lang.foreign.ValueLayout.*; -import static java.lang.foreign.MemoryLayout.PathElement.*; /** * {@snippet lang=c : diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_ecdsa_signature.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_ecdsa_signature.java similarity index 96% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_ecdsa_signature.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_ecdsa_signature.java index c9f3bcb..f56bdd8 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_ecdsa_signature.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_ecdsa_signature.java @@ -15,16 +15,12 @@ */ // Generated by jextract -package org.bitcoinj.secp256k1.foreign.jextract; +package org.bitcoinj.secp256k1.ffm.jextract; import java.lang.invoke.*; import java.lang.foreign.*; -import java.nio.ByteOrder; -import java.util.*; import java.util.function.*; -import java.util.stream.*; -import static java.lang.foreign.ValueLayout.*; import static java.lang.foreign.MemoryLayout.PathElement.*; /** diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_h.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_h.java similarity index 99% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_h.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_h.java index 8843ffe..e98031b 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_h.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_h.java @@ -15,17 +15,14 @@ */ // Generated by jextract -package org.bitcoinj.secp256k1.foreign.jextract; +package org.bitcoinj.secp256k1.ffm.jextract; import java.lang.invoke.*; import java.lang.foreign.*; -import java.nio.ByteOrder; import java.util.*; -import java.util.function.*; import java.util.stream.*; import static java.lang.foreign.ValueLayout.*; -import static java.lang.foreign.MemoryLayout.PathElement.*; public class secp256k1_h { diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_keypair.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_keypair.java similarity index 96% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_keypair.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_keypair.java index 391b1d7..38ccaa9 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_keypair.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_keypair.java @@ -15,16 +15,12 @@ */ // Generated by jextract -package org.bitcoinj.secp256k1.foreign.jextract; +package org.bitcoinj.secp256k1.ffm.jextract; import java.lang.invoke.*; import java.lang.foreign.*; -import java.nio.ByteOrder; -import java.util.*; import java.util.function.*; -import java.util.stream.*; -import static java.lang.foreign.ValueLayout.*; import static java.lang.foreign.MemoryLayout.PathElement.*; /** diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_nonce_function.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_nonce_function.java similarity index 91% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_nonce_function.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_nonce_function.java index ccc5466..9648ada 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_nonce_function.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_nonce_function.java @@ -15,17 +15,10 @@ */ // Generated by jextract -package org.bitcoinj.secp256k1.foreign.jextract; +package org.bitcoinj.secp256k1.ffm.jextract; import java.lang.invoke.*; import java.lang.foreign.*; -import java.nio.ByteOrder; -import java.util.*; -import java.util.function.*; -import java.util.stream.*; - -import static java.lang.foreign.ValueLayout.*; -import static java.lang.foreign.MemoryLayout.PathElement.*; /** * {@snippet lang=c : diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_nonce_function_hardened.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_nonce_function_hardened.java similarity index 92% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_nonce_function_hardened.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_nonce_function_hardened.java index bd8f57d..b5c3452 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_nonce_function_hardened.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_nonce_function_hardened.java @@ -15,17 +15,10 @@ */ // Generated by jextract -package org.bitcoinj.secp256k1.foreign.jextract; +package org.bitcoinj.secp256k1.ffm.jextract; import java.lang.invoke.*; import java.lang.foreign.*; -import java.nio.ByteOrder; -import java.util.*; -import java.util.function.*; -import java.util.stream.*; - -import static java.lang.foreign.ValueLayout.*; -import static java.lang.foreign.MemoryLayout.PathElement.*; /** * {@snippet lang=c : diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_pubkey.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_pubkey.java similarity index 96% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_pubkey.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_pubkey.java index 3057374..4d02fc6 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_pubkey.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_pubkey.java @@ -15,16 +15,12 @@ */ // Generated by jextract -package org.bitcoinj.secp256k1.foreign.jextract; +package org.bitcoinj.secp256k1.ffm.jextract; import java.lang.invoke.*; import java.lang.foreign.*; -import java.nio.ByteOrder; -import java.util.*; import java.util.function.*; -import java.util.stream.*; -import static java.lang.foreign.ValueLayout.*; import static java.lang.foreign.MemoryLayout.PathElement.*; /** diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_schnorrsig_extraparams.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_schnorrsig_extraparams.java similarity index 97% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_schnorrsig_extraparams.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_schnorrsig_extraparams.java index 22fe54d..54686e2 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_schnorrsig_extraparams.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_schnorrsig_extraparams.java @@ -15,16 +15,12 @@ */ // Generated by jextract -package org.bitcoinj.secp256k1.foreign.jextract; +package org.bitcoinj.secp256k1.ffm.jextract; import java.lang.invoke.*; import java.lang.foreign.*; -import java.nio.ByteOrder; -import java.util.*; import java.util.function.*; -import java.util.stream.*; -import static java.lang.foreign.ValueLayout.*; import static java.lang.foreign.MemoryLayout.PathElement.*; /** diff --git a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_xonly_pubkey.java b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_xonly_pubkey.java similarity index 96% rename from secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_xonly_pubkey.java rename to secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_xonly_pubkey.java index 79b552a..cc17324 100644 --- a/secp256k1-foreign/src/main/java/org/bitcoinj/secp256k1/foreign/jextract/secp256k1_xonly_pubkey.java +++ b/secp256k1-ffm/src/main/java/org/bitcoinj/secp256k1/ffm/jextract/secp256k1_xonly_pubkey.java @@ -15,16 +15,12 @@ */ // Generated by jextract -package org.bitcoinj.secp256k1.foreign.jextract; +package org.bitcoinj.secp256k1.ffm.jextract; import java.lang.invoke.*; import java.lang.foreign.*; -import java.nio.ByteOrder; -import java.util.*; import java.util.function.*; -import java.util.stream.*; -import static java.lang.foreign.ValueLayout.*; import static java.lang.foreign.MemoryLayout.PathElement.*; /** diff --git a/secp256k1-ffm/src/main/resources/META-INF/services/org.bitcoinj.secp256k1.api.Secp256k1Provider b/secp256k1-ffm/src/main/resources/META-INF/services/org.bitcoinj.secp256k1.api.Secp256k1Provider new file mode 100644 index 0000000..8969f50 --- /dev/null +++ b/secp256k1-ffm/src/main/resources/META-INF/services/org.bitcoinj.secp256k1.api.Secp256k1Provider @@ -0,0 +1 @@ +org.bitcoinj.secp256k1.ffm.ForeignProvider diff --git a/secp256k1-foreign/src/main/resources/META-INF/services/org.bitcoinj.secp256k1.api.Secp256k1Provider b/secp256k1-foreign/src/main/resources/META-INF/services/org.bitcoinj.secp256k1.api.Secp256k1Provider deleted file mode 100644 index bcffd87..0000000 --- a/secp256k1-foreign/src/main/resources/META-INF/services/org.bitcoinj.secp256k1.api.Secp256k1Provider +++ /dev/null @@ -1 +0,0 @@ -org.bitcoinj.secp256k1.foreign.ForeignProvider diff --git a/secp256k1-integration-test/build.gradle b/secp256k1-integration-test/build.gradle index b70199a..f901b15 100644 --- a/secp256k1-integration-test/build.gradle +++ b/secp256k1-integration-test/build.gradle @@ -11,7 +11,7 @@ ext.moduleName = 'org.bitcoinj.secp256k1.integration' dependencies { implementation project(':secp256k1-api') implementation project(':secp256k1-bouncy') - implementation project(':secp256k1-foreign') + implementation project(':secp256k1-ffm') implementation project(':secp256k1-sandbox') } diff --git a/secp256k1-integration-test/src/test/java/org/bitcoinj/secp256k1/integration/CurveTest.java b/secp256k1-integration-test/src/test/java/org/bitcoinj/secp256k1/integration/CurveTest.java index 4a8ba93..58d3db0 100644 --- a/secp256k1-integration-test/src/test/java/org/bitcoinj/secp256k1/integration/CurveTest.java +++ b/secp256k1-integration-test/src/test/java/org/bitcoinj/secp256k1/integration/CurveTest.java @@ -20,7 +20,7 @@ import org.bitcoinj.secp256k1.api.Secp256k1; import org.bitcoinj.secp256k1.bouncy.Bouncy256k1; import org.bitcoinj.secp256k1.bouncy.BouncyPrivKey; -import org.bitcoinj.secp256k1.foreign.Secp256k1Foreign; +import org.bitcoinj.secp256k1.ffm.Secp256k1Foreign; import org.junit.jupiter.api.Test; import java.math.BigInteger; diff --git a/secp256k1-integration-test/src/test/java/org/bitcoinj/secp256k1/integration/Secp256k1ForeignTest.java b/secp256k1-integration-test/src/test/java/org/bitcoinj/secp256k1/integration/Secp256k1ForeignTest.java index f567c41..6f677c5 100644 --- a/secp256k1-integration-test/src/test/java/org/bitcoinj/secp256k1/integration/Secp256k1ForeignTest.java +++ b/secp256k1-integration-test/src/test/java/org/bitcoinj/secp256k1/integration/Secp256k1ForeignTest.java @@ -17,7 +17,7 @@ import org.bitcoinj.secp256k1.api.P256k1PubKey; import org.bitcoinj.secp256k1.bouncy.BouncyPrivKey; -import org.bitcoinj.secp256k1.foreign.Secp256k1Foreign; +import org.bitcoinj.secp256k1.ffm.Secp256k1Foreign; import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; diff --git a/secp256k1-sandbox/build.gradle b/secp256k1-sandbox/build.gradle index bd6a658..a6442d6 100644 --- a/secp256k1-sandbox/build.gradle +++ b/secp256k1-sandbox/build.gradle @@ -11,7 +11,7 @@ ext.moduleName = 'org.bitcoinj.secp256k1.sandbox' dependencies { api project(':secp256k1-api') api project(':secp256k1-bouncy') - api project(':secp256k1-foreign') + api project(':secp256k1-ffm') } jar { diff --git a/settings.gradle b/settings.gradle index 887183c..658008d 100644 --- a/settings.gradle +++ b/settings.gradle @@ -2,7 +2,7 @@ rootProject.name = 'secp256k1-jdk' include 'secp256k1-api' // API interface library include 'secp256k1-bouncy' // Bouncy Castle implementation -include 'secp256k1-foreign' // Java Foreign Memory & Function ("Panama") implementation +include 'secp256k1-ffm' // Java Foreign Memory & Function ("Panama") implementation include 'secp256k1-bitcoinj' // bitcoinj integration utilities and tests (P2TR address generation, etc.) include 'secp256k1-integration-test' // Integration tests of API implementations (foreign and bouncy) include 'secp256k1-examples-java' // Java examples