nixpkgs/pkgs/development/libraries/libplist/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

59 lines
1.2 KiB
Nix
Raw Normal View History

{ lib
, stdenv
, fetchFromGitHub
, autoreconfHook
, pkg-config
, enablePython ? false
, python3
}:
2018-08-13 04:45:46 +00:00
stdenv.mkDerivation rec {
pname = "libplist";
version = "2.3.0";
outputs = [ "bin" "dev" "out" ] ++ lib.optional enablePython "py";
2018-08-13 04:45:46 +00:00
src = fetchFromGitHub {
owner = "libimobiledevice";
repo = pname;
rev = version;
hash = "sha256-fZfDSWVRg73dN+WF6LbgRSj8vtyeKeyjC8pWXFxUmBg=";
2018-08-13 04:45:46 +00:00
};
2018-08-13 04:45:46 +00:00
nativeBuildInputs = [
autoreconfHook
pkg-config
];
buildInputs = lib.optionals enablePython [
python3
python3.pkgs.cython
];
preAutoreconf = ''
export RELEASE_VERSION=${version}
'';
configureFlags = [
"--enable-debug"
] ++ lib.optionals (!enablePython) [
"--without-cython"
2018-08-13 04:45:46 +00:00
];
doCheck = true;
postFixup = lib.optionalString enablePython ''
moveToOutput "lib/${python3.libPrefix}" "$py"
'';
meta = with lib; {
2018-08-13 04:45:46 +00:00
description = "A library to handle Apple Property List format in binary or XML";
homepage = "https://github.com/libimobiledevice/libplist";
2018-08-13 04:45:46 +00:00
license = licenses.lgpl21Plus;
2019-04-16 11:45:31 +00:00
maintainers = with maintainers; [ infinisil ];
platforms = platforms.unix;
mainProgram = "plistutil";
};
}