Changeset 3f0f739 in rtems-libbsd


Ignore:
Timestamp:
02/24/22 13:56:15 (8 months ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
6-freebsd-12
Children:
2722615
Parents:
117e0cd
git-author:
Sebastian Huber <sebastian.huber@…> (02/24/22 13:56:15)
git-committer:
Sebastian Huber <sebastian.huber@…> (06/23/22 08:46:17)
Message:

build: Ensure mandatory compiler/linker flags

Make sure the flags are present in all build configurations.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • waf_libbsd.py

    r117e0cd r3f0f739  
    195195                    else:
    196196                        bld.fatal('invalid config test: %s' % (configTest))
    197             section_flags = ["-fdata-sections", "-ffunction-sections"]
    198             _add_flags_if_not_present(conf.env.CFLAGS, section_flags)
    199             _add_flags_if_not_present(conf.env.CXXFLAGS, section_flags)
    200             _add_flags_if_not_present(conf.env.LINKFLAGS, ["-Wl,--gc-sections"])
    201197            conf.env.CFLAGS = _remove_bsp_include_path(conf.env.IFLAGS,
    202198                                                       conf.env.CFLAGS)
     
    205201            conf.env.LINKFLAGS = _remove_bsp_include_path(conf.env.IFLAGS,
    206202                                                          conf.env.LINKFLAGS)
     203        section_flags = ["-fdata-sections", "-ffunction-sections"]
     204        _add_flags_if_not_present(conf.env.CFLAGS, section_flags)
     205        _add_flags_if_not_present(conf.env.CXXFLAGS, section_flags)
     206        _add_flags_if_not_present(conf.env.LINKFLAGS, ["-Wl,--gc-sections"])
    207207
    208208    def build(self, bld):
Note: See TracChangeset for help on using the changeset viewer.