Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EXTRAFLAGS appears in AFLAGS three times #1688

Closed
yamt opened this issue Sep 1, 2020 · 1 comment · Fixed by #1776
Closed

EXTRAFLAGS appears in AFLAGS three times #1688

yamt opened this issue Sep 1, 2020 · 1 comment · Fixed by #1776

Comments

@yamt
Copy link
Contributor

yamt commented Sep 1, 2020

I only checked sim. but others might have similar issues.

when you do "make EXTRAFLAGS=foobar",
foobar appears in eg. AFLAGS three times.

it's a problem because some options are not idempotent.
eg. the following example was with EXTRAFLAGS="-fsanitize=address -mllvm -asan-stack=0 "

AS: sim/up_setjmp64.S
/usr/local/Cellar/llvm/10.0.1/bin/clang -c -Wall -Wstrict-prototypes -Wshadow -Wundef -g -fstack-protector-all -fno-builtin -fno-common -isystem "/Users/yamamoto/git/nuttx/nuttx/include" -D__KERNEL__ -fsanitize=address -mllvm -asan-stack=0 -pipe -I "/Users/yamamoto/git/nuttx/nuttx/arch/sim/src" -I "/Users/yamamoto/git/nuttx/nuttx/arch/sim/src/chip" -I "/Users/yamamoto/git/nuttx/nuttx/sched" -D__KERNEL__ -fsanitize=address -mllvm -asan-stack=0 -D__ASSEMBLY__ -I "/Users/yamamoto/git/nuttx/nuttx/arch/sim/src" -I "/Users/yamamoto/git/nuttx/nuttx/arch/sim/src/chip" -I "/Users/yamamoto/git/nuttx/nuttx/sched" -D__KERNEL__ -fsanitize=address -mllvm -asan-stack=0 sim/up_setjmp64.S -o up_setjmp64.o
clang (LLVM option parsing): for the --asan-stack option: may only occur zero or one times!
clang (LLVM option parsing): for the --asan-stack option: may only occur zero or one times!

@protobits
Copy link
Contributor

@yamt I think I solved this in #1776
can you verify this removes your case of repeated flags in AFLAGS? The fix should apply to all *FLAGS.

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 a pull request may close this issue.

2 participants