go-waku/examples/android-kotlin
Anton Iakimov 826c7fb924
chore: switch wakuv2 fleet to waku
2024-03-20 11:38:48 +01:00
..
.idea feat: kotlin android example (#226) 2022-04-12 08:12:14 -04:00
app chore: switch wakuv2 fleet to waku 2024-03-20 11:38:48 +01:00
gradle/wrapper feat: kotlin android example (#226) 2022-04-12 08:12:14 -04:00
.gitignore feat: kotlin android example (#226) 2022-04-12 08:12:14 -04:00
README.md chore: rename status-im/go-waku to waku-org/go-waku 2022-11-09 16:03:40 -04:00
build.gradle feat: kotlin android example (#226) 2022-04-12 08:12:14 -04:00
gradle.properties feat: kotlin android example (#226) 2022-04-12 08:12:14 -04:00
gradlew feat: kotlin android example (#226) 2022-04-12 08:12:14 -04:00
gradlew.bat feat: kotlin android example (#226) 2022-04-12 08:12:14 -04:00
settings.gradle feat: kotlin android example (#226) 2022-04-12 08:12:14 -04:00

README.md

Android Kotlin Example

Requirements

  • Android Studio

Running this example

These instructions should be executed in the terminal:

# Clone the repository
git clone https://github.com/waku-org/go-waku.git
cd go-waku

# Set required env variables
export ANDROID_NDK_HOME=/path/to/android/ndk
export ANDROID_HOME=/path/to/android/sdk/

# Build the .jar
make mobile-android

# Copy the jar into `libs/` folder
cp ./build/lib/gowaku.aar ./examples/android-kotlin/app/libs/.

Open the project in Android Studio and run the example app.

Help wanted!

  • Is it possible to build go-waku automatically by executing make mobile-android and copying the .jar automatically into libs/ in Android Studio?
  • Permissions should be requested on runtime
  • Determine the required permission to fix this:
2022-04-07 19:29:27.542 20042-20068/com.example.waku E/GoLog: 2022-04-07T23:29:27.542Z	ERROR	basichost	basic/basic_host.go:327	failed to resolve local interface addresses	{"error": "route ip+net: netlinkrib: permission denied"}
  • The example app blocks the main thread and code in general could be improved