我最近买了Raspberry Pi。我已经配置好了,并且在桌面(amd64)上安装了用于arm的交叉编译器。我编译了一个简单的“ hello world”程序,然后使用将其从桌面复制到Pi scp ./hello david@192.168.1.33:~/hello
。登录我的Pi后,我运行ls -l hello
并得到一个正常响应:
-rwxr-xr-x 1 david david 6774 Nov 16 18:08 hello
但是当我尝试执行它时,得到以下信息:
david@raspberry-pi:~$ ./hello
-bash: ./hello: No such file or directory
david@raspberry-pi:~$ file hello
hello: ELF 32-bit LSB executable, ARM, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.26, BuildID[sha1]=0x6a926b4968b3e1a2118eeb6e656db3d21c73cf10, not stripped
david@raspberry-pi:~$ ldd hello
not a dynamic executable
file hello
并ldd hello
发布输出。