Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
d032f3e
Update clang-format so clang-21 works
yohjimane Sep 22, 2025
d6bc19c
Cmake for windows can load in vs2022
yohjimane Sep 22, 2025
19ba0b5
23/29 building with cmake on windows
yohjimane Sep 23, 2025
44da204
More work on windows cmake build
yohjimane Sep 23, 2025
c009d0c
linux works again, windows 27/30
yohjimane Sep 23, 2025
1f6ad77
cmake for windows builds successfully
yohjimane Sep 23, 2025
488c901
Cmake for windows - final commit
yohjimane Sep 23, 2025
b420c5c
address some PR comments
yohjimane Sep 23, 2025
b8010ba
Don't set CMAKE_DEFAULT_BUILD_TYPE for visual studio
yohjimane Sep 23, 2025
e5a7d85
Fix cmake for windows release master gold
yohjimane Sep 23, 2025
15554f6
Merge branch 'yohji/feat/cmake-windows' into dev
yohjimane Sep 29, 2025
b9bb985
Merge remote-tracking branch 'OpenXRay/dev' into yohji/feat/cmake-win…
Xottab-DUTY Sep 30, 2025
c6802e5
We don't want .lib and .o files in the bin folder
Xottab-DUTY Sep 30, 2025
cbfbeb8
Small diff reduction and optimization
Xottab-DUTY Sep 30, 2025
1490ea9
GitHub Actions: enable Windows CMake builds
Xottab-DUTY Sep 30, 2025
6fce19d
ODE: pass DEF directly
Xottab-DUTY Sep 30, 2025
8341d24
Compile xrCore with DXERR on Windows
Xottab-DUTY Sep 30, 2025
33b5de6
Add comment regarding CMAKE_DEFAULT_BUILD_TYPE and Visual Studio [ski…
Xottab-DUTY Sep 30, 2025
02b8e38
Fix xrSound linking when Unity build is enabled
Xottab-DUTY Sep 30, 2025
ea3790b
Clean up ImGui usage
Xottab-DUTY Sep 30, 2025
c5fc6be
Use NuGet packages via VS_PACKAGE_REFERENCES and VS_USER_PROPS trick
Xottab-DUTY Sep 30, 2025
cc51a8e
Fix xrGame build when Unity build is enabled
Xottab-DUTY Oct 1, 2025
d3e71b6
Use 7z as CPack generator for Windows
Xottab-DUTY Oct 1, 2025
ef6c1b7
Use CMAKE_DEFAULT_BUILD_TYPE only for Ninja Multi-Config
Xottab-DUTY Oct 1, 2025
a63c664
Reorder linked libraries
Xottab-DUTY Oct 1, 2025
54e48fb
Port all compile options from xray_build.props
Xottab-DUTY Oct 3, 2025
b2626d7
cmake/utils.cmake: add CONDITION option to target_sources_grouped and…
Xottab-DUTY Oct 3, 2025
4559826
Merge branch 'dev' into yohji/feat/cmake-windows
Xottab-DUTY Oct 3, 2025
cb746fb
Fix one last warning on Master Gold
Xottab-DUTY Oct 3, 2025
fed6318
Fix last error that prevents ReleaseMasterGold from compilation
Xottab-DUTY Oct 3, 2025
3ddde25
Work on dependencies detection
Xottab-DUTY Oct 4, 2025
941c890
Merge branch 'dev' into yohji/feat/cmake-windows
Xottab-DUTY Oct 6, 2025
cc304e6
Better CMake configuration for DiscordGameSDK and BugTrap
Xottab-DUTY Oct 10, 2025
7a0015a
Work on packaging and installation
Xottab-DUTY Oct 10, 2025
af5bd50
Merge remote-tracking branch 'OpenXRay/dev' into yohji/feat/cmake-win…
Xottab-DUTY Nov 7, 2025
8527ca7
Fix install targets
Xottab-DUTY Nov 7, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/cibuild.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ on:
workflow_dispatch:

jobs:
windows:
name: Windows ${{ matrix.Configuration }} ${{ matrix.Platform }} (msvc)
msbuild:
name: Windows ${{ matrix.Configuration }} ${{ matrix.Platform }} (MSBuild, MSVC)
runs-on: windows-latest
timeout-minutes: 20
strategy:
Expand Down Expand Up @@ -89,8 +89,8 @@ jobs:
# cc is always set for the correct naming of the job.
# Both cc and cxx should be set if we want to change the compiler.
# You may also want to set XRAY_LINKER when changing the compiler.
#- { name: Windows, os: windows-latest, arch: x64, cc: cl, }
#- { name: Windows, os: windows-latest, arch: x86, cc: cl, }
- { name: Windows, os: windows-latest, arch: x64, cc: cl, }
- { name: Windows, os: windows-latest, arch: x86, cc: cl, }
- { name: Ubuntu, os: ubuntu-latest, arch: amd64, cc: gcc, }
- { name: Ubuntu, os: ubuntu-latest, arch: amd64, cc: clang, cxx: clang++, flags: "-DXRAY_LINKER=lld", }
- { name: Ubuntu, os: ubuntu-24.04-arm, arch: arm64, cc: gcc }
Expand Down
4 changes: 4 additions & 0 deletions Externals/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ add_subdirectory(xrLuaFix)
add_subdirectory(OPCODE)
add_subdirectory(ode)

if (WIN32)
add_subdirectory(DiscordGameSDK)
endif()

# Silence all warnings for external libraries
add_compile_options(${XRAY_DISABLE_WARNINGS})

Expand Down
43 changes: 43 additions & 0 deletions Externals/DiscordGameSDK/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
add_library(DiscordGameSDK STATIC)

target_sources_grouped(
TARGET DiscordGameSDK
NAME "Managers"
FILES
activity_manager.cpp
activity_manager.h
overlay_manager.cpp
overlay_manager.h
relationship_manager.cpp
relationship_manager.h
user_manager.cpp
user_manager.h
)

target_sources_grouped(
TARGET DiscordGameSDK
NAME "Core"
FILES
core.cpp
core.h
discord.h
event.h
ffi.h
#pch.hpp
types.cpp
types.h
)

target_include_directories(DiscordGameSDK
PUBLIC
"${CMAKE_SOURCE_DIR}/Externals"
)

target_link_libraries(DiscordGameSDK
PUBLIC
${XRAY_SDK_LIBRARY_DIR}/discord_game_sdk.dll.lib
)

set_target_properties(DiscordGameSDK PROPERTIES
PREFIX ""
)
2 changes: 1 addition & 1 deletion Externals/GameSpy
150 changes: 121 additions & 29 deletions Externals/LuaJIT-proj/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -68,26 +68,32 @@ if (APPLE)
endif()

# Clean unnecessary files in LuaJIT source directory
execute_process(
COMMAND make clean
WORKING_DIRECTORY ${LUAJIT_DIR}
)
if (NOT MSVC)
execute_process(
COMMAND make clean
WORKING_DIRECTORY ${LUAJIT_DIR}
)
endif()

add_library(xrLuaJIT)

# Compiler options
set(CCOPT_OPT_LEVEL "-O3")
if (MSVC)
set(CCOPT_OPT_LEVEL "/O2")
set(CCOPT "${CMAKE_C_FLAGS} ${CCOPT_OPT_LEVEL}")
else()
set(CCOPT_OPT_LEVEL "-O3")
set(CCOPT "${CMAKE_C_FLAGS} ${CCOPT_OPT_LEVEL}")

set(CCOPT "${CMAKE_C_FLAGS} ${CCOPT_OPT_LEVEL}")
if (XRAY_USE_ASAN)
set(CCOPT "${CCOPT} -fno-stack-protector")
else()
set(CCOPT "${CCOPT} -fomit-frame-pointer -fno-stack-protector")
endif()

if (XRAY_USE_ASAN)
set(CCOPT "${CCOPT} -fno-stack-protector")
else()
set(CCOPT "${CCOPT} -fomit-frame-pointer -fno-stack-protector")
set(CCOPT "${CCOPT} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -U_FORTIFY_SOURCE")
endif()

set(CCOPT "${CCOPT} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -U_FORTIFY_SOURCE")

string(REPLACE " " ";" CCOPT "${CCOPT}")

add_compile_options(
Expand Down Expand Up @@ -137,15 +143,59 @@ set(CCOPTIONS "${CCOPT};${XCFLAGS}")

target_compile_options(xrLuaJIT PRIVATE ${CCOPTIONS})

execute_process(
COMMAND ${CMAKE_C_COMPILER} ${CCOPTIONS} -E lj_arch.h -dM
WORKING_DIRECTORY "${LUAJIT_DIR}"
OUTPUT_VARIABLE TESTARCH_OUTPUT
ERROR_VARIABLE TESTARCH_ERROR
)
if (MSVC)
set(_luajit_detect_src "${CMAKE_CURRENT_BINARY_DIR}/luajit_detect_arch.c")

file(WRITE "${_luajit_detect_src}" "#include <stdio.h>\n#include \"lj_arch.h\"\nint main(void) {\n#ifdef LJ_TARGET_X64\n printf(\"LJ_TARGET_X64 %d\\n\", LJ_TARGET_X64);\n#endif\n#ifdef LJ_TARGET_X86\n printf(\"LJ_TARGET_X86 %d\\n\", LJ_TARGET_X86);\n#endif\n#ifdef LJ_TARGET_ARM64\n printf(\"LJ_TARGET_ARM64 %d\\n\", LJ_TARGET_ARM64);\n#endif\n#ifdef LJ_TARGET_ARM\n printf(\"LJ_TARGET_ARM %d\\n\", LJ_TARGET_ARM);\n#endif\n#ifdef LJ_TARGET_PPC\n printf(\"LJ_TARGET_PPC %d\\n\", LJ_TARGET_PPC);\n#endif\n#ifdef LJ_TARGET_MIPS\n printf(\"LJ_TARGET_MIPS %d\\n\", LJ_TARGET_MIPS);\n#endif\n#ifdef LJ_TARGET_MIPS64\n printf(\"LJ_TARGET_MIPS64 %d\\n\", LJ_TARGET_MIPS64);\n#endif\n#ifdef LJ_TARGET_E2K\n printf(\"LJ_TARGET_E2K %d\\n\", LJ_TARGET_E2K);\n#endif\n#ifdef LJ_TARGET_MIPSR6\n printf(\"LJ_TARGET_MIPSR6 %d\\n\", LJ_TARGET_MIPSR6);\n#endif\n#ifdef __MIPSEL__\n printf(\"__MIPSEL__ 1\\n\");\n#endif\n#ifdef __AARCH64EB__\n printf(\"__AARCH64EB__ 1\\n\");\n#endif\n#ifdef LJ_LE\n printf(\"LJ_LE %d\\n\", LJ_LE);\n#endif\n#ifdef LJ_ARCH_BITS\n printf(\"LJ_ARCH_BITS %d\\n\", LJ_ARCH_BITS);\n#endif\n#ifdef LJ_HASJIT\n printf(\"LJ_HASJIT %d\\n\", LJ_HASJIT);\n#endif\n#ifdef LJ_HASFFI\n printf(\"LJ_HASFFI %d\\n\", LJ_HASFFI);\n#endif\n#ifdef LJ_DUALNUM\n printf(\"LJ_DUALNUM %d\\n\", LJ_DUALNUM);\n#endif\n#ifdef LJ_ARCH_HASFPU\n printf(\"LJ_ARCH_HASFPU %d\\n\", LJ_ARCH_HASFPU);\n#endif\n#ifdef LJ_ABI_SOFTFP\n printf(\"LJ_ABI_SOFTFP %d\\n\", LJ_ABI_SOFTFP);\n#endif\n#ifdef LJ_NO_UNWIND\n printf(\"LJ_NO_UNWIND %d\\n\", LJ_NO_UNWIND);\n#endif\n#ifdef LJ_ARCH_VERSION\n printf(\"LJ_ARCH_VERSION %d\\n\", LJ_ARCH_VERSION);\n#endif\n#ifdef LJ_ARCH_SQRT\n printf(\"LJ_ARCH_SQRT %d\\n\", LJ_ARCH_SQRT);\n#endif\n#ifdef LJ_ARCH_ROUND\n printf(\"LJ_ARCH_ROUND %d\\n\", LJ_ARCH_ROUND);\n#endif\n#ifdef LJ_ARCH_PPC32ON64\n printf(\"LJ_ARCH_PPC32ON64 %d\\n\", LJ_ARCH_PPC32ON64);\n#endif\n#ifdef LJ_FR2\n printf(\"LJ_FR2 %d\\n\", LJ_FR2);\n#endif\n return 0;\n}\n")

set(_saved_try_compile_config ${CMAKE_TRY_COMPILE_CONFIGURATION})
if (CMAKE_CONFIGURATION_TYPES)
set(CMAKE_TRY_COMPILE_CONFIGURATION Release)
endif()

try_run(_luajit_arch_run _luajit_arch_compile
"${CMAKE_CURRENT_BINARY_DIR}/luajit_detect"
"${_luajit_detect_src}"
CMAKE_FLAGS "-DINCLUDE_DIRECTORIES=${LUAJIT_DIR}"
RUN_OUTPUT_VARIABLE TESTARCH_OUTPUT
COMPILE_OUTPUT_VARIABLE TESTARCH_COMPILE_OUTPUT
)

if (CMAKE_CONFIGURATION_TYPES)
set(CMAKE_TRY_COMPILE_CONFIGURATION ${_saved_try_compile_config})
endif()

if (NOT _luajit_arch_compile OR NOT _luajit_arch_run EQUAL 0)
message(FATAL_ERROR "Failed to detect LuaJIT architecture with MSVC.\n${TESTARCH_COMPILE_OUTPUT}")
endif()

unset(_luajit_detect_src)
unset(_luajit_arch_run)
unset(_luajit_arch_compile)
unset(_saved_try_compile_config)
else()
set(_LUAJIT_TESTARCH_COMMAND ${CMAKE_C_COMPILER})

list(APPEND _LUAJIT_TESTARCH_COMMAND ${CCOPTIONS})

foreach(_dir ${CMAKE_C_IMPLICIT_INCLUDE_DIRECTORIES})
list(APPEND _LUAJIT_TESTARCH_COMMAND "-I${_dir}")
endforeach()

if(NOT "${TESTARCH_ERROR}" STREQUAL "")
message("TESTARCH_ERROR=${TESTARCH_ERROR}")
list(APPEND _LUAJIT_TESTARCH_COMMAND -E lj_arch.h -dM)

execute_process(
COMMAND ${_LUAJIT_TESTARCH_COMMAND}
WORKING_DIRECTORY "${LUAJIT_DIR}"
OUTPUT_VARIABLE TESTARCH_OUTPUT
ERROR_VARIABLE TESTARCH_ERROR
)

unset(_LUAJIT_TESTARCH_COMMAND)

if(NOT "${TESTARCH_ERROR}" STREQUAL "")
message("TESTARCH_ERROR=${TESTARCH_ERROR}")
endif()
endif()

if ("${TESTARCH_OUTPUT}" MATCHES "LJ_TARGET_X64")
Expand Down Expand Up @@ -187,10 +237,16 @@ string(APPEND TARGET_ARCH "-DLUAJIT_TARGET=LUAJIT_ARCH_${TARGET_LJARCH}")
if (WIN32)
#string(APPEND TARGET_STRIP "--strip-unneeded")

target_link_options(xrLuaJIT
PRIVATE
" -shared -Wl,--out-implib,libluajit-${ABIVER}.dll.a"
)
if (NOT MSVC)
target_link_options(xrLuaJIT
PRIVATE
" -shared -Wl,--out-implib,libluajit-${ABIVER}.dll.a"
)
endif()

# Export the public API symbols when building the DLL so MSVC generates
# an import library (xrLuaJIT.lib).
target_compile_definitions(xrLuaJIT PRIVATE LUA_BUILD_AS_DLL)

if (LUAJIT_BUILD_STATIC_LIB)
string(APPEND HOST_XCFLAGS " -DLUA_BUILD_AS_DLL")
Expand Down Expand Up @@ -308,6 +364,11 @@ endif()

set(HOST_ACFLAGS "${CMAKE_C_FLAGS} ${CCOPTIONS} ${TARGET_ARCH}")
set(HOST_ALDFLAGS "${CMAKE_C_FLAGS}")
if (MSVC)
string(REPLACE "/DWIN32" "" HOST_ALDFLAGS "${HOST_ALDFLAGS}")
string(REPLACE "/D_WINDOWS" "" HOST_ALDFLAGS "${HOST_ALDFLAGS}")
string(REPLACE " " " " HOST_ALDFLAGS "${HOST_ALDFLAGS}")
endif()

string(APPEND TARGET_XCFLAGS " -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -U_FORTIFY_SOURCE")

Expand All @@ -325,9 +386,33 @@ set(DASM_DASC "${LUAJIT_DIR}/vm_${DASM_ARCH}.dasc")
set(DASM "${LUAJIT_DIR}/../dynasm/dynasm.lua")
set(BUILDVM_ARCH "${CMAKE_CURRENT_BINARY_DIR}/buildvm_arch.h")

set(_luajit_host_build_config Release)
get_property(_luajit_is_multi GLOBAL PROPERTY GENERATOR_IS_MULTI_CONFIG)
if (_luajit_is_multi)
set(_luajit_host_cfg_subdir "${_luajit_host_build_config}")
else()
set(_luajit_host_cfg_subdir "")
endif()

if (_luajit_host_cfg_subdir)
set(_luajit_host_cfg_path "/${_luajit_host_cfg_subdir}")
else()
set(_luajit_host_cfg_path "")
endif()

set(_luajit_build_config_args)
if (_luajit_is_multi)
list(APPEND _luajit_build_config_args --config ${_luajit_host_build_config})
endif()

# Generate buildvm arch header
set(MINILUA_BINARY_DIR "${CMAKE_CURRENT_BINARY_DIR}/HostBuildTools/minilua")
set(MINILUA_FILE "${MINILUA_BINARY_DIR}/minilua")
set(MINILUA_BUILD_OUTPUT "${MINILUA_BINARY_DIR}${_luajit_host_cfg_path}/minilua${CMAKE_EXECUTABLE_SUFFIX}")
set(MINILUA_FILE "${MINILUA_BINARY_DIR}/minilua${CMAKE_EXECUTABLE_SUFFIX}")
set(_luajit_copy_minilua_command "")
if (NOT MINILUA_BUILD_OUTPUT STREQUAL MINILUA_FILE)
set(_luajit_copy_minilua_command COMMAND ${CMAKE_COMMAND} -E copy_if_different "${MINILUA_BUILD_OUTPUT}" "${MINILUA_FILE}")
endif()

add_custom_command(
OUTPUT "${MINILUA_FILE}"
Expand All @@ -342,7 +427,8 @@ add_custom_command(
-DLUA_USE_POSIX=${LUA_USE_POSIX}
-DHOST_ACFLAGS="${HOST_ACFLAGS}"
-DHOST_ALDFLAGS="${HOST_ALDFLAGS}"
COMMAND ${CMAKE_COMMAND} --build ${MINILUA_BINARY_DIR} --config Release --verbose
COMMAND ${CMAKE_COMMAND} --build ${MINILUA_BINARY_DIR} ${_luajit_build_config_args} --verbose
${_luajit_copy_minilua_command}
)

add_custom_command(OUTPUT ${BUILDVM_ARCH}
Expand All @@ -360,7 +446,12 @@ set_target_properties(buildvm_arch PROPERTIES

# Buildvm
set(BUILDVM_BINARY_DIR "${CMAKE_CURRENT_BINARY_DIR}/HostBuildTools/buildvm")
set(BUILDVM_FILE "${BUILDVM_BINARY_DIR}/buildvm")
set(BUILDVM_BUILD_OUTPUT "${BUILDVM_BINARY_DIR}${_luajit_host_cfg_path}/buildvm${CMAKE_EXECUTABLE_SUFFIX}")
set(BUILDVM_FILE "${BUILDVM_BINARY_DIR}/buildvm${CMAKE_EXECUTABLE_SUFFIX}")
set(_luajit_copy_buildvm_command "")
if (NOT BUILDVM_BUILD_OUTPUT STREQUAL BUILDVM_FILE)
set(_luajit_copy_buildvm_command COMMAND ${CMAKE_COMMAND} -E copy_if_different "${BUILDVM_BUILD_OUTPUT}" "${BUILDVM_FILE}")
endif()

add_custom_command(
OUTPUT "${BUILDVM_FILE}"
Expand All @@ -374,7 +465,8 @@ add_custom_command(
-DBUILDVM_ARCH=${BUILDVM_ARCH}
-DHOST_ACFLAGS="${HOST_ACFLAGS}"
-DHOST_ALDFLAGS="${HOST_ALDFLAGS}"
COMMAND ${CMAKE_COMMAND} --build ${BUILDVM_BINARY_DIR} --config Release --verbose
COMMAND ${CMAKE_COMMAND} --build ${BUILDVM_BINARY_DIR} ${_luajit_build_config_args} --verbose
${_luajit_copy_buildvm_command}
)

add_custom_target(buildvm
Expand Down Expand Up @@ -576,7 +668,7 @@ target_link_libraries(xrLuaJIT

target_compile_options(xrLuaJIT
PRIVATE
-Wno-comment
$<$<NOT:$<CXX_COMPILER_ID:MSVC>>:-Wno-comment>
)

set_target_properties(xrLuaJIT PROPERTIES
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ target_include_directories(buildvm
target_compile_options(buildvm
PRIVATE
${HOST_ACFLAGS}
-Wno-discarded-qualifiers
$<$<NOT:$<C_COMPILER_ID:MSVC>>:-Wno-discarded-qualifiers>
)

target_link_options(buildvm
Expand Down
6 changes: 0 additions & 6 deletions Externals/OPCODE/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -92,9 +92,3 @@ target_precompile_headers(xrOPCODE
PRIVATE
pch.hpp
)

if (BUILD_SHARED_LIBS)
install(TARGETS xrOPCODE LIBRARY
DESTINATION "${CMAKE_INSTALL_LIBDIR}"
)
endif()
2 changes: 2 additions & 0 deletions Externals/imgui-proj/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ target_sources(xrImGui PRIVATE
"${IMGUI_DIR}/imgui_internal.h"
"${IMGUI_DIR}/backends/imgui_impl_opengl3.cpp"
"${IMGUI_DIR}/backends/imgui_impl_opengl3.h"
"$<$<STREQUAL:$<PLATFORM_ID>,Windows>:${IMGUI_DIR}/backends/imgui_impl_dx11.cpp>"
"$<$<STREQUAL:$<PLATFORM_ID>,Windows>:${IMGUI_DIR}/backends/imgui_impl_dx11.h>"
"${IMGUI_DIR}/imstb_rectpack.h"
"${IMGUI_DIR}/imstb_textedit.h"
"${IMGUI_DIR}/imstb_truetype.h"
Expand Down
7 changes: 1 addition & 6 deletions Externals/ode/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ target_sources(xrODE PRIVATE
include/ode/timer.h
contrib/msvc7/ode_default/de_padf_integration.cpp
contrib/msvc7/ode_default/de_padf_integration.h
config/msvcdefs.def
)

target_include_directories(xrODE
Expand All @@ -95,9 +96,3 @@ set_target_properties(xrODE PROPERTIES
PREFIX ""
UNITY_BUILD OFF
)

if (BUILD_SHARED_LIBS)
install(TARGETS xrODE LIBRARY
DESTINATION "${CMAKE_INSTALL_LIBDIR}"
)
endif()
27 changes: 27 additions & 0 deletions cmake/FindBugTrap.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
find_path(BUGTRAP_INCLUDE_DIR
NAMES BugTrap.h
PATH_SUFFIXES include
)

find_library(BUGTRAP_LIB
NAMES BugTrap
)

find_file(BUGTRAP_DLL
NAMES BugTrap.dll
PATHS "${XRAY_SDK_BINARY_DIR}"
)

mark_as_advanced(
BUGTRAP_INCLUDE_DIR
BUGTRAP_LIB
BUGTRAP_DLL
)

add_library(BugTrap SHARED IMPORTED GLOBAL)

set_target_properties(BugTrap PROPERTIES
IMPORTED_LOCATION "${BUGTRAP_DLL}"
IMPORTED_IMPLIB "${BUGTRAP_LIB}"
INTERFACE_INCLUDE_DIRECTORIES "${BUGTRAP_INCLUDE_DIR}"
)
Loading
Loading