Skip to content

Commit 2d0e290

Browse files
committed
GitHub: build/publish linux/windows mmv1 binaries
1 parent f4800e8 commit 2d0e290

File tree

3 files changed

+75
-46
lines changed

3 files changed

+75
-46
lines changed

Diff for: .github/workflows/cmake.yml

-44
This file was deleted.

Diff for: .github/workflows/release_bin.yml

+71
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
name: Build Bin
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
7+
8+
jobs:
9+
build_linux:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- uses: actions/checkout@v3
14+
15+
- name: Install Qt
16+
run: sudo apt install qtbase5-dev
17+
18+
- name: Configure CMake
19+
run: cmake -B build -DWITH_CCACHE=OFF -DCMAKE_BUILD_TYPE=Release -DWITH_QT5=ON
20+
21+
- name: Build
22+
run: make -C build install -j 4
23+
24+
- name: Create Archive
25+
run: bash -c "cd build && ../script_create_bin_dist.sh linux"
26+
27+
- name: Upload binaries to release
28+
uses: softprops/action-gh-release@v1
29+
with:
30+
token: ${{ secrets.GITHUB_TOKEN }}
31+
files: build/micmac_linux.tgz
32+
33+
build_win:
34+
runs-on: windows-latest
35+
36+
steps:
37+
- uses: actions/checkout@v3
38+
39+
- name: Install Qt
40+
uses: jurplel/install-qt-action@v3
41+
with:
42+
cache: true
43+
44+
- name: Configure CMake
45+
run: cmake -B build -DWITH_CCACHE=OFF -DCMAKE_BUILD_TYPE=Release -DWITH_QT5=ON -DCMAKE_INSTALL_PREFIX=${{github.workspace}}
46+
47+
- name: Build
48+
run: cmake --build build --config Release --target INSTALL -j 4
49+
- name: Package
50+
shell: bash
51+
run: |
52+
env
53+
mkdir -p bin/platforms bin/imageformats
54+
DEST=$(pwd)/bin
55+
cd $Qt5_Dir/bin
56+
cp Qt5Core.dll Qt5Gui.dll Qt5Xml.dll Qt5OpenGL.dll Qt5Widgets.dll $DEST/
57+
cd $Qt5_Dir/plugins
58+
cp platforms/qwindows.dll $DEST/platforms/
59+
cp imageformats/*.dll $DEST/imageformats/
60+
cd $GITHUB_WORKSPACE
61+
ls -lrt bin
62+
63+
- name: Create Zip
64+
run: 7z a micmac_windows.zip bin\ binaire-aux\ include\XML_MicMac\ include\XML_GEN\ include\qt
65+
66+
- name: Upload binaries to release
67+
uses: softprops/action-gh-release@v1
68+
with:
69+
token: ${{ secrets.GITHUB_TOKEN }}
70+
files: micmac_windows.zip
71+

Diff for: README-GitHub-release.txt

+4-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
1-
To publish a release on GitHub with a compiled version of MicMac (v1, linux),
1+
To publish a release on GitHub with a compiled version of MicMac (v1, linux/Windows),
22
use one the two following methods:
33
- Create a git tag starting with 'v' and then push it on GitHub
44
( git tag v2.01 ; git push origin --tag )
55
- Use GitHub Release creation feature with a new tag starting with 'v'
66

77
The release Assets will contain, in addition to the source code,
8-
a linux compiled version of micmac v1 : micmac_linux.tgz.
8+
two compiled versions of micmac v1 :
9+
- micmac_linux.tgz.
10+
- micmac_windows.zip

0 commit comments

Comments
 (0)