diff options
Diffstat (limited to 'buildqt64.bat')
-rwxr-xr-x | buildqt64.bat | 62 |
1 files changed, 62 insertions, 0 deletions
diff --git a/buildqt64.bat b/buildqt64.bat new file mode 100755 index 0000000..b4e0fca --- /dev/null +++ b/buildqt64.bat @@ -0,0 +1,62 @@ +@echo off
+
+SET BASEDIR=%~dp0
+
+SET SDKDIR=z:\VS2019BT
+SET PERLDIR=z:\Perl64
+
+SET QT_VERSION=5.12
+SET QT_RELEASE=3
+
+SET QT_FULL_VER=%QT_VERSION%.%QT_RELEASE%
+SET QT_SOURCE_ARCHIVE=qt-everywhere-src-%QT_FULL_VER%.zip
+SET "DL_URL=https://download.qt.io/official_releases/qt/%QT_VERSION%/%QT_FULL_VER%/single/%QT_SOURCE_ARCHIVE%"
+SET SRC_DIR=%BASEDIR%qt-%QT_VERSION%
+SET OPENSSL=openssl-1.0.2r
+SET OPENSSL_URL=https://www.openssl.org/source/%OPENSSL%.tar.gz"
+
+SET PATH=%BASEDIR%\wintools;%PERLDIR%\bin;%PATH%
+
+if not exist "%OPENSSL%.tar.gz" wget.exe -c "%OPENSSL_URL%"
+7za.exe x %OPENSSL%.tar.gz -y
+if not exist "%OPENSSL%" 7za.exe x %OPENSSL%.tar -y
+
+rem 64 Bit
+SET INST_ARCH=x86_64-msvc
+call "%SDKDIR%\setvcvars.bat" 2019 x64
+
+if not exist "%BASEDIR%openssl\%INST_ARCH%\lib" (
+rem - static -
+cd %OPENSSL%
+call perl Configure VC-WIN64A --prefix=%BASEDIR%openssl\%INST_ARCH%
+call ms\do_win64a
+call nmake -f ms\nt.mak
+call nmake -f ms\nt.mak install
+rem - shared -
+cd %OPENSSL%
+call perl Configure VC-WIN64A --prefix=%BASEDIR%openssl\%INST_ARCH%
+call ms\do_win64a
+call nmake -f ms\ntdll.mak
+call nmake -f ms\ntdll.mak install
+)
+
+if not exist "%QT_SOURCE_ARCHIVE%" wget.exe -c "%DL_URL%"
+
+if exist %SRC_DIR% (
+ echo Removing previous build dir %SRC_DIR% ...
+ del /f /s /q %SRC_DIR% > nul
+ rmdir /s /q %SRC_DIR%
+)
+
+7za.exe x %QT_SOURCE_ARCHIVE% -y
+rename qt-everywhere-src-%QT_FULL_VER% qt-%QT_VERSION%
+
+SET PREFIX=%BASEDIR%qt-%QT_VERSION%-%INST_ARCH%\
+cd %SRC_DIR%
+del config.cache
+call .\configure -prefix %PREFIX% -mp -static -shared -platform win32-msvc -release -nomake examples -nomake tests -skip qtdoc -skip qtgamepad -skip qtwebengine -ssl -openssl -I%BASEDIR%openssl\%INST_ARCH%\include -L%BASEDIR%openssl\%INST_ARCH%\lib -opensource -qt-zlib -qt-libjpeg -qt-libpng -qt-pcre -qt-freetype -opengl desktop -confirm-license
+call nmake
+call nmake install
+cd %PREFIX%
+%BASEDIR%wintools\7za.exe a -tzip %BASEDIR%\qt-%QT_VERSION%-%INST_ARCH%.zip .\*
+cd %BASEDIR%
\ No newline at end of file |