Makefile revision 4ebb14b236958cfe1ef4ff3b7a50216d9e51f997
436aad11e01e916f75e68a2e9cb89ac217a990d3Tinderbox User#
6fe48fb46e53ffc37542853a1edb74cb481b7d94Automatic Updater# CDDL HEADER START
c7ef13f6c9ef4436bc804b150e0a93307b11fa27Tinderbox User#
c7ef13f6c9ef4436bc804b150e0a93307b11fa27Tinderbox User# The contents of this file are subject to the terms of the
a5636b773fa05a272b6876afd99309c0b3090e2fMark Andrews# Common Development and Distribution License (the "License").
e9e4257668ff6c4e583b0c0db2508650b0b677b8Tinderbox User# You may not use this file except in compliance with the License.
e9e4257668ff6c4e583b0c0db2508650b0b677b8Tinderbox User#
c57668a2fbbe558c1bd21652813616f2f517c469Tinderbox User# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
5e047890ac9b745db060d95f7d1b4f876511240dTinderbox User# or http://www.opensolaris.org/os/licensing.
137fdbc214e99c4cbe57551e9e14f2015c2e42aeTinderbox User# See the License for the specific language governing permissions
3349f0044fda807e1fd6681c833d3593a22dad86Tinderbox User# and limitations under the License.
bed0874e1a09e810575328c4bfc346a47514b69fMark Andrews#
02b47c5d62e1e827743684c28a08e871da454a2dMark Andrews# When distributing Covered Code, include this CDDL HEADER in each
b886b04d8d2b085cbf3e1bf4442dee87f43ba5e4Tinderbox User# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
710bce1a85c96e85ca1a90471382055acd29d51fTinderbox User# If applicable, add the following below this CDDL HEADER, with the
e20309353e6246485c521278131d3fced73d7957Tinderbox User# fields enclosed by brackets "[]" replaced with your own identifying
e20309353e6246485c521278131d3fced73d7957Tinderbox User# information: Portions Copyright [yyyy] [name of copyright owner]
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews#
9a5217f827ac0e006016745e5305b31dc0c7767fTinderbox User# CDDL HEADER END
3cc98b8ecedcbc8465f1cf2740b966b315662430Automatic Updater#
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews#
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# Copyright 2006 Sun Microsystems, Inc. All rights reserved.
e20309353e6246485c521278131d3fced73d7957Tinderbox User# Use is subject to license terms.
e20309353e6246485c521278131d3fced73d7957Tinderbox User#
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews#ident "%Z%%M% %I% %E% SMI"
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews#
efb0e886f18894a1d2489f1ad74ad14b579e11c7Mark Andrews# This makefile drives the production of the ibmf kernel module.
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews#
777e9370fab9f14eacd5517b9cad63293848117bMark Andrews# intel architecture dependent
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews#
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson#
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews# Path to the base of the uts directory tree (usually /usr/src/uts).
b886b04d8d2b085cbf3e1bf4442dee87f43ba5e4Tinderbox User#
710bce1a85c96e85ca1a90471382055acd29d51fTinderbox UserUTSBASE = ../..
aa9c561961e9d877946ebaa8795fa2be054ab7bfEvan Hunt
e130ab53e992670e2a2ecf043976ac09f21358d1Automatic Updater#
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic Updater# Define the module and object file sets.
aa9c561961e9d877946ebaa8795fa2be054ab7bfEvan Hunt#
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic UpdaterMODULE = ibmf
24934f08b9ff81c2be711e566e8002d145573031Tinderbox UserOBJECTS = $(IBMF_OBJS:%=$(OBJS_DIR)/%)
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic UpdaterLINTS = $(IBMF_OBJS:%.o=$(LINTS_DIR)/%.ln)
aa9c561961e9d877946ebaa8795fa2be054ab7bfEvan HuntROOTMODULE = $(ROOT_MISC_DIR)/$(MODULE)
24934f08b9ff81c2be711e566e8002d145573031Tinderbox UserLDFLAGS += -dy -Nmisc/ibtl
e9e4257668ff6c4e583b0c0db2508650b0b677b8Tinderbox UserWARLOCK_OUT = $(IBMF_OBJS:%.o=%.ll)
aa9c561961e9d877946ebaa8795fa2be054ab7bfEvan HuntWARLOCK_OK = $(MODULE).ok
710bce1a85c96e85ca1a90471382055acd29d51fTinderbox UserWLCMD_DIR = $(UTSBASE)/common/io/warlock
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic Updater#
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic Updater# Include common rules.
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic Updater#
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrewsinclude $(UTSBASE)/intel/Makefile.intel
cdfc81e048bd34c1d628380247bda6b80a89e20eAutomatic Updater
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews#
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic Updater# Define targets
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews#
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic UpdaterALL_TARGET = $(BINARY)
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark AndrewsLINT_TARGET = $(MODULE).lint
eabc9c3c07cd956d3c436bd7614cb162dabdda76Mark AndrewsINSTALL_TARGET = $(BINARY) $(ROOTMODULE)
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews
b886b04d8d2b085cbf3e1bf4442dee87f43ba5e4Tinderbox User#
e20309353e6246485c521278131d3fced73d7957Tinderbox User# Overrides
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews#
24934f08b9ff81c2be711e566e8002d145573031Tinderbox User
e20309353e6246485c521278131d3fced73d7957Tinderbox User#DEBUG_DEFS_DBG32 += -DTNF_DEBUG
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews
7feccf248d2a20a2ae48b290f58ded5abc853e9aTinderbox User#
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# lint pass one enforcement
ad411d8ccf8a27eb903b842ab507ba6729d0246bTinderbox User#
80faf1588895fd26490f82f95a7a1b771df1c324Automatic UpdaterCFLAGS += $(CCVERBOSE)
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews
ad411d8ccf8a27eb903b842ab507ba6729d0246bTinderbox User#
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# For now, disable these lint checks; maintainers should endeavor
28a5dd720187fddb16055a0f64b63a7b66f29f64Mark Andrews# to investigate and remove these for maximum lint coverage.
28a5dd720187fddb16055a0f64b63a7b66f29f64Mark Andrews# Please do not carry these forward to new Makefiles.
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews#
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark AndrewsLINTTAGS += -erroff=E_BAD_PTR_CAST_ALIGN
91216cff91b34c9ff6e846dc23f248219cafe660Andreas GustafssonLINTTAGS += -erroff=E_ASSIGN_NARROW_CONV
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews#
efb0e886f18894a1d2489f1ad74ad14b579e11c7Mark Andrews# Default build targets.
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews#
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson.KEEP_STATE:
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrewsdef: $(DEF_DEPS)
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrewsall: $(ALL_DEPS)
28a5dd720187fddb16055a0f64b63a7b66f29f64Mark Andrews
28a5dd720187fddb16055a0f64b63a7b66f29f64Mark Andrewsclean: $(CLEAN_DEPS)
78f3ed4bc2fcd3d270bfd599804f3b27a1db4d91Mark Andrews $(RM) $(WARLOCK_OUT) $(WARLOCK_OK)
3349f0044fda807e1fd6681c833d3593a22dad86Tinderbox User
3349f0044fda807e1fd6681c833d3593a22dad86Tinderbox Userclobber: $(CLOBBER_DEPS)
78f3ed4bc2fcd3d270bfd599804f3b27a1db4d91Mark Andrews $(RM) $(WARLOCK_OUT) $(WARLOCK_OK)
28a5dd720187fddb16055a0f64b63a7b66f29f64Mark Andrews
28a5dd720187fddb16055a0f64b63a7b66f29f64Mark Andrewslint: $(LINT_DEPS)
28a5dd720187fddb16055a0f64b63a7b66f29f64Mark Andrews
28a5dd720187fddb16055a0f64b63a7b66f29f64Mark Andrewsmodlintlib: $(MODLINTLIB_DEPS)
2a31bd531072824ef252c18303859d6af7451b00Francis Dupont
3349f0044fda807e1fd6681c833d3593a22dad86Tinderbox Userclean.lint: $(CLEAN_LINT_DEPS)
3349f0044fda807e1fd6681c833d3593a22dad86Tinderbox User
2a31bd531072824ef252c18303859d6af7451b00Francis Dupontinstall: $(INSTALL_DEPS)
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews
2ba8f584b97cbab864570e38fd26b8cb90961428Tinderbox User#
3349f0044fda807e1fd6681c833d3593a22dad86Tinderbox User# Include common targets.
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews#
78f3ed4bc2fcd3d270bfd599804f3b27a1db4d91Mark Andrewsinclude $(UTSBASE)/intel/Makefile.targ
bed0874e1a09e810575328c4bfc346a47514b69fMark Andrews
24bf1e02f03577db0feb50b80238c4150c96d05dAutomatic Updater#
78f3ed4bc2fcd3d270bfd599804f3b27a1db4d91Mark Andrews# Defines for local commands.
78f3ed4bc2fcd3d270bfd599804f3b27a1db4d91Mark Andrews#
2ba8f584b97cbab864570e38fd26b8cb90961428Tinderbox UserWLCC = wlcc
a308b69ac66fadf66863484f301314d6e6a3f1d2Automatic UpdaterTOUCH = touch
78f3ed4bc2fcd3d270bfd599804f3b27a1db4d91Mark AndrewsWARLOCK = warlock
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark AndrewsSCS = sccs
551271d8198ae06e37edf5da519d8ee153eeac0fTinderbox UserTEST = test
27c3c21f41520e8d6336d80a8094389e321cb6d2Mark Andrews
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews#
b871c7156eb037d41f53828c6fcb9cc876128962Mark Andrews# Warlock targets
b871c7156eb037d41f53828c6fcb9cc876128962Mark Andrews#
b871c7156eb037d41f53828c6fcb9cc876128962Mark Andrewswarlock: $(WARLOCK_OK)
01a5c5503482fb3ba52088bf0178a7213273bf96Mark Andrews
551271d8198ae06e37edf5da519d8ee153eeac0fTinderbox User%.wlcmd:
b871c7156eb037d41f53828c6fcb9cc876128962Mark Andrews cd $(WLCMD_DIR); $(TEST) -f $@ || $(SCCS) get $@
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews
cdfc81e048bd34c1d628380247bda6b80a89e20eAutomatic Updater$(WARLOCK_OK): $(WARLOCK_OUT) warlock_ddi.files ibmf.wlcmd
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews $(WARLOCK) -c $(WLCMD_DIR)/ibmf.wlcmd $(WARLOCK_OUT) \
fe80a4909bf62b602feaf246866e9d29f7654194Automatic Updater -l ../warlock/ddi_dki_impl.ll
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews $(TOUCH) $@
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews
fa0326cc2cf428f67575b6ba3b97b528a31b0010Tinderbox User%.ll: $(UTSBASE)/common/io/ib/mgt/ibmf/%.c
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews $(WLCC) $(CPPFLAGS) -DNPROBE -DDEBUG -o $@ $<
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews
fe80a4909bf62b602feaf246866e9d29f7654194Automatic Updaterwarlock_ddi.files:
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews @cd ../warlock; pwd; $(MAKE) warlock
e16b482740c5e7ad4c27e271fa829b957cdf67d4Mark Andrews