Skip to content

Commit

Permalink
feat: Windows support fully added
Browse files Browse the repository at this point in the history
  • Loading branch information
Jaskowicz1 committed Dec 20, 2023
1 parent 6b6549a commit b6d3ff4
Show file tree
Hide file tree
Showing 5 changed files with 378 additions and 286 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
.vs

# Build directories
_build
build
cmake-build-debug
out

# Xcode stuff
*.xcworkspace
Expand Down
27 changes: 18 additions & 9 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,24 @@ add_executable(${PROJECT_NAME}
${source_files}
)

find_package(DPP REQUIRED)

target_link_libraries(${PROJECT_NAME}
${DPP_LIBRARIES}
)

target_include_directories(${PROJECT_NAME} PRIVATE
${DPP_INCLUDE_DIR}
)
if(WIN32)
find_package(dpp CONFIG REQUIRED)
target_link_libraries(${PROJECT_NAME} PRIVATE
dpp::dpp
wsock32
ws2_32
)
else()
find_package(DPP REQUIRED)

target_link_libraries(${PROJECT_NAME}
${DPP_LIBRARIES}
)

target_include_directories(${PROJECT_NAME} PRIVATE
${DPP_INCLUDE_DIR}
)
endif()

set_target_properties(${PROJECT_NAME} PROPERTIES
CXX_STANDARD 17
Expand Down
48 changes: 48 additions & 0 deletions CMakeSettings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
{
"configurations": [
{
"name": "x64-MSVC-Debug",
"generator": "Ninja",
"configurationType": "Debug",
"inheritEnvironments": [ "msvc_x64_x64" ],
"buildRoot": "${projectDir}\\out\\build\\${name}",
"installRoot": "${projectDir}\\out\\install\\${name}",
"cmakeCommandArgs": "",
"buildCommandArgs": "",
"ctestCommandArgs": ""
},
{
"name": "x64-MSVC-Release",
"generator": "Ninja",
"configurationType": "Release",
"inheritEnvironments": [ "msvc_x64_x64" ],
"buildRoot": "${projectDir}\\out\\build\\${name}",
"installRoot": "${projectDir}\\out\\install\\${name}",
"cmakeCommandArgs": "",
"buildCommandArgs": "",
"ctestCommandArgs": ""
},
{
"name": "x64-Clang-Debug",
"generator": "Ninja",
"configurationType": "Debug",
"buildRoot": "${projectDir}\\out\\build\\${name}",
"installRoot": "${projectDir}\\out\\install\\${name}",
"cmakeCommandArgs": "",
"buildCommandArgs": "",
"ctestCommandArgs": "",
"inheritEnvironments": [ "clang_cl_x64_x64" ]
},
{
"name": "x64-Clang-Release",
"generator": "Ninja",
"configurationType": "Release",
"buildRoot": "${projectDir}\\out\\build\\${name}",
"installRoot": "${projectDir}\\out\\install\\${name}",
"cmakeCommandArgs": "",
"buildCommandArgs": "",
"ctestCommandArgs": "",
"inheritEnvironments": [ "clang_cl_x64_x64" ]
}
]
}
Loading

0 comments on commit b6d3ff4

Please sign in to comment.