Documentation for Release 2024.2
Building Executable Applications
On this page
This page is a guide on making standalone executable applications that don’t use
the CxxTest framework. By executable application or app, we mean any .cpp
file with its own main
function, making use of Chaste functionality.
App locations
The Chaste build system assumes that the following locations may contain apps:
Chaste/apps/src
(contains the Cardiac executable)Chaste/projects/<project_name>/apps/src
(see User Projects if you are unfamiliar with user projects)
Building the app
To build an app, first configure Chaste as normal:
Note
You may wish to switch on an optimised build - longer to compile, faster to run - when compiling executables for repeated/production use, see cmake build guide and the options for CMAKE_BUILD_TYPE
for how to switch on these compiler flags.
If you are building an app in Chaste/apps/src
, you should see something
similar to the following as part of the output:
The Chaste
app is the “cardiac executable”, see Cardiac Executable Tutorials for how to use it.
If you have made a new app within a user project, you should see something similar to:
You then simply build the app as you would any other target:
The executable app will be created in either:
/path/to/build_dir/apps
/path/to/build_dir/projects/<project_name>/apps
depending on whether the app is in the main Chaste apps directory, or a project directory.