mirror of
https://git.rtems.org/rtems-source-builder
synced 2024-10-09 07:15:10 +08:00
parent
650c6f9933
commit
c51f634258
@ -20,8 +20,6 @@
|
|||||||
|
|
||||||
from __future__ import print_function
|
from __future__ import print_function
|
||||||
|
|
||||||
import sb.check
|
|
||||||
|
|
||||||
try:
|
try:
|
||||||
import sb.check
|
import sb.check
|
||||||
sb.check.run()
|
sb.check.run()
|
||||||
|
20
source-builder/sb/__init__.py
Normal file
20
source-builder/sb/__init__.py
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
#
|
||||||
|
# RTEMS Tools Project (http://www.rtems.org/)
|
||||||
|
# Copyright 2020 Chris Johns (chrisj@rtems.org)
|
||||||
|
# All rights reserved.
|
||||||
|
#
|
||||||
|
# This file is part of the RTEMS Tools package in 'rtems-tools'.
|
||||||
|
#
|
||||||
|
# Permission to use, copy, modify, and/or distribute this software for any
|
||||||
|
# purpose with or without fee is hereby granted, provided that the above
|
||||||
|
# copyright notice and this permission notice appear in all copies.
|
||||||
|
#
|
||||||
|
# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||||
|
# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||||
|
# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||||
|
# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||||
|
# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||||
|
# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
|
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
|
||||||
|
from __future__ import print_function
|
@ -48,8 +48,7 @@ except KeyboardInterrupt:
|
|||||||
print('abort: user terminated')
|
print('abort: user terminated')
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
except:
|
except:
|
||||||
print('error: unknown application load error')
|
raise
|
||||||
sys.exit(1)
|
|
||||||
|
|
||||||
def humanize_number(num, suffix):
|
def humanize_number(num, suffix):
|
||||||
for unit in ['','K','M','G','T','P','E','Z']:
|
for unit in ['','K','M','G','T','P','E','Z']:
|
||||||
|
@ -45,8 +45,7 @@ except KeyboardInterrupt:
|
|||||||
print('user terminated', file = sys.stderr)
|
print('user terminated', file = sys.stderr)
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
except:
|
except:
|
||||||
print('error: unknown application load error', file = sys.stderr)
|
raise
|
||||||
sys.exit(1)
|
|
||||||
|
|
||||||
def _check_bool(value):
|
def _check_bool(value):
|
||||||
istrue = None
|
istrue = None
|
||||||
|
@ -40,8 +40,7 @@ except KeyboardInterrupt:
|
|||||||
print('abort: user terminated', file = sys.stderr)
|
print('abort: user terminated', file = sys.stderr)
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
except:
|
except:
|
||||||
print('error: unknown application load error', file = sys.stderr)
|
raise
|
||||||
sys.exit(1)
|
|
||||||
|
|
||||||
def run(args = sys.argv):
|
def run(args = sys.argv):
|
||||||
ec = 0
|
ec = 0
|
||||||
|
@ -23,10 +23,10 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
import multiprocessing
|
import multiprocessing
|
||||||
|
import platform
|
||||||
import pprint
|
import pprint
|
||||||
import os
|
import os
|
||||||
|
|
||||||
from . import platform
|
|
||||||
from . import path
|
from . import path
|
||||||
|
|
||||||
def load():
|
def load():
|
||||||
|
@ -30,9 +30,6 @@ import datetime
|
|||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
|
|
||||||
import pprint
|
|
||||||
pp = pprint.PrettyPrinter(indent = 2)
|
|
||||||
|
|
||||||
try:
|
try:
|
||||||
from . import build
|
from . import build
|
||||||
from . import check
|
from . import check
|
||||||
@ -42,15 +39,13 @@ try:
|
|||||||
from . import log
|
from . import log
|
||||||
from . import options
|
from . import options
|
||||||
from . import path
|
from . import path
|
||||||
from . import setbuilder
|
|
||||||
from . import sources
|
from . import sources
|
||||||
from . import version
|
from . import version
|
||||||
except KeyboardInterrupt:
|
except KeyboardInterrupt:
|
||||||
print('user terminated', file = sys.stderr)
|
print('user terminated', file = sys.stderr)
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
except:
|
except:
|
||||||
print('error: unknown application load error', file = sys.stderr)
|
raise
|
||||||
sys.exit(1)
|
|
||||||
|
|
||||||
_line_len = 78
|
_line_len = 78
|
||||||
|
|
||||||
@ -865,6 +860,7 @@ class report:
|
|||||||
raise error.general('writing output file: %s: %s' % (name, err))
|
raise error.general('writing output file: %s: %s' % (name, err))
|
||||||
|
|
||||||
def generate(self, name, tree = None, opts = None, macros = None):
|
def generate(self, name, tree = None, opts = None, macros = None):
|
||||||
|
from . import setbuilder
|
||||||
self.buildset_start(name)
|
self.buildset_start(name)
|
||||||
if tree is None:
|
if tree is None:
|
||||||
tree = self.tree
|
tree = self.tree
|
||||||
@ -899,6 +895,7 @@ class report:
|
|||||||
|
|
||||||
def run(args):
|
def run(args):
|
||||||
try:
|
try:
|
||||||
|
from . import setbuilder
|
||||||
optargs = { '--list-bsets': 'List available build sets',
|
optargs = { '--list-bsets': 'List available build sets',
|
||||||
'--list-configs': 'List available configurations',
|
'--list-configs': 'List available configurations',
|
||||||
'--format': 'Output format (text, html, markdown, ini, xml)',
|
'--format': 'Output format (text, html, markdown, ini, xml)',
|
||||||
|
@ -48,8 +48,7 @@ except KeyboardInterrupt:
|
|||||||
print('abort: user terminated', file = sys.stderr)
|
print('abort: user terminated', file = sys.stderr)
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
except:
|
except:
|
||||||
print('error: unknown application load error', file = sys.stderr)
|
raise
|
||||||
sys.exit(1)
|
|
||||||
|
|
||||||
def macro_expand(macros, _str):
|
def macro_expand(macros, _str):
|
||||||
cstr = None
|
cstr = None
|
||||||
|
@ -33,8 +33,7 @@ except KeyboardInterrupt:
|
|||||||
print('abort: user terminated', file = sys.stderr)
|
print('abort: user terminated', file = sys.stderr)
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
except:
|
except:
|
||||||
print('error: unknown application load error', file = sys.stderr)
|
raise
|
||||||
sys.exit(1)
|
|
||||||
|
|
||||||
def expand(macros, line):
|
def expand(macros, line):
|
||||||
#
|
#
|
||||||
|
@ -42,8 +42,7 @@ except KeyboardInterrupt:
|
|||||||
print('abort: user terminated', file = sys.stderr)
|
print('abort: user terminated', file = sys.stderr)
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
except:
|
except:
|
||||||
print('error: unknown application load error', file = sys.stderr)
|
raise
|
||||||
sys.exit(1)
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# Define host profiles so it can simulated on another host.
|
# Define host profiles so it can simulated on another host.
|
||||||
|
@ -41,8 +41,7 @@ except KeyboardInterrupt:
|
|||||||
print('abort: user terminated', file = sys.stderr)
|
print('abort: user terminated', file = sys.stderr)
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
except:
|
except:
|
||||||
print('error: unknown application load error', file = sys.stderr)
|
raise
|
||||||
sys.exit(1)
|
|
||||||
|
|
||||||
def unique(l):
|
def unique(l):
|
||||||
return sorted(list(set(l)))
|
return sorted(list(set(l)))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user