Skip to content

Commit 9f57831

Browse files
committed
CI: check generated_cpp on macos
1 parent 675ea74 commit 9f57831

File tree

1 file changed

+31
-2
lines changed

1 file changed

+31
-2
lines changed

.github/workflows/build_latest.yml

Lines changed: 31 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
strategy:
2020
fail-fast: false
2121
matrix:
22-
os: ['ubuntu', 'windows']
22+
os: ['ubuntu', 'macos', 'windows']
2323
qt-version: [ '5.12.*', '5.15.*', '6.8.*', '6.9.*' ]
2424
python-version: [ '3.12' ]
2525
runs-on: ${{ matrix.os }}-latest
@@ -73,6 +73,14 @@ jobs:
7373
CONFIG+=sanitizer CONFIG+=sanitize_undefined CONFIG+=sanitize_address
7474
make -j $(nproc)
7575
76+
- name: Build generator MacOS
77+
shell: cmd
78+
if: ${{ matrix.os == 'macos' }}
79+
run: |
80+
cd generator
81+
qmake CONFIG+=release CONFIG-=debug_and_release CONFIG-=debug_and_release_target generator.pro
82+
make -j $(nproc)
83+
7684
- name: Build generator Windows
7785
shell: cmd
7886
if: ${{ matrix.os == 'windows' }}
@@ -110,7 +118,28 @@ jobs:
110118
PYTHONDEVMODE=1 PYTHONASYNCIODEBUG=1 PYTHONWARNINGS=error PYTHONMALLOC=malloc_debug \
111119
UBSAN_OPTIONS="halt_on_error=1" ASAN_OPTIONS="detect_leaks=0:detect_stack_use_after_return=1:fast_unwind_on_malloc=0" \
112120
make check TESTARGS="-platform offscreen"
113-
121+
122+
- name: Build PythonQt Macos
123+
if: ${{ matrix.os == 'macos' }}
124+
run: |
125+
set -ue
126+
echo ======= SYSTEM INFO ========
127+
uname -a; gcc --version | head -n 1; python --version; qmake --version
128+
echo ============================
129+
PYTHON_VERSION_MAJOR=$(cut -d . -f1 <<< ${{ steps.versions.outputs.PYTHON_VERSION_SHORT }})
130+
for i in "python${{ steps.versions.outputs.PYTHON_VERSION_SHORT }}-embed" "python${{ steps.versions.outputs.PYTHON_VERSION_SHORT }}" \
131+
"python${PYTHON_VERSION_MAJOR}-embed" "python${PYTHON_VERSION_MAJOR}"
132+
do if pkg-config --exists "$i"; then PYTHON_PKGCONFIG_NAME="$i"; break; fi; done
133+
qmake CONFIG+=ccache CONFIG+=${{ matrix.configuration }} CONFIG+=sanitizer CONFIG+=sanitize_undefined CONFIG+=sanitize_address \
134+
PYTHON_VERSION=${{ steps.versions.outputs.PYTHON_VERSION_SHORT }} \
135+
PYTHON_DIR="$pythonLocation" \
136+
PKGCONFIG+=$PYTHON_PKGCONFIG_NAME \
137+
-r PythonQt.pro
138+
make -j $(nproc)
139+
PYTHONDEVMODE=1 PYTHONASYNCIODEBUG=1 PYTHONWARNINGS=error PYTHONMALLOC=malloc_debug \
140+
UBSAN_OPTIONS="halt_on_error=1" ASAN_OPTIONS="detect_leaks=0:detect_stack_use_after_return=1:fast_unwind_on_malloc=0" \
141+
make check TESTARGS="-platform offscreen"
142+
114143
- name: Build PythonQt Windows
115144
shell: cmd
116145
if: ${{ matrix.os == 'windows' }}

0 commit comments

Comments
 (0)