Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • meson/part/compiler_args/meson.build

    r18969ce rc89ae25  
    6060        '-Wall',
    6161        '-Wextra',
    62         '-Werror-implicit-function-declaration',
    6362        '-Wwrite-strings',
    6463        '-Wunknown-pragmas',
     
    6968
    7069        '-ffunction-sections',
     70        '-fdata-sections',
    7171        '-fno-common',
    72         '-fdebug-prefix-map=' + meson.source_root() + '=.',
     72        '-fdebug-prefix-map=' + meson.source_root() + '/=',
     73        '-fdebug-prefix-map=../../=',
    7374]
    7475
     
    8788
    8889if CONFIG_LINE_DEBUG
    89         extra_common_flags += [ '-gdwarf-4', '-g3' ]
     90        extra_common_flags += [ '-gdwarf-5', '-g3' ]
    9091endif
    9192
    9293extra_cflags = extra_common_flags + [
    9394        '-Wmissing-prototypes',
     95        '-Werror-implicit-function-declaration',
    9496
    9597        '-Wno-missing-braces',
     
    110112extra_cppflags = extra_common_flags + [
    111113        '-fno-exceptions',
     114        '-Wno-misleading-indentation',
    112115        '-frtti',
    113116]
     
    128131        add_project_link_arguments(extra_cflags, language : [ lang ])
    129132endforeach
     133
     134# This flag is needed at several places, hence we define it here.
     135#
     136# For backwards compatibility we try to detect --no-warn-rwx-segments.
     137# However, the autodetection done by Meson also results in
     138# "cannot find entry symbol _start; defaulting to 00000000004000b0"
     139# thus the option is never supported alone. So when detecting we also
     140# specify --entry=main so that the stub source provided by Meson is build
     141# correctly.
     142ldflags_ignore_rwx_segments = []
     143if cc.has_link_argument('-Wl,--no-warn-rwx-segments,--entry=main')
     144    ldflags_ignore_rwx_segments += ['-Wl,--no-warn-rwx-segments']
     145endif
Note: See TracChangeset for help on using the changeset viewer.