# (https://www.kernel.org/pub/tools/crosstool/files/bin/), except the followings:
# arc: https://github.com/foss-for-synopsys-dwc-arc-processors/toolchain/releases
# blackfin: http://sourceforge.net/projects/adi-toolchain/files/
-# nds32: http://osdk.andestech.com/packages/
+# nds32: http://osdk.andestech.com/packages/nds32le-linux-glibc-v1.tgz
# nios2: https://sourcery.mentor.com/GNUToolchain/subscription42545
# sh: http://sourcery.mentor.com/public/gnu_toolchain/sh-linux-gnu
+#
+# openrisc kernel.org toolchain is out of date, download latest one from
+# http://opencores.org/or1k/OpenRISC_GNU_tool_chain#Prebuilt_versions
CROSS_COMPILE = {
'arc': 'arc-linux-',
'aarch64': 'aarch64-linux-',
'mips': 'mips-linux-',
'nds32': 'nds32le-linux-',
'nios2': 'nios2-linux-gnu-',
- 'openrisc': 'or32-linux-',
+ 'openrisc': 'or1k-elf-',
'powerpc': 'powerpc-linux-',
'sh': 'sh-linux-gnu-',
'sparc': 'sparc-linux-',
color_text(color_enabled, color, msg) + '\n'
def update_cross_compile():
- """Update per-arch CROSS_COMPILE via enviroment variables
+ """Update per-arch CROSS_COMPILE via environment variables
The default CROSS_COMPILE values are available
in the CROSS_COMPILE list above.
- You can override them via enviroment variables
+ You can override them via environment variables
CROSS_COMPILE_{ARCH}.
For example, if you want to override toolchain prefixes
pass
shutil.rmtree(self.build_dir)
- def add(self, defconfig):
+ def add(self, defconfig, num, total):
"""Assign a new subprocess for defconfig and add it to the slot.
If the slot is vacant, create a new subprocess for processing the
stderr=subprocess.PIPE)
self.defconfig = defconfig
self.state = STATE_DEFCONFIG
+ self.num = num
+ self.total = total
return True
def poll(self):
if self.state == STATE_AUTOCONF:
self.parser.update_defconfig(self.defconfig)
+ print ' %d defconfigs out of %d\r' % (self.num + 1, self.total),
+ sys.stdout.flush()
+
"""Save off the defconfig in a consistent way"""
cmd = list(self.make_cmd)
cmd.append('savedefconfig')
for i in range(options.jobs):
self.slots.append(Slot(config_attrs, options, devnull, make_cmd))
- def add(self, defconfig):
+ def add(self, defconfig, num, total):
"""Add a new subprocess if a vacant slot is found.
Arguments:
Return True on success or False on failure
"""
for slot in self.slots:
- if slot.add(defconfig):
+ if slot.add(defconfig, num, total):
return True
return False
# Main loop to process defconfig files:
# Add a new subprocess into a vacant slot.
# Sleep if there is no available slot.
- for defconfig in defconfigs:
- while not slots.add(defconfig):
+ for i, defconfig in enumerate(defconfigs):
+ while not slots.add(defconfig, i, len(defconfigs)):
while not slots.available():
# No available slot: sleep for a while
time.sleep(SLEEP_TIME)
while not slots.empty():
time.sleep(SLEEP_TIME)
+ print ''
slots.show_failed_boards()
def bad_recipe(filename, linenum, msg):