Changeset d3357e9 in mainline


Ignore:
Timestamp:
2019-08-17T12:49:43Z (5 years ago)
Author:
Jiří Zárevúcky <zarevucky.jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
f69d5a8
Parents:
56440a5
git-author:
Jiří Zárevúcky <zarevucky.jiri@…> (2019-06-30 15:23:58)
git-committer:
Jiří Zárevúcky <zarevucky.jiri@…> (2019-08-17 12:49:43)
Message:

Make building bootable images optional

Files:
4 edited

Legend:

Unmodified
Added
Removed
  • boot/meson.build

    r56440a5 rd3357e9  
    8181        endif
    8282
     83        boot_files = static_library('bootfiles', boot_src,
     84                include_directories: boot_include_dirs,
     85                implicit_include_directories: false,
     86                c_args: boot_c_args,
     87                pic: false,
     88                build_by_default: true,
     89        )
     90
    8391        # Preprocess linker script using C preprocessor.
    8492        boot_ldscript = custom_target('_link.ld',
     
    97105                ],
    98106                capture: true,
     107                build_by_default: true
    99108        )
    100109
     
    133142        boot_image_map_path = meson.current_build_dir()/boot_image_name + '.map'
    134143
    135         boot_elf = executable(boot_image_name + '.elf', boot_src, boot_comps_o,
     144        boot_elf = executable(boot_image_name + '.elf', boot_comps_o,
    136145                include_directories: boot_include_dirs,
    137                 implicit_include_directories: false,
    138146                c_args: boot_c_args,
    139147                link_args: boot_c_args + boot_link_args + [
     
    141149                ],
    142150                link_depends: boot_ldscript,
    143                 install: true,
    144                 install_dir: 'boot',
     151                link_whole: boot_files,
    145152                pie: false,
     153                build_by_default: false,
    146154        )
    147155
     
    160168endif
    161169
    162 if POSTBUILD == 'none'
    163         POST_INPUT = disabler()
    164 endif
    165 
    166170if POSTBUILD == 'raw'
    167171        POST_INPUT = boot_image
  • build_all.sh

    r56440a5 rd3357e9  
    2222
    2323
    24 echo "Configuring all profiles."
     24echo
     25echo "###################### Configuring all profiles ######################"
    2526
    2627for profile in $PROFILES; do
    2728        if [ -f ${profile}/build.ninja ]; then
    28                 echo "Profile ${profile} already configured."
     29                ninja -C ${profile} build.ninja || exit 1
    2930                continue
    3031        fi
     
    5152done
    5253
    53 
    54 echo "Building all profiles."
     54echo
     55echo "###################### Building all profiles ######################"
    5556
    5657for profile in $PROFILES; do
    57         ninja -C ${profile}
     58        ninja -C ${profile} || exit 1
    5859done
     60
     61
     62if [ "$#" -eq 1 ] && [ "$1" = 'images' ]; then
     63        echo "###################### Building all images ######################"
     64
     65        for profile in $PROFILES; do
     66                ninja -C ${profile} image_path || exit 1
     67        done
     68else
     69        echo
     70        echo "Bootable images not built."
     71        echo "Run '$0 images' to build them as well."
     72fi
  • kernel/meson.build

    r56440a5 rd3357e9  
    5454        ],
    5555        capture: true,
     56        build_by_default: true,
    5657)
    5758
  • meson.build

    r56440a5 rd3357e9  
    518518subdir('boot')
    519519
    520 custom_target(POST_OUTPUT,
    521         output: POST_OUTPUT,
    522         input: POST_INPUT,
    523         command: [ cp, '@INPUT@', '@OUTPUT@' ],
    524         build_by_default: true,
    525 )
     520if is_variable('POST_INPUT')
     521        image = custom_target(POST_OUTPUT,
     522                output: POST_OUTPUT,
     523                input: POST_INPUT,
     524                command: [ cp, '@INPUT@', '@OUTPUT@' ],
     525        )
     526
     527        custom_target('image_path',
     528                output: 'image_path',
     529                input: image,
     530                command: [ 'echo', '@INPUT@' ],
     531                capture: true,
     532        )
     533else
     534        custom_target('image_path',
     535                output: 'image_path',
     536                command: [ 'echo' ],
     537                capture: true,
     538        )
     539endif
Note: See TracChangeset for help on using the changeset viewer.