Makefile revision f808c858fa61e7769218966759510a8b1190dfcf
346N/A#
346N/A# CDDL HEADER START
1276N/A#
346N/A# The contents of this file are subject to the terms of the
1549N/A# Common Development and Distribution License (the "License").
346N/A# You may not use this file except in compliance with the License.
346N/A#
919N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
919N/A# or http://www.opensolaris.org/os/licensing.
919N/A# See the License for the specific language governing permissions
919N/A# and limitations under the License.
919N/A#
919N/A# When distributing Covered Code, include this CDDL HEADER in each
919N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
919N/A# If applicable, add the following below this CDDL HEADER, with the
919N/A# fields enclosed by brackets "[]" replaced with your own identifying
919N/A# information: Portions Copyright [yyyy] [name of copyright owner]
919N/A#
919N/A# CDDL HEADER END
919N/A#
919N/A#
919N/A# Copyright 2006 Sun Microsystems, Inc. All rights reserved.
919N/A# Use is subject to license terms.
919N/A#
346N/A# ident "%Z%%M% %I% %E% SMI"
346N/A#
346N/A
346N/Ainclude ../Makefile.lib
493N/A
346N/ASUBDIRS = $(MACH)
970N/A$(BUILD64)SUBDIRS += $(MACH64)
970N/A
970N/Aall := TARGET= all
970N/Ainstall := TARGET= install
1356N/Aclean := TARGET= clean
1356N/Aclobber := TARGET= clobber
1356N/Alint := TARGET= lint
346N/A
1549N/A# capability NAMES generated source
346N/ANAMES= \
911N/Asrc/libc/xcurses/boolcode.c src/libc/xcurses/boolfnam.c \
1549N/Asrc/libc/xcurses/boolname.c src/libc/xcurses/numcode.c \
1549N/Asrc/libc/xcurses/numfnam.c src/libc/xcurses/numname.c \
1549N/Asrc/libc/xcurses/strcode.c src/libc/xcurses/strfnam.c \
911N/Asrc/libc/xcurses/strname.c
346N/A
1276N/AGENERATED= \
1068N/A$(NAMES) src/libc/xcurses/keyindex.c h/term.h
1068N/A
1068N/A# definitions for install_h target
1068N/AHDRS= h/term.h h/curses.h h/unctrl.h
1068N/AROOTHDRDIR= $(ROOT)/usr/xpg4/include
1068N/AROOTHDRS= $(HDRS:h/%=$(ROOTHDRDIR)/%)
1549N/A
1549N/A# install rule for install_h target
346N/A$(ROOTHDRDIR)/%: h/%
346N/A $(INS.file)
1276N/A
493N/A# extra clean-up work
346N/ACLOBBERFILES= $(GENERATED)
970N/A
970N/A.KEEP_STATE:
970N/A
346N/ALIBS= $(DYNLIB) $(LINTLIB)
346N/A
346N/Aall: $(GENERATED) .WAIT $(SUBDIRS)
install: all .WAIT $(SUBDIRS)
clean clobber: $(SUBDIRS)
$(RM) $(GENERATED)
lint: $(SUBDIRS)
# still need to implement cstyle check of term.h
# do this when we go through and make this library cstyle clean.
check: $(HDRS)
install_h: $(ROOTHDRS)
$(SUBDIRS): $(GENERATED)
@cd $@; pwd; $(MAKE) $(TARGET)
# derived C files
# mknames.awk defines functions so needs nawk
$(NAMES) : src/libc/xcurses/mknames.awk src/libc/xcurses/caps
$(RM) $(NAMES)
cd src/libc/xcurses; nawk -f mknames.awk caps
h/term.h : src/libc/xcurses/mkterm.awk src/libc/xcurses/caps
$(RM) $@
cd src/libc/xcurses; awk -f mkterm.awk caps > term.h
$(MV) src/libc/xcurses/term.h h/term.h
src/libc/xcurses/keyindex.c : src/libc/xcurses/mkkey.awk src/libc/xcurses/caps
$(RM) $@
cd src/libc/xcurses; nawk -f mkkey.awk caps > keyindex.c