Changeset 85e14e0 in rtems-tools


Ignore:
Timestamp:
May 10, 2017, 11:09:02 AM (2 years ago)
Author:
Chris Johns <chrisj@…>
Branches:
master
Children:
9a8a03c
Parents:
ad15f6b
Message:

rtems-bsp-builder: Fix excluding builds.

Excluding builds was not working. This patch fixes that and it
also correctly handles mixed builds.

Location:
tester
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • tester/rt/check.py

    rad15f6b r85e14e0  
    3232
    3333import argparse
     34import copy
    3435import datetime
    3536import operator
     
    543544                arch['excludes'][exclude] = ['all']
    544545            for i in self._get_items(a, False):
    545                 if i[0].startswith('exclude_'):
    546                     exclude = i[0][len('exclude_'):]
     546                if i[0].startswith('exclude-'):
     547                    exclude = i[0][len('exclude-'):]
    547548                    if exclude not in arch['excludes']:
    548549                        arch['excludes'][exclude] = []
     
    584585    def builds(self):
    585586        if self.builds_['build'] in self.builds_['builds']:
    586             build = self.builds_['builds'][self.builds_['build']]
     587            build = copy.copy(self.builds_['builds'][self.builds_['build']])
    587588            if ':' in build[0]:
    588589                return [self.builds_['build']]
     
    615616        excludes = self.archs[arch]['excludes'].keys()
    616617        for exclude in self.archs[arch]['excludes']:
    617             if bsp not in self.archs[arch]['excludes'][exclude]:
     618            if 'all' not in self.archs[arch]['excludes'][exclude] and \
     619               bsp not in self.archs[arch]['excludes'][exclude]:
    618620                excludes.remove(exclude)
    619621        return sorted(excludes)
     
    643645            s1 = ' ' * len(s1)
    644646        s += textbox.line(cols_1, marker = '+', indent = 1)
    645         s += textbox.line(cols_1, line = '=', marker = '+', indent = 1)
     647        s += os.linesep
    646648        if profiles:
     649            s += textbox.line(cols_1, line = '=', marker = '+', indent = 1)
    647650            profiles = sorted(self.profiles['profiles'])
    648651            bsps = 0
     
    671674                        s1 = ' ' * len(s1)
    672675                s += textbox.line(cols_2, marker = '+', indent = 1)
     676            s += os.linesep
    673677        if builds:
    674678            s += textbox.line(cols_1, line = '=', marker = '+', indent = 1)
     
    706710                    s1 = ' ' * len(s1)
    707711                s += textbox.line(cols_c, marker = '+', indent = 1)
     712            s += os.linesep
    708713        if architectures:
    709714            s += textbox.line(cols_1, line = '=', marker = '+', indent = 1)
     
    745750                        excludes = []
    746751                        for exclude in arch['excludes']:
    747                             if bsp in arch['excludes'][exclude]:
     752                            if 'all' in arch['excludes'][exclude] or \
     753                               bsp in arch['excludes'][exclude]:
    748754                                excludes += [exclude]
    749755                        excludes = ', '.join(excludes)
     
    756762                            s += textbox.row(cols_b, [s1, ' '], indent = 1)
    757763                    s += textbox.line(cols_b, marker = '+', indent = 1)
     764            s += os.linesep
    758765        return s
    759766
     
    803810        if builds is None:
    804811            return None
    805         for b in self.config.excludes(arch):
    806             if b in builds:
    807                 builds.remove(b)
    808         for b in self.config.bsp_excludes(arch, bsp):
    809             if b in builds:
    810                 builds.remove(b)
     812        excludes = set(self.config.excludes(arch) +
     813                       self.config.bsp_excludes(arch, bsp))
     814        remove = []
     815        for e in excludes:
     816            remove += [b for b in builds if e in b]
     817        for b in remove:
     818            builds.remove(b)
    811819        return builds
    812820
     
    11031111        log.notice(title())
    11041112        log.output(command_line())
     1113
     1114        config = configuration()
     1115        config.load(config_file, opts.build)
     1116
     1117        if opts.config_report:
     1118            log.notice('Configuration Report:')
     1119            log.notice(config.report())
     1120            sys.exit(0)
     1121
    11051122        if opts.rtems is None:
    11061123            raise error.general('No RTEMS source provided on the command line')
     
    11131130        if opts.bsp is not None and opts.arch is None:
    11141131            raise error.general('BSP provided but no architecture')
    1115 
    1116         config = configuration()
    1117         config.load(config_file, opts.build)
    1118 
    1119         if opts.config_report:
    1120             log.notice('Configuration Report:')
    1121             log.notice(config.report())
    1122             sys.exit(0)
    11231132
    11241133        options = { 'stop-on-error'   : opts.stop_on_error,
  • tester/rtems/rtems-bsps.ini

    rad15f6b r85e14e0  
    108108    xilinx_zynq_zc702, xilinx_zynq_zc706, xilinx_zynq_zedboard,
    109109    xilinx_zynq_a9_qemu
    110 exclude_smp = arm1136jfs,
     110exclude-smp = arm1136jfs,
    111111    arm1136js, arm7tdmi, arm920, armcortexa9, atsamv,
    112112    beagleboardorig, beagleboardxm, beagleboneblack, beaglebonewhite,
     
    130130    tms570ls3137_hdk_sdram,
    131131    tms570ls3137_hdk_with_loader
    132 exclude_network =
     132exclude-network =
    133133    altcycv_devkit, altcycv_devkit_smp,
    134     realview_pbx_a9_qemu, realview_pbx_a9_qemu_smp,
     134    realview_pbx_a9_qemu, realview_pbx_a9_qemu_smp
    135135
    136136[i386]
Note: See TracChangeset for help on using the changeset viewer.