]> git.pld-linux.org Git - packages/xen.git/blob - xen-xenstore-version.patch
- use functions
[packages/xen.git] / xen-xenstore-version.patch
1 # HG changeset patch
2 # User kfraser@localhost.localdomain
3 # Node ID d71e72d8532cfdf5896f560d98d45262841c8b83
4 # Parent  7dfc65c380352627c1501fd34bdb1139bee3f3b4
5 Add versioning info to xenstore library.
6 From: Mark McLoughlin <markmc@redhat.com>
7 Signed-off-by: Keir Fraser <keir@xensource.com>
8
9 diff -burN xen-3.0.2.orig/tools/xenstore/Makefile xen-3.0.2/tools/xenstore/Makefile
10 --- xen-3.0.2.orig/tools/xenstore/Makefile      2006-07-26 15:50:33.550208000 +0200
11 +++ xen-3.0.2/tools/xenstore/Makefile   2006-07-26 15:54:26.068739500 +0200
12 @@ -2,6 +2,9 @@
13  include $(XEN_ROOT)/tools/Rules.mk
14  XEN_LIBXC          = $(XEN_ROOT)/tools/libxc
15  
16 +MAJOR = 3.0
17 +MINOR = 0
18 +
19  INSTALL         = install
20  INSTALL_DATA   = $(INSTALL) -m0644
21  INSTALL_PROG    = $(INSTALL) -m0755
22 @@ -77,11 +80,20 @@
23  talloc_test.o: talloc.c
24         $(COMPILE.c) -o $@ $<
25  
26 -libxenstore.so: xs.opic xs_lib.opic
27 -       $(CC) $(CFLAGS) $(LDFLAGS) -Wl,-soname -Wl,libxenstore.so -shared -o $@ $^ -lpthread
28 +libxenstore.so: libxenstore.so.$(MAJOR)
29 +       ln -sf $< $@
30 +
31 +libxenstore.so.$(MAJOR): libxenstore.so.$(MAJOR).$(MINOR)
32 +       ln -sf $< $@
33 +
34 +libxenstore.so.$(MAJOR).$(MINOR): xs.opic xs_lib.opic
35 +       $(CC) $(CFLAGS) $(LDFLAGS) -Wl,-soname -Wl,libxenstore.so.$(MAJOR) -shared -o $@ $^ -lpthread
36 +
37 +libxenstore.a: xs.o xs_lib.o
38 +       ar rcs libxenstore.a $^
39  
40  clean: testsuite-clean
41 -       rm -f *.o *.opic *.so
42 +       rm -f *.o *.opic *.so*
43         rm -f xenstored xs_random xs_stress xs_crashme
44         rm -f xs_test xenstored_test xs_tdb_dump xenstore-control xenstore-ls
45         rm -f $(CLIENTS)
46 @@ -147,7 +159,9 @@
47         $(INSTALL_PROG) xenstore-control $(DESTDIR)/usr/bin
48         $(INSTALL_PROG) xenstore-ls $(DESTDIR)/usr/bin
49         $(INSTALL_DIR) -p $(DESTDIR)/usr/$(LIBDIR)
50 -       $(INSTALL_DATA) libxenstore.so $(DESTDIR)/usr/$(LIBDIR)
51 +       $(INSTALL_DATA) libxenstore.so.$(MAJOR).$(MINOR) $(DESTDIR)/usr/$(LIBDIR)
52 +       ln -sf libxenstore.so.$(MAJOR).$(MINOR) $(DESTDIR)/usr/$(LIBDIR)/libxenstore.so.$(MAJOR)
53 +       ln -sf libxenstore.so.$(MAJOR) $(DESTDIR)/usr/$(LIBDIR)/libxenstore.so
54         $(INSTALL_DATA) xs.h $(DESTDIR)/usr/include
55         $(INSTALL_DATA) xs_lib.h $(DESTDIR)/usr/include
56  
This page took 0.671865 seconds and 3 git commands to generate.