Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-3445

cannot statically compile zabbix_proxy with sqlite3

XMLWordPrintable

    • Icon: Problem report Problem report
    • Resolution: Cannot Reproduce
    • Icon: Major Major
    • 3.0.13rc1
    • 1.8.3, 1.8.4, 3.0.7, 3.2.3
    • Proxy (P)
    • centos 5.4
    • Sprint 18, Sprint 19

      I tried both 1.8.3 and 1.8.4 with the same result:

      2 issues are described

      a) The configuration process successfully completes: ./configure --enable-proxy --enable-static --with-sqlite3
      but then the last step of the make process returns: "/usr/bin/ld: cannot find -lsqlite3" because libsqlite3.a isn't included in either the sqlite or the sqlite-devel package (i think Configure should check and complain), so it's needed to manually compile sqlite from sources and point the configure to the new path.

      b) But even after that, the make process still fails with various undefined reference errors related to sqlite library (i.e.: /root/zabbix-1.8.3/src/libs/zbxdb/db.c:757: undefined reference to `sqlite3_free_table').
      In order to fix this I had to manually edit the src/zabbix_proxy/Makefile and change:

      LIBS = -lm -lresolv
      to
      LIBS = -lm -lresolv -lsqlite3 -ldl -lpthread

      after that, the make process finished successfully

            Unassigned Unassigned
            gabriele.armao Gabriele Armao
            Team C
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: