]> git.pld-linux.org Git - packages/CAMD.git/blob - CAMD-shared.patch
- fix SuiteSparse_config BR
[packages/CAMD.git] / CAMD-shared.patch
1 --- CAMD/Demo/Makefile.orig     2014-10-01 20:15:40.452951732 +0200
2 +++ CAMD/Demo/Makefile  2014-10-01 20:40:07.992890145 +0200
3 @@ -22,22 +22,22 @@
4  dist:
5  
6  camd_demo: camd_demo.c library $(INC)
7 -       $(C) -o camd_demo camd_demo.c ../Lib/libcamd.a $(LIB2)
8 +       libtool --tag=CC --mode=link $(CC) $(LDFLAGS) $(CFLAGS) -I../Include -o camd_demo camd_demo.c ../Lib/libcamd.la $(LIB2)
9         ./camd_demo > my_camd_demo.out
10         - diff camd_demo.out my_camd_demo.out
11  
12  camd_l_demo: camd_l_demo.c library $(INC)
13 -       $(C) -o camd_l_demo camd_l_demo.c ../Lib/libcamd.a $(LIB2)
14 +       libtool --tag=CC --mode=link $(CC) $(LDFLAGS) $(CFLAGS) -I../Include -o camd_l_demo camd_l_demo.c ../Lib/libcamd.la $(LIB2)
15         ./camd_l_demo > my_camd_l_demo.out
16         - diff camd_l_demo.out my_camd_l_demo.out
17  
18  camd_demo2: camd_demo2.c library $(INC)
19 -       $(C) -o camd_demo2 camd_demo2.c ../Lib/libcamd.a $(LIB2)
20 +       libtool --tag=CC --mode=link $(CC) $(LDFLAGS) $(CFLAGS) -I../Include -o camd_demo2 camd_demo2.c ../Lib/libcamd.la $(LIB2)
21         ./camd_demo2 > my_camd_demo2.out
22         - diff camd_demo2.out my_camd_demo2.out
23  
24  camd_simple: camd_simple.c library $(INC)
25 -       $(C) -o camd_simple camd_simple.c ../Lib/libcamd.a $(LIB2)
26 +       libtool --tag=CC --mode=link $(CC) $(LDFLAGS) $(CFLAGS) -I../Include -o camd_simple camd_simple.c ../Lib/libcamd.la $(LIB2)
27         ./camd_simple > my_camd_simple.out
28         - diff camd_simple.out my_camd_simple.out
29  
30 --- CAMD/Lib/GNUmakefile.orig   2014-10-01 20:15:40.442951733 +0200
31 +++ CAMD/Lib/GNUmakefile        2014-10-01 20:41:30.242886694 +0200
32 @@ -2,7 +2,7 @@
33  # CAMD Makefile for compiling on Unix systems (for GNU make only)
34  #-------------------------------------------------------------------------------
35  
36 -default: libcamd.a
37 +default: libcamd.la
38  
39  include /usr/share/misc/SuiteSparse_config.mk
40  
41 @@ -29,18 +29,21 @@
42  #-------------------------------------------------------------------------------
43  
44  camd_i_%.o: ../Source/camd_%.c $(INC)
45 -       $(C) -DDINT -c $< -o $@
46 +       libtool --tag=CC --mode=compile $(C) -DDINT -c $< -o $@
47  
48  camd_l_%.o: ../Source/camd_%.c $(INC)
49 -       $(C) -DDLONG -c $< -o $@
50 +       libtool --tag=CC --mode=compile $(C) -DDLONG -c $< -o $@
51  
52  #-------------------------------------------------------------------------------
53  # Create the libcamd.a library (C versions only)
54  #-------------------------------------------------------------------------------
55  
56 -libcamd.a: $(CAMDI) $(CAMDL)
57 -       $(ARCHIVE)  libcamd.a $^
58 -       - $(RANLIB) libcamd.a
59 +libcamd.la: $(CAMDI) $(CAMDL)
60 +       libtool --tag=CC --mode=link $(CC) $(LDFLAGS) -o libcamd.la -rpath $(libdir) $(^:.o=.lo) -lsuitesparseconfig -lm
61 +
62 +install: libcamd.la
63 +       install -d $(DESTDIR)$(libdir)
64 +       libtool --mode=install install libcamd.la $(DESTDIR)$(libdir)
65  
66  #-------------------------------------------------------------------------------
67  # Remove all but the files in the original distribution
68 @@ -52,4 +55,4 @@
69  purge: distclean
70  
71  distclean: clean
72 -       - $(RM) libcamd.a
73 +       - $(RM) libcamd.la
This page took 0.064859 seconds and 4 git commands to generate.