Here is the detail below, and I can't find the -l flags to the linker, where is it? And is there any way to put libasan.so.1 ahead of libc.so in this gcc ld order? arm-linux-androideabi-gcc -v Using built-in specs. COLLECT_GCC=arm-linux-androideabi-gcc COLLECT_LTO_WRAPPER=/home/star/codes/icos_debug_ci_line/prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.9/bin/../libexec/gcc/arm-linux-androideabi/4.9/lto-wrapper Target: arm-linux-androideabi Configured with: .././../gcc/gcc-4.9/configure --prefix=/home/star/codes/android-toolchain-src/prefix --target=arm-linux-androideabi --host=x86_64-linux-gnu --build=x86_64-linux-gnu --with-gnu-as --with-gnu-ld --enable-languages=c,c++ --with-gmp=/home/star/codes/android-toolchain-src/prefix --with-mpfr=/home/star/codes/android-toolchain-src/prefix --with-mpc=/home/star/codes/android-toolchain-src/prefix --with-cloog=/home/star/codes/android-toolchain-src/prefix --with-isl=/home/star/codes/android-toolchain-src/prefix --with-ppl=/home/star/codes/android-toolchain-src/prefix --disable-ppl-version-check --disable-cloog-version-check --disable-isl-version-check --enable-cloog-backend=isl --with-host-libstdcxx='-static-libgcc -Wl,-Bstatic,-lstdc++,-Bdynamic -lm' --disable-libssp --enable-threads --disable-nls --disable-libmudflap --disable-libgomp --enable-libstdc__-v3 --disable-sjlj-exceptions --disable-shared --disable-tls --disable-libitm --with-float=soft --with-fpu=vfp --with-arch=armv5te --enable-target-optspace --with-gcc-version=4.9 --disable-ppl-version-check --disable-cloog-version-check --disable-isl-version-check --enable-cloog-backend=isl --with-host-libstdcxx='-static-libgcc -Wl,-Bstatic,-lstdc++,-Bdynamic -lm' --enable-libstdc__-v3 --enable-initfini-array --with-sysroot=/home/star/codes/android-toolchain-src/build/sysroot --with-binutils-version=2.23 --with-mpfr-version=3.1.1 --with-mpc-version=1.0.1 --with-gmp-version=5.0.5 --with-gdb-version=7.6 --disable-bootstrap --disable-libquadmath --enable-plugins --enable-libgomp --enable-libsanitizer --enable-shared --enable-gold --enable-graphite=yes --with-cloog-version=0.18.0 --with-isl-version=0.11.1 --enable-eh-frame-hdr-for-static --with-arch=armv5te --enable-gold --prefix=/home/star/codes/android-toolchain-src/prefix --program-transform-name='s&^&arm-linux-androideabi-&' --enable-gold=default Thread model: posix gcc version 4.9 20140514 (prerelease) (GCC)
在 2014年7月29日星期二UTC+8下午6时05分56秒,Evgeniy Stepanov写道: > > gcc > > On Tue, Jul 29, 2014 at 1:10 PM, ji wang <[email protected] > <javascript:>> wrote: > > Ah,I am sorry. Run what with -v? I am not much familiar about this. > > > > > > 在 2014年7月29日星期二UTC+8下午4时55分46秒,Evgeniy Stepanov写道: > >> > >> Run it with -v and check the order of -l flags to the linker, which > >> determines the order of DT_NEEDED entries. > >> > >> On Tue, Jul 29, 2014 at 12:41 PM, ji wang <[email protected]> wrote: > >> >>I could not make static runtime work on older android versions, but > >> >>now I don't see any issues with it. Perhaps something with dlopen-ed > >> >>libraries? > >> > I prefer use shared Asan lib now :), because I've found some issues > like > >> > when I use static one to check two libs the sametime: > >> > "Shadow memory range interleaves with an existing memory mapping." > >> > > >> > And Yuri said the GCC Asan android toolchain which I am using now, > when > >> > we > >> > pass -fsanitize=address to the LD_FLAGS, > >> > the GCC can arrange proper lib order during link using libasan.so.1 > >> > ahead of > >> > libc.so, Is that right? Or some difference on Android? > >> > > >> > > >> > 在 2014年7月29日星期二UTC+8下午4时00分05秒,Evgeniy Stepanov写道: > >> >> > >> >> I could not make static runtime work on older android versions, but > >> >> now I don't see any issues with it. Perhaps something with dlopen-ed > >> >> libraries? > >> >> And you need shared runtime for zygote anyway, unless you build your > >> >> own system image. > >> >> > >> >> On Mon, Jul 28, 2014 at 6:49 PM, ji wang <[email protected]> > wrote: > >> >> > How about use static asan runtime? Do the interceptors work with > the > >> >> > static > >> >> > runtime? > >> >> > Like libasan.a those static lib could compiled into the executable > >> >> > and > >> >> > the > >> >> > test shared lib. > >> >> > > >> >> > -- > >> >> > You received this message because you are subscribed to the Google > >> >> > Groups > >> >> > "address-sanitizer" group. > >> >> > To unsubscribe from this group and stop receiving emails from it, > >> >> > send > >> >> > an > >> >> > email to [email protected]. > >> >> > For more options, visit https://groups.google.com/d/optout. > >> > > >> > -- > >> > You received this message because you are subscribed to the Google > >> > Groups > >> > "address-sanitizer" group. > >> > To unsubscribe from this group and stop receiving emails from it, > send > >> > an > >> > email to [email protected]. > >> > For more options, visit https://groups.google.com/d/optout. > > > > -- > > You received this message because you are subscribed to the Google > Groups > > "address-sanitizer" group. > > To unsubscribe from this group and stop receiving emails from it, send > an > > email to [email protected] <javascript:>. > > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "address-sanitizer" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
