2021-03-25 17:33:16 +01:00
|
|
|
{ lib, stdenv, fetchurl, autoreconfHook, fuse, curl, pkg-config, glib, zlib }:
|
2007-10-25 16:45:00 +02:00
|
|
|
|
2021-05-15 18:39:05 +02:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "curlftpfs";
|
|
|
|
version = "0.9.2";
|
|
|
|
|
2007-10-25 16:45:00 +02:00
|
|
|
src = fetchurl {
|
2021-05-15 18:39:05 +02:00
|
|
|
url = "mirror://sourceforge/curlftpfs/curlftpfs-${version}.tar.gz";
|
2010-04-09 17:40:12 +02:00
|
|
|
sha256 = "0n397hmv21jsr1j7zx3m21i7ryscdhkdsyqpvvns12q7qwwlgd2f";
|
2007-10-25 16:45:00 +02:00
|
|
|
};
|
2021-05-15 18:39:05 +02:00
|
|
|
|
|
|
|
patches = [
|
|
|
|
# This removes AC_FUNC_MALLOC and AC_FUNC_REALLOC from configure.ac because
|
|
|
|
# it is known to cause problems. Search online for "rpl_malloc" and
|
|
|
|
# "rpl_realloc" to find out more.
|
|
|
|
./fix-rpl_malloc.patch
|
|
|
|
];
|
|
|
|
|
2021-03-25 17:33:16 +01:00
|
|
|
nativeBuildInputs = [ autoreconfHook pkg-config ];
|
|
|
|
buildInputs = [ fuse curl glib zlib ];
|
|
|
|
|
|
|
|
CFLAGS = lib.optionalString stdenv.isDarwin "-D__off_t=off_t";
|
|
|
|
|
|
|
|
postPatch = lib.optionalString stdenv.isDarwin ''
|
|
|
|
# Fix the build on macOS with macFUSE installed. Needs autoreconfHook for
|
|
|
|
# this change to effect
|
|
|
|
substituteInPlace configure.ac --replace \
|
|
|
|
'export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig:$PKG_CONFIG_PATH' \
|
|
|
|
""
|
|
|
|
'';
|
2016-08-02 18:06:29 +02:00
|
|
|
|
2018-04-25 05:20:18 +02:00
|
|
|
doCheck = false; # fails, doesn't work well too, btw
|
|
|
|
|
2021-01-11 08:54:33 +01:00
|
|
|
meta = with lib; {
|
2018-09-07 22:17:34 +02:00
|
|
|
description = "Filesystem for accessing FTP hosts based on FUSE and libcurl";
|
2020-04-01 03:11:51 +02:00
|
|
|
homepage = "http://curlftpfs.sourceforge.net";
|
2021-05-15 18:39:05 +02:00
|
|
|
license = licenses.gpl2Only;
|
2021-03-25 17:33:16 +01:00
|
|
|
platforms = platforms.unix;
|
2016-08-02 18:06:29 +02:00
|
|
|
};
|
2007-10-25 16:45:00 +02:00
|
|
|
}
|