foo #10
Workflow file for this run
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: Windows build | |
on: | |
push: | |
pull_request: | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: windows-latest | |
defaults: | |
run: | |
shell: msys2 {0} | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: msys2/setup-msys2@v2 | |
with: | |
msystem: MINGW32 | |
install: mingw-w64-i686-gcc mingw-w64-i686-make mingw-w64-i686-freetype mingw-w64-i686-pkg-config | |
- name: configure | |
run: ./configure | |
- name: build | |
run: mingw32-make | |
- name: save lib | |
uses: actions/upload-artifact@v3 | |
with: | |
name: dtx-build | |
path: | | |
libdrawtext.dll | |
libdrawtext.a | |
build-noft: | |
runs-on: windows-latest | |
defaults: | |
run: | |
shell: msys2 {0} | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: msys2/setup-msys2@v2 | |
with: | |
msystem: MINGW32 | |
install: mingw-w64-i686-gcc mingw-w64-i686-make | |
- name: configure | |
run: ./configure --disable-freetype | |
- name: build | |
run: mingw32-make | |
- name: save lib | |
uses: actions/upload-artifact@v3 | |
with: | |
name: dtx-noft-build | |
path: | | |
libdrawtext-noft.dll | |
libdrawtext-noft.a | |
font2glyphmap: | |
runs-on: windows-latest | |
defaults: | |
run: | |
shell: msys2 {0} | |
needs: build | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: msys2/setup-msys2@v2 | |
with: | |
msystem: MINGW32 | |
install: mingw-w64-i686-gcc mingw-w64-i686-make mingw-w64-i686-freetype | |
- name: get build | |
uses: actions/download-artifact@v3 | |
with: | |
name: dtx-build | |
- name: build | |
run: | | |
cd tools/font2glyphmap | |
mingw32-make | |
- name: save font2glyphmap | |
uses: actions/upload-artifact@v3 | |
with: | |
name: font2glyphmap | |
path: | | |
tools/font2glyphmap/font2glyphmap.exe | |
example-simple: | |
runs-on: windows-latest | |
defaults: | |
run: | |
shell: msys2 {0} | |
needs: build | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: msys2/setup-msys2@v2 | |
with: | |
msystem: MINGW32 | |
install: mingw-w64-i686-gcc mingw-w64-i686-make mingw-w64-i686-freeglut mingw-w64-i686-freetype mingw-w64-i686-wget | |
- name: download font | |
run: | | |
mkdir -p examples/fonts | |
cd examples/fonts | |
wget http://downloads.sourceforge.net/project/linuxlibertine/linuxlibertine/5.1.3-2/LinLibertineTTF_5.1.3_2011_06_21.tgz | |
tar zvx LinLibertine_R.ttf -f LinLibertineTTF_5.1.3_2011_06_21.tgz | |
mv LinLibertine_R.ttf linux-libertine.ttf | |
- name: get build | |
uses: actions/download-artifact@v3 | |
with: | |
name: dtx-build | |
- name: build | |
run: | | |
cd examples/simple | |
mingw32-make | |
- name: save simple example | |
uses: actions/upload-artifact@v3 | |
with: | |
name: example-simple | |
path: | | |
examples/simple/simple.exe | |
examples/simple/serif.ttf | |
example-nofreetype: | |
runs-on: windows-latest | |
defaults: | |
run: | |
shell: msys2 {0} | |
needs: build-noft | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: msys2/setup-msys2@v2 | |
with: | |
msystem: MINGW32 | |
install: mingw-w64-i686-gcc mingw-w64-i686-make mingw-w64-i686-freeglut | |
- name: get nofreetype build | |
uses: actions/download-artifact@v3 | |
with: | |
name: dtx-noft-build | |
- name: build | |
run: | | |
cd examples/nofreetype | |
mingw32-make | |
- name: save nofreetype example | |
uses: actions/upload-artifact@v3 | |
with: | |
name: example-noft | |
path: | | |
examples/nofreetype/simple-noft.exe | |
examples/nofreetype/serif_s24.glyphmap | |
package: | |
runs-on: windows-latest | |
defaults: | |
run: | |
shell: msys2 {0} | |
needs: [build, build-noft, font2glyphmap, example-simple, example-nofreetype] | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: msys2/setup-msys2@v2 | |
with: | |
msystem: MINGW32 | |
- name: get build | |
uses: actions/download-artifact@v3 | |
with: | |
name: dtx-build | |
- name: get nofreetype build | |
uses: actions/download-artifact@v3 | |
with: | |
name: dtx-noft-build | |
- name: get font2glyphmap | |
uses: actions/download-artifact@v3 | |
with: | |
name: font2glyphmap | |
- name: get simple example | |
uses: actions/download-artifact@v3 | |
with: | |
name: example-simple | |
- name: get simple example | |
uses: actions/download-artifact@v3 | |
with: | |
name: example-noft | |
- name: stage | |
run: | | |
mkdir -p libdrawtext-mingw32/examples/simple | |
mkdir -p libdrawtext-mingw32/examples/nofreetype | |
mkdir -p libdrawtext-mingw32/tools/font2glyphmap | |
cp README.md COPYING* libdrawtext-mingw32 | |
cp src/drawtext.h libdrawtext-mingw32 | |
cp libdrawtext*.dll libdrawtext-mingw32 | |
cp libdrawtext*.a libdrawtext-mingw32 | |
cp font2glyphmap.exe tools/font2glyphmap | |
cp simple.exe libdrawtext-mingw32/examples/simple | |
cp serif.ttf libdrawtext-mingw32/examples/simple | |
cp simple-noft.exe libdrawtext-mingw32/examples/nofreetype | |
cp serif_s24.glyphmap libdrawtext-mingw32/examples/nofreetype | |
- name: archive | |
uses: actions/upload-artifact@v3 | |
with: | |
name: libdrawtext-mingw32 | |
path: libdrawtext-mingw32 | |
# vi:ts=2 sts=2 sw=2 expandtab: |