pkgsMusl.liburing: fix build

Musl doesn't have ucontext.h.  Quoting getcontext(3):

> POSIX.1-2008 removes the specification of getcon‐ text(), citing
> portability issues, and recommending that applications be rewritten
> to use POSIX threads instead.

We should therefore regard ucontext as a GNUism, and only expect the
uncontext example to be build for Glibc.
main
Alyssa Ross 3 years ago
parent 3db9ebca5e
commit 3a4f647269
No known key found for this signature in database
GPG Key ID: F9DBED4859B271C0
  1. 11
      pkgs/development/libraries/liburing/default.nix

@ -33,16 +33,15 @@ stdenv.mkDerivation rec {
outputs = [ "out" "bin" "dev" "man" ];
postInstall =
# Copy the examples into $bin. Most reverse dependency of this package should
# reference only the $out output
''
postInstall = ''
# Copy the examples into $bin. Most reverse dependency of this package should
# reference only the $out output
mkdir -p $bin/bin
cp ./examples/io_uring-cp examples/io_uring-test $bin/bin
cp ./examples/link-cp $bin/bin/io_uring-link-cp
'' + lib.optionalString stdenv.hostPlatform.isGnu ''
cp ./examples/ucontext-cp $bin/bin/io_uring-ucontext-cp
''
;
'';
meta = with lib; {
description = "Userspace library for the Linux io_uring API";

Loading…
Cancel
Save