13 stdenv.mkDerivation rec {
18 url = "mirror://sourceforge/rox/rox-filer-${version}.tar.bz2";
19 sha256 = "a929bd32ee18ef7a2ed48b971574574592c42e34ae09f36604bf663d7c101ba8";
26 buildInputs = [ libxml2 gtk shared-mime-info libSM ];
30 ./rox-filer-2.11-in-source-build.patch
31 # Pull upstream fix for -fno-common toolchains like upstream gcc-10:
32 # https://github.com/rox-desktop/rox-filer/pull/15
34 name = "fno-common.patch";
35 url = "https://github.com/rox-desktop/rox-filer/commit/86b0bb9144186d51ea9b898905111bd8b143b552.patch";
36 sha256 = "1csyx229i09p00lbdlkdqdhn3x2lb5zby1h9rkjgzlr2qz74gc69";
40 # go to the source directory after unpacking the sources
41 sourceRoot = "rox-filer-${version}/ROX-Filer";
43 # account for 'setSourceRoot' offset
44 patchFlags = [ "-p2" ];
46 # patch the main.c to disable the lookup of the APP_DIR environment variable,
47 # which is used to lookup the location for certain images when rox-filer
48 # starts; rather override the location with an absolute path to the directory
49 # where images are stored to prevent having to use a wrapper, which sets the
50 # APP_DIR environment variable prior to starting rox-filer
52 sed -i -e "s:g_strdup(getenv(\"APP_DIR\")):\"$out\":" src/main.c
57 configureScript = "../src/configure";
62 cp -av Help Messages Options.xml ROX images style.css .DirIcon "$out"
64 # create the man/ directory, which will be moved from $out to share/ in the fixup phase
66 cp -av ../rox.1 "$out/man/"
70 cp -v ROX-Filer "$out/bin/rox"
73 mkdir -p "$out/ROX/MIME"
75 ln -sv text-x-{diff,patch}.png
76 ln -sv application-x-font-{afm,type1}.png
77 ln -sv application-xml{,-dtd}.png
78 ln -sv application-xml{,-external-parsed-entity}.png
79 ln -sv application-{,rdf+}xml.png
80 ln -sv application-x{ml,-xbel}.png
81 ln -sv application-{x-shell,java}script.png
82 ln -sv application-x-{bzip,xz}-compressed-tar.png
83 ln -sv application-x-{bzip,lzma}-compressed-tar.png
84 ln -sv application-x-{bzip-compressed-tar,lzo}.png
85 ln -sv application-x-{bzip,xz}.png
86 ln -sv application-x-{gzip,lzma}.png
87 ln -sv application-{msword,rtf}.png
91 description = "Fast, lightweight, gtk2 file manager";
93 homepage = "http://rox.sourceforge.net/desktop";
94 license = with licenses; [ gpl2 lgpl2 ];
95 platforms = platforms.linux;
96 maintainers = [ maintainers.eleanor ];