diff options
author | Edmund Wu <fangkazuto@gmail.com> | 2020-06-12 14:01:43 -0400 |
---|---|---|
committer | Edmund Wu <fangkazuto@gmail.com> | 2020-06-12 14:01:43 -0400 |
commit | 107f7ba0263dc6225cc0d3bafa10f7581c5444d0 (patch) | |
tree | 969404334d3a50dd978a442ede9fc1a1adb4e0a2 /pkgs/os-specific/linux/musl | |
parent | da60549504f23c7ee03f72e8ce8bef9ccf6f79b7 (diff) |
musl: include libc.musl-$arch
Diffstat (limited to 'pkgs/os-specific/linux/musl')
-rw-r--r-- | pkgs/os-specific/linux/musl/default.nix | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/pkgs/os-specific/linux/musl/default.nix b/pkgs/os-specific/linux/musl/default.nix index 51dcf4cfca333..422ad5c1cb507 100644 --- a/pkgs/os-specific/linux/musl/default.nix +++ b/pkgs/os-specific/linux/musl/default.nix @@ -26,6 +26,12 @@ let sha256 = "1mzxnc2ncq8lw9x6n7p00fvfklc9p3wfv28m68j0dfz5l8q2k6pp"; }; + arch = if stdenv.hostPlatform.isx86_64 + then "x86_64" + else if stdenv.hostPlatform.isx86_32 + then "i386" + else null; + in stdenv.mkDerivation rec { pname = "musl"; @@ -102,6 +108,9 @@ stdenv.mkDerivation rec { -lc \ -B $out/lib \ -Wl,-dynamic-linker=$(ls $out/lib/ld-*) + '' + lib.optionalString (arch != null) '' + # Create 'libc.musl-$arch' symlink + ln -rs $out/lib/libc.so $out/lib/libc.musl-${arch}.so.1 '' + lib.optionalString useBSDCompatHeaders '' install -D ${queue_h} $dev/include/sys/queue.h install -D ${cdefs_h} $dev/include/sys/cdefs.h |