Fix GIO/GObject Visual C++ projects
authorChun-wei Fan <fanchunwei@src.gnome.org>
Wed, 2 May 2012 03:10:23 +0000 (11:10 +0800)
committerChun-wei Fan <fanchunwei@src.gnome.org>
Wed, 2 May 2012 03:10:23 +0000 (11:10 +0800)
-Make up for the missed DLL_EXPORT-it's actually needed for all GLib DLL
 builds, omitting this caused problems to surface due to recent works to
 make GDBus work on Windows.
-Also use the FFI_BULIDING macro for GObject builds as the suggessted
 workaround for using static LibFFI builds (as we do now)-please see
 ffi.h(.in). This will fix the build of GObject against LibFFI 3.0.11,
 but it is probable that this will change at some point for LibFFI.

build/win32/vs10/gio.vcxprojin
build/win32/vs10/gobject.vcxprojin
build/win32/vs9/gio.vcprojin
build/win32/vs9/gobject.vcprojin

index 9b83fe68c34fabd8418a1f174a391b67f69ae260..362d82080976b0534d664c18dfa6eb91e43f1abb 100644 (file)
@@ -71,7 +71,7 @@
     <ClCompile>
       <Optimization>Disabled</Optimization>
       <AdditionalIncludeDirectories>../../../gio;../../../gmodule;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
-      <PreprocessorDefinitions>_DEBUG;G_LOG_DOMAIN="GLib-GIO";GIO_COMPILATION;GIO_MODULE_DIR="gio/modules";%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <PreprocessorDefinitions>_DEBUG;G_LOG_DOMAIN="GLib-GIO";GIO_COMPILATION;DLL_EXPORT;GIO_MODULE_DIR="gio/modules";%(PreprocessorDefinitions)</PreprocessorDefinitions>
       <MinimalRebuild>true</MinimalRebuild>
       <BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
       <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
@@ -97,7 +97,7 @@
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <AdditionalIncludeDirectories>../../../gio;../../../gmodule;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
-      <PreprocessorDefinitions>G_LOG_DOMAIN="GLib-GIO";GIO_COMPILATION;GIO_MODULE_DIR="gio/modules";%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <PreprocessorDefinitions>G_LOG_DOMAIN="GLib-GIO";GIO_COMPILATION;DLL_EXPORT;GIO_MODULE_DIR="gio/modules";%(PreprocessorDefinitions)</PreprocessorDefinitions>
       <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
       <PrecompiledHeader>
       </PrecompiledHeader>
     <ClCompile>
       <Optimization>Disabled</Optimization>
       <AdditionalIncludeDirectories>../../../gio;../../../gmodule;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
-      <PreprocessorDefinitions>_DEBUG;G_LOG_DOMAIN="GLib-GIO";GIO_COMPILATION;GIO_MODULE_DIR="gio/modules";%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <PreprocessorDefinitions>_DEBUG;G_LOG_DOMAIN="GLib-GIO";GIO_COMPILATION;DLL_EXPORT;GIO_MODULE_DIR="gio/modules";%(PreprocessorDefinitions)</PreprocessorDefinitions>
       <MinimalRebuild>true</MinimalRebuild>
       <BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
       <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
     <ClCompile>
       <AdditionalIncludeDirectories>../../../gio;../../../gmodule;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
-      <PreprocessorDefinitions>G_LOG_DOMAIN="GLib-GIO";GIO_COMPILATION;GIO_MODULE_DIR="gio/modules";%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <PreprocessorDefinitions>G_LOG_DOMAIN="GLib-GIO";GIO_COMPILATION;DLL_EXPORT;GIO_MODULE_DIR="gio/modules";%(PreprocessorDefinitions)</PreprocessorDefinitions>
       <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
       <PrecompiledHeader>
       </PrecompiledHeader>
index b0ec950e443f9ffde5b12dca035c7d417aa1f5d0..e39b192df925cad7aff3fac322d546af6b04da4c 100644 (file)
@@ -71,7 +71,7 @@
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
     <ClCompile>
       <Optimization>Disabled</Optimization>
