Make sure Scons takes the CFLAGS/CXXFLAGS/LDFLAGS etc for the system. Signed-off-by: Robin H. Johnson diff -Nuar ipager-1.1.0.orig/SConstruct ipager-1.1.0/SConstruct --- ipager-1.1.0.orig/SConstruct 2008-09-08 20:32:23.007016555 -0700 +++ ipager-1.1.0/SConstruct 2008-09-08 20:32:05.103267940 -0700 @@ -30,6 +30,16 @@ # environment ipager_env = Environment(options = ipager_options, ENV = os.environ) +# process env variables +for K in ['CPPFLAGS', 'CFLAGS', 'CXXFLAGS', 'LDFLAGS', 'CC', 'CXX']: + if K in os.environ.keys(): + dict = ipager_env.ParseFlags(os.environ[K]) + # These headers are supposed static. Don't check at each build. + for i in dict['CPPPATH']: + dict['CCFLAGS'].append('-I' + i) + dict['CPPPATH'] = [] + ipager_env.MergeFlags(dict) + ipager_env.Append( CPPFLAGS = [ '-Wall' ], CPPPATH = [ '/usr/X11R6/include' ],