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

Glibc errors with v0.2.2 #858

Closed
4 of 11 tasks
ravenclaw900 opened this issue Jun 25, 2022 · 10 comments
Closed
4 of 11 tasks

Glibc errors with v0.2.2 #858

ravenclaw900 opened this issue Jun 25, 2022 · 10 comments

Comments

@ravenclaw900
Copy link

Checklist

Describe your issue

Cross returns glibc build script errors on aarch64-unknown-linux-musl and arm-unknown-linux-musleabihf with the new version.

What target(s) are you cross-compiling for?

aarch64-unknown-linux-musl, arm-unknown-linux-musleabihf

Which operating system is the host (e.g computer cross is on) running?

  • macOS
  • Windows
  • Linux / BSD
  • other OS (specify in description)

What architecture is the host?

  • x86_64 / AMD64
  • arm32
  • arm64 (including Mac M1)

What container engine is cross using?

  • docker
  • podman
  • other container engine (specify in description)

cross version

v0.2.2

Example

Armv6: https://github.com/ravenclaw900/DietPi-Dashboard/runs/7050663794
Aarch64: https://github.com/ravenclaw900/DietPi-Dashboard/runs/7050775525
Rebuild of previously working code: https://github.com/ravenclaw900/DietPi-Dashboard/runs/7051046368

Additional information / notes

From #724, running cargo clean or building without the cache didn’t help.

@Alexhuszagh
Copy link
Contributor

Alexhuszagh commented Jun 25, 2022

Can you give me detailed instructions on how to build your library? I've tried just the simple in the backend directory but I'm assuming I need to do something else. Edit: Nevermind, the Makefile was simple and clear.

cross build --release --target arm-unknown-linux-musleabihf --features compression

But if this does reproduce faithfully, this might be the best way we can diagnose and fix #724, so thank you.

@Alexhuszagh
Copy link
Contributor

This will take me a while to debug, and I'll be off tomorrow so it'll likely be Sunday or early next week, but it's not reproducing every time for arm-unknown-linux-musleabihf on my end.

I've run the following sequence:

git clone https://github.com/ravenclaw900/DietPi-Dashboard --depth 1
cd DietPi-Dashboard
cd src/frontend
yarn build
cd ../..
cp -r src/frontend/dist src/backend
cross build --release --target arm-unknown-linux-musleabihf --features compression

I'll try extensively debugging this, and sometimes issues arise when mixing toolchains so I'll try that too.

@Emilgardis
Copy link
Member

Emilgardis commented Jun 25, 2022

Related to #724, this one doesn't seem to be solved with a clean however

@Emilgardis

This comment was marked as outdated.

@Emilgardis
Copy link
Member

Removing all build-script-builds in target/release/deps and target/release/build is enough.

I believe this is related rust-lang/cargo#10367 (comment)

@ravenclaw900
Copy link
Author

@Emilgardis
Copy link
Member

Sorry, I meant remove all dependencies of the buildscript, so remove every folder with a build-script. I just removed the full folders.

This is essentially a cargo clean but worse.

@ravenclaw900
Copy link
Author

ravenclaw900 commented Jun 25, 2022

Alright, deleting all the build folders and all the .so files let it compile. Luckily, this should only be required when compiling dependencies with build scripts, so it can be removed most of the time.

@rafaelmaeuer
Copy link

I had this error when building binaries for different platforms with a bash-script. Deleting target/release after every build solved it for me.

@Alexhuszagh
Copy link
Contributor

Closing as a duplicate of #724.

@Emilgardis Emilgardis closed this as not planned Won't fix, can't repro, duplicate, stale Sep 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants