mirror of
https://github.com/LongSoft/UEFITool.git
synced 2024-11-21 23:48:22 +08:00
Fix building with MinGW 11.2.0 on Windows, add it into CI/CD
This commit is contained in:
parent
9bb0549ad2
commit
6247fa5bbc
25
.github/workflows/main.yml
vendored
25
.github/workflows/main.yml
vendored
@ -87,7 +87,7 @@ jobs:
|
||||
- name: Build everything
|
||||
run: ninja -C build-meson
|
||||
|
||||
build_win:
|
||||
build_windows:
|
||||
name: Build on Windows
|
||||
runs-on: windows-2019
|
||||
steps:
|
||||
@ -115,7 +115,7 @@ jobs:
|
||||
- name: Configure UEFIExtract
|
||||
shell: bash
|
||||
working-directory: ${{runner.workspace}}/build/UEFIExtract
|
||||
run: cmake -G "Visual Studio 16 2019" -T "v141_xp" -DU_STATIC_RT=YES ../../UEFITool/UEFIExtract/
|
||||
run: cmake -G "Visual Studio 16 2019" -T "v141_xp" ../../UEFITool/UEFIExtract/
|
||||
|
||||
- name: Build UEFIExtract
|
||||
working-directory: ${{runner.workspace}}/build/UEFIExtract
|
||||
@ -135,7 +135,7 @@ jobs:
|
||||
- name: Configure UEFIFind
|
||||
shell: bash
|
||||
working-directory: ${{runner.workspace}}/build/UEFIFind
|
||||
run: cmake -G "Visual Studio 16 2019" -T "v141_xp" -DU_STATIC_RT=YES ../../UEFITool/UEFIFind/
|
||||
run: cmake -G "Visual Studio 16 2019" -T "v141_xp" ../../UEFITool/UEFIFind/
|
||||
|
||||
- name: Build UEFIFind
|
||||
working-directory: ${{runner.workspace}}/build/UEFIFind
|
||||
@ -186,6 +186,25 @@ jobs:
|
||||
tag: ${{ github.ref }}
|
||||
file_glob: true
|
||||
|
||||
build_windows_mingw:
|
||||
name: Build on Windows with MinGW
|
||||
runs-on: windows-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Install Qt
|
||||
uses: jurplel/install-qt-action@v3
|
||||
with:
|
||||
version: '6.3.1'
|
||||
host: 'windows'
|
||||
target: 'desktop'
|
||||
arch: 'win64_mingw'
|
||||
|
||||
- name: Build everything using CMake and MinGW
|
||||
run: |
|
||||
cmake -G "MinGW Makefiles" -B build .
|
||||
cmake --build build -j
|
||||
|
||||
analyze_coverity:
|
||||
env:
|
||||
PROJECT_TYPE: TOOL
|
||||
|
@ -20,7 +20,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
#include <sys/stat.h>
|
||||
#include <fstream>
|
||||
|
||||
#ifdef WIN32
|
||||
#if defined(_WIN32) || defined(__MINGW32__)
|
||||
#include <direct.h>
|
||||
#include <stdlib.h>
|
||||
static inline bool isExistOnFs(const UString & path) {
|
||||
|
@ -12,8 +12,8 @@
|
||||
#define __BYTE_ORDER BYTE_ORDER
|
||||
#define __BIG_ENDIAN BIG_ENDIAN
|
||||
#define __LITTLE_ENDIAN LITTLE_ENDIAN
|
||||
// Windows with MS compiler
|
||||
#elif defined(_MSC_VER)
|
||||
// Windows with MS or MinGW compilers
|
||||
#elif defined(_MSC_VER) || defined(__MINGW32__)
|
||||
#include <stdlib.h>
|
||||
#define __LITTLE_ENDIAN 1234
|
||||
#define __BIG_ENDIAN 4321
|
||||
|
Loading…
Reference in New Issue
Block a user