Zabbix build fails when compiled without libcurl

XMLWordPrintable

      Compile server,proxy,agent
      1) --with-ldap
      2) but without --with-libcurl

       CC=clang CFLAGS="-g -ggdb3 -O0  -Wunused-but-set-variable"  ./configure --with-openipmi --enable-agent --enable-agent2 --enable-proxy --enable-server --with-postgresql --with-libxml2  --with-net-snmp --with-ssh2 --with-libevent --with-ldap  --enable-ipv6 --with-libpcre --with-openssl  --enable-webservic  --prefix=$(pwd)
      

      Result on master:

      simple.c:60:68: error: call to undeclared function 'zbx_join_hostport'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
         60 |                 zabbix_log(LOG_LEVEL_DEBUG, "LDAP - initialization failed [%s]", zbx_join_hostport(host_port,
            |                                                                                  ^
      simple.c:60:68: warning: format specifies type 'char *' but the argument has type 'int' [-Wformat]
         60 |                 zabbix_log(LOG_LEVEL_DEBUG, "LDAP - initialization failed [%s]", zbx_join_hostport(host_port,
            |                                                                            ~~    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
            |                                                                            %d
         61 |                                 sizeof(host_port), host, port));
            |                                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      ../../../../include/zbxcommon.h:789:26: note: expanded from macro 'zabbix_log'
        789 |                         zbx_log_handle(level, __VA_ARGS__);                                             \
            |                                               ^~~~~~~~~~~
      1 warning and 1 error generated.
      

      Also, there seems to be a separate issue on 7.0,7.4,master

      /usr/bin/ld: ../../src/libs/zbxxml/libzbxxml.a(libzbxxml_a-xml.o): in function `zbx_xml_node_free':
      /home/zabbix/second_zabbix/zabbix/src/libs/zbxxml/xml.c:439:(.text+0x1944): undefined reference to `zbx_str_free'
      /usr/bin/ld: /home/zabbix/second_zabbix/zabbix/src/libs/zbxxml/xml.c:439:(.text+0x1948): undefined reference to `zbx_str_free'
      /usr/bin/ld: /home/zabbix/second_zabbix/zabbix/src/libs/zbxxml/xml.c:439:(.text+0x194c): undefined reference to `zbx_vector_str_clear_ext'
      /usr/bin/ld: /home/zabbix/second_zabbix/zabbix/src/libs/zbxxml/xml.c:440:(.text+0x1958): undefined reference to `zbx_vector_str_destroy'
      /usr/bin/ld: ../../src/libs/zbxxml/libzbxxml.a(libzbxxml_a-xml.o): in function `xml_to_vector':
      /home/zabbix/second_zabbix/zabbix/src/libs/zbxxml/xml.c:478:(.text+0x1a88): undefined reference to `zbx_vector_str_create'
      /usr/bin/ld: /home/zabbix/second_zabbix/zabbix/src/libs/zbxxml/xml.c:507:(.text+0x1bec): undefined reference to `zbx_vector_str_append'
      /usr/bin/ld: /home/zabbix/second_zabbix/zabbix/src/libs/zbxxml/xml.c:510:(.text+0x1c3c): undefined reference to `zbx_vector_str_append'
      /usr/bin/ld: /home/zabbix/second_zabbix/zabbix/src/libs/zbxxml/xml.c:515:(.text+0x1c64): undefined reference to `zbx_vector_str_append'
      collect2: error: ld returned 1 exit status
      

            Assignee:
            Artjoms Rimdjonoks
            Reporter:
            Artjoms Rimdjonoks
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - Not Specified
                Not Specified
                Logged:
                Time Spent - 1.5h
                1.5h