-
-
Notifications
You must be signed in to change notification settings - Fork 12.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
folly fizz wangle watchman 2021.08.02.00 #82474
Conversation
Same failure on macOS for
Linux failure for
|
c44786c
to
518c63f
Compare
You will need to add |
I don't know for sure if GCC-9 will help on Linux. Just trying things out for now. I'll try disabling some newer versions of GCC in case it helps. GCC-11 is able to compile Still trying to figure out how upstream is able to build The Facebook projects seem to have their own build system, which will take some time to dissect and see what versions of dependencies are actually used in CI. |
518c63f
to
f4b9aa8
Compare
29a592f
to
68df02d
Compare
Got But broke test for Still need to find what boost linker flags are needed to get Linux to compile the
|
I did see that and only tried the first flag here, which failed with It could be I'll probably restart test with those flags inside an |
We might also be hitting NixOS/nix#2306 where our libraries are # ls .linuxbrew/opt/boost/lib/libboost_context*
.linuxbrew/opt/boost/lib/libboost_context-mt.a .linuxbrew/opt/boost/lib/libboost_context-mt.so.1.76.0
.linuxbrew/opt/boost/lib/libboost_context-mt.so Might try using |
68df02d
to
f1fb8a3
Compare
Formula/watchman.rb
Outdated
system "cmake", "-S", ".", "-B", "build", | ||
"-DBUILD_SHARED_LIBS=ON", | ||
"-DCMAKE_PREFIX_PATH=#{buildpath}/googletest", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's try ENV.append_path "CMAKE_PREFIX_PATH"
; I don't think we want to override the env variable set by superenv.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll try updating after Linux CI results are available to see if any changes are needed there.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, I don't think it overrides the value.
For example, in https://cmake.org/cmake/help/latest/command/find_package.html, this should behave similar to ENV.prepend_path
since it is step 2 (Search paths specified in cmake-specific cache variables) while Homebrew superenv uses step 3 (Search paths specified in cmake-specific environment variables).
Since we want local GoogleTest to take precedence, this should behave as expected.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For more specific option, I think setting
ENV["GTest_DIR"] = ENV["GMock_DIR"] = buildpath/"googletest"
worked for me.
Giving this a try on CI instead of general search path.
Linux passes on everything but
|
f47f063
to
eeb0825
Compare
Added a bunch of ohai/print statements to |
eeb0825
to
c90cea0
Compare
Successfully built on both macOS and Linux. Should be good to review and merge now. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work!
ohai "Starting EchoServer on port #{port}" | ||
fork { exec testpath/"EchoServer", "-port", port.to_s } | ||
sleep 2 | ||
sleep 3 | ||
|
||
require "pty" | ||
r, w, pid = PTY.spawn(testpath/"EchoClient", "-port", port.to_s) | ||
w.write "Hello from Homebrew!\nAnother test line.\n" | ||
sleep 1 | ||
Process.kill("TERM", pid) | ||
output = r.read | ||
output = "" | ||
PTY.spawn(testpath/"EchoClient", "-port", port.to_s) do |r, w, pid| | ||
ohai "Sending data via EchoClient" | ||
w.write "Hello from Homebrew!\nAnother test line.\n" | ||
sleep 3 | ||
Process.kill "TERM", pid | ||
begin | ||
ohai "Reading received data" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can remove the ohai
calls now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe do this in a CI-syntax-only PR to avoid rerunning. They do help though when running CI as it is very difficult to debug where the CI fails since we don't print out anything after compiling the test program.
🤖 A scheduled task has triggered a merge. |
brew install --build-from-source <formula>
, where<formula>
is the name of the formula you're submitting?brew test <formula>
, where<formula>
is the name of the formula you're submitting?brew audit --strict <formula>
(after doingbrew install --build-from-source <formula>
)? If this is a new formula, does it passbrew audit --new <formula>
?Another try after #81599 with some Linux fixes.
Highly doubt macOS build of
watchman
has been fixed since upstream is only able to build Linux:https://github.com/facebook/watchman/actions/runs/1089437312