Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/zabbix/zabbix.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndris Zeila <andris.zeila@zabbix.com>2019-12-02 10:41:34 +0300
committerAndris Zeila <andris.zeila@zabbix.com>2019-12-02 10:44:14 +0300
commit3b74170245fd7aac5d6fd17ca0a9aecacdb446f5 (patch)
treed22a5a5034a4be4e4f7ec5316f3bb62bfa6b6133 /include/sysinfo.h
parenta96e87c1a9f6114fe2088c4f3757a35e7b6bc9c5 (diff)
...G...... [ZBXNEXT-5609] added agent2 windows build support
* commit '636b601d1dec2d9b3bf4d423877c0477ba7a7fe0': (39 commits) .......... [ZBXNEXT-5609] fixed coding style .......... [ZBXNEXT-5609] added changelog entry .......... [DEV-1333] fixed compilation on windows .......... [DEV-1333] removed unused function .......... [DEV-1333] fixed log monitoring crash .......... [DEV-1333] added empty scheduler update when host is disabled .......... [DEV-1333] removed mtime from eventlog result .......... [DEV-1333] fixed version remote command format .......... [DEV-1333] fixed 64 bit architecture setting .......... [DEV-1333] added compile date/time/os/arch variable support .......... [DEV-1333] fixed logrt not working on windows due to file being opened in text mode instead of binary and path separator being unix style .......... [DEV-1333] reworked windows command execution to use undocumented (but widely used) NtResumeProcess() function from ntdll.dll .......... [DEV-1333] fixed logrt on windows .......... [DEV-1333] added application starting directory as default location for agent configuration file on windows .......... [DEV-1333] added current directory as default location for agent configuration file on windows .......... [DEV-1333] added comment, minor refactoring .......... [DEV-1333] removed global system.run related configuration settings .......... [DEV-1333] fixed command execution on 32 bit windows, added check for process exit code as a workaround for race condition when started process finished before a job is assigned .......... [DEV-1333] fixed not to support PID file on Windows .......... [DEV-1333] fixed not to support PID file on Windows ... (cherry picked from commit 014f43c2a00bf7286c70cd14ecc1cddfa9254e6e)
Diffstat (limited to 'include/sysinfo.h')
-rw-r--r--include/sysinfo.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/sysinfo.h b/include/sysinfo.h
index 16d236662de..4d040ab9a8c 100644
--- a/include/sysinfo.h
+++ b/include/sysinfo.h
@@ -141,7 +141,7 @@ extern int CONFIG_UNSAFE_USER_PARAMETERS;
#define ZBX_AVG15 2
#define ZBX_AVG_COUNT 3
-#ifdef _WINDOWS
+#if defined(_WINDOWS)
# define MAX_COLLECTOR_PERIOD (15 * SEC_PER_MIN)
#endif
@@ -269,7 +269,7 @@ int VFS_FS_SIZE(AGENT_REQUEST *request, AGENT_RESULT *result);
int VFS_FS_DISCOVERY(AGENT_REQUEST *request, AGENT_RESULT *result);
int VM_MEMORY_SIZE(AGENT_REQUEST *request, AGENT_RESULT *result);
-#ifdef _WINDOWS
+#if defined(_WINDOWS) || defined(__MINGW32__)
int USER_PERF_COUNTER(AGENT_REQUEST *request, AGENT_RESULT *result);
int PERF_COUNTER(AGENT_REQUEST *request, AGENT_RESULT *result);
int PERF_COUNTER_EN(AGENT_REQUEST *request, AGENT_RESULT *result);
@@ -288,7 +288,7 @@ int VM_VMEMORY_SIZE(AGENT_REQUEST *request, AGENT_RESULT *result);
int SYSTEM_STAT(AGENT_REQUEST *request, AGENT_RESULT *result);
#endif
-#ifdef _WINDOWS
+#if defined(_WINDOWS) || defined(__MINGW32__)
typedef int (*zbx_metric_func_t)(AGENT_REQUEST *request, AGENT_RESULT *result, HANDLE timeout_event);
#else
typedef int (*zbx_metric_func_t)(AGENT_REQUEST *request, AGENT_RESULT *result);
@@ -310,7 +310,7 @@ int zbx_execute_threaded_metric(zbx_metric_func_t metric_func, AGENT_REQUEST *re
#define ZBX_SYSINFO_PROC_CMDLINE 0x0004
#define ZBX_SYSINFO_PROC_USER 0x0008
-#ifdef _WINDOWS
+#if defined(_WINDOWS) || defined(__MINGW32__)
#define ZBX_MUTEX_ALL_ALLOW 0
#define ZBX_MUTEX_THREAD_DENIED 1
#define ZBX_MUTEX_LOGGING_DENIED 2