-
Notifications
You must be signed in to change notification settings - Fork 72
50 lines (46 loc) · 1.46 KB
/
build_macos.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
name: Build on Mac
on:
workflow_call:
inputs:
verSion:
required: true
type: string
secrets:
AWS_ACCESS_KEY_ID:
required: true
AWS_SECRET_ACCESS_KEY:
required: true
AWS_BUCKET:
required: true
workflow_dispatch:
jobs:
build-mac:
runs-on: macos-11
steps:
- name: 'Checkout GitHub Action'
uses: actions/checkout@v3
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: 'temurin' # See 'Supported distributions' for available options.
java-version: '8'
- name: build jar
run: |
echo $JAVA_HOME
export CPPFLAGS="-I$JAVA_HOME/include"
export CXXFLAGS="-I$JAVA_HOME/include"
brew install zlib
brew install bzip2 lz4 snappy
ROCKSDB_DISABLE_JEMALLOC=1 PORTABLE=1 DEBUG_LEVEL=0 make -j 2 rocksdbjavastatic #more CPU cores makes shared github runner to overload cpu and stop
- name: Upload artifacts to S3
if: inputs.verSion != ' '
uses: NotCoffee418/s3-zip-upload@v1
env:
AWS_SECRET_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_BUCKET: ${{ secrets.AWS_BUCKET }}
BUCKET_NAME: spdb-builder
AWS_REGION: us-east-1
SOURCE_MODE: FILE
SOURCE_PATH: java/target/libspeedbjni-osx-x86_64.jnilib
DEST_FILE: jar_test/v${{ inputs.verSion }}/libspeedbjni-osx-x86_64.jnilib