[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [PATCH 4 of 4] tools: support building with --as-needed



# HG changeset patch
# User Ian Campbell <ian.campbell@xxxxxxxxxx>
# Date 1300205703 0
# Node ID ec906d89bd42120407bb53d28d31079162b37286
# Parent  4446ee65519b4fcd894b08cf091c5aed935d0e74
tools: support building with --as-needed

Tested by forcing --as-needed via tools/Rules.mk but this is included
since the intention is simply to support diustros which default to
--as-needed, not to enable it everywhere.

Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx>

diff -r 4446ee65519b -r ec906d89bd42 tools/Rules.mk
--- a/tools/Rules.mk    Tue Mar 15 16:10:33 2011 +0000
+++ b/tools/Rules.mk    Tue Mar 15 16:15:03 2011 +0000
@@ -65,9 +65,6 @@ LDFLAGS += $(shell getconf LFS_LDFLAGS)
 LDFLAGS += $(shell getconf LFS_LDFLAGS)
 endif
 
-# Xen tools build is currently incompatible with ld --as-needed
-LDFLAGS += -Wl,--no-as-needed
-
 # 32-bit x86 does not perform well with -ve segment accesses on Xen.
 CFLAGS-$(CONFIG_X86_32) += $(call cc-option,$(CC),-mno-tls-direct-seg-refs)
 CFLAGS += $(CFLAGS-y)
diff -r 4446ee65519b -r ec906d89bd42 tools/blktap2/vhd/lib/Makefile
--- a/tools/blktap2/vhd/lib/Makefile    Tue Mar 15 16:10:33 2011 +0000
+++ b/tools/blktap2/vhd/lib/Makefile    Tue Mar 15 16:15:03 2011 +0000
@@ -57,7 +57,7 @@ build: $(LIBVHD-BUILD)
 
 libvhd.a: $(LIB-OBJS)
        $(CC) $(CFLAGS) -Wl,$(SONAME_LDFLAG),$(LIBVHD-SONAME) $(SHLIB_LDFLAGS) \
-               $(LDFLAGS) -o libvhd.so.$(LIBVHD-MAJOR).$(LIBVHD-MINOR) $(LIBS) 
$^
+               $(LDFLAGS) -o libvhd.so.$(LIBVHD-MAJOR).$(LIBVHD-MINOR) $^ 
$(LIBS)
        ln -sf libvhd.so.$(LIBVHD-MAJOR).$(LIBVHD-MINOR) 
libvhd.so.$(LIBVHD-MAJOR)
        ln -sf libvhd.so.$(LIBVHD-MAJOR) libvhd.so
        $(AR) rc $@ $^
diff -r 4446ee65519b -r ec906d89bd42 tools/libxc/Makefile
--- a/tools/libxc/Makefile      Tue Mar 15 16:10:33 2011 +0000
+++ b/tools/libxc/Makefile      Tue Mar 15 16:15:03 2011 +0000
@@ -159,7 +159,7 @@ libxenctrl.so.$(MAJOR): libxenctrl.so.$(
        ln -sf $< $@
 
 libxenctrl.so.$(MAJOR).$(MINOR): $(CTRL_PIC_OBJS)
-       $(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) 
-Wl,libxenctrl.so.$(MAJOR) $(DLOPEN_LIBS) $(SHLIB_LDFLAGS) -o $@ $^ 
$(PTHREAD_LIBS)
+       $(CC) $(CFLAGS) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) 
-Wl,libxenctrl.so.$(MAJOR) $(SHLIB_LDFLAGS) -o $@ $^ $(DLOPEN_LIBS) 
$(PTHREAD_LIBS)
 
 # libxenguest
 

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.