samba3, fusesmb: removing

Samba 3 has been discontinued since Q1/2015. So I think it's time
to just wipe it from the pkgs. FuseSMB is pretty much abandoned,
upstream does not exist and it's also not as useful as it used to
be anyways.
This commit is contained in:
Dima 2019-10-15 14:33:08 +02:00 committed by Lassulus
parent 201defc4bf
commit 0541d071af
5 changed files with 4 additions and 143 deletions

View File

@ -115,7 +115,7 @@ in
type = types.package; type = types.package;
default = pkgs.samba; default = pkgs.samba;
defaultText = "pkgs.samba"; defaultText = "pkgs.samba";
example = literalExample "pkgs.samba3"; example = literalExample "pkgs.samba4Full";
description = '' description = ''
Defines which package should be used for the samba server. Defines which package should be used for the samba server.
''; '';

View File

@ -1,99 +0,0 @@
{ stdenv, fetchurl, readline, pam ? null, openldap ? null
, popt, iniparser, libunwind
, fam ? null , acl ? null, cups ? null
, useKerberos ? false, kerberos ? null, winbind ? true
# Eg. smbclient and smbspool require a smb.conf file.
# If you set configDir to "" an empty configuration file
# $out/lib/smb.conf is is created for you.
#
# configDir defaults to "/etc/samba" so that smbpassword picks up
# the location of its passwd db files from the system configuration file
# /etc/samba/smb.conf. That's why nixos touches /etc/samba/smb.conf even if you
# don't enable the samba upstart service.
, configDir ? "/etc/samba"
}:
assert useKerberos -> kerberos != null;
stdenv.mkDerivation rec {
name = "samba-3.6.25";
src = fetchurl {
url = "mirror://samba/pub/samba/stable/${name}.tar.gz";
sha256 = "0l9pz2m67vf398q3c2dwn8jwdxsjb20igncf4byhv6yq5dzqlb4g";
};
patches = [(fetchurl {
url = "https://download.samba.org/pub/samba/patches/security/"
+ "samba-3.6.25-security-2015-12-16.patch";
sha256 = "00dcjcn577825mfdwdp76jfy5kcrqw3s4d5c41gqdq5gfcdbmqdb";
})];
buildInputs = [ readline pam openldap popt iniparser libunwind fam acl cups ]
++ stdenv.lib.optional useKerberos kerberos;
enableParallelBuilding = true;
postPatch =
# XXX: Awful hack to allow cross-compilation.
'' sed -i source3/configure \
-e 's/^as_fn_error .. \("cannot run test program while cross compiling\)/$as_echo \1/g'
''; # "
preConfigure =
'' cd source3
export samba_cv_CC_NEGATIVE_ENUM_VALUES=yes
export libreplace_cv_HAVE_GETADDRINFO=yes
export ac_cv_file__proc_sys_kernel_core_pattern=no # XXX: true on Linux, false elsewhere
'';
configureFlags =
stdenv.lib.optionals (pam != null) [ "--with-pam" "--with-pam_smbpass" ]
++ [ "--with-aio-support"
"--disable-swat"
"--with-configdir=${configDir}"
"--with-fhs"
"--localstatedir=/var"
]
++ (stdenv.lib.optional winbind "--with-winbind")
++ (stdenv.lib.optional (stdenv.cc.libc != null) "--with-libiconv=${stdenv.cc.libc}");
# Need to use a DESTDIR because `make install' tries to write in /var and /etc.
installFlags = "DESTDIR=$(TMPDIR)/inst";
stripAllList = [ "bin" "sbin" ];
postInstall =
''
mkdir -p $out
mv $TMPDIR/inst/$out/* $out/
mkdir -p "$out/lib/pkgconfig"
cp pkgconfig/*.pc "$out/lib/pkgconfig"
mkdir -pv $out/lib/cups/backend
ln -sv ../../../bin/smbspool $out/lib/cups/backend/smb
mkdir -pv $out/etc/openldap/schema
cp ../examples/LDAP/samba.schema $out/etc/openldap/schema
# For nsswitch. Glibc >= 2.1 looks for libnss_<name>.so.2 (see man
# nsswitch.conf), so provide that too.
cp -v ../nsswitch/libnss_wins.so "$out/lib"
cp -v ../nsswitch/libnss_winbind.so "$out/lib"
(cd "$out/lib" && ln -s libnss_winbind.so libnss_winbind.so.2)
(cd "$out/lib" && ln -s libnss_wins.so libnss_wins.so.2)
'' # */
+ stdenv.lib.optionalString (configDir == "") "touch $out/lib/smb.conf";
meta = with stdenv.lib; {
homepage = https://www.samba.org/;
description = "The standard Windows interoperability suite of programs for Linux and Unix";
platforms = platforms.linux;
license = licenses.gpl3;
knownVulnerabilities = [
"Numerous CVEs and no patches from upstream for 3.x since 2014."
];
};
}

