Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
195 views
in Technique[技术] by (71.8m points)

linux - Makefile rule is not executing

I'm trying to compile Atmel's Bitcloud (WSNDemo) on Ubuntu 14.04.

The makefile (http://pastebin.com/4gGcGRvY) however seems not executing a rule on my computer.

The problem is that it doesn't start the compiler only the linker. And of course the linker then can't find the objects.

$(OBJ_PATH)/%.o: $(SRCS)

is never called (line 187 in makefile) upon running this:

make -n -f Makefile_All_StdlinkSec_MegaRf_Atmega2564rfr2_16Mhz_Gcc all APP_NAME=WSNDemo

However if I specify the object and also the source by hand (in line 192), then it runs fine:

$(OBJ_PATH)/ofdIntFlashRead.o: ../../../../BitCloud/Components/HAL/drivers/OFD/src/ofdIntFlashRead.s

Note: all source files are in the right place.

So I don't understand why the pattern matching is not working.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

Sorry for misleading you guys.

The mistake was in the Makefile. It came from Windows and the author unintentionally changed a filename to lowercase, and then the makefile couldn't find it on Linux (but it was okay on Windows).

Thank you for your time though.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...