首页 > 其他 > 详细

makefile中的缩进

时间:2020-01-30 12:31:12      阅读:232      评论:0      收藏:0      [点我收藏+]

今天写makefile中遇到了2个问题。
Makefile missing separator. Stop*** recipe commences before first target. Stop.

问题一: Makefile missing separator. Stop

当出现这种error,一般与Tab缩进有关,makefile要求命令行开头必须用tab键

clean:
    rm *.cpp~    //必须缩进

问题二: recipe commences before first target. Stop

出现这种error是因为命令缺了一个target。

# 错误例子
ifndef src
    @echo "src no define"
endif

# 纠正
ifndef src
warning:
    @echo "src no define"
endif

makefile中的缩进

原文:https://www.cnblogs.com/friedCoder/p/12242384.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!