Error while compiling U-boot-1.1.6 on fedora 8 with ELDK cross compiler - u-boot

I am compiling U-boot, for yosemite board. when i hit make all, fallowing errors will occurred.
make[1]: *** No rule to make target '.depend' needed by 'libcommon.a'. Stop

Related

Errors in building INET in omnet++ 5.5.1

I have installed OMNeT++ 5.5.1 in ubuntu 18.04 successfully and it is working.
However, I am getting the following errors while building the latest version of INET. I followed the instructions ( using the IDE) given in the document. Can anyone please help me to get ride of it? Thank you.
/tmp/cc4FhpSO.s: Assembler messages:
/tmp/cc4FhpSO.s: Fatal error: can't close ../out/gcc-debug/src/inet/visualizer/base/MediumVisualizerBase.o: No space left on device
Makefile:1754: recipe for target '../out/gcc-debug/src/inet/visualizer/base/MediumVisualizerBase.o' failed
make[1]: *** [../out/gcc-debug/src/inet/visualizer/base/MediumVisualizerBase.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make[1]: Leaving directory '/home/tech/Downloads/inet4/src'
make: *** [all] Error 2
Makefile:7: recipe for target 'all' failed
"make MODE=debug -j2 all" terminated with exit code 2. Build might be incomplete.
20:48:19 Build Failed. 5 errors, 0 warnings. (took 11m:39s.915ms)
It seems that you don't have free space in the disk:
/tmp/cc4FhpSO.s: Fatal error: can't close ../out/gcc-debug/src/inet/visualizer/base/MediumVisualizerBase.o: No space left on device

Working cmake/mingw configuration stopped working. The C compiler is not able to compile a simple test program

I write the C program using MinGW on windows 10 with Clion IDE. I had everything working and compiled successfully multiple times before. Can't link the error with any action but now cmake test in Clion fails - "Test Cmake run finished with errors" and I can't compile. Cmake error:
-- The C compiler identification is GNU 9.2.0
-- The CXX compiler identification is GNU 9.2.0
-- Check for working C compiler: C:/msys64/mingw64/bin/gcc.exe
-- Check for working C compiler: C:/msys64/mingw64/bin/gcc.exe -- broken
CMake Error at C:/Users/karol/AppData/Local/JetBrains/Toolbox/apps/CLion/ch-0/193.6015.37/bin/cmake/win/share/cmake-3.15/Modules/CMakeTestCCompiler.cmake:60 (message):
The C compiler
"C:/msys64/mingw64/bin/gcc.exe"
is not able to compile a simple test program.
It fails with the following output:
Change Dir: C:/Users/karol/AppData/Local/Temp/cmake_check_environment/_build11621595605978509144/CMakeFiles/CMakeTmp
Run Build Command(s):C:/msys64/mingw64/bin/mingw32-make.exe cmTC_15aad/fast && C:/msys64/mingw64/bin/mingw32-make.exe -f CMakeFiles\cmTC_15aad.dir\build.make CMakeFiles/cmTC_15aad.dir/build
mingw32-make.exe[1]: Entering directory 'C:/Users/karol/AppData/Local/Temp/cmake_check_environment/_build11621595605978509144/CMakeFiles/CMakeTmp'
Building C object CMakeFiles/cmTC_15aad.dir/testCCompiler.c.obj
C:\msys64\mingw64\bin\gcc.exe -o CMakeFiles\cmTC_15aad.dir\testCCompiler.c.obj -c C:\Users\karol\AppData\Local\Temp\cmake_check_environment\_build11621595605978509144\CMakeFiles\CMakeTmp\testCCompiler.c
Linking C executable cmTC_15aad.exe
C:\Users\karol\AppData\Local\JetBrains\Toolbox\apps\CLion\ch-0\193.6015.37\bin\cmake\win\bin\cmake.exe -E cmake_link_script CMakeFiles\cmTC_15aad.dir\link.txt --verbose=1
C:\Users\karol\AppData\Local\JetBrains\Toolbox\apps\CLion\ch-0\193.6015.37\bin\cmake\win\bin\cmake.exe -E remove -f CMakeFiles\cmTC_15aad.dir/objects.a
C:\msys64\mingw64\bin\ar.exe cr CMakeFiles\cmTC_15aad.dir/objects.a #CMakeFiles\cmTC_15aad.dir\objects1.rsp
C:\msys64\mingw64\bin\gcc.exe -Wl,--whole-archive CMakeFiles\cmTC_15aad.dir/objects.a -Wl,--no-whole-archive -o cmTC_15aad.exe -Wl,--out-implib,libcmTC_15aad.dll.a -Wl,--major-image-version,0,--minor-image-version,0 #CMakeFiles\cmTC_15aad.dir\linklibs.rsp
gcc.exe: fatal error: cannot execute 'ld': CreateProcess: No such file or directory
compilation terminated.
mingw32-make.exe[1]: *** [CMakeFiles\cmTC_15aad.dir\build.make:88: cmTC_15aad.exe] Error 1
mingw32-make.exe[1]: Leaving directory 'C:/Users/karol/AppData/Local/Temp/cmake_check_environment/_build11621595605978509144/CMakeFiles/CMakeTmp'
mingw32-make.exe: *** [Makefile:120: cmTC_15aad/fast] Error 2
CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
CMakeLists.txt:1 (project)
-- Configuring incomplete, errors occurred!
See also "C:/Users/karol/AppData/Local/Temp/cmake_check_environment/_build11621595605978509144/CMakeFiles/CMakeOutput.log".
See also "C:/Users/karol/AppData/Local/Temp/cmake_check_environment/_build11621595605978509144/CMakeFiles/CMakeError.log".
Error code: 1
I don't know what caused it. One thing I did around the time it broke is turn off avast cyber capture. But now I turned off avast antivirus completely and turned off "Check apps and files" option in Defender. The latter I did when Clion popped a notification saying "Windows Defender might be interrupting build speed". I also clicked "fix" in this Clion pop-up and it added project folders to exceptions. Clion notified me of it not immediately after the error but way later.
The directory "C:/Users/karol/AppData/Local/Temp/cmake_check_environment/" mentioned in the error report doesn't exist. I tried unchecking "read-only access" of AppData/Local/temp directory but Windows keeps putting it on. Between those changes and antivirus changes, I was restarting windows many times.
The error message i get when trying to compile:
C:\Users\karol\AppData\Local\JetBrains\Toolbox\apps\CLion\ch-0\193.6015.37\bin\cmake\win\bin\cmake.exe --build C:\Users\karol\Desktop\studia\wstep_do_C\final_project\cmake-build-debug --target final_project -- -j 2
[ 20%] Linking C executable final_project.exe
gcc.exe: fatal error: cannot execute 'ld': CreateProcess: No such file or directory
compilation terminated.
mingw32-make.exe[3]: *** [CMakeFiles\final_project.dir\build.make:134: final_project.exe] Error 1
mingw32-make.exe[2]: *** [CMakeFiles\Makefile2:75: CMakeFiles/final_project.dir/all] Error 2
mingw32-make.exe[1]: *** [CMakeFiles\Makefile2:82: CMakeFiles/final_project.dir/rule] Error 2
mingw32-make.exe: *** [Makefile:117: final_project] Error 2
Many poeple experienced simmilar error caused by non-latin characters in path, not the case here. Also i don't suspect mingw installation as it used to work.
Clion toolchains settings

How to fix 'ld: library not found for -lglib-2.0'

I have to do a compiler with flex and bison for a school project.
They give to me example of new language but I can't compile them..
The code is working fine for other people so the problem come from my Mac. The problem appears when I try to compile with make command, he say "ld: library not found for -lglib-2.0".
I installed "Glib" already but this don't solve the problem.
make
[ 20%] Linking C executable facile
ld: library not found for -lglib-2.0
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [facile] Error 1
make[1]: *** [CMakeFiles/facile.dir/all] Error 2
make: *** [all] Error 2
I need to compile the code to work after on the project.
Thanks you

Linux driver module compilation issuue

I have downloaded some very famous examples modules of linux kernel from http://examples.oreilly.com/9780596005900/
and tries to compile on my system.
My system info:
cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=12.04
DISTRIB_CODENAME=precise
DISTRIB_DESCRIPTION="Ubuntu 12.04.5 LTS"
uname -a
Linux user 3.13.0-32-generic #57~precise1-Ubuntu SMP Tue Jul 15 03:51:20 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux
cd example/simple
make
Got error
make -C /lib/modules/3.13.0-32-generic/build M=/home/user/projects/self/examples/simple LDDINCDIR=/home/user/projects/self/examples/simple/../include modules
make[1]: Entering directory `/usr/src/linux-headers-3.13.0-32-generic'
/usr/src/linux-headers-3.13.0-32-generic/arch/x86/Makefile:98: stack protector enabled but no compiler support
/usr/src/linux-headers-3.13.0-32-generic/arch/x86/Makefile:113: CONFIG_X86_X32 enabled but no binutils support
scripts/Makefile.build:49: *** CFLAGS was changed in "/home/user/projects/self/examples/simple/Makefile". Fix it to use ccflags-y. Stop.
make[1]: *** [_module_/home/user/projects/self/examples/simple] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-3.13.0-32-generic'
make: *** [default] Error 2
I came to know that now kernel build system does not allow to change CFLAGS outside of kernel so changes Makefile this way
-CFLAGS += $(DEBFLAGS) -I$(LDDINCDIR)
+ccflags-y += $(DEBFLAGS) -I$(LDDINCDIR)
Now again Make and get below error messages
make -C /lib/modules/3.13.0-32-generic/build M=/home/user/projects/self/examples/simple LDDINCDIR=/home/user/projects/self/examples/simple/../include modules
make[1]: Entering directory `/usr/src/linux-headers-3.13.0-32-generic'
/usr/src/linux-headers-3.13.0-32-generic/arch/x86/Makefile:98: stack protector enabled but no compiler support
/usr/src/linux-headers-3.13.0-32-generic/arch/x86/Makefile:113: CONFIG_X86_X32 enabled but no binutils support
CC [M] /home/user/projects/self/examples/simple/simple.o
cc1: error: unrecognized command line option "-m64"
cc1: error: unrecognized command line option "-mno-mmx"
cc1: error: unrecognized command line option "-mno-sse"
cc1: error: unrecognized command line option "-mno-red-zone"
cc1: error: unrecognized command line option "-mcmodel=kernel"
cc1: error: unrecognized command line option "-maccumulate-outgoing-args"
make[2]: *** [/home/user/projects/self/examples/simple/simple.o] Error 1
make[1]: *** [_module_/home/user/projects/self/examples/simple] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-3.13.0-32-generic'
make: *** [default] Error 2
earlier I have compiled these example succusfully on my 32 bit system but now i moved to 64 bit system and facing this errors. I have googled about these errors but nothing helped till yet.
Let me how can i solved this compilation errors.
If you have spaces in your the directory you're compiling from or in the directory that contains your kernel sources, try removing them and make again.
If you don't have spaces in your compile directory and you're still getting this error, your kernel compilation may be failing because its directory belongs to root and you're running as an unprivileged user. Try sudo make.

glibc not properly compiling

While compiling glibc 2.11, I get the following error. Any idea how to solve this.
In file included from ../sysdeps/unix/sysv/linux/syslog.c:10:
../misc/syslog.c: In function ‘__vsyslog_chk’:
../misc/syslog.c:123: sorry, unimplemented: inlining failed in call to ‘syslog’: function body not available
../misc/syslog.c:155: sorry, unimplemented: called from here
make[2]: *** [/home/alice/Desktop/glib-build/misc/syslog.o] Error 1
make[2]: Leaving directory `/home/alice/Desktop/glibc-2.11/misc'
make[1]: *** [misc/subdir_lib] Error 2
make[1]: Leaving directory `/home/alice/Desktop/glibc-2.11'
make: *** [all] Error 2
Apparently, this is a known problem with building glibc on Ubuntu. In essence:
glibc does not build with _FORTIFY_SOURCE enabled, and Ubuntu compiles stuff with -D_FORTIFY_SOURCE=2.
You need to disable this by undefining _FORTIFY_SOURCE. i.e. append -U_FORTIFY_SOURCE to your CFLAGS.

Resources