[Bug 610992] Re: clang -fstack-protector fails to link (undefined reference to `__stack_chk_guard')

Anders Kaseorg andersk at mit.edu
Mon Aug 16 18:08:43 BST 2010


test/CodeGen/Generic/stack-protector.ll was supposed to have been
deleted.  The problem is that the ‘diffstats’ target in
debian/rules.d/control.mk, which is run on debian/rules clean, corrupted
the patch in such a way that it truncates this file instead of deleting
it.  (It also stripped my DEP-3 headers.)

This disables the ‘diffstats’ target to avoid corrupting the patches.

** Patch added: "llvm-2.7_2.7-3ubuntu2_lp610992.debdiff"
   https://bugs.launchpad.net/ubuntu/+source/llvm-2.7/+bug/610992/+attachment/1493674/+files/llvm-2.7_2.7-3ubuntu2_lp610992.debdiff

-- 
clang -fstack-protector fails to link (undefined reference to `__stack_chk_guard')
https://bugs.launchpad.net/bugs/610992
You received this bug notification because you are a member of Ubuntu
Sponsors Team, which is a direct subscriber.

Status in The Low Level Virtual Machine Compiler Infrastructure: Unknown
Status in “llvm-2.7” package in Ubuntu: New
Status in “llvm-2.7” package in Debian: Unknown

Bug description:
Binary package hint: clang

$ echo 'int main(){char s[80];}' > test.c
$ gcc -fstack-protector test.c -o test
$ ./test
$ clang -fstack-protector test.c -o test
/usr/bin/ld: /tmp/cc-0Rbhby.o: in function main:test.c(.text+0xc): error: undefined reference to '__stack_chk_guard'
/usr/bin/ld: /tmp/cc-0Rbhby.o: in function main:test.c(.text+0x22): error: undefined reference to '__stack_chk_guard'
collect2: ld returned 1 exit status
clang: error: linker command failed with exit code 1 (use -v to see invocation)





More information about the Ubuntu-sponsors mailing list