[cmake] WITH_WEBVIEW new defaults
* Enable by default now * Use a config file to detect if it is enabled
This commit is contained in:
parent
10ea529f70
commit
0e458c8c2c
@ -1,10 +1,7 @@
|
|||||||
option(WITH_WEBVIEW "Build with WebView support for AAD login popup browser" OFF)
|
option(WITH_WEBVIEW "Build with WebView support for AAD login popup browser" ON)
|
||||||
if (WITH_WEBVIEW)
|
if (WITH_WEBVIEW)
|
||||||
option(WITH_WEBVIEW_QT "Build with QtWebEngine support for AAD login broweser popup" OFF)
|
option(WITH_WEBVIEW_QT "Build with QtWebEngine support for AAD login broweser popup" OFF)
|
||||||
|
|
||||||
set(DEFINITIONS
|
|
||||||
-DWITH_WEBVIEW
|
|
||||||
)
|
|
||||||
set(SRCS
|
set(SRCS
|
||||||
sdl_webview.hpp
|
sdl_webview.hpp
|
||||||
webview_impl.hpp
|
webview_impl.hpp
|
||||||
@ -56,9 +53,12 @@ else()
|
|||||||
)
|
)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
configure_file(sdl_config.hpp.in sdl_config.hpp @ONLY)
|
||||||
|
|
||||||
add_library(aad-view STATIC
|
add_library(aad-view STATIC
|
||||||
${SRCS}
|
${SRCS}
|
||||||
)
|
)
|
||||||
|
target_include_directories(aad-view PUBLIC ${CMAKE_CURRENT_BINARY_DIR})
|
||||||
target_link_libraries(aad-view
|
target_link_libraries(aad-view
|
||||||
PRIVATE
|
PRIVATE
|
||||||
${LIBS}
|
${LIBS}
|
||||||
|
3
client/SDL/aad/sdl_config.hpp.in
Normal file
3
client/SDL/aad/sdl_config.hpp.in
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#cmakedefine WITH_WEBVIEW
|
@ -21,6 +21,9 @@
|
|||||||
|
|
||||||
#include <freerdp/freerdp.h>
|
#include <freerdp/freerdp.h>
|
||||||
|
|
||||||
|
#include <sdl_config.hpp>
|
||||||
|
|
||||||
|
#if defined(WITH_WEBVIEW)
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
extern "C"
|
extern "C"
|
||||||
{
|
{
|
||||||
@ -32,3 +35,4 @@ extern "C"
|
|||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
#endif
|
||||||
|
@ -56,9 +56,7 @@
|
|||||||
#include "sdl_pointer.hpp"
|
#include "sdl_pointer.hpp"
|
||||||
#include "dialogs/sdl_dialogs.hpp"
|
#include "dialogs/sdl_dialogs.hpp"
|
||||||
|
|
||||||
#ifdef WITH_WEBVIEW
|
|
||||||
#include "aad/sdl_webview.hpp"
|
#include "aad/sdl_webview.hpp"
|
||||||
#endif
|
|
||||||
|
|
||||||
#define SDL_TAG CLIENT_TAG("SDL")
|
#define SDL_TAG CLIENT_TAG("SDL")
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user