summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorevoskuil <eric@voskuil.org>2014-03-26 22:08:54 (GMT)
committer evoskuil <eric@voskuil.org>2014-03-26 22:08:54 (GMT)
commit8cea3e9db436681a416d1bcfc447db1ae4665378 (patch)
treecbe16089b753400acc8befb57901bca638882a38
parent6bdc35f69919b4cef778d1c2355aa42fa3d73197 (diff)
Clean builds for VS2013, a few sections disabled.
-rw-r--r--builds/msvc/vs2013/obelisk/obelisk.props21
-rw-r--r--builds/msvc/vs2013/obelisk/obelisk.vcxproj48
-rw-r--r--builds/msvc/vs2013/properties/Common.props13
-rw-r--r--builds/msvc/vs2013/properties/Debug.props3
-rw-r--r--builds/msvc/vs2013/properties/LinkTimeCodeGeneration.props3
-rw-r--r--builds/msvc/vs2013/properties/Release.props3
-rw-r--r--builds/msvc/vs2013/properties/StaticDebugLinkTimeCodeGeneration.props13
-rw-r--r--builds/msvc/vs2013/properties/StaticReleaseLinkTimeCodeGeneration.props9
-rw-r--r--src/client/backend.cpp4
-rw-r--r--src/worker/publisher.cpp6
-rw-r--r--src/worker/service/blockchain.cpp5
-rw-r--r--src/worker/service/fullnode.cpp5
-rw-r--r--src/worker/service/protocol.cpp5
13 files changed, 101 insertions, 37 deletions
diff --git a/builds/msvc/vs2013/obelisk/obelisk.props b/builds/msvc/vs2013/obelisk/obelisk.props
index 61aa89b..f5e64dc 100644
--- a/builds/msvc/vs2013/obelisk/obelisk.props
+++ b/builds/msvc/vs2013/obelisk/obelisk.props
@@ -7,9 +7,7 @@
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
<RunCodeAnalysis>false</RunCodeAnalysis>
</PropertyGroup>
-
- <!-- TODO: incorporate _MSC_VER in places where there is a MSVC (vs. Windows/_WIN32) dependency. -->
- <!-- If the version number of the Visual C++ compiler is 17.00.51106.1, the _MSC_VER macro evaluates to 1700. -->
+
<ItemDefinitionGroup>
<ClCompile>
<AdditionalIncludeDirectories>$(ProjectDir)..\..\..\..\include\;%(AdditionalIncludeDirectories);$(ProjectDir)..\..\..\..\..\libbitcoin\include\;$(ProjectDir)..\..\..\..\..\czmqpp\include\;$(ProjectDir)..\..\..\..\..\czmq\include\;$(ProjectDir)..\..\..\..\..\libzmq\include\;(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
@@ -24,7 +22,7 @@
<ItemDefinitionGroup Condition="'$(ConfigurationType)'=='StaticLibrary'">
<ClCompile>
- <PreprocessorDefinitions>LIBCONFIG_STATIC;LIBCONFIGXX_STATIC;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <PreprocessorDefinitions>LIBCONFIG_STATIC;LIBCONFIGXX_STATIC;ZMQ_STATIC;LIBCZMQ_STATIC;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ClCompile>
</ItemDefinitionGroup>
@@ -32,17 +30,12 @@
<ClCompile>
<PreprocessorDefinitions>BITCOIN_DISABLE_ASSERTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ClCompile>
- <Link>
- <AdditionalLibraryDirectories>$(ProjectDir)..\..\..\..\..\libbitcoin\bin\$(PlatformName)\Release\</AdditionalLibraryDirectories>
- <AdditionalDependencies>czmqpp.lib;czmq.lib;libzmq.lib;%(AdditionalDependencies)</AdditionalDependencies>
- </Link>
</ItemDefinitionGroup>
- <ItemDefinitionGroup Condition="$(Configuration.IndexOf('Debug')) != -1">
- <Link>
- <AdditionalLibraryDirectories>$(ProjectDir)..\..\..\..\..\libbitcoin\bin\$(PlatformName)\Debug\</AdditionalLibraryDirectories>
- <AdditionalDependencies>czmqpp_d.lib;czmq_d.lib;libzmq_d.lib;%(AdditionalDependencies)</AdditionalDependencies>
- </Link>
- </ItemDefinitionGroup>
+ <Target Name="LinkageInfo" BeforeTargets="PrepareForBuild">
+ <Message Text="Linkage-libconfig : $(Linkage-libconfig)" Importance="high"/>
+ <Message Text="Linkage-zlib : $(Linkage-zlib)" Importance="high"/>
+ <Message Text="Linkage-openssl : $(Linkage-openssl)" Importance="high"/>
+ </Target>
</Project> \ No newline at end of file
diff --git a/builds/msvc/vs2013/obelisk/obelisk.vcxproj b/builds/msvc/vs2013/obelisk/obelisk.vcxproj
index b455751..b9617a1 100644
--- a/builds/msvc/vs2013/obelisk/obelisk.vcxproj
+++ b/builds/msvc/vs2013/obelisk/obelisk.vcxproj
@@ -168,14 +168,46 @@
<Import Project="$(ProjectDir)..\properties\StaticRelease.props" />
<Import Project="$(ProjectDir)..\properties\x64.props" />
</ImportGroup>
- <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|Win32'">
- <ClCompile />
- </ItemDefinitionGroup>
- <!--<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|Win32'">
- <ClCompile>
- <AdditionalIncludeDirectories>C:\Source\nuget\LevelDB.1.16.0.5\lib\native\include\;C:\Source\nuget\Snappy.1.1.1.7\lib\native\include\;C:\Source\nuget\Crc32C.1.0.4\lib\native\include\;$(ProjectDir)..\..\..\..\include\;$(ProjectDir)..\..\..\..\include\obelisk\;$(ProjectDir)..\..\..\..\include\obelisk\client\;$(ProjectDir)..\..\..\..\..\libbitcoin\include\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
- </ClCompile>
- </ItemDefinitionGroup>-->
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugLTCG|Win32'">
+ <Linkage-libconfig>ltcg</Linkage-libconfig>
+ <Linkage-zlib>ltcg</Linkage-zlib>
+ <Linkage-openssl>ltcg</Linkage-openssl>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseLTCG|Win32'">
+ <Linkage-libconfig>ltcg</Linkage-libconfig>
+ <Linkage-zlib>ltcg</Linkage-zlib>
+ <Linkage-openssl>ltcg</Linkage-openssl>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugLTCG|x64'">
+ <Linkage-libconfig>ltcg</Linkage-libconfig>
+ <Linkage-zlib>ltcg</Linkage-zlib>
+ <Linkage-openssl>ltcg</Linkage-openssl>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseLTCG|x64'">
+ <Linkage-libconfig>ltcg</Linkage-libconfig>
+ <Linkage-zlib>ltcg</Linkage-zlib>
+ <Linkage-openssl>ltcg</Linkage-openssl>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugLIB|Win32'">
+ <Linkage-libconfig>static</Linkage-libconfig>
+ <Linkage-zlib>static</Linkage-zlib>
+ <Linkage-openssl>static</Linkage-openssl>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseLIB|Win32'">
+ <Linkage-libconfig>static</Linkage-libconfig>
+ <Linkage-zlib>static</Linkage-zlib>
+ <Linkage-openssl>static</Linkage-openssl>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugLIB|x64'">
+ <Linkage-libconfig>static</Linkage-libconfig>
+ <Linkage-zlib>static</Linkage-zlib>
+ <Linkage-openssl>static</Linkage-openssl>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseLIB|x64'">
+ <Linkage-libconfig>static</Linkage-libconfig>
+ <Linkage-zlib>static</Linkage-zlib>
+ <Linkage-openssl>static</Linkage-openssl>
+ </PropertyGroup>
<ItemGroup>
<None Include="packages.config" />
</ItemGroup>
diff --git a/builds/msvc/vs2013/properties/Common.props b/builds/msvc/vs2013/properties/Common.props
index 8fd7505..10e0380 100644
--- a/builds/msvc/vs2013/properties/Common.props
+++ b/builds/msvc/vs2013/properties/Common.props
@@ -10,15 +10,18 @@
<ItemDefinitionGroup>
<ClCompile>
- <DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<!-- Windows and CRT definitions for unicode. Note that Linux only supports unicode so char is UCS-16. -->
<PreprocessorDefinitions>UNICODE;_UNICODE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<WarningLevel>Level3</WarningLevel>
</ClCompile>
- <Link>
- <GenerateDebugInformation>true</GenerateDebugInformation>
- </Link>
</ItemDefinitionGroup>
-
+
+ <Target Name="ConfigInfo" BeforeTargets="PrepareForBuild">
+ <Message Text="ConfigurationType : $(ConfigurationType)" Importance="high"/>
+ <Message Text="Configuration : $(Configuration)" Importance="high"/>
+ <Message Text="PlatformToolset : $(PlatformToolset)" Importance="high"/>
+ <Message Text="Building..." Importance="high"/>
+ </Target>
+
</Project> \ No newline at end of file
diff --git a/builds/msvc/vs2013/properties/Debug.props b/builds/msvc/vs2013/properties/Debug.props
index 7cc49fa..825321a 100644
--- a/builds/msvc/vs2013/properties/Debug.props
+++ b/builds/msvc/vs2013/properties/Debug.props
@@ -11,7 +11,7 @@
</PropertyGroup>
<ItemDefinitionGroup>
- <ClCompile>
+ <ClCompile><DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<FunctionLevelLinking>true</FunctionLevelLinking>
@@ -22,6 +22,7 @@
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ResourceCompile>
<Link>
+ <GenerateDebugInformation>true</GenerateDebugInformation>
<ImportLibrary>$(ProjectDir)..\..\..\..\bin\$(PlatformName)\Debug\$(RootNamespace)\$(TargetName).imp.lib</ImportLibrary>
</Link>
</ItemDefinitionGroup>
diff --git a/builds/msvc/vs2013/properties/LinkTimeCodeGeneration.props b/builds/msvc/vs2013/properties/LinkTimeCodeGeneration.props
index 338a970..42708b5 100644
--- a/builds/msvc/vs2013/properties/LinkTimeCodeGeneration.props
+++ b/builds/msvc/vs2013/properties/LinkTimeCodeGeneration.props
@@ -9,6 +9,9 @@
<ItemDefinitionGroup>
<ClCompile>
<WholeProgramOptimization>true</WholeProgramOptimization>
+
+ <!-- This overrides Debug.props->LinkIncremental and therefore this reference must always be set after Debug.props is included. -->
+ <LinkIncremental>false</LinkIncremental>
</ClCompile>
<Link>
<LinkTimeCodeGeneration>UseLinkTimeCodeGeneration</LinkTimeCodeGeneration>
diff --git a/builds/msvc/vs2013/properties/Release.props b/builds/msvc/vs2013/properties/Release.props
index 56767a3..aff972f 100644
--- a/builds/msvc/vs2013/properties/Release.props
+++ b/builds/msvc/vs2013/properties/Release.props
@@ -13,7 +13,7 @@
<ItemDefinitionGroup>
<ClCompile>
<AdditionalOptions>/Oy- %(AdditionalOptions)</AdditionalOptions>
- <DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
+ <!--<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>-->
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
@@ -26,6 +26,7 @@
</ResourceCompile>
<Link>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
+ <!--<GenerateDebugInformation>true</GenerateDebugInformation>-->
<ImportLibrary>$(ProjectDir)..\..\..\..\bin\$(PlatformName)\Release\$(RootNamespace)\$(TargetName).imp.lib</ImportLibrary>
<OptimizeReferences>true</OptimizeReferences>
</Link>
diff --git a/builds/msvc/vs2013/properties/StaticDebugLinkTimeCodeGeneration.props b/builds/msvc/vs2013/properties/StaticDebugLinkTimeCodeGeneration.props
index a57b7de..18b017c 100644
--- a/builds/msvc/vs2013/properties/StaticDebugLinkTimeCodeGeneration.props
+++ b/builds/msvc/vs2013/properties/StaticDebugLinkTimeCodeGeneration.props
@@ -2,17 +2,20 @@
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ImportGroup Label="PropertySheets">
- <Import Project="StaticLinkTimeCodeGeneration.props" />
<Import Project="Debug.props" />
+ <Import Project="StaticLinkTimeCodeGeneration.props" />
</ImportGroup>
<PropertyGroup>
<_ProjectFileVersion>10.0.40219.1</_ProjectFileVersion>
<_PropertySheetDisplayName>Static Debug Link Time Code Generation Library</_PropertySheetDisplayName>
-
- <!-- This overrides Debug.props->LinkIncremental and therefore
- this reference must always be set after Debug.props is included. -->
- <LinkIncremental>false</LinkIncremental>
</PropertyGroup>
+ <ItemDefinitionGroup>
+ <ClCompile>
+ <!-- Linking CRT statically when building a static library is conventional. -->
+ <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
+ </ClCompile>
+ </ItemDefinitionGroup>
+
</Project> \ No newline at end of file
diff --git a/builds/msvc/vs2013/properties/StaticReleaseLinkTimeCodeGeneration.props b/builds/msvc/vs2013/properties/StaticReleaseLinkTimeCodeGeneration.props
index efb1192..668a9e9 100644
--- a/builds/msvc/vs2013/properties/StaticReleaseLinkTimeCodeGeneration.props
+++ b/builds/msvc/vs2013/properties/StaticReleaseLinkTimeCodeGeneration.props
@@ -2,8 +2,8 @@
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ImportGroup Label="PropertySheets">
- <Import Project="StaticLinkTimeCodeGeneration.props" />
<Import Project="Release.props" />
+ <Import Project="StaticLinkTimeCodeGeneration.props" />
</ImportGroup>
<PropertyGroup>
@@ -11,4 +11,11 @@
<_PropertySheetDisplayName>Static Release Link Time Code Generation Library</_PropertySheetDisplayName>
</PropertyGroup>
+ <ItemDefinitionGroup>
+ <ClCompile>
+ <!-- Linking CRT statically when building a static library is conventional. -->
+ <RuntimeLibrary>MultiThreaded</RuntimeLibrary>
+ </ClCompile>
+ </ItemDefinitionGroup>
+
</Project> \ No newline at end of file
diff --git a/src/client/backend.cpp b/src/client/backend.cpp
index 8292c10..0662feb 100644
--- a/src/client/backend.cpp
+++ b/src/client/backend.cpp
@@ -59,11 +59,11 @@ void backend_cluster::send(const outgoing_message& message)
void backend_cluster::update()
{
- // Poll socket for a reply, with timeout
+ // Poll socket for a reply, with timeout
czmqpp::poller poller(socket_);
BITCOIN_ASSERT(poller.self());
czmqpp::socket which = poller.wait(0);
- // If we got a reply, process it
+ // If we got a reply, process it
receive_incoming();
// Finally resend any expired requests that we didn't get
// a response to yet.
diff --git a/src/worker/publisher.cpp b/src/worker/publisher.cpp
index 8ad454d..597f5ce 100644
--- a/src/worker/publisher.cpp
+++ b/src/worker/publisher.cpp
@@ -27,8 +27,14 @@ bool publisher::setup_socket(
bool publisher::start(config_type& config)
{
+#ifdef _MSC_VER
+#pragma message( "WARNING: line temporarily disabled, work in progress." )
+#pragma message( "WARNING: line temporarily disabled, work in progress." )
+#else
+ // THESE LINES FAIL COMPILATION ON CTP_Nov2013
node_.subscribe_blocks(std::bind(&publisher::send_blk, this, _1, _2));
node_.subscribe_transactions(std::bind(&publisher::send_tx, this, _1));
+#endif
log_debug(LOG_PUBLISHER) << "Publishing blocks: "
<< config.block_publish;
if (!setup_socket(config.block_publish, socket_block_))
diff --git a/src/worker/service/blockchain.cpp b/src/worker/service/blockchain.cpp
index 597d97c..15ed77f 100644
--- a/src/worker/service/blockchain.cpp
+++ b/src/worker/service/blockchain.cpp
@@ -25,9 +25,14 @@ void blockchain_fetch_history(node_impl& node,
return;
log_debug(LOG_REQUEST) << "blockchain.fetch_history("
<< payaddr.encoded() << ", from_height=" << from_height << ")";
+#ifdef _MSC_VER
+#pragma message( "WARNING: line temporarily disabled, work in progress." )
+#else
+ // THIS LINE FAILS COMPILATION ON CTP_Nov2013
node.blockchain().fetch_history(payaddr,
std::bind(send_history_result,
_1, _2, request, queue_send), from_height);
+#endif
}
void blockchain_fetch_transaction(node_impl& node,
diff --git a/src/worker/service/fullnode.cpp b/src/worker/service/fullnode.cpp
index 95d2f45..556ebeb 100644
--- a/src/worker/service/fullnode.cpp
+++ b/src/worker/service/fullnode.cpp
@@ -20,10 +20,15 @@ void fullnode_fetch_history(node_impl& node,
// TODO: Slows down queries!
//log_debug(LOG_WORKER) << "fetch_history("
// << payaddr.encoded() << ", from_height=" << from_height << ")";
+#ifdef _MSC_VER
+#pragma message( "WARNING: line temporarily disabled, work in progress." )
+#else
+ // THIS LINE FAILS COMPILATION ON CTP_Nov2013
fetch_history(node.blockchain(), node.transaction_indexer(),
payaddr,
std::bind(send_history_result, _1, _2, request, queue_send),
from_height);
+#endif
}
} // namespace obelisk
diff --git a/src/worker/service/protocol.cpp b/src/worker/service/protocol.cpp
index 62ebf93..7398c3a 100644
--- a/src/worker/service/protocol.cpp
+++ b/src/worker/service/protocol.cpp
@@ -29,8 +29,13 @@ void protocol_broadcast_transaction(node_impl& node,
return;
}
auto ignore_send = [](const std::error_code&, size_t) {};
+#ifdef _MSC_VER
+#pragma message( "WARNING: line temporarily disabled, work in progress." )
+#else
+ // THIS LINE CONSISTENTLY CAUSES A FAILURE IN CTP_Nov2013 COMPILER (CL.EXE)
// Send and hope for the best!
node.protocol().broadcast(tx, ignore_send);
+#endif
// Response back to user saying everything is fine.
write_error_code(serial, std::error_code());
log_debug(LOG_WORKER)