} /* namespace */
const char *const config_element_all = "all";
-LTTNG_EXPORT const char *config_xml_encoding = "UTF-8";
+LTTNG_EXPORT extern const char *const config_xml_encoding;
+const char *const config_xml_encoding = "UTF-8";
LTTNG_EXPORT size_t config_xml_encoding_bytes_per_char = 2; /* Size of the encoding's largest
character */
-LTTNG_EXPORT const char *config_xml_indent_string = "\t";
-LTTNG_EXPORT const char *config_xml_true = "true";
-LTTNG_EXPORT const char *config_xml_false = "false";
+LTTNG_EXPORT extern const char *const config_xml_indent_string;
+LTTNG_EXPORT extern const char *const config_xml_true;
+LTTNG_EXPORT extern const char *const config_xml_false;
+
+const char *const config_xml_indent_string = "\t";
+const char *const config_xml_true = "true";
+const char *const config_xml_false = "false";
const char *const config_element_channel = "channel";
const char *const config_element_channels = "channels";
const char *const config_event_context_vsgid = "VSGID";
/* Deprecated symbols */
-LTTNG_EXPORT const char *config_element_perf;
+LTTNG_EXPORT extern const char *const config_element_perf;
enum process_event_node_phase {
CREATION = 0,
static int process_domain_node(xmlNodePtr domain_node, const char *session_name)
{
int ret;
- struct lttng_domain domain {};
+ struct lttng_domain domain{};
struct lttng_handle *handle = nullptr;
struct lttng_channel *channel = nullptr;
xmlNodePtr channels_node = nullptr;
#include <ctype.h>
-LTTNG_EXPORT const char *config_str_yes = "yes";
-LTTNG_EXPORT const char *config_str_true = "true";
-LTTNG_EXPORT const char *config_str_on = "on";
-LTTNG_EXPORT const char *config_str_no = "no";
-LTTNG_EXPORT const char *config_str_false = "false";
-LTTNG_EXPORT const char *config_str_off = "off";
-
+LTTNG_EXPORT extern const char *const config_str_yes;
+LTTNG_EXPORT extern const char *const config_str_true;
+LTTNG_EXPORT extern const char *const config_str_on;
+LTTNG_EXPORT extern const char *const config_str_no;
+LTTNG_EXPORT extern const char *const config_str_false;
+LTTNG_EXPORT extern const char *const config_str_off;
+
+const char *const config_str_yes = "yes";
+const char *const config_str_true = "true";
+const char *const config_str_on = "on";
+const char *const config_str_no = "no";
+const char *const config_str_false = "false";
+const char *const config_str_off = "off";
namespace {
struct handler_filter_args {
const char *section;
const char *const mi_lttng_element_context_symbol = "symbol";
/* Deprecated symbols preserved for ABI compatibility. */
-LTTNG_EXPORT const char *mi_lttng_context_type_perf_counter;
-LTTNG_EXPORT const char *mi_lttng_context_type_perf_cpu_counter;
-LTTNG_EXPORT const char *mi_lttng_context_type_perf_thread_counter;
-LTTNG_EXPORT const char *mi_lttng_element_track_untrack_pid_target;
-LTTNG_EXPORT const char *mi_lttng_element_track_untrack_targets;
-LTTNG_EXPORT const char *mi_lttng_element_calibrate;
-LTTNG_EXPORT const char *mi_lttng_element_calibrate_function;
-LTTNG_EXPORT const char *mi_lttng_element_command_calibrate;
+LTTNG_EXPORT extern const char *const mi_lttng_context_type_perf_counter;
+LTTNG_EXPORT extern const char *const mi_lttng_context_type_perf_cpu_counter;
+LTTNG_EXPORT extern const char *const mi_lttng_context_type_perf_thread_counter;
+LTTNG_EXPORT extern const char *const mi_lttng_element_track_untrack_pid_target;
+LTTNG_EXPORT extern const char *const mi_lttng_element_track_untrack_targets;
+LTTNG_EXPORT extern const char *const mi_lttng_element_calibrate;
+LTTNG_EXPORT extern const char *const mi_lttng_element_calibrate_function;
+LTTNG_EXPORT extern const char *const mi_lttng_element_command_calibrate;
/* This is a merge of jul loglevel and regular loglevel
* Those should never overlap by definition
LTTNG_EXPORT size_t default_ust_pid_channel_subbuf_size;
LTTNG_EXPORT size_t default_ust_uid_channel_subbuf_size;
-LTTNG_EXPORT const char *config_element_pid_tracker = nullptr;
-LTTNG_EXPORT const char *config_element_target_pid = nullptr;
-LTTNG_EXPORT const char *config_element_targets = nullptr;
-LTTNG_EXPORT const char *config_element_trackers = nullptr;
-
#ifdef __cplusplus
extern "C" {
#endif
+LTTNG_EXPORT extern const char *const config_element_pid_tracker;
+LTTNG_EXPORT extern const char *const config_element_target_pid;
+LTTNG_EXPORT extern const char *const config_element_targets;
+LTTNG_EXPORT extern const char *const config_element_trackers;
+
+const char *const config_element_pid_tracker = nullptr;
+const char *const config_element_target_pid = nullptr;
+const char *const config_element_targets = nullptr;
+const char *const config_element_trackers = nullptr;
+
struct log_time {
char str[19];
};