Changeset 63660a3 in mainline for kernel/meson.build


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:
41408d94
Parents:
2c38a55b
git-author:
Jiří Zárevúcky <zarevucky.jiri@…> (2019-06-26 14:31:18)
git-committer:
Jiří Zárevúcky <zarevucky.jiri@…> (2019-08-17 12:49:43)
Message:

shuffle some variables around

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/meson.build

    r2c38a55b r63660a3  
    11
    2 ## The at-sign
    3 #
    4 # The `atsign` variable holds the ASCII character representing the at-sign
    5 # ('@') used in various $(AS) constructs (e.g. @progbits). On architectures that
    6 # don't use '@' for starting a comment, `atsign` is merely '@'. However, on
    7 # those that do use it for starting a comment (e.g. arm32), `atsign` must be
    8 # defined as the percentile-sign ('%') in the architecture-dependent files.
    9 #
    10 atsign = '@'
    11 
    12 ## Some architectures need a particular string at the beginning of assembly files.
    13 as_prolog = ''
    14 
    15 kernel_c_args = []
    16 kernel_link_args = []
    17 kernel_includes = []
    182arch_src = []
    193
     4# Fills arch_src.
    205subdir('arch' / h_arch)
     6
     7# Defines genarch_src.
    218subdir('genarch')
     9
     10# Defines generic_src, instrumentable_src.
    2211subdir('generic')
     12
     13# Defines test_src
    2314subdir('test')
    2415
     
    2718symtab_section = '.section symtab.data, "a", ' + atsign + 'progbits;'
    2819
    29 kernel_includes += include_directories(
     20kernel_include_dirs = include_directories(
    3021        'generic/include',
    3122        'genarch/include',
     
    4637]
    4738
     39# Preprocess linker script using C preprocessor.
    4840kernel_ldscript = custom_target('_link.ld',
    4941        input: 'arch' / h_arch / '_link.ld.in',
     
    6355)
    6456
    65 kernel_link_args += [
     57kernel_link_args = arch_kernel_link_args + [
    6658        '-Wl,--nmagic',
    6759        '-T', meson.current_build_dir() / '_link.ld',
     
    7365endif
    7466
    75 kernel_c_args += kernel_defs + [
     67kernel_c_args = arch_kernel_c_args + kernel_defs + [
    7668        '-ffreestanding',
    7769        # TODO: remove this flag
     
    8880
    8981instrumentables = static_library('instrumentables', instrumentable_src,
    90         include_directories: kernel_includes,
     82        include_directories: kernel_include_dirs,
    9183        implicit_include_directories: false,
    9284        c_args: kernel_c_args + (CONFIG_TRACE ? [ '-finstrument-functions' ] : []),
     
    9587
    9688noninstrumentables = static_library('noninstrumentables', arch_src, genarch_src, generic_src, test_src,
    97         include_directories: kernel_includes,
     89        include_directories: kernel_include_dirs,
    9890        implicit_include_directories: false,
    9991        c_args: kernel_c_args,
     
    129121        output: 'empty_map.S',
    130122        capture: true,
    131         command: [ 'echo', as_prolog + symtab_section ],
     123        command: [ 'echo', kernel_as_prolog + symtab_section ],
    132124)
    133125
     
    139131
    140132        kernel_elf = executable(kernel_name + '.elf', kernel_map_S,
    141                 include_directories: kernel_includes,
     133                include_directories: kernel_include_dirs,
    142134                implicit_include_directories: false,
    143135                c_args: kernel_c_args,
     
    170162                        output: kernel_map_S_name,
    171163                        capture: true,
    172                         command: [ 'echo', as_prolog + symtab_section + ' .incbin "@INPUT@"' ],
     164                        command: [ 'echo', kernel_as_prolog + symtab_section + ' .incbin "@INPUT@"' ],
    173165                )
    174166        endif
Note: See TracChangeset for help on using the changeset viewer.