The formatting in your question (both the makefile and the error message) is too messed up to be sure, but my suspicion is that your ifeq
is indented with a TAB.
That's not right; ifeq
is a make command. (Almost) all lines with TAB characters as the first character on the line in a makefile is passed to the shell. The shell doesn't know anything about ifeq
, so, depending on your shell, might print an error like that.
You should move the app:
target after the ifeq
blocks to just before the use of $(CC)
(and ensure the $(CC) ...
line is indented with a TAB as the first character on that line).
In the future please be sure to use SO's formatting capabilities, and be sure to cut and paste error messages exactly, plus a few lines of context before and after, when asking questions.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…