Skip to content

[staging-next] qt6.qtdeclarative: slightly less bad hack to make it build on Darwin again#334087

Merged
K900 merged 1 commit intoNixOS:staging-nextfrom
K900:qtdeclarative-darwin-deps
Aug 13, 2024
Merged

[staging-next] qt6.qtdeclarative: slightly less bad hack to make it build on Darwin again#334087
K900 merged 1 commit intoNixOS:staging-nextfrom
K900:qtdeclarative-darwin-deps

Conversation

@K900
Copy link
Copy Markdown
Contributor

@K900 K900 commented Aug 12, 2024

Description of changes

Not sure why it broke, could be the recent cmake changes?

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)
    • sandbox = relaxed
    • sandbox = true
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 24.11 Release Notes (or backporting 23.11 and 24.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

@ofborg ofborg bot added the 6.topic: darwin Running or building packages on Darwin label Aug 12, 2024
cmakeFlags = [
"-DQt6ShaderToolsTools_DIR=${pkgsBuildBuild.qt6.qtshadertools}/lib/cmake/Qt6ShaderTools"
# for some reason doesn't get found automatically on Darwin
"-DPython_EXECUTABLE=${lib.getExe pkgsBuildBuild.python3}"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: lib.cmakeFeature

@ofborg ofborg bot added 10.rebuild-darwin: 101-500 This PR causes between 101 and 500 packages to rebuild on Darwin. 10.rebuild-linux: 501+ This PR causes many rebuilds on Linux and should normally target the staging branches. 10.rebuild-linux: 501-1000 This PR causes many rebuilds on Linux and should normally target the staging branches. labels Aug 12, 2024
@paparodeo
Copy link
Copy Markdown
Contributor

paparodeo commented Aug 12, 2024

FWIW i was unable to reproduce on x64 darwin (big sur) building with and without the sandbox enabled.

@NickCao
Copy link
Copy Markdown
Member

NickCao commented Aug 12, 2024

FWIW i was unable to reproduce on x64 darwin (big sur) building with and without the sandbox enabled.

Might be on the wrong branch? This is targeting staging-next. https://hydra.nixos.org/eval/1808219?filter=qt6.qtdeclarative&compare=1808209&full=


qtModule {
pname = "qtdeclarative";
strictDeps = !stdenv.isDarwin; # fails to detect python3 otherwise
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any idea why?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No idea, someone with an actual Darwin machine may want to investigate.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

8c9c8ad looks suspicious.

@paparodeo
Copy link
Copy Markdown
Contributor

FWIW i was unable to reproduce on x64 darwin (big sur) building with and without the sandbox enabled.

Might be on the wrong branch? This is targeting staging-next. https://hydra.nixos.org/eval/1808219?filter=qt6.qtdeclarative&compare=1808209&full=

i did check i was on staging-next and that the cmake changes were in the tree i was using. will double check once i have access to the machine later.

@paparodeo
Copy link
Copy Markdown
Contributor

paparodeo commented Aug 13, 2024

FWIW i was unable to reproduce on x64 darwin (big sur) building with and without the sandbox enabled.

Might be on the wrong branch? This is targeting staging-next. https://hydra.nixos.org/eval/1808219?filter=qt6.qtdeclarative&compare=1808209&full=

i did check i was on staging-next and that the cmake changes were in the tree i was using. will double check once i have access to the machine later.

$ git status
On branch staging-next
Your branch is up to date with 'origin/staging-next'.
$ git log -n 1 
commit 45080a955932de96b78c631fe9b3518a4e7bf8a8 (HEAD -> staging-next, origin/staging-next)
Merge: 12873fb718e4 2d2404abaf13
Author: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Date:   Sat Aug 10 18:01:08 2024 +0000

    Merge master into staging-next
$ ls pkgs/by-name/cm/cmake/000-nixpkgs-cmake-prefix-path.diff
pkgs/by-name/cm/cmake/000-nixpkgs-cmake-prefix-path.diff
$ nix-build -A qt6.qtdeclarative
...
/nix/store/kasrw47ln7w6gs3a7v9plca4bvq0q2cd-qtdeclarative-6.7.2
$ uname -a
Darwin odel.lan 20.6.0 Darwin Kernel Version 20.6.0: Thu Jul  6 22:12:47 PDT 2023; root:xnu-7195.141.49.702.12~1/RELEASE_X86_64 x86_64 i386 Darwin

[edit] yeah, idk. i can just comment out the line with python3 and the build works. python3 is not required. i do the same thing on linux and the build breaks. if someone is able to reproduce, printing out PATH and NIXPKGS_CMAKE_PREFIX_PATH in preConfigure would be somewhat helpful, also, type -a python3.

@K900
Copy link
Copy Markdown
Contributor Author

K900 commented Aug 13, 2024

Let's just merge this for now and investigate later.

@K900 K900 merged commit e50d3a5 into NixOS:staging-next Aug 13, 2024
@K900 K900 deleted the qtdeclarative-darwin-deps branch July 27, 2025 10:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

6.topic: darwin Running or building packages on Darwin 10.rebuild-darwin: 101-500 This PR causes between 101 and 500 packages to rebuild on Darwin. 10.rebuild-linux: 501-1000 This PR causes many rebuilds on Linux and should normally target the staging branches. 10.rebuild-linux: 501+ This PR causes many rebuilds on Linux and should normally target the staging branches.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants