@@ -3,13 +3,12 @@ class Ettercap < Formula
33 homepage "https://ettercap.github.io/ettercap/"
44 license "GPL-2.0-or-later"
55 revision 2
6+ head "https://github.com/Ettercap/ettercap.git" , branch : "master"
67
78 stable do
89 url "https://github.com/Ettercap/ettercap/archive/refs/tags/v0.8.3.1.tar.gz"
910 sha256 "d0c3ef88dfc284b61d3d5b64d946c1160fd04276b448519c1ae4438a9cdffaf3"
1011
11- depends_on "pcre"
12-
1312 # Part of libmaxminddb backport that cannot be added via patch.
1413 # Remove in the next release along with corresponding install
1514 resource "GeoLite2-Country.mmdb" do
@@ -29,6 +28,13 @@ class Ettercap < Formula
2928 url "https://raw.githubusercontent.com/Homebrew/homebrew-core/1cf441a0/Patches/ettercap/libmaxminddb-backport.diff"
3029 sha256 "b7869963df256af7cfae0f9e936e6dac4ec51a8b38dcfef6ea909e81e3ab8d0e"
3130 end
31+
32+ # Apply Debian's upstreamed patch for pcre2 support. Remove in the next release.
33+ # https://github.com/Ettercap/ettercap/commit/b1686d46792aecc10662e4a8ec221c9727661878
34+ patch do
35+ url "https://sources.debian.org/data/main/e/ettercap/1%3A0.8.3.1-15/debian/patches/1170.patch"
36+ sha256 "a3c426d36f84487bbdb5d02b831df295af33373fcb59ee81254cee6807a50a4c"
37+ end
3238 end
3339
3440 no_autobump! because : :requires_manual_review
@@ -47,12 +53,6 @@ class Ettercap < Formula
4753 sha256 x86_64_linux : "ed90068515d35787a0e19066936f3689eea7a1e7ed85ab1119ab60a71c7881d6"
4854 end
4955
50- head do
51- url "https://github.com/Ettercap/ettercap.git" , branch : "master"
52-
53- depends_on "pcre2"
54- end
55-
5656 depends_on "cmake" => :build
5757 depends_on "gdk-pixbuf"
5858 depends_on "glib"
@@ -61,6 +61,7 @@ class Ettercap < Formula
6161 depends_on "libnet"
6262 depends_on "ncurses"
6363 depends_on "openssl@3"
64+ depends_on "pcre2"
6465
6566 uses_from_macos "bison" => :build
6667 uses_from_macos "flex" => :build
@@ -89,7 +90,7 @@ def install
8990
9091 args = %W[
9192 -DBUNDLED_LIBS=OFF
92- -DCMAKE_INSTALL_RPATH=#{ rpath }
93+ -DCMAKE_INSTALL_RPATH=#{ rpath } ; #{ rpath ( source : lib / "ettercap" ) }
9394 -DCMAKE_POLICY_VERSION_MINIMUM=3.5
9495 -DENABLE_CURSES=ON
9596 -DENABLE_GTK=ON
0 commit comments