Cross compilation (magic 7F45 error)

2019-09-17 13:49发布

问题:

I want to use the Android Screenshot Library. In order to start the native service, i have to execute the run.ps1 file via Windows PowerShell, as it's written here: https://code.google.com/p/android-screenshot-library/wiki/UserGuide I got the "..asl-native : not executable : magic 7F45" error, and i read that i have to make a cross-compilation to make it work; but i have no clue how to do that? what compilers should I use?

回答1:

Magic number 7F45 specifies the Executable and Linkable Format (ELF) file type, a format that is not executable on ARM processors.

Reason could be either improper cross compilation or either using wrong toolchain.

Using correct toolchain should fix this problem