Skip to content
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

Qt 5: revert 5.9.2; remove build temporary directory #31357

Merged
merged 15 commits into from
Nov 8, 2017

Conversation

ttuegel
Copy link
Member

@ttuegel ttuegel commented Nov 7, 2017

Motivation

This PR groups two unrelated changes to Qt 5.9 to reduce rebuilds.

Qt 5.9.2 breaks all Kirigami applications. KDE has requested that we revert one commit (which breaks SDDM) or downgrade to Qt 5.9.1.

It is no longer necessary to create a temporary symlink farm when building Qt 5 packages. This should make it easier to use nix-shell to develop Qt projects.

Testing

  • Tested using sandboxing (nix.useSandbox on NixOS, or option build-use-sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Fits CONTRIBUTING.md.

@ttuegel ttuegel self-assigned this Nov 7, 2017
@ttuegel ttuegel requested a review from FRidh as a code owner November 7, 2017 13:29
@ttuegel ttuegel merged commit 094d088 into NixOS:master Nov 8, 2017
@orivej
Copy link
Contributor

orivej commented Nov 9, 2017

It is no longer necessary to create a temporary symlink farm when building Qt 5 packages.

This is very welcome! Am I reading it right that you've accomplished this primarily with fixQtModulePaths and fixQtBuiltinPaths?

@ttuegel
Copy link
Member Author

ttuegel commented Nov 9, 2017

Most of the work is just to set QMAKEPATH correctly. fixQtModulePaths and fixQtBuiltinPaths are to clean up other developers' faulty assumptions. Qt developers tend to assume that all of Qt is installed to the same prefix as qmake (false) and that it is safe to install new components in the same prefix as qmake (also false).

orivej added a commit to orivej/nixpkgs that referenced this pull request Nov 9, 2017
Probably failing since NixOS#31357
@orivej orivej mentioned this pull request Nov 9, 2017
8 tasks
@orivej
Copy link
Contributor

orivej commented Nov 9, 2017

Thank you!

I've noticed that somehow cmd = $$system("type -p $$2") in defineTest(qtHaveModule) in qtbase.patch is impure, it executes type in /bin/sh on NixOS and Linux, and this fails on Linux when /bin/sh is dash because its type prints

$ type -p ls
-p: not found
ls is /bin/ls

and then qmake attemps to execute -p: not found uic is /nix/store/.... command -v prints just the path in both bash and dash, but maybe we could find a pure solution?

@bjornfor
Copy link
Contributor

bjornfor commented Nov 9, 2017

Replacing "type -p" with "command -v" makes it POSIX sh compatible, and thus it should work in dash.

@dtzWill
Copy link
Member

dtzWill commented Nov 9, 2017

@ttuegel looks like fe0ab94 (:+1: for the refactoring cleanup!) is incomplete for 5.6:

  • The old directories and files are still present, but at first glance appear unused.
  • At least one of the patches for 5.6 didn't make it into the corresponding uber-patch, namely for ICU 59, without which it currently doesn't build (cc mendeley: 1.17.10 -> 1.17.11 #31443).

Thanks for wrangling all this!

@ttuegel
Copy link
Member Author

ttuegel commented Nov 9, 2017

Replacing "type -p" with "command -v" makes it POSIX sh compatible, and thus it should work in dash.

Thanks for the tip!

At least one of the patches for 5.6 didn't make it into the corresponding uber-patch, namely for ICU 59, without which it currently doesn't build (cc #31443).

Ugh, this must have gone fubar when I merged master in; it certainly was building when I tested.

@ttuegel ttuegel mentioned this pull request Nov 10, 2017
8 tasks
@orivej
Copy link
Contributor

orivej commented Nov 10, 2017

Previously enableParallelBuilding defaulted to true. Why have you change it to false?

@lukeadams
Copy link
Contributor

Note: this does break qt5 on darwin.
Changes so far to get it to build:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants