-
Notifications
You must be signed in to change notification settings - Fork 90
Fix errors compiling for OSX catalina #940
New issue
<
8000
/summary>
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
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
Fix errors compiling for OSX catalina #940
Conversation
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.
utACK 1f03f54
bootstrap.log
... |
Hmmm... Sorry. I never used make depends locally. Is it working now with cave spectre's push?
…________________________________
From: Sean Phillips ***@***.***>
Sent: Wednesday, May 5, 2021 2:00:51 PM
To: Veil-Project/veil ***@***.***>
Cc: eugene-so ***@***.***>; Assign ***@***.***>
Subject: Re: [Veil-Project/veil] Fix errors compiling for OSX catalina (#940)
Seem to have a problem with Boost on a fairly fresh Catalina MacBook Pro.
cd depends
make
...
Fetching boost_1_64_0.tar.bz2 from https://dl.bintray.com/boostorg/release/1.64.0/source/
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- 0:00:02 --:--:-- 0
curl: (22) The requested URL returned error: 403 Forbidden
Fetching boost_1_64_0.tar.bz2 from https://bitcoincore.org/depends-sources
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 76.7M 100 76.7M 0 0 157k 0 0:08:19 0:08:19 --:--:-- 378k
/Users/.../Documents/GitHub/veil/depends/work/download/boost-1_64_0/boost_1_64_0.tar.bz2.temp: OK
Extracting boost...
/Users/.../Documents/GitHub/veil/depends/sources/boost_1_64_0.tar.bz2: OK
Preprocessing boost...
Configuring boost...
Building Boost.Build engine with toolset darwin...
Failed to build Boost.Build build engine
Consult 'bootstrap.log' for more details
make: *** [/Users/.../Documents/GitHub/veil/depends/work/build/x86_64-apple-darwin19.6.0/boost/1_64_0-0bee59b2cae/./.stamp_configured] Error 1
—
You are receiving this because you were assigned.
Reply to this email directly, view it on GitHub<#940 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AQ7EU4JASYZG4MNRDZDJMRTTMGPXHANCNFSM44AJ3VCA>.
|
I got a checksum error on the first download, so it downloaded from the bitcoin repo and got a checksum error also. |
Let's talk about this for a minute. It now looks like Cave Spectre's change broke the automated build check (which was working previously). In this PR, I never touched the dependent boost library or the automated build macOS version. It was meant to fix a local build on MacOS Catalina which is what I'm using. I usually build using these commands which are described in build-osx.md:
As such I never tested |
bd2d1ac
to
1f03f54
Compare
Since you didn't build depends; we don't know if bintray.com going down is what broke depends, or if depends doesn't build on Catalina. So this was an attempt to isolate the problem. Since Sean is able to test it, this seemed like a good place to put that change quickly so that he doesn't have to monkey around with cherry-picking together two different branches. It's been reverted since boost.org had a bad checksum on their website. |
What shall we do here then? I know that later in the C++17 branch I do start updating the boost library and automated build osx versions. |
bd2d1ac
to
1f03f54
Compare
We're going to have @seanPhill build this with your method; make sure nothing seems broken, and if that's the case merge it, and cross the depends bridge with your c++17 branch since it doesn't look like there's an easy cherry-pick into this branch to solve that issue. |
On Catalina, using the documented in build-osx.md brew install ... method When compiling afterwards, with
Everything seemed to be going fine when suddenly getting 20 errors apparently relating to C++17, hitting the maximum errors and then stopping. I've copied and pasted the output from around the point that the errors began. |
Hmmm... peculiar. I thought I had it compiling on my Catalina system without requiring C++17 at this point. I'll give it another try from scratch build as well. |
Ok, I found that this was actually missing one cherry-pick related to dark mode that is required. It now compiles fine on my Catalina system from scratch. @seanPhill : I wonder if there is a mismatch on your system between the QT@5 installed using brew as a dependency and another version of QT on your system? On my system, I do not have the path /usr/local/include/QtCore where your error is showing up. Instead I have /usr/local/Cellar/qt@5/5.15.2/include/QtCore which is the one installed by brew. It's possible that the version you have on your system already requires C++17 for QT which would require pulling a lot more of the changes from the C++17 branch, whereas the one installed by brew still works fine using C++11. Here is exactly what I ran to get it to compile and check certain things:
|
brew info qt@5 qt@5 is keg-only, which means it was not symlinked into /usr/local, If you need to have qt@5 first in your PATH, run: For compilers to find qt@5 you may need to set: For pkg-config to find qt@5 you may need to set: ==> Analytics |
On another note, I wonder why it is pulling the QT5 include from the wrong place? |
I have the same qt@5 result that you have. I don't know why an error would refer to a different file path.
(Caveats & analytics are identical.) I don't remember installing any other qt (unless I was trying to install dependencies for another wallet), but
... Oh! Looking at that date and time that was last night and would have been right when I was installing dependencies for this Veil PR. ... I notice that the |
Yes, you have the same brew installed version, but what I mean is the error you posted earlier shows that the compiler is using a different QT on your system. We'll probably have to look into how to fix this to make sure it is using ***@***.*** even if a different QT is installed.
…________________________________
From: Sean Phillips ***@***.***>
Sent: May 7, 2021 4:27 PM
To: Veil-Project/veil ***@***.***>
Cc: eugene-so ***@***.***>; Assign ***@***.***>
Subject: Re: [Veil-Project/veil] Fix errors compiling for OSX catalina (#940)
I have the same ***@***.*** result that you have. I don't know why an error would refer to a different file path.
brew info ***@***.***
***@***.***: stable 5.15.2 (bottled) [keg-only]
Cross-platform application and UI framework
https://www.qt.io/
***@***.***/5.15.2 (10,688 files, 367.9MB)
Poured from bottle on 2021-04-09 at 11:35:54
From: ***@***.***
License: GFDL-1.3-only and GPL-2.0-only and GPL-3.0-only and LGPL-2.1-only and LGPL-3.0- Dependencies
Build: pkg-config ✔
==> Requirements
Build: Xcode ✔
Required: macOS >= 10.12 ✔
``` (Caveats & analytics are identical.)
—
You are receiving this because you were assigned.
Reply to this email directly, view it on GitHub<#940 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AQ7EU4ICRBLGATSKRLCUNGLTMRSLLANCNFSM44AJ3VCA>.
|
:/
on my Big Sur Mac, bearing in mind that it got just the same errors as the two Catalinas, and I still got the
and so on. Note that Qt5 is apparently getting included from the Cellar and then used in an "include" directory.
|
Please just try a quick test... If you rename your directory /usr/local/include/QtCore to something else for you still get the same error?
…________________________________
From: Sean Phillips ***@***.***>
Sent: Friday, May 7, 2021 8:06:12 PM
To: Veil-Project/veil ***@***.***>
Cc: eugene-so ***@***.***>; Assign ***@***.***>
Subject: Re: [Veil-Project/veil] Fix errors compiling for OSX catalina (#940)
:/
I just tried
./autogen.sh
./configure BDB_LIBS="-L${BDB_PREFIX}/lib -ldb_cxx-4.8" BDB_CFLAGS="-I${BDB_PREFIX}/include"
make -j4
on my Big Sur Mac, bearing in mind that it got just the same errors as the two Catalinas, and I still got the
fatal error: too many errors emitted, stopping now [-ferror-limit=]
11 warnings and 20 errors generated.
make[2]: *** [qt/test/test_veil_qt-addressbooktests.o] Error 1
make[2]: *** Waiting for unfinished jobs....
11 warnings and 20 errors generated.
make[2]: *** [qt/test/test_veil_qt-paymentservertests.o] Error 1
11 warnings and 20 errors generated.
and so on.
Note that Qt5 is apparently getting included from the Cellar and then used in an "include" directory.
In file included from ***@***.***/5.15.2/lib/QtCore.framework/Headers/QByteArray:1:
In file included from ***@***.***/5.15.2/lib/QtCore.framework/Headers/qbytearray.h:44:
In file included from /usr/local/include/QtCore/qrefcount.h:43:
In file included from /usr/local/include/QtCore/qatomic.h:41:
/usr/local/include/QtCore/qglobal.h:667:87: error: expected '>'
typename = std::enable_if_t<std::is_arithmetic_v<T> && std::is_arithmetic_v<U> &&```
—
You are receiving this because you were assigned.
Reply to this email directly, view it on GitHub<#940 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AQ7EU4MBUKQR7HHG2TF2SATTMSMBJANCNFSM44AJ3VCA>.
|
I really don't think that is the issue. In fact it was the Please bear in mind the note on the qt@5 installation that
|
I'm pretty sure the different qt headers is the issue and it should be fixed on the makefile side. Just thought it might be easy for you to test without the extr a qt, but I'll can also try to reproduce your issue when I have some time. Had a ton of family medical issues lately unfortunately. 😔
…________________________________
From: Sean Phillips ***@***.***>
Sent: Saturday, May 8, 2021 1:46:02 PM
To: Veil-Project/veil ***@***.***>
Cc: eugene-so ***@***.***>; Assign ***@***.***>
Subject: Re: [Veil-Project/veil] Fix errors compiling for OSX catalina (#940)
I really don't think that is the issue. /usr/local/include/QtCore is a symlink to QtCore -> ../Cellar/qt/6.0.3_2/include/QtCore
There's are dozens of Qt-related symlinks in there, including QtCore5Compat -> ../Cellar/qt/6.0.3_2/include/QtCore5Compat
In fact it was the brew install ... qt ... that installed this version. A few weeks earlier on a different coin ***@***.*** was installed for those depends. It's not entirely in scope for this PR, but I have a High Sierra Mac that had neither installed and I have installed ***@***.*** on it. (I think ***@***.*** might not be High Sierra compatible.) I will try the installation on that one for the moment, although being out of support there might be other issues.
—
You are receiving this because you were assigned.
Reply to this email directly, view it on GitHub<#940 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AQ7EU4PJBESNNAK3DYRLDBTTMWIHVANCNFSM44AJ3VCA>.
|
No worries. FYI, the High Sierra Mac that I specifically made sure that |
On a Catalina Mac I removed qt@6 and pyqt that depends on it, and tried to compile, but I got an error relating to files written with an older version of protoc. |
The brew version 3.15.8 seems correct. What do you get when you type this command?
I get libprotoc 3.15.8 |
Seems like bitcoin eventually completely dropped protobuf from their build |
What is happening with this PR? Seems like something broke with the automated build recently? |
I can approve the automated build again now. I see it is waiting. |
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 think the CPPFLAGS changes need to appear in the yml files used by gitian
https://github.com/Veil-Project/veil/blob/master/contrib/gitian-descriptors/gitian-linux.yml
This change should not impact the linux build. @codeofalltrades ^^^ |
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.
utACK d596243
Changes in XCode 11 Objective-C Runtime caused a build error. (Solution ported from bitcoin PR 16720) Comment out incompatible legacy dark mode fix. Updated instruction on how to build berkeley DB for Catalina. Specify qt@5 requirement in osx build instructions Installation of higher versions of qt causes build to fail. Update boost depends path to jfrog
d596243
to
f0120a0
Compare
Push Summary
Fix compilation issue on MacOS 10.15 Catalina machine.
Root Cause
Changes in XCode 11 Objective-C Runtime caused an error building on
MacOS 10.15 Catalina machine.
Updated instruction on how to build berkeley DB for macOS 10.15 Catalina.
Solution
Ported solution from bitcoin PR 16720.
Bounty PR
Bounty Payment Address
sv1qqp6aptgvgp9t9h8sgzkqmu6cgq2e20l9x6fsl5ask7t3ygy2jagftcpq0x5z0h522ca5h06qq3hx33pke00r7gjt3j24n896gf55y68ptrmjqqqqd8lz3
Unit Testing Results