Qt5.15.16+msvc2019_x86+qwebengine(含mp4)源码编译

系统要求:

内存32g,cpu性能越高越好,硬盘在安装环境、下载源码后,至少还有100g可用空间

下载源码:

https://download.qt.io/archive/qt/5.15/
解压到 D:\

准备工作:

1、安装01.vs_professional_2019或者01.vs_enterprise_2019

  • 勾选桌面C++开发工具

2、安装git、python2.7.15jom_1_1_3(jom编译器比nmake快很多)、nodejs-v13.14.0icu4crubyperl

  • 需要配置到环境变量里
  • 环境变量要在最前面,避免用其它软件里的老版本perl

3、安装Win32OpenSSL-1-1-1w 或者 编译openssl_1.1.1w

  • 以管理员身份运行:x64_x86 Cross Tools Command Prompt for VS 2019
  • 设置执行perl环境
D:\strawberry-perl-5.32.1.1-32bit-portable\portableshell.bat
  • 如果自行编译,进入openssl目录,开始编译
cd /d D:\openssl-1.1.1w
perl configure no-shared VC-WIN32 no-asm –prefix="D:\openssl\1.1.1w"
nmake
nmake install

编译教程:

在开始菜单找到"x64_x86 Cross Tools Command Prompt for VS 2019",以管理员身份运行,然后输入以下命令

  • 动态编译
cd /d D:\qt-everywhere-src-5.15.16
#编译doc
#set LLVM_INSTALL_DIR=C:\Qt\LLVM
#set QDOC_USE_STATIC_LIBCLANG=1

configure OPENSSL_PREFIX="C:\Program Files (x86)\OpenSSL-Win32" OPENSSL_LIBS="-llibcrypto -llibssl -lgdi32 -lWs2_32 -lwsock32 -ladvapi32 -luser32 -lcrypt32" -openssl-linked -debug-and-release -confirm-license -opensource -platform win32-msvc -prefix "C:\Qt\5.15.16\msvc2019_32bit" -opengl dynamic -nomake tests -no-compile-examples -webengine-proprietary-codecs  -mp -recheck
  • 静态编译
cd /d D:\qt-everywhere-src-5.15.16
#编译doc
#set LLVM_INSTALL_DIR=C:\Qt\LLVM
#set QDOC_USE_STATIC_LIBCLANG=1
#静态编译
configure -static -static-runtime -openssl-linked OPENSSL_PREFIX="C:\Program Files (x86)\OpenSSL" OPENSSL_LIBS="-llibcrypto -llibssl -lgdi32 -lWs2_32 -lwsock32 -ladvapi32 -luser32 -lcrypt32" -debug-and-release -confirm-license -opensource -platform win32-msvc -prefix "C:\Qt\5.15.16\msvc2019_32bit_static" -opengl dynamic -nomake tests -no-compile-examples  -skip qtwebengine -mp -recheck
  • 执行结果
D:\qt-everywhere-src-5.15.16>configure OPENSSL_PREFIX="C:\Program Files (x86)\OpenSSL-Win32" OPENSSL_LIBS="-llibcrypto -llibssl -lgdi32 -lWs2_32 -lwsock32 -ladvapi32 -luser32 -lcrypt32" -openssl-linked -debug-and-release -confirm-license -opensource -platform win32-msvc -prefix "C:\Qt\5.15.16\msvc2019_x86" -opengl dynamic -nomake tests -no-compile-examples -webengine-proprietary-codecs  -mp -recheck
+ cd qtbase
+ D:\qt-everywhere-src-5.15.16\qtbase\configure.bat -top-level OPENSSL_PREFIX="C:\Program Files (x86)\OpenSSL-Win32" OPENSSL_LIBS="-llibcrypto -llibssl -lgdi32 -lWs2_32 -lwsock32 -ladvapi32 -luser32 -lcrypt32" -openssl-linked -debug-and-release -confirm-license -opensource -platform win32-msvc -prefix "C:\Qt\5.15.16\msvc2019_x86" -opengl dynamic -nomake tests -no-compile-examples -webengine-proprietary-codecs  -mp -recheck

Notice: re-mapping requested qmake spec to unified 'win32-msvc'.

Bootstrapping qmake ...

jom 1.1.3 - empower your cores


This is the Qt Open Source Edition.

You have already accepted the terms of the Open Source license.

