59 lines
1.3 KiB
Makefile
59 lines
1.3 KiB
Makefile
# ldnssec-utils
|
|
#
|
|
# Written in 2021 by Lucas
|
|
#
|
|
# To the extent possible under law, the author(s) have dedicated all
|
|
# copyright and related and neighboring rights to this software to the
|
|
# public domain worldwide. This software is distributed without any
|
|
# warranty.
|
|
#
|
|
# You should have received a copy of the CC0 Public Domain Dedication
|
|
# along with this software. If not, see
|
|
# <http://creativecommons.org/publicdomain/zero/1.0/>.
|
|
.POSIX:
|
|
.SUFFIXES:
|
|
.SUFFIXES: .o .c
|
|
|
|
P = ldnssec-utils
|
|
V = 0.0
|
|
|
|
LIBHDR = util.h
|
|
LIBOBJ = util.o
|
|
|
|
BIN = ldnssec-keygen ldnssec-sign-dnskey
|
|
BINEX = ex-print-zone
|
|
OBJ = ${BIN:=.o} ${BINEX:=.o} ${LIBOBJ}
|
|
SRC = ${OBJ:.o=.c}
|
|
DIST = COPYING Makefile ${LIBHDR} ${SRC}
|
|
|
|
LDNS_INCS = -I/usr/local/include
|
|
LDNS_LIBS = -L/usr/local/lib -lldns
|
|
|
|
.o:
|
|
${CC} ${LDFLAGS} -o $@ $@.o ${LIBOBJ} ${LDNS_LIBS}
|
|
|
|
.c.o:
|
|
${CC} ${CFLAGS} ${LDNS_INCS} -c $<
|
|
|
|
all: ${BINEX} ${BIN}
|
|
|
|
clean:
|
|
rm -f ${BIN} ${BINEX} ${OBJ} ${P}-${V}.tgz
|
|
|
|
dist: clean
|
|
pax -ws ',^,${P}-${V}/,' ${DIST} | gzip >${P}-${V}.tgz
|
|
|
|
install: all
|
|
mkdir -p ${PREFIX}/bin
|
|
cp -f ${BIN} ${PREFIX}/bin
|
|
cd ${PREFIX}/bin && chmod 555 ${BIN}
|
|
|
|
uninstall:
|
|
cd ${PREFIX}/bin && rm -f ${BIN}
|
|
|
|
util.o: util.h
|
|
|
|
ldnssec-keygen: ldnssec-keygen.o ${LIBOBJ}
|
|
ldnssec-sign-dnskey: ldnssec-sign-dnskey.o ${LIBOBJ}
|
|
ex-print-zone: ex-print-zone.o ${LIBOBJ}
|