-
Notifications
You must be signed in to change notification settings - Fork 115
/
Copy pathappveyor.yml
98 lines (87 loc) · 3.21 KB
/
appveyor.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
# can not have space before '&&', ')' when setting env var in multiple line commands
branches:
only:
- master
- prelease
- ci
- appveyor
# https://www.appveyor.com/docs/build-environment/#using-multiple-images-for-the-same-build
# APPVEYOR_BUILD_WORKER_IMAGE is used in environment matrix, image is not
environment:
matrix:
- _CC: VS2019
_PLATFORM: desktop
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
- _CC: VS2019
_PLATFORM: store
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
- _CC: MINGW
_PLATFORM: desktop
_CACHE: msys64
- _ARCH: arm
_CC: VS2013
_PLATFORM: phone
- _ARCH: x86
_CC: VS2013
_PLATFORM: store
- _ARCH: x86
_CC: VS2013
_PLATFORM: desktop
matrix:
fast_finish: false
init:
- echo NUMBER_OF_PROCESSORS=%NUMBER_OF_PROCESSORS%
- echo PROCESSOR_IDENTIFIER=%PROCESSOR_IDENTIFIER%
- set MSYS2_PATH_TYPE=inherit
- set MSYS2_DIR=C:\msys64
- set
#https://stackoverflow.com/questions/37627248/how-to-split-a-command-over-multiple-lines-in-appveyor-yml
install:
# can not starts with %
- git submodule update --init
- if /i %_CC%==MinGW (
C:\msys64\usr\bin\pacman -Syyuu --noconfirm &&
C:\msys64\usr\bin\pacman -Suu --noconfirm &&
C:\msys64\usr\bin\pacman -S --noconfirm --needed mingw-w64-i686-gcc mingw-w64-x86_64-gcc &&
C:\msys64\usr\bin\pacman -Sc --noconfirm
)
- C:\msys64\usr\bin\pacman -S --noconfirm --needed diffutils patch pkg-config nasm yasm
- set FF_BRANCH=%FF_VERSION%
- if not [%FF_BRANCH%]==[master] set FF_BRANCH=release/%FF_VERSION%
- git clone -b %FF_BRANCH% --depth 1 --no-tags https://git.ffmpeg.org/ffmpeg.git ffmpeg-%FF_VERSION%
- if /i %_PLATFORM%==desktop (
appveyor DownloadFile "https://sourceforge.net/projects/avbuild/files/dep/dep.7z/download" -FileName dep.7z &&
7z x -y dep.7z -otools &&
set PKG_CONFIG_PATH_MFX=%CD%\tools\%_CC%%_ARCH%\lib\pkgconfig)
before_build:
- set HOME=%CD%
- set MSYSTEM=%_CC%%_ARCH% # ffmpeg configure refuses to build for mingw in pure msys. so we lie. MUST use upper case. ommited by msvc
- if not [%CONFIG_SUFFIX%]==[] copy /y config%CONFIG_SUFFIX%.sh config.sh
- set FFSRC=%CD%\ffmpeg-%FF_VERSION%
build_script:
# V=1 to check libmfx error, but the error disappears if V=1. WTF
- if /i not %_CC%==MinGW if /i not %_PLATFORM%==store set V=1
- if /i %_CC%==MinGW (
set VC_BUILD=false&&
set MSYS2_PATH_TYPE=&&
C:\msys64\usr\bin\bash.exe --login avbuild.sh mingw
) else (
set BUILD_NOW=true&&
tools\vcbuild.bat %_CC% %_PLATFORM% %_ARCH% all
)
after_build:
- set SDK_NAME=ffmpeg-%FF_VERSION%-%_PLATFORM%-%_CC%%_ARCH%%CONFIG_SUFFIX%
- move sdk* %SDK_NAME%
- 7z a %SDK_NAME%.7z %SDK_NAME%
test: off
artifacts:
- path: '%SDK_NAME%.7z' # relative to repo root
deploy:
provider: FTP
protocol: sftp
host: frs.sourceforge.net
username: novesky
password:
secure: 2mQg4oxdX8S7rMJz2TCGGg==
folder: /home/frs/project/avbuild/windows-%_PLATFORM% # why always relative path even if starts with / ? I have to make a link home/frs/project/avbuild/xxx => /home/frs/project/avbuild/xxx
active_mode: false