Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 600276 - app-arch/p7zip-16.02-r1: fails to compile with clang and -fsanitize=address
Summary: app-arch/p7zip-16.02-r1: fails to compile with clang and -fsanitize=address
Status: CONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Matthew Thode ( prometheanfire )
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-11-20 11:37 UTC by Agostino Sarubbo
Modified: 2016-11-20 11:41 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Agostino Sarubbo gentoo-dev 2016-11-20 11:37:03 UTC
The test was done in this way:

CC="clang" CXX="clang++" CFLAGS="-fsanitize=address" CXXFLAGS="-fsanitize=address" LDFLAGS="-fsanitize=address" MAKEOPTS="-j1" emerge -v p7zip


clang++ -c -I. -I../../../../C -I../../../../CPP/myWindows -I../../../../CPP/include_windows -I../../../../CPP -fsanitize=address -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DNDEBUG -D_REENTRANT -DENV_UNIX -D_7ZIP_LARGE_PAGES -D_7ZIP_ASM  -DEXTERNAL_CODECS -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_REENTRANT -DENV_UNIX -DBREAK_HANDLER -DUNICODE -D_UNICODE -DUNIX_USE_WIN_FILE   ../../../../CPP/myWindows/wine_date_and_time.cpp
clang++ -fsanitize=address -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DNDEBUG -D_REENTRANT -DENV_UNIX -D_7ZIP_LARGE_PAGES -D_7ZIP_ASM  -DEXTERNAL_CODECS -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_REENTRANT -DENV_UNIX -DBREAK_HANDLER -DUNICODE -D_UNICODE -DUNIX_USE_WIN_FILE    -o ../../../../bin/7z -fsanitize=address 7zCrc.o 7zCrcOpt_asm.o  Alloc.o CpuArch.o Threads.o OutStreamWithCRC.o CreateCoder.o FilePathAutoRename.o FileStreams.o FilterCoder.o LimitedStreams.o MethodProps.o ProgressUtils.o PropId.o StreamObjects.o StreamUtils.o UniqBlocks.o CopyCoder.o ArchiveCommandLine.o ArchiveExtractCallback.o ArchiveOpenCallback.o Bench.o DefaultName.o EnumDirItems.o Extract.o ExtractingFilePath.o HashCalc.o LoadCodecs.o OpenArchive.o PropIDUtils.o SetProperties.o SortUtils.o TempFiles.o Update.o UpdateAction.o UpdateCallback.o UpdatePair.o UpdateProduce.o BenchCon.o ConsoleClose.o ExtractCallbackConsole.o HashCon.o List.o Main.o MainAr.o OpenCallbackConsole.o PercentPrinter.o UpdateCallbackConsole.o UserInputUtils.o CRC.o CommandLineParser.o IntToString.o ListFileUtils.o MyString.o MyVector.o MyWindows.o NewHandler.o StdInStream.o StdOutStream.o StringConvert.o StringToInt.o UTFConvert.o Wildcard.o DLL.o ErrorMsg.o FileDir.o FileFind.o FileIO.o FileName.o PropVariant.o PropVariantConv.o System.o TimeUtils.o myAddExeFlag.o mySplitCommandLine.o wine_date_and_time.o  -lpthread -ldl
NewHandler.o: In function `operator delete[](void*)':
../../../../CPP/Common/NewHandler.cpp:(.text+0xe0): multiple definition of `operator delete[](void*)'
/usr/bin/../lib/clang/3.9.0/lib/linux/libclang_rt.asan_cxx-x86_64.a(asan_new_delete.cc.o):/tmp/portage/sys-devel/llvm-3.9.0-r1/work/llvm-3.9.0.src/projects/compiler-rt/lib/asan/asan_new_delete.cc:113: first defined here
NewHandler.o: In function `operator delete(void*)':
../../../../CPP/Common/NewHandler.cpp:(.text+0xa0): multiple definition of `operator delete(void*)'
/usr/bin/../lib/clang/3.9.0/lib/linux/libclang_rt.asan_cxx-x86_64.a(asan_new_delete.cc.o):/tmp/portage/sys-devel/llvm-3.9.0-r1/work/llvm-3.9.0.src/projects/compiler-rt/lib/asan/asan_new_delete.cc:109: first defined here
NewHandler.o: In function `operator new[](unsigned long)':
../../../../CPP/Common/NewHandler.cpp:(.text+0x50): multiple definition of `operator new[](unsigned long)'
/usr/bin/../lib/clang/3.9.0/lib/linux/libclang_rt.asan_cxx-x86_64.a(asan_new_delete.cc.o):/tmp/portage/sys-devel/llvm-3.9.0-r1/work/llvm-3.9.0.src/projects/compiler-rt/lib/asan/asan_new_delete.cc:80: first defined here
NewHandler.o: In function `operator new(unsigned long)':
../../../../CPP/Common/NewHandler.cpp:(.text+0x0): multiple definition of `operator new(unsigned long)'
/usr/bin/../lib/clang/3.9.0/lib/linux/libclang_rt.asan_cxx-x86_64.a(asan_new_delete.cc.o):/tmp/portage/sys-devel/llvm-3.9.0-r1/work/llvm-3.9.0.src/projects/compiler-rt/lib/asan/asan_new_delete.cc:78: first defined here
clang-3.9: error: linker command failed with exit code 1 (use -v to see invocation)
../../../../makefile.glb:26: recipe for target '../../../../bin/7z' failed
make[1]: *** [../../../../bin/7z] Error 1
make[1]: Leaving directory '/tmp/portage/app-arch/p7zip-16.02-r1/work/p7zip_16.02/CPP/7zip/UI/Console'
makefile:50: recipe for target '7z' failed
make: *** [7z] Error 2
 * ERROR: app-arch/p7zip-16.02-r1::gentoo failed (compile phase):
 *   emake failed
Comment 1 Agostino Sarubbo gentoo-dev 2016-11-20 11:41:39 UTC
gcc with asan wfm