blob: 26701d1dc4f259b4932432024982daeac8bfd686 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
|
{ lib
, boost
, cmake
, cxxopts
, digestpp
, fetchFromGitHub
, fmt
, jsoncons
, pugixml
, sqlite_orm
, stdenv
}:
stdenv.mkDerivation {
pname = "bt-migrate";
version = "0-unstable-2023-08-17";
src = fetchFromGitHub {
owner = "mikedld";
repo = "bt-migrate";
rev = "e15a489c0c76f98355586ebbee08223af4e9bf50";
hash = "sha256-kA6yxhbIh3ThmgF8Zyoe3I79giLVmdNr9IIrw5Xx4s0=";
};
nativeBuildInputs = [
cmake
];
buildInputs = [
boost
cxxopts
fmt
jsoncons
pugixml
sqlite_orm
];
cmakeFlags = [
(lib.strings.cmakeBool "USE_VCPKG" false)
# NOTE: digestpp does not have proper CMake packaging (yet?)
(lib.strings.cmakeBool "USE_FETCHCONTENT" true)
(lib.strings.cmakeFeature "FETCHCONTENT_SOURCE_DIR_DIGESTPP" "${digestpp}/include/digestpp")
];
# NOTE: no install target in CMake...
installPhase = ''
runHook preInstall
mkdir -p $out/bin
cp BtMigrate $out/bin
runHook postInstall
'';
strictDeps = true;
meta = with lib; {
description = "Torrent state migration tool";
homepage = "https://github.com/mikedld/bt-migrate?tab=readme-ov-file";
license = licenses.gpl3Only;
maintainers = with maintainers; [ ambroisie ];
mainProgram = "BtMigrate";
platforms = platforms.all;
};
}
|