]> git.pld-linux.org Git - packages/COLAMD.git/blob - colamd-shared.patch
- fix SuiteSparse_config BR
[packages/COLAMD.git] / colamd-shared.patch
1 --- COLAMD/Demo/Makefile.orig   2014-10-01 21:32:41.549424470 +0200
2 +++ COLAMD/Demo/Makefile        2014-10-02 17:21:56.629763313 +0200
3 @@ -23,12 +23,12 @@
4  dist:
5  
6  colamd_example: colamd_example.c library
7 -       $(C) -o colamd_example colamd_example.c ../Lib/libcolamd.a $(LIB2)
8 +       libtool --tag=CC --mode=link $(C) $(LDFLAGS) -o colamd_example colamd_example.c ../Lib/libcolamd.la $(LIB2)
9         - ./colamd_example > my_colamd_example.out
10         - diff colamd_example.out my_colamd_example.out
11  
12  colamd_l_example: colamd_l_example.c library
13 -       $(C) -o colamd_l_example colamd_l_example.c ../Lib/libcolamd.a $(LIB2)
14 +       libtool --tag=CC --mode=link $(C) $(LDFLAGS) -o colamd_l_example colamd_l_example.c ../Lib/libcolamd.la $(LIB2)
15         - ./colamd_l_example > my_colamd_l_example.out
16         - diff colamd_l_example.out my_colamd_l_example.out
17  
18 --- COLAMD/Lib/Makefile.orig    2014-10-02 17:24:27.669756976 +0200
19 +++ COLAMD/Lib/Makefile 2014-10-02 18:14:05.969631988 +0200
20 @@ -2,7 +2,8 @@
21  # COLAMD Makefile
22  #-------------------------------------------------------------------------------
23  
24 -default: libcolamd.a
25 +default: libcolamd.la
26 +libdir := /usr/lib
27  
28  include /usr/share/misc/SuiteSparse_config.mk
29  
30 @@ -13,15 +14,18 @@
31  SRC = ../Source/colamd.c
32  
33  # creates libcolamd.a, a C-callable COLAMD library
34 -libcolamd.a:  $(SRC) $(INC)
35 -       $(CC) $(CF) $(I) -c ../Source/colamd.c
36 -       $(CC) $(CF) $(I) -c ../Source/colamd.c -DDLONG -o colamd_l.o
37 -       $(ARCHIVE)  libcolamd.a colamd.o colamd_l.o
38 -       - $(RANLIB) libcolamd.a
39 +libcolamd.la:  $(SRC) $(INC)
40 +       libtool --tag=CC --mode=compile $(CC) $(CF) $(I) -c ../Source/colamd.c
41 +       libtool --tag=CC --mode=compile $(CC) $(CF) $(I) -c ../Source/colamd.c -DDLONG -o colamd_l.o
42 +       libtool --tag=CC --mode=link $(CC) $(LDFLAGS) $(CFLAGS) -o libcolamd.la -rpath $(libdir) colamd.lo colamd_l.lo -lsuitesparseconfig -lm
43 +
44 +install: libcolamd.la
45 +       install -d $(DESTDIR)$(libdir)
46 +       libtool --mode=install install libcolamd.la $(DESTDIR)$(libdir)
47
48 +ccode: libcolamd.la
49  
50 -ccode: libcolamd.a
51 -
52 -library: libcolamd.a
53 +library: libcolamd.la
54  
55  clean:
56         - $(RM) $(CLEAN)
57 @@ -29,4 +33,4 @@
58  purge: distclean
59  
60  distclean: clean
61 -       - $(RM) libcolamd.a
62 +       - $(RM) libcolamd.la
This page took 0.04741 seconds and 3 git commands to generate.