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

Building with mode flag fails if config gpr file does not exist #1129

Closed
onox opened this issue Aug 2, 2022 · 2 comments
Closed

Building with mode flag fails if config gpr file does not exist #1129

onox opened this issue Aug 2, 2022 · 2 comments
Labels
type: bug Something isn't working
Milestone

Comments

@onox
Copy link
Contributor

onox commented Aug 2, 2022

If alr build is run with one of the build mode flags, it will fail with the message "unknown project file: "config/*_config"" if the config gpr file does not exist:

$ alr build --release
ⓘ Building orka_numerics/orka_numerics.gpr...
orka_numerics.gpr:1:06: unknown project file: "config/orka_numerics_config"
orka_numerics.gpr:6:60: unknown package or project "Orka_Numerics_Config"
orka_numerics.gpr:31:38: unknown package or project "Orka_Numerics_Config"
orka_numerics.gpr:40:40: unknown package or project "Orka_Numerics_Config"

If I then run alr build without any flag it starts building.

I have also noticed that sometimes it doesn't update the Build_Profile variable or it does but then it doesn't update the Ada_Compiler_Switches.

$ alr build --validation
ⓘ Building orka_numerics/orka_numerics.gpr...    
Build finished successfully in 0.42 seconds.

$ alr build --release
ⓘ Building orka_numerics/orka_numerics.gpr...    
Build finished successfully in 0.42 seconds.

Right now Build_Profile is "release", but Ada_Compiler_Switches contain "-Og" instead of "-O3".

I'm using following build switches:

[build-switches]
validation.compile_checks = "warnings"
"*".style_checks = ["-gnatygAO-Is"]

(Without it I still get "-Og").

@mosteo
Copy link
Member

mosteo commented Aug 3, 2022

It looks like the logic to detect when to generate the config files is flaky. Thanks for the report.

@mosteo mosteo added the type: bug Something isn't working label Aug 3, 2022
@mosteo mosteo added this to the 1.3 milestone Aug 3, 2022
@mosteo mosteo modified the milestones: 1.3, 2.0 Sep 12, 2023
@mosteo
Copy link
Member

mosteo commented Sep 13, 2023

Should be fixed after #1438. Please reopen if you find otherwise.

@mosteo mosteo closed this as completed Sep 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants