0

I am trying to compile libmemcached on Centos 6.4 with gcc 4.8.2. I've run configure which gives me:

Configuration summary for libmemcached version 1.0.17

   * Installation prefix:       /usr/local
   * System type:               unknown-linux-gnu
   * Host CPU:                  x86_64
   * C Compiler:                gcc (GCC) 4.8.2
   * C Flags:                   -g -O2  -Wno-unknown-pragmas -Wno-pragmas -Wall -Wextra -std=c99 -Wunsuffixed-float-constants -Wjump-misses-init -Wno-attributes -Waddress -Wvarargs -Warray-bounds -Wbad-function-cast -Wchar-subscripts -Wcomment -Wfloat-equal -Wformat-security -Wformat=2 -Wformat-y2k -Wlogical-op -Wmaybe-uninitialized -Wmissing-field-initializers -Wmissing-noreturn -Wmissing-prototypes -Wnested-externs -Wnormalized=id -Woverride-init -Wpointer-arith -Wpointer-sign -Wredundant-decls -Wshadow -Wsign-compare -Wstrict-overflow=1 -Wswitch-enum -Wtrampolines -Wundef -Wunsafe-loop-optimizations -funsafe-loop-optimizations -fsanitize=address -fsanitize=thread -Wclobbered -Wunused -Wunused-result -Wunused-variable -Wunused-parameter -Wunused-local-typedefs -Wwrite-strings -fwrapv -pipe
   * C++ Compiler:              g++ (GCC) 4.8.2
   * C++ Flags:                 -g -O2 -Wno-unknown-pragmas -Wno-pragmas -Wall -Wextra -Wno-attributes -Wvarargs -Waddress -Warray-bounds -Wchar-subscripts -Wcomment -Wctor-dtor-privacy -Wfloat-equal -Wformat=2 -Wformat-y2k -Wmaybe-uninitialized -Wmissing-field-initializers -Wlogical-op -Wnon-virtual-dtor -Wnormalized=id -Woverloaded-virtual -Wpointer-arith -Wredundant-decls -Wshadow -Wsign-compare -Wstrict-overflow=1 -Wswitch-enum -Wtrampolines -Wundef -Wunsafe-loop-optimizations -funsafe-loop-optimizations -Wc++11-compat -fsanitize=address -fsanitize=thread -Wclobbered -Wunused -Wunused-result -Wunused-variable -Wunused-parameter -Wunused-local-typedefs -Wwrite-strings -Wformat-security -fwrapv -pipe
   * CPP Flags:                  -fvisibility=hidden
   * LIB Flags:                 
   * Assertions enabled:        no
   * Debug enabled:             no
   * Shared:                    yes
   * Warnings as failure:       no
   * SASL support:              yes
   * make -j:                   2
   * VCS checkout:              no

But after I run make I always get:

g++: error: -fsanitize=address is incompatible with -fsanitize=thread

What does this error mean?

2

2 Answers 2

1

This seems to be a bug in the recent versions: https://bugs.launchpad.net/libmemcached/+bug/1169311

You likely don't want to be building bleeding edge--use the latest stable version, especially if you're on production hardware. Have you tried building a stable release?

0

Both of these are options to the clang version of g++.

http://clang.llvm.org/docs/ThreadSanitizer.html

http://clang.llvm.org/docs/AddressSanitizer.html

And you can't use them both at the same time when building an executable as they load incompatible extra libraries.

Look in the config.log file and try and figure out why these options are being enabled in the build. Something is going wrong in the config process as both of these options slow down the code significantly and should not be configured by default. They are primarily intended to help debug runtime errors, not be in production code.

Check for environmental variables related to g++.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .