class Sunshine < Formula desc "Gamestream host/server for Moonlight" homepage "https://app.lizardbyte.dev" url "https://github.com/LizardByte/Sunshine.git", tag: "v0.14.1", revision: "6000b85b1a4ec574d93fbc7545f5bf48f3d5aaa7" license all_of: ["GPL-3.0", "BSD-3-Clause", "MIT"] head "https://github.com/LizardByte/Sunshine.git" depends_on "boost" => :build depends_on "cmake" => :build depends_on "ffmpeg" depends_on "openssl@1.1" depends_on "opus" def install args = %W[ -DOPENSSL_ROOT_DIR=#{Formula["openssl"].opt_prefix} -DSUNSHINE_ASSETS_DIR=local/sunshine/assets -DSUNSHINE_CONFIG_DIR=local/sunshine/config ] system "cmake", "-S", ".", "-B", "build", *std_cmake_args, *args cd "build" do system "make", "-j" system "make", "install" end end test do # No discernable tests in project, making do with cli output system "touch", "sunshine.conf" assert_match "Sunshine version: v0.14.1", shell_output("#{bin}/sunshine sunshine.conf --version").strip end end