Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 0 additions & 9 deletions docs-template/EXAMPLE_README.md.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ git checkout v0.4.0
- [Android](#android)
- [Setup](#setup)
- [Build & Run](#build--run)
- [About `libc++_shared.so`](#about-libc_sharedso)
- [Old phones](#old-phones)
- [About `cargo-apk`](#about-cargo-apk)
- [iOS](#ios)
Expand Down Expand Up @@ -130,14 +129,6 @@ Or build it with Android Studio.

Then you can test it in your Android project.

##### About `libc++_shared.so`

Bevy may require `libc++_shared.so` to run on Android, as it is needed by the `oboe` crate, but typically `cargo-ndk` does not copy this file automatically.

To include it, you can manually obtain it from NDK source or use a `build.rs` script for automation, as described in the `cargo-ndk` [README](https://github.com/bbqsrc/cargo-ndk?tab=readme-ov-file#linking-against-and-copying-libc_sharedso-into-the-relevant-places-in-the-output-directory).

Alternatively, you can modify project files to include it when building an APK. To understand the specific steps taken in this project, please refer to the comments within the project files for detailed instructions(`app/CMakeList.txt`, `app/build.gradle`, `app/src/main/cpp/dummy.cpp`).

#### Debugging

You can view the logs with the following command:
Expand Down
9 changes: 0 additions & 9 deletions examples/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ git checkout v0.4.0
- [Android](#android)
- [Setup](#setup)
- [Build & Run](#build--run)
- [About `libc++_shared.so`](#about-libc_sharedso)
- [Old phones](#old-phones)
- [About `cargo-apk`](#about-cargo-apk)
- [iOS](#ios)
Expand Down Expand Up @@ -730,14 +729,6 @@ Or build it with Android Studio.

Then you can test it in your Android project.

##### About `libc++_shared.so`

Bevy may require `libc++_shared.so` to run on Android, as it is needed by the `oboe` crate, but typically `cargo-ndk` does not copy this file automatically.

To include it, you can manually obtain it from NDK source or use a `build.rs` script for automation, as described in the `cargo-ndk` [README](https://github.com/bbqsrc/cargo-ndk?tab=readme-ov-file#linking-against-and-copying-libc_sharedso-into-the-relevant-places-in-the-output-directory).

Alternatively, you can modify project files to include it when building an APK. To understand the specific steps taken in this project, please refer to the comments within the project files for detailed instructions(`app/CMakeList.txt`, `app/build.gradle`, `app/src/main/cpp/dummy.cpp`).

#### Debugging

You can view the logs with the following command:
Expand Down
5 changes: 0 additions & 5 deletions examples/mobile/android_example/app/CMakeLists.txt

This file was deleted.

15 changes: 0 additions & 15 deletions examples/mobile/android_example/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -12,23 +12,12 @@ android {
targetSdk 33
versionCode 1
versionName "1.0"
// need this otherwise it won't insert libc++_shared.so
externalNativeBuild {
cmake {
arguments "-DANDROID_STL=c++_shared"
}
}
// set up targets
ndk {
abiFilters 'arm64-v8a'
}
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
externalNativeBuild {
cmake {
path "CMakeLists.txt"
}
}
buildTypes {
release {
minifyEnabled false
Expand All @@ -42,10 +31,6 @@ android {
buildFeatures {
prefab true
}
// The final part to insert libc++_shared.so only
packagingOptions {
exclude 'lib/*/libdummy.so'
}
sourceSets {
main {
assets.srcDirs += files('../../../../assets')
Expand Down
2 changes: 0 additions & 2 deletions examples/mobile/android_example/app/src/main/cpp/dummy.cpp

This file was deleted.

5 changes: 0 additions & 5 deletions examples/mobile/android_example_native/app/CMakeLists.txt

This file was deleted.

16 changes: 0 additions & 16 deletions examples/mobile/android_example_native/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -12,23 +12,12 @@ android {
targetSdk 33
versionCode 1
versionName "1.0"
// need this otherwise it won't insert libc++_shared.so
externalNativeBuild {
cmake {
arguments "-DANDROID_STL=c++_shared"
}
}
// set up targets
ndk {
abiFilters 'arm64-v8a'
}
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
externalNativeBuild {
cmake {
path "CMakeLists.txt"
}
}
buildTypes {
release {
minifyEnabled false
Expand All @@ -42,11 +31,6 @@ android {
buildFeatures {
viewBinding true
}
// The final part to insert libc++_shared.so only
packagingOptions {
exclude 'lib/*/libdummy.so'
}

sourceSets {
main {
assets.srcDirs += files('../../../../assets')
Expand Down

This file was deleted.