【问题标题】:What is wrong with makefile?makefile 有什么问题?
【发布时间】:2017-08-15 01:38:11
【问题描述】:

我正在尝试编译android的内核,然后得到错误。

/home/igor/work/hwp6s-kernel/arch/arm/mach-hi6620/pwrctrl/Makefile:9: *** missing separator.  Stop.
      File makefile
EXTRA_CFLAGS   +=   -wformat

obj-y               += common/
obj-y               += dfsMgr/
obj-y               += periMgr/
obj-y               += sleepMgr/
obj-y               += hotplug/
obj-y               += test/
EXTRA_CFLAGS -= -Wformat

【问题讨论】:

    标签: android gnu-make makefile


    【解决方案1】:

    makefile 中没有-= 运算符。阅读本文时,Make 感到困惑。

    即使该运算符确实存在(或者您正确使用了$(filter-out ...)),您也不会得到您想要的效果。 obj-y 只是将内容添加到列表中,该列表在读取 kbuild makefile 后处理。届时,在读取 kbuild makefile 结束时存在的EXTRA_CFLAGS 值将生效。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2018-09-13
      • 2012-01-30
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多