Bug 13326 - regarding dtc error in buildroot source code
Summary: regarding dtc error in buildroot source code
Status: RESOLVED WONTFIX
Alias: None
Product: buildroot
Classification: Unclassified
Component: Other (show other bugs)
Version: unspecified
Hardware: All Linux
: P5 normal
Target Milestone: ---
Assignee: unassigned
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-11-19 17:24 UTC by anil kumar
Modified: 2021-07-03 17:05 UTC (History)
3 users (show)

See Also:
Host:
Target:
Build:


Attachments
the error is about multiple definition of yyloc which is in the path /scripts/scripts/dtc/dtc-lexer.lex.o (482 bytes, text/plain)
2020-11-20 03:08 UTC, anil kumar
Details

Note You need to log in before you can comment on or make changes to this bug.
Description anil kumar 2020-11-19 17:24:08 UTC
/usr/bin/ld: scripts/dtc/dtc-parser.tab.o:(.bss+0x10): multiple definition of `yylloc'; scripts/dtc/dtc-lexer.lex.o:(.bss+0x0): first defined here
collect2: error: ld returned 1 exit status
make[3]: *** [scripts/Makefile.host:99: scripts/dtc/dtc] Error 1
make[2]: *** [scripts/Makefile.build:544: scripts/dtc] Error 2
make[2]: *** Waiting for unfinished jobs....
  HOSTCC  scripts/mod/sumversion.o
  HOSTLD  scripts/mod/modpost
make[1]: *** [Makefile:1061: scripts] Error 2
Comment 1 anil kumar 2020-11-20 03:08:25 UTC
Created attachment 8671 [details]
the error is about multiple definition of yyloc which is in the path /scripts/scripts/dtc/dtc-lexer.lex.o
Comment 2 Fabrice Fontaine 2021-01-08 11:01:26 UTC
This error raised with gcc 10 should have been fixed by https://git.buildroot.net/buildroot/commit/?id=198db470a73c14191915f8374362bc2a8b08c2bf (applied to master in April 2020)
Comment 3 Yann E. MORIN 2021-07-03 17:05:08 UTC
Anil, All,

As stated by Fabrice, this is now fixed for the dtc package he pointed at.

The traces you pasted are supposedly from the Linux kernel. Since there
are so many versions of the Linux kernel, we can't easily bundle a patch
for the dtc copy bundled in the kernel sources. You will have to backport
the upstream commit e33a814e772cdc36436c8c188d8c42d019fda639, using
BR2_GLOBAL_PATCH_DIR.

Regards,
Yann E. MORIN.