Browse Source

Try to enable AUTO_RCC on msvc

Ivan Savenko 1 year ago
parent
commit
7fccfb66de
2 changed files with 11 additions and 7 deletions
  1. 10 3
      .github/workflows/github.yml
  2. 1 4
      launcher/CMakeLists.txt

+ 10 - 3
.github/workflows/github.yml

@@ -66,7 +66,7 @@ jobs:
             pack: 1
             pack_type: RelWithDebInfo
             extension: exe
-            preset: windows-msvc-release-ccache
+            preset: windows-msvc-release
           - platform: mingw
             os: ubuntu-22.04
             test: 0
@@ -207,8 +207,15 @@ jobs:
 
     - name: Configure
       run: |
-        if [[ ${{matrix.preset}} == linux-gcc-test ]]; then GCC14=1; fi
-        cmake -DENABLE_CCACHE:BOOL=ON --preset ${{ matrix.preset }} ${GCC14:+-DCMAKE_C_COMPILER=gcc-14 -DCMAKE_CXX_COMPILER=g++-14}
+        if [[ ${{matrix.preset}} == linux-gcc-test ]]
+        then
+            cmake -DENABLE_CCACHE:BOOL=ON -DCMAKE_C_COMPILER=gcc-14 -DCMAKE_CXX_COMPILER=g++-14 --preset ${{ matrix.preset }}
+        elif [[ ${{matrix.platform}} != msvc ]]
+        then
+            cmake -DENABLE_CCACHE:BOOL=ON --preset ${{ matrix.preset }}
+        else
+            cmake --preset ${{ matrix.preset }}
+        fi
 
     - name: Build
       run: |

+ 1 - 4
launcher/CMakeLists.txt

@@ -112,12 +112,9 @@ endif()
 
 assign_source_group(${launcher_SRCS} ${launcher_HEADERS} ${launcher_RESOURCES} ${launcher_TS} ${launcher_ICON})
 
-# TODO: enabling AUTORCC breaks msvc build on CI
 set(CMAKE_AUTOMOC ON)
 set(CMAKE_AUTOUIC ON)
-if(NOT (MSVC AND "$ENV{GITHUB_ACTIONS}" STREQUAL true))
-	set(CMAKE_AUTORCC ON)
-endif()
+set(CMAKE_AUTORCC ON)
 
 if(POLICY CMP0071)
 	cmake_policy(SET CMP0071 NEW)