Skip to content

Commit f03ad6f

Browse files
committed
update build
modify: action卸载llvm 9.01 modify: 更改release名字 modify: 更改release名字 modify: 更改release名字 modify: 更改release名字 modify: 更改release名字 modify: 改换 Update cmake.yml Update cmake.yml Update cmake.yml Update cmake.yml modify: 改换 modify:
1 parent 73ec76e commit f03ad6f

File tree

1 file changed

+55
-0
lines changed

1 file changed

+55
-0
lines changed

.github/workflows/cmake.yml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
name: CMake
2+
3+
on: [push]
4+
5+
env:
6+
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
7+
BUILD_TYPE: Release
8+
9+
jobs:
10+
build:
11+
# The CMake configure and build commands are platform agnostic and should work equally
12+
# well on Windows or Mac. You can convert this to a matrix build if you need
13+
# cross-platform coverage.
14+
# See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
15+
runs-on: ubuntu-latest
16+
17+
steps:
18+
- uses: actions/checkout@v2
19+
20+
- name: Installing LLVM 11
21+
run: sudo apt remove -y llvm-9-dev llvm-9-doc llvm-9 llvm-9-runtime llvm-9-tools && sudo apt install -y llvm-11-dev
22+
23+
- name: Installing libedit
24+
run: sudo apt install -y libedit-dev
25+
26+
- name: Create Build Environment
27+
# Some projects don't allow in-source building, so create a separate build directory
28+
# We'll use this as our working directory for all subsequent commands
29+
run: cmake -E make_directory ${{runner.workspace}}/build
30+
31+
- name: Configure CMake
32+
# Use a bash shell so we can use the same syntax for environment variable
33+
# access regardless of the host operating system
34+
shell: bash
35+
working-directory: ${{runner.workspace}}/build
36+
# Note the current convention is to use the -S and -B options here to specify source
37+
# and build directories, but this is only available with CMake 3.13 and higher.
38+
# The CMake binaries on the Github Actions machines are (as of this writing) 3.12
39+
run: cmake $GITHUB_WORKSPACE
40+
41+
- name: Build
42+
working-directory: ${{runner.workspace}}/build
43+
shell: bash
44+
# Execute the build. You can specify a specific target with "--target <NAME>"
45+
run: cmake --build .
46+
47+
- name: Create Release
48+
id: create_release
49+
if: startsWith(github.ref, 'refs/tags/')
50+
uses: softprops/action-gh-release@v1
51+
with:
52+
tag_name: ${{ github.ref }}
53+
files: ${{runner.workspace}}/build/sysyplus_compiler
54+
env:
55+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)