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
6969  set (CPPREST_HTTP_CLIENT_IMPL asio CACHE  STRING  "Internal use." )
7070  set (CPPREST_HTTP_LISTENER_IMPL asio CACHE  STRING  "Internal use." )
7171elseif (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." )
7373  set (CPPREST_WEBSOCKETS_IMPL winrt CACHE  STRING  "Internal use." )
7474  set (CPPREST_FILEIO_IMPL winrt CACHE  STRING  "Internal use." )
7575  set (CPPREST_HTTP_CLIENT_IMPL winrt CACHE  STRING  "Internal use." )
@@ -115,7 +115,12 @@ elseif(ANDROID)
115115    )
116116elseif (UNIX ) # This includes OSX 
117117elseif (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 ()
119124
120125  if (NOT  BUILD_SHARED_LIBS )
121126    # 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")
8080    pplx/threadpool.cpp
8181    pplx/pplxwin.cpp
8282  )
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" )
8388endif ()
8489
8590# Http client component 
@@ -186,6 +191,7 @@ if(CPPREST_PPLX_IMPL STREQUAL "apple")
186191  target_link_libraries (cpprest PRIVATE  ${COREFOUNDATION}  ${SECURITY} )
187192elseif (CPPREST_PPLX_IMPL STREQUAL  "linux" )
188193elseif (CPPREST_PPLX_IMPL STREQUAL  "win" )
194+ elseif (CPPREST_PPLX_IMPL STREQUAL  "winrt" )
189195elseif (CPPREST_PPLX_IMPL STREQUAL  "winpplx" )
190196  target_compile_definitions (cpprest PUBLIC  -DCPPREST_FORCE_PPLX=1)
191197else ()
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments