From 992b93edf9abe34fed15ade4ba9f7b2277d5b71b Mon Sep 17 00:00:00 2001 From: Henrik Hautakoski Date: Mon, 14 Nov 2022 22:22:42 +0100 Subject: [PATCH 1/2] .github/workflows/package.yml: Adding windows installer. --- .github/workflows/package.yml | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) diff --git a/.github/workflows/package.yml b/.github/workflows/package.yml index b125bec..2f59b48 100644 --- a/.github/workflows/package.yml +++ b/.github/workflows/package.yml @@ -8,7 +8,7 @@ on: jobs: # Debian package ubuntu: - name: Package + name: Package (Debian) runs-on: ubuntu-latest steps: - uses: actions/checkout@v1 @@ -29,3 +29,25 @@ jobs: if: startsWith(github.ref, 'refs/tags/') with: files: ${{ steps.package.outputs.ASSETS }} + + windows: + name: Package (Windows) + runs-on: windows-latest + steps: + - uses: actions/checkout@v1 + + - name: Configure + run: cmake --no-warn-unused-cli -G Ninja -B build -DCPACK_GENERATOR=NSIS -DCMAKE_BUILD_TYPE=Release . + + - name: Package + id: package + shell: bash + run: | + cmake --build build --target package + echo ASSET=$(ls -1 build/*.exe) >> $GITHUB_OUTPUT + + - name: Release + uses: softprops/action-gh-release@v1 + if: startsWith(github.ref, 'refs/tags/') + with: + files: ${{ steps.package.outputs.ASSET }} From 578c2ce757279ce9339d9f9f6311adf2cabdd766 Mon Sep 17 00:00:00 2001 From: Henrik Hautakoski Date: Mon, 14 Nov 2022 22:23:15 +0100 Subject: [PATCH 2/2] CMakeLists.txt: set CPACK_PACKAGE_INSTALL_DIRECTORY to only contain package name and not version. --- CMakeLists.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 27ce400..cf4626d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -42,6 +42,7 @@ endforeach(dict ${dictionaries}) set( CPACK_PACKAGE_FILE_NAME "${PROJECT_NAME}-${PROJECT_VERSION}") set( CPACK_PACKAGE_CONTACT ${PROJECT_MAINTAINER} ) set( CPACK_PACKAGE_VENDOR "Sw/eden" ) +set( CPACK_PACKAGE_INSTALL_DIRECTORY "${PROJECT_NAME}") # Archive specific set( CPACK_ARCHIVE_COMPONENT_INSTALL TRUE )