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

Executable not found while using toolchain with foreign_rules_cc #76

Open
todd-enf opened this issue May 16, 2024 · 0 comments
Open

Executable not found while using toolchain with foreign_rules_cc #76

todd-enf opened this issue May 16, 2024 · 0 comments

Comments

@todd-enf
Copy link

While working to integrate a cross-compilation toolchain supported by bazel_embedded, I encountered issues where executing any of the compilation tools (gcc, ar, strip, etc.) would fail with "File or directory not found", when the wrapper script attempts to invoke the actual executable.

Digging into the issue a little more, I found that the wrapper scripts rely on a path relative to the "root" of the sandbox to call the executable themselves. The foreign_rules_cc (in particular the make rule), however changes it's execution directory to better support the make, etc. invocations, which then make the relative path included in the wrapper scripts invalid. This results in the given targets failing to compile.

Reproduction Steps:

Use a bazel_embedded toolchain against a make rule from the foreign_rules_cc toolchain.

Are there any known workarounds/solutions for such an issue?

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

No branches or pull requests

1 participant