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

cannot execute binary file: Exec format error #13432

Closed
2 tasks done
Trid-collab opened this issue Jun 16, 2022 · 2 comments
Closed
2 tasks done

cannot execute binary file: Exec format error #13432

Trid-collab opened this issue Jun 16, 2022 · 2 comments
Labels
bug Reproducible Homebrew/brew bug outdated PR was locked due to age

Comments

@Trid-collab
Copy link

brew config output

HOMEBREW_VERSION: 3.5.2
ORIGIN: https://github.com/Homebrew/brew
HEAD: fba051f98f609634ae4392d0053ddfc627f8cdb3
Last commit: 3 days ago
Core tap ORIGIN: https://github.com/Homebrew/homebrew-core
Core tap HEAD: 15a20097a72cf43b35be3415befb97638c34649d
Core tap last commit: 5 minutes ago
Core tap branch: master
HOMEBREW_PREFIX: /home/linuxbrew/.linuxbrew
HOMEBREW_CASK_OPTS: []
HOMEBREW_CORE_GIT_REMOTE: https://github.com/Homebrew/homebrew-core
HOMEBREW_MAKE_JOBS: 8
Homebrew Ruby: 2.6.8 => /home/linuxbrew/.linuxbrew/Homebrew/Library/Homebrew/vendor/portable-ruby/2.6.8_1/bin/ruby
CPU: octa-core 64-bit unknown_0x6_0x8c
Clang: N/A
Git: 2.36.1 => /home/linuxbrew/.linuxbrew/bin/git
Curl: 7.68.0 => /bin/curl
Kernel: Linux 4.4.0-19041-Microsoft x86_64 GNU/Linux
OS: Ubuntu 20.04.4 LTS (focal)
Host glibc: 2.31
/usr/bin/gcc: 9.4.0
/usr/bin/ruby: N/A
glibc: N/A
gcc@5: N/A
xorg: N/A

brew doctor output

brew doctor
Please note that these warnings are just used to help the Homebrew maintainers
with debugging if you file an issue. If everything you use Homebrew for is
working fine: please don't worry or file an issue; just ignore this. Thanks!

Warning: "config" scripts exist outside your system or Homebrew directories.
`./configure` scripts often look for *-config scripts to determine if
software packages are installed, and which additional flags to use when
compiling and linking.

Having additional scripts in your path can confuse software installed via
Homebrew if the config script overrides a system or Homebrew-provided
script of the same name. We found the following "config" scripts:
  /home/tri/.pyenv/shims/python-config
  /home/tri/.pyenv/shims/python3-config
  /home/tri/.pyenv/shims/python3.10-config

Verification

  • I ran brew update and am still able to reproduce my issue.
  • I have resolved all warnings from brew doctor and that did not fix my problem.

What were you trying to do (and why)?

I am doing a fresh install of brew on my WSL2 setup. After installing fd, exa, ripgrep and trying to run the these commands I am getting the following errors:

-bash: /home/linuxbrew/.linuxbrew/bin/fd: cannot execute binary file: Exec format error
-bash: /home/linuxbrew/.linuxbrew/bin/exa: cannot execute binary file: Exec format error
-bash: /home/linuxbrew/.linuxbrew/bin/ripgrep: cannot execute binary file: Exec format error

Whereas the other installs like git or bpytop or mc has been working fine without any issues

Is there something I am missing here

What happened (include all command output)?

fd
zsh: exec format error: fd

exa
zsh: exec format error: exa

and so on

What did you expect to happen?

Expecting commands like fd, exa etc to run

Step-by-step reproduction instructions (by running brew commands)

brew install fd 
fd 

or brew install exa 
exa
@Trid-collab Trid-collab added the bug Reproducible Homebrew/brew bug label Jun 16, 2022
@gromgit
Copy link
Contributor

gromgit commented Jun 16, 2022

I don't do Windows, but comparing the Kernel line of brew config against microsoft/WSL#4555 (comment), it sure looks like you're actually running WSL1, which neatly explains the problem you're seeing.

Alternatively, try running ls /run/WSL/. If you get a File not found, that confirms you're running WSL1.

@Trid-collab
Copy link
Author

Thank you. The WSL version was indeed was the issue. I had installed in a new laptop so I hoped that WSL2 would be installed by default.

@github-actions github-actions bot added the outdated PR was locked due to age label Jul 17, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 17, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Reproducible Homebrew/brew bug outdated PR was locked due to age
Projects
None yet
Development

No branches or pull requests

2 participants