xref: /illumos-gate/usr/src/tools/mandoc/Makefile (revision 4d131170)
195c635efSGarrett D'Amore#
295c635efSGarrett D'Amore# This file and its contents are supplied under the terms of the
395c635efSGarrett D'Amore# Common Development and Distribution License ("CDDL"), version 1.0.
495c635efSGarrett D'Amore# You may only use this file in accordance with the terms of version
595c635efSGarrett D'Amore# 1.0 of the CDDL.
695c635efSGarrett D'Amore#
795c635efSGarrett D'Amore# A full copy of the text of the CDDL should have accompanied this
895c635efSGarrett D'Amore# source.  A copy of the CDDL is also available via the Internet at
995c635efSGarrett D'Amore# http://www.illumos.org/license/CDDL.
1095c635efSGarrett D'Amore#
1195c635efSGarrett D'Amore
1295c635efSGarrett D'Amore#
134585130bSYuri Pankov# Copyright 2017 Nexenta Systems, Inc.
1473769bc1SJason King# Copyright 2018 Joyent, Inc.
1595c635efSGarrett D'Amore#
1695c635efSGarrett D'Amore
17260e9a87SYuri PankovCMDDIR=		$(SRC)/cmd/mandoc
184585130bSYuri PankovLCDIR=		$(SRC)/lib/libc/port
1995c635efSGarrett D'Amore
20503609a9SYuri Pankovinclude		$(SRC)/tools/Makefile.tools
21260e9a87SYuri Pankovinclude		$(CMDDIR)/Makefile.common
2295c635efSGarrett D'Amore
2373769bc1SJason KingCPPFLAGS +=	-_gcc=-nostdinc
2410f4f8a6SJerry JelinekCPPFLAGS +=	-I$(NATIVE_ADJUNCT)/include
2510f4f8a6SJerry JelinekLDFLAGS +=	-L$(NATIVE_ADJUNCT)/lib -R$(NATIVE_ADJUNCT)/lib
26a40ea1a7SYuri Pankov
27*93b88728SJohn Levon# 3rd party code
28*93b88728SJohn LevonSMATCH=off
29*93b88728SJohn Levon
30260e9a87SYuri Pankov.KEEP_STATE:
3195c635efSGarrett D'Amore
32260e9a87SYuri Pankovall:		$(PROG)
3395c635efSGarrett D'Amore
34503609a9SYuri Pankovinstall:	all $(ROOTONBLDMACHPROG)
3595c635efSGarrett D'Amore
36260e9a87SYuri Pankovclean:
37260e9a87SYuri Pankov		$(RM) $(PROG) $(OBJS)
3895c635efSGarrett D'Amore
3995c635efSGarrett D'Amore$(PROG):	$(OBJS)
40260e9a87SYuri Pankov		$(LINK.c) $(OBJS) -o $@ $(LDLIBS)
4195c635efSGarrett D'Amore		$(POST_PROCESS)
4295c635efSGarrett D'Amore
4395c635efSGarrett D'Amore%.o:		$(CMDDIR)/%.c
4495c635efSGarrett D'Amore		$(COMPILE.c) -o $@ $<
4595c635efSGarrett D'Amore
464585130bSYuri Pankov%.o:		$(LCDIR)/gen/%.c
474585130bSYuri Pankov		$(COMPILE.c) -o $@ $<
484585130bSYuri Pankov
49503609a9SYuri Pankovinclude		$(SRC)/tools/Makefile.targ
50