Split st and mt core build cache

This commit is contained in:
Jerome Wu 2022-10-05 16:56:29 +08:00
parent 5031606c42
commit 44ea5f04dc
2 changed files with 7 additions and 10 deletions

View File

@ -21,12 +21,16 @@ jobs:
id: cache-build
uses: actions/cache@v3
with:
path: build-cache
key: build-cache-v1-${{ hashFiles('Dockerfile', 'build/*') }}
path: |
build-cache-st
build-cache-mt
key: build-cache-v1-${{ hashFiles('Dockerfile', 'Makefile', 'build/*') }}
restore-keys: |
build-cache-v1-
- name: Build ffmpeg-core
run: make ci ci-mt
run: make prd EXTRA_ARGS="--cache-from=type=local,src=build-cache-st --cache-to=type=local,dest=build-cache-st,mode=max"
- name: Build ffmpet-core-mt
run: make prd-mt EXTRA_ARGS="--cache-from=type=local,src=build-cache-mt --cache-to=type=local,dest=build-cache-mt,mode=max"
- name: Upload core and core-mt
uses: actions/upload-artifact@v3
with:

View File

@ -3,7 +3,6 @@ all: dev
MT_FLAGS := -sUSE_PTHREADS -pthread
DEV_ARGS := --progress=plain
CI_ARGS := --cache-from=type=local,src=build-cache --cache-to=type=local,dest=build-cache,mode=max
DEV_CFLAGS := --profiling
DEV_MT_CFLAGS := $(DEV_CFLAGS) $(MT_FLAGS)
@ -49,9 +48,3 @@ prd:
prd-mt:
make build-mt EXTRA_CFLAGS="$(PROD_MT_CFLAGS)"
ci:
make prd EXTRA_ARGS="$(CI_ARGS)"
ci-mt:
make prd-mt EXTRA_ARGS="$(CI_ARGS)"