From 44ea5f04dce6b3b958085993a278c9ab3f0a9851 Mon Sep 17 00:00:00 2001 From: Jerome Wu Date: Wed, 5 Oct 2022 16:56:29 +0800 Subject: [PATCH] Split st and mt core build cache --- .github/workflows/CI.yml | 10 +++++++--- Makefile | 7 ------- 2 files changed, 7 insertions(+), 10 deletions(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 8b4d1c1..144a98f 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -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: diff --git a/Makefile b/Makefile index 744b61c..8e260bc 100644 --- a/Makefile +++ b/Makefile @@ -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)"