From 61a47e5ef5b1f80726c745d8cd5ac9efdf336c73 Mon Sep 17 00:00:00 2001 From: Bo Anderson Date: Tue, 22 Oct 2024 15:52:45 +0100 Subject: [PATCH] xclogparser: staticly link Swift stdlib on Linux --- Formula/x/xclogparser.rb | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Formula/x/xclogparser.rb b/Formula/x/xclogparser.rb index a0c72eb30aef0a..04fdf157ac6de8 100644 --- a/Formula/x/xclogparser.rb +++ b/Formula/x/xclogparser.rb @@ -4,6 +4,7 @@ class Xclogparser < Formula url "https://github.com/MobileNativeFoundation/XCLogParser/archive/refs/tags/v0.2.39.tar.gz" sha256 "b225891b94bbdb549ddbc9ffe838ad87f73ef7cc79934e3e23969bb1220eafd9" license "Apache-2.0" + revision 1 bottle do sha256 cellar: :any_skip_relocation, arm64_sonoma: "2af489ea40d0e2ea3d490c151137cc74992e17d9e5d4ea842efe37bb5c3c83f3" @@ -20,7 +21,12 @@ class Xclogparser < Formula uses_from_macos "swift" def install - system "swift", "build", "-c", "release", "--disable-sandbox" + args = if OS.mac? + ["--disable-sandbox"] + else + ["--static-swift-stdlib"] + end + system "swift", "build", "-c", "release", *args bin.install ".build/release/xclogparser" end