pax: workaround for mkstemp() and long filenames
[minix.git] / tools / mandoc / Makefile
blobfbfb643a8b2194a2f61539be7341c985752fd9f0
1 # $NetBSD: Makefile,v 1.5 2010/02/20 13:43:31 joerg Exp $
3 HOSTPROGNAME= ${_TOOL_PREFIX}mandoc
4 HOST_SRCDIR= external/bsd/mdocml/bin/mandoc
6 NOMAN= # defined
8 .include <bsd.own.mk>
9 .include <bsd.sys.mk>
11 NETBSD_MINOR!= ${HOST_SH} ${NETBSDSRCDIR}/sys/conf/osrelease.sh -n
12 NETBSD_OSNAME= "NetBSD ${NETBSD_MINOR}"
14 HOST_CPPFLAGS+= -DOSNAME=${NETBSD_OSNAME:Q} -DHAVE_CONFIG_H -I.
16 DPSRCS+= config.h
18 CLEANFILES+= config.log config.h
20 config.h: config.h.pre config.h.post
21 rm -f config.log
22 ( cat ${DISTDIR}/config.h.pre; \
23 echo; \
24 if $(CC) $(CFLAGS) -Werror -c ${DISTDIR}/test-strlcat.c >> config.log 2>&1; then \
25 echo '#define HAVE_STRLCAT'; \
26 rm test-strlcat.o; \
27 fi; \
28 if $(CC) $(CFLAGS) -Werror -c ${DISTDIR}/test-strlcpy.c >> config.log 2>&1; then \
29 echo '#define HAVE_STRLCPY'; \
30 rm test-strlcpy.o; \
31 fi; \
32 echo; \
33 cat ${DISTDIR}/config.h.post \
34 ) > $@
36 .include "${.CURDIR}/../Makefile.host"