Makefile.com revision 5648:161f8007cab9
11849Swollman# 21849Swollman# CDDL HEADER START 31849Swollman# 41849Swollman# The contents of this file are subject to the terms of the 51849Swollman# Common Development and Distribution License (the "License"). 61849Swollman# You may not use this file except in compliance with the License. 71849Swollman# 81849Swollman# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 91849Swollman# or http://www.opensolaris.org/os/licensing. 101849Swollman# See the License for the specific language governing permissions 111849Swollman# and limitations under the License. 121849Swollman# 131849Swollman# When distributing Covered Code, include this CDDL HEADER in each 141849Swollman# file and include the License file at usr/src/OPENSOLARIS.LICENSE. 151849Swollman# If applicable, add the following below this CDDL HEADER, with the 161849Swollman# fields enclosed by brackets "[]" replaced with your own identifying 171849Swollman# information: Portions Copyright [yyyy] [name of copyright owner] 181849Swollman# 191849Swollman# CDDL HEADER END 201849Swollman# 211849Swollman# 221849Swollman#ident "%Z%%M% %I% %E% SMI" 231849Swollman# 241849Swollman# Copyright 2007 Sun Microsystems, Inc. All rights reserved. 251849Swollman# Use is subject to license terms. 261849Swollman# 271849Swollman# psm/stand/lib/boot/sparcv9/Makefile.com 281849Swollman# 291849Swollman# SPARC architecture Makefile for Standalone Library 301849Swollman# Platform-specific, but shared between platforms. 3185437Speter# Firmware dependent. 3293000Sobrien# 331849Swollman 341849Swollmaninclude $(TOPDIR)/Makefile.master 351849Swollmaninclude $(TOPDIR)/lib/Makefile.lib 361849Swollmaninclude $(TOPDIR)/psm/stand/lib/Makefile.lib 371849Swollman 381849SwollmanPSMSYSHDRDIR = $(TOPDIR)/psm/stand 391849Swollman 401849SwollmanLIBBOOT = libboot.a 411849SwollmanLINTLIBBOOT = llib-lboot.ln 421849Swollman 431849Swollman# ARCHCMNDIR - common code for several machines of a given isa 441849Swollman# OBJSDIR - where the .o's go 451849Swollman 461849SwollmanARCHCMNDIR = $(TOPDIR)/uts/sparc/os 471849SwollmanOBJSDIR = objs 481849Swollman 491849SwollmanCMNSRCS = bootops.c 501849SwollmanBOOTSRCS = $(PLATSRCS) $(CMNSRCS) 511849SwollmanBOOTOBJS = $(BOOTSRCS:%.c=%.o) 521849Swollman 531849SwollmanOBJS = $(BOOTOBJS:%=$(OBJSDIR)/%) 541849SwollmanL_OBJS = $(OBJS:%.o=%.ln) 551849SwollmanL_SRCS = $(CMNSRCS:%=$(ARCHCMNDIR)/%) $(PLATSRCS) 561849Swollman 571849SwollmanCPPINCS += -I$(SRC)/uts/common 581849SwollmanCPPINCS += -I$(SRC)/uts/sun 591849SwollmanCPPINCS += -I$(SRC)/uts/sparc 601849SwollmanCPPINCS += -I$(SRC)/uts/sparc/$(ARCHVERS) 611849SwollmanCPPINCS += -I$(SRC)/uts/$(PLATFORM) 621849SwollmanCPPINCS += -I$(ROOT)/usr/include/$(ARCHVERS) 631849SwollmanCPPINCS += -I$(ROOT)/usr/platform/$(PLATFORM)/include 641849SwollmanCPPINCS += -I$(PSMSYSHDRDIR) 651849SwollmanCPPFLAGS = $(CPPINCS) $(CCYFLAG)$(PSMSYSHDRDIR) 661849SwollmanCPPFLAGS += -D_KERNEL -D_MACHDEP 671849SwollmanASFLAGS = -P -D__STDC__ -D_ASM $(CPPINCS) 681849SwollmanCFLAGS += $(CCVERBOSE) 691849Swollman 701849Swollman.KEEP_STATE: 711849Swollman 721849Swollman.PARALLEL: $(OBJS) $(L_OBJS) 731849Swollman 741849Swollmanall install: $(LIBBOOT) .WAIT 751849Swollman 761849Swollmanlint: $(LINTLIBBOOT) 771849Swollman 781849Swollmanclean: 791849Swollman $(RM) $(OBJS) $(L_OBJS) 801849Swollman 811849Swollmanclobber: clean 82 $(RM) $(LIBBOOT) $(LINTLIBBOOT) a.out core 83 84$(LIBBOOT): $(OBJSDIR) .WAIT $(OBJS) 85 $(BUILD.AR) $(OBJS) 86 87$(LINTLIBBOOT): $(OBJSDIR) .WAIT $(L_OBJS) 88 @$(ECHO) "\nlint library construction:" $@ 89 @$(LINT.lib) -o boot $(L_SRCS) 90 91$(OBJSDIR): 92 -@[ -d $@ ] || mkdir $@ 93 94# 95# build rules using standard library object subdirectory 96# 97$(OBJSDIR)/%.o: $(ARCHCMNDIR)/%.c 98 $(COMPILE.c) -o $@ $< 99 $(POST_PROCESS_O) 100 101$(OBJSDIR)/%.o: $(ARCHCMNDIR)/%.s 102 $(COMPILE.s) -o $@ $< 103 $(POST_PROCESS_O) 104 105$(OBJSDIR)/%.ln: $(ARCHCMNDIR)/%.c 106 @($(LHEAD) $(LINT.c) $< $(LTAIL)) 107 @$(MV) $(@F) $@ 108 109$(OBJSDIR)/%.ln: $(ARCHCMNDIR)/%.s 110 @($(LHEAD) $(LINT.s) $< $(LTAIL)) 111 @$(MV) $(@F) $@ 112