Merge pull request #621 from manongjohn/setup_build_caches
Setup ccache for Action builds
This commit is contained in:
commit
e472b8c3b0
4 changed files with 71 additions and 15 deletions
44
.github/workflows/linux_build.yml
vendored
44
.github/workflows/linux_build.yml
vendored
|
@ -7,24 +7,52 @@ jobs:
|
|||
runs-on: ubuntu-16.04
|
||||
strategy:
|
||||
matrix:
|
||||
compiler: [ clang ]
|
||||
compiler: [ gcc, clang ]
|
||||
include:
|
||||
- compiler: gcc
|
||||
cc: gcc
|
||||
cxx: g++
|
||||
- compiler: clang
|
||||
cc: clang
|
||||
cxx: clang++
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: Install Dependencies
|
||||
run: bash ./ci-scripts/linux/tahoma-install.sh
|
||||
run: |
|
||||
ci-scripts/linux/tahoma-install.sh
|
||||
sudo apt-get install ccache
|
||||
- uses: actions/cache@v2
|
||||
with:
|
||||
path: |
|
||||
/home/runner/.ccache
|
||||
/home/runner/work/tahoma2d/taoma2d/thirdparty/openh264
|
||||
/home/runner/work/tahoma2d/taoma2d/thirdparty/ffmpeg
|
||||
/home/runner/work/tahoma2d/taoma2d/thirdparty/ffmpeg_shared
|
||||
/home/runner/work/tahoma2d/taoma2d/thirdparty/opencv
|
||||
key: ${{ runner.os }}-${{ matrix.compiler }}-${{ github.sha }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-${{ matrix.compiler }}-
|
||||
${{ runner.os }}-
|
||||
- name: Build ffmpeg
|
||||
run: bash ./ci-scripts/linux/tahoma-buildffmpeg.sh
|
||||
run: |
|
||||
export CC="ccache ${{ matrix.cc }}"
|
||||
export CXX="ccache ${{ matrix.cxx }}"
|
||||
ci-scripts/linux/tahoma-buildffmpeg.sh
|
||||
- name: Build OpenCV
|
||||
run: bash ./ci-scripts/linux/tahoma-buildopencv.sh
|
||||
run: |
|
||||
export CC="ccache ${{ matrix.cc }}"
|
||||
export CXX="ccache ${{ matrix.cxx }}"
|
||||
ci-scripts/linux/tahoma-buildopencv.sh
|
||||
- name: Build Tahoma2D
|
||||
run: bash ./ci-scripts/linux/tahoma-build.sh
|
||||
run: |
|
||||
export CC="ccache ${{ matrix.cc }}"
|
||||
export CXX="ccache ${{ matrix.cxx }}"
|
||||
ci-scripts/linux/tahoma-build.sh
|
||||
- name: Create Package
|
||||
run: bash ./ci-scripts/linux/tahoma-buildpkg.sh
|
||||
run: |
|
||||
ci-scripts/linux/tahoma-buildpkg.sh
|
||||
mv toonz/build/Tahoma2D-linux.tar.gz toonz/build/Tahoma2D-linux-${{ matrix.compiler }}.tar.gz
|
||||
- uses: actions/upload-artifact@v1
|
||||
with:
|
||||
name: Tahoma2D-linux.tar.gz
|
||||
path: toonz/build/Tahoma2D-linux.tar.gz
|
||||
name: Tahoma2D-linux-${{ matrix.compiler }}.tar.gz
|
||||
path: toonz/build/Tahoma2D-linux-${{ matrix.compiler }}.tar.gz
|
||||
|
|
27
.github/workflows/macOS_build.yml
vendored
27
.github/workflows/macOS_build.yml
vendored
|
@ -8,13 +8,32 @@ jobs:
|
|||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: Install Dependencies
|
||||
run: bash ./ci-scripts/osx/tahoma-install.sh
|
||||
run: |
|
||||
ci-scripts/osx/tahoma-install.sh
|
||||
brew install ccache
|
||||
mkdir /Users/runner/.ccache
|
||||
- uses: actions/cache@v2
|
||||
with:
|
||||
path: |
|
||||
/Users/runner/.ccache
|
||||
/Users/runner/work/tahoma2d/taoma2d/thirdparty/aom
|
||||
/Users/runner/work/tahoma2d/taoma2d/thirdparty/ffmpeg
|
||||
/Users/runner/work/tahoma2d/taoma2d/thirdparty/ffmpeg_shared
|
||||
/Users/runner/work/tahoma2d/taoma2d/thirdparty/opencv
|
||||
key: ${{ runner.os }}-${{ github.sha }}
|
||||
restore-keys: ${{ runner.os }}-
|
||||
- name: Build ffmpeg
|
||||
run: bash ./ci-scripts/osx/tahoma-buildffmpeg.sh
|
||||
run: |
|
||||
export PATH="/usr/local/opt/ccache/libexec:$PATH"
|
||||
ci-scripts/osx/tahoma-buildffmpeg.sh
|
||||
- name: Build OpenCV
|
||||
run: bash ./ci-scripts/osx/tahoma-buildopencv.sh
|
||||
run: |
|
||||
export PATH="/usr/local/opt/ccache/libexec:$PATH"
|
||||
ci-scripts/osx/tahoma-buildopencv.sh
|
||||
- name: Build Tahoma2D
|
||||
run: bash ./ci-scripts/osx/tahoma-build.sh
|
||||
run: |
|
||||
export PATH="/usr/local/opt/ccache/libexec:$PATH"
|
||||
ci-scripts/osx/tahoma-build.sh
|
||||
- name: Create Package
|
||||
run: bash ./ci-scripts/osx/tahoma-buildpkg.sh
|
||||
- uses: actions/upload-artifact@v1
|
||||
|
|
|
@ -16,14 +16,17 @@ cd ..
|
|||
|
||||
echo ">>> Cloning ffmpeg"
|
||||
git clone https://git.ffmpeg.org/ffmpeg.git ffmpeg
|
||||
cp -R ffmpeg ffmpeg_shared
|
||||
|
||||
cd ffmpeg
|
||||
cd ffmpeg_shared
|
||||
echo "*" >| .gitignore
|
||||
|
||||
echo ">>> Configuring to build ffmpeg (shared)"
|
||||
export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig
|
||||
|
||||
./configure --prefix=/usr/local \
|
||||
--cc="$CC" \
|
||||
--cxx="$CXX" \
|
||||
--toolchain=hardened \
|
||||
--pkg-config-flags="--static" \
|
||||
--extra-cflags="-I/usr/local/include" \
|
||||
|
@ -64,10 +67,14 @@ sudo make install
|
|||
sudo ldconfig
|
||||
|
||||
echo ">>> Configuring to build ffmpeg (static)"
|
||||
cd ../ffmpeg
|
||||
echo "*" >| .gitignore
|
||||
|
||||
export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig
|
||||
|
||||
./configure --prefix=/usr/local \
|
||||
--cc="$CC" \
|
||||
--cxx="$CXX" \
|
||||
--pkg-config-flags="--static" \
|
||||
--extra-cflags="-I/usr/local/include -static" \
|
||||
--extra-ldflags="-L/usr/local/lib -static" \
|
||||
|
|
|
@ -26,8 +26,9 @@ cd ../..
|
|||
|
||||
echo ">>> Cloning ffmpeg"
|
||||
git clone https://git.ffmpeg.org/ffmpeg.git ffmpeg
|
||||
cp -R ffmpeg ffmpeg_shared
|
||||
|
||||
cd ffmpeg
|
||||
cd ffmpeg_shared
|
||||
echo "*" >| .gitignore
|
||||
|
||||
echo ">>> Configuring to build ffmpeg (shared)"
|
||||
|
@ -73,7 +74,8 @@ echo ">>> Installing ffmpeg (shared)"
|
|||
sudo make install
|
||||
|
||||
echo ">>> Configuring to build ffmpeg (static)"
|
||||
make clean
|
||||
cd ../ffmpeg
|
||||
echo "*" >| .gitignore
|
||||
|
||||
export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig
|
||||
export SDKROOT=`xcrun --show-sdk-path`
|
||||
|
|
Loading…
Reference in a new issue