From 527a1048f14ca739eed4f5d9dcc2c62ac30080f0 Mon Sep 17 00:00:00 2001 From: Lee Maguire Date: Thu, 18 Jul 2024 13:57:41 +0100 Subject: [PATCH] Document release process (#231) --- Android.bp | 4 --- conanfile.py | 4 +-- contributing/release-process.md | 51 +++++++++++++++++++++++++++++++++ ports/vcpkg.json | 7 +---- 4 files changed, 53 insertions(+), 13 deletions(-) create mode 100644 contributing/release-process.md diff --git a/Android.bp b/Android.bp index 6b914f74..71327a5c 100644 --- a/Android.bp +++ b/Android.bp @@ -46,10 +46,6 @@ cc_library_static { name: "realm-cpp", defaults: ["realm_consumer_defaults", "realm_defaults", "realm_cpp_defaults"], srcs: ["src/cpprealm/**/*.cpp"], - exclude_srcs: [ - "src/cpprealm/internal/apple/**/*", - "src/cpprealm/internal/curl/**/*" - ], export_include_dirs: ["include"], export_generated_headers: ["gen_realmcxx_version_numbers"], static_libs: ["realm"], diff --git a/conanfile.py b/conanfile.py index 40c3f762..193b6385 100644 --- a/conanfile.py +++ b/conanfile.py @@ -30,13 +30,11 @@ def requirements(self): if not self.is_darwin(): self.requires("openssl/3.2.0") self.requires("libuv/1.48.0") - if self.settings.os == "Linux": - self.requires("libcurl/8.4.0") def source(self): git = Git(self) git.clone(url="https://github.com/realm/realm-cpp", target=".") git.folder = "." - git.checkout(commit="9170fe12bd3527b8287734a518962b3609c6ec50") + git.checkout(commit="5ec1bda338dfd0c91ce1eea2ccb2c0adf7d86690") git.run("submodule update --init --recursive") def layout(self): diff --git a/contributing/release-process.md b/contributing/release-process.md new file mode 100644 index 00000000..af8c7e73 --- /dev/null +++ b/contributing/release-process.md @@ -0,0 +1,51 @@ +# Realm C++ SDK Release Process: + +### What to check on GitHub Actions: +There are four main workflows: +- CMake build +- SPM +- Vcpkg +- Conan + +#### CMake build: +This is where the majority of testing is done, tests run on macos, Windows and Ubuntu. On Ubuntu a variety of compilers are tested. Debug and Release configurations are tested on each platform. +DB tests, Sync tests and Client reset tests run separately as part of the workflow. +#### SPM: +Only DB tests are performed. +#### Vcpkg: +The Vcpkg tests are to ensure that nothing in our CMakeLists has changed to break the Vcpkg portfile. It will install the cpprealm Vcpkg and link it against the DB tests to ensure everything integrates fine. +#### Conan: +Similar to Vcpkg, the purpose of these tests is to ensure the Conanfile is setup correctly and it links correctly against the DB tests. + +### AOSP: +Before each release check that everything builds fine on AOSP. It’s recommended to install AOSP on a Ubuntu workstation VM. +Clone the repo (can take a few hours) +https://source.android.com/docs/setup/download +Build android (also takes hours) +https://source.android.com/docs/setup/build/building +- `source build/envsetup.sh` +- `lunch aosp_cf_x86_64_phone-trunk_staging-eng` +- `m` +Once that is done, create a ‘vendor’ folder +All 3rd party libs should be cloned inside of `vendor` +Cd into your project folder and run `mma` + +### Vcpkg: +Whenever Core has a new release we should take it upon ourselves to update the portfile on the vcpkg repo. The main steps are: +Fork Vcpkg +Create a branch for the Core update +Update the versions in the portfile, example [here](https://github.com/microsoft/vcpkg/pull/39888). + +Once the Core update has performed, the same process should be taken for the C++ SDK. On Vcpkg the SDK is called cpprealm + +### Conanfile: +We haven’t submitted to the Conan index yet, but users can consume the conanfile locally. + +# Releasing from main: +- Ensure changelog is correct +- Ensure Core submodule is updated in both [Package.swift](https://github.com/realm/realm-cpp/blob/5ec1bda338dfd0c91ce1eea2ccb2c0adf7d86690/Package.swift#L5) and git submodules +- Ensure Conanfile.py is [pointing to the latest upstream](https://github.com/realm/realm-cpp/blob/main/conanfile.py#L39) and the [version is correct](https://github.com/realm/realm-cpp/blob/main/conanfile.py#L8). +- Ensure [version in local vcpkg portfile](https://github.com/realm/realm-cpp/blob/5ec1bda338dfd0c91ce1eea2ccb2c0adf7d86690/ports/vcpkg.json#L3) is correct +- Ensure the version in [dependencies.list](https://github.com/realm/realm-cpp/blob/5ec1bda338dfd0c91ce1eea2ccb2c0adf7d86690/dependencies.list#L1) is correct. +- Create a tag prefixed with v and publish the release. +- Copy the link for the release to appx-releases. diff --git a/ports/vcpkg.json b/ports/vcpkg.json index 6132e99e..619f3a7e 100644 --- a/ports/vcpkg.json +++ b/ports/vcpkg.json @@ -19,14 +19,9 @@ "version>=": "1.43.0", "platform": "!osx" }, - { - "name": "curl", - "version>=": "8.4.0", - "platform": "linux" - }, { "name": "realm-core", - "version>=": "14.8.0" + "version>=": "14.10.4" } ] }