summaryrefslogtreecommitdiff
path: root/tools/testing
diff options
context:
space:
mode:
authorShuah Khan <shuah.kh@samsung.com>2014-06-25 05:53:36 +0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-07-12 05:11:18 +0400
commitb80f557042d4742b8c0ed69467d6b87a83186c8d (patch)
tree9d9ba28fadb215c8da8400604d80ef941ff3643c /tools/testing
parentef9feb682dea988f731a2e5a2e8e498aba6a9da7 (diff)
downloadlinux-b80f557042d4742b8c0ed69467d6b87a83186c8d.tar.xz
tools: Fix mqueue Makefile compile linking order
Makefile compile linking order is incorrect causing the compile to fail not finding librt symbols. /tmp/cceTqwFh.o: In function `test_queue_fail': mq_open_tests.c:(.text+0x6b): undefined reference to `mq_open' mq_open_tests.c:(.text+0x80): undefined reference to `mq_getattr' mq_open_tests.c:(.text+0xa2): undefined reference to `mq_close' mq_open_tests.c:(.text+0xcf): undefined reference to `mq_unlink' /tmp/cceTqwFh.o: In function `test_queue.constprop.6': mq_open_tests.c:(.text+0x15a): undefined reference to `mq_open' mq_open_tests.c:(.text+0x16f): undefined reference to `mq_getattr' mq_open_tests.c:(.text+0x195): undefined reference to `mq_close' mq_open_tests.c:(.text+0x1c2): undefined reference to `mq_unlink' /tmp/cceTqwFh.o: In function `shutdown.part.0': mq_open_tests.c:(.text.unlikely+0x5b): undefined reference to `mq_close' mq_open_tests.c:(.text.unlikely+0x7a): undefined reference to `mq_unlink' collect2: error: ld returned 1 exit status make: *** [all] Error 1 Signed-off-by: Shuah Khan <shuah.kh@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools/testing')
-rw-r--r--tools/testing/selftests/mqueue/Makefile4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/testing/selftests/mqueue/Makefile b/tools/testing/selftests/mqueue/Makefile
index 218a122c7951..8056e2e68fa4 100644
--- a/tools/testing/selftests/mqueue/Makefile
+++ b/tools/testing/selftests/mqueue/Makefile
@@ -1,6 +1,6 @@
all:
- gcc -O2 -lrt mq_open_tests.c -o mq_open_tests
- gcc -O2 -lrt -lpthread -lpopt -o mq_perf_tests mq_perf_tests.c
+ gcc -O2 mq_open_tests.c -o mq_open_tests -lrt
+ gcc -O2 -o mq_perf_tests mq_perf_tests.c -lrt -lpthread -lpopt
run_tests:
@./mq_open_tests /test1 || echo "mq_open_tests: [FAIL]"