fix missing windeployqt in windows workflows

This commit is contained in:
alemuntoni 2022-06-06 14:09:39 +02:00
parent 09f2a009c3
commit 01713dbd37
8 changed files with 98 additions and 27 deletions

View File

@ -9,6 +9,8 @@ on:
required: true
default: 'YYYY.MM'
env:
QT_VERSION: 5.15.2
jobs:
update_ml_version:
@ -39,8 +41,17 @@ jobs:
with:
ref: main
submodules: recursive
- name: Cache Qt
id: cache-qt
uses: actions/cache@v1
with:
path: ../Qt
key: ${{ runner.os }}-QtCache-${{ env.QT_VERSION }}
- name: Install Qt
uses: jurplel/install-qt-action@v2
with:
path: ../Qt
key: ${{ runner.os }}-QtCache-${{ env.QT_VERSION }}
- name: Install dependencies
run: |
bash scripts/${{ runner.os }}/0_setup_env_ubuntu.sh --dont_install_qt --dowload_cgal_and_boost_src
@ -91,8 +102,17 @@ jobs:
run: |
brew install libomp cgal xerces-c
npm install -g appdmg
- name: Cache Qt
id: cache-qt
uses: actions/cache@v1
with:
path: ../Qt
key: ${{ runner.os }}-QtCache-${{ env.QT_VERSION }}
- name: Install Qt
uses: jurplel/install-qt-action@v2
with:
path: ../Qt
key: ${{ runner.os }}-QtCache-${{ env.QT_VERSION }}
- name: Setup env variables
id: envs
shell: bash
@ -158,8 +178,17 @@ jobs:
submodules: recursive
- name: Setup MSVC
uses: ilammy/msvc-dev-cmd@v1
- name: Cache Qt
id: cache-qt
uses: actions/cache@v1
with:
path: ../Qt
key: ${{ runner.os }}-QtCache-${{ env.QT_VERSION }}
- name: Install Qt
uses: jurplel/install-qt-action@v2
with:
path: ../Qt
key: ${{ runner.os }}-QtCache-${{ env.QT_VERSION }}
- name: Setup env variables
shell: bash
id: envs
@ -172,7 +201,7 @@ jobs:
echo "VCINSTALLDIR=C:\Program Files (x86)\Microsoft Visual Studio\2022\Enterprise\VC" >> $GITHUB_ENV
- name: Install wget
run: |
$env:PATH = "C:\msys64\mingw64\bin;C:\msys64\usr\bin"
$env:PATH = "${{ env.PATH }};C:\msys64\mingw64\bin;C:\msys64\usr\bin"
pacman.exe -S --noconfirm --noprogressbar wget unzip
- name: Set Certificate
run: |
@ -193,7 +222,7 @@ jobs:
- name: Deploy
shell: C:\shells\msys2bash.cmd {0}
run: |
bash scripts/${{ runner.os }}/2_deploy.sh
bash scripts/${{ runner.os }}/2_deploy.sh -qt=${{ env.Qt5_DIR }}
- name: NSIS script
shell: bash
run: |

View File

@ -3,6 +3,9 @@ name: Linux
on:
[push, pull_request]
env:
QT_VERSION: 5.15.2
jobs:
linux_build:
name: Build MeshLab (Linux)
@ -15,8 +18,17 @@ jobs:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Cache Qt
id: cache-qt
uses: actions/cache@v1
with:
path: ../Qt
key: ${{ runner.os }}-QtCache-${{ env.QT_VERSION }}
- name: Install Qt
uses: jurplel/install-qt-action@v2
with:
cached: ${{ steps.cache-qt.outputs.cache-hit }}
version: ${{ env.QT_VERSION }}
- name: Install dependencies
run: |
bash scripts/${{ runner.os }}/0_setup_env_ubuntu.sh --dont_install_qt --dowload_cgal_and_boost_src

View File

@ -3,6 +3,9 @@ name: MacOS
on:
[push, pull_request]
env:
QT_VERSION: 5.15.2
jobs:
macos_build:
name: Build MeshLab (MacOS)
@ -19,8 +22,17 @@ jobs:
run: |
brew install libomp cgal xerces-c
npm install -g appdmg
- name: Cache Qt
id: cache-qt
uses: actions/cache@v1
with:
path: ../Qt
key: ${{ runner.os }}-QtCache-${{ env.QT_VERSION }}
- name: Install Qt
uses: jurplel/install-qt-action@v2
with:
cached: ${{ steps.cache-qt.outputs.cache-hit }}
version: ${{ env.QT_VERSION }}
- name: Setup env variables
id: envs
shell: bash

View File

@ -2,6 +2,9 @@ name: Windows
on: [push, pull_request]
env:
QT_VERSION: 5.15.2
jobs:
windows_build:
name: Build MeshLab (Windows)
@ -16,8 +19,17 @@ jobs:
submodules: recursive
- name: Setup MSVC
uses: ilammy/msvc-dev-cmd@v1
- name: Cache Qt
id: cache-qt
uses: actions/cache@v1
with:
path: ../Qt
key: ${{ runner.os }}-QtCache-${{ env.QT_VERSION }}
- name: Install Qt
uses: jurplel/install-qt-action@v2
with:
cached: ${{ steps.cache-qt.outputs.cache-hit }}
version: ${{ env.QT_VERSION }}
- name: Setup env variables
shell: bash
id: envs
@ -30,7 +42,7 @@ jobs:
echo "VCINSTALLDIR=C:\Program Files (x86)\Microsoft Visual Studio\2022\Enterprise\VC" >> $GITHUB_ENV
- name: Install wget
run: |
$env:PATH = "C:\msys64\mingw64\bin;C:\msys64\usr\bin"
$env:PATH = "${{ env.PATH }};C:\msys64\mingw64\bin;C:\msys64\usr\bin"
pacman.exe -S --noconfirm --noprogressbar wget unzip
- name: Download external libraries
shell: C:\shells\msys2bash.cmd {0}
@ -43,7 +55,7 @@ jobs:
- name: Deploy
shell: C:\shells\msys2bash.cmd {0}
run: |
bash scripts/${{ runner.os }}/2_deploy.sh
bash scripts/${{ runner.os }}/2_deploy.sh -qt=${{ env.Qt5_DIR }}
- name: NSIS script
shell: bash
run: |

