Makefile revision 7014882c6a3672fd0e5d60200af8643ae53c5928
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# CDDL HEADER START
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# The contents of this file are subject to the terms of the
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# Common Development and Distribution License (the "License").
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# You may not use this file except in compliance with the License.
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# or http://www.opensolaris.org/os/licensing.
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# See the License for the specific language governing permissions
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# and limitations under the License.
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# When distributing Covered Code, include this CDDL HEADER in each
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# If applicable, add the following below this CDDL HEADER, with the
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# fields enclosed by brackets "[]" replaced with your own identifying
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# information: Portions Copyright [yyyy] [name of copyright owner]
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# CDDL HEADER END
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# uts/sparc/spppcomp/Makefile
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# Copyright 2007 Sun Microsystems, Inc. All rights reserved.
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# Use is subject to license terms.
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# Copyright (c) 2011 Bayard G. Bell. All rights reserved.
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# This makefile drives the production of the spppcomp STREAMS
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# kernel module.
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# sparc architecture dependent
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# Path to the base of the uts directory tree (usually /usr/src/uts).
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de ReeperUTSBASE = ../..
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# Define the module and object file sets.
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de ReeperMODULE = spppcomp
80c77071c6700660c39046da32a0d7953620f608Mark de ReeperOBJECTS = $(SPPPCOMP_OBJS:%=$(OBJS_DIR)/%)
80c77071c6700660c39046da32a0d7953620f608Mark de ReeperLINTS = $(SPPPCOMP_OBJS:%.o=$(LINTS_DIR)/%.ln)
80c77071c6700660c39046da32a0d7953620f608Mark de ReeperROOTMODULE = $(USR_STRMOD_DIR)/$(MODULE)
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# Include common rules.
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeperinclude $(UTSBASE)/sparc/Makefile.sparc
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# Define targets
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de ReeperALL_TARGET = $(BINARY)
80c77071c6700660c39046da32a0d7953620f608Mark de ReeperLINT_TARGET = $(MODULE).lint
80c77071c6700660c39046da32a0d7953620f608Mark de ReeperINSTALL_TARGET = $(BINARY) $(ROOTMODULE)
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# Internal build definitions
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de ReeperCPPFLAGS += -DINTERNAL_BUILD -DSOL2 -DMUX_FRAME
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# Additional compiler definitions
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de ReeperINC_PATH += -I$(UTSBASE)/common/io/ppp/common
80c77071c6700660c39046da32a0d7953620f608Mark de ReeperCFLAGS += $(CCVERBOSE)
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# Define dependency on sppp
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de ReeperLDFLAGS += -dy -N drv/sppp
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper
80c77071c6700660c39046da32a0d7953620f608Mark de ReeperCLEANLINTFILES += $(LINT64_FILES)
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper
80c77071c6700660c39046da32a0d7953620f608Mark de ReeperCERRWARN += -_gcc=-Wno-parentheses
80c77071c6700660c39046da32a0d7953620f608Mark de ReeperCERRWARN += -_gcc=-Wno-uninitialized
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper#
80c77071c6700660c39046da32a0d7953620f608Mark de Reeper# For now, disable these lint checks; maintainers should endeavor
# to investigate and remove these for maximum lint coverage.
# Please do not carry these forward to new Makefiles.
#
LINTTAGS += -erroff=E_BAD_PTR_CAST_ALIGN
LINTTAGS += -erroff=E_PTRDIFF_OVERFLOW
LINTTAGS += -erroff=E_ASSIGN_NARROW_CONV
#
# Default build targets.
#
.KEEP_STATE:
def: $(DEF_DEPS)
all: $(ALL_DEPS)
clean: $(CLEAN_DEPS)
clobber: $(CLOBBER_DEPS)
lint: $(LINT_DEPS)
modlintlib: $(MODLINTLIB_DEPS) lint64
clean.lint: $(CLEAN_LINT_DEPS)
install: $(INSTALL_DEPS)
$(LINTS_DIR)/%.ln: $(UTSBASE)/common/io/ppp/spppcomp/%.c
@($(LHEAD) $(LINT.c) $< $(LTAIL))
$(OBJS_DIR)/%.o: $(UTSBASE)/common/io/ppp/spppcomp/%.c
$(COMPILE.c) -o $@ $<
$(CTFCONVERT_O)
#
# Include common targets.
#
include $(UTSBASE)/sparc/Makefile.targ