More environment improvements
This commit is contained in:
parent
9cdc13e0f5
commit
9c8f3c099b
10
SConstruct
10
SConstruct
@ -13,6 +13,8 @@ opts.AddVariables(
|
|||||||
("CXX", "C++ Compiler"),
|
("CXX", "C++ Compiler"),
|
||||||
("AS", "Assembler"),
|
("AS", "Assembler"),
|
||||||
("LINK", "Linker"),
|
("LINK", "Linker"),
|
||||||
|
("AR", "Archiver"),
|
||||||
|
("RANLIB", "Archiver Indexer"),
|
||||||
("BUILDTYPE", "Build type (RELEASE, DEBUG, or PERF)", "RELEASE"),
|
("BUILDTYPE", "Build type (RELEASE, DEBUG, or PERF)", "RELEASE"),
|
||||||
("VERBOSE", "Show full build information (0 or 1)", "0"),
|
("VERBOSE", "Show full build information (0 or 1)", "0"),
|
||||||
("NUMCPUS", "Number of CPUs to use for build (0 means auto).", "0"),
|
("NUMCPUS", "Number of CPUs to use for build (0 means auto).", "0"),
|
||||||
@ -37,6 +39,10 @@ if os.environ.has_key('AS'):
|
|||||||
env["AS"] = os.getenv('AS')
|
env["AS"] = os.getenv('AS')
|
||||||
if os.environ.has_key('LD'):
|
if os.environ.has_key('LD'):
|
||||||
env["LINK"] = os.getenv('LD')
|
env["LINK"] = os.getenv('LD')
|
||||||
|
if os.environ.has_key('AR'):
|
||||||
|
env["AR"] = os.getenv('AR')
|
||||||
|
if os.environ.has_key('RANLIB'):
|
||||||
|
env["RANLIB"] = os.getenv('RANLIB')
|
||||||
if os.environ.has_key('CFLAGS'):
|
if os.environ.has_key('CFLAGS'):
|
||||||
env.Append(CCFLAGS = SCons.Util.CLVar(os.environ['CFLAGS']))
|
env.Append(CCFLAGS = SCons.Util.CLVar(os.environ['CFLAGS']))
|
||||||
if os.environ.has_key('CPPFLAGS'):
|
if os.environ.has_key('CPPFLAGS'):
|
||||||
@ -97,6 +103,10 @@ if env["VERBOSE"] == "0":
|
|||||||
env["ARCOMSTR"] = "Creating library $TARGET"
|
env["ARCOMSTR"] = "Creating library $TARGET"
|
||||||
env["RANLIBCOMSTR"] = "Indexing library $TARGET"
|
env["RANLIBCOMSTR"] = "Indexing library $TARGET"
|
||||||
env["LINKCOMSTR"] = "Linking $TARGET"
|
env["LINKCOMSTR"] = "Linking $TARGET"
|
||||||
|
env["ASCOMSTR"] = "Assembling $TARGET"
|
||||||
|
env["ASPPCOMSTR"] = "Assembling $TARGET"
|
||||||
|
env["ARCOMSTR"] = "Archiving $TARGET"
|
||||||
|
env["RANLIBCOMSTR"] = "Indexing $TARGET"
|
||||||
|
|
||||||
def GetNumCPUs(env):
|
def GetNumCPUs(env):
|
||||||
if env["NUMCPUS"] != "0":
|
if env["NUMCPUS"] != "0":
|
||||||
|
Loading…
Reference in New Issue
Block a user