-      <PreprocessorDefinitions>_DEBUG;GOBJECT_COMPILATION;G_LOG_DOMAIN="Glib-GObject";%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <PreprocessorDefinitions>_DEBUG;GOBJECT_COMPILATION;DLL_EXPORT;G_LOG_DOMAIN="Glib-GObject";FFI_BUILDING;%(PreprocessorDefinitions)</PreprocessorDefinitions>
       <MinimalRebuild>true</MinimalRebuild>
       <BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
       <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
@@ -96,7 +96,7 @@
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WholeProgramOptimization>false</WholeProgramOptimization>
-      <PreprocessorDefinitions>GOBJECT_COMPILATION;G_LOG_DOMAIN="Glib-GObject";%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <PreprocessorDefinitions>GOBJECT_COMPILATION;DLL_EXPORT;G_LOG_DOMAIN="Glib-GObject";FFI_BUILDING;%(PreprocessorDefinitions)</PreprocessorDefinitions>
       <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
       <PrecompiledHeader>
       </PrecompiledHeader>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
     <ClCompile>
       <Optimization>Disabled</Optimization>
-      <PreprocessorDefinitions>_DEBUG;GOBJECT_COMPILATION;G_LOG_DOMAIN="Glib-GObject";%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <PreprocessorDefinitions>_DEBUG;GOBJECT_COMPILATION;DLL_EXPORT;G_LOG_DOMAIN="Glib-GObject";FFI_BUILDING;%(PreprocessorDefinitions)</PreprocessorDefinitions>
       <MinimalRebuild>true</MinimalRebuild>
       <BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
       <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
     <ClCompile>
       <WholeProgramOptimization>false</WholeProgramOptimization>
-      <PreprocessorDefinitions>GOBJECT_COMPILATION;G_LOG_DOMAIN="Glib-GObject";%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <PreprocessorDefinitions>GOBJECT_COMPILATION;DLL_EXPORT;G_LOG_DOMAIN="Glib-GObject";FFI_BUILDING;%(PreprocessorDefinitions)</PreprocessorDefinitions>
       <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
       <PrecompiledHeader>
       </PrecompiledHeader>
index 41352e06829e82efd6833498cf0180b1546b6500..8d73dcdef755a05c7db95c1d18b0cecc36efd1ab 100644 (file)
@@ -28,7 +28,7 @@
                                Name="VCCLCompilerTool"\r
                                Optimization="0"\r
                                AdditionalIncludeDirectories="../../../gio,../../../gmodule"\r
-                               PreprocessorDefinitions="_DEBUG;G_LOG_DOMAIN=\&quot;GLib-GIO\&quot;;GIO_COMPILATION;GIO_MODULE_DIR=\&quot;gio/modules\&quot;"\r
+                               PreprocessorDefinitions="_DEBUG;G_LOG_DOMAIN=\&quot;GLib-GIO\&quot;;GIO_COMPILATION;DLL_EXPORT;GIO_MODULE_DIR=\&quot;gio/modules\&quot;"\r
                                MinimalRebuild="true"\r
                                BasicRuntimeChecks="3"\r
                                RuntimeLibrary="3"\r
@@ -61,7 +61,7 @@
                        <Tool\r
                                Name="VCCLCompilerTool"\r
                                AdditionalIncludeDirectories="../../../gio,../../../gmodule"\r
-                               PreprocessorDefinitions="G_LOG_DOMAIN=\&quot;GLib-GIO\&quot;;GIO_COMPILATION;GIO_MODULE_DIR=\&quot;gio/modules\&quot;"\r
+                               PreprocessorDefinitions="G_LOG_DOMAIN=\&quot;GLib-GIO\&quot;;GIO_COMPILATION;DLL_EXPORT;GIO_MODULE_DIR=\&quot;gio/modules\&quot;"\r
                                RuntimeLibrary="2"\r
                                UsePrecompiledHeader="0"\r
                                WarningLevel="3"\r
@@ -94,7 +94,7 @@
                                Name="VCCLCompilerTool"\r
                                Optimization="0"\r
                                AdditionalIncludeDirectories="../../../gio,../../../gmodule"\r
-                               PreprocessorDefinitions="_DEBUG;G_LOG_DOMAIN=\&quot;GLib-GIO\&quot;;GIO_COMPILATION;GIO_MODULE_DIR=\&quot;gio/modules\&quot;"\r
+                               PreprocessorDefinitions="_DEBUG;G_LOG_DOMAIN=\&quot;GLib-GIO\&quot;;GIO_COMPILATION;DLL_EXPORT;GIO_MODULE_DIR=\&quot;gio/modules\&quot;"\r
                                MinimalRebuild="true"\r
                                BasicRuntimeChecks="3"\r
                                RuntimeLibrary="3"\r
                        <Tool\r
                                Name="VCCLCompilerTool"\r
                                AdditionalIncludeDirectories="../../../gio,../../../gmodule"\r
-                               PreprocessorDefinitions="G_LOG_DOMAIN=\&quot;GLib-GIO\&quot;;GIO_COMPILATION;GIO_MODULE_DIR=\&quot;gio/modules\&quot;"\r
+                               PreprocessorDefinitions="G_LOG_DOMAIN=\&quot;GLib-GIO\&quot;;GIO_COMPILATION;DLL_EXPORT;GIO_MODULE_DIR=\&quot;gio/modules\&quot;"\r
                                RuntimeLibrary="2"\r
                                UsePrecompiledHeader="0"\r
                                WarningLevel="3"\r
index 909c4510fbfdf45e980489b492486427273d78a0..c9baac31b444558b3c4d09c924d1d0e0f7fe054e 100644 (file)
@@ -28,7 +28,7 @@
                        <Tool
                                Name="VCCLCompilerTool"
                                Optimization="0"
-                               PreprocessorDefinitions="_DEBUG;GOBJECT_COMPILATION;G_LOG_DOMAIN=\&quot;Glib-GObject\&quot;"
+                               PreprocessorDefinitions="_DEBUG;GOBJECT_COMPILATION;DLL_EXPORT;G_LOG_DOMAIN=\&quot;Glib-GObject\&quot;;FFI_BUILDING"
                                MinimalRebuild="true"
                                BasicRuntimeChecks="3"
                                RuntimeLibrary="3"
@@ -60,7 +60,7 @@
                        <Tool
                                Name="VCCLCompilerTool"
                                WholeProgramOptimization="false"
-                               PreprocessorDefinitions="GOBJECT_COMPILATION;G_LOG_DOMAIN=\&quot;Glib-GObject\&quot;"
+                               PreprocessorDefinitions="GOBJECT_COMPILATION;DLL_EXPORT;G_LOG_DOMAIN=\&quot;Glib-GObject\&quot;;FFI_BUILDING"
                                RuntimeLibrary="2"
                                UsePrecompiledHeader="0"
                                WarningLevel="3"
@@ -92,7 +92,7 @@
                        <Tool
                                Name="VCCLCompilerTool"
                                Optimization="0"
-                               PreprocessorDefinitions="_DEBUG;GOBJECT_COMPILATION;G_LOG_DOMAIN=\&quot;Glib-GObject\&quot;"
+                               PreprocessorDefinitions="_DEBUG;GOBJECT_COMPILATION;DLL_EXPORT;G_LOG_DOMAIN=\&quot;Glib-GObject\&quot;;FFI_BUILDING"
                                MinimalRebuild="true"
                                BasicRuntimeChecks="3"
                                RuntimeLibrary="3"
                        <Tool
                                Name="VCCLCompilerTool"
                                WholeProgramOptimization="false"
-                               PreprocessorDefinitions="GOBJECT_COMPILATION;G_LOG_DOMAIN=\&quot;Glib-GObject\&quot;"
+                               PreprocessorDefinitions="GOBJECT_COMPILATION;DLL_EXPORT;G_LOG_DOMAIN=\&quot;Glib-GObject\&quot;;FFI_BUILDING"
                                RuntimeLibrary="2"
                                UsePrecompiledHeader="0"
                                WarningLevel="3"