Skip to content

Commit 7f647fe

Browse files
committed
Add build_old_ubuntu.yaml for old server
Signed-off-by: Frank Li <Frank.Li@nxp.com>
1 parent b776f70 commit 7f647fe

1 file changed

Lines changed: 54 additions & 0 deletions

File tree

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
name: Build for x64 ubuntu
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
tags:
8+
- uuu*
9+
pull_request:
10+
types:
11+
- opened
12+
- synchronize
13+
14+
jobs:
15+
build:
16+
name: Build with Ubuntu 20.04 Docker
17+
18+
steps:
19+
- name: Checkout repository
20+
uses: actions/checkout@v3
21+
with:
22+
fetch-depth: 0
23+
24+
- name: Build
25+
run: |
26+
git fetch --tags --force # Retrieve annotated tags. #issue 290
27+
if [ "${{ matrix.os }}" == "ubuntu-22.04" ]; then git submodule update --init tinyxml2; cd tinyxml2;
28+
29+
docker run --rm -v ${{ github.workspace }}:/workspace -w /workspace -e DEBIAN_FRONTEND=noninteractive -e TZ=UTC ubuntu:20.04 bash -c "
30+
apt-get update &&
31+
apt-get --yes --force-yes install libusb-1.0-0-dev libbz2-dev libzstd-dev libtinyxml2-dev
32+
git config --global --add safe.directory /workspace &&
33+
cd tinyxml2 && cmake . && make && cd .. &&
34+
cmake -D 'STATIC=1' -D 'FORCE_OLD=on' . && make"
35+
36+
- name: Copy
37+
run: |
38+
cp ./uuu/uuu ./uuu/uuu-ubuntu20.04
39+
40+
- name: Upload Build Artifacts
41+
uses: actions/upload-artifact@v4
42+
with:
43+
name: uuu-ubuntu-20.04
44+
path: ./uuu/uuu-ubuntu20.04
45+
46+
- name: Create or Update Release
47+
uses: ncipollo/release-action@v1
48+
with:
49+
name: Release ${{ github.ref_name }}
50+
tag: ${{ github.ref_name }}
51+
commit: ${{ github.sha }}
52+
allowUpdates: true
53+
prerelease: true
54+
artifacts: "./uuu/uuu-ubuntu20.04"

0 commit comments

Comments
 (0)