!ayCRiZriCVtuCUpeLp:nixos.org

Nix Cross Compiling

398 Members
92 Servers

Load older messages


SenderMessageTime
7 Oct 2024
@memegames99:matrix.org@memegames99:matrix.org removed their display name memegames99.00:05:53
@memegames99:matrix.org@memegames99:matrix.org left the room.00:06:12
@suskeyhose:matrix.orgsrasuSo I'm trying to get this project to have a builder as well for windows, and it seems like the spliced packages doesn't have mkDerivation? Do I just use the llvmPackages_18.stdenv.mkDerivation even for the crosscompiled package?01:37:05
@artturin:matrix.orgArtturin
In reply to @suskeyhose:matrix.org
So I'm trying to get this project to have a builder as well for windows, and it seems like the spliced packages doesn't have mkDerivation? Do I just use the llvmPackages_18.stdenv.mkDerivation even for the crosscompiled package?
What?
02:14:08
@suskeyhose:matrix.orgsrasuI had the pkgs' value we discussed earlier and I was trying to make a package derivation for my flake doing the build I got working with that devshell, but mkDerivation says it's unresolved/not present on that set.02:15:56
@artturin:matrix.orgArtturin Use the stdenv from the package you're overriding something.stdenv 02:18:45
@artturin:matrix.orgArtturinDidn't see your message02:21:04
@artturin:matrix.orgArtturin
In reply to @suskeyhose:matrix.org
I had the pkgs' value we discussed earlier and I was trying to make a package derivation for my flake doing the build I got working with that devshell, but mkDerivation says it's unresolved/not present on that set.
mkDerivation isn't a top-level attribute, it's in stdenv
02:21:32
@suskeyhose:matrix.orgsrasuaah02:21:40
@suskeyhose:matrix.orgsrasuthanks, dunno how i missed that in the docs02:22:15
@artturin:matrix.orgArtturin

By the way, if you wanted to override something which goes in nativeBuildInputs you'll want to get the package from buildPackages/pkgsBuildHost(different names for the same thing for historical reasons) because override,overrideAttrs don't preserve __spliced https://github.com/NixOS/nixpkgs/issues/132651

If you wanted a overriden hello in nativeBuildInputs here https://git.sr.ht/~srasu/c_template/tree/nix/pkgs-cross-windows-build/item/flake.nix#L106
You'd do (pkgs'.buildPackages. hello.overrideAttrs(...))

02:36:30
@suskeyhose:matrix.orgsrasuoh awesome!02:37:20
@suskeyhose:matrix.orgsrasuthanks for the tip02:37:28
@artturin:matrix.orgArtturinpkgs'.pkgsBuildBuild.hello for something that goes in depsBuildBuild02:37:50
@artturin:matrix.orgArtturinYou can use these for reference https://github.com/NixOS/nixpkgs/blob/6abc2cbbc4f9d151b46f4d87cae0e6a2b1b20f49/pkgs/stdenv/generic/make-derivation.nix#L304-L31602:39:14
@artturin:matrix.orgArtturin* pkgs'.pkgsBuildBuild.hello for something that goes inside depsBuildBuild (which would be a better place fkr hello because its not a compiler or compiler adjacent tool which cares about the hostPlatform or targetPlatform)02:45:51
@artturin:matrix.orgArtturin* pkgs'.pkgsBuildBuild.hello for something that goes inside depsBuildBuild (which would be a better place for hello because its not a compiler or compiler adjacent tool which cares about the hostPlatform or targetPlatform)02:46:04
@lehmanator:tchncs.deSam Lehman changed their profile picture.14:24:43
8 Oct 2024
@colemickens:matrix.orgcolemickens
  /build/.attr-0l2nkwhif96f51f4amnlf414lhl4rv9vh8iffyp431v6s28gsr90: line 3: /nix/store/fj1212b8v89zxbd20592kp7v8blzgmdx-shared-mime-info-aarch64-unknown-linux-gnu-2.4/bin/update-mime-database: cannot execute binary file: Exec format error
01:43:46
@colemickens:matrix.orgcolemickens:(01:43:47
@colemickens:matrix.orgcolemickens shared-mine-info cross compilation seems broken 01:44:09
@colemickens:matrix.orgcolemickenswhich seems just depended on by HM.01:48:29
* @colemickens:matrix.orgcolemickens secretly wishes cross was more blocking but also that sounds tough01:48:56
@artturin:matrix.orgArtturin
In reply to @colemickens:matrix.org
shared-mine-info cross compilation seems broken
Builds fine here
01:58:48
@colemickens:matrix.orgcolemickenshmmmmmmm02:03:53
@colemickens:matrix.orgcolemickensthanks for the heads up, I'll dig in more02:03:59
@artturin:matrix.orgArtturinIs the error in shared-mime-info or a dependant02:04:41
@colemickens:matrix.orgcolemickens
error: builder for '/nix/store/32cd10a9zgxs6aik4n3pdla7j0dqshhv-home-manager-path.drv' failed with exit code 126;
       last 2 log lines:
       > created 315 symlinks in user environment
       > /build/.attr-0l2nkwhif96f51f4amnlf414lhl4rv9vh8iffyp431v6s28gsr90: line 3: /nix/store/fj1212b8v89zxbd20592kp7v8blzgmdx-shared-mime-info-aarch64-unknown-linux-gnu-2.4/bin/update-mime-database: cannot execute binary file: Exec format error
       For full logs, run 'nix log /nix/store/32cd10a9zgxs6aik4n3pdla7j0dqshhv-home-manager-path.drv'.
02:07:01
@artturin:matrix.orgArtturin4h ago https://github.com/nix-community/home-manager/commit/038630363e7de57c36c417fd2f5d7c14773403e402:08:46
@artturin:matrix.orgArtturinThey should be using buildPackages as the default02:08:56

Show newer messages


Back to Room ListRoom Version: 6