Add Visual C++ 2008 projects for GResource tools

Add projects to build the glib-compile-resources and gresource(-tool)
utilities, and "install" these tools upon successful compilation, and dist
the new projects.

One piece of note: will it be better to dist gconstructor_as_data.h instead
of generating it in the VS build process (I generated it in the property
sheet update in this commit)?

Visual C++ 2010 projects will follow shortly.
This commit is contained in:
Chun-wei Fan 2012-02-07 14:37:57 +08:00
parent 867f554ea5
commit d858cd3047
5 changed files with 365 additions and 0 deletions

View File

@ -16,4 +16,6 @@ EXTRA_DIST = \
testglib.vcproj \
glib-compile-schemas.vcproj \
gsettings.vcproj \
glib-compile-resources.vcproj \
gresource.vcproj \
install.vcproj

View File

@ -0,0 +1,156 @@
<?xml version="1.0" encoding="big5"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="9.00"
Name="glib-compile-resources"
ProjectGUID="{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}"
RootNamespace="glibcompileresources"
Keyword="Win32Proj"
TargetFrameworkVersion="196613"
>
<Platforms>
<Platform
Name="Win32"
/>
<Platform
Name="x64"
/>
</Platforms>
<ToolFiles>
</ToolFiles>
<Configurations>
<Configuration
Name="Debug|Win32"
InheritedPropertySheets=".\glib.vsprops"
ConfigurationType="1"
CharacterSet="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="..\..\..\gmodule;..\..\..\gio"
PreprocessorDefinitions="_DEBUG;GIO_COMPILATION"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
UsePrecompiledHeader="0"
WarningLevel="3"
DebugInformationFormat="4"
/>
<Tool
Name="VCLinkerTool"
LinkIncremental="2"
GenerateDebugInformation="true"
SubSystem="1"
TargetMachine="1"
/>
</Configuration>
<Configuration
Name="Debug|x64"
InheritedPropertySheets=".\glib.vsprops"
ConfigurationType="1"
CharacterSet="2"
>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="..\..\..\gmodule;..\..\..\gio"
PreprocessorDefinitions="_DEBUG;GIO_COMPILATION"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
UsePrecompiledHeader="0"
WarningLevel="3"
DebugInformationFormat="3"
CompileAs="1"
/>
<Tool
Name="VCLinkerTool"
LinkIncremental="2"
GenerateDebugInformation="true"
SubSystem="1"
RandomizedBaseAddress="1"
DataExecutionPrevention="0"
TargetMachine="17"
/>
</Configuration>
<Configuration
Name="Release|Win32"
InheritedPropertySheets=".\glib.vsprops"
ConfigurationType="1"
CharacterSet="1"
WholeProgramOptimization="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="2"
EnableIntrinsicFunctions="true"
AdditionalIncludeDirectories="..\..\..\gmodule;..\..\..\gio"
PreprocessorDefinitions="GIO_COMPILATION"
RuntimeLibrary="2"
EnableFunctionLevelLinking="true"
UsePrecompiledHeader="0"
WarningLevel="3"
DebugInformationFormat="3"
/>
<Tool
Name="VCLinkerTool"
LinkIncremental="1"
GenerateDebugInformation="true"
SubSystem="1"
OptimizeReferences="2"
EnableCOMDATFolding="2"
TargetMachine="1"
/>
</Configuration>
<Configuration
Name="Release|x64"
InheritedPropertySheets=".\glib.vsprops"
ConfigurationType="1"
CharacterSet="2"
WholeProgramOptimization="1"
>
<Tool
Name="VCCLCompilerTool"
AdditionalIncludeDirectories="..\..\..\gmodule;..\..\..\gio"
PreprocessorDefinitions="GIO_COMPILATION"
RuntimeLibrary="2"
UsePrecompiledHeader="0"
WarningLevel="3"
DebugInformationFormat="3"
CompileAs="1"
/>
<Tool
Name="VCLinkerTool"
LinkIncremental="1"
GenerateDebugInformation="true"
SubSystem="1"
OptimizeReferences="2"
EnableCOMDATFolding="2"
RandomizedBaseAddress="1"
DataExecutionPrevention="0"
TargetMachine="17"
/>
</Configuration>
</Configurations>
<References>
</References>
<Files>
<Filter
Name="Source Files"
Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
>
<File RelativePath="..\..\..\gio\glib-compile-resources.c" />
<File RelativePath="..\..\..\gio\gvdb\gvdb-builder.c" />
</Filter>
</Files>
<Globals>
</Globals>
</VisualStudioProject>

