mirror of
https://github.com/SysRay/psOff_public.git
synced 2024-11-27 08:30:25 +00:00
use install/development instead of EMULATOR_DEV_ROOT
This commit is contained in:
parent
9fd289d0d6
commit
e67e24a18f
5
.vscode/tasks.json
vendored
5
.vscode/tasks.json
vendored
@ -23,11 +23,10 @@
|
||||
"command": "cmake.exe",
|
||||
"args": [
|
||||
"-S${workspaceFolder}",
|
||||
"-B_build/",
|
||||
"-B_build/_Release",
|
||||
"-GNinja",
|
||||
"-DEMULATOR_DEV_ROOT=../_build/_Install/development",
|
||||
"-DCMAKE_BUILD_TYPE=Release",
|
||||
"-DCMAKE_INSTALL_PREFIX=../_build/_Install",
|
||||
"-DCMAKE_INSTALL_PREFIX=_build/_Install",
|
||||
"-DCMAKE_C_COMPILER=clang-cl.exe",
|
||||
"-DCMAKE_CXX_COMPILER=clang-cl.exe",
|
||||
"-DCMAKE_EXPORT_COMPILE_COMMANDS=1",
|
||||
|
@ -1,5 +1,4 @@
|
||||
cmake_minimum_required(VERSION 3.24)
|
||||
include(ExternalProject)
|
||||
|
||||
set(ProjectName psOff_${CMAKE_BUILD_TYPE})
|
||||
project(${ProjectName} VERSION 0.0.1)
|
||||
@ -15,10 +14,6 @@ set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON)
|
||||
set(CMAKE_WINDOWS_SYMBOL_VISIBILITY_IN_STATIC_LIBRARIES OFF)
|
||||
|
||||
# # Gather Infos
|
||||
# Emulator development
|
||||
if(NOT EMULATOR_DEV_ROOT)
|
||||
message(FATAL_ERROR "EMULATOR_DEV_ROOT not defined")
|
||||
endif()
|
||||
|
||||
# Vulkan
|
||||
find_package(Vulkan 1.3 REQUIRED)
|
||||
@ -32,13 +27,14 @@ message("Vulkan Path: ${VulkanPath}")
|
||||
|
||||
#
|
||||
include_directories(BEFORE
|
||||
${EMULATOR_DEV_ROOT}/include
|
||||
${CMAKE_INSTALL_PREFIX}/development/include
|
||||
${CMAKE_SOURCE_DIR}/modules_include
|
||||
${CMAKE_SOURCE_DIR}
|
||||
${CMAKE_BINARY_DIR}/third_party/install/include
|
||||
)
|
||||
|
||||
link_directories(BEFORE
|
||||
${EMULATOR_DEV_ROOT}/lib
|
||||
${CMAKE_INSTALL_PREFIX}/development/lib
|
||||
${CMAKE_BINARY_DIR}/third_party/install/lib
|
||||
)
|
||||
|
||||
@ -51,16 +47,7 @@ add_definitions("-D__APICALL_IMPORT")
|
||||
|
||||
# # Projects
|
||||
# Build third party
|
||||
ExternalProject_Add(third_party
|
||||
SOURCE_DIR ${CMAKE_SOURCE_DIR}/third_party
|
||||
BINARY_DIR ${CMAKE_BINARY_DIR}/third_party
|
||||
CMAKE_ARGS
|
||||
-DCMAKE_BUILD_TYPE:STRING=Release
|
||||
-DCMAKE_INSTALL_PREFIX=${CMAKE_BINARY_DIR}/third_party/install
|
||||
-DCMAKE_CXX_FLAGS_RELEASE=${CMAKE_CXX_FLAGS_RELEASE}
|
||||
-DCMAKE_C_FLAGS_RELEASE=${CMAKE_C_FLAGS_RELEASE}
|
||||
-DCMAKE_SHARED_LINKER_FLAGS=${CMAKE_SHARED_LINKER_FLAGS}
|
||||
)
|
||||
include("${CMAKE_SOURCE_DIR}/third_party/third_party.cmake")
|
||||
|
||||
# Internal Projects
|
||||
add_subdirectory(modules)
|
||||
|
@ -8,6 +8,7 @@ add_library(${libName} SHARED
|
||||
entry.cpp
|
||||
)
|
||||
|
||||
add_dependencies(${libName} third_party)
|
||||
|
||||
target_compile_definitions(${libName} PRIVATE BOOST_ALL_NO_LIB)
|
||||
target_link_libraries(${libName} PRIVATE
|
||||
|
@ -1,6 +1,6 @@
|
||||
function(setupModule _Target)
|
||||
add_custom_command(TARGET ${_Target} POST_BUILD
|
||||
COMMAND ${EMULATOR_DEV_ROOT}/bin/dll2Nids.exe ${CMAKE_CURRENT_BINARY_DIR}/${_Target}.dll
|
||||
COMMAND ${CMAKE_INSTALL_PREFIX}/development/bin/dll2Nids.exe ${CMAKE_CURRENT_BINARY_DIR}/${_Target}.dll
|
||||
)
|
||||
|
||||
install(FILES $<TARGET_PDB_FILE:${_Target}> DESTINATION debug OPTIONAL)
|
||||
|
5
third_party/CMakeLists.txt
vendored
5
third_party/CMakeLists.txt
vendored
@ -1,3 +1,8 @@
|
||||
cmake_minimum_required(VERSION 3.24)
|
||||
project(third_party VERSION 0.0.1)
|
||||
|
||||
include(ExternalProject)
|
||||
|
||||
add_subdirectory(portAudio)
|
||||
|
||||
install(DIRECTORY "ffmpeg/bin/" DESTINATION "${CMAKE_BINARY_DIR}/bin"
|
||||
|
12
third_party/third_party.cmake
vendored
Normal file
12
third_party/third_party.cmake
vendored
Normal file
@ -0,0 +1,12 @@
|
||||
include(ExternalProject)
|
||||
|
||||
ExternalProject_Add(third_party
|
||||
SOURCE_DIR ${CMAKE_SOURCE_DIR}/third_party
|
||||
BINARY_DIR ${CMAKE_BINARY_DIR}/third_party
|
||||
CMAKE_ARGS
|
||||
-DCMAKE_BUILD_TYPE:STRING=Release
|
||||
-DCMAKE_INSTALL_PREFIX=${CMAKE_BINARY_DIR}/third_party/install
|
||||
-DCMAKE_CXX_FLAGS_RELEASE=${CMAKE_CXX_FLAGS_RELEASE}
|
||||
-DCMAKE_C_FLAGS_RELEASE=${CMAKE_C_FLAGS_RELEASE}
|
||||
-DCMAKE_SHARED_LINKER_FLAGS=${CMAKE_SHARED_LINKER_FLAGS}
|
||||
)
|
Loading…
Reference in New Issue
Block a user