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 54ab75253Smrj# Common Development and Distribution License (the "License"). 64ab75253Smrj# 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# 214ab75253Smrj 227c478bd9Sstevel@tonic-gate# 23bba9e99cSGarrett D'Amore# Copyright 2010 Sun Microsystems, Inc. All rights reserved. 247c478bd9Sstevel@tonic-gate# Use is subject to license terms. 257c478bd9Sstevel@tonic-gate# 267c478bd9Sstevel@tonic-gate# include global definitions 277c478bd9Sstevel@tonic-gateinclude ../../../Makefile.master 287c478bd9Sstevel@tonic-gate 297c478bd9Sstevel@tonic-gateHDRS= \ 307c478bd9Sstevel@tonic-gateavintr.h \ 315bdc182bSGarrett D'Amorebootconf.h \ 32*6357b7bbSGarrett D'Amoredkmpio.h \ 337c478bd9Sstevel@tonic-gatefdreg.h fdvar.h \ 34b51e13bfSGarrett D'Amoreobpdefs.h \ 357c478bd9Sstevel@tonic-gatepromif.h promimpl.h \ 36b51e13bfSGarrett D'Amoreser_async.h ser_zscc.h \ 37fb9f9b97Skupfersocalio.h socalreg.h \ 383db86aabSstevelsocal_cq_defs.h socalmap.h socalvar.h \ 397c478bd9Sstevel@tonic-gatettymux.h ttymuxuser.h \ 407c478bd9Sstevel@tonic-gatezsdev.h 417c478bd9Sstevel@tonic-gate 427c478bd9Sstevel@tonic-gateSCSIADHDRS= \ 43*6357b7bbSGarrett D'Amorefascmd.h fasdma.h \ 443d19cdaeSstevelfasreg.h fasvar.h ifpio.h sfvar.h 45fb9f9b97Skupfer 467c478bd9Sstevel@tonic-gateSCSITARGHDRS= \ 477c478bd9Sstevel@tonic-gate 487c478bd9Sstevel@tonic-gateROOTDIR= $(ROOT)/usr/include/sys 497c478bd9Sstevel@tonic-gateROOTDIRS= $(ROOTDIR) \ 507c478bd9Sstevel@tonic-gate $(ROOTDIR)/audio \ 517c478bd9Sstevel@tonic-gate $(ROOTDIR)/scsi/adapters \ 527c478bd9Sstevel@tonic-gate $(ROOTDIR)/scsi/targets 537c478bd9Sstevel@tonic-gate 547c478bd9Sstevel@tonic-gateROOTHDRS= $(HDRS:%=$(ROOTDIR)/%) 557c478bd9Sstevel@tonic-gateROOTFCHDRS= $(FCHDRS:%=$(ROOTDIR)/fc4/%) 567c478bd9Sstevel@tonic-gateROOTSCSIADHDRS= $(SCSIADHDRS:%=$(ROOTDIR)/scsi/adapters/%) 577c478bd9Sstevel@tonic-gateROOTSCSITARGHDRS= $(SCSITARGHDRS:%=$(ROOTDIR)/scsi/targets/%) 587c478bd9Sstevel@tonic-gate 597c478bd9Sstevel@tonic-gate 607c478bd9Sstevel@tonic-gate# install rules 617c478bd9Sstevel@tonic-gate$(ROOTDIR)/%: % 627c478bd9Sstevel@tonic-gate $(INS.file) 637c478bd9Sstevel@tonic-gate 647c478bd9Sstevel@tonic-gate$(ROOTDIR)/audio/%: audio/% 657c478bd9Sstevel@tonic-gate $(INS.file) 667c478bd9Sstevel@tonic-gate 677c478bd9Sstevel@tonic-gate$(ROOTDIR)/scsi/adapters/%: scsi/adapters/% 687c478bd9Sstevel@tonic-gate $(INS.file) 697c478bd9Sstevel@tonic-gate 707c478bd9Sstevel@tonic-gate$(ROOTDIR)/scsi/targets/%: scsi/targets/% 717c478bd9Sstevel@tonic-gate $(INS.file) 727c478bd9Sstevel@tonic-gate 737c478bd9Sstevel@tonic-gate# check files really don't exist 747c478bd9Sstevel@tonic-gate 757c478bd9Sstevel@tonic-gateaudio/%.check: audio/%.h 767c478bd9Sstevel@tonic-gate $(DOT_H_CHECK) 777c478bd9Sstevel@tonic-gate 787c478bd9Sstevel@tonic-gatescsi/adapters/%.check: scsi/adapters/%.h 797c478bd9Sstevel@tonic-gate $(DOT_H_CHECK) 807c478bd9Sstevel@tonic-gate 817c478bd9Sstevel@tonic-gatescsi/targets/%.check: scsi/targets/%.h 827c478bd9Sstevel@tonic-gate $(DOT_H_CHECK) 837c478bd9Sstevel@tonic-gate 847c478bd9Sstevel@tonic-gateCHECKHDRS= \ 857c478bd9Sstevel@tonic-gate $(HDRS:%.h=%.check) \ 867c478bd9Sstevel@tonic-gate $(FCHDRS:%.h=fc4/%.check) \ 877c478bd9Sstevel@tonic-gate $(SCSIADHDRS:%.h=scsi/adapters/%.check) \ 887c478bd9Sstevel@tonic-gate $(SCSITARGHDRS:%.h=scsi/targets/%.check) 897c478bd9Sstevel@tonic-gate 907c478bd9Sstevel@tonic-gate# headers which won't quite meet the standards... 917c478bd9Sstevel@tonic-gate# 927c478bd9Sstevel@tonic-gate# devops.h has a macro where the formal parameters to the macro are greater 937c478bd9Sstevel@tonic-gate# than 80 characters. cpp (or the equivalent built into acomp) does not allow 947c478bd9Sstevel@tonic-gate# continuation line breaks in the formal parameter list. This could be fixed 957c478bd9Sstevel@tonic-gate# by giving shorter names to the formal parameters, but the right fix is to 967c478bd9Sstevel@tonic-gate# fix cpp. (Also, /* CSTYLED */ doesn't seem to fix this. 977c478bd9Sstevel@tonic-gate# 987c478bd9Sstevel@tonic-gatedevops.check := CSTYLE_TAIL = | grep -v "line > 80 characters" | true 997c478bd9Sstevel@tonic-gate 1007c478bd9Sstevel@tonic-gate.KEEP_STATE: 1017c478bd9Sstevel@tonic-gate 1027c478bd9Sstevel@tonic-gate.PARALLEL: $(CHECKHDRS) $(ROOTHDRS) $(ROOTAUDHDRS) $(ROOTAUDIMPLHDRS) \ 1037c478bd9Sstevel@tonic-gate $(ROOTSCSIADHDRS) $(ROOTSCSITARGHDRS) $(ROOTXHDRS) \ 1047c478bd9Sstevel@tonic-gate $(ROOTFCHDRS) 1057c478bd9Sstevel@tonic-gate 1067c478bd9Sstevel@tonic-gateinstall_h: $(ROOTDIRS) .WAIT $(ROOTHDRS) \ 1077c478bd9Sstevel@tonic-gate $(ROOTAUDHDRS) $(ROOTAUDIMPLHDRS) \ 1087c478bd9Sstevel@tonic-gate $(ROOTSCSIADHDRS) $(ROOTSCSITARGHDRS) $(ROOTFCHDRS) 1097c478bd9Sstevel@tonic-gate 1107c478bd9Sstevel@tonic-gate$(ROOTDIRS): 1117c478bd9Sstevel@tonic-gate $(INS.dir) 1127c478bd9Sstevel@tonic-gate 1137c478bd9Sstevel@tonic-gatecheck: $(CHECKHDRS) 114