lib.mk 832 Bytes
Newer Older
Kurt Zeilenga's avatar
Kurt Zeilenga committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
##---------------------------------------------------------------------------
##
## Makefile Template for Libraries
##

all-common: $(LIBRARY) $(PROGRAMS)

version.c: $(OBJS) $(srcdir)/Version.c
	$(RM) $@
	(u=$${USER-root} v=`$(CAT) $(VERSIONFILE)` d=`$(PWD)` \
	h=`$(HOSTNAME)` t=`$(DATE)`; $(SED) -e "s|%WHEN%|$${t}|" \
	-e "s|%WHOANDWHERE%|$${u}@$${h}:$${d}|" \
	-e "s|%VERSION%|$${v}|" \
	< $(srcdir)/Version.c > $@)

16
install-common: FORCE
Kurt Zeilenga's avatar
Kurt Zeilenga committed
17
18
19
20
21
22
23

lint: lint-local FORCE
	$(LINT) $(DEFS) $(DEFINES) $(SRCS)

lint5: lint5-local FORCE
	$(5LINT) $(DEFS) $(DEFINES) $(SRCS)

24
clean-common: 	FORCE
Kurt Zeilenga's avatar
Kurt Zeilenga committed
25
	$(RM) $(LIBRARY) ../$(LIBRARY) $(PROGRAMS) $(XPROGRAMS) $(XSRCS) \
26
		*.o a.out core version.c *.lo .libs/*
Kurt Zeilenga's avatar
Kurt Zeilenga committed
27

28
depend-common: FORCE
Kurt Zeilenga's avatar
Kurt Zeilenga committed
29
30
31
32
33
34
	$(MKDEP) $(DEFS) $(DEFINES) $(SRCS)

lint-local: FORCE
lint5-local: FORCE

Makefile: $(top_srcdir)/build/lib.mk