Subscribe to our column
Linux compilation requirements for host environment
Documentation/process/changes.rst
Compilation process
1. Miscellaneous
SYSHDR arch/arm/include/generated/uapi/asm/unistd-common.h
sh './arch/arm/tools/syscallhdr.sh' 'arch/arm/tools/syscall.tbl' 'arch/arm/include/generated/uapi/asm/unistd-common.h' 'common' '' '__NR_SYSCALL_BASE'
SYSHDR arch/arm/include/generated/uapi/asm/unistd-oabi.h
SYSHDR arch/arm/include/generated/uapi/asm/unistd-eabi.h
HOSTCC scripts/dtc/dtc.o
gcc -Wp,-MMD,scripts/dtc/.dtc.o.d -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu89 -I ./scripts/dtc/libfdt -DNO_YAML -c -o scripts/dtc/dtc.o scripts/dtc/dtc.c
HOSTCC scripts/dtc/flattree.o
HOSTCC scripts/dtc/fstree.o
HOSTCC scripts/dtc/data.o
HOSTCC scripts/dtc/livetree.o
HOSTCC scripts/dtc/treesource.o
HOSTCC scripts/dtc/srcpos.o
HOSTCC scripts/dtc/checks.o
HOSTCC scripts/dtc/util.o
LEX scripts/dtc/dtc-lexer.lex.c
flex -oscripts/dtc/dtc-lexer.lex.c -L scripts/dtc/dtc-lexer.l
YACC scripts/dtc/dtc-parser.tab.[ch]
bison -o scripts/dtc/dtc-parser.tab.c --defines=scripts/dtc/dtc-parser.tab.h -t -l scripts/dtc/dtc-parser.y
HOSTCC scripts/dtc/dtc-lexer.lex.o
HOSTCC scripts/dtc/dtc-parser.tab.o
HOSTLD scripts/dtc/dtc
gcc -o scripts/dtc/dtc scripts/dtc/dtc.o scripts/dtc/flattree.o scripts/dtc/fstree.o scripts/dtc/data.o scripts/dtc/livetree.o scripts/dtc/treesource.o scripts/dtc/srcpos.o scripts/dtc/checks.o scripts/dtc/util.o scripts/dtc/dtc-lexer.lex.o scripts/dtc/dtc-parser.tab.o
HOSTCC scripts/kallsyms
gcc -Wp,-MMD,scripts/.kallsyms.d -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu89 -o scripts/kallsyms scripts/kallsyms.c
HOSTCC scripts/sorttable
UPD include/config/kernel.release
set -e; mkdir -p include/config/; trap "rm -f include/config/.kernel.release.tmp" EXIT; { echo "5.11.0$(sh ./scripts/setlocalversion .)"; } > include/config/.kernel.release.tmp; if [ ! -r include/config/kernel.release ] || ! cmp -s include/config/kernel.release include/config/.kernel.release.tmp; then : ' UPD include/config/kernel.release'; mv -f include/config/.kernel.release.tmp include/config/kernel.release; fi
UPD include/generated/uapi/linux/version.h
UPD include/generated/utsrelease.h
SYSNR arch/arm/include/generated/asm/unistd-nr.h
sh './arch/arm/tools/syscallnr.sh' 'arch/arm/tools/syscall.tbl' 'arch/arm/include/generated/asm/unistd-nr.h' ''
GEN arch/arm/include/generated/asm/mach-types.h
mkdir -p arch/arm/include/generated/asm/ && awk -f arch/arm/tools/gen-mach-types arch/arm/tools/mach-types > arch/arm/include/generated/asm/mach-types.h
SYSTBL arch/arm/include/generated/calls-oabi.S
sh './arch/arm/tools/syscalltbl.sh' 'arch/arm/tools/syscall.tbl' 'arch/arm/include/generated/calls-oabi.S' 'common,oabi'
SYSTBL arch/arm/include/generated/calls-eabi.S
CC scripts/mod/empty.o
HOSTCC scripts/mod/mk_elfconfig
MKELF scripts/mod/elfconfig.h
scripts/mod/mk_elfconfig < scripts/mod/empty.o > scripts/mod/elfconfig.h
HOSTCC scripts/mod/modpost.o
CC scripts/mod/devicetable-offsets.s
UPD scripts/mod/devicetable-offsets.h
HOSTCC scripts/mod/file2alias.o
HOSTCC scripts/mod/sumversion.o
HOSTLD scripts/mod/modpost
CC kernel/bounds.s
UPD include/generated/bounds.h
UPD include/generated/timeconst.h
CC arch/arm/kernel/asm-offsets.s
UPD include/generated/asm-offsets.h
CALL scripts/checksyscalls.sh
sh scripts/checksyscalls.sh arm-linux-gnueabi-gcc -Wp,-MMD,./.missing-syscalls.d -nostdinc -isystem /home/mmt/work/BiscuitOS/output/linux-5.10-arm32/arm-linux-gnueabi/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabi/bin/../lib/gcc/arm-linux-gnueabi/7.4.1/include -I./arch/arm/include -I./arch/arm/include/generated -I./include -I./arch/arm/include/uapi -I./arch/arm/include/generated/uapi -I./include/uapi -I./include/generated/uapi -include ./include/linux/kconfig.h -include ./include/linux/compiler_types.h -D__KERNEL__ -mlittle-endian -Wall -Wundef -Werror=strict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -fshort-wchar -fno-PIE -Werror=implicit-function-declaration -Werror=implicit-int -Werror=return-type -Wno-format-security -std=gnu89 -fno-dwarf2-cfi-asm -fno-ipa-sra -mabi=aapcs-linux -mfpu=vfp -funwind-tables -marm -Wa,-mno-warn-deprecated -D__LINUX_ARM_ARCH__=6 -march=armv6k -mtune=arm1136j-s -msoft-float -Uarm -fno-delete-null-pointer-checks -Wno-frame-address -Wno-format-truncation -Wno-format-overflow -O2 --param=allow-store-data-races=0 -Wframe-larger-than=1024 -fstack-protector-strong -Wno-unused-but-set-variable -Wimplicit-fallthrough -Wno-unused-const-variable -fomit-frame-pointer -Wdeclaration-after-statement -Wvla -Wno-pointer-sign -Wno-array-bounds -Wno-stringop-overflow -Wno-restrict -Wno-maybe-uninitialized -fno-strict-overflow -fno-stack-check -fconserve-stack -Werror=date-time -Werror=incompatible-pointer-types -Werror=designated-init -DKBUILD_MODFILE='"./missing-syscalls"' -DKBUILD_BASENAME='"missing_syscalls"' -DKBUILD_MODNAME='"missing_syscalls"'
CALL scripts/atomic/check-atomics.sh
2. Compilation of .o files
CC init/main.o
arm-linux-gnueabi-gcc -Wp,-MMD,init/.main.o.d -nostdinc -isystem /home/mmt/work/BiscuitOS/output/linux-5.10-arm32/arm-linux-gnueabi/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabi/bin/../lib/gcc/arm-linux-gnueabi/7.4.1/include -I./arch/arm/include -I./arch/arm/include/generated -I./include -I./arch/arm/include/uapi -I./arch/arm/include/generated/uapi -I./include/uapi -I./include/generated/uapi -include ./include/linux/kconfig.h -include ./include/linux/compiler_types.h -D__KERNEL__ -mlittle-endian -Wall -Wundef -Werror=strict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -fshort-wchar -fno-PIE -Werror=implicit-function-declaration -Werror=implicit-int -Werror=return-type -Wno-format-security -std=gnu89 -fno-dwarf2-cfi-asm -fno-ipa-sra -mabi=aapcs-linux -mfpu=vfp -funwind-tables -marm -Wa,-mno-warn-deprecated -D__LINUX_ARM_ARCH__=6 -march=armv6k -mtune=arm1136j-s -msoft-float -Uarm -fno-delete-null-pointer-checks -Wno-frame-address -Wno-format-truncation -Wno-format-overflow -O2 --param=allow-store-data-races=0 -Wframe-larger-than=1024 -fstack-protector-strong -Wno-unused-but-set-variable -Wimplicit-fallthrough -Wno-unused-const-variable -fomit-frame-pointer -Wdeclaration-after-statement -Wvla -Wno-pointer-sign -Wno-array-bounds -Wno-stringop-overflow -Wno-restrict -Wno-maybe-uninitialized -fno-strict-overflow -fno-stack-check -fconserve-stack -Werror=date-time -Werror=incompatible-pointer-types -Werror=designated-init -fno-function-sections -fno-data-sections -DKBUILD_MODFILE='"init/main"' -DKBUILD_BASENAME='"main"' -DKBUILD_MODNAME='"main"' -c -o init/main.o init/main.c
CHK include/generated/compile.h
sh ./scripts/mkcompile_h include/generated/compile.h
"arm" "" ""
"" "arm-linux-gnueabi-gcc (Linaro GCC 7.4-2019.02) 7.4.1 20181213 [linaro-7.4-2019.02 revision 56ec6f6b99cc167ff0c2f8e1a2eed33b1edc85d4]" "arm-linux-gnueabi-ld"
UPD include/generated/compile.h
3. with
AR init/built-in.a
rm -f init/built-in.a; arm-linux-gnueabi-ar cDPrST init/built-in.a init/main.o init/version.o init/do_mounts.o init/noinitramfs.o init/calibrate.o init/init_task.o
4. lds
LDS arch/arm/kernel/vmlinux.lds
arm-linux-gnueabi-gcc -E -Wp,-MMD,arch/arm/kernel/.vmlinux.lds.d -nostdinc -isystem /home/mmt/work/BiscuitOS/output/linux-5.10-arm32/arm-linux-gnueabi/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabi/bin/../lib/gcc/arm-linux-gnueabi/7.4.1/include -I./arch/arm/include -I./arch/arm/include/generated -I./include -I./arch/arm/include/uapi -I./arch/arm/include/generated/uapi -I./include/uapi -I./include/generated/uapi -include ./include/linux/kconfig.h -D__KERNEL__ -mlittle-endian -DTEXT_OFFSET=0x00008000 -P -Uarm -D__ASSEMBLY__ -DLINKER_SCRIPT -o arch/arm/kernel/vmlinux.lds arch/arm/kernel/vmlinux.lds.S
5. as
AS arch/arm/lib/ashldi3.o
arm-linux-gnueabi-gcc -Wp,-MMD,arch/arm/lib/.ashldi3.o.d -nostdinc -isystem /home/mmt/work/BiscuitOS/output/linux-5.10-arm32/arm-linux-gnueabi/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabi/bin/../lib/gcc/arm-linux-gnueabi/7.4.1/include -I./arch/arm/include -I./arch/arm/include/generated -I./include -I./arch/arm/include/uapi -I./arch/arm/include/generated/uapi -I./include/uapi -I./include/generated/uapi -include ./include/linux/kconfig.h -D__KERNEL__ -mlittle-endian -D__ASSEMBLY__ -fno-PIE -mabi=aapcs-linux -mfpu=vfp -funwind-tables -marm -Wa,-mno-warn-deprecated -D__LINUX_ARM_ARCH__=6 -march=armv6k -mtune=arm1136j-s -include asm/unified.h -msoft-float -c -o arch/arm/lib/ashldi3.o arch/arm/lib/ashldi3.S
6. conmk
HOSTCC drivers/tty/vt/conmakehash
gcc -Wp,-MMD,drivers/tty/vt/.conmakehash.d -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu89 -o drivers/tty/vt/conmakehash drivers/tty/vt/conmakehash.c
CONMK drivers/tty/vt/consolemap_deftbl.c
drivers/tty/vt/conmakehash drivers/tty/vt/cp437.uni > drivers/tty/vt/consolemap_deftbl.c
7. shipped
SHIPPED drivers/tty/vt/defkeymap.c
cat drivers/tty/vt/defkeymap.c_shipped > drivers/tty/vt/defkeymap.c
CC drivers/tty/vt/defkeymap.o
arm-linux-gnueabi-gcc -Wp,-MMD,drivers/tty/vt/.defkeymap.o.d -nostdinc -isystem /home/mmt/work/BiscuitOS/output/linux-5.10-arm32/arm-linux-gnueabi/gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabi/bin/../lib/gcc/arm-linux-gnueabi/7.4.1/include -I./arch/arm/include -I./arch/arm/include/generated -I./include -I./arch/arm/include/uapi -I./arch/arm/include/generated/uapi -I./include/uapi -I./include/generated/uapi -include ./include/linux/kconfig.h -include ./include/linux/compiler_types.h -D__KERNEL__ -mlittle-endian -Wall -Wundef -Werror=strict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -fshort-wchar -fno-PIE -Werror=implicit-function-declaration -Werror=implicit-int -Werror=return-type -Wno-format-security -std=gnu89 -fno-dwarf2-cfi-asm -fno-ipa-sra -mabi=aapcs-linux -mfpu=vfp -funwind-tables -marm -Wa,-mno-warn-deprecated -D__LINUX_ARM_ARCH__=6 -march=armv6k -mtune=arm1136j-s -msoft-float -Uarm -fno-delete-null-pointer-checks -Wno-frame-address -Wno-format-truncation -Wno-format-overflow -O2 --param=allow-store-data-races=0 -Wframe-larger-than=1024 -fstack-protector-strong -Wno-unused-but-set-variable -Wimplicit-fallthrough -Wno-unused-const-variable -fomit-frame-pointer -Wdeclaration-after-statement -Wvla -Wno-pointer-sign -Wno-array-bounds -Wno-stringop-overflow -Wno-restrict -Wno-maybe-uninitialized -fno-strict-overflow -fno-stack-check -fconserve-stack -Werror=date-time -Werror=incompatible-pointer-types -Werror=designated-init -DKBUILD_MODFILE='"drivers/tty/vt/defkeymap"' -DKBUILD_BASENAME='"defkeymap"' -DKBUILD_MODNAME='"defkeymap"' -c -o drivers/tty/vt/defkeymap.o drivers/tty/vt/defkeymap.c
Previous article:OK6410A development board (three) 7 u-boot-2021.01 boot analysis u-boot and linux configuration part
Next article:OK6410A development board (three) 6 u-boot-2021.01 boot analysis SPL and u-boot compilation and linking differences
- Popular Resources
- Popular amplifiers
- Learn ARM development(16)
- Learn ARM development(17)
- Learn ARM development(18)
- Embedded system debugging simulation tool
- A small question that has been bothering me recently has finally been solved~~
- Learn ARM development (1)
- Learn ARM development (2)
- Learn ARM development (4)
- Learn ARM development (6)
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- LED chemical incompatibility test to see which chemicals LEDs can be used with
- Application of ARM9 hardware coprocessor on WinCE embedded motherboard
- What are the key points for selecting rotor flowmeter?
- LM317 high power charger circuit
- A brief analysis of Embest's application and development of embedded medical devices
- Single-phase RC protection circuit
- stm32 PVD programmable voltage monitor
- Introduction and measurement of edge trigger and level trigger of 51 single chip microcomputer
- Improved design of Linux system software shell protection technology
- What to do if the ABB robot protection device stops
- Analysis of the application of several common contact parts in high-voltage connectors of new energy vehicles
- Wiring harness durability test and contact voltage drop test method
- From probes to power supplies, Tektronix is leading the way in comprehensive innovation in power electronics testing
- From probes to power supplies, Tektronix is leading the way in comprehensive innovation in power electronics testing
- Sn-doped CuO nanostructure-based ethanol gas sensor for real-time drunk driving detection in vehicles
- Design considerations for automotive battery wiring harness
- Do you know all the various motors commonly used in automotive electronics?
- What are the functions of the Internet of Vehicles? What are the uses and benefits of the Internet of Vehicles?
- Power Inverter - A critical safety system for electric vehicles
- Analysis of the information security mechanism of AUTOSAR, the automotive embedded software framework
- Inductance calculation formula
- [NXP Rapid IoT Review] + Recommendation for NXP Rapid IoT to connect the differential ADC input port of KW64 to the expansion port
- [Allwinner V853 heterogeneous AI intelligent vision development board review] "mkimage command not found" error solution...
- Live broadcast with prizes | Sign up for TI's June Embedded Processing Live Theme Week to get a glimpse of new products in industrial scenarios!
- [MSP430] Practical ADC use, internal temperature measurement use
- STM32F401CC spi flash recognition problem
- [Raspberry Pi 4B Review] + Building an OPENCV Environment
- Design and Application of Saber Simulation Software
- [2022 Digi-Key Innovation Design Competition] ESP32S2 button control RGB light
- New wearable technology developed, more skin-friendly and stronger