-
Notifications
You must be signed in to change notification settings - Fork 21
102 lines (100 loc) · 3.67 KB
/
build.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
name: Build
on:
push:
repository_dispatch:
types: [run_build]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
build-linux:
runs-on: ubuntu-latest
container: ubuntu:14.04
steps:
- uses: actions/checkout@v3
- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install -y software-properties-common
sudo apt-get install -y cmake cmake-data git build-essential autoconf automake libtool texinfo bison flex pkg-config python
- name: Build CMake 3.4.1
run: |
sudo apt-get install -y wget libcurl4-openssl-dev
wget http://www.cmake.org/files/v3.4/cmake-3.4.1.tar.gz && tar -xvzf cmake-3.4.1.tar.gz
cd cmake-3.4.1/ && ./configure --system-curl --parallel=$(nproc) && make -j$(nproc) && sudo make install
update-alternatives --install /usr/bin/cmake cmake /usr/local/bin/cmake 1 --force
- name: Clone
run: |
export REV=dirty-$(git describe --always)
git clone https://github.com/vitasdk/buildscripts.git
chmod +x *.sh
- name: Build
run: |
cd buildscripts
git config --global user.email "builds@travis-ci.com"
git config --global user.name "Travis CI"
mkdir build
cd build
cmake ..
make -j$(nproc) tarball
- name: Upload artifacts
if: ${{ success() }}
uses: actions/upload-artifact@v3
with:
name: vitasdk-linux
path: buildscripts/build/*.tar.bz2
- uses: svenstaro/upload-release-action@v2
if: contains(github.ref,'refs/heads/master')
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: buildscripts/build/*.tar.bz2
overwrite: true
file_glob: true
tag: master-linux-v2.${{github.run_number}}
release_name: master-linux-v2.${{github.run_number}}
build-windows:
runs-on: ubuntu-latest
container: ubuntu:14.04
steps:
- uses: actions/checkout@v3
- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install -y software-properties-common
sudo apt-get install -y cmake cmake-data git build-essential autoconf automake libtool texinfo bison flex pkg-config python g++-mingw-w64
- name: Build CMake 3.4.1
run: |
sudo apt-get install -y wget libcurl4-openssl-dev
wget http://www.cmake.org/files/v3.4/cmake-3.4.1.tar.gz && tar -xvzf cmake-3.4.1.tar.gz
cd cmake-3.4.1/ && ./configure --system-curl --parallel=$(nproc) && make -j$(nproc) && sudo make install
update-alternatives --install /usr/bin/cmake cmake /usr/local/bin/cmake 1 --force
- name: Clone
run: |
export REV=dirty-$(git describe --always)
git clone https://github.com/vitasdk/buildscripts.git
chmod +x *.sh
- name: Build
run: |
cd buildscripts
git config --global user.email "builds@travis-ci.com"
git config --global user.name "Travis CI"
unset CXX
unset CC
mkdir build
cd build
cmake .. -DCMAKE_TOOLCHAIN_FILE=toolchain-x86_64-w64-mingw32.cmake
make -j$(nproc) tarball
- name: Upload artifacts
if: ${{ success() }}
uses: actions/upload-artifact@v3
with:
name: vitasdk-windows
path: buildscripts/build/*.tar.bz2
- uses: svenstaro/upload-release-action@v2
if: contains(github.ref,'refs/heads/master')
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: buildscripts/build/*.tar.bz2
overwrite: true
file_glob: true
tag: master-win-v2.${{github.run_number}}
release_name: master-win-v2.${{github.run_number}}