~ubuntu-branches/ubuntu/natty/suitesparse/natty

« back to all changes in this revision

Viewing changes to debian/patches/06-BTF_Lib_Makefile.dpatch

  • Committer: Bazaar Package Importer
  • Author(s): Rafael Laboissiere, Rafael Laboissiere, Ondrej Certik
  • Date: 2008-02-21 14:46:50 UTC
  • mfrom: (1.1.2 upstream) (5.1.1 hardy)
  • Revision ID: james.westby@ubuntu.com-20080221144650-tgeppgj0t7s759i8
Tags: 3.1.0-3
[ Rafael Laboissiere ]
* Upload to unstable

[ Ondrej Certik ]
* XS-DM-Upload-Allowed: yes field added
* Ondrej Certik added to uploaders

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#! /bin/sh /usr/share/dpatch/dpatch-run
 
2
## 06-BTF_Lib_Makefile.dpatch by Daniel Rus Morales <danirus@tol-project.org>
 
3
##
 
4
## All lines beginning with `## DP:' are a description of the patch.
 
5
## DP: Build shared version of BTF library.
 
6
 
 
7
@DPATCH@
 
8
diff -u upstrm/BTF/Lib/Makefile debsrc/BTF/Lib/Makefile
 
9
--- upstrm/BTF/Lib/Makefile     2007-05-03 22:34:57.000000000 +0200
 
10
+++ debsrc/BTF/Lib/Makefile     2007-12-15 19:05:38.000000000 +0100
 
11
@@ -15,38 +15,55 @@
 
12
 
 
13
 all: library
 
14
 
 
15
-library: libbtf.a
 
16
+library: libbtf.a libbtf.so.3.1.0
 
17
 
 
18
 OBJ = btf_order.o btf_maxtrans.o btf_strongcomp.o \
 
19
     btf_l_order.o btf_l_maxtrans.o btf_l_strongcomp.o
 
20
+OBJ_SL = $(subst .o,.oo,$(OBJ))
 
21
 
 
22
 libbtf.a: $(OBJ)
 
23
        $(AR) libbtf.a $(OBJ)
 
24
        $(RANLIB) libbtf.a
 
25
 
 
26
-$(OBJ): $(INC)
 
27
+libbtf.so.3.1.0: $(OBJ_SL)
 
28
+       $(CC) -shared $^ -lm -Wl,-soname -Wl,$@ -o $@
 
29
+       ln -s $@ libbtf.so
 
30
+
 
31
+$(OBJ) $(OBJ_SL): $(INC)
 
32
 
 
33
 #-------------------------------------------------------------------------------
 
34
 
 
35
 btf_order.o: ../Source/btf_order.c
 
36
        $(C) -c $(I) $< -o $@
 
37
+btf_order.oo: ../Source/btf_order.c
 
38
+       $(C) -fPIC -c $(I) $< -o $@
 
39
 
 
40
 btf_maxtrans.o: ../Source/btf_maxtrans.c
 
41
        $(C) -c $(I) $< -o $@
 
42
+btf_maxtrans.oo: ../Source/btf_maxtrans.c
 
43
+       $(C) -fPIC -c $(I) $< -o $@
 
44
 
 
45
 btf_strongcomp.o: ../Source/btf_strongcomp.c
 
46
        $(C) -c $(I) $< -o $@
 
47
+btf_strongcomp.oo: ../Source/btf_strongcomp.c
 
48
+       $(C) -fPIC -c $(I) $< -o $@
 
49
 
 
50
 #-------------------------------------------------------------------------------
 
51
 
 
52
 btf_l_order.o: ../Source/btf_order.c
 
53
        $(C) -c $(I) -DDLONG $< -o $@
 
54
+btf_l_order.oo: ../Source/btf_order.c
 
55
+       $(C) -fPIC -c $(I) -DDLONG $< -o $@
 
56
 
 
57
 btf_l_maxtrans.o: ../Source/btf_maxtrans.c
 
58
        $(C) -c $(I) -DDLONG $< -o $@
 
59
+btf_l_maxtrans.oo: ../Source/btf_maxtrans.c
 
60
+       $(C) -fPIC -c $(I) -DDLONG $< -o $@
 
61
 
 
62
 btf_l_strongcomp.o: ../Source/btf_strongcomp.c
 
63
        $(C) -c $(I) -DDLONG $< -o $@
 
64
+btf_l_strongcomp.oo: ../Source/btf_strongcomp.c
 
65
+       $(C) -fPIC -c $(I) -DDLONG $< -o $@
 
66
 
 
67
 #-------------------------------------------------------------------------------
 
68
 
 
69
@@ -57,3 +75,6 @@
 
70
 
 
71
 clean:
 
72
        - $(RM) $(CLEAN)
 
73
+       -$(RM) *.oo
 
74
+       -$(RM) *.a
 
75
+       -$(RM) *.so*