2
# compiler definition for tru64/OSF1 cc compiler
3
# based on suncc.py from waf
6
import Utils, Options, Configure
8
from Configure import conftest
10
from compiler_cc import c_compiler
12
c_compiler['osf1V'] = ['gcc', 'tru64cc']
15
def find_tru64cc(conf):
18
if v['CC']: cc = v['CC']
19
elif 'CC' in conf.environ: cc = conf.environ['CC']
20
if not cc: cc = conf.find_program('cc', var='CC')
21
if not cc: conf.fatal('tru64cc was not found')
22
cc = conf.cmd_to_list(cc)
25
if not Utils.cmd_output(cc + ['-V']):
26
conf.fatal('tru64cc %r was not found' % cc)
28
conf.fatal('tru64cc -V could not be executed')
31
v['CC_NAME'] = 'tru64'
34
def tru64cc_common_flags(conf):
38
v['CC_TGT_F'] = ['-c', '-o', '']
39
v['CPPPATH_ST'] = '-I%s' # template for adding include paths
42
if not v['LINK_CC']: v['LINK_CC'] = v['CC']
44
v['CCLNK_TGT_F'] = ['-o', '']
46
v['LIB_ST'] = '-l%s' # template for adding libs
47
v['LIBPATH_ST'] = '-L%s' # template for adding libpaths
48
v['STATICLIB_ST'] = '-l%s'
49
v['STATICLIBPATH_ST'] = '-L%s'
50
v['CCDEFINES_ST'] = '-D%s'
52
# v['SONAME_ST'] = '-Wl,-h -Wl,%s'
53
# v['SHLIB_MARKER'] = '-Bdynamic'
54
# v['STATICLIB_MARKER'] = '-Bstatic'
57
v['program_PATTERN'] = '%s'
60
# v['shlib_CCFLAGS'] = ['-Kpic', '-DPIC']
61
v['shlib_LINKFLAGS'] = ['-shared']
62
v['shlib_PATTERN'] = 'lib%s.so'
65
# v['staticlib_LINKFLAGS'] = ['-Bstatic']
66
# v['staticlib_PATTERN'] = 'lib%s.a'