Skip to content

Commit a70f2f6

Browse files
baudeBrewTestBot
authored andcommitted
qemu: add 9p support for Darwin
qemu: add 9p support for Darwin Qemu already has support for 9p in Linux. Adding this for MacOS users will bring them into parity for 9p support. This replaces Ashley's #95318 Signed-off-by: Brent Baude <bbaude@redhat.com>
1 parent 8822fe4 commit a70f2f6

File tree

1 file changed

+59
-0
lines changed

1 file changed

+59
-0
lines changed

Diff for: Formula/qemu.rb

+59
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ class Qemu < Formula
44
url "https://download.qemu.org/qemu-6.2.0.tar.xz"
55
sha256 "68e15d8e45ac56326e0b9a4afa8b49a3dfe8aba3488221d098c84698bca65b45"
66
license "GPL-2.0-only"
7+
revision 1
78
head "https://git.qemu.org/git/qemu.git", branch: "master"
89

910
bottle do
@@ -36,8 +37,10 @@ class Qemu < Formula
3637
depends_on "vde"
3738

3839
on_linux do
40+
depends_on "attr"
3941
depends_on "gcc"
4042
depends_on "gtk+3"
43+
depends_on "libcap-ng"
4144
end
4245

4346
fails_with gcc: "5"
@@ -48,6 +51,61 @@ class Qemu < Formula
4851
sha256 "81237c7b42dc0ffc8b32a2f5734e3480a3f9a470c50c14a9c4576a2561a35807"
4952
end
5053

54+
# The following patches add 9p support to darwin. They can
55+
# be deleted when qemu-7 is released.
56+
patch do
57+
url "https://gitlab.com/qemu-project/qemu/-/commit/e0bd743bb2dd4985791d4de880446bdbb4e04fed.diff"
58+
sha256 "9168d424f7bcabb74fdca35fd4d3db1279136ce03d656a2e0391aa4344244e49"
59+
end
60+
patch do
61+
url "https://raw.githubusercontent.com/baude/homebrew-qemu/798fdd7c6e2924591f45b282b3f59cb6e9850504/add_9p-util-linux.diff"
62+
sha256 "e2835578eeea09b75309fc3ac4a040b47c0ac8149150d8ddf45f7228ab7b5433"
63+
end
64+
patch do
65+
url "https://raw.githubusercontent.com/baude/homebrew-qemu/798fdd7c6e2924591f45b282b3f59cb6e9850504/remove_9p-util.diff"
66+
sha256 "ccf31a8e60ac7fc54fd287eca7e63fe1c9154e346d2a1367b33630227b88144d"
67+
end
68+
patch do
69+
url "https://raw.githubusercontent.com/ashley-cui/homebrew-podman/e1162ec457bd46ed84aef9a0aa41e80787121088/change.patch"
70+
sha256 "af8343144aea8b51852b8bf7c48f94082353c5e0c57d78fc61e7c3e4be3658b9"
71+
end
72+
patch do
73+
url "https://gitlab.com/qemu-project/qemu/-/commit/f41db099c71151291c269bf48ad006de9cbd9ca6.diff"
74+
sha256 "1769d60fc2248fc457846ec8fbbf837be539e08bd0f56daf6ec9201afe6c157e"
75+
end
76+
patch do
77+
url "https://gitlab.com/qemu-project/qemu/-/commit/6b3b279bd670c6a2fa23c9049820c814f0e2c846.diff"
78+
sha256 "bde6fa9deffeb31ca092f183a9bffc1041501c2532a625f8875fa119945049b8"
79+
end
80+
patch do
81+
url "https://gitlab.com/qemu-project/qemu/-/commit/67a71e3b71a2834d028031a92e76eb9444e423c6.diff"
82+
sha256 "60f38699e2488f854c295afbfea56f30fce1ebc0d2a7dcddf8bedba2d14533b1"
83+
end
84+
patch do
85+
url "https://gitlab.com/qemu-project/qemu/-/commit/38d7fd68b0c8775b5253ab84367419621aa032e6.diff"
86+
sha256 "b89ed2a06d1e81cb18b7fab0b47313d8a3acc6be70a4874854c0cc925fc6e57f"
87+
end
88+
patch do
89+
url "https://gitlab.com/qemu-project/qemu/-/commit/57b3910bc3513ab515296692daafd1c546f3c115.diff"
90+
sha256 "4bbd1f2d209f099fb2b075630b67a3d08829d67c56edcb21fc5688f66a486296"
91+
end
92+
patch do
93+
url "https://gitlab.com/qemu-project/qemu/-/commit/b5989326f558faedd2511f29459112cced2ca8f5.diff"
94+
sha256 "5c53c4cc28229058f9fac3eed521d62edf9b952bf24eb18790a400a074ed6f0b"
95+
end
96+
patch do
97+
url "https://gitlab.com/qemu-project/qemu/-/commit/029ed1bd9defa33a80bb40cdcd003699299af8db.diff"
98+
sha256 "a349c6de07fcf8314a1d84cacc05c68573728641cc5054d0fc149d14e1c9bed8"
99+
end
100+
patch do
101+
url "https://gitlab.com/qemu-project/qemu/-/commit/d3671fd972cd185a6923433aa4802f54d8b62112.diff"
102+
sha256 "f40dd472ec4dcbf6f352338de85c1aba5a92a3b9f0a691f8ae51e298e2b5a273"
103+
end
104+
patch do
105+
url "https://raw.githubusercontent.com/NixOS/nixpkgs/8fc669a1dd84ae0db237fdb30e84c9f47e0e9436/pkgs/applications/virtualization/qemu/allow-virtfs-on-darwin.patch"
106+
sha256 "61422ab60ed9dfa3d9fe8a267c54fab230f100e9ba92275bc98cf5da9e388cde"
107+
end
108+
51109
def install
52110
ENV["LIBTOOL"] = "glibtool"
53111

@@ -61,6 +119,7 @@ def install
61119
--enable-libssh
62120
--enable-slirp=system
63121
--enable-vde
122+
--enable-virtfs
64123
--extra-cflags=-DNCURSES_WIDECHAR=1
65124
--disable-sdl
66125
]

0 commit comments

Comments
 (0)