233 lines
11 KiB
YAML
233 lines
11 KiB
YAML
kind: pipeline
|
|
type: docker
|
|
name: from-source-amd64
|
|
platform:
|
|
os: linux
|
|
arch: amd64
|
|
|
|
environment:
|
|
GOPROXY: direct
|
|
GOARCH: amd64
|
|
GOAMD64: v3
|
|
GOOS: linux
|
|
CFLAGS: "-march=native -Ofast"
|
|
LDFLAGS: "-flto"
|
|
PKG_CONFIG_PATH: "/drone/src/build_deps/lib/pkgconfig"
|
|
LD_LIBRARY_PATH: "/drone/src/build_deps/lib"
|
|
CGO_CFLAGS: "-I/drone/src/build_deps/include"
|
|
CGO_LDFLAGS: "-L/drone/src/build_deps/lib"
|
|
|
|
workspace:
|
|
path: /drone/src
|
|
|
|
steps:
|
|
- name: prepare-testdata
|
|
image: alpine
|
|
commands:
|
|
- apk update
|
|
- apk add --no-cache wget bash
|
|
- ./testdata/prepare.sh
|
|
- name: build-x264
|
|
image: golang:1.19-bullseye
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc g++ bash make libtool nasm
|
|
- cd /tmp
|
|
- git clone --depth 1 --branch stable https://code.videolan.org/videolan/x264.git && cd x264 && ./configure --disable-cli --disable-ffms --disable-lavf --disable-swscale --enable-static --bit-depth=all --chroma-format=all --enable-lto --enable-pic --disable-opencl --prefix=/drone/src/build_deps && make -j$(nproc) && make install && cd ..
|
|
- name: build-vmaf
|
|
image: golang:1.19-bullseye
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc g++ bash cmake make libtool meson ccache nasm perl xxd pkg-config
|
|
- cd /tmp
|
|
- git clone --depth 1 --branch v2.3.1 https://github.com/Netflix/vmaf.git && cd vmaf/libvmaf && meson setup build . --prefix /drone/src/build_deps --buildtype release -Denable_float=true -Dbuilt_in_models=true && ninja -vC build && ninja -vC build install && cd ../..
|
|
- name: build-libaom
|
|
image: golang:1.19-bullseye
|
|
depends_on:
|
|
- build-vmaf
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc g++ bash cmake make libtool ccache nasm perl xxd pkg-config
|
|
- cd /tmp
|
|
- git clone --depth 1 --branch v3.5.0 https://aomedia.googlesource.com/aom.git && cd aom && mkdir b && cd b && cmake .. -DCMAKE_INTERPROCEDURAL_OPTIMIZATION=ON -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=ON -D CMAKE_INSTALL_PREFIX:PATH=/drone/src/build_deps -DENABLE_DOCS=OFF -DENABLE_EXAMPLES=OFF -DENABLE_TOOLS=OFF -DENABLE_TESTS=OFF -DENABLE_CCACHE=ON -DCONFIG_FRAME_PARALLEL_ENCODE=1 -DCONFIG_AV1_TEMPORAL_DENOISING=1 -DCONFIG_BITRATE_ACCURACY=1 -DCONFIG_TUNE_VMAF=1 -DCONFIG_NN_V2=1 -DCONFIG_RT_ML_PARTITIONING=1 -DCONFIG_THREE_PASS=1 -DCONFIG_AV1_ENCODER=1 -DCONFIG_AV1_DECODER=1 && make -j$(nproc) && make install && cd ../..
|
|
- name: build-dav1d
|
|
image: golang:1.19-bullseye
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc g++ bash libtool meson ccache nasm pkg-config
|
|
- cd /tmp
|
|
- git clone --depth 1 --branch 1.0.0 https://code.videolan.org/videolan/dav1d.git && cd dav1d && meson setup build . --prefix /drone/src/build_deps --buildtype release --default-library=static && ninja -vC build && ninja -vC build install && cd ..
|
|
- name: test-nocgo-short
|
|
image: golang:1.19-alpine
|
|
depends_on:
|
|
- prepare-testdata
|
|
commands:
|
|
- apk update
|
|
- apk add --no-cache git
|
|
- CGO_ENABLED=0 go test -p 1 -failfast -timeout 60m -cover -gcflags=-d=checkptr -v ./... -test.short
|
|
- name: test-cgo-libdav1d-long
|
|
image: golang:1.19-bullseye
|
|
depends_on:
|
|
- build-dav1d
|
|
- prepare-testdata
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc pkg-config
|
|
- go test -p 1 -failfast -timeout 60m -cover -gcflags=-d=checkptr -v -tags=disable_library_libaom,disable_library_libx264,disable_library_libvmaf ./decoder/libdav1d
|
|
- name: test-cgo-libaom-long
|
|
image: golang:1.19-bullseye
|
|
depends_on:
|
|
- build-libaom
|
|
- prepare-testdata
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc pkg-config
|
|
- go test -p 1 -failfast -timeout 60m -cover -gcflags=-d=checkptr -v -tags=disable_library_libdav1d,disable_library_libx264,disable_library_libvmaf ./encoder/libaom
|
|
- name: test-cgo-libx264-long
|
|
image: golang:1.19-bullseye
|
|
depends_on:
|
|
- build-x264
|
|
- prepare-testdata
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc pkg-config
|
|
- go test -p 1 -failfast -timeout 60m -cover -gcflags=-d=checkptr -v -tags=disable_library_libdav1d,disable_library_libaom,disable_library_libvmaf ./encoder/libx264
|
|
- name: test-cgo-libvmaf-long
|
|
image: golang:1.19-bullseye
|
|
depends_on:
|
|
- build-dav1d
|
|
- build-vmaf
|
|
- prepare-testdata
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc pkg-config
|
|
- go test -p 1 -failfast -timeout 60m -cover -gcflags=-d=checkptr -v -tags=disable_library_libaom,disable_library_libx264 ./utilities/libvmaf
|
|
- name: test-cgo-full-short
|
|
image: golang:1.19-bullseye
|
|
depends_on:
|
|
- build-x264
|
|
- build-vmaf
|
|
- build-libaom
|
|
- build-dav1d
|
|
- prepare-testdata
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc pkg-config
|
|
- go test -p 1 -failfast -timeout 60m -cover -gcflags=-d=checkptr -v ./... -test.short
|
|
---
|
|
kind: pipeline
|
|
type: docker
|
|
name: from-source-arm64
|
|
platform:
|
|
os: linux
|
|
arch: arm64
|
|
|
|
environment:
|
|
GOPROXY: direct
|
|
GOARCH: arm64
|
|
GOOS: linux
|
|
CFLAGS: "-march=native -Ofast"
|
|
LDFLAGS: "-flto"
|
|
PKG_CONFIG_PATH: "/drone/src/build_deps/lib/pkgconfig"
|
|
LD_LIBRARY_PATH: "/drone/src/build_deps/lib"
|
|
CGO_CFLAGS: "-I/drone/src/build_deps/include"
|
|
CGO_LDFLAGS: "-L/drone/src/build_deps/lib"
|
|
|
|
workspace:
|
|
path: /drone/src
|
|
|
|
steps:
|
|
- name: prepare-testdata
|
|
image: alpine
|
|
commands:
|
|
- apk update
|
|
- apk add --no-cache wget bash
|
|
- ./testdata/prepare.sh
|
|
- name: build-x264
|
|
image: golang:1.19-bullseye
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc g++ bash make libtool nasm
|
|
- cd /tmp
|
|
- git clone --depth 1 --branch stable https://code.videolan.org/videolan/x264.git && cd x264 && ./configure --disable-cli --disable-ffms --disable-lavf --disable-swscale --enable-static --bit-depth=all --chroma-format=all --enable-lto --enable-pic --disable-opencl --prefix=/drone/src/build_deps && make -j$(nproc) && make install && cd ..
|
|
- name: build-vmaf
|
|
image: golang:1.19-bullseye
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc g++ bash cmake make libtool meson ccache nasm perl xxd pkg-config
|
|
- cd /tmp
|
|
- git clone --depth 1 --branch v2.3.1 https://github.com/Netflix/vmaf.git && cd vmaf/libvmaf && meson setup build . --prefix /drone/src/build_deps --buildtype release -Denable_float=true -Dbuilt_in_models=true && ninja -vC build && ninja -vC build install && cd ../..
|
|
- name: build-libaom
|
|
image: golang:1.19-bullseye
|
|
depends_on:
|
|
- build-vmaf
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc g++ bash cmake make libtool ccache nasm perl xxd pkg-config
|
|
- cd /tmp
|
|
- git clone --depth 1 --branch v3.5.0 https://aomedia.googlesource.com/aom.git && cd aom && mkdir b && cd b && cmake .. -DCMAKE_INTERPROCEDURAL_OPTIMIZATION=ON -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=OFF -D CMAKE_INSTALL_PREFIX:PATH=/drone/src/build_deps -DENABLE_DOCS=OFF -DENABLE_EXAMPLES=OFF -DENABLE_TOOLS=OFF -DENABLE_TESTS=OFF -DENABLE_CCACHE=ON -DCONFIG_FRAME_PARALLEL_ENCODE=1 -DCONFIG_AV1_TEMPORAL_DENOISING=1 -DCONFIG_BITRATE_ACCURACY=1 -DCONFIG_TUNE_VMAF=1 -DCONFIG_NN_V2=1 -DCONFIG_RT_ML_PARTITIONING=1 -DCONFIG_THREE_PASS=1 -DCONFIG_AV1_ENCODER=1 -DCONFIG_AV1_DECODER=1 && make -j$(nproc) && make install && cd ../..
|
|
- name: build-dav1d
|
|
image: golang:1.19-bullseye
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc g++ bash libtool meson ccache nasm pkg-config
|
|
- cd /tmp
|
|
- git clone --depth 1 --branch 1.0.0 https://code.videolan.org/videolan/dav1d.git && cd dav1d && meson setup build . --prefix /drone/src/build_deps --buildtype release --default-library=static && ninja -vC build && ninja -vC build install && cd ..
|
|
- name: test-nocgo-short
|
|
image: golang:1.19-alpine
|
|
depends_on:
|
|
- prepare-testdata
|
|
commands:
|
|
- apk update
|
|
- apk add --no-cache git
|
|
- CGO_ENABLED=0 go test -p 1 -failfast -timeout 60m -cover -gcflags=-d=checkptr -v ./... -test.short
|
|
- name: test-cgo-libdav1d-long
|
|
image: golang:1.19-bullseye
|
|
depends_on:
|
|
- build-dav1d
|
|
- prepare-testdata
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc pkg-config
|
|
- go test -p 1 -failfast -timeout 60m -cover -gcflags=-d=checkptr -v -tags=disable_library_libaom,disable_library_libx264,disable_library_libvmaf ./decoder/libdav1d
|
|
- name: test-cgo-libaom-long
|
|
image: golang:1.19-bullseye
|
|
depends_on:
|
|
- build-libaom
|
|
- prepare-testdata
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc pkg-config
|
|
- go test -p 1 -failfast -timeout 60m -cover -gcflags=-d=checkptr -v -tags=disable_library_libdav1d,disable_library_libx264,disable_library_libvmaf ./encoder/libaom
|
|
- name: test-cgo-libx264-long
|
|
image: golang:1.19-bullseye
|
|
depends_on:
|
|
- build-x264
|
|
- prepare-testdata
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc pkg-config
|
|
- go test -p 1 -failfast -timeout 60m -cover -gcflags=-d=checkptr -v -tags=disable_library_libdav1d,disable_library_libaom,disable_library_libvmaf ./encoder/libx264
|
|
- name: test-cgo-libvmaf-long
|
|
image: golang:1.19-bullseye
|
|
depends_on:
|
|
- build-dav1d
|
|
- build-vmaf
|
|
- prepare-testdata
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc pkg-config
|
|
- go test -p 1 -failfast -timeout 60m -cover -gcflags=-d=checkptr -v -tags=disable_library_libaom,disable_library_libx264 ./utilities/libvmaf
|
|
- name: test-cgo-full-short
|
|
image: golang:1.19-bullseye
|
|
depends_on:
|
|
- build-x264
|
|
- build-vmaf
|
|
- build-libaom
|
|
- build-dav1d
|
|
- prepare-testdata
|
|
commands:
|
|
- DEBIAN_FRONTEND=noninteractive apt update
|
|
- DEBIAN_FRONTEND=noninteractive apt install -y git gcc pkg-config
|
|
- go test -p 1 -failfast -timeout 60m -cover -gcflags=-d=checkptr -v ./... -test.short
|
|
... |