From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alexey Smishlayev Date: Tue, 14 Jan 2014 13:25:23 +0200 Subject: [U-Boot] Compiling fw_printenv tool In-Reply-To: References: <52987228.9040604@xtech2.lv> <52988D88.5000806@xtech2.lv> Message-ID: <52D51EA3.4060702@xtech2.lv> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hello Detlev, On 2014.01.14. 12:54, Detlev Zundel wrote: > Hi Alexey, > >> Dear Detlev, >> >> I ran >> $ make HOSTCC=arm-none-linux-gnueabi-gcc env >> and got the tools/env/fw_printenv executable. But the Make command >> returned error: >> strip: Unable to recognise the format of the input file `fw_printenv' >> make[1]: *** [fw_printenv] Error 1 >> >> I guess, HOSTSTRIP variable also has to be set. >> >> However, I uploaded the unstripped executable to my embedded device, >> and ran: >> $ chmod a+x fw_printenv >> $ ./fw_printenv >> -sh: ./fw_printenv: not found >> >> I tried also manually stripping the executable. >> What could be this error related to? > Oops, I really missed that mail, sorry. > > This error message means that your cross-compiled binary does not run on > the embedded device (maybe the device uses different libraries than your > cross toolchain links agains). To troubleshoot that, start with a > regular "hello-world.c" and continue to fw_printenv only if you have > this working. > > Cheers > Detlev > I've googled it and sorted it out. The problem was that executable was dynamically linked and the *.so was not found on the embedded system. I compiled it with -static and it runs. Best regards, Alexey