diff --git a/ports/ci/appveyor/build.bat b/ports/ci/appveyor/build.bat index 4adba44..833a013 100755 --- a/ports/ci/appveyor/build.bat +++ b/ports/ci/appveyor/build.bat @@ -22,18 +22,19 @@ echo. mkdir build-x64 cd build-x64 +setlocal +if "%CMAKE_GENERATOR%" == "MSYS Makefiles" set PATH=C:\msys64\mingw64\bin;C:\msys64\usr\bin;%PATH% if "%CMAKE_GENERATOR%" == "MSYS Makefiles" ( - setlocal - set PATH=C:\msys64\mingw64\bin;C:\msys64\usr\bin;%PATH% cmake ^ -G "%CMAKE_GENERATOR%" ^ -DCMAKE_INSTALL_PREFIX="%INSTALL_PREFIX%" ^ .. cmake --build . - endlocal ) +endlocal + if "%CMAKE_GENERATOR:~0,13%" == "Visual Studio" ( cmake ^ -G "%CMAKE_GENERATOR%" ^ @@ -52,18 +53,19 @@ echo. mkdir build-x86 cd build-x86 +setlocal +if "%CMAKE_GENERATOR%" == "MSYS Makefiles" set PATH=C:\msys64\mingw32\bin;C:\msys64\usr\bin;%PATH% if "%CMAKE_GENERATOR%" == "MSYS Makefiles" ( - setlocal - set PATH=C:\msys64\mingw32\bin;C:\msys64\usr\bin;"%PATH%" cmake ^ -G "%CMAKE_GENERATOR%" ^ -DCMAKE_INSTALL_PREFIX="%INSTALL_PREFIX%" ^ .. cmake --build . - endlocal ) +endlocal + if "%CMAKE_GENERATOR:~0,13%" == "Visual Studio" ( cmake ^ -G "%CMAKE_GENERATOR%" ^ diff --git a/ports/ci/appveyor/install_deps.bat b/ports/ci/appveyor/install_deps.bat index e7b4211..d892137 100755 --- a/ports/ci/appveyor/install_deps.bat +++ b/ports/ci/appveyor/install_deps.bat @@ -18,10 +18,10 @@ REM Web-Site: http://webcamoid.github.io/ rem Installing various utilities choco install -y jfrog-cli +setlocal +if "%CMAKE_GENERATOR%" == "MSYS Makefiles" set PATH=C:\msys64\usr\bin;%PATH% if "%CMAKE_GENERATOR%" == "MSYS Makefiles" ( - setlocal - set PATH=C:\msys64\usr\bin;%PATH% pacman -Syy pacman --noconfirm --needed -S ^ cmake ^ @@ -33,5 +33,6 @@ if "%CMAKE_GENERATOR%" == "MSYS Makefiles" ( mingw-w64-i686-cmake ^ mingw-w64-x86_64-pkg-config ^ mingw-w64-i686-pkg-config - endlocal ) + +endlocal