Running configuration tests...
Checking for alloca() in alloca.h... no
Checking for C99 support... no
Checking for D-Bus >= 1.2... no
Checking for IncrediBuild... no
Checking for Support for Intel Control-flow Enforcement Technology... no
Checking for udev... no
Checking for POSIX fallocate()... no
Checking for zlib... no
Checking for Zstandard... no
Checking for eventfd... no
Checking for inotify... no
Checking for PCRE2... no
Checking for slog2... no
Checking for DoubleConversion... no
Checking for O_CLOEXEC... no
Checking for getifaddrs()... no
Checking for IPv6 ifname... no
Checking for XCB >= 1.11... no
Checking for KMS... no
Checking for EGL... no
Checking for evdev... no
Checking for GBM... no
Checking for LinuxFB... no
Checking for mtdev... no
Checking for OpenVG... no
Checking for libjpeg... no
Checking for libmd4c... no
Checking for tslib... no
Checking for Vulkan... no
Checking for XLib... no
Checking for xkbcommon >= 0.5.0... no
Checking for CUPS... no
Checking for DB2 (IBM)... no
Checking for InterBase... no
Checking for MySQL... no
Checking for OCI (Oracle)... no
Checking for PostgreSQL... no
Checking for SQLite (version 2)... no
Checking for TDS (Sybase)... no
Checking for ntddmodm... no
Checking for Assimp... no
Checking for SDL2... no
Checking for Assimp... no
Checking for Autodesk FBX... no
Checking for Wayland EGL library... no
Checking for BlueZ... no
Checking for sensorfw... no
Checking for Gypsy... no
Checking for GStreamer 1.0... no
Checking for GStreamer 0.10... no
Checking for OpenAL... no
Checking for libresourceqt5... no
Checking for Flite... no
Checking for libclang... no
Checking for d-bus... no
Checking for fontconfig... no
Checking for libdrm... no
Checking for xcomposite... no
Checking for xcursor... no
Checking for xi... no
Checking for xkbfile... no
Checking for xtst... no
Checking for embedded build... no
Done running configuration tests.

Configure summary:

Build type: win32-msvc (i386, CPU features: sse sse2)
Compiler: msvc 192930159
Configuration: sse2 aesni sse3 ssse3 sse4_1 sse4_2 avx avx2 avx512f avx512bw avx512cd avx512dq avx512er avx512ifma avx512pf avx512vbmi avx512vl f16c largefile msvc_mp precompile_header rdrnd rdseed shani x86SimdAlways shared shared debug_and_release release debug build_all c++11 c++14 c++17 c++1z concurrent dbus no-pkg-config release_tools stl
Build options:
  Mode ................................... debug and release; default link: debug; optimized tools
  Optimize release build for size ........ no
  Building shared libraries .............. yes
  Using C standard ....................... C89
  Using C++ standard ..................... C++17
  Relocatable ............................ yes
  Using precompiled headers .............. yes
  Using LTCG ............................. no
  Target compiler supports:
    SSE .................................. SSE2 SSE3 SSSE3 SSE4.1 SSE4.2
    AVX .................................. AVX AVX2
    AVX512 ............................... F ER CD PF DQ BW VL IFMA VBMI
    Other x86 ............................ AES F16C RDRAND SHA
  Build parts ............................ libs examples tools
  App store compliance ................... no
Qt modules and options:
  Qt Concurrent .......................... yes
  Qt D-Bus ............................... yes
  Qt D-Bus directly linked to libdbus .... no
  Qt Gui ................................. yes
  Qt Network ............................. yes
  Qt Sql ................................. yes
  Qt Testlib ............................. yes
  Qt Widgets ............................. yes
  Qt Xml ................................. yes
Support enabled for:
  Using pkg-config ....................... no
  udev ................................... no
  Using system zlib ...................... no
  Zstandard support ...................... no
Qt Core:
  DoubleConversion ....................... yes
    Using system DoubleConversion ........ no
  GLib ................................... no
  iconv .................................. no
  ICU .................................... no
  Built-in copy of the MIME database ..... yes
  Tracing backend ........................ <none>
  Logging backends:
    journald ............................. no
    syslog ............................... no
    slog2 ................................ no
  PCRE2 .................................. yes
    Using system PCRE2 ................... no
Qt Network:
  getifaddrs() ........................... no
  IPv6 ifname ............................ no
  libproxy ............................... no
  Schannel ............................... no
  OpenSSL ................................ yes
    Qt directly linked to OpenSSL ........ yes
  OpenSSL 1.1 ............................ yes
  DTLS ................................... yes
  OCSP-stapling .......................... yes
  SCTP ................................... no
  Use system proxies ..................... yes
  GSSAPI ................................. no
