Skip to content

Build fixes#18

Open
phodina wants to merge 2 commits intotinythings:masterfrom
phodina:build-fixes
Open

Build fixes#18
phodina wants to merge 2 commits intotinythings:masterfrom
phodina:build-fixes

Conversation

@phodina
Copy link
Collaborator

@phodina phodina commented Feb 10, 2026

@isbm Let's start with simple things, then we can dispatch the Rust and Nix codebase ;-)

These two patches were in the the fixes branch for long time.

The uname fix caused previously:

make build-release
Building Microhop (release)
make[1]: Entering directory '/home/pethod/microhop'
RUSTFLAGS='-C target-feature=+crt-static' cargo build -p microhop --target unknown-unknown-linux-gnu --release
error: failed to run `rustc` to learn about target-specific information

Caused by:
  process didn't exit successfully: `rustc - --crate-name ___ --print=file-names -C target-feature=+crt-static --target unknown-unknown-linux-gnu --crate-type bin --crate-type rlib --crate-type dylib --crate-type cdylib --crate-type staticlib --crate-type proc-macro --print=sysroot --print=split-debuginfo --print=crate-name --print=cfg -Wwarnings` (exit status: 1)
  --- stderr
  error: error loading target specification: could not find specification for target "unknown-unknown-linux-gnu"
    |
    = help: run `rustc --print target-list` for a list of built-in targets

make[1]: *** [Makefile:9: microhop-release-static] Error 101
make[1]: Leaving directory '/home/pethod/microhop'
make: *** [Makefile:38: build-release] Error 2
$ uname -p
unknown
$ uname -m
x86_64

Second change is about the libc. If the target is statically linked then there should be no need to use gnu glibc and switch to musl libc instead.

Any thoughts?

Petr Hodina added 2 commits February 10, 2026 12:51
We are interested in machine architecture and want to get:

```
$ uname -m
aarch64

$ uname -m
x86_64
```

Signed-off-by: Petr Hodina <petr.hodina@protonmail.com>
Signed-off-by: Petr Hodina <petr.hodina@protonmail.com>
@isbm
Copy link
Member

isbm commented Feb 10, 2026

@phodina I think you are building it with musl here, that's why it might need either adding this thing too, or just leave it with glibc.

Also I've added you to this org, so you can approve checks yourself 😄

@isbm
Copy link
Member

isbm commented Feb 10, 2026

musl vs glibc: I completely agree here. Statically linking to glibc was rather exceptional necessity, than the right thing to do. If you can manage build get right — we can ditch glibc entirely (it is not even designed to be statically linked).

But if not, then we have to keep it for workflow checks. 😢

@phodina
Copy link
Collaborator Author

phodina commented Feb 10, 2026

Also I've added you to this org, so you can approve checks yourself 😄

Should make life easier for both of us 😄

But if not, then we have to keep it for workflow checks. 😢

That's the biggest pain point but will look into that

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.

2 participants