NetXMS Support Forum

Please login or register.

Login with username, password and session length

Author Topic: CentOS7/V2.2.13 configure "cannot compute sizeof (wchar_t)"  (Read 399 times)

ptrivino

  • Newbie
  • *
  • Posts: 8
    • View Profile
CentOS7/V2.2.13 configure "cannot compute sizeof (wchar_t)"
« on: April 13, 2019, 04:29:42 am »

Hi, I am giving NetXMS a try. Since I'm CentOS 7, I'm doing 'from source' which seems well explained. I have run into a couple missing dependencies - OpenSSL (saw the document warning, thought that was already installed, but ok, fixed), curl (needed libcurl-devel, OK), libssh and libssh-devel, then this:

Quote
checking size of wchar_t... configure: error: in `/home/a-ptrivino/Downloads/netxms-2.2.13':
configure: error: cannot compute sizeof (wchar_t)
See `config.log' for more details

(That last line is a hoot, this is FROM config.log... :D)

But I don't find anything about this in this forum. The germane part of config.log seems to be this:

Code: [Select]
| #if HAVE_WCHAR_H
| #include <wchar.h>
| #endif
|
|
| static long int longval () { return (long int) (sizeof (wchar_t)); }
| static unsigned long int ulongval () { return (long int) (sizeof (wchar_t)); }
| #include <stdio.h>
| #include <stdlib.h>
| int
| main ()
| {
|
|   FILE *f = fopen ("conftest.val", "w");
|   if (! f)
|     return 1;
|   if (((long int) (sizeof (wchar_t))) < 0)
|     {
|       long int i = longval ();
|       if (i != ((long int) (sizeof (wchar_t))))
|       return 1;
|       fprintf (f, "%ld", i);
|     }
|   else
|     {
|       unsigned long int i = ulongval ();
|       if (i != ((long int) (sizeof (wchar_t))))
|       return 1;
|       fprintf (f, "%lu", i);
|     }
|   /* Do not output a trailing newline, as this causes \r\n confusion
|      on some platforms.  */
|   return ferror (f) || fclose (f) != 0;
|
|   ;
|   return 0;
| }
configure:26002: error: in `/home/a-ptrivino/Downloads/netxms-2.2.13':
configure:26004: error: cannot compute sizeof (wchar_t)
See `config.log' for more details

Please let me know what else I should provide to help find the cause of this.  Thank you!

Paul
Logged

Victor Kirhenshtein

  • Lead Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 6584
    • View Profile
Re: CentOS7/V2.2.13 configure "cannot compute sizeof (wchar_t)"
« Reply #1 on: April 15, 2019, 05:39:17 pm »

Hi,

could you please provide full config.log?

Best regards,
Victor
Logged

ptrivino

  • Newbie
  • *
  • Posts: 8
    • View Profile
Re: CentOS7/V2.2.13 configure "cannot compute sizeof (wchar_t)"
« Reply #2 on: April 15, 2019, 07:22:14 pm »

Surely, attached. Thanks.

Paul
Logged

Victor Kirhenshtein

  • Lead Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 6584
    • View Profile
Re: CentOS7/V2.2.13 configure "cannot compute sizeof (wchar_t)"
« Reply #3 on: April 16, 2019, 07:57:19 pm »

Actual failure related to OpenSSL libraries:

./conftest: error while loading shared libraries: libssl.so.1.1: cannot open shared object file: No such file or directory

Make sure you have matching libssl development and binary packages and that correct libssl.so is in library path.

Best regards,
Victor
Logged

ptrivino

  • Newbie
  • *
  • Posts: 8
    • View Profile
Re: CentOS7/V2.2.13 configure "cannot compute sizeof (wchar_t)"
« Reply #4 on: April 16, 2019, 10:00:44 pm »

OK I now see I have 1.0.2k and 1.1.1b of OpenSSL both installed (kinda), I'll try getting out of that. the 1.1.1b libssl.so is in /usr/local/lib64 but not in my libpath. But I don't want two versions at all, so...

Thanks.
Logged

ptrivino

  • Newbie
  • *
  • Posts: 8
    • View Profile
Re: CentOS7/V2.2.13 configure "cannot compute sizeof (wchar_t)"
« Reply #5 on: April 17, 2019, 10:44:37 pm »

OK, I started over - built a new CentOS 7 VM, and this time I verified that OpenSSL (v1.0.2k) is installed. I also then installed/updated MySQL, perl-core, libcurl-devel, and libssh-devel because those were what were complained about on the first tries. I then untar NetXMS (netxms-2.2.13.tar.gz), and do

Code: [Select]
./configure --with-server --with-mysql --with-agent
which then gives these last three lines:

Quote
checking openssl/crypto.h presence... no
checking for openssl/crypto.h... no
configure: error: OpenSSL is required for encryption support

I do see that there are crypto.h files in the /usr/src/kernels (not what we want I'm sure). I also see that the tar for openssl v1.0.2r does have that file.

Finding the --with-bundled-openssl config option, I tried that:

Quote
checking openssl/crypto.h usability... no
checking openssl/crypto.h presence... configure: error: OpenSSL is required for encryption support
no
checking for openssl/crypto.h... no

So, I'm stumped.

Paul
Logged

Victor Kirhenshtein

  • Lead Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 6584
    • View Profile
Re: CentOS7/V2.2.13 configure "cannot compute sizeof (wchar_t)"
« Reply #6 on: April 18, 2019, 06:06:44 pm »

Did you install openssl-devel package?

This is from my RHEL 7 system:

build-rhel-7-x64:~$ rpm -qa | grep openssl
openssl-libs-1.0.2k-16.el7_6.1.x86_64
openssl-devel-1.0.2k-16.el7_6.1.x86_64
openssl-1.0.2k-16.el7_6.1.x86_64

Best regards,
Victor
Logged

ptrivino

  • Newbie
  • *
  • Posts: 8
    • View Profile
Re: CentOS7/V2.2.13 configure "cannot compute sizeof (wchar_t)"
« Reply #7 on: April 18, 2019, 09:22:35 pm »

Victor, thanks, I have worked my way through the rest of the needed packages and/or set configure options to avoid them (mosquitto for example). Thanks.
Logged