Qt Gui:
  Accessibility .......................... yes
  FreeType ............................... yes
    Using system FreeType ................ no
  HarfBuzz ............................... yes
    Using system HarfBuzz ................ no
  Fontconfig ............................. no
  Image formats:
    GIF .................................. yes
    ICO .................................. yes
    JPEG ................................. yes
      Using system libjpeg ............... no
    PNG .................................. yes
      Using system libpng ................ no
  Text formats:
    HtmlParser ........................... yes
    CssParser ............................ yes
    OdfWriter ............................ yes
    MarkdownReader ....................... yes
      Using system libmd4c ............... no
    MarkdownWriter ....................... yes
  EGL .................................... yes
  OpenVG ................................. no
  OpenGL:
    ANGLE ................................ yes
    Combined ANGLE Library ............... no
    Desktop OpenGL ....................... no
    Dynamic OpenGL ....................... yes
    OpenGL ES 2.0 ........................ no
    OpenGL ES 3.0 ........................ no
    OpenGL ES 3.1 ........................ no
    OpenGL ES 3.2 ........................ no
  Vulkan ................................. no
  Session Management ..................... yes
Features used by QPA backends:
  evdev .................................. no
  libinput ............................... no
  INTEGRITY HID .......................... no
  mtdev .................................. no
  tslib .................................. no
  xkbcommon .............................. no
  X11 specific:
    XLib ................................. no
    XCB Xlib ............................. no
    EGL on X11 ........................... no
    xkbcommon-x11 ........................ no
QPA backends:
  DirectFB ............................... no
  EGLFS .................................. no
  LinuxFB ................................ no
  VNC .................................... no
  Windows:
    Direct 2D ............................ yes
    DirectWrite .......................... yes
    DirectWrite 2 ........................ yes
Qt Sql:
  SQL item models ........................ yes
Qt Widgets:
  GTK+ ................................... no
  Styles ................................. Fusion Windows WindowsVista
Qt PrintSupport:
  CUPS ................................... no
Qt Sql Drivers:
  DB2 (IBM) .............................. no
  InterBase .............................. no
  MySql .................................. no
  OCI (Oracle) ........................... no
  ODBC ................................... yes
  PostgreSQL ............................. no
  SQLite2 ................................ no
  SQLite ................................. yes
    Using system provided SQLite ......... no
  TDS (Sybase) ........................... no
Qt Testlib:
  Tester for item models ................. yes
Serial Port:
  ntddmodm ............................... no
Qt SerialBus:
  Socket CAN ............................. no
  Socket CAN FD .......................... no
  SerialPort Support ..................... yes
Further Image Formats:
  JasPer ................................. no
  MNG .................................... no
  TIFF ................................... yes
    Using system libtiff ................. no
  WEBP ................................... yes
    Using system libwebp ................. no
Qt QML:
  QML network support .................... yes
  QML debugging and profiling support .... yes
  QML just-in-time compiler .............. yes
  QML sequence object .................... yes
  QML XML http request ................... yes
  QML Locale ............................. yes
Qt QML Models:
  QML list model ......................... yes
  QML delegate model ..................... yes
Qt Quick:
  Direct3D 12 ............................ yes
  AnimatedImage item ..................... yes
  Canvas item ............................ yes
  Support for Qt Quick Designer .......... yes
  Flipable item .......................... yes
  GridView item .......................... yes
  ListView item .......................... yes
  TableView item ......................... yes
  Path support ........................... yes
  PathView item .......................... yes
  Positioner items ....................... yes
  Repeater item .......................... yes
  ShaderEffect item ...................... yes
  Sprite item ............................ yes
QtQuick3D:
  Assimp ................................. yes
  System Assimp .......................... no
Qt Scxml:
  ECMAScript data model for QtScxml ...... yes
Qt Gamepad:
  SDL2 ................................... no
Qt 3D:
  Assimp ................................. yes
  System Assimp .......................... no
  Output Qt3D GL traces .................. no
  Use SSE2 instructions .................. no
  Use AVX2 instructions .................. no
  Aspects:
    Render aspect ........................ yes
    Input aspect ......................... yes
    Logic aspect ......................... yes
    Animation aspect ..................... yes
    Extras aspect ........................ yes
Qt 3D Renderers:
  OpenGL Renderer ........................ yes
  RHI Renderer ........................... no
Qt 3D GeometryLoaders:
  Autodesk FBX ........................... no
