Skip to content

Instantly share code, notes, and snippets.

@srhb
Created August 5, 2019 18:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save srhb/f5b304f39f840aebf7cb08349fc7a9c2 to your computer and use it in GitHub Desktop.
Save srhb/f5b304f39f840aebf7cb08349fc7a9c2 to your computer and use it in GitHub Desktop.
{ stdenv
, callPackage
, lib
, dpkg
# Package dependencies
, fetchurl
, fuse
, curl
, libevent
, libsearpc
, libuuid
, openssl
, sqlite
, autoPatchelfHook
}:
let
libevent-2_0-src = builtins.fetchurl {
url = "https://github.com/NixOS/nixpkgs/raw/3be19de8e4eba036d1c6ae81295beee1871a7fef~1/pkgs/development/libraries/libevent/default.nix";
sha256 = "0000000000000000000000000000000000000000000000000000";
};
libevent-2_0 = callPackage libevent-2_0-src {};
in
stdenv.mkDerivation rec {
version = "1.0.0";
pname = "seadrive-daemon";
name = "${pname}-${version}";
src = fetchurl {
url = "https://deb.seadrive.org/jessie/pool/main/s/seadrive-daemon/seadrive-daemon_1.0.0_amd64.deb";
sha256 = "09nbgcgqzxdb4f1c6dw8azvhpcap88frc64da0d49f7lrikgd49l";
};
unpackCmd = "${dpkg}/bin/dpkg-deb -x $curSrc .";
nativeBuildInputs = [ autoPatchelfHook ];
buildInputs = [
fuse
curl
libevent
libsearpc
libuuid
openssl
sqlite
libevent-2_0
];
installPhase = ''
mkdir --parent $out
mv * $out/
'';
meta = {
homepage = "https://www.seafile.com/en/home/";
description = "The SeaDrive client enables you to access files on the Seafile server without syncing to local disk. It works like a network drive.";
platforms = [ "x86_64-linux" ];
license = stdenv.lib.licenses.unfree;
};
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment