xref: /titanic_44/usr/src/uts/sun4u/seattle/Makefile (revision 32529ec11ac8e93a62985721612a18ee6bb8659a)
1#
2# Copyright 2005 Sun Microsystems, Inc.  All rights reserved.
3# Use is subject to license terms.
4#
5# ident	"%Z%%M%	%I%	%E% SMI"
6#
7# uts/sun4u/seattle/Makefile
8#
9#	This makefile drives the production of the sun4u seattle platform
10#	module.
11#
12#	sun4u implementation architecture dependent
13#
14
15#
16#	Path to the base of the uts directory tree (usually /usr/src/uts).
17#
18UTSBASE	= ../..
19
20#
21#	Include common rules.
22#
23include $(UTSBASE)/sun4u/seattle/Makefile.seattle
24
25def		:=	TARGET= def
26all		:=	TARGET= all
27install		:=	TARGET= install
28install_h	:=	TARGET= install_h
29clean		:=	TARGET= clean
30clobber		:=	TARGET= clobber
31lint		:=	TARGET= lint
32lintlib		:=	TARGET= lintlib
33modlintlib	:=	TARGET= modlintlib
34clean.lint	:=	TARGET= clean.lint
35check		:=	TARGET= check
36
37#
38#	Default build targets.
39#
40.KEEP_STATE:
41
42def all clean clean.lint clobber: $(SEATTLE_KMODS)
43
44modlintlib:	$(SEATTLE_KMODS)
45
46LINKED_PLATFORMS	= SUNW,Sun-Fire-V245
47
48# EXPORT DELETE START
49#
50# aes256 is delivered in the SUNWcryr package which is removed from
51# the EXPORT_SRC build.
52#
53SEATTLE_CRYPTO_LINKS	+= aes256
54# EXPORT DELETE END
55
56install:	$(ROOT_SEATTLE_DIR) \
57		$(USR_SEATTLE_DIR) \
58		$(USR_SEATTLE_INC_DIR) \
59		$(USR_SEATTLE_SBIN_EEPROM) \
60		$(USR_SEATTLE_SBIN_PRTDIAG) \
61		$(USR_SEATTLE_SBIN_TRAPSTAT) \
62		$(USR_SEATTLE_LIB_DIR) \
63		$(LINKED_PLATFORMS:%=$(USR_PLAT_DIR)/%) \
64		$(LINKED_PLATFORMS:%=$(ROOT_PLAT_DIR)/%) \
65		$(SEATTLE_CRYPTO_LINKS) \
66		.WAIT $(SEATTLE_KMODS)
67
68check install_h:
69
70lint:		modlintlib
71
72#
73# The 'lint.platmod' target lints the seattle platform module against the sun4u
74# kernel.  This ends up doing all the kernel cross-checks, so it takes a couple
75# of minutes.  Due to the low ROI, it's not run by default, but it's a good
76# idea to run this if you change os/seattle.c.
77#
78LINT_LIBS	 = $(LINT_LIB) \
79		   -L$(SEATTLE_LINT_LIB_DIR) \
80		   -L$(LINT_LIB_DIR) $(LINT_KMODS:%=-l%) \
81		   -L$(SPARC_LIB_DIR) $(SPARC_LINTS:%=-l%)
82
83lint.platmod:	modlintlib
84	@-$(ECHO) "\nSeattle Platform-dependent module: global crosschecks:"
85	@-$(LINT) $(LINTFLAGS) $(LINT_LIBS) 2>&1 | $(LGREP.2)
86
87$(SEATTLE_KMODS): FRC
88	@cd $@; pwd; $(MAKE) $(TARGET)
89
90$(SEATTLE_CRYPTO_LINKS): $(ROOT_SEATTLE_CRYPTO_DIR_64)
91	-$(RM) $(ROOT_SEATTLE_CRYPTO_DIR_64)/$@;
92	$(SYMLINK) $(ROOT_US3_CRYPTO_LINK)/$@ $(ROOT_SEATTLE_CRYPTO_DIR_64)/$@
93
94# EXPORT DELETE START
95
96EXPORT_SRC:
97	$(RM) Makefile+
98	sed -e "/^# EXPORT DELETE START/,/^# EXPORT DELETE END/d" \
99	    < Makefile > Makefile+
100	$(MV) Makefile+ Makefile
101	$(CHMOD) 444 Makefile
102
103# EXPORT DELETE END
104
105#
106#
107#	Include common targets.
108#
109include $(UTSBASE)/sun4u/seattle/Makefile.targ
110