• Reid Kleckner's avatar
    Explicitly pass linker /OPT and other flags implied by /PROFILE · bf8b9821
    Reid Kleckner authored
    LLD currently ignores /PROFILE, so it does not enable /OPT:ICF and
    /OPT:REF for chrome_elf.dll. chrome_elf_import_unittests checks that the
    linker strips dead dependencies on user32.dll and shell32.dll, so it
    currently fails when chrome_elf.dll is linked with LLD.
    
    I will fix this bug in upstream LLD, but in the meantime this will fix
    the issue. This change also seens like it is more explicit and reduces
    gn complexity, so maybe we should leave it like this after the LLD fix.
    
    R=brucedawson@chromium.org, thakis@chromium.org
    
    Bug: chromium:827075
    Change-Id: Icd2a09aab031b7ff07738892c12a5de1ec9936b9
    Reviewed-on: https://chromium-review.googlesource.com/986694
    Commit-Queue: Reid Kleckner <rnk@chromium.org>
    Reviewed-by: default avatarNico Weber <thakis@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#547105}
    bf8b9821
BUILD.gn 18.8 KB