broken build when -fsanitize=thread = yes

Bug #1164442 reported by Remi Collet
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
libmemcached
Fix Committed
Medium
Brian Aker

Bug Description

Build on Fedora 19, with latest gcc fails.

...
checking whether C compiler accepts -fsanitize=thread... yes
...
Configuration summary for libmemcached version 1.0.17
   * Installation prefix: /usr
   * System type: redhat-linux-gnu
   * Host CPU: x86_64
   * C Compiler: gcc (GCC) 4.8.0 20130320 (Red Hat 4.8.0-0.18)
   * C Flags: -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -Wno-unknown-pragmas -Wno-pragmas -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 -floop-parallelize-all -fwrapv
   * C++ Compiler: g++ (GCC) 4.8.0 20130320 (Red Hat 4.8.0-0.18)
   * C++ Flags: -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -Wno-unknown-pragmas -Wno-pragmas -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 -floop-parallelize-all -fwrapv
   * CPP Flags: -fvisibility=hidden
   * LIB Flags:
   * Assertions enabled: no
   * Debug enabled: no
   * Shared: yes
   * Warnings as failure: no
   * SASL support: yes
   * make -j: 4
   * VCS checkout: no
...
  CC libmemcached-1.0/t/c_sasl_test.o
g++: error: -fsanitize=thread linking must be done with -pie or -shared
make[1]: *** [libtest/core-count] Error 1
make[1]: *** Waiting for unfinished jobs....
g++: error: -fsanitize=thread linking must be done with -pie or -shared
make[1]: *** [libtest/backtrace] Error 1
make[1]: Leaving directory `/builddir/build/BUILD/libmemcached-1.0.17'
make: *** [all] Error 2

Brian Aker (brianaker)
Changed in libmemcached:
milestone: none → 1.0.18
assignee: nobody → Brian Aker (brianaker)
importance: Undecided → Medium
status: New → In Progress
Brian Aker (brianaker)
Changed in libmemcached:
status: In Progress → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.