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 2005 Sun Microsystems, Inc. All rights reserved. 24# Use is subject to license terms. 25# 26# cmd/awk_xpg4/Makefile 27# 28# Copyright (c) 2018, Joyent, Inc. 29 30# NOTE: this is nawk in usr/src/cmd/awk_xpg4 to reside as /usr/xpg4/bin/awk 31 32PROG= awk 33XPG4PROG= awk 34 35OBJ1= awk0.o awk1.o awk2.o awk3.o awk4.o 36OBJ2= awk.o 37XPG4AWKOBJ= values-xpg4.o 38OBJS= $(OBJ2) $(OBJ1) $(XPG4AWKOBJ) 39 40include ../Makefile.cmd 41 42CPPFLAGS += -D_FILE_OFFSET_BITS=64 43CFLAGS += $(CCVERBOSE) 44CERRWARN += -_gcc=-Wno-parentheses 45CERRWARN += $(CNOWARN_UNINIT) 46YFLAGS += -d 47LDLIBS += -lm 48CLEANFILES= awk.c y.tab.h 49 50# because of labels from yacc 51awk.o := CERRWARN += -_gcc=-Wno-unused-label 52 53# not linted 54SMATCH=off 55 56# for messaging catalog 57 58POFILE= awk_xpg4.po 59POFILES= $(OBJ1:%.o=%.po) $(OBJ2:%.o=%.po) 60 61.KEEP_STATE: 62 63.PARALLEL: $(OBJS) 64 65all: $(XPG4) 66 67$(XPG4): $(OBJS) 68 $(LINK.c) $(OBJS) -o $@ $(LDLIBS) 69 $(POST_PROCESS) 70 71$(POFILE): $(POFILES) 72 $(RM) $@ 73 cat $(POFILES) > $@ 74# 75 76install: all $(ROOTXPG4PROG) 77 78values-xpg4.o: ../../lib/crt/common/values-xpg4.c 79 $(COMPILE.c) -o $@ ../../lib/crt/common/values-xpg4.c 80 81clean: 82 $(RM) $(OBJS) $(XPG4) $(CLEANFILES) 83 84awk.c + y.tab.h: awk.y 85 86awk.o: awk.c y.tab.h 87 88awk0.c: awk.c y.tab.h 89 90awk1.c: awk.c y.tab.h 91 92awk2.c: awk.c y.tab.h 93 94awk3.c: awk.c y.tab.h 95 96awk4.c: awk.c y.tab.h 97 98include ../Makefile.targ 99