OK6410A development board (three) 7 u-boot-2021.01 boot analysis u-boot and linux configuration part

Publisher:心灵舞动Latest update time:2022-09-23 Source: csdnKeywords:OK6410A Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

U-boot configuration

make O=output ok6410a_mini_defconfig

// You don't need to specify ARCH (because it's written in defconfig) and CROSS_COMPILE (because it's not needed now, it's needed when building) when configuring

// If CROSS_COMPILE is written, CROSS_COMPILE will be checked, and then it still needs to be written when building

// The first time using arm-gcc, CC lib/asm-offsets.s during compilation


make[1]: Entering directory '/home/suws/ok6410/system-new/u-boot/output'

  HOSTCC  scripts/basic/fixdep

  cc -Wp,-MD,scripts/basic/.fixdep.d -Iscripts/basic -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu11 -o scripts/basic/fixdep ../scripts/basic/fixdep.c

  GEN     ./Makefile

rm -f .tmp_quiet_recordmcount

ln -fsn .. source

/bin/bash ../scripts/mkmakefile

    .. . 2021 01

  GEN     ./Makefile

  HOSTCC  scripts/kconfig/conf.o

  cc -Wp,-MD,scripts/kconfig/.conf.o.d -Iscripts/kconfig -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu11 -c -o scripts/kconfig/conf.o ../scripts/kconfig/conf.c

  YACC    scripts/kconfig/zconf.tab.c

  bison -oscripts/kconfig/zconf.tab.c -t -l ../scripts/kconfig/zconf.y

  LEX     scripts/kconfig/zconf.lex.c

  flex -oscripts/kconfig/zconf.lex.c -L ../scripts/kconfig/zconf.l

  HOSTCC  scripts/kconfig/zconf.tab.o

  cc -Wp,-MD,scripts/kconfig/.zconf.tab.o.d -Iscripts/kconfig -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu11  -I../scripts/kconfig -c -o scripts/kconfig/zconf.tab.o scripts/kconfig/zconf.tab.c

  HOSTLD  scripts/kconfig/conf

  cc   -o scripts/kconfig/conf scripts/kconfig/conf.o scripts/kconfig/zconf.tab.o


scripts/kconfig/conf  --defconfig=arch/../configs/ok6410a_mini_defconfig Kconfig

#

# configuration written to .config

#

make[1]: Leaving directory '/home/suws/ok6410/system-new/u-boot/output'


Linux configuration

  HOSTCC  scripts/basic/fixdep

  gcc -Wp,-MMD,scripts/basic/.fixdep.d -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu89         -o scripts/basic/fixdep scripts/basic/fixdep.c 

  HOSTCC  scripts/kconfig/conf.o

  gcc -Wp,-MMD,scripts/kconfig/.conf.o.d -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu89       -c -o scripts/kconfig/conf.o scripts/kconfig/conf.c

  HOSTCC  scripts/kconfig/confdata.o

  gcc -Wp,-MMD,scripts/kconfig/.confdata.o.d -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu89       -c -o scripts/kconfig/confdata.o scripts/kconfig/confdata.c

  HOSTCC  scripts/kconfig/expr.o

  gcc -Wp,-MMD,scripts/kconfig/.expr.o.d -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu89       -c -o scripts/kconfig/expr.o scripts/kconfig/expr.c

  LEX     scripts/kconfig/lexer.lex.c

  flex -oscripts/kconfig/lexer.lex.c -L scripts/kconfig/lexer.l

  YACC    scripts/kconfig/parser.tab.[ch]

  bison -o scripts/kconfig/parser.tab.c --defines=scripts/kconfig/parser.tab.h -t -l scripts/kconfig/parser.y

  HOSTCC  scripts/kconfig/lexer.lex.o

  gcc -Wp,-MMD,scripts/kconfig/.lexer.lex.o.d -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu89      -I ./scripts/kconfig -c -o scripts/kconfig/lexer.lex.o scripts/kconfig/lexer.lex.c

  HOSTCC  scripts/kconfig/parser.tab.o

  gcc -Wp,-MMD,scripts/kconfig/.parser.tab.o.d -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu89      -I ./scripts/kconfig -c -o scripts/kconfig/parser.tab.o scripts/kconfig/parser.tab.c

  HOSTCC  scripts/kconfig/preprocess.o

  gcc -Wp,-MMD,scripts/kconfig/.preprocess.o.d -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu89       -c -o scripts/kconfig/preprocess.o scripts/kconfig/preprocess.c

  HOSTCC  scripts/kconfig/symbol.o

  gcc -Wp,-MMD,scripts/kconfig/.symbol.o.d -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu89       -c -o scripts/kconfig/symbol.o scripts/kconfig/symbol.c

  HOSTCC  scripts/kconfig/util.o

  gcc -Wp,-MMD,scripts/kconfig/.util.o.d -Wall -Wmissing-prototypes -Wstrict-prototypes -O2 -fomit-frame-pointer -std=gnu89       -c -o scripts/kconfig/util.o scripts/kconfig/util.c

  HOSTLD  scripts/kconfig/conf

  gcc   -o scripts/kconfig/conf scripts/kconfig/conf.o scripts/kconfig/confdata.o scripts/kconfig/expr.o scripts/kconfig/lexer.lex.o scripts/kconfig/parser.tab.o scripts/kconfig/preprocess.o scripts/kconfig/symbol.o scripts/kconfig/util.o

scripts/kconfig/conf  --defconfig=arch/arm/configs/ok6410A_sdboot_mini_defconfig Kconfig

#

# configuration written to .config

#


Differences between u-boot and linux configuration

Configure the environment variables that need to be filled

u-boot configuration does not need to fill ARCH and CROSS_COMPILE 

u-boot compilation requires configuration of CROSS_COMPILE

The linux configuration needs to fill in ARCH (so that defconfig can be found) and CROSS_COMPILE (filling will change the generated .config, and the .config will be filled with the CROSS_COMPILE information CONFIG_CC_VERSION_TEXT)

Linux compilation also requires configuration of ARCH and CROSS_COMPILE 


Configuration run process

Same point:

All generate scripts/kconfig/conf

And use the command scripts/kconfig/conf --defconfig=/path_to_defconfig/ok6410a_mini_defconfig Kconfig to generate .config

difference

u-boot scripts/kconfig/conf is relatively simple 

cc   -o scripts/kconfig/conf scripts/kconfig/conf.o scripts/kconfig/zconf.tab.o

Linux scripts/kconfig/conf is more complicated

  gcc   -o scripts/kconfig/conf scripts/kconfig/conf.o scripts/kconfig/confdata.o scripts/kconfig/expr.o scripts/kconfig/lexer.lex.o scripts/kconfig/parser.tab.o scripts/kconfig/preprocess.o scripts/kconfig/symbol.o scripts/kconfig/util.o


Keywords:OK6410A Reference address:OK6410A development board (three) 7 u-boot-2021.01 boot analysis u-boot and linux configuration part

Previous article:OK6410A development board (three) 8 u-boot-2021.01 boot analysis SPL image running part
Next article:OK6410A Development Board (VI) 3 OK6410A Linux-5.11 Compilation Analysis

Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号