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

configure script fails to detect go compiler presence

XMLWordPrintable

    • Sprint 57 (Oct 2019)
    • 0.125

       

      configure script fails to check go compiler presence, make fails with compilation error afterwards.

      Steps to reproduce:

      1. ./bootstrap.sh
      2. ./configure --enable-agent2
      3. make install

      Result:

      configure:

      ...
      checking for libevent support... yes
      checking for go... no
      checking for javac... javac
      checking for jar... jar
      ...

      make:

      ...
      make[5]: Entering directory '/home/aleksandrs/devel/zabbix/go/src/zabbix/cmd/zabbix_agent2'
      ...
      /bin/bash: go: command not found
      /bin/bash: go: command not found
      /bin/bash: go: command not found
      Makefile:527: recipe for target 'build' failed
      make[5]: *** [build] Error 127
      

      Expected:
      configure:

      checking for libevent support... yes
      checking for go... no
      configure: error: Unable to find "go" executable in path
      

      Solution:

      diff --git a/configure.ac b/configure.ac
      index d92fa4494c0..ace19e6fe92 100644
      --- a/configure.ac
      +++ b/configure.ac
      @@ -1685,7 +1685,7 @@ SENDER_LIBS="$SENDER_LIBS $TLS_LIBS"
       
       if test "x$agent2" = "xyes"; then
              AC_CHECK_PROGS([GO], [go], [no])
      -       if test "x$go" = "xno"; then
      +       if test "x$GO" = "xno"; then
                      AC_MSG_ERROR([Unable to find "go" executable in path])
              fi
       fi

            viktors.tjarve Viktors Tjarve
            Kalimulin Alex Kalimulin
            Team A
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: