61 lines
1.9 KiB
Ruby
61 lines
1.9 KiB
Ruby
class Wget < Formula
|
|
bottle do
|
|
root_url "https://homebrew.mirror.ygg/bottles"
|
|
rebuild 2
|
|
sha256 cellar: "/opt/homebrew/Cellar", arm64_sequoia: "aa19cf5de262d5b67631af8288cce233a075c251c68050a1e73699314a911e7b"
|
|
sha256 cellar: "/opt/homebrew/Cellar", arm64_tahoe: "27e15ca14afaaa7c2016bba7a098452cf66d1d8a74330ed6195a0b6ae7a4dada"
|
|
sha256 cellar: "/home/linuxbrew/.linuxbrew/Cellar", x86_64_linux: "8f58b44e7482ee12e910df582cf43a4dadb808e4db70bfc760aaf258942652a5"
|
|
end
|
|
desc "Internet file retriever"
|
|
homepage "https://www.gnu.org/software/wget/"
|
|
url "https://ftpmirror.gnu.org/gnu/wget/wget-1.25.0.tar.gz"
|
|
sha256 "766e48423e79359ea31e41db9e5c289675947a7fcf2efdcedb726ac9d0da3784"
|
|
license "GPL-3.0-or-later"
|
|
compatibility_version 1
|
|
|
|
|
|
|
|
head do
|
|
url "https://git.savannah.gnu.org/git/wget.git", branch: "master"
|
|
|
|
depends_on "autoconf" => :build
|
|
depends_on "automake" => :build
|
|
depends_on "xz" => :build
|
|
end
|
|
|
|
depends_on "pkgconf" => :build
|
|
depends_on "libidn2"
|
|
depends_on "libpsl"
|
|
depends_on "openssl@3"
|
|
|
|
on_macos do
|
|
depends_on "gettext"
|
|
depends_on "libunistring"
|
|
end
|
|
|
|
on_linux do
|
|
depends_on "util-linux"
|
|
depends_on "zlib-ng-compat"
|
|
end
|
|
|
|
def install
|
|
system "./bootstrap", "--skip-po" if build.head?
|
|
system "./configure", "--prefix=#{prefix}",
|
|
"--sysconfdir=#{etc}",
|
|
"--with-ssl=openssl",
|
|
"--with-libssl-prefix=#{formula_opt_prefix("openssl@3")}",
|
|
"--disable-pcre",
|
|
"--disable-pcre2",
|
|
"--with-libpsl",
|
|
"--without-included-regex"
|
|
system "make", "install"
|
|
end
|
|
|
|
test do
|
|
system bin/"wget", "-O", File::NULL, "https://google.com"
|
|
|
|
# Verify PSL support is built in via libpsl
|
|
assert_match "+psl", shell_output("#{bin}/wget --version")
|
|
end
|
|
end
|