Some errors occurred when building Linux 2.4.36 Kernel used for building cross-compiler

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi, guys,

I want to build Linux 2.4.X kernel (head files and its libraries) in order to build a cross compiler GCC. However some errors occurred.

it requests the gcc version currently used on my host machine is less than 4.2.

So I tried gcc 4.0. However while making gcc 4.0 sourc codes, and please see below for details.


Could someone help me with these two errors ?  I really want to build a cross-compiler in order to run our 32-bit application on i686 single board computer, which has the following information:

processor   : 0
vendor_id   : GenuineIntel
cpu family  : 6
model       : 11
model name  : Mobile Intel(R) Celeron(TM) CPU          650MHz
stepping    : 4
cpu MHz           : 648.911
cache size  : 256 KB
fdiv_bug    : no
hlt_bug           : no
f00f_bug    : no
coma_bug    : no
fpu         : yes
fpu_exception     : yes
cpuid level : 2
wp          : yes
flags       : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 mmx fxsr sse
bogomips    : 1294.33


I look forward to your help and your response is greatly appreciated.

Best regards,

Dingjun


/*********** errors occurred from building gcc 4.0**********/
...............................
configure: creating ./config.status
config.status: creating Makefile
config.status: creating testsuite/Makefile
config.status: creating config.h
config.status: executing default commands
make[1]: Entering directory '/home/dingjun/build_cross_gcc/gcc-4.0.0/build-x86_64-unknown-linux-gnu/libiberty'
if [ x"" != x ] && [ ! -d pic ]; then \
  mkdir pic; \
else true; fi
touch stamp-picdir
make[1]: *** No rule to make target '../include/ansidecl.h', needed by 'regex.o'.  Stop.
make[1]: Leaving directory '/home/dingjun/build_cross_gcc/gcc-4.0.0/build-x86_64-unknown-linux-gnu/libiberty'
make: *** [Makefile:2221: all-build-libiberty] Error 2



/**************** errors occurred from Linux kernel building ​​​​​​*************/
gcc -D__KERNEL__ -I/home/dingjun/build_cross_gcc/linux-2.4.36/include -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fno-strict-aliasing -fno-common -fno-pie -fno-builtin-strpbrk -fno-builtin-sprintf -fomit-frame-pointer -Wno-pointer-sign -mno-red-zone -mcmodel=kernel -pipe -fno-reorder-blocks -finline-limit=2000 -fno-strength-reduce -Wno-sign-compare -fno-asynchronous-unwind-tables -fno-unit-at-a-time -march=nocona -S -o offset.tmp offset.c
In file included from /home/dingjun/build_cross_gcc/linux-2.4.36/include/linux/kernel.h:14,
                 from /home/dingjun/build_cross_gcc/linux-2.4.36/include/linux/wait.h:13,
                 from /home/dingjun/build_cross_gcc/linux-2.4.36/include/linux/fs.h:12,
                 from /home/dingjun/build_cross_gcc/linux-2.4.36/include/linux/capability.h:17,
                 from /home/dingjun/build_cross_gcc/linux-2.4.36/include/linux/binfmts.h:5,
                 from /home/dingjun/build_cross_gcc/linux-2.4.36/include/linux/sched.h:9,
                 from offset.c:9:
/home/dingjun/build_cross_gcc/linux-2.4.36/include/linux/compiler.h:45:2: error: #error "GCC >= 4.2 miscompiles kernel 2.4, do not use it!"
   45 | #error "GCC >= 4.2 miscompiles kernel 2.4, do not use it!"
      |  ^~~~~
/home/dingjun/build_cross_gcc/linux-2.4.36/include/linux/compiler.h:46:2: error: #error "While the resulting kernel may boot, you will encounter random bugs"
   46 | #error "While the resulting kernel may boot, you will encounter random bugs"
      |  ^~~~~
/home/dingjun/build_cross_gcc/linux-2.4.36/include/linux/compiler.h:47:2: error: #error "at runtime. Only versions 2.95.3 to 4.1 are known to work reliably."
   47 | #error "at runtime. Only versions 2.95.3 to 4.1 are known to work reliably."
      |  ^~~~~
/home/dingjun/build_cross_gcc/linux-2.4.36/include/linux/compiler.h:48:2: error: #error "To build with another version, for instance 3.3, please do"
   48 | #error "To build with another version, for instance 3.3, please do"
      |  ^~~~~
/home/dingjun/build_cross_gcc/linux-2.4.36/include/linux/compiler.h:49:2: error: #error "   make bzImage CC=gcc-3.3 "
   49 | #error "   make bzImage CC=gcc-3.3 "
      |  ^~~~~
make[2]: *** [Makefile:18: offset.h] Error 1
make[2]: Leaving directory '/home/dingjun/build_cross_gcc/linux-2.4.36/arch/x86_64/tools'
make[1]: *** [Rules.make:136: _sfdep_arch/x86_64/tools] Error 2
make[1]: Leaving directory '/home/dingjun/build_cross_gcc/linux-2.4.36'
make: *** [Makefile:506: dep-files] Error 2
Dingjun Chen  | Software Developer

[Geotech Airborne Geophysical Surveys]

Geotech Ltd. dba Geotech Airborne | 270 INDUSTRIAL PKY S | AURORA ON CA | L4G 3T9
T: +1 905 841 5004 | Dingjun.Chen@xxxxxxxxxxxxxxxxxxx<mailto:Dingjun.Chen@xxxxxxxxxxxxxxxxxxx> | www.geotechairborne.com<www.geotech.ca>

P Please consider the environment before printing this email

This message may contain PRIVILEGED AND PROPRIETARY INFORMATION intended solely for the use of the addressee (s) named above. Any disclosure, distribution, copying, or use of the information by others is strictly prohibited. If you have received this message in error, please advise the sender by immediate reply and delete the original message.




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux