From fefc166019dd2b4b3ded0057469811ba17a56380 Mon Sep 17 00:00:00 2001 From: Alexander Bayandin Date: Mon, 29 Jan 2024 11:07:23 +0000 Subject: [PATCH] neon-storage 4713 --- Formula/neon-storage.rb | 44 ++++++++++++++++++++++------------------- 1 file changed, 24 insertions(+), 20 deletions(-) diff --git a/Formula/neon-storage.rb b/Formula/neon-storage.rb index 5e35aa1..9e0dfa6 100644 --- a/Formula/neon-storage.rb +++ b/Formula/neon-storage.rb @@ -2,8 +2,8 @@ class NeonStorage < Formula desc "Storage components for Neon" homepage "https://github.com/neondatabase/neon" url "https://github.com/neondatabase/neon.git", - tag: "release-4642", - revision: "a1a74eef2c60c283bc038b65b99db2ed0c68f5bb" + tag: "release-4713", + revision: "1ec3e39d4e777d53d78eea8eba7d21f37942b000" license "Apache-2.0" head "https://github.com/neondatabase/neon.git", branch: "main" @@ -14,9 +14,10 @@ class NeonStorage < Formula sha256 cellar: :any_skip_relocation, x86_64_linux: "88c87bf0a437c6278a10376a3c20e20b9a0bb36296f3b515f6c51880a7b4937f" end - depends_on "bayandin/tap/neon-postgres" => :build depends_on "pkg-config" => :build depends_on "rust" => :build + depends_on "bayandin/tap/neon-postgres" + depends_on "libpq" depends_on "openssl@3" depends_on "protobuf" @@ -35,9 +36,6 @@ def neon_postgres end def install - ENV["BUILD_TAG"] = build.stable? ? "release-#{version}" : "dev-#{Utils.git_short_head}" - ENV["GIT_VERSION"] = Utils.git_head - # A workaround for `FATAL: postmaster became multithreaded during startup` on macOS >= 14.2 # See https://www.postgresql.org/message-id/flat/CYMBV0OT7216.JNRUO6R6GH86%40neon.tech if OS.mac? @@ -48,20 +46,26 @@ def install EOS end - with_env(POSTGRES_INSTALL_DIR: neon_postgres.opt_libexec) do - system "cargo", "install", *std_cargo_args(root: libexec, path: "compute_tools") - system "cargo", "install", *std_cargo_args(root: libexec, path: "control_plane") - system "cargo", "install", *std_cargo_args(root: libexec, path: "control_plane/attachment_service") - system "cargo", "install", *std_cargo_args(root: libexec, path: "libs/postgres_ffi/wal_craft") - system "cargo", "install", *std_cargo_args(root: libexec, path: "pageserver") - system "cargo", "install", *std_cargo_args(root: libexec, path: "pageserver/ctl") - system "cargo", "install", *std_cargo_args(root: libexec, path: "pageserver/pagebench") - system "cargo", "install", *std_cargo_args(root: libexec, path: "proxy") - system "cargo", "install", *std_cargo_args(root: libexec, path: "s3_scrubber") - system "cargo", "install", *std_cargo_args(root: libexec, path: "safekeeper") - system "cargo", "install", *std_cargo_args(root: libexec, path: "storage_broker") - system "cargo", "install", *std_cargo_args(root: libexec, path: "trace") - end + ENV["BUILD_TAG"] = build.stable? ? "release-#{version}" : "dev-#{Utils.git_short_head}" + ENV["GIT_VERSION"] = Utils.git_head + ENV["POSTGRES_INSTALL_DIR"] = neon_postgres.opt_libexec + ENV["POSTGRES_DISTRIB_DIR"] = neon_postgres.opt_libexec + + mkdir_p libexec/"control_plane/attachment_service" + cp_r "control_plane/attachment_service/migrations", libexec/"control_plane/attachment_service/" + + system "cargo", "install", *std_cargo_args(root: libexec, path: "compute_tools") + system "cargo", "install", *std_cargo_args(root: libexec, path: "control_plane") + system "cargo", "install", *std_cargo_args(root: libexec, path: "control_plane/attachment_service") + system "cargo", "install", *std_cargo_args(root: libexec, path: "libs/postgres_ffi/wal_craft") + system "cargo", "install", *std_cargo_args(root: libexec, path: "pageserver") + system "cargo", "install", *std_cargo_args(root: libexec, path: "pageserver/ctl") + system "cargo", "install", *std_cargo_args(root: libexec, path: "pageserver/pagebench") + system "cargo", "install", *std_cargo_args(root: libexec, path: "proxy") + system "cargo", "install", *std_cargo_args(root: libexec, path: "s3_scrubber") + system "cargo", "install", *std_cargo_args(root: libexec, path: "safekeeper") + system "cargo", "install", *std_cargo_args(root: libexec, path: "storage_broker") + system "cargo", "install", *std_cargo_args(root: libexec, path: "trace") end test do