4

Are there any existing native libraries (not whole wallets, I do not need a UI but want to sign transactions and call smart contract functions embedded in another app) for iOS or Android? If not, are there efforts currently ongoing or what is the closest I could get right now?

4

There are some guys who are running geth on Android and iOS. you could find the libs and the apk project. But seriously, you need to wait the light protocol client because it is a bit insane to use a full client (Many Go of storage + so many writes that it will use battery and storage longevity).

Look this:

Android

The geth with LES is in test currently. I have made few benchmarks:

  • 600MB disk storage (4GB of write) vs 4.8GB for fast synch
  • 20min to synchronize vs 21min for fast synch

iOS

  • Native implementation on Swift of geth functionality: web3swift
2

There is Nethereum which is a .Net client for Ethereum.

You can use Xamarin (comes free with VS now) to build Android, iOS and Windows apps through the .Net framework.

Github link - https://github.com/Nethereum/Nethereum

1

(Note: I haven't done any mobile development for a while, and certainly none related to Ethereum. The below answer therefore includes a level of conjecture. I don't know of any existing efforts.)

Android apps are (most often) written in Java, so it's plausible that the relevant parts of EthereumJ could be ported with relatively little pain.

It's also been possible to write Android apps in Go since (Go) version 1.4, though I'm unsure how well supported this is. It does, however, raise the possibility of a Geth port, or partial port. Similarly, looking at Go's available mobile packages, it looks like iOS support is also there.

Edit:

Or I could have just Googled... (Thanks Ellis for the prod.)

This entry on the official GitHub repo describes how to perform an Android-Geth port, and references the more general Ethereum cross compilation page. From there, the xgo README has some further details of building mobile libraries.

I can't immediately see any pre-built libraries/images.

  • There are some guys who are running geth on Android and iOS. you could find the libs and the apk project. – Ellis Jun 28 '16 at 22:11
0

web3j now provides a Android release for working with Ethereum nodes. web3j is a lightweight Java library that provides full support for Ethereum's JSON-RPC API and transaction signing.

It also provides generation of smart-contract wrappers for deploying, transacting and calling smart contracts.

You need to run your own client, or use a cloud-based service like Infura to work with it.

As mentioned by Richard, the Geth team also provide a pre-built Android binary now. This is built using gomobile, rather than being a pure Java implementation like web3j.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.