Closed nuraalkhateeb closed 8 years ago
Hi,
I see that you are running sudo make
instead of make
.
I always had problems when compiling with sudo. You should avoid doing it. Clean the u-boot code and take ownership of all the files (since some of the binaries belong to root now after your sudo command).
Then run a standard make and see if it works correctly.
Additionally, did you export CROSS_COMPILE=arm-linux-gnueabihf-
?
What do you mean by clean the u-boot code? I'll take ownership and see if that works and yes, I did export CROSS_COMPILE. However, that did not solve my problem.
Without cleaning u-boot code, I've tried 'make' without sudo and received
noor@noor-Z97M-D3H:~/Documents/SOC_tutorial-master/Tutorial_1/u-boot$ make arm-linux-gnueabihf-as: error while loading shared libraries: libz.so.1: cannot open shared object file: No such file or directory /usr/local/DS-5_v5.22.0/sw/gcc/bin/../libexec/gcc/arm-linux-gnueabihf/4.8.3/cc1: error while loading shared libraries: libz.so.1: cannot open shared object file: No such file or directory /usr/local/DS-5_v5.22.0/sw/gcc/bin/../libexec/gcc/arm-linux-gnueabihf/4.8.3/cc1: error while loading shared libraries: libz.so.1: cannot open shared object file: No such file or directory * Your GCC does not produce working binaries in THUMB mode. * Your board is configured for THUMB mode. make: *\ [checkthumb] Error 1
Okay, so I'm now getting different errors. I'll try resolving these.
By clean, I meant run make distclean
.
Do the following:
pushd "sw/hps/u-boot"
sudo chown --recursive noor:noor . # may need to adapt depending on your username and groupname
export CROSS_COMPILE=arm-linux-gnueabihf-
make distclean
git checkout b104b3dc1dd90cdbf67ccf3c51b06e4f1592fe91
make socfpga_cyclone5_config
# modify the "socfpga_cyclone5_socdk.h" file as needed
make
popd
Ok, I see that you are missing some shared libraries. You should install the package that contains libz.so.1 from your package manager.
Thank you, I was able to get the correct packages and fix those errors.
Sahand,
Would you know anything about why I'm receiving this error
noor@noor-Z97M-D3H:~/Documents/SOC_tutorial-master/Tutorial_1/u-boot$ sudo make [sudo] password for noor: CHK include/config/uboot.release CHK include/generated/version_autogenerated.h CHK include/generated/timestamp_autogenerated.h UPD include/generated/timestamp_autogenerated.h CC lib/asm-offsets.s lib/asm-offsets.c:1:0: error: bad value (armv5) for -march= switch /* ^ make[1]: * [lib/asm-offsets.s] Error 1 make: * [prepare0] Error 2
I receive this right after making changes to socfpga_cyclone5_socdk.h and running 'make'.
I've googled the error, but nothing helped solve my issue.
Thank you, ~Nora