Skip to content
Go to file


Failed to load latest commit information.
Latest commit message
Commit time


dfc is a tool to report file system space usage information. When the output is a terminal, it uses color and graphs by default. It has a lot of features such as HTML, JSON and CSV export, multiple filtering options, the ability to show mount options and so on.



cmake is required to build dfc. For convenience, a simple Makefile (which calls cmake under the hood) is provided.

I suggest you create a build directory in which you compile dfc. This is of course not required but it will prevent files from being created everywhere in the source folder.


Create the build directory:

mkdir build

Navigate into it:

cd build

Run the cmake command to generate a Makefile that works for your OS:

cmake ..

Now you can use the make command to build dfc:


The dfc binary will be placed into a bin sub-directory.


Several options can be tweaked before you compile dfc. To activate / deactivate or change them, you need to do it at the cmake step. Note that you may also use ccmake instead which gives you a curses interface to tweak the options.

By default, translations are enabled. They require gettext to be installed on the system. You can however easily disable them in which case no translations nor language translated configuration files will be installed.

cmake .. -DNLS_ENABLED=false

dfc has also the LFS option enabled by default. This option activates compile flags in order to support listing of large file systems (over 4G) on 32-bit hosts. This will not harm 64-bit systems if activated but if you feel the need to deactivate it, use the following:

cmake .. -DLFS_ENABLED=false

Different types of build are available. Most people will only care about RELEASE which is the build type that shall be used when distributing the software as binary or installing it as it adds some optimization flags. To enable RELEASE build use the following:


Developers might care about DEBUG build when debugging the program as it adds debug flags such as -g3. Enable it like so:


Note that by default, dfc build with very strict compilers flags.


Once built, you can run dfc by typing:


from within the directory where dfc is located.

See ./dfc -h for quick options and usage overview or read the manual page.


By default, dfc binary will be installed in /usr/local/bin. As root, type:

make install

You can also choose some standards parameters like where the files need to be installed. This needs to be done when using the cmake command. Example (from the previously created build directory):


Then run the make install and it will install dfc according to what you chose in the previous step.


The configuration file found in conf/dfcrc needs to be placed here if one desires to use it:


Note that if, for instance, French is the language you use, you should then use the configuration file that has been translated into French (found in conf/fr/dfcrc) and so on for any language into which dfc has been translated.

If your operating system does not support XDG Base Directory Specification it can then be placed in this directory:


Or, last choice, directly in $HOME (but the name has to be preceded by a dot):



Here is the list of dependencies:

  • standard C library

Yep, that should be it. :)

Please, note that gettext is required in order to build translations. If you do not want to package dfc with translation support, use the option to disable translation as explained in the build section.

Of course, cmake is a build dependency.

You can’t perform that action at this time.