Conversation
|
|
I believe the error is related to abseil or protobuf, but they are really hard to bump |
|
Perhaps on the Linux build use I'm very eager to get the new OpenCV formula for macOS, please and thank you. 😸 |
|
I would suggest try removing this line: homebrew-core/Formula/o/opencv.rb Line 108 in a62c9fe and then change this line: homebrew-core/Formula/o/opencv.rb Line 141 in a62c9fe to then lastly remove this line: homebrew-core/Formula/o/opencv.rb Line 151 in a62c9fe I think that should allow the OpenCV on Linux to build its own protobuf (used only for itself), and resolve the CI failure. |
|
I see the new build failure due to the protobuf build directory being removed. To address this, the following additional changes are needed: homebrew-core/Formula/o/opencv.rb Line 96 in 17336c8 change this to: |
|
Oops, I forgot my Ruby style. That should be: libdirs = %w[ffmpeg libjasper libjpeg libjpeg-turbo libpng libtiff libwebp openexr openjpeg tbb zlib]
libdirs += "protobuf" if OS.mac? |
|
The correct syntax is: libdirs = %w[ffmpeg libjasper libjpeg libjpeg-turbo libpng libtiff libwebp openexr openjpeg tbb zlib]
libdirs += ["protobuf"] if OS.mac? |
|
Thanks for your patience while we work thru the build issues here @dnhn From looking at the OpenCV build defaults here, I think one more change is needed. This line here needs to be removed: homebrew-core/Formula/o/opencv.rb Line 120 in 3789536 And then this line needs to be modified: homebrew-core/Formula/o/opencv.rb Line 141 in 3789536 to be ["-DWITH_OBSENSOR=OFF", "-DBUILD_PROTOBUF=OFF", "-DPROTOBUF_UPDATE_FILES=ON"] |
|
We're back to the original error message now, but at least we know the specific version of protobuf installed on Linux. Right before this line: homebrew-core/Formula/o/opencv.rb Line 201 in c97cea9 This code should install the matching version of protobuf in a venv on Linux before running the test: # create venv for running Python tests on Linux
if !OS.mac?
system python3, "-m", "venv", testpath/"testvenv"
system "source", testpath/"testvenv"
system python3, "-m", "pip install protobuf==3.19.1"
end |
|
Apparently the syntax demanded by the linter is: unless OS.mac?instead of if !OS.mac? |
|
In other words, use this instead: # create venv for running Python tests on Linux
unless OS.mac?
system python3, "-m", "venv", testpath/"testvenv"
system "source", testpath/"testvenv"
system python3, "-m", "pip install protobuf==3.19.1"
end |
d4cf917 to
fbeb7e3
Compare
|
@SMillerDev did you change the line that I suggested of: system "source", testpath/"testvenv"to system ".", testpath/"testvenv"because I do not think that will work. Also the CI failed on that line: The purpose of my change is to switch python to use that venv, in order to install a specific version of |
|
Actually, now that I read it again, I think my proposed change should have been: system "source", testpath/"testvenv/bin/activate" |
a51b7a8 to
6a4527b
Compare
|
Please don't add merge commits, our CI can't handle them. |
|
Same issue in |
carlocab
left a comment
There was a problem hiding this comment.
mlt has low install numbers. I suggest just merging this regardless if it's not broken everywhere.
|
Caution Please do not push to this PR branch before the bottle commits have been pushed, as this results in a state that is difficult to recover from. If you need to resolve a merge conflict, please use a merge commit. Do not force-push to this PR branch. |
HOMEBREW_NO_INSTALL_FROM_API=1 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 doingHOMEBREW_NO_INSTALL_FROM_API=1 brew install --build-from-source <formula>)? If this is a new formula, does it passbrew audit --new <formula>?