File tree Expand file tree Collapse file tree 4 files changed +37
-1
lines changed Expand file tree Collapse file tree 4 files changed +37
-1
lines changed Original file line number Diff line number Diff line change @@ -15,6 +15,10 @@ project(DirectXMesh
15
15
HOMEPAGE_URL "https://go.microsoft.com/fwlink/?LinkID=324981"
16
16
LANGUAGES CXX )
17
17
18
+ if (DEFINED XBOX_CONSOLE_TARGET )
19
+ set (CMAKE_CXX_STANDARD_LIBRARIES "" )
20
+ endif ()
21
+
18
22
option (BUILD_TOOLS "Build meshconvert" ON )
19
23
20
24
option (BUILD_SHARED_LIBS "Build DirectXMesh as a shared library" OFF )
@@ -83,6 +87,10 @@ if(WIN32 AND BUILD_SHARED_LIBS)
83
87
84
88
target_compile_definitions (${PROJECT_NAME} PRIVATE DIRECTX_MESH_EXPORT )
85
89
target_compile_definitions (${PROJECT_NAME} INTERFACE DIRECTX_MESH_IMPORT )
90
+
91
+ if (XBOX_CONSOLE_TARGET MATCHES "scarlett|xboxone" )
92
+ target_link_libraries (${PROJECT_NAME} PRIVATE xgameplatform.lib )
93
+ endif ()
86
94
else ()
87
95
add_library (${PROJECT_NAME} ${LIBRARY_SOURCES} ${LIBRARY_HEADERS} )
88
96
endif ()
Original file line number Diff line number Diff line change @@ -203,12 +203,14 @@ if(DEFINED XBOX_CONSOLE_TARGET)
203
203
message (FATAL_ERROR "Legacy Xbox One XDK required to build for Durango." )
204
204
endif ()
205
205
list (APPEND COMPILER_DEFINES WINAPI_FAMILY=WINAPI_FAMILY_TV_TITLE _XBOX_ONE _TITLE MONOLITHIC=1 )
206
+ list (APPEND LINKER_SWITCHES /NODEFAULTLIB:kernel32.lib /NODEFAULTLIB:ole32.lib /NODEFAULTLIB:oldnames.lib )
206
207
else ()
207
208
CHECK_INCLUDE_FILE_CXX (gxdk.h GXDK_HEADER )
208
209
if (NOT GXDK_HEADER )
209
210
message (FATAL_ERROR "Microsoft GDK with Xbox Extensions required to build for Xbox. See https://aka.ms/gdkx" )
210
211
endif ()
211
212
list (APPEND COMPILER_DEFINES WINAPI_FAMILY=WINAPI_FAMILY_GAMES )
213
+ list (APPEND LINKER_SWITCHES /NODEFAULTLIB:kernel32.lib /NODEFAULTLIB:oldnames.lib )
212
214
if (XBOX_CONSOLE_TARGET STREQUAL "scarlett" )
213
215
CHECK_INCLUDE_FILE_CXX (d3d12_xs.h D3D12XS_HEADER )
214
216
if (NOT D3D12XS_HEADER )
Original file line number Diff line number Diff line change @@ -265,6 +265,19 @@ jobs:
265
265
inputs :
266
266
cwd : ' $(Build.SourcesDirectory)'
267
267
cmakeArgs : --build out\build\x64-Release-Scarlett-Clang
268
+ - task : DeleteFiles@1
269
+ inputs :
270
+ Contents : ' out/build'
271
+ - task : CMake@1
272
+ displayName : ' CMake (MSVC, DLL): Config Scarlett Debug'
273
+ inputs :
274
+ cwd : ' $(Build.SourcesDirectory)'
275
+ cmakeArgs : --preset=x64-Debug-Scarlett -DBUILD_SHARED_LIBS=ON
276
+ - task : CMake@1
277
+ displayName : ' CMake (MSVC, DLL): Build Scarlett Debug'
278
+ inputs :
279
+ cwd : ' $(Build.SourcesDirectory)'
280
+ cmakeArgs : --build out\build\x64-Debug-Scarlett
268
281
269
282
- job : BUILD_GDK_CMAKE_XBONE
270
283
displayName : ' Microsoft Game Development Kit (GDK) using CMake (XboxOne)'
@@ -371,3 +384,16 @@ jobs:
371
384
inputs :
372
385
cwd : ' $(Build.SourcesDirectory)'
373
386
cmakeArgs : --build out\build\x64-Release-XboxOne-Clang
387
+ - task : DeleteFiles@1
388
+ inputs :
389
+ Contents : ' out/build'
390
+ - task : CMake@1
391
+ displayName : ' CMake (MSVC, DLL): Config XboxOne Debug'
392
+ inputs :
393
+ cwd : ' $(Build.SourcesDirectory)'
394
+ cmakeArgs : --preset=x64-Debug-XboxOne -DBUILD_SHARED_LIBS=ON
395
+ - task : CMake@1
396
+ displayName : ' CMake (MSVC, DLL): Build XboxOne Debug'
397
+ inputs :
398
+ cwd : ' $(Build.SourcesDirectory)'
399
+ cmakeArgs : --build out\build\x64-Debug-XboxOne
Original file line number Diff line number Diff line change 1
- #include <winres .h>
1
+ #include <winver .h>
2
2
3
3
VS_VERSION_INFO VERSIONINFO
4
4
FILEVERSION 1,0,0,0
You can’t perform that action at this time.
0 commit comments