CMake setting reference¶
This section references all settings that can be used with Cahute’s CMake settings.
CMake built-in settings¶
The following variables can be used with every CMake project, and described amongst others in cmake-variables(7), but may be described with information more relevant to Cahute here.
CMAKE_BUILD_TYPE
Build type. Commonly found values with Cahute are the following:
Debug
Non-optimized output with debug symbols and no binary stripping.
Release
Optimized output.
Note
As described in the CMake package guidelines for Archlinux, CMake automatically forces
-O3
whenRelease
is selected. Cahute overrides this with-O2
instead.CMAKE_INSTALL_PREFIX
Install prefix.
In the build from source guides, it is recommended to set this to
/usr
rather than the default/usr/local
value.CMAKE_VERBOSE_MAKEFILE
Optional switch to set to
ON
to see the commands executed when building the project.
Cahute-specific general settings¶
The following variables are specific to Cahute.
CAHUTE_CLI
Enable command-line utilities.
This is enabled by default.
CAHUTE_CLI_EXPERIMENTAL
Enable experimental / unfinished command-line utilities.
This is disabled by default.
CAHUTE_DEFAULT_LOGLEVEL
Default logging level used when creating a context, among
debug
info
,warning
(by default),error
,fatal
andnone
.See Logging facilities for more information.
CAHUTE_GIT
Include git-related information to the built targets, i.e. if the source directory is a git repository with at least one commit on the current branch, the following macros will be defined and included in the headers:
CAHUTE_GIT_COMMIT
;CAHUTE_GIT_BRANCH
;CAHUTE_GIT_TAGGED
;CAHUTE_GIT_DIRTY
.
This is enabled by default.
CAHUTE_LIBUSB
Enable the use of libusb.
Note
This will be ignored on Win32, since Cahute needs to support drivers libusb doesn’t.
This is enabled by default on platforms libusb support.
CAHUTE_PKGCONF
Enable installing pkgconf / pkg-config files.
This is supported by default.
CAHUTE_REPORT_URL
URL to the bug reporting guide included within the library and command-line utilities.
CAHUTE_SDL
Enable the use of SDL.
This is enabled by default on platforms SDL2 support.
CAHUTE_UDEV
Enable building and installing the udev rule.
This is enabled by default when building for Linux.
CAHUTE_UDEV_GROUP
Name of the group to which the udev rule gives permission to calculators plugged in via USB.
It is recommended to set the same group here as for normal serial devices, as defined by your distribution.
The Linux Standard Base groups defines
uucp
and the Archlinux user groups use it for serial devices, other distributions use other groups such asdialout
; see the following for more information:This is set to
uucp
by default.
Cahute-specific command-line utility switches¶
Most command-line utilities in Cahute can be enabled using the CAHUTE_CLI setting.
However, they can also be individually enabled using the following switches:
Cahute-specific experimental command-line utility switches¶
Some command-line utilities in Cahute are considered experimental (not fully implemented), and can be enabled by enabling both the CAHUTE_CLI and CAHUTE_CLI_EXPERIMENTAL settings.
However, they can also be individually enabled using the following switches:
CAHUTE_CLI_CAS
Enable building CaS.