-
-
Notifications
You must be signed in to change notification settings - Fork 14.2k
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
nixos/modules/installer/sd-card/sd-image-mips64el.nix: init #194153
Conversation
Okay, this builds again. I will try booting it tonight. |
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
@ofborg build pkgsCross.octeon.linux |
|
Switched branches to |
@ofborg build pkgsCross.octeon.linux_latest |
|
||
nixpkgs.buildPlatform = builtins.currentSystem; | ||
nixpkgs.hostPlatform = lib.systems.examples.octeon; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure I can review anything else, but there's at least this.
This would need to use mips64el
(since it's the name of the file) or rename the file for octeon
. I'd prefer targeting the generic mips64el
and users needing octeon can provide a host platform.
But actually, with a bit more thought, SD/ISO builds should be made assuming native builds. Cross-compiling usage is done externally through configuring platforms. Look at all the other existing sd image configs. So actually removing the lines is the correct resolution here.
nixpkgs.buildPlatform = builtins.currentSystem; | |
nixpkgs.hostPlatform = lib.systems.examples.octeon; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@roberth is insisting that it be done this way -- through module parameters.
Perhaps one of you can convince the other.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(I left a comment on the other PR)
There is no convincing to do, and we agree, and this comment here agrees with the idea that cross-compilation is configured through the NixOS configuration.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This module is a "profile" module that's specifically about mips64el, so it does make sense to set a default hostPlatform
, but buildPlatform
is not specific to mips64el hosts and therefore shouldn't be set here.
…latform p11-kit does not cross-compile. This prevents the NixOS installer from cross-compiling. Therefore, we mark it broken in this case and omit it.
The libnvme documentation fails to build when cross compiling, with: FAILED: doc/nvme_admin_opcode.2 /nix/store/qcvcsink30f4wh36jzg3rbvkshwzj38c-meson-1.1.1/bin/meson --internal exe --capture doc/nvme_admin_opcode.2 -- /build/source/doc/kernel-doc -module libnvme -man -function nvme_admin_opcode ../doc/../src/nvme/types.h Traceback (most recent call last): File "/nix/store/qcvcsink30f4wh36jzg3rbvkshwzj38c-meson-1.1.1/bin/meson", line 6, in <module> File "/nix/store/qcvcsink30f4wh36jzg3rbvkshwzj38c-meson-1.1.1/lib/python3.10/site-packages/mesonbuild/mesonmain.py", line 30, in <module> from . import mlog ImportError: cannot import name 'mlog' from 'mesonbuild' (/nix/store/qcvcsink30f4wh36jzg3rbvkshwzj38c-meson-1.1.1/lib/python3.10/site-packages/mesonbuild/__init__.py) [703/811] Generating doc/nvme_identify_cns_man with a custom command (wrapped by meson to capture output) FAILED: doc/nvme_identify_cns.2 /nix/store/qcvcsink30f4wh36jzg3rbvkshwzj38c-meson-1.1.1/bin/meson --internal exe --capture doc/nvme_identify_cns.2 -- /build/source/doc/kernel-doc -module libnvme -man -function nvme_identify_cns ../doc/../src/nvme/types.h Traceback (most recent call last): File "/nix/store/qcvcsink30f4wh36jzg3rbvkshwzj38c-meson-1.1.1/bin/meson", line 6, in <module> File "/nix/store/qcvcsink30f4wh36jzg3rbvkshwzj38c-meson-1.1.1/lib/python3.10/site-packages/mesonbuild/mesonmain.py", line 30, in <module> from . import mlog
Rebased. |
This cross-compiles a complete NixOS installer image. The image is built specifically for Cavium Octeon chips, because currently these are the Mips64 products that are commercially available: you can order a Ubiquiti Edgerouter from Amazon and have it the next day. All of Debian's non-Longsoon MIPS builders are Octeons: https://wiki.debian.org/MIPSPort Co-authored-by: Samuel Dionne-Riel <[email protected]>
The full installer builds from
|
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/binary-cache-for-riscv64/44934/3 |
Description of changes
This cross-compiles a complete NixOS installer image.
Includes:
For cross compilation, you will need: