xref: /netbsd-src/external/bsd/openldap/dist/build/lib.mk (revision e670fd5c413e99c2f6a37901bb21c537fcd322d2)
1# $OpenLDAP$
2## This work is part of OpenLDAP Software <http://www.openldap.org/>.
3##
4## Copyright 1998-2021 The OpenLDAP Foundation.
5## All rights reserved.
6##
7## Redistribution and use in source and binary forms, with or without
8## modification, are permitted only as authorized by the OpenLDAP
9## Public License.
10##
11## A copy of this license is available in the file LICENSE in the
12## top-level directory of the distribution or, alternatively, at
13## <http://www.OpenLDAP.org/license.html>.
14##---------------------------------------------------------------------------
15#
16# Makefile Template for Libraries
17#
18
19all-common: $(LIBRARY) $(PROGRAMS)
20
21version.c: Makefile
22	$(RM) $@
23	$(MKVERSION) $(LIBRARY) > $@
24
25version.o version.lo: version.c $(OBJS)
26
27install-common: FORCE
28
29lint: lint-local FORCE
30	$(LINT) $(DEFS) $(DEFINES) $(SRCS)
31
32lint5: lint5-local FORCE
33	$(5LINT) $(DEFS) $(DEFINES) $(SRCS)
34
35#
36# In the mingw/cygwin environment, the so and dll files must be
37# deleted separately, instead of using the {.so*,*.dll} construct
38# that was previously used. It just didn't work.
39#
40clean-common: 	FORCE
41	$(RM) $(LIBRARY) ../$(LIBRARY) $(XLIBRARY) \
42		$(PROGRAMS) $(XPROGRAMS) $(XSRCS) $(XXSRCS) \
43		*.o *.lo a.out *.exe *.pc core version.c .libs/*
44
45depend-common: FORCE
46	$(MKDEP) $(DEFS) $(DEFINES) $(SRCS) $(XXSRCS)
47
48lint-local: FORCE
49lint5-local: FORCE
50
51Makefile: $(top_srcdir)/build/lib.mk
52
53