From ad54266395a46cb226637cbd8deb3a68ebfaf539 Mon Sep 17 00:00:00 2001 From: bubnikv Date: Wed, 19 Sep 2018 18:05:58 +0200 Subject: [PATCH] Fixed GUI build --- src/CMakeLists.txt | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index cf37a82c91..fcf7c17dcc 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -43,6 +43,13 @@ else() endif() add_subdirectory(libslic3r) + +if (SLIC3R_GUI) + message(STATUS "WXWIN environment set to: $ENV{WXWIN}") + find_package(wxWidgets REQUIRED COMPONENTS base core adv html gl) + include(${wxWidgets_USE_FILE}) +endif() + add_subdirectory(slic3r) # Create a slic3r executable @@ -64,10 +71,6 @@ endif () # Add the Slic3r GUI library, libcurl, OpenGL and GLU libraries. if (SLIC3R_GUI) - message(STATUS "WXWIN environment set to: $ENV{WXWIN}") - find_package(wxWidgets REQUIRED COMPONENTS base core adv html gl) - include(${wxWidgets_USE_FILE}) - target_link_libraries(slic3r libslic3r_gui ${wxWidgets_LIBRARIES} ${CURL_LIBRARIES}) # Configure libcurl & OpenSSL