Make Keeps Failing on CentOS 7

Started by tnayak, July 02, 2019, 07:18:50 AM

Previous topic - Next topic

tnayak


Hi,

I'm a novice in Linux and I'm trying to install NetXMS.  I followed the instructions for Installing from source, but 'Make' keeps failing, after running for several minutes, at the same point with the following errors.  I would greatly appreciate any suggestions.


make[5]: Entering directory `/home/ares/netxms-2.2.15.2/src/db/dbdrv/mysql'
  CXX      mysql_la-mysql.lo
mysql.cpp: In function 'void* GetFieldInternal(MYSQL_RESULT*, int, int, void*, int, bool)':
mysql.cpp:703:3: error: 'my_bool' was not declared in this scope
   my_bool isNull;
   ^
mysql.cpp:703:11: error: expected ';' before 'isNull'
   my_bool isNull;
           ^
mysql.cpp:714:16: error: 'isNull' was not declared in this scope
   b.is_null = &isNull;
                ^
mysql.cpp: In function 'void* GetFieldUnbufferedInternal(MYSQL_UNBUFFERED_RESULT*, int, void*, int, bool)':
mysql.cpp:1063:7: error: 'my_bool' was not declared in this scope
       my_bool isNull;
       ^
mysql.cpp:1063:15: error: expected ';' before 'isNull'
       my_bool isNull;
               ^
mysql.cpp:1074:20: error: 'isNull' was not declared in this scope
       b.is_null = &isNull;
                    ^
At global scope:
cc1plus: warning: unrecognized command line option "-Wno-format-truncation" [enabled by default]
make[5]: *** [mysql_la-mysql.lo] Error 1
make[5]: Leaving directory `/home/ares/netxms-2.2.15.2/src/db/dbdrv/mysql'
make[4]: *** [all-recursive] Error 1
make[4]: Leaving directory `/home/ares/netxms-2.2.15.2/src/db/dbdrv'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/home/ares/netxms-2.2.15.2/src/db'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/ares/netxms-2.2.15.2/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/ares/netxms-2.2.15.2'
make: *** [all] Error 2



CentOS Setup
I'm installing NetXMS in a CentOS 7.6.1810 in an ESXi 6.7 virtual machine with:

    Minimal Install
    No Security profile selected
    Firewalld disabled and stopped


I installed the following packages installed:
    yum -y update
    yum -y groups install 'Development Tools'
    yum -y install libcurl-devel
    yum -y install libssh-devel
    yum -y install openssl-devel
    yum -y install wget
    yum -y install nano


I only installed this package to get around an error message that appeared in the pre-build checks:
    yum -y install epel-release
    yum -y install mosquitto-devel


I thought the issue involved a conflict with mariadb-libs-1:5.5.60-1.el7_5.x86_64 so I removed it before installing MySQL using the following commands:
    rpm -ev --nodeps mariadb-libs-5.5.60-1.el7_5.x86_64
    wget http://repo.mysql.com/mysql80-community-release-el7-3.noarch.rpm
    rpm -ivh mysql80-community-release-el7-3.noarch.rpm
    yum -y install mysql-server

    yum install mysql-devel


UPDATE #1: I tried starting MySQL Server ( systemctl status mysqld.service) before using the Make command, but the build failed almost immediately.

UPDATE #2: I tired installing MySQl using
mysql80-community-release-el7-1.noarch.rpm, but had the same result.  I'm trying to figure out how to install MySql 5.7 and will post the results. 

UPDATE #3: I haven't figured out how to install MySQL 5.7 yet, but I did find a couple of other posts on the forum where the user shared the results of the ./configure script and the Server Libs statement was not empty, e.g. Server libs: -lldap -llber or Server libs:  -lssl -lrt.  Could that point to a solution to the problem?


NetXMS Install
NetXMS source code package: wget https://www.netxms.org/download/releases/2.2/2.2.15/netxms-2.2.15.2.tar.gz
Build script: sh ./configure --with-server --with-mysql --with-agent

---------------------------------------------------------------------
                        Configure results
---------------------------------------------------------------------
Prefix                  : /usr/local
Platform                : Linux
Shared library suffix   : .so
IPv6 support            : YES
MQTT support            : YES
Build Server            : YES
Server libs             :
LDAP support            : NO
XMPP support            : YES
ZeroMQ support          : NO
Encryption enabled      : YES
SSH support enabled     : YES
Build DB-Drivers        : mysql sqlite
Build Clients           : NO
Build Agent             : YES
Agent libs              :
Agent extra components  :
Subagents list          : linux ds18x20 mysql netsvc ssh mqtt
Systemd support         : NO
Build Static Agent      : NO
UNICODE build           : YES
Use internal libexpat   : YES
Use internal libtre     : YES
Use internal libjansson : YES
Use internal sqlite     : YES
Use internal zlib       : NO
Force 32bit build       : NO
C compiler              : gcc
C++ compiler            : g++
C++ compiler info       : g++ (GCC) 4.8.5 20150623 (Red Hat 4.8.5-36)
CPPFLAGS                : -D_THREAD_SAFE -DTRE_WCHAR=1 -D_GNU_SOURCE -O2 -Wformat -Wno-unused-result -Wno-format-truncation -Werror=return-type -fvisibility=hidden -I/usr/local/include -DUNICODE -DPREFIX=L\"${prefix}\" -DDATADIR=L\"${pkgdatadir}\" -DBINDIR=L\"${bindir}\" -DLIBDIR=L\"${libdir}\" -DPKGLIBDIR=L\"${pkglibdir}\" -DSTATEDIR=L\"${localstatedir}/lib/netxms\" -DNDEBUG
CXXFLAGS                : -g -O2 -std=c++11 -fno-rtti -fno-exceptions -fvisibility-inlines-hidden
CFLAGS                  : -g -O2
LDFLAGS                 : -L/usr/local/lib
LIBS                    : -lz -lresolv -ldl  -lpthread -lssl -lcrypto
Executable LDFLAGS      :
Executable LIBS         :
MySQL CPPFLAGS          : -I/usr/include/mysql
MySQL LDFLAGS           : -L/usr/lib64/mysql
MySQL LIBS              : -lmysqlclient