Skip to content

Commit

Permalink
more wip
Browse files Browse the repository at this point in the history
  • Loading branch information
fealebenpae committed Apr 15, 2019
1 parent 9eced2e commit 62de80f
Show file tree
Hide file tree
Showing 15 changed files with 234 additions and 1,842 deletions.
813 changes: 180 additions & 633 deletions Jenkinsfile

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion Realm/AssemblyInfo.props
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Product>Realm .NET</Product>
<Version>4.0</Version>
<VersionPrefix>4.0.0</VersionPrefix>
<Description Condition="'$(Description)' == ''">Realm is a mobile database: a replacement for SQLite</Description>
<Company>Realm Inc.</Company>
<Copyright>Copyright © $([System.DateTime]::Now.ToString(yyyy)) Realm Inc.</Copyright>
Expand Down
43 changes: 38 additions & 5 deletions Realm/Realm/Realm.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,45 @@
<Content Include="RealmWrappersReferences.props" Pack="true" PackagePath="build\Realm.props" />
<!-- iOS -->
<None Update="app.config" Pack="true" PackagePath="native\ios\$(AssemblyName).dll.config" />
<None Include="..\..\wrappers\build\$(Configuration)-ios-universal\librealm-wrappers.a">
<None Include="..\..\wrappers\build\iOS\$(Configuration)\realm-wrappers.framework">
<Pack>true</Pack>
<PackagePath>native\ios\universal</PackagePath>
<Link>wrappers\iOS\librealm-wrappers..a</Link>
<Link>wrappers\iOS\%(Filename).%(Extension)</Link>
</None>
<!-- Windows --><!--
<!-- macOS -->
<None Include="..\..\wrappers\build\macOS\$(Configuration)\librealm-wrappers.dylib">
<Pack>true</Pack>
<PackagePath>runtimes\osx.10.10-x64\native</PackagePath>
<Link>wrappers\Darwin\%(Filename).%(Extension)</Link>
</None>
<!-- Linux -->
<None Include="..\..\wrappers\build\Linux\$(Configuration)\librealm-wrappers.so">
<Pack>true</Pack>
<PackagePath>runtimes\linux-x64\native</PackagePath>
<Link>wrappers\Linux\%(Filename).%(Extension)</Link>
</None>
<!-- Android -->
<None Include="..\..\wrappers\build\Android\$(Configuration)-armeabi-v7a\librealm-wrappers.so">
<Pack>true</Pack>
<PackagePath>native\android\armeabi-v7a</PackagePath>
<Link>wrappers\Android\armeabi-v7a\%(Filename).%(Extension)</Link>
</None>
<None Include="..\..\wrappers\build\Android\$(Configuration)-arm64-v8a\librealm-wrappers.so">
<Pack>true</Pack>
<PackagePath>native\android\arm64-v8a</PackagePath>
<Link>wrappers\Android\arm64-v8a\%(Filename).%(Extension)</Link>
</None>
<None Include="..\..\wrappers\build\Android\$(Configuration)-x86\librealm-wrappers.so">
<Pack>true</Pack>
<PackagePath>native\android\x86</PackagePath>
<Link>wrappers\Android\x86\%(Filename).%(Extension)</Link>
</None>
<None Include="..\..\wrappers\build\Android\$(Configuration)-x86_64\librealm-wrappers.so">
<Pack>true</Pack>
<PackagePath>native\android\x86_64</PackagePath>
<Link>wrappers\Android\x86_64\%(Filename).%(Extension)</Link>
</None>
<!-- Windows -->
<None Include="..\..\wrappers\build\Windows\$(Configuration)-Win32\realm-wrappers.dll">
<Pack>true</Pack>
<PackagePath>runtimes\win81-x86\native</PackagePath>
Expand All @@ -36,7 +69,7 @@
<PackagePath>runtimes\win81-x64\native</PackagePath>
<Link>wrappers\Windows\x64\%(Filename).%(Extension)</Link>
</None>
--><!-- WindowsStore --><!--
<!-- WindowsStore -->
<None Include="..\..\wrappers\build\WindowsStore\$(Configuration)-Win32\realm-wrappers.dll">
<Pack>true</Pack>
<PackagePath>runtimes\win10-x86\nativeassets\uap10.0</PackagePath>
Expand All @@ -51,7 +84,7 @@
<Pack>true</Pack>
<PackagePath>runtimes\win10-arm\nativeassets\uap10.0</PackagePath>
<Link>wrappers\WindowsStore\ARM\%(Filename).%(Extension)</Link>
</None>-->
</None>
</ItemGroup>
<Import Project="..\AssemblyInfo.props " />
<Import Project="..\Realm.Fody\InSolutionWeaver.props" />
Expand Down
8 changes: 3 additions & 5 deletions Realm/Realm/RealmWrappersReferences.props
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,9 @@
<_RealmNugetNativePath Condition="'$(_RealmNugetNativePath)' == ''">$(MSBuildThisFileDirectory)..\native\</_RealmNugetNativePath>
</PropertyGroup>
<ItemGroup Condition="'$(TargetFrameworkIdentifier)' == 'Xamarin.iOS'">
<NativeReference Include="$(_RealmNugetNativePath)ios\universal\librealm-wrappers.a">
<Kind>Static</Kind>
<SmartLink>True</SmartLink>
<IsCxx>True</IsCxx>
<LinkerFlags>-lz -framework Security</LinkerFlags>
<NativeReference Include="$(_RealmNugetNativePath)ios\universal\realm-wrappers.framework">
<Kind>Framework</Kind>
<SmartLink>False</SmartLink>
</NativeReference>
<None Include="$(_RealmNugetNativePath)ios\Realm.dll.config">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
Expand Down
2 changes: 0 additions & 2 deletions Tests/Realm.Tests/Realm.Tests.csproj
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,9 @@
<PropertyGroup>
<TargetFrameworks>net461;netcoreapp20;monoandroid81;xamarin.ios10;xamarin.mac20</TargetFrameworks>
<TargetFrameworks Condition="'$(OS)' == 'Windows_NT'">$(TargetFrameworks);uap10.0.16299</TargetFrameworks>
<TargetFrameworks Condition="'$(MSBuildRuntimeType)' == 'Core'">netcoreapp20</TargetFrameworks>
<RootNamespace>Realms.Tests</RootNamespace>
<BuildWithRealmNugets Condition="'$(BuildWithRealmNugets)' == ''">False</BuildWithRealmNugets>
<IsTestProject>true</IsTestProject>
<OutputType>Library</OutputType>
</PropertyGroup>

