Cannot compile from source on Centos7

Hi,

I try to compile the new 1.6.0 on Centos7, but i get the following error:

# make
clang++ -O3 -fstack-protector -fPIE -Wall -Wno-deprecated -std=c++11 -pthread  -DNDEBUG  -DZT_USE_MINIUPNPC -DMINIUPNP_STATICLIB -DMINIUPNPC_SET_SOCKET_TIMEOUT -DMINIUPNPC_GET_SRC_ADDR -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=600 -DOS_STRING=\"Linux\" -DMINIUPNPC_VERSION_STRING=\"2.0\" -DUPNP_VERSION_STRING=\"UPnP/1.1\" -DENABLE_STRNATPMPERR -DZT_BUILD_PLATFORM=1 -DZT_BUILD_ARCHITECTURE=2 -DZT_SOFTWARE_UPDATE_DEFAULT="\"disable\"" -D_MT_ALLOCATOR_H -D_POOL_ALLOCATOR_H -D_EXTPTR_ALLOCATOR_H -D_DEBUG_ALLOCATOR_H -DZT_USE_X64_ASM_SALSA2012 -DZT_USE_FAST_X64_ED25519 -msse -msse2 -mssse3 -msse4.1 -mpclmul   -c -o node/AES_aesni.o node/AES_aesni.cpp
node/AES_aesni.cpp:30:16: warning: unknown attribute '__target__' ignored [-Wattributes]
__attribute__((__target__("ssse3,sse4,sse4.1,sse4.2,pclmul")))
               ^
node/AES_aesni.cpp:35:15: error: use of undeclared identifier '_mm_clmulepi64_si128'
        __m128i t1 = _mm_clmulepi64_si128(h, y, 0x00);
                     ^
node/AES_aesni.cpp:36:15: error: use of undeclared identifier '_mm_clmulepi64_si128'
        __m128i t2 = _mm_clmulepi64_si128(h, y, 0x01);
                     ^
node/AES_aesni.cpp:37:15: error: use of undeclared identifier '_mm_clmulepi64_si128'
        __m128i t3 = _mm_clmulepi64_si128(h, y, 0x10);
                     ^
node/AES_aesni.cpp:38:15: error: use of undeclared identifier '_mm_clmulepi64_si128'
        __m128i t4 = _mm_clmulepi64_si128(h, y, 0x11);
                     ^
node/AES_aesni.cpp:185:16: warning: unknown attribute '__target__' ignored [-Wattributes]
__attribute__((__target__("ssse3,sse4,sse4.1,sse4.2,aes,pclmul")))
               ^
node/AES_aesni.cpp:202:16: warning: unknown attribute '__target__' ignored [-Wattributes]
__attribute__((__target__("ssse3,sse4,sse4.1,sse4.2,aes,pclmul")))
               ^
node/AES_aesni.cpp:207:6: error: use of undeclared identifier '_mm_aeskeygenassist_si128'
        y = _mm_aeskeygenassist_si128(a, 0x00);
            ^
node/AES_aesni.cpp:222:16: warning: unknown attribute '__target__' ignored [-Wattributes]
__attribute__((__target__("ssse3,sse4,sse4.1,sse4.2,pclmul")))
               ^
node/AES_aesni.cpp:260:44: error: use of undeclared identifier '_mm_clmulepi64_si128'
                        __m128i a = _mm_xor_si128(_mm_xor_si128(_mm_clmulepi64_si128(hhhh, d1, 0x00), _mm_clmulepi64_si128(hhh, d2, 0x00)), _mm_xor_si12...
                                                                ^
node/AES_aesni.cpp:261:44: error: use of undeclared identifier '_mm_clmulepi64_si128'
                        __m128i b = _mm_xor_si128(_mm_xor_si128(_mm_clmulepi64_si128(hhhh, d1, 0x11), _mm_clmulepi64_si128(hhh, d2, 0x11)), _mm_xor_si12...
                                                                ^
node/AES_aesni.cpp:262:58: error: use of undeclared identifier '_mm_clmulepi64_si128'
                        __m128i c = _mm_xor_si128(_mm_xor_si128(_mm_xor_si128(_mm_clmulepi64_si128(hhhh2, _mm_xor_si128(_mm_shuffle_epi32(d1, 78), d1), ...
                                                                              ^
node/AES_aesni.cpp:290:16: warning: unknown attribute '__target__' ignored [-Wattributes]
__attribute__((__target__("ssse3,sse4,sse4.1,sse4.2,pclmul,aes")))
               ^
node/AES_aesni.cpp:310:15: error: use of undeclared identifier '_mm_clmulepi64_si128'
        __m128i t1 = _mm_clmulepi64_si128(h, y, 0x00);
                     ^
node/AES_aesni.cpp:311:15: error: use of undeclared identifier '_mm_clmulepi64_si128'
        __m128i t2 = _mm_clmulepi64_si128(h, y, 0x01);
                     ^
node/AES_aesni.cpp:312:15: error: use of undeclared identifier '_mm_clmulepi64_si128'
        __m128i t3 = _mm_clmulepi64_si128(h, y, 0x10);
                     ^
node/AES_aesni.cpp:313:15: error: use of undeclared identifier '_mm_clmulepi64_si128'
        __m128i t4 = _mm_clmulepi64_si128(h, y, 0x11);
                     ^
node/AES_aesni.cpp:314:10: error: use of undeclared identifier '_mm_aesenc_si128'
        encIV = _mm_aesenc_si128(encIV, k[1]);
                ^
node/AES_aesni.cpp:317:10: error: use of undeclared identifier '_mm_aesenc_si128'
        encIV = _mm_aesenc_si128(encIV, k[2]);
                ^
node/AES_aesni.cpp:320:10: error: use of undeclared identifier '_mm_aesenc_si128'
        encIV = _mm_aesenc_si128(encIV, k[3]);
                ^
node/AES_aesni.cpp:325:10: error: use of undeclared identifier '_mm_aesenc_si128'
        encIV = _mm_aesenc_si128(encIV, k[4]);
                ^
node/AES_aesni.cpp:328:10: error: use of undeclared identifier '_mm_aesenc_si128'
        encIV = _mm_aesenc_si128(encIV, k[5]);
                ^
node/AES_aesni.cpp:331:10: error: use of undeclared identifier '_mm_aesenc_si128'
        encIV = _mm_aesenc_si128(encIV, k[6]);
                ^
node/AES_aesni.cpp:334:10: error: use of undeclared identifier '_mm_aesenc_si128'
        encIV = _mm_aesenc_si128(encIV, k[7]);
                ^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
5 warnings and 20 errors generated.
make: *** [node/AES_aesni.o] Error 1

Compiling on Centos8 runs fine.
Can someone give me hint?

best regards
Chris

Problem solved. In case someone else is having this problem:

yum install centos-release-scl
yum install devtoolset-8

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.