-
Notifications
You must be signed in to change notification settings - Fork 426
113 lines (112 loc) · 3.18 KB
/
build_linux.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
name: Build CCExtractor on Linux
on:
workflow_dispatch:
push:
paths:
- '.github/workflows/build_linux.yml'
- '**.c'
- '**.h'
- '**Makefile**'
- 'linux/**'
- 'package_creators/**'
- 'src/rust/**'
pull_request:
types: [opened, synchronize, reopened]
paths:
- '.github/workflows/build_linux.yml'
- '**.c'
- '**.h'
- '**Makefile**'
- 'linux/**'
- 'package_creators/**'
- 'src/rust/**'
jobs:
build_shell:
runs-on: ubuntu-latest
steps:
- name: Install dependencies
run: sudo apt update && sudo apt-get install libgpac-dev libtesseract-dev
- uses: actions/checkout@v4
- name: build
run: ./build
working-directory: ./linux
- name: Display version information
run: ./ccextractor --version
working-directory: ./linux
- name: Prepare artifacts
run: mkdir ./linux/artifacts
- name: Copy release artifact
run: cp ./linux/ccextractor ./linux/artifacts/
- uses: actions/upload-artifact@v4
with:
name: CCExtractor Linux build
path: ./linux/artifacts
build_autoconf:
runs-on: ubuntu-latest
steps:
- name: Install dependencies
run: sudo apt update && sudo apt-get install libgpac-dev
- uses: actions/checkout@v4
- name: run autogen
run: ./autogen.sh
working-directory: ./linux
- name: configure
run: ./configure --enable-debug
working-directory: ./linux
- name: make
run: make
working-directory: ./linux
- name: Display version information
run: ./ccextractor --version
working-directory: ./linux
cmake:
runs-on: ubuntu-latest
steps:
- name: Install dependencies
run: sudo apt update && sudo apt-get install libgpac-dev
- uses: actions/checkout@v4
- name: cmake
run: mkdir build && cd build && cmake ../src
- name: build
run: make -j$(nproc)
working-directory: build
- name: Display version information
run: ./build/ccextractor --version
cmake_ocr_hardsubx:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install dependencies
run: sudo apt update && sudo apt install libgpac-dev libtesseract-dev libavformat-dev libavdevice-dev libswscale-dev yasm
- name: cmake
run: |
mkdir build && cd build
cmake -DWITH_OCR=ON -DWITH_HARDSUBX=ON ../src
- name: build
run: |
make -j$(nproc)
working-directory: build
- name: Display version information
run: ./build/ccextractor --version
build_rust:
runs-on: ubuntu-latest
steps:
- name: Install dependencies
run: sudo apt update && sudo apt-get install libgpac-dev
- uses: actions/checkout@v4
- name: cache
uses: actions/cache@v4
with:
path: |
src/rust/.cargo/registry
src/rust/.cargo/git
src/rust/target
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: ${{ runner.os }}-cargo-
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
- name: build
run: cargo build
working-directory: ./src/rust