xiaoyur347/gperftools_uclibc

how to compile it?

Opened this issue · 5 comments

when i use autoconf:
"configure.ac:21: error: possibly undefined macro: AM_INIT_AUTOMAKE
If this token and others are legitimate, please use m4_pattern_allow.
See the Autoconf documentation."

and can tell the compile steps?

i use make with mips, and it happen:

In file included from src/tcmalloc.cc:133:
src/thread_cache.h:283: warning: tls_model' attribute ignored /tmp/ccMMJTSU.s: Assembler messages: /tmp/ccMMJTSU.s:697: Error: opcode not supported on this processor: mips1 (mips1)sync'
/tmp/ccMMJTSU.s:709: Error: opcode not supported on this processor: mips1 (mips1) ll $2,0($4)' /tmp/ccMMJTSU.s:711: Error: opcode not supported on this processor: mips1 (mips1)sc $3,0($4)'
/tmp/ccMMJTSU.s:869: Error: opcode not supported on this processor: mips1 (mips1) ll $2,0($16)' /tmp/ccMMJTSU.s:872: Error: opcode not supported on this processor: mips1 (mips1)sc $3,0($16)'
/tmp/ccMMJTSU.s:886: Error: opcode not supported on this processor: mips1 (mips1) sync' /tmp/ccMMJTSU.s:954: Error: opcode not supported on this processor: mips1 (mips1)ll $3,0($5)'
/tmp/ccMMJTSU.s:957: Error: opcode not supported on this processor: mips1 (mips1) sc $4,0($5)' /tmp/ccMMJTSU.s:971: Error: opcode not supported on this processor: mips1 (mips1)sync'
/tmp/ccMMJTSU.s:1115: Error: opcode not supported on this processor: mips1 (mips1) `sync'

anyone have idea?

Maybe the atomic operation(asm) in atomicops-internals-mips.h is not
supported in mips1.

2013/12/19 van201314 notifications@github.com

i use make with mips, and it happen:

In file included from src/tcmalloc.cc:133:
src/thread_cache.h:283: warning: tls_model' attribute ignored
/tmp/ccMMJTSU.s: Assembler messages:
/tmp/ccMMJTSU.s:697: Error: opcode not supported on this processor: mips1
(mips1)sync'
/tmp/ccMMJTSU.s:709: Error: opcode not supported on this processor: mips1
(mips1) ll $2,0($4)'
/tmp/ccMMJTSU.s:711: Error: opcode not supported on this processor: mips1
(mips1)sc $3,0($4)'
/tmp/ccMMJTSU.s:869: Error: opcode not supported on this processor: mips1
(mips1) ll $2,0($16)'
/tmp/ccMMJTSU.s:872: Error: opcode not supported on this processor: mips1
(mips1)sc $3,0($16)'
/tmp/ccMMJTSU.s:886: Error: opcode not supported on this processor: mips1
(mips1) sync'
/tmp/ccMMJTSU.s:954: Error: opcode not supported on this processor: mips1
(mips1)ll $3,0($5)'
/tmp/ccMMJTSU.s:957: Error: opcode not supported on this processor: mips1
(mips1) sc $4,0($5)'
/tmp/ccMMJTSU.s:971: Error: opcode not supported on this processor: mips1
(mips1)sync'
/tmp/ccMMJTSU.s:1115: Error: opcode not supported on this processor: mips1
(mips1) `sync'

anyone have idea?


Reply to this email directly or view it on GitHubhttps://github.com//issues/1#issuecomment-30909214
.

i update the new resource from github, and when i config and make
./configure --host=mipsel-linux-uclibc --enable-frame-pointers --enable-minimal --disable-debugalloc --disable-heap-checker --disable-heap-profiler --disable-cpu-profiler LDFLAGS="-lpthread"

and make, it take this error:
mipsel-linux-uclibc/bin/ld: tcmalloc::ThreadCache::threadlocal_data_: TLS definition in ./.libs/libtcmalloc_minimal_internal.a(libtcmalloc_minimal_internal_la-thread_cache.o) section .tdata mismatches non-TLS reference in .libs/libtcmalloc_minimal_la-tcmalloc.o
./.libs/libtcmalloc_minimal_internal.a(libtcmalloc_minimal_internal_la-thread_cache.o): could not read symbols: Bad value
collect2: ld returned 1 exit status
make: *** [libtcmalloc_minimal.la] Error 1

so, how to do it?

now i know this is my mips does not support tls, so when i undefine HAVE_TLS 1, this error disappear
but a new error happen:
./.libs/libtcmalloc_minimal.so: undefined reference to `__cxa_atexit'

i take mipsel-linux-uclibc-g++ -v , i can see:
--enable-__cxa_atexit

and grep __cxa_atexit .libs/*
Binary file .libs/libtcmalloc_minimal.a matches
Binary file .libs/libtcmalloc_minimal_internal.a matches
Binary file .libs/libtcmalloc_minimal_internal_la-memfs_malloc.o matches
Binary file .libs/libtcmalloc_minimal_internal_la-static_vars.o matches
Binary file .libs/libtcmalloc_minimal_internal_la-symbolize.o matches
Binary file .libs/libtcmalloc_minimal_la-tcmalloc.o matches
Binary file .libs/libtcmalloc_minimal.so matches
Binary file .libs/libtcmalloc_minimal.so.4 matches
Binary file .libs/libtcmalloc_minimal.so.4.1.2 matches

so, anyone know how to solve it...

I search my toolchain and find this:
Binary file bin/g++ matches
Binary file bin/gfortran matches
Binary file bin/gcc matches
Binary file bin/c++ matches
include/c++/4.5.3/cxxabi.h: __cxa_atexit(void ()(void), void_, void_)
_GLIBCXX_NOTHROW;
Binary file lib/libstdc++.so matches
Binary file lib/libstdc++.a matches
Binary file lib/libstdc++.so.6 matches
Binary file lib/libstdc++.so.6.0.14 matches
Binary file sys-root/lib/libuClibc-0.9.32.1.so matches (__cxa_atexit
defined here)
Binary file sys-root/lib/libc.so.0 matches
Binary file sys-root/usr/lib/libc.a matches
Binary file sys-root/usr/lib/uclibc_nonshared.a matches

nm sys-root/lib/libuClibc-0.9.32.1.so | grep __cxa_atexit
00059d30 t __GI___cxa_atexit
00059d30 T __cxa_atexit

2013/12/30 van201314 notifications@github.com

now i know this is my mips does not support tls, so when i undefine
HAVE_TLS 1, this error disappear
but a new error happen:
./.libs/libtcmalloc_minimal.so: undefined reference to `__cxa_atexit'

i take mipsel-linux-uclibc-g++ -v , i can see:
--enable-__cxa_atexit

and grep __cxa_atexit .libs/*
Binary file .libs/libtcmalloc_minimal.a matches
Binary file .libs/libtcmalloc_minimal_internal.a matches
Binary file .libs/libtcmalloc_minimal_internal_la-memfs_malloc.o matches
Binary file .libs/libtcmalloc_minimal_internal_la-static_vars.o matches
Binary file .libs/libtcmalloc_minimal_internal_la-symbolize.o matches
Binary file .libs/libtcmalloc_minimal_la-tcmalloc.o matches
Binary file .libs/libtcmalloc_minimal.so matches
Binary file .libs/libtcmalloc_minimal.so.4 matches
Binary file .libs/libtcmalloc_minimal.so.4.1.2 matches

so, anyone know how to solve it...


Reply to this email directly or view it on GitHubhttps://github.com//issues/1#issuecomment-31338517
.