~eda-qa/leaflang/platform

« back to all changes in this revision

Viewing changes to SConstruct

  • Committer: edA-qa mort-ora-y
  • Date: 2017-08-06 13:27:14 UTC
  • mto: This revision was merged to the branch mainline in revision 101.
  • Revision ID: eda-qa@disemia.com-20170806132714-qz5xl2dib3xizals
trying to cleanup library building, on linux at least

Show diffs side-by-side

added added

removed removed

Lines of Context:
7
7
vars.AddVariables(
8
8
        PathVariable('BOOST_PREFIX','Where boost was installed', '/usr/' ),
9
9
        PathVariable('BUILD_DIR','Intermediate build directory', 'build', PathVariable.PathIsDirCreate),
 
10
        PathVariable('DIST_DIR','Redistributable package directory', 'dist', PathVariable.PathIsDirCreate),
10
11
        PathVariable('LLVM_DIR','Where LLVM is installed', '/opt/llvm/install' ),
11
12
        PathVariable('GMP_DIR','Where GMP is installed', '/usr/' ),
12
13
        EnumVariable('BUILD_TYPE','Optimization/debug build type',
33
34
 
34
35
# setup compiler flags
35
36
if baseEnv['BUILD_TYPE'] == 'release':
36
 
        baseEnv.Append(CXXFLAGS = ['-O3', '-g', '-ggdb3'])
 
37
        baseEnv.Append(CXXFLAGS = ['-O3', '-g3', '-ggdb3'])
37
38
else:
38
39
        baseEnv.Append(CXXFLAGS = ['-g3', '-ggdb3'])
 
40
baseEnv['RPATH'] = Literal('\\$$ORIGIN')
 
41
baseEnv.Append(LINKFLAGS=['-z','origin'])
 
42
 
39
43
# expose basic flags in case building foreign code
40
44
baseEnv['BASE_CXXFLAGS'] = baseEnv['CXXFLAGS']
41
45
# our own code has stricter requirements
105
109
# Call the ohter build files
106
110
Export('baseEnv')
107
111
 
108
 
baseEnv.VariantDir(baseEnv['BUILD_DIR'],'src',duplicate=0)
109
 
baseEnv.SConscript('$BUILD_DIR/SConscript')
 
112
#baseEnv.VariantDir(baseEnv['BUILD_DIR'],'src',duplicate=0)
 
113
baseEnv.SConscript('src/SConscript', variant_dir=baseEnv['BUILD_DIR'], duplicate=0)
 
114
 
 
115
#baseEnv.VariantDir(baseEnv['DIST_DIR'], 'package', duplicate=0)
 
116
baseEnv.SConscript('package/SConscript', variant_dir=baseEnv['DIST_DIR'], duplicate =0)
110
117
 
111
118
# Only things in build directory get built, this excludes the .test directory
112
119
Default(baseEnv['BUILD_DIR'])