View File

@ -59,6 +59,20 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "gsettings", "gsettings.vcpr
{F3D1583C-5613-4809-BD98-7CC1C1276F92} = {F3D1583C-5613-4809-BD98-7CC1C1276F92}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "glib-compile-resources", "glib-compile-resources.vcproj", "{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}"
ProjectSection(ProjectDependencies) = postProject
{12BCA020-EABF-429E-876A-A476BC9C10C0} = {12BCA020-EABF-429E-876A-A476BC9C10C0}
{F172EFFC-E30F-4593-809E-DB2024B1E753} = {F172EFFC-E30F-4593-809E-DB2024B1E753}
{F3D1583C-5613-4809-BD98-7CC1C1276F92} = {F3D1583C-5613-4809-BD98-7CC1C1276F92}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "gresource", "gresource.vcproj", "{95A1571F-61BE-4C51-BE53-2F2DAB280685}"
ProjectSection(ProjectDependencies) = postProject
{12BCA020-EABF-429E-876A-A476BC9C10C0} = {12BCA020-EABF-429E-876A-A476BC9C10C0}
{F172EFFC-E30F-4593-809E-DB2024B1E753} = {F172EFFC-E30F-4593-809E-DB2024B1E753}
{F3D1583C-5613-4809-BD98-7CC1C1276F92} = {F3D1583C-5613-4809-BD98-7CC1C1276F92}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "install", "install.vcproj", "{2093D218-190E-4194-9421-3BA7CBF33B10}"
ProjectSection(ProjectDependencies) = postProject
{12BCA020-EABF-429E-876A-A476BC9C10C0} = {12BCA020-EABF-429E-876A-A476BC9C10C0}
@ -262,6 +276,38 @@ Global
{05041C63-F1C5-49BA-A7DE-61EBB5307EAA}.Release_ExtPCRE|Win32.Build.0 = Release|Win32
{05041C63-F1C5-49BA-A7DE-61EBB5307EAA}.Release_ExtPCRE|x64.ActiveCfg = Release|x64
{05041C63-F1C5-49BA-A7DE-61EBB5307EAA}.Release_ExtPCRE|x64.Build.0 = Release|x64
{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}.Debug|Win32.ActiveCfg = Debug|Win32
{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}.Debug|Win32.Build.0 = Debug|Win32
{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}.Debug|x64.ActiveCfg = Debug|x64
{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}.Debug|x64.Build.0 = Debug|x64
{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}.Release|Win32.ActiveCfg = Release|Win32
{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}.Release|Win32.Build.0 = Release|Win32
{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}.Release|x64.ActiveCfg = Release|x64
{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}.Release|x64.Build.0 = Release|x64
{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}.Debug_ExtPCRE|Win32.ActiveCfg = Debug|Win32
{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}.Debug_ExtPCRE|Win32.Build.0 = Debug|Win32
{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}.Debug_ExtPCRE|x64.ActiveCfg = Debug|x64
{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}.Debug_ExtPCRE|x64.Build.0 = Debug|x64
{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}.Release_ExtPCRE|Win32.ActiveCfg = Release|Win32
{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}.Release_ExtPCRE|Win32.Build.0 = Release|Win32
{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}.Release_ExtPCRE|x64.ActiveCfg = Release|x64
{B0CDEC7F-DCE1-4F7E-B8A4-A3009C18FB2A}.Release_ExtPCRE|x64.Build.0 = Release|x64
{95A1571F-61BE-4C51-BE53-2F2DAB280685}.Debug|Win32.ActiveCfg = Debug|Win32
{95A1571F-61BE-4C51-BE53-2F2DAB280685}.Debug|Win32.Build.0 = Debug|Win32
{95A1571F-61BE-4C51-BE53-2F2DAB280685}.Debug|x64.ActiveCfg = Debug|x64
{95A1571F-61BE-4C51-BE53-2F2DAB280685}.Debug|x64.Build.0 = Debug|x64
{95A1571F-61BE-4C51-BE53-2F2DAB280685}.Release|Win32.ActiveCfg = Release|Win32
{95A1571F-61BE-4C51-BE53-2F2DAB280685}.Release|Win32.Build.0 = Release|Win32
{95A1571F-61BE-4C51-BE53-2F2DAB280685}.Release|x64.ActiveCfg = Release|x64
{95A1571F-61BE-4C51-BE53-2F2DAB280685}.Release|x64.Build.0 = Release|x64
{95A1571F-61BE-4C51-BE53-2F2DAB280685}.Debug_ExtPCRE|Win32.ActiveCfg = Debug|Win32
{95A1571F-61BE-4C51-BE53-2F2DAB280685}.Debug_ExtPCRE|Win32.Build.0 = Debug|Win32
{95A1571F-61BE-4C51-BE53-2F2DAB280685}.Debug_ExtPCRE|x64.ActiveCfg = Debug|x64
{95A1571F-61BE-4C51-BE53-2F2DAB280685}.Debug_ExtPCRE|x64.Build.0 = Debug|x64
{95A1571F-61BE-4C51-BE53-2F2DAB280685}.Release_ExtPCRE|Win32.ActiveCfg = Release|Win32
{95A1571F-61BE-4C51-BE53-2F2DAB280685}.Release_ExtPCRE|Win32.Build.0 = Release|Win32
{95A1571F-61BE-4C51-BE53-2F2DAB280685}.Release_ExtPCRE|x64.ActiveCfg = Release|x64
{95A1571F-61BE-4C51-BE53-2F2DAB280685}.Release_ExtPCRE|x64.Build.0 = Release|x64
{2093D218-190E-4194-9421-3BA7CBF33B10}.Debug|Win32.ActiveCfg = Debug|Win32
{2093D218-190E-4194-9421-3BA7CBF33B10}.Debug|Win32.Build.0 = Debug|Win32
{2093D218-190E-4194-9421-3BA7CBF33B10}.Debug|x64.ActiveCfg = Debug|x64

