Scons. Go recursive with Glob

前端 未结 4 1579
一个人的身影
一个人的身影 2021-01-13 06:51

I using scons for a few days and confused a bit. Why there is no built-in tools for building sources recursively starting from given root? Let me explain: I have such source

4条回答
  •  执笔经年
    2021-01-13 07:24

    I use this:

    srcdir = './'
    sources = [s for s in glob2.glob(srcdir + '**/*.cpp') if "/." not in s]
    

提交回复
热议问题