Update install.sh

This commit is contained in:
midoks
2023-09-29 23:38:13 +08:00
parent 0b712c7242
commit dfa53c4c4c
+9 -1
View File
@@ -39,9 +39,17 @@ Install_App()
fi
INSTALL_CMD=cmake
# check cmake version
CMAKE_VERSION=`cmake -version | grep version | awk '{print $3}' | awk -F '.' '{print $1}'`
if [ "$CMAKE_VERSION" -eq "2" ];then
mkdir -p /var/log/mariadb
touch /var/log/mariadb/mariadb.log
INSTALL_CMD=cmake3
fi
mkdir -p $serverPath/mosquitto
cd mosquitto-${VERSION} && cmake CMakeLists.txt -DCMAKE_INSTALL_PREFIX=$serverPath/mosquitto && make install
cd mosquitto-${VERSION} && ${INSTALL_CMD} CMakeLists.txt -DCMAKE_INSTALL_PREFIX=$serverPath/mosquitto && make install
if [ -d $serverPath/mosquitto ];then