File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -240,12 +240,12 @@ jobs:
240240 - name : Install MinGW
241241 run : | # dpkg-dev is apparently required for pkg-config for cross-building
242242 sudo apt-get install g++-mingw-w64-${{ matrix.arch }}-win32 mingw-w64-tools libz-mingw-w64-dev dpkg-dev
243- - name : Install libpng dev headers for MinGW
244- run : |
245- ./.github/scripts/mingw-w64-libpng-dev.sh ${{ matrix.triplet }}
243+ # - name: Install libpng dev headers for MinGW
244+ # run: |
245+ # ./.github/scripts/mingw-w64-libpng-dev.sh ${{ matrix.triplet }}
246246 - name : Cross-build Windows binaries
247247 run : |
248- make mingw${{ matrix.bits }} -kj Q=
248+ cmake -B build -DCMAKE_TOOLCHAIN_FILE=cmake/toolchain-mingw64.cmake
249249 - name : Package binaries
250250 run : | # DLL dependencies can be figured out using e.g. Dependency Walker or objdump -p
251251 mkdir bins
Original file line number Diff line number Diff line change @@ -14,6 +14,6 @@ CMakeCache.txt
1414CMakeFiles /
1515cmake_install.cmake
1616CMakeUserPresets.json
17- build /
17+ build * /
1818* .dSYM /
1919callgrind.out. *
Original file line number Diff line number Diff line change 1+ # From https://www.mingw-w64.org/build-systems/cmake/
2+
3+ set (CMAKE_SYSTEM_NAME Windows)
4+ set (CMAKE_SYSTEM_PROCESSOR x86_64)
5+
6+ # specify the cross compiler
7+ set (CMAKE_C_COMPILER x86_64-w64-mingw32-gcc)
8+ set (CMAKE_CXX_COMPILER x86_64-w64-mingw32-g++)
9+ set (CMAKE_RC_COMPILER x86_64-w64-mingw32-windres)
10+
11+ # where is the target environment
12+ set (CMAKE_FIND_ROOT_PATH /usr/x86_64-w64-mingw32)
13+
14+ # search for programs in the build host directories
15+ set (CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
16+ # for libraries and headers in the target directories
17+ set (CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
18+ set (CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
You can’t perform that action at this time.
0 commit comments