Skip to content

Add LC_ALL=C to cc-objdump-file-format.sh for awk to work properly - #614

Merged
tavip merged 1 commit into
lkl:masterfrom
elkcl:file-format-locale-patch
Aug 21, 2025
Merged

Add LC_ALL=C to cc-objdump-file-format.sh for awk to work properly#614
tavip merged 1 commit into
lkl:masterfrom
elkcl:file-format-locale-patch

Conversation

@elkcl

@elkcl elkcl commented Aug 20, 2025

Copy link
Copy Markdown

If a non-English locale is used, awk fails to properly extract the file format from objdump output, leading to build errors such as this:

arch/lkl/Kconfig:42: syntax error
arch/lkl/Kconfig:41: invalid statement

The problem is fixed by making sure that objdump uses the C locale.

@ddiss ddiss left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks fine, although I'm a little confused as to why other $OBJDUMP output parsers (e.g. arch/x86/tools/Makefile) don't need this. Which locale are you using?

@elkcl

elkcl commented Aug 20, 2025

Copy link
Copy Markdown
Author

I'm using ru_RU.UTF-8. Fixing that file was enough for the build to succeed in my case, so I didn't really check any other objdump/awk passes.

As far as I can see, arch/x86/tools/chkobjdump.awk and arch/x86/tools/objdump_reformat.awk both don't mention any locale-dependent strings, so that's probably why they're working fine

@tavip tavip left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks @elkcl ! Please add the Signed-off-by: tag to the commit message.

@elkcl
elkcl force-pushed the file-format-locale-patch branch from 23d8925 to bd914ba Compare August 20, 2025 19:23
@elkcl

elkcl commented Aug 21, 2025

Copy link
Copy Markdown
Author

ok, done!

@tavip

tavip commented Aug 21, 2025

Copy link
Copy Markdown
Member

Thanks @elkcl, could you also please fix the author name in the git commit to avoid checkpatch complaining?

WARNING: From:/Signed-off-by: email name mismatch: 'From: Elk Cloner <dev@elkcl.ru>' != 'Signed-off-by: Ilya Denisyev <dev@elkcl.ru>'

@elkcl
elkcl force-pushed the file-format-locale-patch branch 2 times, most recently from 26ac604 to a0b4877 Compare August 21, 2025 19:42
Signed-off-by: Ilya Denisyev <dev@elkcl.ru>
@elkcl
elkcl force-pushed the file-format-locale-patch branch from a0b4877 to 49f9937 Compare August 21, 2025 19:44
@elkcl

elkcl commented Aug 21, 2025

Copy link
Copy Markdown
Author

Sure, should be good to go now

@tavip
tavip merged commit 9f876c1 into lkl:master Aug 21, 2025
12 of 13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants