Skip to content

Commit e7475d1

Browse files
committed
Update build config
1 parent ef1e2d9 commit e7475d1

File tree

6 files changed

+1339
-1
lines changed

6 files changed

+1339
-1
lines changed

.github/workflows/msbuild.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# separate terms of service, privacy policy, and support
44
# documentation.
55

6-
name: MSBuild
6+
name: QtReleaseBuild
77

88
on:
99
push:

QtMsBuild/Qt.props

+59
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<!--
3+
/****************************************************************************
4+
**
5+
** Copyright (C) 2020 The Qt Company Ltd.
6+
** Contact: https://www.qt.io/licensing/
7+
**
8+
** This file is part of the Qt VS Tools.
9+
**
10+
** $QT_BEGIN_LICENSE:GPL-EXCEPT$
11+
** Commercial License Usage
12+
** Licensees holding valid commercial Qt licenses may use this file in
13+
** accordance with the commercial license agreement provided with the
14+
** Software or, alternatively, in accordance with the terms contained in
15+
** a written agreement between you and The Qt Company. For licensing terms
16+
** and conditions see https://www.qt.io/terms-conditions. For further
17+
** information use the contact form at https://www.qt.io/contact-us.
18+
**
19+
** GNU General Public License Usage
20+
** Alternatively, this file may be used under the terms of the GNU
21+
** General Public License version 3 as published by the Free Software
22+
** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
23+
** included in the packaging of this file. Please review the following
24+
** information to ensure the GNU General Public License requirements will
25+
** be met: https://www.gnu.org/licenses/gpl-3.0.html.
26+
**
27+
** $QT_END_LICENSE$
28+
**
29+
****************************************************************************/
30+
-->
31+
<!--
32+
///////////////////////////////////////////////////////////////////////////////////////////////////
33+
// Item type definition and default values
34+
// -->
35+
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
36+
<!--
37+
/////////////////////////////////////////////////////////////////////////////////////////////////
38+
// Import private Qt property definitions
39+
// -->
40+
<ImportGroup Label="Qt">
41+
<Import Project="$(MSBuildThisFileDirectory)\qt_private.props"/>
42+
</ImportGroup>
43+
<!--
44+
/////////////////////////////////////////////////////////////////////////////////////////////////
45+
// User-defined settings
46+
// -->
47+
<PropertyGroup Label="UserMacros">
48+
<!-- Placeholder for user macros written by VS Property Manager -->
49+
</PropertyGroup>
50+
<PropertyGroup>
51+
<!-- Placeholder for properties written by VS Property Manager -->
52+
</PropertyGroup>
53+
<ItemDefinitionGroup>
54+
<!-- Placeholder for default metadata written by VS Property Manager -->
55+
</ItemDefinitionGroup>
56+
<ItemGroup>
57+
<!-- Placeholder for items written by VS Property Manager -->
58+
</ItemGroup>
59+
</Project>

QtMsBuild/qt.targets

+67
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<!--
3+
/***************************************************************************************************
4+
Copyright (C) 2024 The Qt Company Ltd.
5+
SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
6+
***************************************************************************************************/
7+
-->
8+
9+
<!--
10+
///////////////////////////////////////////////////////////////////////////////////////////////////
11+
// Qt/MSBuild
12+
// -->
13+
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
14+
<!--
15+
/////////////////////////////////////////////////////////////////////////////////////////////////
16+
// Fail-safe import of private definitions
17+
// -->
18+
<Import
19+
Condition="'$(QtPrivateLoaded)' != 'true'"
20+
Project="$(MSBuildThisFileDirectory)\qt_private.props"/>
21+
22+
<!--
23+
/////////////////////////////////////////////////////////////////////////////////////////////////
24+
// Defaults for project version constants
25+
// -->
26+
<PropertyGroup>
27+
<QtVsProjectVersion
28+
Condition="'$(QtVsProjectVersion)' == ''"
29+
>0</QtVsProjectVersion>
30+
<QtVsProjectMinVersion_Settings
31+
Condition="'$(QtVsProjectMinVersion_Settings)' == ''"
32+
>0</QtVsProjectMinVersion_Settings>
33+
<QtVsProjectMinVersion_ClProperties
34+
Condition="'$(QtVsProjectMinVersion_ClProperties)' == ''"
35+
>0</QtVsProjectMinVersion_ClProperties>
36+
</PropertyGroup>
37+
38+
<!--
39+
/////////////////////////////////////////////////////////////////////////////////////////////////
40+
// Defaults for CriticalSection task
41+
// -->
42+
<PropertyGroup>
43+
<QtCriticalSectionTimeout Condition="'$(QtCriticalSectionTimeout)' == ''"
44+
>10</QtCriticalSectionTimeout>
45+
<QtCriticalSectionFixedTimeout Condition="'$(QtCriticalSectionFixedTimeout)' == ''"
46+
>false</QtCriticalSectionFixedTimeout>
47+
<QtCriticalSectionDelay Condition="'$(QtCriticalSectionDelay)' == ''"
48+
>0</QtCriticalSectionDelay>
49+
</PropertyGroup>
50+
51+
<!--
52+
/////////////////////////////////////////////////////////////////////////////////////////////////
53+
// Qt Common Targets
54+
// -->
55+
<Import Project="qt_globals.targets"/>
56+
<Import Project="qt_settings.targets"/>
57+
<Import Project="qt_tasks.targets"/>
58+
<Import Project="qt_vars.targets"/>
59+
60+
<!--
61+
/////////////////////////////////////////////////////////////////////////////////////////////////
62+
// Import subfolder targets
63+
// -->
64+
<Import
65+
Project="$(QtMsBuildTargets)"/>
66+
67+
</Project>

