Skip to content

build: If both Qt4 and Qt5 are installed, use Qt5#6938

Merged
laanwj merged 1 commit into
bitcoin:masterfrom
laanwj:2015_11_prefer_qt5
Nov 4, 2015
Merged

build: If both Qt4 and Qt5 are installed, use Qt5#6938
laanwj merged 1 commit into
bitcoin:masterfrom
laanwj:2015_11_prefer_qt5

Conversation

@laanwj

@laanwj laanwj commented Nov 4, 2015

Copy link
Copy Markdown
Member

If both Qt4 and Qt5 development headers are installed, use Qt5. Building against Qt5 should be encouraged as that is where active development happens.

@maflcko

maflcko commented Nov 4, 2015

Copy link
Copy Markdown
Member

Concept ACK

@paveljanik

Copy link
Copy Markdown
Contributor

Please also remove --with-gui from ./configure --with-gui=qt5 in doc/build-osx.md.

@fanquake

fanquake commented Nov 4, 2015

Copy link
Copy Markdown
Member

Concept ACK

On Wednesday, November 4, 2015, paveljanik notifications@github.com wrote:

Please also remove --with-gui from ./configure --with-gui=qt5 in doc/
build-osx.md.


Reply to this email directly or view it on GitHub
#6938 (comment).

@laanwj

laanwj commented Nov 4, 2015

Copy link
Copy Markdown
Member Author

Please also remove --with-gui from ./configure --with-gui=qt5 in doc/build-osx.md.

But that means you may end up without a GUI at all, if the proper dependencies cannot be found. Is that the intended behavior? If not, actively setting a GUI makes sense

@jonasschnelli

Copy link
Copy Markdown
Contributor

utACK!

Please also remove --with-gui from ./configure --with-gui=qt5 in doc/build-osx.md.

We should definitively keep this.

@paveljanik

Copy link
Copy Markdown
Contributor

@laanwj IMO configure without arguments should build whatever it can build (based on dependencies, and warn user that it can't build GUI because of missing deps) and you should be able to disable GUI with --disable-gui if you want to save compile time, do not care about GUI etc. Selecting which UI has sense only when you can and should select one of supported systems, but as we deprecate Qt4...

@jonasschnelli

Copy link
Copy Markdown
Contributor

I think ./configure should only build the UI if the user did pass the --with-gui argument. In self build environment, i guess most users like to build bitcoin-core without the UI. But no strong opinion.

@paveljanik

Copy link
Copy Markdown
Contributor

I'm happy with setting the --with-gui default to no, but when --with-gui is used, please do not require an argument and autoselect the highest qt available.

@jonasschnelli

Copy link
Copy Markdown
Contributor

agree with @paveljanik

@laanwj

laanwj commented Nov 4, 2015

Copy link
Copy Markdown
Member Author

I have no clue what happens if you do --with-gui without argument. Have you tested? You can do --without-gui if you want to build without GUI.

The default if you don't provide it is auto, which means that (with this pull), it will

  • build with Qt5 if Qt5 is installed
  • otherwise, build with Qt4 if Qt4 is installed
  • otherwise, build without GUI

I have no intention of changing the semantics there. The only thing I'm changing is what Qt is selected by default, which IMO should be Qt5.

@jonasschnelli

Copy link
Copy Markdown
Contributor

Agree. --with-gui already does auto-select. But right,.. as @laanwj mention, this PR would only change this auto-behavior to Qt5 instead of Qt4.

Do we need adaptation here:?
https://github.com/bitcoin/bitcoin/blob/master/build-aux/m4/bitcoin_qt.m4#L53

@laanwj laanwj force-pushed the 2015_11_prefer_qt5 branch from 7701b0e to dbacc69 Compare November 4, 2015 15:19
@laanwj

laanwj commented Nov 4, 2015

Copy link
Copy Markdown
Member Author

@jonasschnelli good catch, updated

If both Qt4 and Qt5 development headers are installed, use Qt5. Building
against Qt5 should be encouraged as that is where active development
happens.
@paveljanik

Copy link
Copy Markdown
Contributor

I just want to save the work again at qt6 bumb: just do not document the qt version in the doc/build-osx.md the Qt version at all.

@laanwj laanwj merged commit dbacc69 into bitcoin:master Nov 4, 2015
laanwj added a commit that referenced this pull request Nov 4, 2015
dbacc69 build: If both Qt4 and Qt5 are installed, use Qt5 (Wladimir J. van der Laan)
@luke-jr

luke-jr commented Nov 5, 2015

Copy link
Copy Markdown
Member

Shouldn't the preferred Qt be based on what the OS default is configured for...?

@laanwj

laanwj commented Nov 5, 2015

Copy link
Copy Markdown
Member Author

@luke-jr That may have been a better choice in the beginning, but right now, we're slowly moving away from Qt4. I expect to retain compatibility for the foreseeable future, but the GUI experience may be worse than Qt5, so we pick what is best for us.

@maflcko

maflcko commented Nov 5, 2015

Copy link
Copy Markdown
Member

Note: I need to set --with-gui=qt4 or merge #6248, to get this working on fedora.

@maflcko

maflcko commented Nov 5, 2015

Copy link
Copy Markdown
Member

Tested ACK. Nice, bitcoin-qt looks so much more clean when built with qt5! (No missing icons, styles, etc.)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants