blob: 47c855c31b7f9af2b2a67fe189420bb517d227e3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
|
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup Label="UserMacros">
<GlibEtcInstallRoot>$(SolutionDir)\..\..\..\..\vs10\$(Platform)</GlibEtcInstallRoot>
<VSVER>10</VSVER>
<BASE_GI_DIR>$(SolutionDir)\..\..\..</BASE_GI_DIR>
<CopyDir>$(GlibEtcInstallRoot)</CopyDir>
<GIApiVersion>1.0</GIApiVersion>
<DefDir>$(SolutionDir)$(Configuration)\$(Platform)\obj\$(ProjectName)</DefDir>
<GenerateGIRDef>
echo EXPORTS > $(DefDir)\girepository.def
cl -EP ..\..\..\girepository\girepository.symbols >> $(DefDir)\girepository.def
</GenerateGIRDef>
<GenEverythingH>
if exist ..\..\..\tests\everything.h goto DONE_GEN_EVERYTHING_C
cd ..\..\..\tests
set PATH=$(GlibEtcInstallRoot)\bin;$(SolutionDir)$(Configuration)\$(PlatformName)\bin;%PYTHONDIR%;%PATH%
set PYTHONPATH=$(SolutionDir)$(Configuration)\$(PlatformName)\bin;$(BASE_GI_DIR)
set UNINSTALLED_INTROSPECTION_SRCDIR=$(BASE_GI_DIR)
python ..\tools\g-ir-scanner --verbose -I. --add-include-path=..\ --add-include-path=..\gir --generate-typelib-tests=Everything,everything.h,everything.c
cd $(SolutionDir)
:DONE_GEN_EVERYTHING_C
</GenEverythingH>
<GenerateGIR>
@echo off
set CC=cl
if "$(MINGWDIR)" == "" goto ERR_NOGCC
if "$(PYTHONDIR)" == "" goto ERR_NOPYPATH
if "$(PKG_CONFIG_PATH)" == "" goto ERR_NOPKGCONFIG
set PYTHONPATH=$(SolutionDir)$(Configuration)\$(PlatformName)\bin\;$(BASE_GI_DIR)
set UNINSTALLED_INTROSPECTION_SRCDIR=$(BASE_GI_DIR)
set PATH=$(GlibEtcInstallRoot)\bin;$(SolutionDir)$(Configuration)\$(PlatformName)\bin\;$(PATH);$(PYTHONDIR);$(MINGWDIR)\bin
set LIB=$(GlibEtcInstallRoot)\lib;$(SolutionDir)$(Configuration)\$(PlatformName)\bin\;$(LIB);$(PYTHONDIR)\libs
set INCLUDE=$(GlibEtcInstallRoot)\include;$(GlibEtcInstallRoot)\lib\glib-2.0\include;$(INCLUDE);$(PYTHONDIR)\include
set PLAT=$(Platform)
set CONF=$(Configuration)
set BASEDIR=$(GlibEtcInstallRoot)
set VSVER=$(VSVER)
cd ..
call gengir.bat
cd .\vs$(VSVER)
goto DONE
:ERR_NOGCC
echo You need a Windows GCC installation to preprocess the headers to generate .gir files
echo Please set MINGWDIR accordingly before launching the Project
goto DONE
:ERR_NOPYPATH
echo You need a Python installation to build the Python module and run the Python scripts to generate .gir files
echo The Python installation needs to correspond to the configuration of your build, i.e. Win32 or x64
echo Please set PYTHONDIR accordingly before launching the Project
goto DONE
:ERR_NOPKGCONFIG
echo You need pkg-config and need to set PKG_CONFIG_PATH to point to pkgconfig (.pc) files to generate .gir files
echo Please set PKG_CONFIG_PATH accordingly before launching the Project
goto DONE
:DONE
</GenerateGIR>
<LibGILibtoolCompatibleDllPrefix>lib</LibGILibtoolCompatibleDllPrefix>
<LibGILibtoolCompatibleDllSuffix>-$(GIApiVersion)-0</LibGILibtoolCompatibleDllSuffix>
<LibGISeparateVS10DllPrefix />
<LibGISeparateVS10DllSuffix>-1-vs10</LibGISeparateVS10DllSuffix>
<LibGIDllPrefix>$(LibGISeparateVS10DllPrefix)</LibGIDllPrefix>
<LibGIDllSuffix>$(LibGISeparateVS10DllSuffix)</LibGIDllSuffix>
<GIDoInstall>
mkdir $(CopyDir)
mkdir $(CopyDir)\bin
copy $(SolutionDir)$(Configuration)\$(Platform)\bin\$(LibGIDllPrefix)girepository$(LibGIDllSuffix).dll $(CopyDir)\bin
copy $(SolutionDir)$(Configuration)\$(Platform)\bin\g-ir-compiler.exe $(CopyDir)\bin
copy $(SolutionDir)$(Configuration)\$(Platform)\bin\g-ir-generate.exe $(CopyDir)\bin
copy ..\..\..\tools\g-ir-annotation-tool $(CopyDir)\bin
copy ..\..\..\tools\g-ir-doc-tool $(CopyDir)\bin
copy ..\..\..\tools\g-ir-scanner $(CopyDir)\bin
#include "gir.vs10.install"
copy $(SolutionDir)$(Configuration)\$(Platform)\bin\_giscanner.pyd $(CopyDir)\lib\gobject-introspection\giscanner
mkdir $(CopyDir)\share\gir-$(GIApiVersion)
copy $(SolutionDir)$(Configuration)\$(Platform)\share\gir-$(GIApiVersion)\*.gir $(CopyDir)\share\gir-$(GIApiVersion)
mkdir $(CopyDir)\share\gobject-introspection-$(GIApiVersion)
copy ..\..\..\girepository\gdump.c $(CopyDir)\share\gobject-introspection-$(GIApiVersion)
mkdir $(CopyDir)\lib\girepository-$(GIApiVersion)
copy $(SolutionDir)$(Configuration)\$(Platform)\bin\girepository-$(GIApiVersion).lib $(CopyDir)\lib
copy $(SolutionDir)$(Configuration)\$(Platform)\lib\girepository-$(GIApiVersion)\*.typelib $(CopyDir)\lib\girepository-$(GIApiVersion)
</GIDoInstall>
</PropertyGroup>
<PropertyGroup>
<_PropertySheetDisplayName>giprops</_PropertySheetDisplayName>
<OutDir>$(SolutionDir)$(Configuration)\$(PlatformName)\bin\</OutDir>
<IntDir>$(SolutionDir)$(Configuration)\$(PlatformName)\obj\$(ProjectName)\</IntDir>
</PropertyGroup>
<ItemDefinitionGroup>
<ClCompile>
<AdditionalIncludeDirectories>..\..\..;..\..\..\girepository;$(GlibEtcInstallRoot)\include;$(GlibEtcInstallRoot)\include\glib-2.0;$(GlibEtcInstallRoot)\lib\glib-2.0\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>HAVE_CONFIG_H;WIN32;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ForcedIncludeFiles>msvc_recommended_pragmas.h;%(ForcedIncludeFiles)</ForcedIncludeFiles>
</ClCompile>
<Link>
<AdditionalDependencies>gio-2.0.lib;gobject-2.0.lib;gmodule-2.0.lib;gthread-2.0.lib;glib-2.0.lib;%(AdditionalDependencies)</AdditionalDependencies>
<AdditionalLibraryDirectories>$(GlibEtcInstallRoot)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
</Link>
<PreBuildEvent>
<Command>
if not exist ..\..\..\config.h copy ..\..\..\config.h.win32 ..\..\..\config.h
if not exist ..\..\..\tools\g-ir-scanner copy ..\..\..\tools\g-ir-scanner.in ..\..\..\tools\g-ir-scanner
if not exist ..\..\..\tools\g-ir-doc-tool copy ..\..\..\tools\g-ir-doc-tool.in ..\..\..\tools\g-ir-doc-tool
if not exist ..\..\..\tools\g-ir-annotation-tool copy ..\..\..\tools\g-ir-annotation-tool.in ..\..\..\tools\g-ir-annotation-tool
</Command>
</PreBuildEvent>
</ItemDefinitionGroup>
<ItemGroup>
<BuildMacro Include="GlibEtcInstallRoot">
<Value>$(GlibEtcInstallRoot)</Value>
</BuildMacro>
<BuildMacro Include="VSVER">
<Value>$(VSVER)</Value>
</BuildMacro>
<BuildMacro Include="BASE_GI_DIR">
<Value>$(BASE_GI_DIR)</Value>
</BuildMacro>
<BuildMacro Include="CopyDir">
<Value>$(CopyDir)</Value>
</BuildMacro>
<BuildMacro Include="GIApiVersion">
<Value>$(GIApiVersion)</Value>
</BuildMacro>
<BuildMacro Include="DefDir">
<Value>$(DefDir)</Value>
</BuildMacro>
<BuildMacro Include="GenerateGIRDef">
<Value>$(GenerateGIRDef)</Value>
</BuildMacro>
<BuildMacro Include="GenEverythingH">
<Value>$(GenEverythingH)</Value>
</BuildMacro>
<BuildMacro Include="GenerateGIR">
<Value>$(GenerateGIR)</Value>
</BuildMacro>
<BuildMacro Include="LibGILibtoolCompatibleDllPrefix">
<Value>$(LibGILibtoolCompatibleDllPrefix)</Value>
</BuildMacro>
<BuildMacro Include="LibGILibtoolCompatibleDllSuffix">
<Value>$(LibGILibtoolCompatibleDllSuffix)</Value>
</BuildMacro>
<BuildMacro Include="LibGISeparateVS10DllPrefix">
<Value>$(LibGISeparateVS10DllPrefix)</Value>
</BuildMacro>
<BuildMacro Include="LibGISeparateVS10DllSuffix">
<Value>$(LibGISeparateVS10DllSuffix)</Value>
</BuildMacro>
<BuildMacro Include="LibGIDllPrefix">
<Value>$(LibGIDllPrefix)</Value>
</BuildMacro>
<BuildMacro Include="LibGIDllSuffix">
<Value>$(LibGIDllSuffix)</Value>
</BuildMacro>
<BuildMacro Include="GIDoInstall">
<Value>$(GIDoInstall)</Value>
</BuildMacro>
</ItemGroup>
</Project>
|