diff options
author | Daiderd Jordan <daiderd@gmail.com> | 2018-10-27 17:32:39 +0100 |
---|---|---|
committer | Daiderd Jordan <daiderd@gmail.com> | 2018-10-27 17:32:39 +0100 |
commit | 82365ebe0442b9f90a233ed24c822861a26d08da (patch) | |
tree | c8dcfaf1e8ca6b8e57a5af437746be0724502a4e /pkgs/tools/misc/watchexec | |
parent | f2b8262e053f6d2ab91cb9e5ead0496e3e4d3eab (diff) | |
download | nixlib-82365ebe0442b9f90a233ed24c822861a26d08da.tar nixlib-82365ebe0442b9f90a233ed24c822861a26d08da.tar.gz nixlib-82365ebe0442b9f90a233ed24c822861a26d08da.tar.bz2 nixlib-82365ebe0442b9f90a233ed24c822861a26d08da.tar.lz nixlib-82365ebe0442b9f90a233ed24c822861a26d08da.tar.xz nixlib-82365ebe0442b9f90a233ed24c822861a26d08da.tar.zst nixlib-82365ebe0442b9f90a233ed24c822861a26d08da.zip |
watchexec: fix darwin build
Diffstat (limited to 'pkgs/tools/misc/watchexec')
-rw-r--r-- | pkgs/tools/misc/watchexec/default.nix | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/pkgs/tools/misc/watchexec/default.nix b/pkgs/tools/misc/watchexec/default.nix index e376568d3503..dd3eddf73954 100644 --- a/pkgs/tools/misc/watchexec/default.nix +++ b/pkgs/tools/misc/watchexec/default.nix @@ -1,4 +1,4 @@ -{ stdenv, rustPlatform, fetchFromGitHub }: +{ stdenv, rustPlatform, fetchFromGitHub, CoreServices, CoreFoundation }: rustPlatform.buildRustPackage rec { name = "watchexec-${version}"; @@ -13,11 +13,19 @@ rustPlatform.buildRustPackage rec { cargoSha256 = "1li84kq9myaw0zwx69y72f3lx01s7i9p8yays4rwvl1ymr614y1l"; + buildInputs = stdenv.lib.optionals stdenv.isDarwin [ CoreServices ]; + + # FIXME: Use impure version of CoreFoundation because of missing symbols. + # Undefined symbols for architecture x86_64: "_CFURLResourceIsReachable" + preConfigure = stdenv.lib.optionalString stdenv.isDarwin '' + export NIX_LDFLAGS="-F${CoreFoundation}/Library/Frameworks -framework CoreFoundation $NIX_LDFLAGS" + ''; + meta = with stdenv.lib; { description = "Executes commands in response to file modifications"; homepage = https://github.com/watchexec/watchexec; license = with licenses; [ asl20 ]; maintainers = [ maintainers.michalrus ]; - platforms = platforms.linux; + platforms = platforms.linux ++ platforms.darwin; }; } |