All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] blktap: correct order of linker options to avoid link errors with recent toolchains
@ 2010-07-28 12:54 Olaf Hering
  0 siblings, 0 replies; only message in thread
From: Olaf Hering @ 2010-07-28 12:54 UTC (permalink / raw)
  To: xen-devel


Fix link error in openSuSE 11.2. 
The order of objects and linked libraries is important with recent toolchain
when --as-needed is used.

../../memshr/libmemshr.a(interface.o): In function `memshr_vbd_issue_ro_request':
/usr/src/packages/BUILD/xen-unstable.hg-4.1.21864/tools/memshr/interface.c:165: undefined reference to `xc_memshr_nominate_gref'
/usr/src/packages/BUILD/xen-unstable.hg-4.1.21864/tools/memshr/interface.c:179: undefined reference to `xc_memshr_share'
../../memshr/libmemshr.a(interface.o): In function `memshr_vbd_initialize':
/usr/src/packages/BUILD/xen-unstable.hg-4.1.21864/tools/memshr/interface.c:116: undefined reference to `xc_interface_open'
collect2: ld returned 1 exit status
make[5]: *** [blktapctrl] Error 1

Signed-off-by: Olaf Hering <olaf@aepfle.de>

---
 tools/blktap/drivers/Makefile |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- xen-unstable.hg-4.1.21864.orig/tools/blktap/drivers/Makefile
+++ xen-unstable.hg-4.1.21864/tools/blktap/drivers/Makefile
@@ -29,7 +29,7 @@ CFLAGS += -DMEMSHR
 MEMSHRLIBS += $(MEMSHR_DIR)/libmemshr.a
 endif
 
-LDFLAGS_blktapctrl := $(LDFLAGS_libxenctrl) $(LDFLAGS_libxenstore) $(MEMSHRLIBS) -L../lib -lblktap -lrt -lm -lpthread
+LDFLAGS_blktapctrl := $(MEMSHRLIBS) $(LDFLAGS_libxenctrl) $(LDFLAGS_libxenstore) -L../lib -lblktap -lrt -lm -lpthread
 LDFLAGS_img := $(LIBAIO_DIR)/libaio.a $(CRYPT_LIB) -lpthread -lz
 
 BLK-OBJS-y  := block-aio.o

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2010-07-28 12:54 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-07-28 12:54 [PATCH] blktap: correct order of linker options to avoid link errors with recent toolchains Olaf Hering

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.