2018-03-27 08:27:32 +02:00
|
|
|
{ stdenv, fetchurl, fetchpatch, cmake, pkgconfig, xorg, libjpeg, libpng
|
2018-07-17 22:11:16 +02:00
|
|
|
, fontconfig, freetype, pam, dbus, makeWrapper }:
|
2007-02-25 23:25:25 +01:00
|
|
|
|
2009-02-18 11:38:51 +01:00
|
|
|
stdenv.mkDerivation rec {
|
2013-10-15 12:51:41 +02:00
|
|
|
name = "slim-1.3.6";
|
2009-02-18 11:38:51 +01:00
|
|
|
|
2007-02-25 23:25:25 +01:00
|
|
|
src = fetchurl {
|
2014-05-18 13:25:43 +02:00
|
|
|
url = "mirror://sourceforge/slim.berlios/${name}.tar.gz";
|
2013-10-15 12:51:41 +02:00
|
|
|
sha256 = "1pqhk22jb4aja4hkrm7rjgbgzjyh7i4zswdgf5nw862l2znzxpi1";
|
2007-02-25 23:25:25 +01:00
|
|
|
};
|
2009-02-18 11:38:51 +01:00
|
|
|
|
2013-10-15 12:51:41 +02:00
|
|
|
patches =
|
|
|
|
[ # Allow the paths of the configuration file and theme directory to
|
|
|
|
# be set at runtime.
|
|
|
|
./runtime-paths.patch
|
2013-10-15 13:15:33 +02:00
|
|
|
|
|
|
|
# Exit after the user's session has finished. This works around
|
|
|
|
# slim's broken PAM session handling (see
|
|
|
|
# http://developer.berlios.de/bugs/?func=detailbug&bug_id=19102&group_id=2663).
|
|
|
|
./run-once.patch
|
2016-01-30 10:37:39 +01:00
|
|
|
|
|
|
|
# Ensure that sessions appear in sort order, rather than in
|
|
|
|
# directory order.
|
|
|
|
./sort-sessions.patch
|
2017-04-23 19:02:50 +02:00
|
|
|
|
|
|
|
# Allow to set logfile to a special "/dev/stderr" in order to continue
|
|
|
|
# logging to stderr and thus to the journal.
|
|
|
|
./no-logfile.patch
|
2018-03-27 08:27:32 +02:00
|
|
|
] ++ stdenv.lib.optional stdenv.hostPlatform.isMusl (fetchpatch {
|
|
|
|
url = "https://raw.githubusercontent.com/gentoo/musl/8eddda8072add075ebf56cf6d288bc1450d6b5f8/x11-misc/slim/files/slim-1.3.6-add-missing-libgen_h.patch";
|
|
|
|
sha256 = "0f82672s2r2cmdqfn2mbg3di76mbla9n0ik20p2gv4igi6p866xm";
|
|
|
|
});
|
2012-08-17 17:33:37 +02:00
|
|
|
|
2014-03-30 19:32:10 +02:00
|
|
|
preConfigure = "substituteInPlace CMakeLists.txt --replace /lib $out/lib";
|
2009-02-18 11:38:51 +01:00
|
|
|
|
2012-12-13 11:30:18 +01:00
|
|
|
cmakeFlags = [ "-DUSE_PAM=1" ];
|
2009-02-18 11:38:51 +01:00
|
|
|
|
2016-04-16 18:52:29 +02:00
|
|
|
NIX_CFLAGS_COMPILE = "-I${freetype.dev}/include/freetype -std=c++11";
|
2014-06-09 19:47:31 +02:00
|
|
|
|
2013-10-15 12:51:41 +02:00
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
|
|
|
buildInputs =
|
|
|
|
[ cmake pkgconfig libjpeg libpng fontconfig freetype
|
2018-07-17 22:11:16 +02:00
|
|
|
pam dbus
|
2014-02-05 13:44:59 +01:00
|
|
|
xorg.libX11 xorg.libXext xorg.libXrandr xorg.libXrender xorg.libXmu xorg.libXft makeWrapper
|
2013-10-15 12:51:41 +02:00
|
|
|
];
|
|
|
|
|
2012-08-17 17:33:37 +02:00
|
|
|
NIX_CFLAGS_LINK = "-lXmu";
|
2008-01-30 20:49:42 +01:00
|
|
|
|
|
|
|
meta = {
|
2017-11-10 22:13:27 +01:00
|
|
|
homepage = https://sourceforge.net/projects/slim.berlios/; # berlios shut down; I found no replacement yet
|
2012-08-17 17:33:37 +02:00
|
|
|
platforms = stdenv.lib.platforms.linux;
|
2018-08-04 18:26:41 +02:00
|
|
|
license = stdenv.lib.licenses.gpl2;
|
2008-01-30 20:49:42 +01:00
|
|
|
};
|
2007-02-25 23:25:25 +01:00
|
|
|
}
|