build: update command to build plugins

Use docker to build plugin

Change-Id: I4b9afdaeff17811f05cec3d91c69db308ba7bde6
This commit is contained in:
alexandre 2025-02-12 14:23:19 -05:00 committed by Adrien Béraud
parent 49bf2a6541
commit eec6cc6908
1 changed files with 38 additions and 3 deletions

View File

@ -148,6 +148,8 @@ cd ${DAEMON}/contrib/native
make .onnx
```
Or by enabling onnx with `--enable-onnx` in the common dependencies
* Linux - With CUDA acceleration (CUDA 10.2):
```bash
@ -233,12 +235,45 @@ First you need to go to the plugins repository in your cloned jami-plugins:
- Linux - Nvidia GPU
`PROCESSOR=NVIDIA python3 build-plugin.py --projects=GreenScreen`
`PROCESSOR=NVIDIA PLATFORM_TYPE="LINUX" AUTHOR='SFL' DIVISION='Internal' python3 build-plugin.py --projects='GreenScreen'`
- Linux - CPU
`python3 build-plugin.py --projects=GreenScreen`
Using Docker (recommended):
```bash
docker run -it --rm \
-v $(pwd):/root/jami/:rw \
-w /root/ \
-e BATCH_MODE=1 \
jami-plugins-docker /bin/bash -c "
cd jami
PLATFORM_TYPE="LINUX" AUTHOR='SFL' DIVISION='Internal' python3 build-plugin.py --projects='GreenScreen'"
```
Without using Docker :
`PLATFORM_TYPE="LINUX" AUTHOR='SFL' DIVISION='Internal' python3 build-plugin.py --projects='GreenScreen'`
- Android
Using Docker (recommended):
Change the android ABI between `arm64-v8a`, `armeabi-v7a` and `x86_64`.
`arm64-v8a` is by far the most common ABI.
```bash
docker run -t --rm
-v $(pwd):/home/gradle/plugins:rw
-w /home/gradle
-e BATCH_MODE=1
jami-plugins-android /bin/bash -c "
export DAEMON=/home/gradle/plugins
cd ./plugins
PLATFORM_TYPE="ANDROID" ANDROID_ABI="arm64-v8a" python3 build-plugin.py --projects=GreenScreen --distribution=android
```
Without using Docker :
```bash
export JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk-amd64/jre
export ANDROID_HOME=/home/${USER}/Android/Sdk
@ -246,7 +281,7 @@ export ANDROID_SDK=${ANDROID_HOME}
export ANDROID_NDK=${ANDROID_HOME}/ndk/21.1.6352462
export ANDROID_NDK_ROOT=${ANDROID_NDK}
export PATH=${PATH}:${ANDROID_HOME}/tools:${ANDROID_HOME}/platform-tools:${ANDROID_NDK}:${JAVA_HOME}/bin
ANDROID_ABI="<android-architecture-separate-by-space>" python3 build-plugin.py --projects=GreenScreen --distribution=android
PLATFORM_TYPE="ANDROID" ANDROID_ABI="<android-architecture-separate-by-space>" python3 build-plugin.py --projects=GreenScreen --distribution=android
```
The GreenScreen.jpl file will be available under `<build/>`.