Makefile 打印变量的值
生活随笔
收集整理的這篇文章主要介紹了
Makefile 打印变量的值
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
$(warning??$(XXX))???打印變量的值
1,使用info/warning/error增加調試信息
方法1: $(info, "here add the debug info")
???????????但是此不能打印出.mk的行號
方法2: $(warning "here add the debug info")
???
方法3: $(error "error: this will stop the compile")
?????這個可以停止當前makefile的編譯
方法4: 打印變量的值
??????$(info $(TARGET_DEVICE) )
2,使用echo增加調試信息(echo只能在target:后面的語句中使用,且前面是個TAB)
方法1: @echo "start the compilexxxxxxxxxxxxxxxxxxxxxxx"
方法2: @echo $(files)
總結
以上是生活随笔為你收集整理的Makefile 打印变量的值的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 3. OD-爆破有钥匙的exe(有验证文
- 下一篇: Windows驱动—64位驱动测试64位