1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/jitsi_ynh.git synced 2024-09-03 19:35:57 +02:00

add install support for armv7l

i can not test for armv7h
This commit is contained in:
rosbeef andino 2022-04-12 23:14:43 -04:00 committed by GitHub
parent 63248b3407
commit aa06cfa0a3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -126,6 +126,46 @@ gpasswd --add www-data $app
#=================================================
ynh_script_progression --message="Setting up source files..."
if [ $(uname -m) == "armv7l" ]
then
# prepare openjdk8 installation
mkdir /tmp/jitsi-install/
cd /tmp/jitsi-install/
#install openjdk 8 because javah is used by jitsi and not supported in higher versions
wget http://security.debian.org/debian-security/pool/updates/main/o/openjdk-8/openjdk-8-jre_8u322-b06-1~deb9u1_armhf.deb
wget http://security.debian.org/debian-security/pool/updates/main/o/openjdk-8/openjdk-8-jre-headless_8u322-b06-1~deb9u1_armhf.deb
wget http://security.debian.org/debian-security/pool/updates/main/o/openjdk-8/openjdk-8-jdk_8u322-b06-1~deb9u1_armhf.deb
wget http://security.debian.org/debian-security/pool/updates/main/o/openjdk-8/openjdk-8-jdk-headless_8u322-b06-1~deb9u1_armhf.deb
sudo apt install \
./openjdk-8-jre_8u322-b06-1~deb9u1_armhf.deb \
./openjdk-8-jre-headless_8u322-b06-1~deb9u1_armhf.deb \
./openjdk-8-jdk_8u322-b06-1~deb9u1_armhf.deb \
./openjdk-8-jdk-headless_8u322-b06-1~deb9u1_armhf.deb
# ser openjdk as default
sudo update-alternatives --set java /usr/lib/jvm/java-8-openjdk-armhf/jre/bin/java
# stop related services if exist
sudo systemctl stop prosody jitsi-videobridge jitsi-jicofo
# prepare jniwrapper comppilation
export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-armhf
sudo apt update
sudo apt install automake autoconf build-essential libtool git maven m4
git clone https://github.com/sctplab/usrsctp.git
git clone https://github.com/jitsi/jitsi-sctp
mv ./usrsctp ./jitsi-sctp/usrsctp/
cd ./jitsi-sctp
# needed to make compile works
mkdir -p ./jniwrapper/native/src/main/resources/lib/linux-arm/
# compile
mvn package -DbuildSctp -DbuildNativeWrapper -DdeployNewJnilib -DskipTests
mvn package
fi
ynh_app_setting_set --app=$app --key=final_path --value=$final_path
# Download, check integrity, uncompress and patch the source from app.src
declare -A packages
@ -146,6 +186,15 @@ do
ynh_secure_remove --file="$final_path/${package}_temp"
done
if [ $(uname -m) == "armv7l" ]
then
# rm official jniwrapper to copy
rm "$final_path/jitsi-videobridge/lib/jniwrapper-native-1.0-*"
cp "./jniwrapper/native/target/jniwrapper-native-1.0-SNAPSHOT.jar" "$final_path/jitsi-videobridge/lib/jniwrapper-native-1.0-SNAPSHOT.jar"
chmod 640 jniwrapper-native-1.0-SNAPSHOT.jar
chown $app:$app jniwrapper-native-1.0-SNAPSHOT.jar
fi
ynh_setup_source --dest_dir="$final_path/jitsi-meet-prosody" --source_id=mod_auth_ldap
chmod 750 "$final_path"