mirror of
https://github.com/GerbilSoft/rom-properties.git
synced 2025-06-18 11:35:38 -04:00
AppVeyor: Build with optional features turned off, then turned on.
This will probably increase build times, but it will improve coverage of lesser-used functionality.
This commit is contained in:
parent
bc096db57d
commit
0bcc45e8e5
12
appveyor.cmd
12
appveyor.cmd
@ -1,6 +1,14 @@
|
||||
@ECHO OFF
|
||||
cmake --version
|
||||
|
||||
:: Enable or disable optional features?
|
||||
if "%1" == "OFF" (
|
||||
set OPTEN=OFF
|
||||
) else (
|
||||
set OPTEN=ON
|
||||
)
|
||||
set "OPTFEAT=-DENABLE_EXTRA_SECURITY=%OPTEN% -DENABLE_JPEG=%OPTEN% -DENABLE_XML=%OPTEN% -DENABLE_DECRYPTION=%OPTEN% -DENABLE_UNICE68=%OPTEN% -DENABLE_LIBMSPACK=%OPTEN% -DENABLE_PVRTC=%OPTEN% -DENABLE_ZSTD=%OPTEN% -DENABLE_LZ4=%OPTEN% -DENABLE_LZO=%OPTEN%"
|
||||
|
||||
if "%compiler%" == "msvc2015" goto :msvc2015
|
||||
if "%compiler%" == "mingw-w64" goto :mingw-w64
|
||||
echo *** ERROR: Unsupported compiler '%compiler%'.
|
||||
@ -13,7 +21,7 @@ set CMAKE_GENERATOR_TOOLSET=v140_xp
|
||||
if "%platform%" == "x64" set "CMAKE_GENERATOR=%CMAKE_GENERATOR% Win64"
|
||||
mkdir build
|
||||
cd build
|
||||
cmake .. -G "%CMAKE_GENERATOR%" -DCMAKE_GENERATOR_TOOLSET=%CMAKE_GENERATOR_TOOLSET% -DENABLE_EXTRA_SECURITY=ON -DENABLE_JPEG=ON -DBUILD_TESTING=ON -DENABLE_LTO=OFF -DENABLE_PCH=ON
|
||||
cmake .. -G "%CMAKE_GENERATOR%" -DCMAKE_GENERATOR_TOOLSET=%CMAKE_GENERATOR_TOOLSET% -DENABLE_EXTRA_SECURITY=ON -DENABLE_JPEG=ON -DBUILD_TESTING=ON -DENABLE_LTO=OFF -DENABLE_PCH=ON %OPTFEAT%
|
||||
exit /b %ERRORLEVEL%
|
||||
|
||||
:mingw-w64
|
||||
@ -27,5 +35,5 @@ set "PATH=%MINGW64_ROOT%\bin;%PATH%"
|
||||
|
||||
mkdir build
|
||||
cd build
|
||||
cmake .. -G "MinGW Makefiles" -DCMAKE_PREFIX_PATH=%MINGW64_ROOT% -DCMAKE_C_COMPILER=%MINGW64_ROOT%/bin/gcc.exe -DCMAKE_CXX_COMPILER=%MINGW64_ROOT%/bin/g++.exe -DCMAKE_BUILD_TYPE=%configuration% -DENABLE_JPEG=ON -DBUILD_TESTING=ON -DENABLE_LTO=OFF -DENABLE_PCH=ON
|
||||
cmake .. -G "MinGW Makefiles" -DCMAKE_PREFIX_PATH=%MINGW64_ROOT% -DCMAKE_C_COMPILER=%MINGW64_ROOT%/bin/gcc.exe -DCMAKE_CXX_COMPILER=%MINGW64_ROOT%/bin/g++.exe -DCMAKE_BUILD_TYPE=%configuration% -DENABLE_JPEG=ON -DBUILD_TESTING=ON -DENABLE_LTO=OFF -DENABLE_PCH=ON %OPTFEAT%
|
||||
exit /b %ERRORLEVEL%
|
||||
|
10
appveyor.yml
10
appveyor.yml
@ -48,14 +48,20 @@ environment:
|
||||
configuration: Debug
|
||||
compiler: mingw-w64
|
||||
|
||||
# Run CMake.
|
||||
# Run CMake with optional features turned off initially.
|
||||
before_build:
|
||||
- cd %APPVEYOR_BUILD_FOLDER%
|
||||
- appveyor.cmd
|
||||
- appveyor.cmd OFF
|
||||
|
||||
# Build once with optional features turned off,
|
||||
# then build again with optional features turned on.
|
||||
build_script:
|
||||
- cd %APPVEYOR_BUILD_FOLDER%\build
|
||||
- cmake --build . --config %configuration%
|
||||
- cd ..
|
||||
- appveyor.cmd ON
|
||||
- cd %APPVEYOR_BUILD_FOLDER%\build
|
||||
- cmake --build . --config %configuration%
|
||||
|
||||
test_script:
|
||||
- cd %APPVEYOR_BUILD_FOLDER%\build
|
||||
|
Loading…
Reference in New Issue
Block a user