nixpkgs-suyu/pkgs/os-specific/darwin/apple-source-releases/text_cmds/default.nix

28 lines
1.1 KiB
Nix
Raw Normal View History

2021-03-14 19:12:53 +01:00
{ lib, appleDerivation, xcbuildHook, ncurses, bzip2, zlib, xz }:
2018-04-16 05:22:28 +02:00
appleDerivation {
nativeBuildInputs = [ xcbuildHook ];
2021-03-14 19:12:53 +01:00
buildInputs = [ ncurses bzip2 zlib xz ];
2018-04-16 05:22:28 +02:00
# patches to use ncursees
# disables md5
patchPhase = ''
substituteInPlace text_cmds.xcodeproj/project.pbxproj \
2021-03-14 19:20:33 +01:00
--replace 'FC6C98FB149A94EB00DDCC47 /* libcurses.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libcurses.dylib; path = /usr/lib/libcurses.dylib; sourceTree = "<absolute>"; };' 'FC6C98FB149A94EB00DDCC47 /* libncurses.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libncurses.dylib; path = /usr/lib/libncurses.dylib; sourceTree = "<absolute>"; };' \
2018-04-16 05:22:28 +02:00
--replace 'FC7A7EB5149875E00086576A /* PBXTargetDependency */,' ""
'';
installPhase = ''
for f in Products/Release/*; do
if [ -f $f ]; then
install -D $f $out/bin/$(basename $f)
fi
2018-04-16 05:22:28 +02:00
done
'';
meta = {
2021-01-15 15:45:37 +01:00
platforms = lib.platforms.darwin;
maintainers = with lib.maintainers; [ matthewbauer ];
2018-04-16 05:22:28 +02:00
};
}