mirror of
https://github.com/hedge-dev/XenosRecomp.git
synced 2025-10-30 07:12:17 +00:00
Convert almost all dependencies to submodules.
This commit is contained in:
parent
20bf465448
commit
cf44a5e6fb
8 changed files with 34 additions and 14 deletions
9
.gitmodules
vendored
9
.gitmodules
vendored
|
|
@ -1,3 +1,12 @@
|
|||
[submodule "thirdparty/smol-v"]
|
||||
path = thirdparty/smol-v
|
||||
url = https://github.com/aras-p/smol-v
|
||||
[submodule "thirdparty/zstd"]
|
||||
path = thirdparty/zstd
|
||||
url = https://github.com/facebook/zstd.git
|
||||
[submodule "thirdparty/xxHash"]
|
||||
path = thirdparty/xxHash
|
||||
url = https://github.com/Cyan4973/xxHash.git
|
||||
[submodule "thirdparty/fmt"]
|
||||
path = thirdparty/fmt
|
||||
url = https://github.com/fmtlib/fmt.git
|
||||
|
|
|
|||
|
|
@ -3,6 +3,9 @@ cmake_minimum_required(VERSION 3.20)
|
|||
include($ENV{VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake)
|
||||
set(CMAKE_CXX_STANDARD 17)
|
||||
|
||||
project(ShaderRecomp-ALL)
|
||||
project("ShaderRecomp-ALL")
|
||||
|
||||
add_subdirectory(ShaderRecomp)
|
||||
set(SHADER_RECOMP_THIRDPARTY_ROOT "${CMAKE_CURRENT_SOURCE_DIR}/thirdparty")
|
||||
|
||||
add_subdirectory(${SHADER_RECOMP_THIRDPARTY_ROOT})
|
||||
add_subdirectory("${CMAKE_CURRENT_SOURCE_DIR}/ShaderRecomp")
|
||||
|
|
|
|||
|
|
@ -19,14 +19,12 @@ add_executable(ShaderRecomp
|
|||
"${SMOLV_SOURCE_DIR}/smolv.cpp")
|
||||
|
||||
find_package(directx-dxc CONFIG REQUIRED)
|
||||
find_package(xxHash CONFIG REQUIRED)
|
||||
find_package(zstd CONFIG REQUIRED)
|
||||
find_package(fmt CONFIG REQUIRED)
|
||||
|
||||
target_link_libraries(ShaderRecomp PRIVATE
|
||||
Microsoft::DirectXShaderCompiler
|
||||
Microsoft::DXIL
|
||||
xxHash::xxhash
|
||||
$<IF:$<TARGET_EXISTS:zstd::libzstd_shared>,zstd::libzstd_shared,zstd::libzstd_static>
|
||||
libzstd_static
|
||||
fmt::fmt)
|
||||
|
||||
target_include_directories(ShaderRecomp PRIVATE ${SMOLV_SOURCE_DIR})
|
||||
|
|
@ -39,9 +37,8 @@ endif()
|
|||
|
||||
if (WIN32)
|
||||
target_compile_definitions(ShaderRecomp PRIVATE _CRT_SECURE_NO_WARNINGS)
|
||||
file(COPY ${PACKAGE_PREFIX_DIR}/bin/dxil.dll DESTINATION ${CMAKE_CURRENT_BINARY_DIR})
|
||||
else()
|
||||
set_target_properties(Microsoft::DXIL PROPERTIES IMPORTED_LOCATION ${PACKAGE_PREFIX_DIR}/lib/libdxil.so)
|
||||
find_file(DIRECTX_DXIL_LIBRARY "dxil.dll")
|
||||
file(COPY ${DIRECTX_DXIL_LIBRARY} DESTINATION ${CMAKE_CURRENT_BINARY_DIR})
|
||||
endif()
|
||||
|
||||
if (SHADER_RECOMP_DXIL)
|
||||
|
|
|
|||
11
thirdparty/CMakeLists.txt
vendored
Normal file
11
thirdparty/CMakeLists.txt
vendored
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
if (NOT TARGET fmt::fmt)
|
||||
add_subdirectory("${SHADER_RECOMP_THIRDPARTY_ROOT}/fmt")
|
||||
endif()
|
||||
|
||||
if (NOT TARGET xxHash::xxhash)
|
||||
add_subdirectory("${SHADER_RECOMP_THIRDPARTY_ROOT}/xxHash/cmake_unofficial")
|
||||
endif()
|
||||
|
||||
if (NOT TARGET libzstd)
|
||||
add_subdirectory("${SHADER_RECOMP_THIRDPARTY_ROOT}/zstd/build/cmake")
|
||||
endif()
|
||||
1
thirdparty/fmt
vendored
Submodule
1
thirdparty/fmt
vendored
Submodule
|
|
@ -0,0 +1 @@
|
|||
Subproject commit 873670ba3f9e7bc77ec2c1c94b04f1f8bef77e9f
|
||||
1
thirdparty/xxHash
vendored
Submodule
1
thirdparty/xxHash
vendored
Submodule
|
|
@ -0,0 +1 @@
|
|||
Subproject commit 2bf8313b934633b2a5b7e8fd239645b85e10c852
|
||||
1
thirdparty/zstd
vendored
Submodule
1
thirdparty/zstd
vendored
Submodule
|
|
@ -0,0 +1 @@
|
|||
Subproject commit f7a8bb1263448e5028aceeba606a08fe3809550f
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
{
|
||||
"builtin-baseline": "e63bd09dc0b7204467705c1c7c71d0e2a3f8860b",
|
||||
"builtin-baseline": "b322364f06308bdd24823f9d8f03fe0cc86fd46f",
|
||||
"dependencies": [
|
||||
"directx-dxc",
|
||||
"fmt",
|
||||
"xxhash",
|
||||
"zstd"
|
||||
"directx-dxc"
|
||||
]
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue