source: rtems-tools/tester/covoar/wscript @ 4cee5c3

Last change on this file since 4cee5c3 was 4cee5c3, checked in by Krzysztof Miesowicz <krzysztof.miesowicz@…>, on Aug 26, 2017 at 8:15:55 AM

covoar/wscript: Add paths to rtemstoolkit to build.

Co-Author: Cillian O'Donnell <cpodonnell8@…>

  • Property mode set to 100644
File size: 4.6 KB
Line 
1#
2# RTEMS Tools Project (http://www.rtems.org/)
3# Copyright 2014 Chris Johns (chrisj@rtems.org)
4# All rights reserved.
5#
6# This file is part of the RTEMS Tools package in 'rtems-tools'.
7#
8# Redistribution and use in source and binary forms, with or without
9# modification, are permitted provided that the following conditions are met:
10#
11# 1. Redistributions of source code must retain the above copyright notice,
12# this list of conditions and the following disclaimer.
13#
14# 2. Redistributions in binary form must reproduce the above copyright notice,
15# this list of conditions and the following disclaimer in the documentation
16# and/or other materials provided with the distribution.
17#
18# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
19# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
21# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
22# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
23# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
24# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
25# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
26# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
27# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
28# POSSIBILITY OF SUCH DAMAGE.
29#
30
31#
32# Build the covoar application.
33#
34# Taken from the waf C++ demo.
35#
36
37#
38# The following two variables are used by the target "waf dist".
39#
40VERSION='0.0.1'
41APPNAME='covoar'
42
43#
44# These variables are mandatory ('/' are converted automatically)
45#
46top = '.'
47out = 'build'
48
49def init(ctx):
50    pass
51
52rtl_includes = ['../../rtemstoolkit',
53                '../../rtemstoolkit/elftoolchain/common',
54                '../../rtemstoolkit/elftoolchain/libelf',
55                '../../rtemstoolkit/libiberty']
56
57def options(opt):
58    opt.load('compiler_cxx')
59
60def configure(conf):
61    conf.load('compiler_cxx')
62    conf.check_cc(function_name='open64', header_name="stdlib.h", mandatory = False)
63    conf.check_cc(function_name='stat64', header_name="stdlib.h", mandatory = False)
64    conf.write_config_header('covoar-config.h')
65    conf.env.STLIBPATH_RLD = conf.path.abspath() + '/../../build/rtemstoolkit'
66    conf.env.STLIB_RLD = ['rld','iberty','elf']
67
68def build(bld):
69    bld.stlib(target = 'ccovoar',
70              source = ['app_common.cc',
71                        'ConfigFile.cc',
72                        'CoverageFactory.cc',
73                        'CoverageMap.cc',
74                        'CoverageMapBase.cc',
75                        'CoverageRanges.cc',
76                        'CoverageReaderBase.cc',
77                        'CoverageReaderQEMU.cc',
78                        'CoverageReaderRTEMS.cc',
79                        'CoverageReaderSkyeye.cc',
80                        'CoverageReaderTSIM.cc',
81                        'CoverageWriterBase.cc',
82                        'CoverageWriterRTEMS.cc',
83                        'CoverageWriterSkyeye.cc',
84                        'CoverageWriterTSIM.cc',
85                        'DesiredSymbols.cc',
86                        'ExecutableInfo.cc',
87                        'Explanations.cc',
88                        'GcovData.cc',
89                        'GcovFunctionData.cc',
90                        'ObjdumpProcessor.cc',
91                        'ReportsBase.cc',
92                        'ReportsText.cc',
93                        'ReportsHtml.cc',
94                        'SymbolTable.cc',
95                        'Target_arm.cc',
96                        'TargetBase.cc',
97                        'TargetFactory.cc',
98                        'Target_i386.cc',
99                        'Target_lm32.cc',
100                        'Target_m68k.cc',
101                        'Target_powerpc.cc',
102                        'Target_sparc.cc'],
103              cflags = ['-O2', '-g'],
104              cxxflags = ['-std=c++11', '-O2', '-g'],
105              includes = ['.'] + rtl_includes)
106
107    bld.program(target = 'trace-converter',
108                source = ['TraceConverter.cc',
109                          'TraceList.cc',
110                          'TraceReaderBase.cc',
111                          'TraceReaderLogQEMU.cc',
112                          'TraceWriterBase.cc',
113                          'TraceWriterQEMU.cc'],
114                use = ['ccovoar','RLD'],
115                cflags = ['-O2', '-g'],
116                includes = ['.'] + rtl_includes)
117
118    bld.program(target = 'covoar',
119                source = ['covoar.cc'],
120                use = ['ccovoar','RLD'],
121                cflags = ['-O2', '-g'],
122                includes = ['.'] + rtl_includes)
Note: See TracBrowser for help on using the repository browser.