aboutsummaryrefslogtreecommitdiffstats
path: root/math/simd-viterbi/files/patch-makefile.in
blob: 221944132a71bcb2a91577afb30e5da93b9f39cc (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
--- makefile.in.orig    Mon Feb  4 18:57:37 2002
+++ makefile.in Tue Nov  7 16:45:09 2006
@@ -5,9 +5,9 @@
 VPATH = @srcdir@
 CC=@CC@
 
-CFLAGS=@CFLAGS@ -I. -Wall @ARCH_OPTION@
+CFLAGS=@CFLAGS@ -I. -Wall -fPIC
 
-SHARED_LIB=libviterbi.so.@VERSION@
+SHARED_LIB=libviterbi.so.2
 STATIC_LIB=@STATIC_LIB@
 
 CLIB=viterbi27port.o viterbi29port.o parity.o
@@ -22,19 +22,18 @@
    ./vtest29
 
 install: all
-   install -m 644 -p $(SHARED_LIB) $(STATIC_LIB) @libdir@
+   $(BSD_INSTALL_DATA) $(STATIC_LIB) @libdir@
+   $(BSD_INSTALL_PROGRAM) $(SHARED_LIB) @libdir@
    (cd @libdir@;ln -f -s $(SHARED_LIB) libviterbi.so)
    (cd @libdir@;ln -f -s $(STATIC_LIB) libviterbi.a)
-   ldconfig
-   install -m 644 -p parity.h viterbi27.h viterbi29.h @includedir@
-   mkdir -m 0755 -p @mandir@/man3
-   install -m 644 -p simd-viterbi.3 @mandir@/man3
+   $(BSD_INSTALL_DATA) parity.h viterbi27.h viterbi29.h @includedir@
+   $(BSD_INSTALL_MAN) simd-viterbi.3 @mandir@/man3
 
 vtest27: vtest27.o $(STATIC_LIB)
-   gcc -g -o $@ $^
+   cc -g -o $@ $^
 
 vtest29: vtest29.o $(STATIC_LIB)
-   gcc -g -o $@ $^
+   cc -g -o $@ $^
 
 vtest27.o: vtest27.c viterbi27.h parity.h
 
@@ -53,31 +52,31 @@
    ar rv $@ $^
 
 $(SHARED_LIB): $(STATIC_LIB)
-   gcc -shared -Xlinker -soname=libviterbi.so.@SO_NAME@ -o $@ -Wl,-whole-archive $^ -Wl,-no-whole-archive -lc
+   cc -shared -fPIC -Xlinker -soname=libviterbi.so.@SO_NAME@ -o $@ -Wl,-whole-archive $^ -Wl,-no-whole-archive -lc
 
 viterbi27port.o: viterbi27.c viterbi27.h parity.h
-   gcc -c $(CFLAGS) -o $@ $<
+   cc -c $(CFLAGS) -o $@ $<
 
 viterbi27mmx.o: viterbi27.c viterbi27.h parity.h
-   gcc -c $(CFLAGS) -DMMX=1 -o $@ $<
+   cc -c $(CFLAGS) -DMMX=1 -o $@ $<
 
 viterbi27sse.o: viterbi27.c viterbi27.h parity.h
-   gcc -c $(CFLAGS) -DSSE=1 -o $@ $<
+   cc -c $(CFLAGS) -DSSE=1 -o $@ $<
 
 viterbi27sse2.o: viterbi27.c viterbi27.h parity.h
-   gcc -c $(CFLAGS) -DSSE2=1 -o $@ $<
+   cc -c $(CFLAGS) -DSSE2=1 -o $@ $<
 
 viterbi29port.o: viterbi29.c viterbi29.h parity.h
-   gcc -c $(CFLAGS) -o $@ $<
+   cc -c $(CFLAGS) -o $@ $<
 
 viterbi29mmx.o: viterbi29.c viterbi29.h parity.h
-   gcc -c $(CFLAGS) -DMMX=1 -o $@ $<
+   cc -c $(CFLAGS) -DMMX=1 -o $@ $<
 
 viterbi29sse.o: viterbi29.c viterbi29.h parity.h
-   gcc -c $(CFLAGS) -DSSE=1 -o $@ $<
+   cc -c $(CFLAGS) -DSSE=1 -o $@ $<
 
 viterbi29sse2.o: viterbi29.c viterbi29.h parity.h
-   gcc -c $(CFLAGS) -DSSE2=1 -o $@ $<
+   cc -c $(CFLAGS) -DSSE2=1 -o $@ $<
 
 clean:
    rm -f *.o $(SHARED_LIB) *.a vtest27 vtest29 core