Fix build on Windows (no need for properties) #27
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build | |
on: [push, pull_request] | |
jobs: | |
windows: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
submodules: 'true' | |
- uses: ilammy/msvc-dev-cmd@v1 | |
- uses: actions/setup-python@v1 | |
with: | |
python-version: '3.x' | |
- run: pip install meson ninja | |
- run: meson setup build --wrap-mode=default --buildtype=release -Dfreetype=enabled -Ddirectwrite=enabled | |
working-directory: harfbuzz | |
- run: meson compile -C build | |
working-directory: harfbuzz | |
- uses: actions/setup-java@v3 | |
with: | |
distribution: 'temurin' | |
java-version: '17' | |
- run: ./gradlew -i build assembleRelease | |
- run: | | |
mkdir artifact | |
cp harfbuzz/build/src/harfbuzz.lib artifact | |
cp harfbuzz/build/src/harfbuzz.dll artifact | |
cp harfbuzz/build/subprojects/freetype-*/freetype-6.dll artifact | |
cp harfbuzz/build/subprojects/libpng-*/png16-16.dll artifact | |
cp buzz4jni/build/lib/main/release/buzz4j.dll artifact | |
cp build/libs/buzz4j-*.jar artifact | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: buzz4j-windows | |
path: artifact/* | |
linux: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
submodules: 'true' | |
- name: Unpack Gradle secrets | |
run: | | |
mkdir .gradle "$HOME/.gradle" | |
echo "$OSSRH_GPG" | base64 -d > .gradle/ossrh.gpg | |
echo "$GRADLE_PROPERTIES" | base64 -d > "$HOME/.gradle/gradle.properties" | |
shell: bash | |
env: | |
OSSRH_GPG: ${{secrets.OSSRH_GPG}} | |
GRADLE_PROPERTIES: ${{secrets.GRADLE_PROPERTIES}} | |
- run: sudo apt-get update && sudo apt-get install -y meson pkg-config gtk-doc-tools gcc g++ libfreetype6-dev libglib2.0-dev libcairo2-dev | |
- run: meson setup build --wrap-mode=default --buildtype=release -Dfreetype=enabled -Ddirectwrite=enabled | |
working-directory: harfbuzz | |
- run: meson compile -C build | |
working-directory: harfbuzz | |
- uses: actions/setup-java@v3 | |
with: | |
distribution: 'temurin' | |
java-version: '17' | |
- run: ./gradlew -i assembleRelease publish | |
- run: | | |
mkdir artifact | |
cp harfbuzz/build/src/libharfbuzz.so artifact | |
cp buzz4jni/build/lib/main/release/libbuzz4j.so artifact | |
cp build/libs/buzz4j-*.jar artifact | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: buzz4j-linux | |
path: artifact/* |