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 547911a7dScy# Common Development and Distribution License (the "License"). 647911a7dScy# 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# 2147911a7dScy# Copyright 2007 Sun Microsystems, Inc. All rights reserved. 227c478bd9Sstevel@tonic-gate# Use is subject to license terms. 237c478bd9Sstevel@tonic-gate# 247e085c24SAndrew Stormont# Copyright 2018 RackTop Systems. 255661bb76SJohn Levon# Copyright (c) 2018, Joyent, Inc. 267e085c24SAndrew Stormont# 277c478bd9Sstevel@tonic-gate 287c478bd9Sstevel@tonic-gateFMADIR = $(SRC)/cmd/fm 297c478bd9Sstevel@tonic-gateEVERDIR = $(FMADIR)/eversholt 307c478bd9Sstevel@tonic-gateEVERCMNSRC = $(EVERDIR)/common 317c478bd9Sstevel@tonic-gate 327c478bd9Sstevel@tonic-gateEFTCLASS = reader 337c478bd9Sstevel@tonic-gatewriter_WRTOBJ = eftwrite.o 347c478bd9Sstevel@tonic-gatereader_WRTOBJ = 357c478bd9Sstevel@tonic-gate 367c478bd9Sstevel@tonic-gateCMNOBJS = alloc.o check.o eftread.o esclex.o io.o literals.o lut.o \ 377c478bd9Sstevel@tonic-gate out.o ptree.o stable.o stats.o tree.o $($(EFTCLASS)_WRTOBJ) 387c478bd9Sstevel@tonic-gate 397c478bd9Sstevel@tonic-gateCOMMONOBJS = escparse.o $(CMNOBJS) 407c478bd9Sstevel@tonic-gateCOMMONSRCS = $(COMMONOBJS:%.o=$(EVERCMNSRC)/%.c) 417c478bd9Sstevel@tonic-gate 42*6d9ec342SRobert MustacchiBASECPPFLAGS = -I$(EVERCMNSRC) -I. 43*6d9ec342SRobert Mustacchi$(NOT_RELEASE_BUILD)BASECPPFLAGS += -DDEBUG 44*6d9ec342SRobert MustacchiCPPFLAGS += $(BASECPPFLAGS) 457014882cSRichard LoweCFLAGS += $(CCVERBOSE) 46d3b5f563SJohn LevonCERRWARN += $(CNOWARN_UNINIT) 477014882cSRichard LoweCERRWARN += -_gcc=-Wno-unused-label 487014882cSRichard LoweCERRWARN += -_gcc=-Wno-parentheses 497014882cSRichard LoweCERRWARN += -_gcc=-Wno-switch 507c478bd9Sstevel@tonic-gate 515661bb76SJohn LevonSMOFF += all_func_returns 525661bb76SJohn Levon 537c478bd9Sstevel@tonic-gateCTFCONVO = $(CTFCONVERT_O) 547c478bd9Sstevel@tonic-gateCTFMRG = $(CTFMERGE) -L VERSION -o $@ $(OBJS) 557c478bd9Sstevel@tonic-gate 567c478bd9Sstevel@tonic-gatedebug := COPTFLAG = 577c478bd9Sstevel@tonic-gatedebug := COPTFLAG64 = 587c478bd9Sstevel@tonic-gate 597c478bd9Sstevel@tonic-gateROOTPDIR = $(ROOT)/usr/lib/fm 607c478bd9Sstevel@tonic-gateROOTPROG = $(ROOTPDIR)/$(PROG) 617c478bd9Sstevel@tonic-gate 627c478bd9Sstevel@tonic-gateinstall_h: $(ROOTHDIR) $(ROOTHDRS) 637c478bd9Sstevel@tonic-gate 647c478bd9Sstevel@tonic-gate%.o: %.c 657c478bd9Sstevel@tonic-gate $(COMPILE.c) $< 667c478bd9Sstevel@tonic-gate $(CTFCONVO) 677c478bd9Sstevel@tonic-gate 687c478bd9Sstevel@tonic-gate%.o: $(EVERCMNSRC)/%.c 697c478bd9Sstevel@tonic-gate $(COMPILE.c) $< 707c478bd9Sstevel@tonic-gate $(CTFCONVO) 717c478bd9Sstevel@tonic-gate 727c478bd9Sstevel@tonic-gateescparse.o: $(EVERCMNSRC)/escparse.y 737c478bd9Sstevel@tonic-gate $(YACC) -dtv $(EVERCMNSRC)/escparse.y 747c478bd9Sstevel@tonic-gate $(COMPILE.c) -DYYDEBUG -c -o $@ y.tab.c 757c478bd9Sstevel@tonic-gate $(CTFCONVO) 767c478bd9Sstevel@tonic-gate 777e085c24SAndrew Stormont$(ROOTPDIR): 787c478bd9Sstevel@tonic-gate $(INS.dir) 797c478bd9Sstevel@tonic-gate 807e085c24SAndrew Stormont$(ROOTPDIR)/%: % $(ROOTPDIR) 817c478bd9Sstevel@tonic-gate $(INS.file) 82