Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nixpkgs
base: 52419cc32e54
Choose a base ref
...
head repository: NixOS/nixpkgs
compare: e8bfa708c474
Choose a head ref
  • 1 commit
  • 2 files changed
  • 1 contributor

Commits on Aug 11, 2020

  1. meson: Fix rpath clearing

    Meson allows projects to set `build_rpath` property, containing paths
    that will be added during build but will be removed when installing.
    
    When Meson removes build_rpath from `DT_RUNPATH` entry, it just writes
    the shorter ␀-terminated new rpath over the old one to reduce
    the risk of potentially breaking the ELF files
    (when the linker does string de-duplication or something).
    But this can cause much bigger problem for Nix, as it can produce
    cut-in-half-by-␀ store path references.
    
    For example, in systemd’s libudev, it was removing three `$ORIGIN`-relative paths from
    
        $ORIGIN/../libsystemd:$ORIGIN/../basic:$ORIGIN/../shared:…␀
    
    resulting in the following `DT_RUNPATH` entry:
    
        …␀store/v589pqjhvxrj73g3r0xb41yr84z5pwb7-gcc-9.3.0-lib/lib␀
    
    We previously handled this in `fix-rpath.patch` but the method we prevent
    Meson from removing paths added to rpath through `NIX_LDFLAGS` was changed
    during 0.55.0 update and I forgot about this second purpose of the patch.
    
    Let’s re-add this clearing code, as it worked without issues for a long time.
    jtojnar authored and FRidh committed Aug 11, 2020
    Copy the full SHA
    e8bfa70 View commit details
    Browse the repository at this point in the history