1*906afcb8SAndy Fiddaman# 2*906afcb8SAndy Fiddaman# CDDL HEADER START 3*906afcb8SAndy Fiddaman# 4*906afcb8SAndy Fiddaman# The contents of this file are subject to the terms of the 5*906afcb8SAndy Fiddaman# Common Development and Distribution License (the "License"). 6*906afcb8SAndy Fiddaman# You may not use this file except in compliance with the License. 7*906afcb8SAndy Fiddaman# 8*906afcb8SAndy Fiddaman# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 9*906afcb8SAndy Fiddaman# or http://www.opensolaris.org/os/licensing. 10*906afcb8SAndy Fiddaman# See the License for the specific language governing permissions 11*906afcb8SAndy Fiddaman# and limitations under the License. 12*906afcb8SAndy Fiddaman# 13*906afcb8SAndy Fiddaman# When distributing Covered Code, include this CDDL HEADER in each 14*906afcb8SAndy Fiddaman# file and include the License file at usr/src/OPENSOLARIS.LICENSE. 15*906afcb8SAndy Fiddaman# If applicable, add the following below this CDDL HEADER, with the 16*906afcb8SAndy Fiddaman# fields enclosed by brackets "[]" replaced with your own identifying 17*906afcb8SAndy Fiddaman# information: Portions Copyright [yyyy] [name of copyright owner] 18*906afcb8SAndy Fiddaman# 19*906afcb8SAndy Fiddaman# CDDL HEADER END 20*906afcb8SAndy Fiddaman# 21*906afcb8SAndy Fiddaman 22*906afcb8SAndy Fiddaman# 23*906afcb8SAndy Fiddaman# Copyright 2009 Sun Microsystems, Inc. All rights reserved. 24*906afcb8SAndy Fiddaman# Use is subject to license terms. 25*906afcb8SAndy Fiddaman# 26*906afcb8SAndy Fiddaman# Copyright 2021 OmniOS Community Edition (OmniOSce) Association. 27*906afcb8SAndy Fiddaman 28*906afcb8SAndy FiddamanSHELL= /usr/bin/ksh93 29*906afcb8SAndy Fiddaman 30*906afcb8SAndy FiddamanLIBRARY= libsum.a 31*906afcb8SAndy FiddamanVERS= .1 32*906afcb8SAndy Fiddaman 33*906afcb8SAndy Fiddamaninclude ../Makefile.defs 34*906afcb8SAndy Fiddaman 35*906afcb8SAndy FiddamanOBJECTS += $(LIBOBJS) 36*906afcb8SAndy Fiddaman 37*906afcb8SAndy Fiddamaninclude $(SRC)/lib/Makefile.lib 38*906afcb8SAndy Fiddamaninclude ../../Makefile.ast 39*906afcb8SAndy Fiddaman 40*906afcb8SAndy FiddamanMAPFILES= ../mapfile-vers 41*906afcb8SAndy Fiddaman 42*906afcb8SAndy FiddamanLIBS= $(DYNLIB) 43*906afcb8SAndy Fiddaman 44*906afcb8SAndy FiddamanLDLIBS += -last -lmd -lc 45*906afcb8SAndy Fiddaman 46*906afcb8SAndy Fiddaman# We use "=" here since using $(CPPFLAGS.master) is very tricky in our 47*906afcb8SAndy Fiddaman# case - it MUST come as the last element but future changes in -D options 48*906afcb8SAndy Fiddaman# may then cause silent breakage in the AST sources because the last -D 49*906afcb8SAndy Fiddaman# option specified overrides previous -D options so we prefer the current 50*906afcb8SAndy Fiddaman# way to explicitly list each single flag. 51*906afcb8SAndy Fiddaman# Notes: 52*906afcb8SAndy FiddamanCPPFLAGS= \ 53*906afcb8SAndy Fiddaman $(DTEXTDOM) $(DTS_ERRNO) \ 54*906afcb8SAndy Fiddaman -Iast -I. \ 55*906afcb8SAndy Fiddaman -I$(ROOT)/usr/include/ast \ 56*906afcb8SAndy Fiddaman -I$(ROOT)/usr/include \ 57*906afcb8SAndy Fiddaman -D_PACKAGE_ast \ 58*906afcb8SAndy Fiddaman -D_BLD_DLL 59*906afcb8SAndy Fiddaman 60*906afcb8SAndy FiddamanCFLAGS += $(ASTCFLAGS) 61*906afcb8SAndy FiddamanCFLAGS64 += $(ASTCFLAGS64) 62*906afcb8SAndy Fiddaman 63*906afcb8SAndy FiddamanCERRWARN += -_gcc=-Wno-parentheses 64*906afcb8SAndy Fiddaman 65*906afcb8SAndy Fiddaman# This codepath is performance-critical 66*906afcb8SAndy Fiddamansparc_COPTFLAG = -xO5 -_cc=-xprefetch=auto,explicit 67*906afcb8SAndy Fiddamansparcv9_COPTFLAG = $(sparc_COPTFLAG) 68*906afcb8SAndy Fiddamani386_COPTFLAG = -_cc=-xO5 -_cc=-xprefetch=auto,explicit 69*906afcb8SAndy Fiddamanamd64_COPTFLAG = $(i386_COPTFLAG) 70*906afcb8SAndy Fiddaman 71*906afcb8SAndy Fiddamanall: install_h .WAIT $(LIBS) 72*906afcb8SAndy Fiddaman 73*906afcb8SAndy Fiddaman# 74*906afcb8SAndy Fiddaman# libsum is not lint-clean yet; fake up a target. (You can use 75*906afcb8SAndy Fiddaman# "make lintcheck" to actually run lint; please send all lint fixes 76*906afcb8SAndy Fiddaman# upstream (to AT&T) so the next update will pull them into ON.) 77*906afcb8SAndy Fiddaman# 78*906afcb8SAndy Fiddamanlint: 79*906afcb8SAndy Fiddaman @ print "usr/src/lib/libsum is not lint-clean: skipping" 80*906afcb8SAndy Fiddaman 81*906afcb8SAndy Fiddamaninclude $(SRC)/lib/Makefile.targ 82*906afcb8SAndy Fiddaman 83*906afcb8SAndy Fiddamanpics/%.o: $(ASTSRC)/%.c 84*906afcb8SAndy Fiddaman $(CC) $(CFLAGS) $(CPPFLAGS) -c -o $@ $< 85*906afcb8SAndy Fiddaman $(POST_PROCESS_O) 86*906afcb8SAndy Fiddaman 87*906afcb8SAndy Fiddaman###################################################################### 88*906afcb8SAndy Fiddaman# Header file generation 89*906afcb8SAndy Fiddaman 90*906afcb8SAndy Fiddaman$(HEADERSRC:%=ast/%): FRC 91*906afcb8SAndy Fiddaman $(MKDIR) -p $(@D) 92*906afcb8SAndy Fiddaman $(CP) $(ASTSRC)/$(@F) $@ 93*906afcb8SAndy Fiddaman 94*906afcb8SAndy Fiddamaninstall_h: $(HEADERSRC:%=ast/%) 95*906afcb8SAndy Fiddaman 96*906afcb8SAndy FiddamanCLOBBERFILES += ast/* 97*906afcb8SAndy Fiddaman 98*906afcb8SAndy Fiddaman_feature: FRC 99*906afcb8SAndy Fiddaman $(MAKE) -f Makefile.iffe generate 100*906afcb8SAndy Fiddaman 101*906afcb8SAndy Fiddamaninclude ../../Makefile.astmsg 102*906afcb8SAndy Fiddaman 103*906afcb8SAndy FiddamanFRC: 104