View File

@ -31,6 +31,10 @@ copy ..\..\..\glib\glibconfig.h.win32 ..\..\..\glib\glibconfig.h&#x0D;&#x0A;
if exist ..\..\..\gmodule\gmoduleconf.h goto DONE_GMODULECONF_H&#x0D;&#x0A;
copy ..\..\..\gmodule\gmoduleconf.h.win32 ..\..\..\gmodule\gmoduleconf.h&#x0D;&#x0A;
:DONE_GMODULECONF_H&#x0D;&#x0A;
if exist ..\..\..\gio\gconstructor_as_data.h goto DONE_GCONSTRUCTOR_AS_DATA_H&#x0D;&#x0A;
perl ..\..\..\gio\data-to-c.pl ..\..\..\glib\gconstructor.h gconstructor_code > ..\..\..\gio\gconstructor_as_data.h&#x0D;&#x0A;
:DONE_GCONSTRUCTOR_AS_DATA_H&#x0D;&#x0A;
"
/>
<UserMacro
@ -47,6 +51,8 @@ copy $(SolutionDir)$(ConfigurationName)\$(PlatformName)\bin\glib-genmarshal.exe
copy $(SolutionDir)$(ConfigurationName)\$(PlatformName)\bin\gspawn-win32-helper*.exe $(OutDir)\bin&#x0D;&#x0A;
copy $(SolutionDir)$(ConfigurationName)\$(PlatformName)\bin\glib-compile-schemas.exe $(OutDir)\bin&#x0D;&#x0A;
copy $(SolutionDir)$(ConfigurationName)\$(PlatformName)\bin\gsettings.exe $(OutDir)\bin&#x0D;&#x0A;
copy $(SolutionDir)$(ConfigurationName)\$(PlatformName)\bin\glib-compile-resources.exe $(OutDir)\bin&#x0D;&#x0A;
copy $(SolutionDir)$(ConfigurationName)\$(PlatformName)\bin\gresource.exe $(OutDir)\bin&#x0D;&#x0A;
mkdir $(OutDir)\include\glib-$(ApiVersion)\glib&#x0D;&#x0A;
copy ..\..\..\msvc_recommended_pragmas.h $(OutDir)\include\glib-$(ApiVersion)&#x0D;&#x0A;

