- 论坛徽章:
- 1
|
本帖最后由 salman_chan 于 2016-04-18 10:29 编辑
在AIX中编译第三方kafka库时,报错了
不支持TLS
gcc -MD -MP -g -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -c rdkafka_buf.c -o rdkafka_buf.o
In file included from rdkafka_int.h:46,
from rdkafka_buf.c:29:
rdtime.h: In function 'rd_ctime':
rdtime.h:83: error: thread-local storage not supported for this target
这样编译也不行
gcc -MD -MP -g -O2 -fPIC -Wall -Wsign-compare -Wfloat-equal -Wpointer-arith -enable-tls=yes -c rdkafka_transport.c -o rdkafka_transport.o
升级了gcc版本,此问题解决
#gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/opt/freeware/libexec/gcc/powerpc-ibm-aix6.1.0.0/4.9.2/lto-wrapper
Target: powerpc-ibm-aix6.1.0.0
Configured with: ../gcc-4.9.2/configure --with-gmp=/home/gnu/gcc482/ --with-ppl=/home/gnu/gcc482/ --with-mpfr=/home/gnu/gcc482/ --with-mpc=/home/gnu/gcc482/ --enable-languages=c,c++,fortran CFLAGS='-O2 -mpowerpc -mno-mfcrf -mtune=power6' CPPFLAGS=-fexceptions CXXFLAGS='-O2 -mpowerpc -mno-mfcrf -mtune=power6 ' CPPFLAGS=-I/home/gnu/gcc482/include LDFLAGS=-L/home/gnu/gcc482/lib --prefix=/opt/freeware --mandir=/opt/freeware/man --infodir=/opt/freeware/info --enable-version-specific-runtime-libs --disable-nls --enable-decimal-float=dpd --host=powerpc-ibm-aix6.1.0.0
Thread model: aix
gcc version 4.9.2 (GCC)
感谢版主 @windoze 的指点 |
|