Makefile revision 5d4606d7857958f486a2dc8cb37c99a0b72335d6
4133N/A#
4133N/A# CDDL HEADER START
4133N/A#
4133N/A# The contents of this file are subject to the terms of the
4133N/A# Common Development and Distribution License (the "License").
4133N/A# You may not use this file except in compliance with the License.
4133N/A#
4133N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
4133N/A# or http://www.opensolaris.org/os/licensing.
4133N/A# See the License for the specific language governing permissions
4133N/A# and limitations under the License.
4133N/A#
4133N/A# When distributing Covered Code, include this CDDL HEADER in each
4133N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
4133N/A# If applicable, add the following below this CDDL HEADER, with the
4133N/A# fields enclosed by brackets "[]" replaced with your own identifying
4133N/A# information: Portions Copyright [yyyy] [name of copyright owner]
4133N/A#
4133N/A# CDDL HEADER END
4133N/A#
5680N/A
4133N/A#
5680N/A# Copyright 2009 Sun Microsystems, Inc. All rights reserved.
5680N/A# Use is subject to license terms.
5680N/A#
4724N/A
4133N/A#
4133N/A# Copyright 2010 Nexenta Systems, Inc. All rights reserved.
4133N/A#
4723N/A
4133N/APROG= alias
4723N/AALIASPROG= \
4723N/A bg \
4133N/A cd \
4133N/A cksum \
4133N/A cmp \
5680N/A comm \
5680N/A command \
5680N/A cut \
4133N/A fc \
4723N/A fg \
4723N/A getopts \
4723N/A hash \
4133N/A jobs \
4133N/A join \
5680N/A kill \
5680N/A logname \
5680N/A paste \
5680N/A print \
4133N/A read \
4133N/A rev \
4133N/A sleep \
4133N/A sum \
4133N/A tee \
4133N/A test \
4133N/A type \
4723N/A ulimit \
4723N/A umask \
4723N/A unalias \
4723N/A uniq \
4133N/A wait \
4133N/A wc
4133N/A
4133N/AXPG4ALIASPROG= \
4133N/A bg \
4133N/A cd \
4133N/A command \
4133N/A fc \
4133N/A fg \
4133N/A getopts \
4133N/A hash \
4133N/A jobs \
4133N/A kill \
4133N/A read \
4133N/A test \
4133N/A type \
4133N/A ulimit \
4133N/A umask \
4133N/A unalias \
4133N/A wait
4133N/A
4133N/Ainclude ../../Makefile.cmd
4133N/A$(SPARC_BLD)include ../../Makefile.cmd.64
4133N/A
4133N/AROOTALIASPROG= $(ALIASPROG:%=$(ROOTBIN)/%) $(XPG4ALIASPROG:%=$(ROOTXPG4BIN)/%)
4723N/A
4723N/AFILEMODE= 555
4133N/A
4133N/A.KEEP_STATE:
4723N/A
4133N/Aall: $(PROG)
4133N/A
4133N/A$(ROOTBIN)/%: $(ROOTBIN)/alias
4133N/A $(INS.link)
4133N/A
4133N/A$(ROOTXPG4BIN)/%: $(ROOTBIN)/alias
5795N/A $(INS.link)
5795N/A
5795N/A.KEEP_STATE:
5795N/A
5795N/A# Set common AST build flags (e.g., needed to support the math stuff).
5795N/Ainclude ../../../Makefile.ast
5795N/A
5795N/AOBJECTS= \
5795N/A alias.o
5795N/A
5795N/ASRCS= $(OBJECTS:%.o=%.c)
5795N/A
5795N/ALDLIBS += -lshell -lcmd -last
5795N/A
4723N/ACPPFLAGS = \
4133N/A $(DTEXTDOM) $(DTS_ERRNO) \
4133N/A -I$(ROOT)/usr/include/ast \
5795N/A -I$(ROOT)/usr/include
4133N/A
4133N/A# Enable workaround for a crash in /usr/bin/alias when invalid
4723N/A# options are passed (e.g. $ /usr/bin/alias -c #). The shell
4133N/A# code will call an error handler which does a |longjmp()| but
4133N/A# somehow the code failed to do the |setjmp()| before this point.
4723N/ACPPFLAGS += -DWORKAROUND_FOR_ALIAS_CRASH
CFLAGS += \
$(ASTCFLAGS)
CFLAGS64 += \
$(ASTCFLAGS64)
ROOTCMDDIR=$(ROOT)/usr/bin
# .WAIT is needed to get the hardlinks properly done
install: all $(ROOTCMD) .WAIT $(ROOTALIASPROG)
$(PROG): $(OBJECTS)
$(RM) alias
$(LINK.c) $(OBJECTS) -o $@ $(LDLIBS)
$(POST_PROCESS)
clean clobber:
rm -f $(PROG) $(OBJECTS)
lint _msg: