Skip to content

Commit

Permalink
Merge pull request #1036 from MRPT/fix/appveyor-fail
Browse files Browse the repository at this point in the history
Fix/appveyor fail
  • Loading branch information
jlblancoc authored Mar 25, 2020
2 parents e36bbde + 0db708c commit 3a26b90
Show file tree
Hide file tree
Showing 5 changed files with 47 additions and 5 deletions.
2 changes: 1 addition & 1 deletion 3rdparty/nanogui
Submodule nanogui updated 1 files
+15 −0 CMakeLists.txt
2 changes: 2 additions & 0 deletions apps/robot-map-gui/gui/observationTree/CNode.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
*/
#include "CNode.h"

#include <stdexcept>

CNode::CNode(CNode* parent) : m_parent(parent) {}
const CNode* CNode::parentItem() const { return m_parent; }
void CNode::addNewChild()
Expand Down
35 changes: 31 additions & 4 deletions appveyor.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# version format
version: 1.9.9-{branch}-build{build}

os: Visual Studio 2017
os: Visual Studio 2019

clone_folder: c:\projects\mrpt

Expand All @@ -14,12 +14,39 @@ environment:
build:
project: c:\projects\mrpt\build\MRPT.sln

#install:
# - set PATH=%PATH%;%QTDIR%\bin
install:
# Install OpenCV
- choco upgrade chocolatey
- choco install opencv -y
# - tree c:\tools\opencv\build /F
- set OPENCVDIR=C:\tools\opencv\build\
- set PATH=%PATH%;%OPENCVDIR%\bin;%OPENCVDIR%\x64\vc15\bin
# Install wxWidgets
- cd c:\
- ps: Start-FileDownload 'https://github.com/wxWidgets/wxWidgets/releases/download/v3.1.3/wxMSW-3.1.3_vc14x_x64_Dev.7z'
- ps: Start-FileDownload 'https://github.com/wxWidgets/wxWidgets/releases/download/v3.1.3/wxWidgets-3.1.3-headers.7z'
- ps: Start-FileDownload 'https://github.com/wxWidgets/wxWidgets/releases/download/v3.1.3/wxMSW-3.1.3_vc14x_x64_ReleaseDLL.7z'
- 7z x wxMSW-3.1.3_vc14x_x64_Dev.7z -oc:\wxWidgets -aoa
- 7z x wxWidgets-3.1.3-headers.7z -oc:\wxWidgets -aoa
- 7z x wxMSW-3.1.3_vc14x_x64_ReleaseDLL.7z -oc:\wxWidgets -aoa
- set WXWIDGETSDIR=C:\wxWidgets
- set WXWIDGETSLIBDIR=%WXWIDGETSDIR%\lib\vc14x_x64_dll\
# - tree %WXWIDGETSDIR% /F
- set PATH=%PATH%;%WXWIDGETSLIBDIR%
# Qt:
- set QTDIR=C:\Qt\5.14.1\msvc2017_64
# - dir %QTDIR%\bin
- set PATH=%PATH%;%QTDIR%\bin
- PATH

before_build:
- cd c:\projects\mrpt
- git submodule update --init --recursive
- mkdir build
- cd build
- cmake -G "Visual Studio 15 2017 Win64" -DEIGEN_USE_EMBEDDED_VERSION=ON -DBUILD_ASSIMP=OFF ..
- set VERBOSE=1 # for MRPT cmake scripts to show more info
- cmake -G "Visual Studio 16 2019" -DEIGEN_USE_EMBEDDED_VERSION=ON -DBUILD_ASSIMP=OFF -DOpenCV_DIR=%OPENCVDIR% -DwxWidgets_ROOT_DIR=%WXWIDGETSDIR% -DwxWidgets_LIB_DIR=%WXWIDGETSLIBDIR% ..

on_failure:
- ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))

9 changes: 9 additions & 0 deletions cmakemodules/script_nanogui.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,14 @@ endif()

add_subdirectory(3rdparty/nanogui)

set_target_properties(mrpt-nanogui PROPERTIES FOLDER "3rd party")
if (TARGET glfw)
set_target_properties(glfw PROPERTIES FOLDER "3rd party")
endif()
if (TARGET glfw_objects)
set_target_properties(glfw_objects PROPERTIES FOLDER "3rd party")
endif()


set(CMAKE_MRPT_HAS_NANOGUI 1)
set(CMAKE_MRPT_HAS_NANOGUI_SYSTEM 0)
4 changes: 4 additions & 0 deletions libs/gui/src/CDisplayWindowGUI.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,11 @@ CDisplayWindowGUI::CDisplayWindowGUI(
images.height = 64;
images.pixels = default_mrpt_glfw_icon();

// glfwSetWindowIcon added in glfw 3.2
#if GLFW_VERSION_MAJOR > 3 || \
(GLFW_VERSION_MAJOR == 3 && GLFW_VERSION_MINOR >= 2)
glfwSetWindowIcon(screen()->glfwWindow(), 1, &images);
#endif
}

CDisplayWindowGUI::~CDisplayWindowGUI()
Expand Down

0 comments on commit 3a26b90

Please sign in to comment.