Skip to content

pixman: fixing aarch64-darwin build#200156

Merged
vcunat merged 1 commit intoNixOS:staging-nextfrom
vcunat:p/pixman-aarch64_darwin
Nov 9, 2022
Merged

pixman: fixing aarch64-darwin build#200156
vcunat merged 1 commit intoNixOS:staging-nextfrom
vcunat:p/pixman-aarch64_darwin

Conversation

@vcunat
Copy link
Member

@vcunat vcunat commented Nov 8, 2022

https://hydra.nixos.org/build/197830077

Things done
  • Built on platform(s)
    • no rebuild x86_64-linux
    • no rebuild aarch64-linux
    • no rebuild x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • 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/)
  • 22.11 Release Notes (or backporting 22.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
    • (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes
  • Fits CONTRIBUTING.md.

@vcunat
Copy link
Member Author

vcunat commented Nov 8, 2022

@ofborg build pixman

@vcunat vcunat mentioned this pull request Nov 8, 2022
13 tasks
@ofborg ofborg bot added 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux. labels Nov 8, 2022
@vcunat vcunat marked this pull request as draft November 8, 2022 07:38
@vcunat
Copy link
Member Author

vcunat commented Nov 8, 2022

I doesn't work :-(

@vcunat vcunat mentioned this pull request Nov 8, 2022
@vcunat
Copy link
Member Author

vcunat commented Nov 8, 2022

I suppose in the worst case we could split aarch64-darwin away, using the older version with security patch (we patch on 22.05).

@sternenseemann
Copy link
Member

Probably because gccStdenv has this:

      # Remove libcxx/libcxxabi, and add clang for AS if on darwin (it uses
      # clang's internal assembler).
      extraBuildInputs = lib.optional stdenv.hostPlatform.isDarwin clang.cc;

If the gcc assembler can't work on darwin, it seems like we would need to downgrade.

@vcunat vcunat force-pushed the p/pixman-aarch64_darwin branch from 9746374 to 19e3357 Compare November 8, 2022 10:56
@vcunat
Copy link
Member Author

vcunat commented Nov 8, 2022

@ofborg build pixman

@sternenseemann
Copy link
Member

FWIW the gccStdenv stuff was put together in 2017 (including using clang for AS), so who knows how it should be today: a5168fe

@vcunat vcunat force-pushed the p/pixman-aarch64_darwin branch 2 times, most recently from dec7332 to 7ae6f2f Compare November 8, 2022 11:06
@vcunat
Copy link
Member Author

vcunat commented Nov 8, 2022

@ofborg build pixman

@vcunat
Copy link
Member Author

vcunat commented Nov 8, 2022

@vcunat vcunat force-pushed the p/pixman-aarch64_darwin branch from 7ae6f2f to dec7332 Compare November 8, 2022 11:17
@vcunat
Copy link
Member Author

vcunat commented Nov 8, 2022

I haven't tried this one:
@ofborg build pixman

@vcunat
Copy link
Member Author

vcunat commented Nov 8, 2022

But really... someone actually interested in aarch64-darwin should be solving such problems.

@vcunat
Copy link
Member Author

vcunat commented Nov 8, 2022

@reckenrode
Copy link
Contributor

reckenrode commented Nov 8, 2022

I was able to get it to build by disabling ARM64 Neon on aarch64-darwin. This is using the default, clang-based stdenv.

diff --git a/pkgs/development/libraries/pixman/default.nix b/pkgs/development/libraries/pixman/default.nix
index 49f5fbe8815..bd807d603cb 100644
--- a/pkgs/development/libraries/pixman/default.nix
+++ b/pkgs/development/libraries/pixman/default.nix
@@ -18,7 +18,9 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libpng ];
 
-  configureFlags = lib.optional stdenv.isAarch32 "--disable-arm-iwmmxt";
+  configureFlags = lib.optional stdenv.isAarch32 "--disable-arm-iwmmxt"
+   # Disable until https://gitlab.freedesktop.org/pixman/pixman/-/issues/46 is resolved
+   ++ lib.optional (stdenv.isAarch64 && !stdenv.cc.isGNU) "--disable-arm-a64-neon";
 
   preConfigure = ''
     # https://gitlab.freedesktop.org/pixman/pixman/-/issues/62

@vcunat vcunat force-pushed the p/pixman-aarch64_darwin branch from dec7332 to f2ce2f6 Compare November 9, 2022 06:48
@vcunat vcunat force-pushed the p/pixman-aarch64_darwin branch from f2ce2f6 to 50d8cda Compare November 9, 2022 06:48
@vcunat
Copy link
Member Author

vcunat commented Nov 9, 2022

@ofborg build pixman

@vcunat vcunat changed the title pixman: use gccStdenv on aarch64 pixman: fixing aarch64-darwin build Nov 9, 2022
@vcunat vcunat marked this pull request as ready for review November 9, 2022 06:57
@vcunat vcunat merged commit 50d8cda into NixOS:staging-next Nov 9, 2022
@vcunat vcunat deleted the p/pixman-aarch64_darwin branch November 9, 2022 06:58
@vcunat
Copy link
Member Author

vcunat commented Nov 9, 2022

Thanks. OfBorg confirmed success, so I pushed it there with you as author.

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

Labels

10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants