xref: /titanic_41/usr/src/cmd/boot/bootadm/Makefile (revision 7014882c6a3672fd0e5d60200af8643ae53c5928)
17c478bd9Sstevel@tonic-gate#
27c478bd9Sstevel@tonic-gate# CDDL HEADER START
37c478bd9Sstevel@tonic-gate#
47c478bd9Sstevel@tonic-gate# The contents of this file are subject to the terms of the
558091fd8Ssetje# Common Development and Distribution License (the "License").
658091fd8Ssetje# You may not use this file except in compliance with the License.
77c478bd9Sstevel@tonic-gate#
87c478bd9Sstevel@tonic-gate# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
97c478bd9Sstevel@tonic-gate# or http://www.opensolaris.org/os/licensing.
107c478bd9Sstevel@tonic-gate# See the License for the specific language governing permissions
117c478bd9Sstevel@tonic-gate# and limitations under the License.
127c478bd9Sstevel@tonic-gate#
137c478bd9Sstevel@tonic-gate# When distributing Covered Code, include this CDDL HEADER in each
147c478bd9Sstevel@tonic-gate# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
157c478bd9Sstevel@tonic-gate# If applicable, add the following below this CDDL HEADER, with the
167c478bd9Sstevel@tonic-gate# fields enclosed by brackets "[]" replaced with your own identifying
177c478bd9Sstevel@tonic-gate# information: Portions Copyright [yyyy] [name of copyright owner]
187c478bd9Sstevel@tonic-gate#
197c478bd9Sstevel@tonic-gate# CDDL HEADER END
207c478bd9Sstevel@tonic-gate#
217c478bd9Sstevel@tonic-gate#
2248847494SEnrico Perla - Sun Microsystems# Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
237c478bd9Sstevel@tonic-gate# Use is subject to license terms.
247c478bd9Sstevel@tonic-gate#
256debd3f5SAlexander Eremin# Copyright 2011 Nexenta Systems, Inc. All rights reserved.
266debd3f5SAlexander Eremin#
277c478bd9Sstevel@tonic-gate
287c478bd9Sstevel@tonic-gatePROG= bootadm
297c478bd9Sstevel@tonic-gate
307c478bd9Sstevel@tonic-gateSBINLINKS= $(PROG)
317c478bd9Sstevel@tonic-gate
3244da779fSWilliam KucharskiOBJS= bootadm.o bootadm_upgrade.o bootadm_hyper.o
339632cfadSsetjeSRCS = $(OBJS:.o=.c)
349632cfadSsetje
357c478bd9Sstevel@tonic-gateinclude ../Makefile.com
367c478bd9Sstevel@tonic-gate
377c478bd9Sstevel@tonic-gate
387c478bd9Sstevel@tonic-gate.KEEP_STATE:
397c478bd9Sstevel@tonic-gate
40e998e519SSheshadri VasudevanLDLIBS_i386= -lfdisk
416debd3f5SAlexander EreminLDLIBS +=	-lnvpair -lgen -ladm -lefi -lscf -lz -lbe -lzfs $(LDLIBS_$(MACH))
427c478bd9Sstevel@tonic-gate
437c478bd9Sstevel@tonic-gate# Writing into string literals is incorrect.  We need to match gcc's
447c478bd9Sstevel@tonic-gate# behavior, which causes us to take SIGSEGV on such a write.
457c478bd9Sstevel@tonic-gateCFLAGS +=	$(XSTRCONST)
4658091fd8SsetjeCPPFLAGS +=	-D_FILE_OFFSET_BITS=64
472449e17fSsherrymCPPFLAGS +=	-I../../../uts/common -I../../../common
48ae115bc7Smrj
49*7014882cSRichard LoweCERRWARN +=	-_gcc=-Wno-parentheses
50*7014882cSRichard LoweCERRWARN +=	-_gcc=-Wno-uninitialized
51*7014882cSRichard LoweCERRWARN +=	-_gcc=-Wno-unused-label
52*7014882cSRichard Lowe
5348847494SEnrico Perla - Sun MicrosystemsLINTFLAGS += -erroff=E_INCONS_ARG_DECL2
5448847494SEnrico Perla - Sun MicrosystemsLINTFLAGS += -erroff=E_INCONS_VAL_TYPE_DECL2
55e998e519SSheshadri VasudevanLINTFLAGS += -erroff=E_NAME_DEF_NOT_USED2
5648847494SEnrico Perla - Sun Microsystems
577c478bd9Sstevel@tonic-gateall: $(PROG)
587c478bd9Sstevel@tonic-gate
59ae115bc7Smrj$(PROG): $(OBJS) bootadm.h
609632cfadSsetje	$(LINK.c) -o $@ $(OBJS) $(LDLIBS)
619632cfadSsetje	$(POST_PROCESS)
629632cfadSsetje
63986fd29aSsetjeinstall: all $(ROOTSBINPROG) .WAIT $(ROOTUSRSBINLINKS)
647c478bd9Sstevel@tonic-gate
657c478bd9Sstevel@tonic-gateclean:
66ae115bc7Smrj	-$(RM) $(OBJS)
677c478bd9Sstevel@tonic-gate
687c478bd9Sstevel@tonic-gate_msg:
697c478bd9Sstevel@tonic-gate
70ae115bc7Smrjlint:	lint_SRCS
717c478bd9Sstevel@tonic-gate
727c478bd9Sstevel@tonic-gateinclude ../Makefile.targ
73