1
+ name : Build Qt Open Source
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - ' feature/**'
7
+ paths :
8
+ - .github/workflows/build_qt.yml
9
+
10
+ pull_request :
11
+ branches :
12
+ - ' feature/**'
13
+ paths :
14
+ - .github/workflows/build_qt.yml
15
+
16
+ jobs :
17
+ macos :
18
+ runs-on : ${{ matrix.os }}
19
+ strategy :
20
+ fail-fast : false
21
+ matrix :
22
+ os : [macos-14]
23
+ build : [1]
24
+ include :
25
+ - build : 1
26
+ qt-version : " 5.15.15"
27
+ python3-version : " 3.11.9"
28
+ python2-version : " 2.7.18"
29
+
30
+ steps :
31
+ - name : Install Homebrew dependencies
32
+ run : |
33
+ brew install --quiet --formula libiconv libpng libpq libtool libuv libxau libxcb libxdmcp
34
+ brew install --quiet --formula autoconf automake cmake pcre2 harfbuzz freetype node@18 nspr nss
35
+ brew install --quiet --formula xcb-proto xcb-util xcb-util-cursor xcb-util-image xcb-util-keysyms xcb-util-renderutil xcb-util-wm
36
+ brew install --quiet --formula brotli bzip2 dbus glew icu4c jpeg md4c [email protected] pkg-config sqlite xorgproto zlib zstd
37
+
38
+
39
+ # Use Ninja 1.11.1 because Qt need to be patched for Ninja 1.12.1.
40
+ - name : Install Ninja 1.11.1
41
+ run : |
42
+ wget https://github.com/ninja-build/ninja/releases/download/v1.11.1/ninja-mac.zip
43
+ unzip ninja-mac.zip -d ./ninja
44
+ echo "$(pwd)/ninja" >> $GITHUB_PATH
45
+ ninja --version
46
+
47
+ - name : Install pyenv
48
+ run : |
49
+ curl https://pyenv.run | bash
50
+
51
+ export PYENV_ROOT="$HOME/.pyenv"
52
+ echo "$PYENV_ROOT/shims" >> $GITHUB_PATH
53
+ echo "$PYENV_ROOT/bin" >> $GITHUB_PATH
54
+
55
+ - name : Setup pyenv
56
+ run : |
57
+ echo $PATH
58
+ pyenv install ${{ matrix.python3-version }} ${{ matrix.python2-version }}
59
+ pyenv global ${{ matrix.python3-version }} ${{ matrix.python2-version }}
60
+
61
+ - name : Display Python installation location
62
+ run : |
63
+ python -c "import sys; print(sys.executable)"
64
+ python2 -c "import sys; print(sys.executable)"
65
+
66
+ - name : Download Qt ${{ matrix.qt-version }} source
67
+ run : |
68
+ curl -o qt.zip https://download.qt.io/archive/qt/5.15/5.15.15/single/qt-everywhere-opensource-src-5.15.15.zip
69
+ unzip qt.zip
70
+
71
+ - name : Create directory for build
72
+ run : |
73
+ mkdir -p ${{ github.workspace }}/qt-build
74
+
75
+ - name : Configure Qt ${{ matrix.qt-version }}
76
+ run : |
77
+ OPENSSL_LIBS='-L/usr/local/Cellar/[email protected] /1.1.1w/lib -lssl -lcrypto' ../configure/qt-everywhere-opensource-src-5.15.15 -release -prefix ./release -nomake examples -nomake tests QMAKE_APPLE_DEVICE_ARCHS=arm64 -opensource -confirm-license -c++std c++14 -openssl-linked -opengl desktop -release -I /usr/local/Cellar/[email protected] /1.1.1w/include -L /usr/local/Cellar/[email protected] /1.1.1w/lib -skip qtlocation
78
+ working-directory : ${{ github.workspace }}/qt-build
79
+
80
+ - name : Build Qt
81
+ run : |
82
+ make -j$(python -c 'import os; print(os.cpu_count())')
83
+ working-directory : ${{ github.workspace }}/qt-build
84
+
85
+ - name : Display release folder
86
+ run : |
87
+ ls -al ./release
88
+ working-directory : ${{ github.workspace }}/qt-build
0 commit comments