Creating nested makefile

前端 未结 3 1321
独厮守ぢ
独厮守ぢ 2021-02-08 05:45

I am learning makefiles and I know how to create a simple makefile. I am moving on to nested makefiles. Here is my directory structure

/src
...makefile
         


        
3条回答
  •  执笔经年
    2021-02-08 06:33

    Recursive make is generally considered harmful.

    If you really want to be able to type "make" in the root dir and have it build everything using only POSIX makefiles, it is the only way. In that case, link the subprojects in their own directory, and final stuff together in root.

    If you're willing to use gmake syntax, take a look at the Makefiles here: http://github.com/singpolyma/theveeb-ecosystem

提交回复
热议问题