Skip to content

Commit 6bd8412

Browse files
committed
Merge branch 'jvandertil-mono-fixes'
2 parents 08427c7 + 3291179 commit 6bd8412

File tree

11 files changed

+48
-215
lines changed

11 files changed

+48
-215
lines changed

.nuget/NuGet.Config

Lines changed: 0 additions & 6 deletions
This file was deleted.

.nuget/NuGet.exe

8 KB
Binary file not shown.

.nuget/NuGet.targets

Lines changed: 0 additions & 151 deletions
This file was deleted.

FdbShell/FdbShell.csproj

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,6 @@
1111
<AssemblyName>FdbShell</AssemblyName>
1212
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
1313
<FileAlignment>512</FileAlignment>
14-
<SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">..\</SolutionDir>
15-
<RestorePackages>true</RestorePackages>
16-
<NuGetPackageImportStamp>655e8fa6</NuGetPackageImportStamp>
1714
</PropertyGroup>
1815
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
1916
<PlatformTarget>AnyCPU</PlatformTarget>
@@ -69,29 +66,21 @@
6966
</ItemGroup>
7067
<ItemGroup />
7168
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
72-
<Import Project="$(SolutionDir)\.nuget\NuGet.targets" Condition="Exists('$(SolutionDir)\.nuget\NuGet.targets')" />
73-
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
74-
<PropertyGroup>
75-
<ErrorText>This project references NuGet package(s) that are missing on this computer. Enable NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
76-
</PropertyGroup>
77-
<Error Condition="!Exists('$(SolutionDir)\.nuget\NuGet.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\.nuget\NuGet.targets'))" />
78-
<Error Condition="!Exists('..\packages\ILRepack.MSBuild.Task.1.0.9\build\ILRepack.MSBuild.Task.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\ILRepack.MSBuild.Task.1.0.9\build\ILRepack.MSBuild.Task.targets'))" />
79-
</Target>
80-
<Import Project="..\packages\ILRepack.MSBuild.Task.1.0.9\build\ILRepack.MSBuild.Task.targets" Condition="Exists('..\packages\ILRepack.MSBuild.Task.1.0.9\build\ILRepack.MSBuild.Task.targets')" />
69+
<Import Project="..\packages\ILRepack.MSBuild.Task.1.0.9\build\ILRepack.MSBuild.Task.targets" Condition="Exists('..\packages\ILRepack.MSBuild.Task.1.0.9\build\ILRepack.MSBuild.Task.targets') AND '$(OS)' == 'Windows_NT'" />
8170
<!-- ILRepack -->
82-
<Target Name="AfterBuild" Condition="'$(Configuration)' == 'Release'">
71+
<Target Name="AfterBuild" Condition="('$(Configuration)' == 'Release') AND '$(OS)' == 'Windows_NT' ">
8372
<ItemGroup>
8473
<InputAssemblies Include="$(OutputPath)\$(AssemblyName).exe" />
8574
<InputAssemblies Include="$(OutputPath)\FoundationDB.Client.dll" />
8675
</ItemGroup>
8776
<ILRepack Parallel="true" Internalize="true" InternalizeExclude="@(DoNotInternalizeAssemblies)" InputAssemblies="@(InputAssemblies)" TargetKind="Exe" OutputFile="$(OutputPath)\$(AssemblyName).Merged.exe" />
8877
</Target>
8978
<!-- /ILRepack -->
90-
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
79+
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
9180
Other similar extension points exist, see Microsoft.Common.targets.
9281
<Target Name="BeforeBuild">
9382
</Target>
9483
<Target Name="AfterBuild">
9584
</Target>
9685
-->
97-
</Project>
86+
</Project>

FdbTop/FdbTop.csproj

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,6 @@
1212
<TargetFrameworkVersion>v4.5.1</TargetFrameworkVersion>
1313
<FileAlignment>512</FileAlignment>
1414
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
15-
<SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">..\</SolutionDir>
16-
<RestorePackages>true</RestorePackages>
17-
<NuGetPackageImportStamp>e771f9ab</NuGetPackageImportStamp>
1815
</PropertyGroup>
1916
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
2017
<PlatformTarget>AnyCPU</PlatformTarget>
@@ -62,17 +59,9 @@
6259
</ProjectReference>
6360
</ItemGroup>
6461
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
65-
<Import Project="$(SolutionDir)\.nuget\NuGet.targets" Condition="Exists('$(SolutionDir)\.nuget\NuGet.targets')" />
66-
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
67-
<PropertyGroup>
68-
<ErrorText>This project references NuGet package(s) that are missing on this computer. Enable NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
69-
</PropertyGroup>
70-
<Error Condition="!Exists('$(SolutionDir)\.nuget\NuGet.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\.nuget\NuGet.targets'))" />
71-
<Error Condition="!Exists('..\packages\ILRepack.MSBuild.Task.1.0.9\build\ILRepack.MSBuild.Task.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\ILRepack.MSBuild.Task.1.0.9\build\ILRepack.MSBuild.Task.targets'))" />
72-
</Target>
73-
<Import Project="..\packages\ILRepack.MSBuild.Task.1.0.9\build\ILRepack.MSBuild.Task.targets" Condition="Exists('..\packages\ILRepack.MSBuild.Task.1.0.9\build\ILRepack.MSBuild.Task.targets')" />
62+
<Import Project="..\packages\ILRepack.MSBuild.Task.1.0.9\build\ILRepack.MSBuild.Task.targets" Condition="Exists('..\packages\ILRepack.MSBuild.Task.1.0.9\build\ILRepack.MSBuild.Task.targets') AND '$(OS)' == 'Windows_NT'" />
7463
<!-- ILRepack -->
75-
<Target Name="AfterBuild" Condition="'$(Configuration)' == 'Release'">
64+
<Target Name="AfterBuild" Condition="'$(Configuration)' == 'Release' AND '$(OS)' == 'Windows_NT'">
7665
<ItemGroup>
7766
<InputAssemblies Include="$(OutputPath)\$(AssemblyName).exe" />
7867
<InputAssemblies Include="$(OutputPath)\FoundationDB.Client.dll" />
@@ -87,11 +76,11 @@
8776
/>
8877
</Target>
8978
<!-- /ILRepack -->
90-
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
79+
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
9180
Other similar extension points exist, see Microsoft.Common.targets.
9281
<Target Name="BeforeBuild">
9382
</Target>
9483
<Target Name="AfterBuild">
9584
</Target>
9685
-->
97-
</Project>
86+
</Project>

