From fb4d74e90f2b7de4d95f89bd629ada5e3eceed27 Mon Sep 17 00:00:00 2001 From: Iaroslav Postovalov Date: Sun, 4 Oct 2020 13:26:21 +0700 Subject: [PATCH] Add OSX target --- .github/workflows/gradle.yml | 82 ++++++++++++++++++++++++------------ 1 file changed, 56 insertions(+), 26 deletions(-) diff --git a/.github/workflows/gradle.yml b/.github/workflows/gradle.yml index f5e5e62a3..02b7ee2cf 100644 --- a/.github/workflows/gradle.yml +++ b/.github/workflows/gradle.yml @@ -1,35 +1,65 @@ name: Gradle build -on: [push] +on: [ push ] jobs: build-ubuntu: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v1 - - name: Set up JDK 11 - uses: actions/setup-java@v1 - with: - java-version: 11 - - name: Install libgsl-dev - run: sudo apt install libgsl-dev - - name: Cache gradle - uses: actions/cache@v2 - with: - path: | - ~/.gradle/caches - ~/.gradle/wrapper - key: gradle_6_6_1 - restore-keys: gradle_6_6_1 + - uses: actions/checkout@v2 + - name: Set up JDK 11 + uses: actions/setup-java@v1 + with: + java-version: 11 + - name: Install libgsl-dev + run: sudo apt install libgsl-dev + - name: Cache gradle + uses: actions/cache@v2 + with: + path: | + ~/.gradle/caches + ~/.gradle/wrapper + key: gradle_6_6_1 + restore-keys: gradle_6_6_1 - - name: Cache konan - uses: actions/cache@v2 - with: - path: | - ~/.konan/dependencies - ~/.konan/kotlin-native-prebuilt-linux-1.4.20-eap-37 - key: ${{ runner.os }}-konan-1.4.0 - restore-keys: ${{ runner.os }}-konan-1.4.0 - - name: Build with Gradle - run: ./gradlew -Dorg.gradle.daemon=false --build-cache :kmath-gsl:cinteropLibgslNative build + - name: Cache konan + uses: actions/cache@v2 + with: + path: | + ~/.konan/dependencies + ~/.konan/kotlin-native-prebuilt-linux-1.4.20-eap-37 + key: ${{ runner.os }}-konan-1.4.0 + restore-keys: ${{ runner.os }}-konan-1.4.0 + - name: Build with Gradle + run: ./gradlew -Dorg.gradle.daemon=false --build-cache :kmath-gsl:cinteropLibgslNative build + build-osx: + runs-on: macos-latest + + steps: + - uses: actions/checkout@v2 + - name: Set up JDK 11 + uses: actions/setup-java@v1 + with: + java-version: 11 + - name: Install gsl + run: brew install gsl + - name: Cache gradle + uses: actions/cache@v2 + with: + path: | + ~/.gradle/caches + ~/.gradle/wrapper + key: gradle_6_6_1 + restore-keys: gradle_6_6_1 + + - name: Cache konan + uses: actions/cache@v2 + with: + path: | + ~/.konan/dependencies + ~/.konan/kotlin-native-prebuilt-macos-1.4.20-eap-37 + key: ${{ runner.os }}-konan-1.4.0 + restore-keys: ${{ runner.os }}-konan-1.4.0 + - name: Build with Gradle + run: ./gradlew -Dorg.gradle.daemon=false --build-cache :kmath-gsl:cinteropLibgslNative build