File: Makefile

package info (click to toggle)
lintian 2.5.50.4
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 18,268 kB
  • ctags: 1,873
  • sloc: perl: 30,993; sh: 6,133; makefile: 3,443; xml: 1,805; ansic: 568; python: 65; cpp: 9; java: 9; tcl: 4
file content (23 lines) | stat: -rw-r--r-- 502 bytes parent folder | download | duplicates (11)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
CC=gcc
CFLAGS+= -fPIC

SONAMES:= libnoshf.so.1 libeshf.so.1 libunshf.so.1 libfdshf.so.1 \
	  libdupshf.so.1
LIBFILES:= $(patsubst %,%.0.1, $(SONAMES))

all: $(LIBFILES)

$(LIBFILES): code.o
	$(CC) $(LDFLAGS) -o $@ -shared -Wl,-soname,$(patsubst %.0.1,%,$@) $^ -lc

clean:
	rm -f *.a *.o *.so*

install: all
	install -m 0755 -d $(DESTDIR)/usr/lib
	install -m 0644 *.so* $(DESTDIR)/usr/lib
	for FILE in $(SONAMES) ; do \
	    ln -s $${FILE}.0.1 $(DESTDIR)/usr/lib/$$FILE ; \
	done

.PHONY: install clean