2019-05-02 12:43:07 +01:00
|
|
|
{ stdenv
|
|
|
|
, substituteAll
|
|
|
|
, pkgconfig
|
|
|
|
, fetchurl
|
|
|
|
, python3
|
|
|
|
, dropbox
|
|
|
|
, gtk3
|
|
|
|
, gnome3
|
2019-05-22 12:03:39 +01:00
|
|
|
, gdk-pixbuf
|
2019-05-02 12:43:07 +01:00
|
|
|
, gobject-introspection
|
|
|
|
}:
|
|
|
|
|
2014-05-08 15:35:47 +01:00
|
|
|
let
|
2019-03-21 15:49:53 +00:00
|
|
|
version = "2019.02.14";
|
2015-03-22 17:10:28 +00:00
|
|
|
dropboxd = "${dropbox}/bin/dropbox";
|
2014-05-08 15:35:47 +01:00
|
|
|
in
|
2013-03-27 19:12:49 +00:00
|
|
|
stdenv.mkDerivation {
|
2019-08-13 22:52:01 +01:00
|
|
|
pname = "dropbox-cli";
|
|
|
|
inherit version;
|
2013-03-27 19:12:49 +00:00
|
|
|
|
2019-05-02 12:43:07 +01:00
|
|
|
outputs = [ "out" "nautilusExtension" ];
|
|
|
|
|
2013-03-27 19:12:49 +00:00
|
|
|
src = fetchurl {
|
2019-01-02 16:06:45 +00:00
|
|
|
url = "https://linux.dropboxstatic.com/packages/nautilus-dropbox-${version}.tar.bz2";
|
2019-03-21 15:49:53 +00:00
|
|
|
sha256 = "09yg7q45sycl88l3wq0byz4a9k6sxx3m0r3szinvisfay9wlj35f";
|
2013-03-27 19:12:49 +00:00
|
|
|
};
|
|
|
|
|
2019-05-02 12:43:07 +01:00
|
|
|
strictDeps = true;
|
|
|
|
|
|
|
|
patches = [
|
|
|
|
(substituteAll {
|
|
|
|
src = ./fix-cli-paths.patch;
|
|
|
|
inherit dropboxd;
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
pkgconfig
|
|
|
|
gobject-introspection
|
2019-05-22 12:03:39 +01:00
|
|
|
gdk-pixbuf
|
2019-05-02 12:43:07 +01:00
|
|
|
# only for build, the install command also wants to use GTK through introspection
|
|
|
|
# but we are using Nix for installation so we will not need that.
|
|
|
|
(python3.withPackages (ps: with ps; [
|
|
|
|
docutils
|
|
|
|
pygobject3
|
|
|
|
]))
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
python3
|
|
|
|
gtk3
|
|
|
|
gnome3.nautilus
|
|
|
|
];
|
|
|
|
|
|
|
|
configureFlags = [
|
2019-09-03 17:38:57 +01:00
|
|
|
"--with-nautilus-extension-dir=${placeholder "nautilusExtension"}/lib/nautilus/extensions-3.0"
|
2019-05-02 12:43:07 +01:00
|
|
|
];
|
|
|
|
|
|
|
|
makeFlags = [
|
2019-09-03 17:38:57 +01:00
|
|
|
"EMBLEM_DIR=${placeholder "nautilusExtension"}/share/nautilus-dropbox/emblems"
|
2019-05-02 12:43:07 +01:00
|
|
|
];
|
2013-06-16 22:38:33 +01:00
|
|
|
|
2013-03-27 19:12:49 +00:00
|
|
|
meta = {
|
2019-05-02 12:43:07 +01:00
|
|
|
homepage = https://www.dropbox.com;
|
2013-09-26 20:37:49 +01:00
|
|
|
description = "Command line client for the dropbox daemon";
|
2019-05-02 12:43:07 +01:00
|
|
|
license = stdenv.lib.licenses.gpl3Plus;
|
2013-06-16 22:40:43 +01:00
|
|
|
maintainers = with stdenv.lib.maintainers; [ the-kenny ];
|
2013-03-27 19:56:46 +00:00
|
|
|
# NOTE: Dropbox itself only works on linux, so this is ok.
|
2013-03-27 19:12:49 +00:00
|
|
|
platforms = stdenv.lib.platforms.linux;
|
|
|
|
};
|
|
|
|
}
|