Skip to content
This repository has been archived by the owner on Jan 6, 2023. It is now read-only.

Commit

Permalink
Only use sccache for shared(debug) builds
Browse files Browse the repository at this point in the history
  • Loading branch information
John Kleinschmidt committed Apr 25, 2018
1 parent d57361c commit ae29081
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 12 deletions.
26 changes: 18 additions & 8 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,6 @@ jobs:
- run:
name: Update
command: script/update --clean -t $TARGET_ARCH --use-bundled-sccache
- run:
name: Check sccache stats before build
command: script/sccache -s
- run:
name: Build shared library
command: script/build -t $TARGET_ARCH -c $COMPONENT
Expand Down Expand Up @@ -56,7 +53,7 @@ jobs:
command: script/bootstrap
- run:
name: Update
command: script/update --clean -t $TARGET_ARCH --use-bundled-sccache
command: script/update --clean -t $TARGET_ARCH
- run:
name: Build static library
command: script/build -t $TARGET_ARCH -c $COMPONENT
Expand Down Expand Up @@ -99,6 +96,9 @@ jobs:
- run:
name: Build FFmpeg
command: script/build -t $TARGET_ARCH -c ffmpeg
- run:
name: Check sccache stats after build
command: script/sccache -s
- run:
name: Create distribution
command: script/create-dist -t $TARGET_ARCH -c $COMPONENT
Expand Down Expand Up @@ -128,7 +128,7 @@ jobs:
command: script/bootstrap
- run:
name: Update
command: script/update --clean -t $TARGET_ARCH --use-bundled-sccache
command: script/update --clean -t $TARGET_ARCH
- run:
name: Build static library
command: script/build -t $TARGET_ARCH -c $COMPONENT
Expand Down Expand Up @@ -174,6 +174,9 @@ jobs:
- run:
name: Build FFmpeg
command: script/build -t $TARGET_ARCH -c ffmpeg
- run:
name: Check sccache stats after build
command: script/sccache -s
- run:
name: Create shared distribution
command: script/create-dist -t $TARGET_ARCH -c $COMPONENT
Expand Down Expand Up @@ -208,7 +211,7 @@ jobs:
command: script/bootstrap
- run:
name: Update
command: script/update --clean -t $TARGET_ARCH --use-bundled-sccache
command: script/update --clean -t $TARGET_ARCH
- run:
name: Build static library
command: script/build -t $TARGET_ARCH -c $COMPONENT
Expand Down Expand Up @@ -254,6 +257,9 @@ jobs:
- run:
name: Build FFmpeg
command: script/build -t $TARGET_ARCH -c ffmpeg
- run:
name: Check sccache stats after build
command: script/sccache -s
- run:
name: Create shared distribution
command: script/create-dist -t $TARGET_ARCH -c $COMPONENT
Expand Down Expand Up @@ -288,7 +294,7 @@ jobs:
command: script/bootstrap
- run:
name: Update
command: script/update --clean -t $TARGET_ARCH --use-bundled-sccache
command: script/update --clean -t $TARGET_ARCH
- run:
name: Build static library
command: script/build -t $TARGET_ARCH -c $COMPONENT
Expand Down Expand Up @@ -331,6 +337,9 @@ jobs:
- run:
name: Build FFmpeg
command: script/build -t $TARGET_ARCH -c ffmpeg
- run:
name: Check sccache stats after build
command: script/sccache -s
- run:
name: Create distribution
command: script/create-dist -t $TARGET_ARCH -c $COMPONENT
Expand Down Expand Up @@ -360,7 +369,8 @@ jobs:
command: script/bootstrap
- run:
name: Update
command: script/update --clean -t $TARGET_ARCH --use-bundled-sccache
command: script/update --clean -t $TARGET_ARCH

- run:
name: Build static library
command: script/build -t $TARGET_ARCH -c $COMPONENT
Expand Down
15 changes: 11 additions & 4 deletions vsts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,17 +47,24 @@ phases:
- bash: |
echo "===Updating for $TARGET_ARCH===" > >(tee -a buildlog.txt) 2> >(tee -a buildlog.txt >&2)
script/update --clean -t $TARGET_ARCH --use-bundled-sccache > >(tee -a buildlog.txt) 2> >(tee -a buildlog.txt >&2)
if [ "$COMPONENT" == "shared_library" ]; then
script/update --clean -t $TARGET_ARCH --use-bundled-sccache > >(tee -a buildlog.txt) 2> >(tee -a buildlog.txt >&2)
else
script/update --clean -t $TARGET_ARCH > >(tee -a buildlog.txt) 2> >(tee -a buildlog.txt >&2)
name: Update
- bash: |
script/sccache --start-server --azure_container $(SCCACHE_AZURE_BLOB_CONTAINER) --azure_connection "$(SCCACHE_AZURE_CONNECTION_STRING)" > >(tee -a buildlog.txt) 2> >(tee -a buildlog.txt >&2)
script/sccache -s > >(tee -a buildlog.txt) 2> >(tee -a buildlog.txt >&2)
if [ "$COMPONENT" == "shared_library" ]; then
script/sccache --start-server --azure_container $(SCCACHE_AZURE_BLOB_CONTAINER) --azure_connection "$(SCCACHE_AZURE_CONNECTION_STRING)" > >(tee -a buildlog.txt) 2> >(tee -a buildlog.txt >&2)
script/sccache -s > >(tee -a buildlog.txt) 2> >(tee -a buildlog.txt >&2)
fi
echo "===Building $COMPONENT for $TARGET_ARCH===" > >(tee -a buildlog.txt) 2> >(tee -a buildlog.txt >&2)
script/build -t $TARGET_ARCH -c $COMPONENT > >(tee -a buildlog.txt) 2> >(tee -a buildlog.txt >&2)
echo "===Building ffmpeg for $TARGET_ARCH===" > >(tee -a buildlog.txt) 2> >(tee -a buildlog.txt >&2)
script/build -t $TARGET_ARCH -c ffmpeg > >(tee -a buildlog.txt) 2> >(tee -a buildlog.txt >&2)
script/sccache --stop-server > >(tee -a buildlog.txt) 2> >(tee -a buildlog.txt >&2)
if [ "$COMPONENT" == "shared_library" ]; then
script/sccache --stop-server > >(tee -a buildlog.txt) 2> >(tee -a buildlog.txt >&2)
fi
name: Build
- bash: |
Expand Down

0 comments on commit ae29081

Please sign in to comment.