MSVC Builds: Create libgtk3.manifest

Use the Python script that was used to create gtk-win32.rc from
gtk-win32.rc.in to similarly create libgtk3.manifest.  As the wildcard
character can be used for all architectures, use that.

The libgtk3.manifest file needs to be specified explicitly in the projects,
so that it will be recognized and built into the GTK dll, so update the
project files as well on this part.

https://bugzilla.gnome.org/show_bug.cgi?id=733773
This commit is contained in:
Chun-wei Fan
2014-08-06 15:42:23 +08:00
parent 781846e564
commit 285f1cc30f
6 changed files with 20 additions and 14 deletions

View File

@ -69,7 +69,7 @@ def main(argv):
parser.add_argument('--gtk3manifest', dest='gtk3manifest', action='store_const', parser.add_argument('--gtk3manifest', dest='gtk3manifest', action='store_const',
const=1, const=1,
help='Generate libgtk3.manifest (Not used now)') help='Generate libgtk3.manifest')
args = parser.parse_args() args = parser.parse_args()
no_args = True no_args = True
@ -85,12 +85,11 @@ def main(argv):
no_args = False no_args = False
if args.gtk3manifest is not None: if args.gtk3manifest is not None:
print('Not Used... Will add once gtk/libgtk3.manifest.in is added') manifest = {}
#manifest = {} manifest['EXE_MANIFEST_ARCHITECTURE'] = '*'
#manifest['EXE_MANIFEST_ARCHITECTURE'] = '*' process_in(os.path.join(srcroot, 'gtk', 'libgtk3.manifest.in'),
#process_in(os.path.join(srcroot, 'gtk', 'libgtk3.manifest.in', os.path.join(srcroot, 'gtk', 'libgtk3.manifest'),
# os.path.join(srcroot, 'gtk', 'libgtk3.manifest', manifest)
# manifest)
no_args = False no_args = False
if no_args is True: if no_args is True:

View File

@ -64,7 +64,7 @@ $(PythonPath)\python $(GlibEtcInstallRoot)\bin\gdbus-codegen --interface-prefix
cd $(SolutionDir) cd $(SolutionDir)
</GenerateGtkDbusBuiltSources> </GenerateGtkDbusBuiltSources>
<GenerateGtkWin32RC>$(PythonPath)\python ..\process-in-win32.py --gtkwin32rc</GenerateGtkWin32RC> <GenerateGtkWin32RC>$(PythonPath)\python ..\process-in-win32.py --gtkwin32rc --gtk3manifest</GenerateGtkWin32RC>
</PropertyGroup> </PropertyGroup>
<PropertyGroup> <PropertyGroup>
<_PropertySheetDisplayName>gtkgensrcsprops</_PropertySheetDisplayName> <_PropertySheetDisplayName>gtkgensrcsprops</_PropertySheetDisplayName>

View File

@ -39,4 +39,7 @@
<ClCompile Include="..\..\..\modules\input\imviqr.c"><Filter>Source Files</Filter></ClCompile> <ClCompile Include="..\..\..\modules\input\imviqr.c"><Filter>Source Files</Filter></ClCompile>
<ClCompile Include="..\..\..\modules\input\thai-charprop.c"><Filter>Source Files</Filter></ClCompile> <ClCompile Include="..\..\..\modules\input\thai-charprop.c"><Filter>Source Files</Filter></ClCompile>
</ItemGroup> </ItemGroup>
<ItemGroup>
<Manifest Include="..\..\..\gtk\libgtk3.manifest"><Filter>Resource Files</Filter></Manifest>
</ItemGroup>
</Project> </Project>

View File

@ -219,6 +219,9 @@
<ReferenceOutputAssembly>false</ReferenceOutputAssembly> <ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference> </ProjectReference>
</ItemGroup> </ItemGroup>
<ItemGroup>
<Manifest Include="..\..\..\gtk\libgtk3.manifest" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets"> <ImportGroup Label="ExtensionTargets">
</ImportGroup> </ImportGroup>

View File

@ -64,6 +64,6 @@ cd $(SolutionDir)&#x0D;&#x0A;
/> />
<UserMacro <UserMacro
Name="GenerateGtkWin32RC" Name="GenerateGtkWin32RC"
Value="$(PythonPath)\python ..\process-in-win32.py --gtkwin32rc" Value="$(PythonPath)\python ..\process-in-win32.py --gtkwin32rc --gtk3manifest"
/> />
</VisualStudioPropertySheet> </VisualStudioPropertySheet>

View File

@ -197,32 +197,33 @@
<Tool Name="VCCustomBuildTool" <Tool Name="VCCustomBuildTool"
Description="Generating GTK+ Win32 Version Resource..." Description="Generating GTK+ Win32 Version Resource..."
CommandLine="$(GenerateGtkWin32RC)" CommandLine="$(GenerateGtkWin32RC)"
Outputs="..\..\..\gtk\gtk-win32.rc" Outputs="..\..\..\gtk\gtk-win32.rc;..\..\..\gtk\libgtk3.manifest"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration Name="Release|Win32"> <FileConfiguration Name="Release|Win32">
<Tool Name="VCCustomBuildTool" <Tool Name="VCCustomBuildTool"
Description="Generating GTK+ Win32 Version Resource..." Description="Generating GTK+ Win32 Version Resource..."
CommandLine="$(GenerateGtkWin32RC)" CommandLine="$(GenerateGtkWin32RC)"
Outputs="..\..\..\gtk\gtk-win32.rc" Outputs="..\..\..\gtk\gtk-win32.rc;..\..\..\gtk\libgtk3.manifest"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration Name="Debug|x64"> <FileConfiguration Name="Debug|x64">
<Tool Name="VCCustomBuildTool" <Tool Name="VCCustomBuildTool"
Description="Generating GTK+ Win32 Version Resource..." Description="Generating GTK+ Win32 Version Resource..."
CommandLine="$(GenerateGtkWin32RC)" CommandLine="$(GenerateGtkWin32RC)"
Outputs="..\..\..\gtk\gtk-win32.rc" Outputs="..\..\..\gtk\gtk-win32.rc;..\..\..\gtk\libgtk3.manifest"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration Name="Release|x64"> <FileConfiguration Name="Release|x64">
<Tool Name="VCCustomBuildTool" <Tool Name="VCCustomBuildTool"
Description="Generating GTK+ Win32 Version Resource..." Description="Generating GTK+ Win32 Version Resource..."
CommandLine="$(GenerateGtkWin32RC)" CommandLine="$(GenerateGtkWin32RC)"
Outputs="..\..\..\gtk\gtk-win32.rc" Outputs="..\..\..\gtk\gtk-win32.rc;..\..\..\gtk\libgtk3.manifest"
/> />
</FileConfiguration> </FileConfiguration>
</File> </File>
<File RelativePath="..\..\..\gtk\gtk-win32.rc" /> <File RelativePath="..\..\..\gtk\gtk-win32.rc" />
<File RelativePath="..\..\..\gtk\libgtk3.manifest"/>
</Filter> </Filter>
<Filter <Filter
Name="Source Files" Name="Source Files"