Allow supplying of prebuilt bootloader to avoid nested Cargo builds
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 48/100
- Tipo de issue
- Nueva funcionalidad
- Claridad
- Bastante claro
- Estado de actividad
- Activo
- Stack tecnológico
- rust
- Área
- build-system
Línea de trabajo
Start with build.rs at the linked lines, where the UEFI bootloader is built, and trace how its output is copied; check the corresponding BIOS stages for the same pattern. Compare the two approaches raised in the issue: accepting a prebuilt EFI path or using Cargo artifact dependencies. Done means the build can use a separately built bootloader without a nested Cargo build, with equivalent support for relevant BIOS stages.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Hi there,
Thanks for the wonderful crate.
I've been trying to build my Rust kernel using Nix (it makes building my userspace and ramdisk a lot easier).
Nix runs builds in a sandbox without any network access unless the output of the build is guaranteed to match a hash (which it provides utilities for doing from a Cargo lock file). Basically this works best if Nix is what invokes Cargo and it has access to the lock file.
Basically, bootloader's invocation of Cargo from its build script causes problems here, since it builds the bootloader-x86_64-uefi crate (I use UEFI only but I believe something similar happens for BIOS builds), and though it runs --locked, there isn't really a good way to get Nix to "reach" that lock file.
What I would like is a way to supply a prebuilt .efi file, made by a Cargo build running separately, to the build script (by say an environment variable holding a path to the built EFI).
So instead of building the EFI in the build script, it could be done outside and copied into that output directory. If this sounds sensible, I would be willing to open a PR to do this. I would believe similar options would need to be made for each of the BIOS stages for consistency.
Alternatively, since this crate requires a nightly compiler anyway, if this crate used artifact binary dependencies to build each of the bootloader stages and used those built versions in the compiler since that means the same lockfile is used for those builds. This would solve the problem completely, I have tested that Nix can build Rust packages with artifact dependencies just fine with no extra configurations. If this is feasible it would likely be preferable.
- Lenguaje dominante
- Rust
- Estrellas
- 1.7k
- Forks
- 241
- Merge medio
- 2 d 19 h
- PR fusionados (30 d)
- 2
Preparar el entorno
Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de rust-osdev/bootloader
-
FAT32 UEFI compatibilityAbierto
Dificultad 4/5 3-5 días Aptitud para principiantes 48/100
rust-osdev/bootloader#587 · 2 comentarios ·
-
help wanted
Dificultad 3/5 1-2 días Aptitud para principiantes 67/100
rust-osdev/bootloader#581 · 2 comentarios ·
-
No boot on real hardwareAbierto
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
rust-osdev/bootloader#573 · 5 comentarios ·
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 20/100
rust-osdev/bootloader#555 · 2 comentarios ·
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 30/100
rust-osdev/bootloader#534 · 3 comentarios ·
Todos los issues de rust-osdev/bootloader
Issues similares
-
claim
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
Nixitov/Riptide-Native#946 ·
Los mantenedores suelen responder en 1 día
-
area: ai-assistants documentation help wanted
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
BetaBots-LLC/latticegate#17 ·
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 94/100
storytold/craft-libs#5594 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
Los mantenedores suelen responder en 1 día
-
听歌识曲历史跳转后对应音源界面无法返回Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
LingyunStudio/RustMusic#16 ·