Makefile revision 7014882c6a3672fd0e5d60200af8643ae53c5928
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein#
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein# CDDL HEADER START
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein#
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley# The contents of this file are subject to the terms of the
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews# Common Development and Distribution License (the "License").
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley# You may not use this file except in compliance with the License.
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley#
dd750c560ae48cf6caeb9a9fe81d33fc4746106dBrian Wellington# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
dd750c560ae48cf6caeb9a9fe81d33fc4746106dBrian Wellington# or http://www.opensolaris.org/os/licensing.
dd750c560ae48cf6caeb9a9fe81d33fc4746106dBrian Wellington# See the License for the specific language governing permissions
dd750c560ae48cf6caeb9a9fe81d33fc4746106dBrian Wellington# and limitations under the License.
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews#
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews# When distributing Covered Code, include this CDDL HEADER in each
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews# If applicable, add the following below this CDDL HEADER, with the
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews# fields enclosed by brackets "[]" replaced with your own identifying
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews# information: Portions Copyright [yyyy] [name of copyright owner]
dafcb997e390efa4423883dafd100c975c4095d6Mark Andrews#
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley# CDDL HEADER END
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein#
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley#
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley# Copyright 2007 Sun Microsystems, Inc. All rights reserved.
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley# Use is subject to license terms.
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley# Copyright (c) 2011 Bayard G. Bell. All rights reserved.
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley#
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley# This makefile drives the production of the gl_kmech_krb5 kernel module.
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley#
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley# intel implementation architecture dependent
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley#
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley#
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley# Path to the base of the uts directory tree (usually /usr/src/uts).
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley#
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob HalleyUTSBASE = ../..
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein#
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein# Define the module and object file sets.
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein#
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinMODULE = kmech_krb5
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinOBJECTS = $(KGSS_KRB5_OBJS:%=$(OBJS_DIR)/%)
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinLINTS = $(KGSS_KRB5_OBJS:%.o=$(LINTS_DIR)/%.ln)
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinROOTMODULE = $(ROOT_KGSS_DIR)/$(MODULE)
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein#
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein# Include common rules.
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein#
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austeininclude $(UTSBASE)/intel/Makefile.intel
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley#
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley# Define targets
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley#
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob HalleyALL_TARGET = $(BINARY)
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob HalleyLINT_TARGET = $(MODULE).lint
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob HalleyINSTALL_TARGET = $(BINARY) $(ROOTMODULE)
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley#
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley# Defined kgssapi and md5 as depdencies
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley#
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob HalleyLDFLAGS += -dy -N misc/kgssapi -N misc/md5
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley#
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley# For now, disable these lint checks; maintainers should endeavor
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley# to investigate and remove these for maximum lint coverage.
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley# Please do not carry these forward to new Makefiles.
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley#
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob HalleyLINTTAGS += -erroff=E_SUPPRESSION_DIRECTIVE_UNUSED
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob HalleyLINTTAGS += -erroff=E_ASSIGN_NARROW_CONV
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinLINTTAGS += -erroff=E_STATIC_UNUSED
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinCERRWARN += -_gcc=-Wno-unused-function
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinCERRWARN += -_gcc=-Wno-unused-label
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinCERRWARN += -_gcc=-Wno-uninitialized
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinCERRWARN += -_gcc=-Wno-parentheses
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley#
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein# Default build targets.
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein#
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein.KEEP_STATE:
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austeindef: $(DEF_DEPS)
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austeinall: $(ALL_DEPS)
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halleyclean: $(CLEAN_DEPS)
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austeinclobber: $(CLOBBER_DEPS)
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austeinlint: $(LINT_DEPS)
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austeinmodlintlib: $(MODLINTLIB_DEPS)
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halleyclean.lint: $(CLEAN_LINT_DEPS)
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austeininstall: $(INSTALL_DEPS)
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinKMECHKRB5_BASE=$(UTSBASE)/common/gssapi/mechs/krb5
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinKGSSDFLAGS=-I $(UTSBASE)/common/gssapi/include
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinKGSSDFLAGS += $(KRB5_DEFS)
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein$(OBJS_DIR)/%.o: $(KMECHKRB5_BASE)/crypto/crc32/%.c
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley $(COMPILE.c) $(KGSSDFLAGS) -o $@ $<
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley $(CTFCONVERT_O)
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley$(LINTS_DIR)/%.ln: $(KMECHKRB5_BASE)/crypto/crc32/%.c
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley @($(LHEAD) $(LINT.c) $(KGSSDFLAGS) $< $(LTAIL))
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley#
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley# Include common targets.
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein#
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austeininclude $(UTSBASE)/intel/Makefile.targ
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein
268a4475065fe6a8cd7cc707820982cf5e98f430Rob AusteinINC_PATH += \
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein -I$(UTSBASE)/common/gssapi \
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein -I$(UTSBASE)/common/gssapi/include \
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley -I$(UTSBASE)/common/gssapi/mechs/krb5/include \
268a4475065fe6a8cd7cc707820982cf5e98f430Rob Austein -I$(SRC)/lib/gss_mechs/mech_krb5/include \
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley -I$(SRC)/lib/gss_mechs/mech_krb5/krb5/krb
6ea1b817e31b89a627e146fe69e23ea0a64c89ecBob Halley