2018-02-01 09:27:50 +00:00
|
|
|
{ stdenv, fetchFromGitHub, cmake, perl, openssl, curl, libusb1
|
|
|
|
, enableUnsafe ? false }:
|
2017-09-21 15:02:38 +01:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "ttwatch-${version}";
|
2018-12-15 11:54:25 +00:00
|
|
|
version = "2018-12-04";
|
2017-09-21 15:02:38 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "ryanbinns";
|
|
|
|
repo = "ttwatch";
|
2018-12-15 11:54:25 +00:00
|
|
|
rev = "eeb4e19bf7ca7ca2cee7f5fbeb483b27198d86a1";
|
|
|
|
sha256 = "18384apdkq35120cgmda686d293354aibwcq2hwhvvjmnq49fnzr";
|
2017-09-21 15:02:38 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ cmake perl ];
|
|
|
|
buildInputs = [ openssl curl libusb1 ];
|
|
|
|
|
2018-02-01 09:27:50 +00:00
|
|
|
cmakeFlags = stdenv.lib.optional enableUnsafe [ "-Dunsafe=on" ];
|
|
|
|
|
2017-09-21 15:02:38 +01:00
|
|
|
preFixup = ''
|
|
|
|
chmod +x $out/bin/ttbin2mysports
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
homepage = https://github.com/ryanbinns/ttwatch;
|
|
|
|
description = "Linux TomTom GPS Watch Utilities";
|
|
|
|
maintainers = with maintainers; [ dotlambda ];
|
|
|
|
license = licenses.mit;
|
|
|
|
platforms = with platforms; linux;
|
|
|
|
};
|
|
|
|
}
|