]> arthur.barton.de Git - netdata.git/blob - CMakeLists.txt
dns_query_time plugin: replace "." with "_" in dimensions
[netdata.git] / CMakeLists.txt
1
2 # This file is only used for development (netdata in Clion)
3 # It can build netdata, but you are on your own...
4
5 cmake_minimum_required(VERSION 3.3)
6 project(netdata C)
7
8 find_package (Threads)
9
10 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -Wformat-signedness -Werror=format-security -DNETDATA_INTERNAL_CHECKS=1")
11
12 set(NETDATA_SOURCE_FILES
13         src/adaptive_resortable_list.c
14         src/adaptive_resortable_list.h
15         src/appconfig.c
16         src/appconfig.h
17         src/avl.c
18         src/avl.h
19         src/backends.c
20         src/backends.h
21         src/clocks.c
22         src/clocks.h
23         src/common.c
24         src/common.h
25         src/daemon.c
26         src/daemon.h
27         src/dictionary.c
28         src/dictionary.h
29         src/eval.c
30         src/eval.h
31         src/freebsd_sysctl.c
32         src/global_statistics.c
33         src/global_statistics.h
34         src/health.c
35         src/health.h
36         src/health_config.c
37         src/health_json.c
38         src/health_log.c
39         src/inlined.h
40         src/ipc.c
41         src/ipc.h
42         src/log.c
43         src/log.h
44         src/macos_fw.c
45         src/macos_mach_smi.c
46         src/macos_sysctl.c
47         src/main.c
48         src/main.h
49         src/plugin_checks.c
50         src/plugin_checks.h
51         src/plugin_freebsd.c
52         src/plugin_freebsd.h
53         src/plugin_idlejitter.c
54         src/plugin_idlejitter.h
55         src/plugin_macos.c
56         src/plugin_macos.h
57         src/plugin_nfacct.c
58         src/plugin_nfacct.h
59         src/plugin_proc.c
60         src/plugin_proc.h
61         src/plugin_proc_diskspace.c
62         src/plugin_proc_diskspace.h
63         src/plugin_tc.c
64         src/plugin_tc.h
65         src/plugins_d.c
66         src/plugins_d.h
67         src/popen.c
68         src/popen.h
69         src/proc_diskstats.c
70         src/proc_interrupts.c
71         src/proc_loadavg.c
72         src/proc_meminfo.c
73         src/proc_net_dev.c
74         src/proc_net_ip_vs_stats.c
75         src/proc_net_netstat.c
76         src/proc_net_rpc_nfs.c
77         src/proc_net_rpc_nfsd.c
78         src/proc_net_snmp.c
79         src/proc_net_snmp6.c
80         src/proc_net_softnet_stat.c
81         src/proc_net_stat_conntrack.c
82         src/proc_net_stat_synproxy.c
83         src/proc_self_mountinfo.c
84         src/proc_self_mountinfo.h
85         src/proc_softirqs.c
86         src/proc_spl_kstat_zfs.c
87         src/proc_stat.c
88         src/proc_sys_kernel_random_entropy_avail.c
89         src/proc_uptime.c
90         src/proc_vmstat.c
91         src/procfile.c
92         src/procfile.h
93         src/registry.c
94         src/registry.h
95         src/registry_db.c
96         src/registry_init.c
97         src/registry_internals.c
98         src/registry_internals.h
99         src/registry_log.c
100         src/registry_machine.c
101         src/registry_machine.h
102         src/registry_person.c
103         src/registry_person.h
104         src/registry_url.c
105         src/registry_url.h
106         src/rrd.c
107         src/rrd.h
108         src/rrd2json.c
109         src/rrd2json.h
110         src/rrd2json_api_old.c
111         src/rrd2json_api_old.h
112         src/rrdcalc.c
113         src/rrdcalctemplate.c
114         src/rrddim.c
115         src/rrddimvar.c
116         src/rrdfamily.c
117         src/rrdhost.c
118         src/rrdpush.c
119         src/rrdpush.h
120         src/rrdset.c
121         src/rrdsetvar.c
122         src/rrdvar.c
123         src/simple_pattern.c
124         src/simple_pattern.h
125         src/socket.c src/socket.h
126         src/storage_number.c
127         src/storage_number.h
128         src/sys_devices_system_edac_mc.c
129         src/sys_devices_system_node.c
130         src/sys_fs_cgroup.c
131         src/sys_kernel_mm_ksm.c
132         src/unit_test.c
133         src/unit_test.h
134         src/url.c
135         src/url.h
136         src/web_api_old.c
137         src/web_api_old.h
138         src/web_api_v1.c
139         src/web_api_v1.h
140         src/web_buffer.c
141         src/web_buffer.h
142         src/web_buffer_svg.c
143         src/web_buffer_svg.h
144         src/web_client.c
145         src/web_client.h
146         src/web_server.c
147         src/web_server.h
148         src/locks.h)
149
150 set(APPS_PLUGIN_SOURCE_FILES
151         src/appconfig.c
152         src/appconfig.h
153         src/apps_plugin.c
154         src/avl.c
155         src/avl.h
156         src/common.c
157         src/common.h
158         src/clocks.c
159         src/clocks.h
160         src/inlined.h
161         src/log.c
162         src/log.h
163         src/procfile.c
164         src/procfile.h
165         src/web_buffer.c
166         src/web_buffer.h
167         config.h
168         )
169
170 set(FREEIPMI_PLUGIN_SOURCE_FILES
171         src/freeipmi_plugin.c
172         src/common.c
173         src/common.h
174         src/clocks.c
175         src/clocks.h
176         src/inlined.h
177         src/log.c
178         src/log.h
179         src/procfile.c
180         src/procfile.h
181         config.h
182         )
183
184 include_directories(AFTER .)
185
186 add_definitions(-DHAVE_CONFIG_H -DCACHE_DIR="/var/cache/netdata" -DCONFIG_DIR="/etc/netdata" -DLOG_DIR="/var/log/netdata" -DPLUGINS_DIR="/usr/libexec/netdata" -DWEB_DIR="/usr/share/netdata" -DVARLIB_DIR="/var/lib/netdata")
187
188 add_executable(netdata ${NETDATA_SOURCE_FILES})
189 target_link_libraries (netdata m z uuid ${CMAKE_THREAD_LIBS_INIT})
190
191 add_executable(apps.plugin ${APPS_PLUGIN_SOURCE_FILES} src/inlined.h)
192 target_link_libraries (apps.plugin m ${CMAKE_THREAD_LIBS_INIT})
193
194 add_executable(freeipmi.plugin ${FREEIPMI_PLUGIN_SOURCE_FILES})
195 target_link_libraries (freeipmi.plugin ipmimonitoring)