View File

@ -0,0 +1,155 @@
<?xml version="1.0" encoding="big5"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="9.00"
Name="gresource"
ProjectGUID="{95A1571F-61BE-4C51-BE53-2F2DAB280685}"
RootNamespace="gresource"
Keyword="Win32Proj"
TargetFrameworkVersion="196613"
>
<Platforms>
<Platform
Name="Win32"
/>
<Platform
Name="x64"
/>
</Platforms>
<ToolFiles>
</ToolFiles>
<Configurations>
<Configuration
Name="Debug|Win32"
InheritedPropertySheets=".\glib.vsprops"
ConfigurationType="1"
CharacterSet="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="..\..\..\gmodule"
PreprocessorDefinitions="_DEBUG"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
UsePrecompiledHeader="0"
WarningLevel="3"
DebugInformationFormat="4"
/>
<Tool
Name="VCLinkerTool"
LinkIncremental="2"
GenerateDebugInformation="true"
SubSystem="1"
TargetMachine="1"
/>
</Configuration>
<Configuration
Name="Debug|x64"
InheritedPropertySheets=".\glib.vsprops"
ConfigurationType="1"
CharacterSet="2"
>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="..\..\..\gmodule"
PreprocessorDefinitions="_DEBUG"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
UsePrecompiledHeader="0"
WarningLevel="3"
DebugInformationFormat="3"
CompileAs="1"
/>
<Tool
Name="VCLinkerTool"
LinkIncremental="2"
GenerateDebugInformation="true"
SubSystem="1"
RandomizedBaseAddress="1"
DataExecutionPrevention="0"
TargetMachine="17"
/>
</Configuration>
<Configuration
Name="Release|Win32"
InheritedPropertySheets=".\glib.vsprops"
ConfigurationType="1"
CharacterSet="1"
WholeProgramOptimization="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="2"
EnableIntrinsicFunctions="true"
AdditionalIncludeDirectories="..\..\..\gmodule"
PreprocessorDefinitions=""
RuntimeLibrary="2"
EnableFunctionLevelLinking="true"
UsePrecompiledHeader="0"
WarningLevel="3"
DebugInformationFormat="3"
/>
<Tool
Name="VCLinkerTool"
LinkIncremental="1"
GenerateDebugInformation="true"
SubSystem="1"
OptimizeReferences="2"
EnableCOMDATFolding="2"
TargetMachine="1"
/>
</Configuration>
<Configuration
Name="Release|x64"
InheritedPropertySheets=".\glib.vsprops"
ConfigurationType="1"
CharacterSet="2"
WholeProgramOptimization="1"
>
<Tool
Name="VCCLCompilerTool"
AdditionalIncludeDirectories="..\..\..\gmodule"
PreprocessorDefinitions=""
RuntimeLibrary="2"
UsePrecompiledHeader="0"
WarningLevel="3"
DebugInformationFormat="3"
CompileAs="1"
/>
<Tool
Name="VCLinkerTool"
LinkIncremental="1"
GenerateDebugInformation="true"
SubSystem="1"
OptimizeReferences="2"
EnableCOMDATFolding="2"
RandomizedBaseAddress="1"
DataExecutionPrevention="0"
TargetMachine="17"
/>
</Configuration>
</Configurations>
<References>
</References>
<Files>
<Filter
Name="Source Files"
Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
>
<File RelativePath="..\..\..\gio\gresource-tool.c" />
</Filter>
</Files>
<Globals>
</Globals>
</VisualStudioProject>