<!--
SPDX-FileCopyrightText: 2005 - 2008, 2010 - 2022 Michael Pyne <mpyne@kde.org>
SPDX-FileCopyrightText: 2005 - 2024 The kdesrc-build authors

SPDX-License-Identifier: GFDL-1.2-no-invariants-or-later
-->

<chapter id="kde-cmake">
<title>&cmake;, the &kde; build system</title>

<sect1 id="kde-cmake-intro">
<title>Introduction to &cmake;</title>

<para>In March 2006, the &cmake; program
beat out several competitors and was selected to be the build system for &kde; 4, replacing the
autotools-based system that &kde; had used from the beginning.</para>

<para>A introduction to &cmake; page is available on the <ulink
url="https://community.kde.org/Guidelines_HOWTOs/CMake">&kde; Community Wiki</ulink>.
Basically, instead of running <userinput><command>make</command> <option>-f</option>
<filename>Makefile.cvs</filename></userinput>, then <command>configure</command>,
then &make;, we simply run &cmake; and then &make;.
</para>

<para>&kdesrc-build; has support for &cmake;. A few features of &kdesrc-build;
were really features of the underlying buildsystem, including
<link linkend="conf-configure-flags">configure-flags</link>
and <link linkend="conf-do-not-compile">do-not-compile</link>. When equivalent
features are available, they are provided. For instance, the equivalent to the
configure-flags option is <link linkend="conf-cmake-options">cmake-options</link>, and the
<link linkend="conf-do-not-compile">do-not-compile</link> option is also supported for &cmake;
as of &kdesrc-build; version 1.6.3.
</para>

</sect1>
</chapter>
