Skip to content
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

Hang during release build with UEFI #412

Open
fmckeogh opened this issue Jan 22, 2024 · 0 comments
Open

Hang during release build with UEFI #412

fmckeogh opened this issue Jan 22, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@fmckeogh
Copy link
Contributor

Running cargo b -r -vv produces the following output where it hangs (seemingly indefinitely) at zero CPU usage:

[bootloader 0.11.5] warning: `bootloader-x86_64-bios-stage-2` (bin "bootloader-x86_64-bios-stage-2") generated 2 warnings
[bootloader 0.11.5]     Finished stage-2 [optimized] target(s) in 1.51s
[bootloader 0.11.5]    Replacing /home/fm208/.cargo/target/release/build/bootloader-ad4dca68f01168c6/out/bin/bootloader-x86_64-bios-stage-2
[bootloader 0.11.5]     Replaced package `bootloader-x86_64-bios-stage-2 v0.11.5 (/tmp/bootloader/bios/stage-2)` with `bootloader-x86_64-bios-stage-2 v0.11.5 (/tmp/bootloader/bios/stage-2)` (executable `bootloader-x86_64-bios-stage-2`)
[bootloader 0.11.5] warning: be sure to add `/home/fm208/.cargo/target/release/build/bootloader-ad4dca68f01168c6/out/bin` to your PATH to be able to run the installed binaries
[bootloader 0.11.5]     Finished stage-3 [optimized + debuginfo] target(s) in 1.52s
[bootloader 0.11.5]    Replacing /home/fm208/.cargo/target/release/build/bootloader-ad4dca68f01168c6/out/bin/bootloader-x86_64-bios-stage-3
[bootloader 0.11.5]     Replaced package `bootloader-x86_64-bios-stage-3 v0.11.5 (/tmp/bootloader/bios/stage-3)` with `bootloader-x86_64-bios-stage-3 v0.11.5 (/tmp/bootloader/bios/stage-3)` (executable `bootloader-x86_64-bios-stage-3`)
[bootloader 0.11.5] warning: be sure to add `/home/fm208/.cargo/target/release/build/bootloader-ad4dca68f01168c6/out/bin` to your PATH to be able to run the installed binaries
[bootloader 0.11.5]     Finished stage-4 [optimized + debuginfo] target(s) in 1.52s
[bootloader 0.11.5]    Replacing /home/fm208/.cargo/target/release/build/bootloader-ad4dca68f01168c6/out/bin/bootloader-x86_64-bios-stage-4
[bootloader 0.11.5]     Replaced package `bootloader-x86_64-bios-stage-4 v0.11.5 (/tmp/bootloader/bios/stage-4)` with `bootloader-x86_64-bios-stage-4 v0.11.5 (/tmp/bootloader/bios/stage-4)` (executable `bootloader-x86_64-bios-stage-4`)
[bootloader 0.11.5] warning: be sure to add `/home/fm208/.cargo/target/release/build/bootloader-ad4dca68f01168c6/out/bin` to your PATH to be able to run the installed binaries
[bootloader 0.11.5] cargo:rustc-env=BIOS_BOOT_SECTOR_PATH=/home/fm208/.cargo/target/release/build/bootloader-ad4dca68f01168c6/out/bin/bootloader-x86_64-bios-boot-sector.bin
[bootloader 0.11.5] cargo:rustc-env=BIOS_STAGE_2_PATH=/home/fm208/.cargo/target/release/build/bootloader-ad4dca68f01168c6/out/bin/bootloader-x86_64-bios-stage-2.bin
[bootloader 0.11.5] cargo:rustc-env=BIOS_STAGE_3_PATH=/home/fm208/.cargo/target/release/build/bootloader-ad4dca68f01168c6/out/bin/bootloader-x86_64-bios-stage-3.bin
[bootloader 0.11.5] cargo:rustc-env=BIOS_STAGE_4_PATH=/home/fm208/.cargo/target/release/build/bootloader-ad4dca68f01168c6/out/bin/bootloader-x86_64-bios-stage-4.bin
    Building [=======================> ] 133/135: bootloader(build)    

I believe this is cargo install boot loader-x86_64-uefi hanging in build_uefi_bootloader due to my usage of a globally shared target-dir set in ~/.cargo/config.toml.

I can fix this by creating a temporary directory and overriding the target directory to use that, or override the target directory to create one in the root of the bootloader directory, or some other place. Also happy to close this as a WONTFIX, but I know quite a few people use a global directory to avoid large build directories cluttering their drive in different locations.

@phil-opp phil-opp added the bug Something isn't working label Feb 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants