PSARC/2006/379 Solaris on Extended partition
[illumos-gate.git] / usr / src / cmd / format / Makefile
blobe19d8342a7cb2725c5078674d19ad8a21bca535d
2 # CDDL HEADER START
4 # The contents of this file are subject to the terms of the
5 # Common Development and Distribution License (the "License").
6 # You may not use this file except in compliance with the License.
8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 # or http://www.opensolaris.org/os/licensing.
10 # See the License for the specific language governing permissions
11 # and limitations under the License.
13 # When distributing Covered Code, include this CDDL HEADER in each
14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 # If applicable, add the following below this CDDL HEADER, with the
16 # fields enclosed by brackets "[]" replaced with your own identifying
17 # information: Portions Copyright [yyyy] [name of copyright owner]
19 # CDDL HEADER END
22 # Copyright 2008 Sun Microsystems, Inc. All rights reserved.
23 # Use is subject to license terms.
26 PROG= format
28 COBJS= add_definition.o analyze.o checkdev.o ctlr_scsi.o \
29 defect.o init_menus.o io.o label.o main.o \
30 menu.o menu_analyze.o menu_cache.o menu_command.o menu_defect.o \
31 menu_partition.o misc.o modify_partition.o partition.o \
32 prompts.o startup.o menu_scsi.o auto_sense.o disk_generic.o \
33 menu_developer.o menu_fdisk.o
35 OBJS_sparc= init_csparc.o ctlr_ata.o
37 OBJS_i386= init_ci386.o ctlr_ata.o ix_altsctr.o
39 OBJS_= non-existent
41 OBJS= $(OBJS_$(MACH)) $(COBJS)
43 DATA= format.dat
45 include ../Makefile.cmd
47 SRCS= $(OBJS:.o=.c)
49 ROOTSYMLINK= $(ROOTETCPROG)
50 ROOTETCDATA= $(ROOTETC)/$(DATA)
52 $(ROOTETCDATA) := FILEMODE = 0644
53 $(ROOTETCDATA) := OWNER = root
54 $(ROOTETCDATA) := GROUP = sys
56 LDLIBS_i386= -lfdisk
57 LDLIBS_sparc=
58 LDLIBS += -ladm -lefi -ldiskmgt -lnvpair -ldevid $(LDLIBS_$(MACH))
60 LINTFLAGS += -xerroff=E_NAME_DEF_NOT_USED2
61 CPPFLAGS += -D_EXTVTOC
63 .KEEP_STATE:
65 all: $(PROG) $(DATA)
67 .PARALLEL: $(OBJS)
69 $(PROG): $(OBJS)
70 $(LINK.c) -o $(PROG) $(OBJS) $(LDLIBS)
71 $(POST_PROCESS)
74 # Install format as /usr/sbin/format, with link from /etc/format
76 install: $(ROOTUSRSBINPROG) $(ROOTSYMLINK) $(ROOTETCDATA)
78 $(ROOTSYMLINK):
79 $(RM) $@; $(SYMLINK) ../usr/sbin/$(PROG) $@
81 clean:
82 $(RM) $(OBJS)
84 lint: lint_SRCS
86 sb: $(SRCS)
87 $(COMPILE.c) -xsbfast $(SRCS)
89 include ../Makefile.targ