View File

@ -18,6 +18,7 @@ BUILD_PATH=$SOURCE_PATH/../build
INSTALL_PATH=$SOURCE_PATH/../install
DOUBLE_PRECISION_OPTION=""
NIGHTLY_OPTION=""
QT_DIR=""
#check parameters
for i in "$@"
@ -39,6 +40,10 @@ case $i in
NIGHTLY_OPTION="-DMESHLAB_IS_NIGHTLY_VERSION=ON"
shift # past argument=value
;;
-qt=*|--qt_dir=*)
QT_DIR=${i#*=}
shift # past argument=value
;;
*)
# unknown option
;;
@ -61,6 +66,11 @@ BUILD_PATH=$(realpath $BUILD_PATH)
INSTALL_PATH=$(realpath $INSTALL_PATH)
cd $BUILD_PATH
if [ ! -z "$QT_DIR" ]
then
export Qt5_DIR=$QT_DIR
fi
cmake -GNinja -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=$INSTALL_PATH $DOUBLE_PRECISION_OPTION $NIGHTLY_OPTION $SOURCE_PATH
ninja
ninja install

View File

@ -9,6 +9,7 @@
SCRIPTS_PATH="$(dirname "$(realpath "$0")")"
RESOURCES_PATH=$SCRIPTS_PATH/../../resources
INSTALL_PATH=$SCRIPTS_PATH/../../install
QT_DIR=""
#checking for parameters
for i in "$@"
@ -18,15 +19,19 @@ case $i in
INSTALL_PATH="${i#*=}"
shift # past argument=value
;;
-qt=*|--qt_dir=*)
QT_DIR=${i#*=}/bin/
shift # past argument=value
;;
*)
# unknown option
;;
esac
done
windeployqt $INSTALL_PATH/meshlab.exe
${QT_DIR}windeployqt $INSTALL_PATH/meshlab.exe
windeployqt $INSTALL_PATH/plugins/filter_sketchfab.dll --libdir $INSTALL_PATH/
${QT_DIR}windeployqt $INSTALL_PATH/plugins/filter_sketchfab.dll --libdir $INSTALL_PATH/
mv $INSTALL_PATH/lib/meshlab/IFX* $INSTALL_PATH
cp $INSTALL_PATH/IFXCoreStatic.lib $INSTALL_PATH/lib/meshlab/
@ -38,6 +43,3 @@ then
echo "Downloading vc_redist because it was missing..."
wget https://aka.ms/vs/17/release/vc_redist.x64.exe --output-document=$INSTALL_PATH/vc_redist.x64.exe
fi
#at this point, distrib folder contains all the files necessary to execute meshlab
echo "$INSTALL_PATH is now a self contained meshlab application"

View File

@ -20,6 +20,7 @@ INSTALL_PATH=$SOURCE_PATH/../install
CORES="-j4"
DOUBLE_PRECISION_OPTION=""
NIGHTLY_OPTION=""
QT_DIR=""
#check parameters
for i in "$@"
@ -45,6 +46,10 @@ case $i in
NIGHTLY_OPTION="-DMESHLAB_IS_NIGHTLY_VERSION=ON"
shift # past argument=value
;;
-qt=*|--qt_dir=*)
QT_DIR=${i#*=}
shift # past argument=value
;;
*)
# unknown option
;;

View File

@ -11,8 +11,9 @@
# After running this script, $INSTALL_PATH/meshlab.app will be a portable meshlab application.
SCRIPTS_PATH=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
INSTALL_PATH=$SCRIPTS_PATH/../../install
APPNAME="meshlab.app"
QT_DIR=""
#checking for parameters
for i in "$@"
@ -22,29 +23,17 @@ case $i in
INSTALL_PATH="${i#*=}"
shift # past argument=value
;;
-qt=*|--qt_dir=*)
QT_DIR=${i#*=}/bin/
shift # past argument=value
;;
*)
# unknown option
;;
esac
done
echo "Hopefully I should find " $INSTALL_PATH/$APPNAME
if ! [ -e $INSTALL_PATH/$APPNAME -a -d $INSTALL_PATH/$APPNAME ]
then
echo "Started in the wrong dir: I have not found the meshlab.app"
exit -1
fi
if [ -e $QTDIR/bin/macdeployqt ]
then
MACDEPLOYQT_EXE=$QTDIR/bin/macdeployqt
else
MACDEPLOYQT_EXE=macdeployqt
fi
${MACDEPLOYQT_EXE} $INSTALL_PATH/$APPNAME \
${QT_DIR}macdeployqt $INSTALL_PATH/$APPNAME \
-executable=$INSTALL_PATH/$APPNAME/Contents/PlugIns/libedit_align.so \
-executable=$INSTALL_PATH/$APPNAME/Contents/PlugIns/libfilter_csg.so \
-executable=$INSTALL_PATH/$APPNAME/Contents/PlugIns/libfilter_isoparametrization.so \