Skip to content

fix: Fix compilation with only the alloc feature - #342

Merged
martin-hughes merged 1 commit into
rust-osdev:mainfrom
mkroening:fix-alloc
Sep 6, 2026
Merged

fix: Fix compilation with only the alloc feature#342
martin-hughes merged 1 commit into
rust-osdev:mainfrom
mkroening:fix-alloc

Conversation

@mkroening

Copy link
Copy Markdown
Member
$ cargo check --no-default-features --features alloc
error[E0433]: cannot find module or crate `aml` in this scope
   --> src/lib.rs:314:9
    |
314 |     Aml(aml::AmlError),
    |         ^^^ use of unresolved module or unlinked crate `aml`
    |
note: found an item that was configured out
   --> src/lib.rs:57:9
    |
 56 | #[cfg(feature = "aml")]
    |       --------------- the item is gated behind the `aml` feature
 57 | pub mod aml;
    |         ^^^
help: to make use of source file src/aml/mod.rs, use `mod aml` in this file to declare the module
    |
 48 + mod aml;
    |

```
$ cargo check --no-default-features --features alloc
error[E0433]: cannot find module or crate `aml` in this scope
   --> src/lib.rs:314:9
    |
314 |     Aml(aml::AmlError),
    |         ^^^ use of unresolved module or unlinked crate `aml`
    |
note: found an item that was configured out
   --> src/lib.rs:57:9
    |
 56 | #[cfg(feature = "aml")]
    |       --------------- the item is gated behind the `aml` feature
 57 | pub mod aml;
    |         ^^^
help: to make use of source file src/aml/mod.rs, use `mod aml` in this file to declare the module
    |
 48 + mod aml;
    |
```
@martin-hughes

Copy link
Copy Markdown
Contributor

Thanks @mkroening - I’m surprised & disappointed (and apologise to you) that the pipeline didn’t catch this, so I’ll take a look at that in more detail tomorrow.

Your edit looks fine so if Isaac doesn’t get there first I’ll test it and merge tomorrow.

@IsaacWoods

Copy link
Copy Markdown
Member

Yes - I also had a look because I thought we tested this... and we seem to? I'm not sure what is going on with the Action there.

Thanks very much to both of you, Martin and Martin. I'm not at a computer I can test this myself at but this looks fine to me.

martin-hughes added a commit that referenced this pull request Sep 6, 2026
We had a bit of a mystery about why #342 didn't get caught beforehand.
The reason was that the $FEATURES environment variable was never being
set.

Set that variable. This will cause the build to fail. Then we should see
#342 fix it.
@martin-hughes

Copy link
Copy Markdown
Contributor

Tests OK so will merge. Thanks again @mkroening

@martin-hughes
martin-hughes merged commit f80b94f into rust-osdev:main Sep 6, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants