\label{doc_DEBUGGING_md_md_doc_DEBUGGING}%
\Hypertarget{doc_DEBUGGING_md_md_doc_DEBUGGING}%
 Elektra can be debugged using gdb (either standalone or as part of an IDE like CLion).

To see the source files during debugging follow these steps\+:


\begin{DoxyEnumerate}
\item Follow the \mbox{\hyperlink{doc_GETSTARTED_md}{Get started instructions}} to clone and install the repository. ~\newline
 Note\+: To disable compiler optimizations and add debug symbols, add these flags when calling {\ttfamily cmake}\+: ~\newline
 {\ttfamily cmake -\/DCMAKE\+\_\+\+BUILD\+\_\+\+TYPE=DEBUG -\/DENABLE\+\_\+\+DEBUG=on -\/DCMAKE\+\_\+\+C\+\_\+\+FLAGS=-\/O0 -\/g}
\item Before starting gdb, set the environment variable {\ttfamily LD\+\_\+\+LIBRARY\+\_\+\+PATH} to the path where libelektra was installed during {\ttfamily make install} during step 1 (e.\+g. on Ubuntu 20.\+04.\+3 use {\ttfamily export LD\+\_\+\+LIBRARY\+\_\+\+PATH=/usr/local/lib/elektra}). ~\newline
 If you use CLion, set the environment variable in your Debug Configuration.
\item After any code changes, you need to execute {\ttfamily make install} again to apply your changes. 
\end{DoxyEnumerate}