Skip to content

Commit

Permalink
Append OS name into the executable name
Browse files Browse the repository at this point in the history
  • Loading branch information
lbinria committed Feb 2, 2024
1 parent f598281 commit 79ddd65
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 7 deletions.
14 changes: 7 additions & 7 deletions .github/workflows/continuous.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,21 +26,21 @@ jobs:
submodules: recursive

- name: Configure CMake
run: cmake -B build -DCMAKE_BUILD_TYPE=${{ matrix.config }}
run: cmake -B build -DCMAKE_BUILD_TYPE=${{ matrix.config }} -DOSName=${{ matrix.cfg.os }}

- name: CMake Build
run: cmake --build build --parallel

- name: Run executable
run: build/delete_face_addon model=build/catorus.geogram facet_index=0
run: build/delete_face_addon-${{ matrix.cfg.os }} model=build/catorus.geogram facet_index=0

-
name: Deploy
uses: xresloader/upload-to-github-release@v1
with:
tags: true
draft: false
file: build/delete_face_addon
file: build/delete_face_addon-${{ matrix.cfg.os }}
overwrite: true
update_latest_release: true
verbose: true
Expand All @@ -55,27 +55,27 @@ jobs:
submodules: recursive

- name: Configure CMake
run: cmake -B build
run: cmake -B build -DOSName=win

- name: Release build
run: cmake --build build --parallel --config Release

- name: Release run
run: build/Release/delete_face_addon.exe model=build/catorus.geogram facet_index=0
run: build/Release/delete_face_addon-win.exe model=build/catorus.geogram facet_index=0

- name: Debug build
run: cmake --build build --parallel --config Debug

- name: Debug run
run: build/Debug/delete_face_addon.exe model=build/catorus.geogram facet_index=0
run: build/Debug/delete_face_addon-win.exe model=build/catorus.geogram facet_index=0

-
name: Deploy
uses: xresloader/upload-to-github-release@v1
with:
tags: true
draft: false
file: build/delete_face_addon.exe
file: build/Release/delete_face_addon-win.exe
overwrite: true
update_latest_release: true
verbose: true
7 changes: 7 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ project(graphite-addon-examples LANGUAGES C CXX )
set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

message("OSName=" ${OSName})

# Get config
get_property(is_multi_config GLOBAL PROPERTY GENERATOR_IS_MULTI_CONFIG)
if(NOT is_multi_config AND NOT (CMAKE_BUILD_TYPE OR DEFINED ENV{CMAKE_BUILD_TYPE}))
Expand Down Expand Up @@ -40,6 +42,11 @@ IF (NOT WIN32)
target_link_libraries(delete_face_addon m)
ENDIF()

set_target_properties(
delete_face_addon
PROPERTIES
OUTPUT_NAME "delete_facet_addon-${OSName}"
)


file(COPY assets/catorus.geogram DESTINATION .)

0 comments on commit 79ddd65

Please sign in to comment.