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

"Branch out of range" error when compiling to mips_64 with clang-4.0 #10

Open
Bowen-n opened this issue Apr 12, 2023 · 1 comment
Open

Comments

@Bowen-n
Copy link

Bowen-n commented Apr 12, 2023

I have successfully cross-compiled most of the gnu software following the workflow. However, for some of the software, "Branch out of range" error occurs when compiling to mips_64 with clang-4.0 (as well as clang-obfus-xxx).

For example, when compiling tar-1.30 with clang-4.0 (O0) to mips_64, it shows:

...
Making install in gnu
make[1]: Entering directory '/home/binkit/dataset/gnu/sources/tar/tar-1.30_clang-4.0_mips_64_O0_normal/gnu'
make  install-recursive
make[2]: Entering directory '/home/binkit/dataset/gnu/sources/tar/tar-1.30_clang-4.0_mips_64_O0_normal/gnu'
make[3]: Entering directory '/home/binkit/dataset/gnu/sources/tar/tar-1.30_clang-4.0_mips_64_O0_normal/gnu'
  CC       parse-datetime.o
/tmp/parse-datetime-41f91c.s: Assembler messages:
/tmp/parse-datetime-41f91c.s:44857: Error: branch out of range
/tmp/parse-datetime-41f91c.s:44960: Error: branch out of range
/tmp/parse-datetime-41f91c.s:45061: Error: branch out of range
/tmp/parse-datetime-41f91c.s:47476: Error: branch out of range
clang-4.0: error: assembler command failed with exit code 1 (use -v to see invocation)
Makefile:1897: recipe for target 'parse-datetime.o' failed
make[3]: *** [parse-datetime.o] Error 1
make[3]: Leaving directory '/home/binkit/dataset/gnu/sources/tar/tar-1.30_clang-4.0_mips_64_O0_normal/gnu'
Makefile:1922: recipe for target 'install-recursive' failed
make[2]: *** [install-recursive] Error 1
make[2]: Leaving directory '/home/binkit/dataset/gnu/sources/tar/tar-1.30_clang-4.0_mips_64_O0_normal/gnu'
Makefile:2076: recipe for target 'install' failed
make[1]: *** [install] Error 2
make[1]: Leaving directory '/home/binkit/dataset/gnu/sources/tar/tar-1.30_clang-4.0_mips_64_O0_normal/gnu'
Makefile:1388: recipe for target 'install-recursive' failed
make: *** [install-recursive] Error 1

I have tried my best to google it but I haven't found any solution.
I wonder if you have encountered similar problem before and do you have suggestions to solve it?

@0xdkay
Copy link
Collaborator

0xdkay commented Apr 16, 2023

Hello @Bowen-n , sorry for the late reply.
We did not meet such an issue during our compilation.
Could you explain more about your steps and compilation environment, so that we can look into it together?

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

2 participants