<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion global.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"msbuild-sdks": {
"MSBuild.Sdk.Extras": "1.6.55"
"MSBuild.Sdk.Extras": "2.0.24"
}
}
78 changes: 0 additions & 78 deletions wrappers/Makefile

This file was deleted.

File renamed without changes.
15 changes: 8 additions & 7 deletions wrappers/build.ps1
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@ param(
[ValidateSet('Win32', 'x64', 'ARM')]
[string[]]$Platforms = ('Win32'),

[switch]$EnableSync,

[ValidateSet('Windows', 'WindowsStore')]
[Parameter(Position=0)]
[string]$Target = 'Windows'
Expand All @@ -28,21 +26,24 @@ param(
Push-Location $PSScriptRoot

if (!(Get-Module -ListAvailable -Name VSSetup)) {
Install-PackageProvider NuGet -Scope CurrentUser -Force
Import-PackageProvider NuGet -Force
Set-PSRepository -Name PSGallery -InstallationPolicy Trusted
Install-Module -Name VSSetup -Scope CurrentUser -Force
}

$vs = Get-VSSetupInstance | Select-VSSetupInstance -Latest -Require Microsoft.VisualStudio.Component.VC.CMake.Project

# Work-around for Visual Studio 16.0 and CMake 3.13
$Env:path += ";$($vs.InstallationPath)\MSBuild\Current\Bin"

$cmake = Join-Path $vs.InstallationPath -ChildPath "Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\cmake.exe"
$cmakeArgs = "-DCMAKE_BUILD_TYPE=$Configuration", "-DCMAKE_SYSTEM_NAME=$Target", "-DCMAKE_INSTALL_PREFIX=$PSScriptRoot\build", "-DCMAKE_TOOLCHAIN_FILE=c:\\src\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake"
$cmakeArgs = "-DCMAKE_GENERATOR_INSTANCE=$($vs.InstallationPath)", "-DCMAKE_BUILD_TYPE=$Configuration", "-DCMAKE_SYSTEM_NAME=$Target", "-DCMAKE_INSTALL_PREFIX=$PSScriptRoot\build", "-DCMAKE_TOOLCHAIN_FILE=c:\\src\\vcpkg\\scripts\\buildsystems\\vcpkg.cmake"

if ($Target -eq 'WindowsStore') {
$cmakeArgs += "-DCMAKE_SYSTEM_VERSION='10.0'"
}

if ($EnableSync) {
$cmakeArgs += "-DREALM_ENABLE_SYNC=ON"
}

function triplet([string]$target, [string]$platform) {
$arch = $platform.ToLower()
if ($arch -eq 'win32') {
Expand Down
6 changes: 3 additions & 3 deletions wrappers/Dockerfile.centos → wrappers/centos.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ RUN yum install -y \
zlib-devel

RUN mkdir -p /opt/cmake && \
curl -s https://cmake.org/files/v3.11/cmake-3.11.4-Linux-x86_64.sh -o /cmake-3.11.4-Linux-x86_64.sh && \
sh /cmake-3.11.4-Linux-x86_64.sh --prefix=/opt/cmake --skip-license && \
rm /cmake-3.11.4-Linux-x86_64.sh
curl -s https://cmake.org/files/v3.14/cmake-3.14.1-Linux-x86_64.sh -o /cmake.sh && \
sh /cmake.sh --prefix=/opt/cmake --skip-license && \
rm /cmake.sh
ENV PATH="/opt/rh/devtoolset-6/root/usr/bin:/opt/cmake/bin:${PATH}"

RUN mkdir -p /etc/ssh && \
Expand Down
Loading

0 comments on commit 62de80f

Please sign in to comment.