[ZBXNEXT-5609] Investigate Agent2 compilation on Windows Created: 2019 Oct 21 Updated: 2024 Apr 10 Resolved: 2020 Jun 04 |
|
Status: | Closed |
Project: | ZABBIX FEATURE REQUESTS |
Component/s: | Agent (G) |
Affects Version/s: | 4.4.3 |
Fix Version/s: | 4.4.4rc1, 5.0.0alpha1, 5.0 (plan) |
Type: | Change Request | Priority: | Trivial |
Reporter: | Andris Zeila | Assignee: | Andris Zeila |
Resolution: | Fixed | Votes: | 0 |
Labels: | None | ||
Remaining Estimate: | Not Specified | ||
Time Spent: | Not Specified | ||
Original Estimate: | Not Specified |
Team: | |
Sprint: | Sprint 57 (Oct 2019), Sprint 58 (Nov 2019), Sprint 59 (Dec 2019), Sprint 60 (Jan 2020), Sprint 61 (Feb 2020), Sprint 62 (Mar 2020), Sprint 63 (Apr 2020), Sprint 64 (May 2020) |
Story Points: | 5 |
Description |
There are several issues that should be checked/solved to build agent2 on windows:
First we must focus on (2). Might be easier to check with small prototype. Then we can start working on (3) by expanding prototype to use C/GO linking approach used in agent2. After linking issues are solved we can start working on agent C code compilation for linking with agent2. |
Comments |
Comment by Andris Zeila [ 2019 Nov 05 ] |
Build environment setupmingw64
When compiling use windows prompt rather than MSYS terminal provided by mingw PCREThe following instructions will compile and install 64 bit pcre libraries at c:\dev\pcre and 32 bit libraries at c:\dev\pcre32:
OpenSSLDonwload 32 and 64 bit builds from https://bintray.com/vszakats/generic/openssl/1.1.1d, extract into c:\dev\openssl32 and c:\dev\openssl directories accordingly. After it remove extracted *.dll.a (dll call wrapper libraries) as mingw prioritizes them before static libraries. Agent2 build process32 bit1. open mingw environment (windows command prompt) and navigate to build/mingw directory in Zabbix source tree 64 bit1. open mingw environment (windows command prompt) and navigate to build/mingw directory in Zabbix source tree Notes32 and 64 bit versions can be built on 64 bit platform, but only 32 bit version can be built on 32 bit platform. When working on 32 bit platform the steps are the same as 64bit build steps on 64 bit platform. |
Comment by Andris Zeila [ 2019 Dec 02 ] |
Released
Note that currently the number of supported checks is quite minimalistic:
The main goal was to add build support, additional checks will be added in future. |
Comment by Andris Zeila [ 2019 Dec 02 ] |
(15) Does not build with older OpenSSL versions c /MT /Gy /W3 /c /D _WINDOWS /D _CONSOLE /D UNICODE /D _UNICODE /D HAVE_WINLDAP_H /D HAVE_ASSERT_H /D ZABBIX_SERVICE /D "_VC80_UPGRADE=0x0600" /D HAVE_IPV6 /TC /DPCRE_STATIC /DHAVE_OPENSSL /DHAVE_OPENSSL_WITH_PSK tls.c ..\..\..\src\libs\zbxcrypto\tls.c(413): warning C4013: 'ERR_get_error_line_data' undefined; assuming extern returning int ..\..\..\src\libs\zbxcrypto\tls.c(415): warning C4013: 'ERR_error_string_n' undefined; assuming extern returning int ..\..\..\src\libs\zbxcrypto\tls.c(419): error C2065: 'ERR_TXT_STRING': undeclared identifier ..\..\..\src\libs\zbxcrypto\tls.c(3232): warning C4013: 'RAND_status' undefined; assuming extern returning int ..\..\..\src\libs\zbxcrypto\tls.c(4327): warning C4244: 'function': conversion from 'ZBX_SOCKET' to 'int', possible loss of data ..\..\..\src\libs\zbxcrypto\tls.c(4378): warning C4013: 'ERR_peek_error' undefined; assuming extern returning int ..\..\..\src\libs\zbxcrypto\tls.c(5080): warning C4244: 'function': conversion from 'ZBX_SOCKET' to 'int', possible loss of data NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.15.26726\bin\HostX64\x64\cl.exe"' : return code '0x2' Stop. vso CLOSED vso CLOSED |
Comment by Andris Zeila [ 2019 Dec 04 ] |
Released
|
Comment by Marina Generalova [ 2020 May 11 ] |
Documentation updated:
|