QtMsBuild/qt_defaults.props

+155
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,155 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<!--
3+
/***************************************************************************************************
4+
Copyright (C) 2024 The Qt Company Ltd.
5+
SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
6+
***************************************************************************************************/
7+
-->
8+
9+
<!--
10+
///////////////////////////////////////////////////////////////////////////////////////////////////
11+
// Default values of Qt settings
12+
//
13+
// Preceding evaluation chain:
14+
// * Project global properties, incl. $(Keyword), $(WindowsTargetPlatformVersion), $(QtMsBuild)
15+
// * Microsoft.Cpp.Default.props
16+
// * Configuration properties, incl. $(ConfigurationType), $(PlatformToolset)
17+
//
18+
// -->
19+
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
20+
<PropertyGroup>
21+
<QtDefaultsLoaded>true</QtDefaultsLoaded>
22+
</PropertyGroup>
23+
24+
<!-- // Qt VS Project Format Version -->
25+
<PropertyGroup>
26+
<QtVsProjectVersion>0</QtVsProjectVersion>
27+
<QtVsProjectMinVersion_Settings>300</QtVsProjectMinVersion_Settings>
28+
<QtVsProjectMinVersion_ClProperties>300</QtVsProjectMinVersion_ClProperties>
29+
</PropertyGroup>
30+
<PropertyGroup Condition="'$(Keyword)' != ''">
31+
<QtVsProjectVersion Condition="'$(Keyword)' == 'Qt4VSv1.0'">200</QtVsProjectVersion>
32+
<QtVsProjectVersion Condition="$(Keyword.StartsWith('QtVS_v'))"
33+
>$([System.Convert]::ToInt32($(Keyword.Substring(6))))</QtVsProjectVersion>
34+
<QtVsProjectSettings Condition="$(QtVsProjectVersion) &gt;= $(QtVsProjectMinVersion_Settings)"
35+
>true</QtVsProjectSettings>
36+
<QtVsProjectSettings Condition="$(QtVsProjectVersion) &lt; $(QtVsProjectMinVersion_Settings)"
37+
>false</QtVsProjectSettings>
38+
<QtVsProjectClProperties
39+
Condition="$(QtVsProjectVersion) &gt;= $(QtVsProjectMinVersion_ClProperties)"
40+
>true</QtVsProjectClProperties>
41+
<QtVsProjectClProperties
42+
Condition="$(QtVsProjectVersion) &lt; $(QtVsProjectMinVersion_ClProperties)"
43+
>false</QtVsProjectClProperties>
44+
</PropertyGroup>
45+
46+
<PropertyGroup>
47+
<!--// Path of Qt binary files -->
48+
<QtPathBinaries>bin</QtPathBinaries>
49+
<QtPathLibraryExecutables>bin</QtPathLibraryExecutables>
50+
51+
<!--// Run Qt tools during design-time build -->
52+
<QtToolsDesignTime>true</QtToolsDesignTime>
53+
54+
<!--// qmake template -->
55+
<QtQMakeTemplate>vcapp</QtQMakeTemplate>
56+
57+
<!--// Extract Qt variables from qmake-generated Makefile
58+
// Syntax: < var_name > [ = [ makefile_name ] / < pattern > / < replace > / ] -->
59+
<QMake_Makefile>
60+
DEFINES=/-D([^\s=]+(=(\x22(\\\\|\\\x22|[^\x22])*\x22|\S+))?)/$1/;
61+
INCLUDEPATH=INCPATH/-(?:iquote|isystem|idirafter|I)\s*(\x22[^\x22]+\x22|[^\s]+)/$1/;
62+
LIBS=/(?:(?:\/LIBPATH:|-L)(?:\x22[^\x22]+\x22|[^\s]+))|(\x22[^\x22]+\x22|[^\s]+)/$1/;
63+
LIBPATH=LIBS/(?:\/LIBPATH:|-L)(\x22[^\x22]+\x22|[^\s]+)/$1/;
64+
</QMake_Makefile>
65+
66+
<!--// Extract Qt variables from qmake-generated .vcxproj file
67+
// Syntax: < var_name > = < xpath_to_value > -->
68+
<QMake_MSBuild>
69+
DEFINES=/Project/ItemDefinitionGroup/ClCompile/PreprocessorDefinitions;
70+
INCLUDEPATH=/Project/ItemDefinitionGroup/ClCompile/AdditionalIncludeDirectories;
71+
STDCPP=/Project/ItemDefinitionGroup/ClCompile/LanguageStandard;
72+
RUNTIME=/Project/ItemDefinitionGroup/ClCompile/RuntimeLibrary;
73+
CL_OPTIONS=/Project/ItemDefinitionGroup/ClCompile/AdditionalOptions;
74+
LIBS=/Project/ItemDefinitionGroup/Link/AdditionalDependencies;
75+
LINK_OPTIONS=/Project/ItemDefinitionGroup/Link/AdditionalOptions;
76+
</QMake_MSBuild>
77+
78+
<!--// Default Qt version -->
79+
<QtVersionsRegKey Condition="'$(QtVersionsRegKey)' == ''"
80+
>HKEY_CURRENT_USER\Software\QtProject\QtVsTools\Versions</QtVersionsRegKey>
81+
<DefaultQtVersion Condition="'$(DefaultQtVersion)' == ''"
82+
>$([MSBuild]::GetRegistryValue('$(QtVersionsRegKey)','DefaultQtVersion'))</DefaultQtVersion>
83+
84+
<!--// Qt build config -->
85+
<QtBuildConfig Condition="'$(Configuration)' == 'Debug'">debug</QtBuildConfig>
86+
<QtBuildConfig Condition="'$(Configuration)' != 'Debug'">release</QtBuildConfig>
87+
88+
<!--// Qt Plugin default-->
89+
<QtPlugin>false</QtPlugin>
90+
91+
<!--// MOC macro names defaults -->
92+
<MocMacroNames>Q_OBJECT;Q_GADGET;Q_NAMESPACE;Q_NAMESPACE_EXPORT</MocMacroNames>
93+
94+
<!--// QML debug disabled by default -->
95+
<QtQMLDebugEnable>false</QtQMLDebugEnable>
96+
97+
<!--// Default Qt settings -->
98+
<QtInstall Condition="'$(QtInstall)' == ''">$(DefaultQtVersion)</QtInstall>
99+
<QtModules Condition="'$(QtModules)' == ''">core</QtModules>
100+
</PropertyGroup>
101+
102+
<!--// Default late bindings -->
103+
<ItemGroup>
104+
<Qt Include="Qt">
105+
<IntDir>$(IntDir)</IntDir>
106+
<OutDir>$(OutDir)</OutDir>
107+
</Qt>
108+
<QtLateBindings Include="IntDir" />
109+
<QtLateBindings Include="OutDir" />
110+
<QtLateBindings Include="QtInstall" />
111+
<QtLateBindings Include="QtModules" />
112+
<QtLateBindings Include="QtPlugin" />
113+
<QtLateBindings Include="QtBuildConfig" />
114+
<QtLateBindings Include="QtToolsDesignTime" />
115+
<QtLateBindings Include="QtPathBinaries" />
116+
<QtLateBindings Include="QtPathLibraryExecutables" />
117+
<QtLateBindings Include="QtHeaderSearchPath" />
118+
<QtLateBindings Include="QtLibrarySearchPath" />
119+
<QtLateBindings Include="QtQMakeTemplate" />
120+
<QtLateBindings Include="QtVars" />
121+
<QtLateBindings Include="QMakeExtraArgs" />
122+
<QtLateBindings Include="QMakeCodeLines" />
123+
<QtLateBindings Include="QtQMLDebugEnable" />
124+
<QtLateBindings Include="Qt_CL_OPTIONS_" />
125+
<QtLateBindings Include="QtExcludedOptions" />
126+
<QtLateBindings Include="QtOptionsBuildLog" />
127+
<QtLateBindings Include="QtLinkNatvisFile" />
128+
<QtLateBindings Include="QtInstallDir" />
129+
<QtLateBindings Include="QtToolsPath" />
130+
<QtLateBindings Include="QtDllPath" />
131+
</ItemGroup>
132+
<PropertyGroup>
133+
<QtLateBindings Condition="'$(QtLateBindings)' == ''">@(QtLateBindings)</QtLateBindings>
134+
</PropertyGroup>
135+
136+
<!--
137+
/////////////////////////////////////////////////////////////////////////////////////////////////
138+
// Read subfolder dependencies (qt_import.props)
139+
// -->
140+
<PropertyGroup>
141+
<SubFolder>$([System.IO.Directory]::GetDirectories('$(MSBuildThisFileDirectory)'))</SubFolder>
142+
<SubFolderImports Condition="'$(SubFolder)' != ''"
143+
>
144+
$([System.String]::Join(
145+
'\qt_import.props;',
146+
$(SubFolder.Split(';'))))\qt_import.props
147+
</SubFolderImports>
148+
<QtImports>$(SubFolderImports.Split(';'))</QtImports>
149+
<SubFolder/>
150+
<SubFolderImports/>
151+
</PropertyGroup>
152+
<Import
153+
Project="$(QtImports)"/>
154+
155+
</Project>

0 commit comments

Comments
 (0)