FoundationDB.Client.sln

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,6 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FoundationDB.Tests.Sandbox"
99
EndProject
1010
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FoundationDB.Tests", "FoundationDB.Tests\FoundationDB.Tests.csproj", "{7C888F78-99B1-4CA1-8973-282EC5CCCACD}"
1111
EndProject
12-
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".nuget", ".nuget", "{8DB84402-8AF0-4851-A49F-F8EDF2A04B1E}"
13-
ProjectSection(SolutionItems) = preProject
14-
.nuget\NuGet.Config = .nuget\NuGet.Config
15-
.nuget\NuGet.exe = .nuget\NuGet.exe
16-
.nuget\NuGet.targets = .nuget\NuGet.targets
17-
EndProjectSection
18-
EndProject
1912
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FoundationDB.Layers.Common", "FoundationDB.Layers.Common\FoundationDB.Layers.Common.csproj", "{7C7717D6-A1E7-4541-AF8B-1AC762B5ED0F}"
2013
EndProject
2114
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Common", "Common", "{4788B3A8-BFC1-4A57-8062-83071A1D41F7}"

FoundationDB.Storage.Memory/IO/SnapshotWriter.cs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,11 @@ public Task WriteHeaderAsync(SnapshotFormat.Flags headerFlags, Uuid128 uid, ulon
133133
return TaskHelpers.CompletedTask;
134134
}
135135

136+
#if __MonoCS__
137+
public Task WriteLevelAsync(int level, IntPtr[] segment, CancellationToken ct)
138+
#else
136139
public async Task WriteLevelAsync(int level, IntPtr[] segment, CancellationToken ct)
140+
#endif
137141
{
138142
ct.ThrowIfCancellationRequested();
139143

@@ -230,7 +234,11 @@ public async Task WriteLevelAsync(int level, IntPtr[] segment, CancellationToken
230234
if (m_writer.Position >= SnapshotFormat.FLUSH_SIZE)
231235
{
232236
//Console.WriteLine("> partial flush (" + writer.Position + ")");
237+
#if __MonoCS__
238+
int written = m_file.WriteCompletePagesAsync(m_writer.Buffer, m_writer.Position, ct).ConfigureAwait(false).GetAwaiter().GetResult();
239+
#else
233240
int written = await m_file.WriteCompletePagesAsync(m_writer.Buffer, m_writer.Position, ct).ConfigureAwait(false);
241+
#endif
234242
if (written > 0) m_writer.Flush(written);
235243
}
236244
}
@@ -246,6 +254,10 @@ public async Task WriteLevelAsync(int level, IntPtr[] segment, CancellationToken
246254

247255
// optional padding to fill the rest of the page
248256
PadPageIfNeeded(SnapshotFormat.PAGE_SIZE, (byte)(0xFC - level));
257+
258+
#if __MonoCS__
259+
return TaskHelpers.CompletedTask;
260+
#endif
249261
}
250262

251263
public Task WriteJumpTableAsync(CancellationToken ct)

FoundationDB.Tests/FoundationDB.Tests.csproj

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,6 @@
1212
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
1313
<FileAlignment>512</FileAlignment>
1414
<TargetFrameworkProfile />
15-
<SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">..\</SolutionDir>
16-
<RestorePackages>true</RestorePackages>
1715
</PropertyGroup>
1816
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
1917
<DebugSymbols>true</DebugSymbols>
@@ -145,12 +143,11 @@
145143
<Service Include="{82A7F48D-3B50-4B1E-B82E-3ADA8210C358}" />
146144
</ItemGroup>
147145
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
148-
<Import Project="$(SolutionDir)\.nuget\nuget.targets" />
149-
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
146+
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
150147
Other similar extension points exist, see Microsoft.Common.targets.
151148
<Target Name="BeforeBuild">
152149
</Target>
153150
<Target Name="AfterBuild">
154151
</Target>
155152
-->
156-
</Project>
153+
</Project>

build/FoundationDB.Client.nuspec

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,6 @@
1717
<tags>foundationdb nosql</tags>
1818
</metadata>
1919
<files>
20-
<file src="FoundationDB.Client.dll" target="lib\net45" />
21-
<file src="FoundationDB.Client.XML" target="lib\net45" />
22-
<file src="FoundationDB.Client.pdb" target="lib\net45" />
20+
<file src="FoundationDB.Client.*" target="lib\net45" />
2321
</files>
2422
</package>

build/FoundationDB.Layers.Common.nuspec

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,6 @@
2020
</dependencies>
2121
</metadata>
2222
<files>
23-
<file src="FoundationDB.Layers.Common.dll" target="lib\net-45" />
24-
<file src="FoundationDB.Layers.Common.XML" target="lib\net-45" />
25-
<file src="FoundationDB.Layers.Common.pdb" target="lib\net-45" />
23+
<file src="FoundationDB.Layers.Common.*" target="lib\net-45" />
2624
</files>
2725
</package>

0 commit comments

Comments
 (0)