From 519b25ac3868169aff209572b70d10cd70c71332 Mon Sep 17 00:00:00 2001 From: ThatCodingFrog Date: Sat, 10 Oct 2026 15:23:33 -0600 Subject: [PATCH 1/3] Minor cleanup, add CPack --- .github/workflows/build.yaml | 4 ++-- CMakeLists.txt | 6 ++++-- CPackConfig.cmake | 30 ++++++++++++++++++++++++++++++ vcpkg-configuation.json | 7 ------- vcpkg.json | 2 +- 5 files changed, 37 insertions(+), 12 deletions(-) create mode 100644 CPackConfig.cmake delete mode 100644 vcpkg-configuation.json diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 24da3d1..27af534 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -115,6 +115,6 @@ jobs: if: always() uses: actions/upload-artifact@v7 with: - name: build-${{ matrix.os }}-${{ matrix.triplet }} - path: build/ + name: Harbour-${{ matrix.os }} + path: build/Harbour-Ports-*.zip retention-days: 30 \ No newline at end of file diff --git a/CMakeLists.txt b/CMakeLists.txt index cab244d..2c8a803 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,7 +1,7 @@ # Root CMakeLists.txt -cmake_minimum_required(VERSION 3.16) +cmake_minimum_required(VERSION 3.21) -project(Harbour VERSION 0.3.0 LANGUAGES CXX) +project(Harbour VERSION 0.5.0 LANGUAGES CXX) set(CMAKE_CXX_STANDARD 20) set(CMAKE_CXX_STANDARD_REQUIRED ON) @@ -49,3 +49,5 @@ add_custom_command( ${CMAKE_CURRENT_SOURCE_DIR}/assets $/assets ) + +include("${CMAKE_SOURCE_DIR}/CPackConfig.cmake") diff --git a/CPackConfig.cmake b/CPackConfig.cmake new file mode 100644 index 0000000..95c23f7 --- /dev/null +++ b/CPackConfig.cmake @@ -0,0 +1,30 @@ +set(CPACK_PACKAGE_NAME "Harbour-Ports") +set(CPACK_PACKAGE_VENDOR "Harbour Ports Team") +set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "A cross-platform launcher and updater for console game PC ports") +set(CPACK_PACKAGE_VERSION "v0.5.0") + +set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_SOURCE_DIR}/LICENSE") +set(CPACK_PACKAGE_EXECUTABLES "Harbour" "Harbour Ports") + +install(TARGETS Harbour + RUNTIME_DEPENDENCY_SET HarbourDeps + RUNTIME DESTINATION . + BUNDLE DESTINATION . +) + +if(EXISTS "${CMAKE_SOURCE_DIR}/assets") + install(DIRECTORY "${CMAKE_SOURCE_DIR}/assets/" DESTINATION "assets") +endif() + +if(WIN32) + install(RUNTIME_DEPENDENCY_SET HarbourDeps + DESTINATION . + DIRECTORIES "${CMAKE_BINARY_DIR}/" + + PRE_EXCLUDE_REGEXES "api-ms-" "ext-ms-" + POST_EXCLUDE_REGEXES ".*system32/.*\\.dll" + ) + set(CPACK_GENERATOR "ZIP") +endif() + +include(CPack) diff --git a/vcpkg-configuation.json b/vcpkg-configuation.json deleted file mode 100644 index 9f27bee..0000000 --- a/vcpkg-configuation.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "default-registry": { - "kind": "builtin", - "baseline": "9fbeedd5a58b94bcde42eb5be12652c2f27e08cf" - } -} - diff --git a/vcpkg.json b/vcpkg.json index 850e970..88e7a0e 100644 --- a/vcpkg.json +++ b/vcpkg.json @@ -1,6 +1,6 @@ { "name": "harbour", - "version-string": "0.2.0", + "version-string": "0.5.0", "dependencies": [ "sdl3", "freetype", From ee9df63d70a7549eb56c17a6ceaa4e73cbbd2dda Mon Sep 17 00:00:00 2001 From: ThatCodingFrog Date: Sat, 10 Oct 2026 15:24:48 -0600 Subject: [PATCH 2/3] Maybe automatically packaging would be good --- .github/workflows/build.yaml | 4 ++++ CPackConfig.cmake | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 27af534..4a050a3 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -111,6 +111,10 @@ jobs: working-directory: build continue-on-error: true + - name: Package with CPack + run: | + cd build && cpack + - name: Upload build artifacts if: always() uses: actions/upload-artifact@v7 diff --git a/CPackConfig.cmake b/CPackConfig.cmake index 95c23f7..f0448a8 100644 --- a/CPackConfig.cmake +++ b/CPackConfig.cmake @@ -25,6 +25,10 @@ if(WIN32) POST_EXCLUDE_REGEXES ".*system32/.*\\.dll" ) set(CPACK_GENERATOR "ZIP") +else() + set(CPACK_GENERATOR "ZIP") endif() + + include(CPack) From 8a6ae1dd75bc058cd75b9270461df85bd7c5d0cb Mon Sep 17 00:00:00 2001 From: ThatCodingFrog Date: Sat, 10 Oct 2026 16:11:56 -0600 Subject: [PATCH 3/3] Don't double compress --- .github/workflows/build.yaml | 4 ++-- CPackConfig.cmake | 2 -- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 4a050a3..f04c439 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -119,6 +119,6 @@ jobs: if: always() uses: actions/upload-artifact@v7 with: - name: Harbour-${{ matrix.os }} - path: build/Harbour-Ports-*.zip + path: ./build/Harbour-Ports-*.zip + archive: false retention-days: 30 \ No newline at end of file diff --git a/CPackConfig.cmake b/CPackConfig.cmake index f0448a8..207b35e 100644 --- a/CPackConfig.cmake +++ b/CPackConfig.cmake @@ -29,6 +29,4 @@ else() set(CPACK_GENERATOR "ZIP") endif() - - include(CPack)