Fix wxWidgets 3.2 not being found on windows

This commit is contained in:
tamasmeszaros 2022-07-26 11:14:28 +02:00 committed by Lukas Matena
parent 25b2ff5fb8
commit d1c92ded7c
2 changed files with 9 additions and 5 deletions

View File

@ -58,18 +58,24 @@ if (SLIC3R_GUI)
"Hint: On Linux you can set -DSLIC3R_WX_STABLE=1 to use wxWidgets 3.0\n")
endif ()
endif ()
include(${wxWidgets_USE_FILE})
else ()
find_package(wxWidgets 3.1 REQUIRED COMPONENTS html adv gl core base)
find_package(wxWidgets 3.1 COMPONENTS html adv gl core base)
if (wxWidgets_NOTFOUND)
find_package(wxWidgets 3.2 CONFIG REQUIRED COMPONENTS html adv gl core base)
else ()
include(${wxWidgets_USE_FILE})
endif ()
endif ()
if(UNIX)
message(STATUS "wx-config path: ${wxWidgets_CONFIG_EXECUTABLE}")
endif()
include(${wxWidgets_USE_FILE})
find_package(JPEG QUIET)
find_package(TIFF QUIET)
find_package(NanoSVG REQUIRED)
string(REGEX MATCH "wxpng" WX_PNG_BUILTIN ${wxWidgets_LIBRARIES})
if (PNG_FOUND AND NOT WX_PNG_BUILTIN)

View File

@ -257,8 +257,6 @@ set(SLIC3R_GUI_SOURCES
Utils/WinRegistry.hpp
)
find_package(NanoSVG REQUIRED)
if (APPLE)
list(APPEND SLIC3R_GUI_SOURCES
Utils/RetinaHelperImpl.mm