unique step for dependencies installation

This commit is contained in:
alemuntoni 2022-11-24 11:58:34 +01:00
parent 545b28772b
commit 73093b4daf
4 changed files with 70 additions and 23 deletions

View File

@ -26,22 +26,10 @@ jobs:
with:
cache: true
version: ${{ env.QT_VERSION }}
- name: Install Linux dependencies
if: runner.os == 'Linux'
run: |
bash scripts/${{ runner.os }}/0_setup_env.sh --dont_install_qt --dont_install_cgal_and_boost
#needed by qt 5.15 on linux
sudo apt-get install libxcb-icccm4-dev libxcb-image0-dev libxcb-keysyms1-dev libxcb-render-util0-dev libxcb-xinerama0-dev
- name: Install macOS dependencies
if: runner.os == 'macOS'
run: |
brew install llvm libomp cgal xerces-c
npm install -g appdmg
- name: Install Windows dependencies
if: runner.os == 'Windows'
- name: Install dependencies
shell: bash
run: |
choco install ccache ninja wget nsis
bash scripts/${{ runner.os }}/0_setup_env.sh --dont_install_qt --dont_install_cgal_and_boost
- name: Setup env variables
id: envs
shell: bash

View File

@ -29,16 +29,18 @@ sudo apt-get update
echo "=== installing mesa packages..."
sudo apt-get install -y mesa-common-dev libglu1-mesa-dev
echo "=== installing cmake, patchelf, gmp, mpfr and xcerces-c..."
sudo apt-get install -y cmake patchelf libgmp-dev libmpfr-dev libxerces-c-dev
if [ "$DONT_INSTALL_QT" = false ] ; then
echo "=== installing qt packages..."
sudo apt-get install -y qt5-default qttools5-dev-tools qtdeclarative5-dev
else
echo "=== jumping installation of qt packages..."
# libraries that qt requires in any case
sudo apt-get install -y libxcb-icccm4-dev libxcb-image0-dev libxcb-keysyms1-dev libxcb-render-util0-dev libxcb-xinerama0-dev
fi
echo "=== installing cmake, patchelf, gmp, mpfr and xcerces-c..."
sudo apt-get install -y cmake patchelf libgmp-dev libmpfr-dev libxerces-c-dev
# possibility to use always system libraries starting from ubuntu 20.04, since cgal is header only
if [ "$DONT_INSTALL_CGAL_BOOST" = false ] ; then
echo "=== installing cgal and boost..."

View File

@ -0,0 +1,33 @@
#!/bin/bash
# this is a script shell sets up a Windows environment where
# MeshLab can be compiled, deployed and packaged.
#
# Run this script if you never installed any of the MeshLab dependencies.
#
# Requires: choco
DONT_INSTALL_QT=false
#checking for parameters
for i in "$@"
do
case $i in
--dont_install_qt)
DONT_INSTALL_QT=true
shift # past argument=value
;;
*)
# unknown option
;;
esac
done
choco install ccache ninja wget nsis
if [ "$DONT_INSTALL_QT" = false ] ; then
echo "=== installing qt packages..."
choco install qt5-default
else
echo "=== jumping installation of qt packages..."
fi

View File

@ -6,11 +6,35 @@
#
# Requires: homebrew
brew install libomp qt cgal xerces-c
DONT_INSTALL_QT=false
#checking for parameters
for i in "$@"
do
case $i in
--dont_install_qt)
DONT_INSTALL_QT=true
shift # past argument=value
;;
*)
# unknown option
;;
esac
done
brew install cmake libomp cgal xerces-c
npm install -g appdmg
echo "export QTDIR=/usr/local/opt/qt" >> ~/.bash_profile
echo "export PATH=$QTDIR/bin:$PATH" >> ~/.bash_profile
echo "export LD_LIBRARY_PATH=/usr/local/opt/qt/lib:$LD_LIBRARY_PATH" >> ~/.bash_profile
echo "export PKG_CONFIG_PATH=/usr/local/opt/qt/lib:$PKG_CONFIG_PATH" >> ~/.bash_profile
. ~/.bash_profile
if [ "$DONT_INSTALL_QT" = false ] ; then
echo "=== installing qt packages..."
brew install qt
echo "export QTDIR=/usr/local/opt/qt" >> ~/.bash_profile
echo "export PATH=$QTDIR/bin:$PATH" >> ~/.bash_profile
echo "export LD_LIBRARY_PATH=/usr/local/opt/qt/lib:$LD_LIBRARY_PATH" >> ~/.bash_profile
echo "export PKG_CONFIG_PATH=/usr/local/opt/qt/lib:$PKG_CONFIG_PATH" >> ~/.bash_profile
. ~/.bash_profile
else
echo "=== jumping installation of qt packages..."
fi