Qt Wayland Client ........................ no
Qt Wayland Compositor .................... no
Qt Bluetooth:
  BlueZ .................................. no
  BlueZ Low Energy ....................... no
  Linux Crypto API ....................... no
  Native Win32 Bluetooth ................. no
  WinRT Bluetooth API (desktop & UWP) .... yes
  WinRT advanced bluetooth low energy API (desktop & UWP) . yes
Qt Sensors:
  sensorfw ............................... no
Qt Quick Controls 2:
  Styles ................................. Default Fusion Imagine Material Universal
Qt Quick Templates 2:
  Hover support .......................... yes
  Multi-touch support .................... yes
Qt Positioning:
  Gypsy GPS Daemon ....................... no
  WinRT Geolocation API .................. yes
Qt Location:
  Qt.labs.location experimental QML plugin . no
  Geoservice plugins:
    OpenStreetMap ........................ yes
    HERE ................................. yes
    Esri ................................. yes
    Mapbox ............................... yes
    MapboxGL ............................. no
    Itemsoverlay ......................... yes
QtXmlPatterns:
  XML schema support ..................... yes
Qt Multimedia:
  ALSA ................................... no
  GStreamer 1.0 .......................... no
  GStreamer 0.10 ......................... no
  Video for Linux ........................ no
  OpenAL ................................. no
  PulseAudio ............................. no
  Resource Policy (libresourceqt5) ....... no
  Windows Audio Services ................. yes
  DirectShow ............................. yes
  Windows Media Foundation ............... yes
Qt TextToSpeech:
  Flite .................................. no
  Flite with ALSA ........................ no
  Speech Dispatcher ...................... no
Qt Tools:
  Qt Assistant ........................... yes
  Qt Designer ............................ yes
  Qt Distance Field Generator ............ yes
  kmap2qmap .............................. yes
  Qt Linguist ............................ yes
  Mac Deployment Tool .................... no
  makeqpf ................................ yes
  pixeltool .............................. yes
  qdbus .................................. yes
  qev .................................... yes
  Qt Attributions Scanner ................ yes
  qtdiag ................................. yes
  qtpaths ................................ yes
  qtplugininfo ........................... yes
  Windows deployment tool ................ yes
  WinRT Runner Tool ...................... no
Qt Tools:
  QDoc ................................... no
Qt WebEngine Build Tools:
  Use System Ninja ....................... yes
  Jumbo Build Merge Limit ................ no
  Developer build ........................ no
  Sanitizer .............................. no
Qt WebEngineCore:
  Embedded build ......................... no
  Full debug information ................. no
  Pepper Plugins ......................... yes
  Printing and PDF ....................... yes
  Proprietary Codecs ..................... yes
  Spellchecker ........................... yes
  Native Spellchecker .................... no
  WebRTC ................................. yes
  PipeWire over GIO ...................... no
  Geolocation ............................ yes
  WebChannel support ..................... yes
  Kerberos Authentication ................ yes
  Extensions ............................. yes
Qt WebEngineQml:
  Support Qt WebEngine Qml ............... yes
  UI Delegates ........................... yes
  Test Support ........................... no
Qt WebEngineWidgets:
  Support Qt WebEngine Widgets ........... yes
Qt PDF:
  Support V8 ............................. no
  Support XFA ............................ no
  Support XFA-BMP ........................ no
  Support XFA-GIF ........................ no
  Support XFA-PNG ........................ no
  Support XFA-TIFF ....................... no
  Bitcode support ........................ no
  Use static runtime ..................... no
Qt PDF Widgets:
  Support Qt PDF Widgets ................. yes

Note: No wayland-egl support detected. Cross-toolkit compatibility disabled.

WARNING: QDoc will not be compiled, probably because libclang could not be located. This means that you cannot build the Qt documentation.

Either ensure that llvm-config is in your PATH environment variable, or set LLVM_INSTALL_DIR to the location of your llvm installation.
On Linux systems, you may be able to install libclang by installing the libclang-dev or libclang-devel package, depending on your distribution.
On macOS, you can use Homebrew's llvm package.
On Windows, you must set LLVM_INSTALL_DIR to the installation path.

Qt is now configured for building. Just run 'jom'.
Once everything is built, you must run 'jom install'.
Qt will be installed into 'C:\Qt\5.15.16\msvc2019_x86'.

Prior to reconfiguration, make sure you remove any leftovers from
the previous build.
jom 2> error_jom.log

jom install 2> error_jom_install.log

-webengine-proprietary-codecs 是开启mp4播放
-mp 开启多线程编译

备注:

两颗 至强银牌4214 cpu+32G内存的服务器上,用jom编译3次才成功,失败了继续执行jom就行

评论 7
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值