1#
2# CDDL HEADER START
3#
4# The contents of this file are subject to the terms of the
5# Common Development and Distribution License, Version 1.0 only
6# (the "License").  You may not use this file except in compliance
7# with the License.
8#
9# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10# or http://www.opensolaris.org/os/licensing.
11# See the License for the specific language governing permissions
12# and limitations under the License.
13#
14# When distributing Covered Code, include this CDDL HEADER in each
15# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16# If applicable, add the following below this CDDL HEADER, with the
17# fields enclosed by brackets "[]" replaced with your own identifying
18# information: Portions Copyright [yyyy] [name of copyright owner]
19#
20# CDDL HEADER END
21#
22#
23# Copyright 1989-2002 Sun Microsystems, Inc.  All rights reserved.
24# Use is subject to license terms.
25# Copyright 2015 Igor Kozhukhov <ikozhukhov@gmail.com>
26#
27# cmd/lp/filter/postscript/dpost/Makefile
28#
29
30include         ../../../Makefile.lp
31
32PROG=           dpost
33
34SRCS =		dpost.c draw.c color.c pictures.c ps_include.c
35
36OBJS =		$(SRCS:%.c=%.o)
37
38COMMONDIR=      ../common
39
40COMMONOBJS =	$(COMMONDIR)/glob.o \
41		$(COMMONDIR)/misc.o \
42		$(COMMONDIR)/request.o \
43		$(COMMONDIR)/tempnam.o
44
45TXTS=		README
46
47# dpost uses some floating point arithmetic, so if you're running on a system
48# without floating point hardware add the -f option to the definition of CFLAGS.
49
50ENCODING=	2
51CPPFLAGS =	-DDFLTENCODING=$(ENCODING)	\
52		-I. -I$(COMMONDIR)		\
53		$(CPPFLAGS.master)
54
55POFILE =	lp_filter_postscript_dpost.po
56
57.KEEP_STATE:
58
59all:		$(TXTS) $(PROG)
60
61install:	all $(ROOTLIBLPPOSTPROG)
62
63$(PROG):	$(OBJS) $(COMMONOBJS)
64		$(LINK.c) -o $@ $(OBJS) $(COMMONOBJS) $(LDLIBS)
65		$(POST_PROCESS)
66
67$(COMMONOBJS):	$$(@:%.o=%.c)
68		cd $(@D); $(MAKE) $(@F)
69
70ps_include.o:	ps_include.h
71ps_include.h:	ps_include.ps ps_include.awk
72		$(RM) $@; $(AWK) -f ps_include.awk ps_include.ps >$@
73
74clean:
75		$(RM) $(OBJS) ps_include.h
76
77strip:
78		$(STRIP) $(PROG)
79
80lint:		lint_SRCS
81
82include		../../../../Makefile.targ
83
84include		../Makefile.msg
85