File tree Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -69,7 +69,7 @@ elseif(UNIX AND NOT APPLE) # Note: also android
69
69
set (CPPREST_HTTP_CLIENT_IMPL asio CACHE STRING "Internal use." )
70
70
set (CPPREST_HTTP_LISTENER_IMPL asio CACHE STRING "Internal use." )
71
71
elseif (WINDOWS_PHONE OR WINDOWS_STORE )
72
- set (CPPREST_PPLX_IMPL win CACHE STRING "Internal use." )
72
+ set (CPPREST_PPLX_IMPL winrt CACHE STRING "Internal use." )
73
73
set (CPPREST_WEBSOCKETS_IMPL winrt CACHE STRING "Internal use." )
74
74
set (CPPREST_FILEIO_IMPL winrt CACHE STRING "Internal use." )
75
75
set (CPPREST_HTTP_CLIENT_IMPL winrt CACHE STRING "Internal use." )
@@ -115,7 +115,12 @@ elseif(ANDROID)
115
115
)
116
116
elseif (UNIX ) # This includes OSX
117
117
elseif (WIN32 )
118
- add_definitions (-DUNICODE -D_UNICODE -D_WIN32_WINNT=0x0600 -DWIN32 -D_SCL_SECURE_NO_WARNINGS )
118
+ add_definitions (-DUNICODE -D_UNICODE -DWIN32 -D_SCL_SECURE_NO_WARNINGS )
119
+ if (CMAKE_SYSTEM_NAME STREQUAL "WindowsStore" )
120
+ add_definitions (-D_WIN32_WINNT=0x0A00 )
121
+ else ()
122
+ add_definitions (-D_WIN32_WINNT=0x0600 )
123
+ endif ()
119
124
120
125
if (NOT BUILD_SHARED_LIBS )
121
126
# This causes cmake to not link the test libraries separately, but instead hold onto their object files.
Original file line number Diff line number Diff line change @@ -80,6 +80,11 @@ elseif(CPPREST_PPLX_IMPL STREQUAL "winpplx")
80
80
pplx/threadpool.cpp
81
81
pplx/pplxwin.cpp
82
82
)
83
+ elseif (CPPREST_PPLX_IMPL STREQUAL "winrt" )
84
+ list (APPEND SOURCES
85
+ pplx/pplxwin.cpp
86
+ )
87
+ list (FILTER HEADERS_PPLX EXCLUDE REGEX "threadpool\\ .h" )
83
88
endif ()
84
89
85
90
# Http client component
@@ -186,6 +191,7 @@ if(CPPREST_PPLX_IMPL STREQUAL "apple")
186
191
target_link_libraries (cpprest PRIVATE ${COREFOUNDATION} ${SECURITY} )
187
192
elseif (CPPREST_PPLX_IMPL STREQUAL "linux" )
188
193
elseif (CPPREST_PPLX_IMPL STREQUAL "win" )
194
+ elseif (CPPREST_PPLX_IMPL STREQUAL "winrt" )
189
195
elseif (CPPREST_PPLX_IMPL STREQUAL "winpplx" )
190
196
target_compile_definitions (cpprest PUBLIC -DCPPREST_FORCE_PPLX=1 )
191
197
else ()
You can’t perform that action at this time.
0 commit comments