summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Sterba <dsterba@suse.com>2016-11-30 12:34:17 +0100
committerDavid Sterba <dsterba@suse.com>2016-11-30 12:42:27 +0100
commit18b1364e68d155a842fc7b054a4d1e916c69e40a (patch)
tree7ee590e64125306a9607afe823fc537ab4b1776b
parent9d133083aade130f34f6ebde4252d1b7c0b86a6e (diff)
btrfs-progs: tests: add correct rpath to library-test
Our library-test dynamically linked binary was not using the built libbtrfs. To fix that, use -rpath. Reported-by: Mike Gilbert <floppymaster@gmail.com> Signed-off-by: David Sterba <dsterba@suse.com>
-rw-r--r--Makefile.in2
1 files changed, 1 insertions, 1 deletions
diff --git a/Makefile.in b/Makefile.in
index 240df7a0..6a6652c5 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -445,7 +445,7 @@ test-ioctl: ioctl-test ioctl-test-32 ioctl-test-64
library-test: $(libs_shared) library-test.o
@echo " [LD] $@"
- $(Q)$(CC) $(CFLAGS) -o library-test library-test.o $(LDFLAGS) -lbtrfs
+ $(Q)$(CC) $(CFLAGS) -o library-test library-test.o $(LDFLAGS) -Wl,-rpath=$(TOPDIR) -lbtrfs
@echo " [TEST] $@"
$(Q)./$@