1# Copyright Internet Systems Consortium, Inc. ("ISC")
2#
3# This Source Code Form is subject to the terms of the Mozilla Public
4# License, v. 2.0. If a copy of the MPL was not distributed with this
5# file, you can obtain one at https://mozilla.org/MPL/2.0/.
6
7# Copyright (C) Stichting NLnet, Netherlands, stichting@nlnet.nl.
8#
9# The development of Dynamically Loadable Zones (DLZ) for Bind 9 was
10# conceived and contributed by Rob Butler.
11#
12# SPDX-License-Identifier: ISC and MPL-2.0
13#
14# Permission to use, copy, modify, and distribute this software for any purpose
15# with or without fee is hereby granted, provided that the above copyright
16# notice and this permission notice appear in all copies.
17#
18# THE SOFTWARE IS PROVIDED "AS IS" AND STICHTING NLNET DISCLAIMS ALL WARRANTIES
19# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
20# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL STICHTING NLNET BE LIABLE FOR
21# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
22# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
23# OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
24# CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
25
26prefix = /usr
27libdir = $(prefix)/lib/bind9
28
29CFLAGS += -fPIC -g -I../include
30
31all: dlz_filesystem_dynamic.so
32
33dir.o: dir.c
34	$(CC) $(CFLAGS) -c dir.c
35
36dlz_filesystem_dynamic.so: dlz_filesystem_dynamic.c dir.o
37	$(CC) $(CFLAGS) -shared -o dlz_filesystem_dynamic.so \
38		dlz_filesystem_dynamic.c dir.o
39
40clean:
41	rm -f dlz_filesystem_dynamic.so *.o
42
43install: dlz_filesystem_dynamic.so
44	mkdir -p $(DESTDIR)$(libdir)
45	install dlz_filesystem_dynamic.so $(DESTDIR)$(libdir)
46