From eac2857db06c00d95c2d8f8e32c0c28a0ad0569a Mon Sep 17 00:00:00 2001 From: Karutoh Date: Fri, 28 Mar 2025 23:53:39 -0700 Subject: [PATCH] Testing submodule. --- .gitea/workflows/BuildRelease.yaml | 3 +++ .gitignore | 14 ++++++++++++++ CMakeLists.txt | 18 ++++++++++++++++-- 3 files changed, 33 insertions(+), 2 deletions(-) create mode 100644 .gitignore diff --git a/.gitea/workflows/BuildRelease.yaml b/.gitea/workflows/BuildRelease.yaml index 9d8e3ca..c5cd818 100644 --- a/.gitea/workflows/BuildRelease.yaml +++ b/.gitea/workflows/BuildRelease.yaml @@ -15,6 +15,7 @@ jobs: - name: Building/Compiling/Installing Project run: | cd ${{ gitea.workspace }} + git pull --recurse-submodules cmake -A x64 -DCMAKE_BUILD_TYPE=Release --preset=default . cd build cmake --build . --config Release @@ -55,6 +56,7 @@ jobs: - name: Building/Compiling/Installing Project run: | cd ${{ gitea.workspace }} + git pull --recurse-submodules cmake -DCMAKE_BUILD_TYPE=Release . cmake --build . --config Release @@ -85,6 +87,7 @@ jobs: - name: Building/Compiling/Installing Project run: | cd ${{ gitea.workspace }} + git pull --recurse-submodules cmake -DCMAKE_BUILD_TYPE=Release . cmake --build . --config Release diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..630edb7 --- /dev/null +++ b/.gitignore @@ -0,0 +1,14 @@ +*.obj +*.cpp.obj +*.lib +*.exe +*.a +*.ninja_deps +*.ninja_log +*.ninja +*.cmake +*.log +/.idea/ +/cmake-build-release/ +/cmake-build-debug/ +/external \ No newline at end of file diff --git a/CMakeLists.txt b/CMakeLists.txt index 9ec75fb..39609f4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.18.4) +cmake_minimum_required(VERSION 3.25.1) project(DeviceScanner C CXX) if (${CMAKE_HOST_SYSTEM_NAME} STREQUAL "Windows") @@ -36,6 +36,8 @@ elseif (IS_OS_LINUX) add_compile_definitions(VK_USE_PLATFORM_WAYLAND_KHR EHS_WS_WAYLAND) endif() +target_include_directories(DeviceScanner PRIVATE "external/ehs/include") + find_package(ZLIB REQUIRED) if (ZLIB_FOUND) message(STATUS "ZLIB was found.") @@ -50,4 +52,16 @@ else () message(STATUS "OpenSSL was not found.") endif () -target_link_libraries(DeviceScanner PRIVATE OpenSSL::SSL OpenSSL::Crypto ZLIB::ZLIB EHS_Stc wayland-client) \ No newline at end of file +if (IS_OS_WINDOWS) + target_link_libraries(DeviceScanner PRIVATE avrt ws2_32 IPHLPAPI) +elseif (IS_OS_LINUX) + if (LINUX_WINDOW_SYSTEM STREQUAL "Wayland") + target_link_libraries(DeviceScanner PRIVATE wayland-client) + elseif (LINUX_WINDOW_SYSTEM STREQUAL "XCB") + target_link_libraries(DeviceScanner PRIVATE xcb xcb-cursor xcb-xfixes xcb-xinput) + endif () + + target_link_libraries(DeviceScanner PRIVATE z asound pipewire-0.3) +endif () + +target_link_libraries(DeviceScanner PRIVATE OpenSSL::SSL OpenSSL::Crypto ZLIB::ZLIB EHS_Stc) \ No newline at end of file