building OpenCASCADE 7.7.0 with adm/qmake with error

I'm trying to build OpenCASCADE 7.7.0 using adm/qmake/OCCT.pro, which is not shown in document
and I have such complie problem:

cd FoundationClasses\ && ( if not exist Makefile D:\QT\qt-5.15.2-x64\5.15.2\mingw81_64\bin\qmake.exe -o Makefile D:\OpenCASCADE-7.7.0-vc14-64\opencascade-7.7.0\adm\qmake\FoundationClasses\FoundationClasses.pro -spec win32-g++ "CONFIG+=debug" "CONFIG+=qml_debug" ) && D:/QT/qt-5.15.2-x64/Tools/mingw810_64/bin/mingw32-make -f Makefile
mingw32-make[1]: Entering directory 'D:/OpenCASCADE-7.7.0-vc14-64/opencascade-7.7.0/adm/build-Occt-Desktop_Qt_5_15_2_MinGW_64_bit-Debug/FoundationClasses'
cd TKernel\ && ( if not exist Makefile D:\QT\qt-5.15.2-x64\5.15.2\mingw81_64\bin\qmake.exe -o Makefile D:\OpenCASCADE-7.7.0-vc14-64\opencascade-7.7.0\adm\qmake\FoundationClasses\TKernel\TKernel.pro -spec win32-g++ "CONFIG+=debug" "CONFIG+=qml_debug" ) && D:/QT/qt-5.15.2-x64/Tools/mingw810_64/bin/mingw32-make -f Makefile
mingw32-make[2]: Entering directory 'D:/OpenCASCADE-7.7.0-vc14-64/opencascade-7.7.0/adm/build-Occt-Desktop_Qt_5_15_2_MinGW_64_bit-Debug/FoundationClasses/TKernel'
g++ -c -fno-keep-inline-dllexport -fp:precise -Od -Ob1 -g -W4 /EHa -DUNICODE -D_UNICODE -DMINGW_HAS_SECURE_API=1 -D_CRT_SECURE_NO_WARNINGS -D_CRT_NONSTDC_NO_DEPRECATE -D_SCL_SECURE_NO_WARNINGS -I..\..\..\qmake\FoundationClasses\TKernel -I. -I..\..\..\..\inc -ID:\QT\qt-5.15.2-x64\5.15.2\mingw81_64\mkspecs\win32-g++ -o ..\..\..\..\win64\vc0\objd\TKernel\FSD_Base64.o ..\..\..\..\src\FSD\FSD_Base64.cxx
g++: error: /EHa: No such file or directory
g++: error: unrecognized command line option '-fp:precise'; did you mean '-fprofile'?
g++: error: unrecognized command line option '-W4'; did you mean '-W'?

How do I resovle it ?

gkv311 n's picture

The current version of qmake scripts considers only Visual Studio compiler on Windows platform (hense, -EHa flag passed to compiler). So that you will need tuning scripts (win32 branches) for handling Mingw-w64 / gcc on Windows platform.