Menu

Tree [38018e] master /
 History

HTTPS access


File Date Author Commit
 .github 2020-04-08 Victor Mataré Victor Mataré [9a0abd] CI: use plain cmake instead of fancy action
 examples 2020-07-20 Victor Mataré Victor Mataré [703b77] example config: fix typo
 include 2015-10-09 Victor Mataré Victor Mataré [39a07d] include nvml.h, fix cmake docstring
 rcscripts 2020-12-15 Victor Mataré Victor Mataré [7f944a] thinkfan.service: force load after modules
 src 2021-04-16 Victor Mataré Victor Mataré [38018e] use biasing only if temperature >= 0 °C
 CMakeLists.txt 2020-10-14 Victor Mataré Victor Mataré [a5fae8] update version string
 COPYING 2012-05-10 Victor Mataré Victor Mataré [50c8e2] remove duplicate src subdir
 README.md 2020-05-03 Victor Mataré Victor Mataré [0498c8] README: add kernel doc links

Read Me

thinkfan Total alertsLanguage grade: C/C++

Thinkfan is a simple, lightweight fan control program.

WARNING

There's only very basic sanity checking on the configuration (semantic
plausibility). You can set the temperature limits as insane as you like.

Any change to fan behaviour that results in higher temperatures in some parts
of the system will shorten your system's lifetime and/or cause weird hardware
bugs that'll make you pull out your hair.

No warranties whatsoever

If this program steals your car, kills your horse, smokes your dope or pees
on your carpet... too bad, you're on your own.

Building and installing

To compile thinkfan, you will need to have the following things installed:
- A recent C++ compiler (GCC >= 4.8 or clang)
- pkgconfig or an equivalent (pkgconf or pkg-config)
- cmake (and optionally a cmake GUI if you want to configure interactively)
- optional: libyaml-cpp for YAML support (the -dev or -devel package)

  1. In the thinkfan main directory, do
    bash mkdir build && cd build

  2. Then configure your build, either interactively:
    bash ccmake ..
    Or set your build options from the command line. E.g. to configure a build
    with full debugging support:
    bash cmake -D CMAKE_BUILD_TYPE:STRING=Debug ..

CMAKE_BUILD_TYPE:STRING can also be Release, which produces a fully
optimized binary, or RelWithDebInfo, which is also optimized but can
still be debugged with gdb.

Other options are:

USE_NVML:BOOL (default: ON)
Allows thinkfan to read GPU temperatures from the proprietary nVidia
driver. The interface library is loaded dynamically, so it does not
need to be installed when compiling.

USE_ATASMART:BOOL (default: OFF)
Enable libatasmart to read temperatures directly from hard disks. Use
this only when you really need it, since libatasmart is unreasonably
CPU-intensive.

USE_YAML:BOOL (default: ON)
Support config file in the new, more flexible YAML format. The old
config format will be deprecated after the thinkfan 1.0 release. New
features will be supported in YAML configs only. See
examples/thinkfan.conf.yaml. Requires libyaml-cpp.

  1. To compile simply run:
    bash make

  2. If you did not change CMAKE_INSTALL_PREFIX, thinkfan will be installed
    under /usr/local by doing:
    bash sudo make install

CMake will detect whether you use OpenRC or systemd and install some
appropriate service files. With systemd, you can edit the commandline
arguments of the thinkfan service with systemctl edit thinkfan.
With OpenRC, we install only a plain initscript (edit /etc/init.d/thinkfan
to change options).

Documentation

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.