SConscript (6121:18aff7f548c1) | SConscript (7739:f97a5f4d0879) |
---|---|
1# -*- mode:python -*- 2 3# Copyright (c) 2004-2005 The Regents of The University of Michigan 4# All rights reserved. 5# 6# Redistribution and use in source and binary forms, with or without 7# modification, are permitted provided that the following conditions are 8# met: redistributions of source code must retain the above copyright --- 92 unchanged lines hidden (view full) --- 101 102# Check that m4 is available 103import SCons.Tool.m4 104if not SCons.Tool.m4.exists(m4env): 105 print "Error: Can't find version of M4 macro processor. " + \ 106 "Please install M4 and try again." 107 Exit(1) 108 | 1# -*- mode:python -*- 2 3# Copyright (c) 2004-2005 The Regents of The University of Michigan 4# All rights reserved. 5# 6# Redistribution and use in source and binary forms, with or without 7# modification, are permitted provided that the following conditions are 8# met: redistributions of source code must retain the above copyright --- 92 unchanged lines hidden (view full) --- 101 102# Check that m4 is available 103import SCons.Tool.m4 104if not SCons.Tool.m4.exists(m4env): 105 print "Error: Can't find version of M4 macro processor. " + \ 106 "Please install M4 and try again." 107 Exit(1) 108 |
109m4env.Append(M4FLAGS='-DSRCDIR=%s' % Dir('.').path) | 109m4env.Append(M4FLAGS=['-DSRCDIR=%s' % Dir('.').path]) |
110m4env['M4COM'] = '$M4 $M4FLAGS $SOURCES > $TARGET' 111m4env.M4(target=File('libelf_convert.c'), 112 source=[File('elf_types.m4'), File('libelf_convert.m4')]) 113m4env.M4(target=File('libelf_fsize.c'), 114 source=[File('elf_types.m4'), File('libelf_fsize.m4')]) 115m4env.M4(target=File('libelf_msize.c'), 116 source=[File('elf_types.m4'), File('libelf_msize.m4')]) 117 118# Build libelf as a static library with PIC code so it can be linked 119# into either m5 or the library 120m4env.Library('elf', [m4env.SharedObject(f) for f in elf_files]) 121 122main.Prepend(CPPPATH=Dir('.')) 123main.Append(LIBS=['elf']) 124main.Prepend(LIBPATH=[Dir('.')]) 125 | 110m4env['M4COM'] = '$M4 $M4FLAGS $SOURCES > $TARGET' 111m4env.M4(target=File('libelf_convert.c'), 112 source=[File('elf_types.m4'), File('libelf_convert.m4')]) 113m4env.M4(target=File('libelf_fsize.c'), 114 source=[File('elf_types.m4'), File('libelf_fsize.m4')]) 115m4env.M4(target=File('libelf_msize.c'), 116 source=[File('elf_types.m4'), File('libelf_msize.m4')]) 117 118# Build libelf as a static library with PIC code so it can be linked 119# into either m5 or the library 120m4env.Library('elf', [m4env.SharedObject(f) for f in elf_files]) 121 122main.Prepend(CPPPATH=Dir('.')) 123main.Append(LIBS=['elf']) 124main.Prepend(LIBPATH=[Dir('.')]) 125 |