Files
AlexandraTrifan c7e3463d46 appveyor.yml: Make sure the right drivers are copied in
the installer and drop Windows version check for driver
install option.

Signed-off-by: Alexandra Trifan <Alexandra.Trifan@analog.com>
2018-02-02 11:11:15 +02:00

80 lines
3.3 KiB
YAML

os: Windows Server 2012 R2
platform:
- x86
install:
- ps: (new-object System.Net.WebClient).Downloadfile("http://www.7-zip.org/a/7z1514-x64.exe", "c:\projects\7zip_installer.exe")
- c:\projects\7zip_installer.exe /S /D=c:\projects\7zip_tool
- set PATH=c:\projects\7zip_tool;%PATH%
- ps: |
If (!(Test-Path -Path "c:\mingw.7z")) {
(new-object System.Net.WebClient).Downloadfile("https://sourceforge.net/projects/mingw-w64/files/Toolchains%20targetting%20Win32/Personal%20Builds/mingw-builds/5.2.0/threads-posix/dwarf/i686-5.2.0-release-posix-dwarf-rt_v4-rev0.7z", "c:\mingw.7z")
}
- 7z x -y "c:\mingw.7z" -o"C:\" > nul
- ps: |
If (!(Test-Path -Path "c:\msys.zip")) {
(new-object System.Net.WebClient).Downloadfile("https://sourceforge.net/projects/mingw-w64/files/External%20binary%20packages%20%28Win64%20hosted%29/MSYS%20%2832-bit%29/MSYS-20111123.zip", "c:\msys.zip")
}
- 7z x -y "c:\msys.zip" -o"C:\" > nul
- set QTDIR=C:\Qt\5.4\mingw491_32
- set PATH=C:\Program Files (x86)\MSBuild\12.0\bin\;C:\mingw32\bin;C:\msys\bin\;%QTDIR%\bin;%PATH%
- ps: (new-object System.Net.WebClient).Downloadfile("http://swdownloads.analog.com/cse/build/libusb-1.0-hp.7z", "c:\libusb.7z")
- 7z x -y "c:\libusb.7z" -o"C:\libusb" > nul
- git clone https://github.com/analogdevicesinc/libsmu.git C:\libsmu
- if not exist "c:\projects\pixelpulse2\distrib\driver" mkdir c:\projects\pixelpulse2\distrib\driver
- copy C:\libsmu\dist\m1k-winusb.inf c:\projects\pixelpulse2\distrib\driver
- copy C:\libsmu\dist\\m1k-winusbx86.cat c:\projects\pixelpulse2\distrib\driver
- copy C:\libsmu\dist\m1k-winusbx64.cat c:\projects\pixelpulse2\distrib\driver
- 'appveyor DownloadFile "https://ci.appveyor.com/api/projects/analogdevicesinc/pixelpulse2-trayer/artifacts/pp2trayer.exe?branch=master" -FileName c:\projects\pixelpulse2\distrib\pp2trayer.exe'
# Install Inno Setup
- choco install InnoSetup
build_script:
#clone and build libsmu with mingw
- cd C:\libsmu
- mkdir build
- cd build
- cmake -G "MSYS Makefiles" \
-DLIBUSB_LIBRARIES="C:\\libusb\\MinGW32\\static\\libusb-1.0.a" \
-DLIBUSB_INCLUDE_DIRS="C:\\libusb\\include\\libusb-1.0" \
-DBoost_USE_STATIC_LIBS=ON \
-DBUILD_STATIC_LIB=OFF \
-DBUILD_EXAMPLES=OFF \
-DBUILD_TESTS=OFF \
-DBOOST_ROOT="C:\\Libraries\\boost_1_62_0" \
-DBUILD_PYTHON=OFF \
..
- mingw32-make -j8
- cd c:\projects\pixelpulse2
- qmake pixelpulse2.pro "LIBSMU_LIBRARY = C:\libsmu\build\src\libsmu.dll.a" "LIBSMU_INCLUDE_PATH = C:\libsmu\include"
- mingw32-make -j8
# Bundle all dependencies
- ps: |
windeployqt --qmldir qml release\pixelpulse2.exe --dir distrib
cp C:\OpenSSL-Win32\libeay32.dll distrib
cp C:\OpenSSL-Win32\libssl32.dll distrib
cp C:\OpenSSL-Win32\ssleay32.dll distrib
cp C:\OpenSSL-Win32\bin\msvcr120.dll distrib
cp C:\libsmu\build\src\libsmu.dll distrib
cp C:\mingw32\bin\libgomp-1.dll distrib
7z a -y distrib.zip distrib
# Build the installer
- set PATH=%PATH%;"C:\Program Files (x86)\Inno Setup 5"
- ISCC /Q pixelpulse2.iss
after_build:
- ps: |
appveyor PushArtifact release\pixelpulse2.exe
appveyor PushArtifact distrib.zip
appveyor PushArtifact C:\Pixelpulse2_win_setup.exe
cache:
- c:\mingw.7z -> appveyor.yml
- c:\msys.zip -> appveyor.yml