Commit 9af97487 authored by Daniel Silveira's avatar Daniel Silveira

Hotfix: Build with multithread corrected in configure

parent 829b4f99
......@@ -66,7 +66,7 @@ build_sparc:
stage: sbuild-sparc
script:
- make clean # to be removed and used only on failure
- make -j3
- make -j4
#clean_build_sparc:
# tags:
......@@ -93,7 +93,7 @@ build_arm:
stage: sbuild-arm
script:
- make clean # to be removed and used only on failure
- make -j3
- make -j4
#clean_build_arm:
# tags:
......
......@@ -24,40 +24,40 @@ ${template.Rule('noconf', True, [ 'pmk', 'posnc', 'libs', 'tools' ])}
# PMK
${template.Rule('pmk', True, None)}
${template.RunMakeInDir(air.PMK_DIR_NAME, 'all')}
${template.RunMakeInDir(False, air.PMK_DIR_NAME, 'all')}
# POS
${template.Rule('pos', True, [ 'pmk' ])}
${template.RunMakeInDir(air.POS_DIR_NAME, 'all')}
${template.RunMakeInDir(True, air.POS_DIR_NAME, 'all')}
# POS No Configure
${template.Rule('posnc', True, [ 'pmk' ])}
${template.RunMakeInDir(air.POS_DIR_NAME, 'noconf')}
${template.RunMakeInDir(True, air.POS_DIR_NAME, 'noconf')}
# Libraries
${template.Rule('libs', True, [ 'pmk', 'pos' ])}
${template.RunMakeInDir(air.LIBS_DIR_NAME, 'all')}
${template.RunMakeInDir(True, air.LIBS_DIR_NAME, 'all')}
# Tools
${template.Rule('tools', True, None)}
${template.RunMakeInDir(os.path.join(air.TOOLS_DIR_NAME, 'partition_assembler'), 'all')}
${template.RunMakeInDir(True, os.path.join(air.TOOLS_DIR_NAME, 'partition_assembler'), 'all')}
${template.SymLink(os.path.join('..', '..', 'tools', 'configurator', 'configurator.py'), os.path.join('$(AIR_TOOLS)', 'configurator'))}
# Clean
${template.Rule('clean', True, None)}
${template.Remove(os.path.join('$(AIR_TOOLS)', 'configurator'))}
${template.RunMakeInDir(air.LIBS_DIR_NAME, 'clean')}
${template.RunMakeInDir(air.POS_DIR_NAME, 'clean')}
${template.RunMakeInDir(air.PMK_DIR_NAME, 'clean')}
${template.RunMakeInDir(os.path.join(air.TOOLS_DIR_NAME, 'partition_assembler'), 'clean')}
${template.RunMakeInDir(True, air.LIBS_DIR_NAME, 'clean')}
${template.RunMakeInDir(True, air.POS_DIR_NAME, 'clean')}
${template.RunMakeInDir(True, air.PMK_DIR_NAME, 'clean')}
${template.RunMakeInDir(True, os.path.join(air.TOOLS_DIR_NAME, 'partition_assembler'), 'clean')}
${template.Remove(air.INSTALL_DIRECTORY)}
# Distclean
${template.Rule('distclean', True, None)}
${template.RunMakeInDir(air.LIBS_DIR_NAME, 'distclean')}
${template.RunMakeInDir(air.POS_DIR_NAME, 'distclean')}
${template.RunMakeInDir(air.PMK_DIR_NAME, 'distclean')}
${template.RunMakeInDir(os.path.join(air.TOOLS_DIR_NAME, 'partition_assembler'), 'distclean')}
${template.RunMakeInDir(True, air.LIBS_DIR_NAME, 'distclean')}
${template.RunMakeInDir(True, air.POS_DIR_NAME, 'distclean')}
${template.RunMakeInDir(True, air.PMK_DIR_NAME, 'distclean')}
${template.RunMakeInDir(True, os.path.join(air.TOOLS_DIR_NAME, 'partition_assembler'), 'distclean')}
${template.Remove(air.INSTALL_DIRECTORY)}
${template.Remove('Makefile')}
${template.Remove('Makefile.inc')}
......
......@@ -8,25 +8,25 @@ ${template.FileHeader("AIR OS - Directory Makefile")}\
# All
${template.Rule('all', True, None)}
%for i, directory in enumerate(directories):
${template.RunMakeInDir(directory, 'all')}
${template.RunMakeInDir(True, directory, 'all')}
%endfor
# No Configure
${template.Rule('noconf', True, None)}
%for i, directory in enumerate(directories):
${template.RunMakeInDir(directory, 'noconf')}
${template.RunMakeInDir(True, directory, 'noconf')}
%endfor
# Clean
${template.Rule('clean', True, None)}
%for i, directory in enumerate(directories):
${template.RunMakeInDir(directory, 'clean')}
${template.RunMakeInDir(True, directory, 'clean')}
%endfor
# Distclean
${template.Rule('distclean', True, None)}
%for i, directory in enumerate(directories):
${template.RunMakeInDir(directory, 'distclean')}
${template.RunMakeInDir(True, directory, 'distclean')}
%endfor
${template.Remove(output_file)}
......@@ -19,22 +19,22 @@ ${template.MakefileInc(True)}
# All
${template.Rule('all', True, None)}
${template.RunMakeInDir('common', None)}
${template.RunMakeInDir(True, 'common', None)}
% for i, partition in enumerate(app_configuration.partitions):
${template.RunMakeInDir(partition.directory, 'all')}
${template.RunMakeInDir(True, partition.directory, 'all')}
% endfor
${template.RunMakeInDir('config', 'all')}
${template.RunMakeInDir(True, 'config', 'all')}
# Clean
${template.Rule('clean', True, None)}
${template.RunMakeInDir('common', 'clean')}
${template.RunMakeInDir(True, 'common', 'clean')}
% for i, partition in enumerate(app_configuration.partitions):
${template.RunMakeInDir(partition.directory, 'clean')}
${template.RunMakeInDir(True, partition.directory, 'clean')}
% endfor
${template.RunMakeInDir('config', 'clean')}
${template.RunMakeInDir(True, 'config', 'clean')}
# Distclean
${template.Rule('distclean', True, ['clean'])}
${template.RunMakeInDir('config', 'distclean')}
${template.RunMakeInDir(True, 'config', 'distclean')}
${'\t'}${os.path.join('$(AIR_TOOLS)', 'configurator clean')}
......@@ -117,16 +117,24 @@ ${'\t'}@($(SYMLINK) ${file} ${target})\
${'\t'}@($(RM) ${files})\
</%def>
<%def name="RunMakeInDir(dir, rule)">\
<%def name="RunMakeInDir(recurse, dir, rule)">\
<%
import os
%>\
% if os.path.isdir(os.path.join(output_dir, dir)) and (os.path.isfile(os.path.join(output_dir, dir, 'Makefile') or os.path.isfile(os.path.join(output_dir, dir, 'makefile')))):
% if recurse:
% if rule is not None:
${'\t'}$(MAKE) -C ${dir} ${rule}\
% else:
${'\t'}$(MAKE) -C ${dir}\
% endif
% else:
% if rule is not None:
${'\t'}make -C ${dir} ${rule}\
% else:
${'\t'}make -C ${dir}\
% endif
% endif
% endif
</%def>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment