summarylogtreecommitdiffstats
path: root/makefile.shared.mt
blob: 4d8e8d6f3333f3cfd8f4d4a74b942df6a2d3ad5f (plain)
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
include Make.inc

all: libatlas.so libf77blas.so libptf77blas.so libstcblas.so libptcblas.so \
   libblas.so libcblas.so liblapack.so.3.4.1 libptlapack.so.3.4.1 liblapack.so.3


libatlas.so: libatlas.a
	ld $(LDFLAGS) -shared -soname $@ -o $@ --whole-archive libatlas.a \
	   --no-whole-archive -lc $(LIBS)

libf77blas.so : libf77blas.a libatlas.so
	ld $(LDFLAGS) -shared -soname libf77blas.so.3 -o $@ --whole-archive \
	   libf77blas.a --no-whole-archive $(F77SYSLIB) -L. -latlas

libptf77blas.so : libptf77blas.a libatlas.so
	ld $(LDFLAGS) -shared -soname libblas.so.3 -o $@ --whole-archive \
	   libptf77blas.a --no-whole-archive $(F77SYSLIB) -L. -latlas

libstcblas.so : libcblas.a libatlas.so
	ld $(LDFLAGS) -shared -soname libstcblas.so -o $@ --whole-archive \
	   libcblas.a -L. -latlas

libptcblas.so : libptcblas.a libatlas.so
	ld $(LDFLAGS) -shared -soname libcblas.so -o $@ --whole-archive \
	   libptcblas.a -L. -latlas

libblas.so: libptf77blas.so
	ln -s $< $@

libcblas.so: libptcblas.so
	ln -s $< $@

liblapack.so.3.4.1 : liblapack.a libstcblas.so libf77blas.so
	ld $(LDFLAGS) -shared -soname libstlapack.so.3 -o $@ --whole-archive \
	   liblapack.a --no-whole-archive $(F77SYSLIB) -L. -lstcblas -lf77blas -lgcc_s

libptlapack.so.3.4.1 : libptlapack.a libcblas.so libblas.so
	ld $(LDFLAGS) -shared -soname liblapack.so.3 -o $@ --whole-archive \
	   libptlapack.a --no-whole-archive $(F77SYSLIB) -L. -lcblas -lblas -lgcc_s

liblapack.so.3: libptlapack.so.3.4.1
	ln -s $< $@