From 1ff3445209d193a7a195b20f3c796fc516090efd Mon Sep 17 00:00:00 2001 From: Cameron Gutman Date: Sat, 18 Jan 2020 18:22:11 -0800 Subject: [PATCH] Add AppVeyor CI for Windows --- CMakeLists.txt | 2 +- appveyor.yml | 22 ++++++++++++++-------- 2 files changed, 15 insertions(+), 9 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 0d01294e..6afd128d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -35,7 +35,6 @@ if(WIN32) set_source_files_properties(ViGEmClient/src/ViGEmClient.cpp PROPERTIES COMPILE_DEFINITIONS "UNICODE=1;ERROR_INVALID_DEVICE_OBJECT_PARAMETER=650") set_source_files_properties(ViGEmClient/src/ViGEmClient.cpp PROPERTIES COMPILE_FLAGS "-Wno-unknown-pragmas -Wno-misleading-indentation -Wno-class-memaccess") else() - set(Boost_USE_STATIC_LIBS ON) find_package(X11 REQUIRED) set(PLATFORM_TARGET_FILES sunshine/platform/linux.cpp @@ -58,6 +57,7 @@ else() /usr/include/libevdev-1.0) endif() +set(Boost_USE_STATIC_LIBS ON) find_package(Boost COMPONENTS log filesystem REQUIRED) set(SUNSHINE_TARGET_FILES diff --git a/appveyor.yml b/appveyor.yml index 627a5e33..046629db 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -1,4 +1,6 @@ -image: Ubuntu +image: + - Ubuntu + - Visual Studio 2019 environment: matrix: @@ -6,11 +8,12 @@ environment: - BUILD_TYPE: Release install: - - sudo add-apt-repository ppa:hnakamur/icu - - sudo add-apt-repository ppa:hnakamur/boost - - sudo apt update - - sudo apt install -y cmake libssl-dev libavdevice-dev libboost-thread1.67-dev libboost-filesystem1.67-dev libboost-log1.67-dev libpulse-dev libopus-dev libxtst-dev libx11-dev libxfixes-dev libevdev-dev libxcb1-dev libxcb-shm0-dev libxcb-xfixes0-dev - - sudo update-alternatives --set gcc /usr/bin/gcc-8 + - sh: sudo add-apt-repository ppa:hnakamur/icu + - sh: sudo add-apt-repository ppa:hnakamur/boost + - sh: sudo apt update + - sh: sudo apt install -y cmake libssl-dev libavdevice-dev libboost-thread1.67-dev libboost-filesystem1.67-dev libboost-log1.67-dev libpulse-dev libopus-dev libxtst-dev libx11-dev libxfixes-dev libevdev-dev libxcb1-dev libxcb-shm0-dev libxcb-xfixes0-dev + - sh: sudo update-alternatives --set gcc /usr/bin/gcc-8 + - cmd: C:\msys64\usr\bin\bash -lc "pacman --needed --noconfirm -S mingw-w64-x86_64-openssl mingw-w64-x86_64-cmake mingw-w64-x86_64-toolchain mingw-w64-x86_64-ffmpeg mingw-w64-x86_64-boost" before_build: - git submodule update --init --recursive @@ -18,5 +21,8 @@ before_build: - cd build build_script: - - cmake -DCMAKE_BUILD_TYPE=$BUILD_TYPE .. - - make -j$(nproc) \ No newline at end of file + - cmd: set PATH=C:\msys64\mingw64\bin + - sh: cmake -DCMAKE_BUILD_TYPE=$BUILD_TYPE .. + - cmd: cmake -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DOPENSSL_ROOT_DIR=C:\OpenSSL-v111-Win64 -G "MinGW Makefiles" .. + - sh: make -j$(nproc) + - cmd: mingw32-make -j2 \ No newline at end of file