File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -37,6 +37,24 @@ build_android_llama_demo_app() {
37
37
popd
38
38
}
39
39
40
+ build_aar () {
41
+ cp extension/android/build/libs/executorch.jar build_aar/libs
42
+ echo \< manifest xmlns:android=\" http://schemas.android.com/apk/res/android\" \
43
+ package=\" org.pytorch.executorch\"\> \
44
+ \< uses-sdk android:minSdkVersion=\" 19\" /\> \
45
+ \< /manifest\> > build_aar/AndroidManifest.xml
46
+ pushd build_aar
47
+ mv jni/arm64-v8a/libexecutorch_jni.so jni/arm64-v8a/libexecutorch.so
48
+ mv jni/x86_64/libexecutorch_jni.so jni/x86_64/libexecutorch.so
49
+ zip -r executorch.aar libs jni AndroidManifest.xml
50
+
51
+ rm jni/arm64-v8a/libexecutorch.so jni/x86_64/libexecutorch.so
52
+ zip -r executorch-llama.aar libs jni AndroidManifest.xml
53
+ popd
54
+ }
55
+
56
+ mkdir -p build_aar/jni/arm64-v8a build_aar/jni/x86_64 build_aar/libs
57
+
40
58
build_android_native_library arm64-v8a
41
59
build_android_native_library x86_64
42
60
export_model
You can’t perform that action at this time.
0 commit comments