Doc: Describe setting environment variables for run configurations

...in Preferences > Build & Run > General > Application environment >
Change.

Task-number: QTCREATORBUG-30209
Change-Id: Idd58652b25ef6cfebf7bfda1a237f4c661b4c3b6
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
Leena Miettinen
2024-02-13 14:21:42 +01:00
parent e7670dd9db
commit 5d8cf8ce09

View File

@@ -87,7 +87,25 @@
To run in a clean system environment, select \uicontrol {Clean Environment}.
\section2 Run on devices
\section2 Set the environment for all run configurations
To set environment variables for running and debugging applications, so
that they don't affect \QC itself, set environment variables for run
configurations of all projects:
\list 1
\li Go to \preferences > \uicontrol {Build & Run} > \uicontrol General.
\li Select \uicontrol Change in \uicontrol {Application environment}.
\li Set environment variables in \uicontrol {Edit Environment}.
\image qtcreator-edit-environment.webp {Edit Environment dialog}
\endlist
For example, set \c QT_FORCE_STDERR_LOGGING=1 to see application output
in \l {Application Output} instead of a journal or system log.
Or, set \c QT_MESSAGE_PATTERN to add information to debugging messages.
\section2 Use device environment
When running on a mobile device connected to the development host, \QC
fetches information about the \uicontrol {Device Environment} from the device.