Skip to content

Commit 214c2af

Browse files
committed
test
1 parent 4d15f4a commit 214c2af

File tree

3 files changed

+93
-2
lines changed

3 files changed

+93
-2
lines changed

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ run-name: Build ${{inputs.tag_name||github.ref_name}}
88

99
on:
1010
push:
11-
# tags: "*"
11+
tags: "*"
1212
workflow_dispatch:
1313
inputs:
1414
tag_name:

.github/workflows/test.yml

Lines changed: 91 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,91 @@
1+
env:
2+
MSYS2_PATH_TYPE: inherit
3+
SDK_VER: 10.0.22621.0
4+
TAG_NAME: ${{ inputs.tag_name||github.ref_name }}
5+
6+
name: Test
7+
run-name: Test ${{inputs.tag_name||github.ref_name}}
8+
9+
on:
10+
push:
11+
tags: "*"
12+
workflow_dispatch:
13+
inputs:
14+
tag_name:
15+
description: "Tag"
16+
required: true
17+
18+
jobs:
19+
build:
20+
strategy:
21+
matrix:
22+
arch: [x86, amd64, arm, arm64]
23+
type: [static, shared]
24+
license: [gpl, lgpl]
25+
fail-fast: false
26+
runs-on: windows-2022
27+
env:
28+
# amd64_arm,amd64_arm64,x86,amd64
29+
name: ffmpeg-${{ inputs.tag_name||github.ref_name }}-${{matrix.license}}-${{matrix.arch}}-${{matrix.type}}
30+
target: ${{contains(matrix.arch,'arm')&&format('amd64_{0}',matrix.arch)||matrix.arch}}
31+
steps:
32+
- name: Find MSVC
33+
shell: bash
34+
id: msvc
35+
run: |
36+
echo "installationPath=$(vswhere -all -legacy -property installationPath)">>$GITHUB_OUTPUT
37+
- uses: actions/checkout@v4
38+
with:
39+
ref: ${{env.TAG_NAME}}
40+
submodules: recursive
41+
42+
- uses: msys2/setup-msys2@v2
43+
with:
44+
install: >-
45+
diffutils
46+
make
47+
zip
48+
pkgconf
49+
yasm
50+
nasm
51+
52+
- name: Remove MSYS2 link
53+
shell: msys2 {0}
54+
run: |
55+
rm $(which link)
56+
rm -rf /usr/local
57+
58+
- name: Build
59+
shell: cmd
60+
run: |
61+
CALL "${{steps.msvc.outputs.installationPath}}\VC\Auxiliary\Build\vcvarsall.bat" ${{env.target}} ${{env.SDK_VER}}
62+
msys2 -c "./build.sh ${{matrix.arch}} ${{matrix.type}} ${{matrix.license}}"
63+
64+
- name: Debug log
65+
if: ${{ failure() }}
66+
shell: bash
67+
run: |
68+
echo [Debug]
69+
cat FFmpeg/ffbuild/config.log
70+
cat FFmpeg/ffbuild/config.mak
71+
cat FFmpeg/config.h
72+
73+
- name: Pack
74+
shell: msys2 {0}
75+
run: |
76+
CWD=$(pwd)
77+
cd /usr/local
78+
zip -9 ${CWD}/${{env.name}}.zip -r .
79+
cd ${CWD}
80+
sha1sum ${{env.name}}.zip >${{env.name}}.sha1
81+
./build-changelog.sh > changelog
82+
- name: Release
83+
if: ${{startsWith(github.ref, 'refs/tags/')}}
84+
uses: softprops/action-gh-release@v2
85+
with:
86+
tag_name: ${{env.TAG_NAME}}
87+
body_path: changelog
88+
prerelease: ${{contains(env.TAG_NAME,'dev')}}
89+
files: |
90+
${{env.name}}.zip
91+
${{env.name}}.sha1

build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ if [ -n "$ENABLE_LIBVPX" ]; then
122122
fi
123123
apply-patch libvpx libvpx.patch
124124
export
125-
AS=yasm AR=lib ARFLAGS= CC=cl CXX=cl LD=link STRIP=false target= ./build-make-dep.sh libvpx --target=$libvpx_target --as=yasm --disable-optimizations --disable-dependency-tracking --disable-runtime-cpu-detect --disable-thumb --disable-neon --enable-external-build --disable-unit-tests --disable-decode-perf-tests --disable-encode-perf-tests $LIBVPX_ARGS
125+
AS=yasm AR=lib ARFLAGS= CC=cl CXX=cl LD=link STRIP=false target= ./build-make-dep.sh libvpx --target=$libvpx_target --as=yasm --disable-optimizations --disable-dependency-tracking --disable-runtime-cpu-detect --disable-thumb --disable-neon --enable-external-build --disable-unit-tests --disable-decode-perf-tests --disable-encode-perf-tests --disable-examples $LIBVPX_ARGS
126126
FF_ARGS=--enable-libvpx
127127
fi
128128

0 commit comments

Comments
 (0)