scons 的所有有效文件名是什么?

What's all the valid file name for scons?

我试了SConstruct,Sconstruct,sconstruct,好像都可以。

我的问题: 1、所有'sconstruct'个文件是否不区分大小写?我认为 linux 系统文件名是区分大小写的,是 python 认为 scons 对文件名不区分大小写吗?

  1. 如果有 'sconstruct' 文件,scons 打印:

    $烤饼 scons:读取 SConscript 文件 ... scons:完成读取 SConscript 文件。 scons:建立目标...... 司康:`。已是最新。 scons:完成构建目标。

为什么说的是"Reading SConscript file",而不是"Reading SConstruct file"?

估计是老版本的scons,make文件名是"SConscript"吧?但是我尝试将 "SConstruct" 重命名为 "SConscript",然后打印出来:

$ scons

scons: *** No SConstruct file found.

这对我来说太奇怪了,什么是 "SConscript" 概念?

要回答有关 SConstruct 文件名大小写的问题,请参阅手册页:http://scons.org/doc/production/HTML/scons-man.html

By default, scons searches for a file named SConstruct, Sconstruct, or sconstruct (in that order) in the current directory and reads its configuration from the first file found. An alternate file name may be specified via the -f option.

为了更好地理解 SCons.. 还建议阅读用户指南。关于什么是 SConscript 的问题?

http://scons.org/doc/production/HTML/scons-user/ch14.html

14.1. SConscript Files

As we've already seen, the build script at the top of the tree is called SConstruct. The top-level SConstruct file can use the SConscript function to include other subsidiary scripts in the build. These subsidiary scripts can, in turn, use the SConscript function to include still other scripts in the build. By convention, these subsidiary scripts are usually named SConscript. For example, a top-level SConstruct file might arrange for four subsidiary scripts to be included in the build as follows: