at v206 33 lines 734 B view raw
1{ lib, stdenv, fetchurl, python }: 2 3stdenv.mkDerivation rec { 4 name = "smem-1.4"; 5 6 src = fetchurl { 7 url = "http://www.selenic.com/smem/download/${name}.tar.gz"; 8 sha256 = "1v31vy23s7szl6vdrllq9zbg58bp36jf5xy3fikjfg6gyiwgia9f"; 9 }; 10 11 buildInputs = [ python ]; 12 13 buildPhase = 14 '' 15 gcc -O2 smemcap.c -o smemcap 16 ''; 17 18 installPhase = 19 '' 20 mkdir -p $out/bin 21 cp smem smemcap $out/bin/ 22 23 mkdir -p $out/share/man/man8 24 cp smem.8 $out/share/man/man8/ 25 ''; 26 27 meta = { 28 homepage = http://www.selenic.com/smem/; 29 description = "A memory usage reporting tool that takes shared memory into account"; 30 platforms = lib.platforms.linux; 31 maintainers = [ lib.maintainers.eelco ]; 32 }; 33}