View File

@ -1,28 +0,0 @@
{ stdenv, fetchurl, samba, fuse }:
stdenv.mkDerivation rec {
name = "fusesmb-0.8.7";
src = fetchurl {
url = "http://www.ricardis.tudelft.nl/~vincent/fusesmb/download/${name}.tar.gz";
sha256 = "12gz2gn9iqjg27a233dn2wij7snm7q56h97k6gks0yijf6xcnpz1";
};
buildInputs = [ samba fuse ];
postInstall =
''
mkdir -p $out/lib
ln -fs ${samba}/lib/libsmbclient.so $out/lib/libsmbclient.so.0
'';
hardeningDisable = [ "format" ];
meta = with stdenv.lib; {
description = "Samba mounted via FUSE";
license = licenses.gpl2;
platforms = platforms.linux;
broken = true; # Needs vulnerable Samba, missing source link
# 2018-08-21
};
}

View File

@ -117,6 +117,7 @@ mapAliases ({
foomatic_filters = foomatic-filters; # 2016-08 foomatic_filters = foomatic-filters; # 2016-08
fuse_exfat = exfat; # 2015-09-11 fuse_exfat = exfat; # 2015-09-11
fuseki = apache-jena-fuseki; # added 2018-04-25 fuseki = apache-jena-fuseki; # added 2018-04-25
fusesmb = throw "fusesmb is abandoned by upstream"; # added 2019-10-15
gccApple = throw "gccApple is no longer supported"; # added 2018-04-25 gccApple = throw "gccApple is no longer supported"; # added 2018-04-25
gdb-multitarget = gdb; # added 2017-11-13 gdb-multitarget = gdb; # added 2017-11-13
gdk_pixbuf = gdk-pixbuf; # added 2019-05-22 gdk_pixbuf = gdk-pixbuf; # added 2019-05-22
@ -339,6 +340,8 @@ mapAliases ({
s6PortableUtils = s6-portable-utils; # added 2018-07-23 s6PortableUtils = s6-portable-utils; # added 2018-07-23
sagemath = sage; # added 2018-10-27 sagemath = sage; # added 2018-10-27
sam = deadpixi-sam; # added 2018-04-25 sam = deadpixi-sam; # added 2018-04-25
samba3 = throw "Samba 3 is discontinued, please switch to samba4"; # added 2019-10-15
samba3_light = throw "Samba 3 is discontinued, please switch to samba4"; # added 2019-10-15
sambaMaster = throw "removed 2019-09-13: outdated and no longer needed"; sambaMaster = throw "removed 2019-09-13: outdated and no longer needed";
samsungUnifiedLinuxDriver = samsung-unified-linux-driver; # added 2016-01-25 samsungUnifiedLinuxDriver = samsung-unified-linux-driver; # added 2016-01-25
saneBackends = sane-backends; # added 2016-01-02 saneBackends = sane-backends; # added 2016-01-02

View File

@ -6398,8 +6398,6 @@ in
syntex = callPackage ../tools/graphics/syntex {}; syntex = callPackage ../tools/graphics/syntex {};
fusesmb = callPackage ../tools/filesystems/fusesmb { samba = samba3; };
sl = callPackage ../tools/misc/sl { stdenv = gccStdenv; }; sl = callPackage ../tools/misc/sl { stdenv = gccStdenv; };
socat = callPackage ../tools/networking/socat { }; socat = callPackage ../tools/networking/socat { };
@ -15568,8 +15566,6 @@ in
deadpixi-sam-unstable = callPackage ../applications/editors/deadpixi-sam { }; deadpixi-sam-unstable = callPackage ../applications/editors/deadpixi-sam { };
samba3 = callPackage ../servers/samba/3.x.nix { };
samba4 = callPackage ../servers/samba/4.x.nix { samba4 = callPackage ../servers/samba/4.x.nix {
rpcgen = netbsd.rpcgen; rpcgen = netbsd.rpcgen;
python = python3; python = python3;
@ -15577,17 +15573,6 @@ in
samba = samba4; samba = samba4;
# A lightweight Samba 3, useful for non-Linux-based OSes.
samba3_light = lowPrio (samba3.override {
pam = null;
fam = null;
cups = null;
acl = null;
openldap = null;
# libunwind 1.0.1 is not ported to GNU/Hurd.
libunwind = null;
});
samba4Full = lowPrio (samba4.override { samba4Full = lowPrio (samba4.override {
enableLDAP = true; enableLDAP = true;
enablePrinting = true; enablePrinting = true;