diff options
author | Bernhard Voelker <mail@bernhard-voelker.de> | 2012-02-27 21:13:10 +0100 |
---|---|---|
committer | Jim Meyering <meyering@redhat.com> | 2012-02-29 10:01:50 +0100 |
commit | 409a7cc7ea877399d10ff15d875c68bd5edc3288 (patch) | |
tree | 8de8f50d446d4550f625647dbe7948a53688351d /tests | |
parent | 4e776faa8482ae630d2ea9bc767298e664f07ba9 (diff) | |
download | coreutils-409a7cc7ea877399d10ff15d875c68bd5edc3288.tar.xz |
tests: compile and link shared object with $CC to make LD_PRELOAD work
* tests/ls/getxattr-speedup: Compile and link in one step with $CC.
If the shared object file is created by ld (binutils), then the
destructor print_call_count() may not run (seen on OpenSuSE 12.1).
See http://lists.opensuse.org/opensuse/2012-02/msg01342.html
Thanks to Cristian RodrÃguez.
Diffstat (limited to 'tests')
-rwxr-xr-x | tests/ls/getxattr-speedup | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/ls/getxattr-speedup b/tests/ls/getxattr-speedup index d32e24abb..967f7c95f 100755 --- a/tests/ls/getxattr-speedup +++ b/tests/ls/getxattr-speedup @@ -47,8 +47,8 @@ ssize_t lgetxattr(const char *path, const char *name, void *value, size_t size) EOF # Then compile/link it: -$CC -fPIC -O2 -c k.c || framework_failure_ 'failed to compile with -fPIC' -ld -G k.o -o k.so || framework_failure_ 'failed to invoke ld -G ...' +$CC -shared -fPIC -O2 k.c -o k.so \ + || framework_failure_ 'failed to compile with -shared -fPIC' # Create a few files: seq 20 | xargs touch || framework_failure_ |