0
|
1 |
#
|
|
2 |
# CDDL HEADER START
|
|
3 |
#
|
|
4 |
# The contents of this file are subject to the terms of the
|
580
|
5 |
# Common Development and Distribution License (the "License").
|
|
6 |
# You may not use this file except in compliance with the License.
|
0
|
7 |
#
|
|
8 |
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
|
|
9 |
# or http://www.opensolaris.org/os/licensing.
|
|
10 |
# See the License for the specific language governing permissions
|
|
11 |
# and limitations under the License.
|
|
12 |
#
|
|
13 |
# When distributing Covered Code, include this CDDL HEADER in each
|
|
14 |
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
|
|
15 |
# If applicable, add the following below this CDDL HEADER, with the
|
|
16 |
# fields enclosed by brackets "[]" replaced with your own identifying
|
|
17 |
# information: Portions Copyright [yyyy] [name of copyright owner]
|
|
18 |
#
|
|
19 |
# CDDL HEADER END
|
|
20 |
#
|
580
|
21 |
|
0
|
22 |
#
|
|
23 |
# Copyright 2005 Sun Microsystems, Inc. All rights reserved.
|
|
24 |
# Use is subject to license terms.
|
|
25 |
#
|
580
|
26 |
# ident "%Z%%M% %I% %E% SMI"
|
|
27 |
#
|
|
28 |
|
0
|
29 |
#
|
|
30 |
# This makefile drives the production of the generic
|
|
31 |
# unix kernel module.
|
|
32 |
#
|
|
33 |
# sparc implementation architecture dependent
|
|
34 |
#
|
|
35 |
|
|
36 |
#
|
|
37 |
# Path to the base of the uts directory tree (usually /usr/src/uts).
|
|
38 |
#
|
|
39 |
UTSBASE = ../..
|
|
40 |
|
|
41 |
#
|
|
42 |
# Define the module and object file sets.
|
|
43 |
#
|
|
44 |
MODULE = genunix
|
|
45 |
GENUNIX = $(OBJS_DIR)/$(MODULE)
|
|
46 |
|
|
47 |
OBJECTS = $(GENUNIX_OBJS:%=$(OBJS_DIR)/%) \
|
|
48 |
$(NOT_YET_KMODS:%=$(OBJS_DIR)/%)
|
|
49 |
|
|
50 |
LINTS = $(GENUNIX_OBJS:%.o=$(LINTS_DIR)/%.ln) \
|
|
51 |
$(NOT_YET_KMODS:%.o=$(LINTS_DIR)/%.ln)
|
|
52 |
|
|
53 |
ROOTMODULE = $(ROOT_PSM_KERN_DIR)/$(MODULE)
|
|
54 |
|
|
55 |
PLATFORM = sun4u
|
|
56 |
LIBGEN = $(OBJS_DIR)/libgenunix.so
|
|
57 |
LIBSTUBS = $(GENSTUBS_OBJS:%=$(OBJS_DIR)/%)
|
|
58 |
|
|
59 |
#
|
|
60 |
# Include common rules.
|
|
61 |
#
|
|
62 |
include $(UTSBASE)/sparc/Makefile.sparc
|
|
63 |
|
|
64 |
#
|
|
65 |
# Define targets
|
|
66 |
#
|
|
67 |
ALL_TARGET = $(LIBGEN)
|
|
68 |
LINT_TARGET = $(MODULE).lint
|
|
69 |
INSTALL_TARGET = $(GENUNIX) $(ROOTMODULE)
|
|
70 |
|
|
71 |
#
|
|
72 |
# Override defaults
|
|
73 |
#
|
|
74 |
CLEANFILES += $(LIBSTUBS) $(LIBGEN)
|
|
75 |
|
|
76 |
LINT_LIB_DIR = $(UTSBASE)/$(PLATFORM)/lint-libs/$(OBJS_DIR)
|
|
77 |
LINT_LIB = $(LINT_LIB_DIR)/llib-lunix.ln
|
|
78 |
GEN_LINT_LIB =
|
|
79 |
|
|
80 |
BINARY =
|
|
81 |
|
|
82 |
CLOBBERFILES += $(GENUNIX)
|
|
83 |
|
|
84 |
#
|
|
85 |
# Non-patch genunix builds merge a version of the ip module called ipctf. This
|
|
86 |
# is to ensure that the common network-related types are included in genunix and
|
|
87 |
# can thus be uniquified out of other modules. We don't want to do this for
|
|
88 |
# patch builds, since we can't guarantee that ip and genunix will be in the same
|
|
89 |
# patch.
|
|
90 |
#
|
|
91 |
IPCTF_TARGET = $(IPCTF)
|
|
92 |
$(PATCH_BUILD)IPCTF_TARGET =
|
|
93 |
|
|
94 |
#
|
|
95 |
# lint pass one enforcement
|
|
96 |
#
|
|
97 |
CFLAGS += $(CCVERBOSE)
|
|
98 |
CPPFLAGS += -I$(SRC)/common
|
|
99 |
|
|
100 |
#
|
|
101 |
# Default build targets.
|
|
102 |
#
|
|
103 |
.KEEP_STATE:
|
|
104 |
|
|
105 |
.PARALLEL: $(LIBSTUBS)
|
|
106 |
|
|
107 |
def: $(DEF_DEPS)
|
|
108 |
|
|
109 |
all: $(ALL_DEPS)
|
|
110 |
|
|
111 |
clean: $(CLEAN_DEPS)
|
|
112 |
|
|
113 |
clobber: $(CLOBBER_DEPS)
|
|
114 |
|
|
115 |
lint: $(LINT_DEPS)
|
|
116 |
|
|
117 |
modlintlib: $(MODLINTLIB_DEPS)
|
|
118 |
|
|
119 |
clean.lint: $(CLEAN_LINT_DEPS)
|
|
120 |
|
|
121 |
install: $(INSTALL_DEPS)
|
|
122 |
|
|
123 |
$(LIBGEN): $(GENUNIX) $(LIBSTUBS)
|
580
|
124 |
$(BUILD.SO) $(GENUNIX) $(LIBSTUBS)
|
0
|
125 |
|
|
126 |
$(IPCTF_TARGET) ipctf_target: FRC
|
|
127 |
@cd $(IPDRV_DIR); pwd; $(MAKE) ipctf.$(OBJS_DIR)
|
|
128 |
@pwd
|
|
129 |
|
|
130 |
$(GENUNIX): $(IPCTF_TARGET) $(OBJECTS)
|
|
131 |
$(LD) -r $(LDFLAGS) -o $@ $(OBJECTS)
|
|
132 |
$(CTFMERGE_GENUNIX_MERGE)
|
|
133 |
$(POST_PROCESS)
|
|
134 |
|
|
135 |
$(OBJECTS): $(OBJS_DIR)
|
|
136 |
|
|
137 |
#
|
|
138 |
# Include common targets.
|
|
139 |
#
|
|
140 |
include $(UTSBASE)/sparc/Makefile.targ
|
|
141 |
|
|
142 |
#
|
|
143 |
# Include sun4u workarounds.
|
|
144 |
#
|
|
145 |
include $(UTSBASE)/sun4u/Makefile.workarounds
|
|
146 |
|
|
147 |
ALL_DEFS += $(WORKAROUND_DEFS)
|