Support for armv7,armv7s and arm64 #383

issue sandeepmalode opened this issue on March 25, 2016
  1. sandeepmalode commented at 3:58 AM on March 25, 2016: none

    Hi, can anyone please suggest how do I generate libsec256k1 for armv7,armv7s and arm64 for iOS.The existing project builds it for x86_64 arch only. Thanks.

  2. jonasschnelli commented at 7:51 AM on March 25, 2016: contributor

    This is relatively simple. The libsecp256k1 codebase can be cross compiled easily (thanks to the hight portability of C89 and no dependencies).

    A good starting point is this: https://gist.github.com/j0sh/895945 (it needs some path adaptions to newer Xcode versions).

    Or you could adapt the curl is build script: https://github.com/biasedbit/curl-ios-build-scripts (which is more up to date).

    Basically you cross compile for armv7s armv7 and i386 and use lipo -create to create a universal library that include all three platforms (older iOS devices, current one and simulator).

    Would be great if you could post a working script here once you have it.

  3. laanwj commented at 8:33 AM on March 25, 2016: member

    The existing project builds it for x86_84 arch only

    It builds for the build system's arch by default. If that happens to be x86_64, like for most people, it will build for that.

    A typical cross-build setup would be (make sure that you have the toolchain, on Ubuntu it's available as gcc-arm-linux-gnueabihf):

    ./configure --enable-benchmark --host=arm-linux-gnueabihf
    

    I also wrote an ARM assembly implementation of some of the inner functions at some point see https://github.com/bitcoin/secp256k1/pull/366 and https://github.com/bitcoin/secp256k1/pull/173. It resulted in some quite good speedups on some chips.

  4. laanwj commented at 6:01 AM on December 2, 2016: member

    Closing this, I don't think there's anything to add?

    Edit: the ARM32 assembly was merged, it can be enabled with experimental features.

  5. laanwj closed this on Dec 2, 2016


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin-core/secp256k1. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-14 14:15 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me