Skip to content

Commit

Permalink
Github Actions: add libraries built with /MTd to MSVC artifacts
Browse files Browse the repository at this point in the history
Closes #110.
  • Loading branch information
magiblot committed Oct 1, 2023
1 parent b616650 commit 00ce133
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 13 deletions.
36 changes: 24 additions & 12 deletions .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -78,25 +78,31 @@ jobs:
shell: bash
run: cmake . -A Win32 -DTV_USE_STATIC_RTL=ON

- name: Build
- name: Build (Release) (library, apps)
shell: bash
run: cmake --build . --config Release -- -p:UseMultiToolTask=true -p:CL_MPcount=$(nproc)

- name: Build (RelWithDebInfo) (library)
shell: bash
run: cmake --build . --config $BUILD_TYPE -- -p:UseMultiToolTask=true -p:CL_MPcount=$(nproc)
run: cmake --build . --config RelWithDebInfo --target tvision -- -p:UseMultiToolTask=true -p:CL_MPcount=$(nproc)

- name: Upload Examples
uses: actions/upload-artifact@v3
with:
name: examples-x86
path: |
${{env.BUILD_TYPE}}/tvdemo.exe
${{env.BUILD_TYPE}}/tvedit.exe
${{env.BUILD_TYPE}}/tvhc.exe
Release/tvdemo.exe
Release/tvedit.exe
Release/tvhc.exe
- name: Upload Library
uses: actions/upload-artifact@v3
with:
name: library-x86
path: |
${{env.BUILD_TYPE}}/tvision.lib
Release/tvision.lib
RelWithDebInfo/tvision-relwithdebinfo.lib
RelWithDebInfo/tvision-relwithdebinfo.pdb
build-windows-msvc64:
name: Windows (MSVC) (x64)
Expand All @@ -108,25 +114,31 @@ jobs:
shell: bash
run: cmake . -A x64 -DTV_USE_STATIC_RTL=ON

- name: Build
- name: Build (Release) (library, apps)
shell: bash
run: cmake --build . --config Release -- -p:UseMultiToolTask=true -p:CL_MPcount=$(nproc)

- name: Build (RelWithDebInfo) (library)
shell: bash
run: cmake --build . --config $BUILD_TYPE -- -p:UseMultiToolTask=true -p:CL_MPcount=$(nproc)
run: cmake --build . --config RelWithDebInfo --target tvision -- -p:UseMultiToolTask=true -p:CL_MPcount=$(nproc)

- name: Upload Examples
uses: actions/upload-artifact@v3
with:
name: examples-x64
path: |
${{env.BUILD_TYPE}}/tvdemo.exe
${{env.BUILD_TYPE}}/tvedit.exe
${{env.BUILD_TYPE}}/tvhc.exe
Release/tvdemo.exe
Release/tvedit.exe
Release/tvhc.exe
- name: Upload Library
uses: actions/upload-artifact@v3
with:
name: library-x64
path: |
${{env.BUILD_TYPE}}/tvision.lib
Release/tvision.lib
RelWithDebInfo/tvision-relwithdebinfo.lib
RelWithDebInfo/tvision-relwithdebinfo.pdb
build-windows-mingw:
name: Windows (MinGW)
Expand Down
2 changes: 1 addition & 1 deletion source/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ endforeach()

if (TV_USE_STATIC_RTL) # Implies MSVC
target_compile_options(${PROJECT_NAME} PUBLIC
/MT$<$<CONFIG:Debug>:d>
/MT$<$<OR:$<CONFIG:Debug>,$<CONFIG:RelWithDebInfo>>:d>
)
endif()

Expand Down

0 comments on commit 00ce133

Please sign in to comment.