fix(Makefile): fix menuconfig compile error due to CC and LIBS variable error#931
Draft
Frankslu wants to merge 2 commits intoOpenXiangShan:masterfrom
Draft
fix(Makefile): fix menuconfig compile error due to CC and LIBS variable error#931Frankslu wants to merge 2 commits intoOpenXiangShan:masterfrom
Frankslu wants to merge 2 commits intoOpenXiangShan:masterfrom
Conversation
correctly compile menuconfig for the first time * When first clone this repository, CC is initialized with $(call remove_quote $(CONFIG_CC)). But CONFIG_CC isn't initialized now, so CC will be empty string. So set CONFIG_CC?=gcc and CONFIG_CXX?=g++ before CC is initialized. * Menuconfig use LIBS= -lncurses -ltinfo, but the target BINARY in build.mk depends on LIBS, which will result in error "No rule to make tartget '-lncurses'". So change LIBS= to LDFLAGS=
Contributor
Author
|
CI为什么没报错呢() |
Member
|
I can't reproduce the bug. Could you please give reproduction way? |
Member
|
I found that NEMU seems to work in an strage way. If CC isn't set as env var, it works. So, We may check the whole Makefile more detailly later.... |
Member
|
I just mark this PR as draft now, until Makefiles are clarified. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The first compilation
make menuconfigormake riscv***defconfigwill failWhen first clone this repository, CC is initialized with
$(call remove_quote $(CONFIG_CC)). ButCONFIG_CCisn't initialized now, so CC will be empty string. So checkCONFIG_CCandCONFIG_CXXbefore CC is initialized.Menuconfig use
LIBS= -lncurses -ltinfo, but the target BINARY in build.mk depends on LIBS, which will result in error "No rule to make tartget '-lncurses'". So change LIBS to LDFLAGS