Makefile revision 02e56f3f1bfc8d9977bafb8cb5202f576dcded27
6fe48fb46e53ffc37542853a1edb74cb481b7d94Automatic Updater# CDDL HEADER START
229ea4644b3a7d9c7fdaa43888e7f55ba01e2ee3Automatic Updater# The contents of this file are subject to the terms of the
1167fc7904c5f0a472f8df207ac46dd52c7f1ec8Automatic Updater# Common Development and Distribution License (the "License").
0c39b3ed9409ecb277d5e32fa763a4e4d6598df8Automatic Updater# You may not use this file except in compliance with the License.
6fe48fb46e53ffc37542853a1edb74cb481b7d94Automatic Updater# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
0519188c8e1ae76978fc4e0f799620cd36eba07aAutomatic Updater# or http://www.opensolaris.org/os/licensing.
79b273c187a4aa1016a62181983dfdd0521681aeMark Andrews# See the License for the specific language governing permissions
90ff38a0d8deaf5f9c2aa5916d99b2e572d28738Automatic Updater# and limitations under the License.
ac4e70ff8955669341f435bc0a734a17c01af124Mark Andrews# When distributing Covered Code, include this CDDL HEADER in each
6c6a121295b30772cbf3dd75a51fb9d883051a0eAutomatic Updater# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington# If applicable, add the following below this CDDL HEADER, with the
9cd5eb6fe0f26d65724b99216cb31dcdd12e4afdAutomatic Updater# fields enclosed by brackets "[]" replaced with your own identifying
e171a4137c6ba348957e61b7c4c3541493c0da02Automatic Updater# information: Portions Copyright [yyyy] [name of copyright owner]
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# CDDL HEADER END
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# Copyright 2005 Sun Microsystems, Inc. All rights reserved.
e171a4137c6ba348957e61b7c4c3541493c0da02Automatic Updater# Use is subject to license terms.
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# ident "%Z%%M% %I% %E% SMI"
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson# This makefile drives the production of unix (and unix.o).
f2770f6b39a9b2a98afb7a11ed105f73f1570c1eAutomatic Updater# sun4u starcat implementation architecture dependent
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic Updater# Path to the base of the uts directory tree (usually /usr/src/uts).
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic Updater# Define the module and object file sets.
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic Updater $(MACH_NOT_YET_KMODS:%.o=$(LINTS_DIR)/%.ln) \
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic UpdaterROOTMODULE = $(ROOT_STARCAT_KERN_DIR)/$(UNIX)
9cd5eb6fe0f26d65724b99216cb31dcdd12e4afdAutomatic UpdaterGENOPTS = -L $(GENUNIX_DIR)/$(OBJS_DIR) -l $(GENUNIX)
8e9f3b69914ee02a80b87c97b1f8093edb3e9ae0Automatic UpdaterCPUOPTS = -L $(CPU_DIR)/$(OBJS_DIR) -l $(CPUNAME)
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark AndrewsPLATOPTS = -L $(PLAT_DIR)/$(OBJS_DIR) -l $(PLATMOD)
80faf1588895fd26490f82f95a7a1b771df1c324Automatic UpdaterLIBOPTS = $(GENOPTS) $(PLATOPTS) $(CPUOPTS)
693c4232dfdffaff672197d4b9fea944c64cf80aAutomatic Updater# Include common rules.
f2770f6b39a9b2a98afb7a11ed105f73f1570c1eAutomatic Updaterinclude $(UTSBASE)/sun4u/starcat/Makefile.starcat
f2770f6b39a9b2a98afb7a11ed105f73f1570c1eAutomatic Updater# Define targets
e130ab53e992670e2a2ecf043976ac09f21358d1Automatic Updater# This is UNIX_DIR. Use a short path.
78f3ed4bc2fcd3d270bfd599804f3b27a1db4d91Mark AndrewsCLEANFILES += $(UNIX_O) $(MODSTUBS_O) $(OBJS_DIR)/vers.c \
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# lint pass one enforcement
6fe48fb46e53ffc37542853a1edb74cb481b7d94Automatic Updater# Turn on doubleword alignment for 64 bit counter timer registers
f2770f6b39a9b2a98afb7a11ed105f73f1570c1eAutomatic Updater# Default build targets.
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson$(UNIX_BIN): $(UNIX_O) $(MODSTUBS_O) $(MAPFILE) $(LIBS) $(DTRACESTUBS)
f2770f6b39a9b2a98afb7a11ed105f73f1570c1eAutomatic Updater $(LD) -dy -b -o $@ -e _start -I $(KRTLD) -M $(MAPFILE) \
4104e236f71eb5108fcfda6711878a97f6f4a8e7Automatic Updater $(UNIX_O) $(MODSTUBS_O) $(LIBOPTS) $(DTRACESTUBS)
6fe48fb46e53ffc37542853a1edb74cb481b7d94Automatic Updatersymcheck.targ: $(UNIX_O) $(MODSTUBS_O) $(LIBS) $(DTRACESTUBS)
229ea4644b3a7d9c7fdaa43888e7f55ba01e2ee3Automatic Updater $(LD) -dy -b -o $(SYM_MOD) -M $(MAPFILE) \
765c97d56ccddc9d7904c7d9ff2e2d825d9687e4Automatic Updater $(UNIX_O) $(MODSTUBS_O) $(LIBOPTS) $(DTRACESTUBS)
8ccd7da886e93cd490fcb6f4c4e98a6514f35820Automatic Updater#$(UNIX).glom: $(UNIX)
da82e232161d67b77df2d67898bdac693f647be1Automatic Updater# ${LD} -dy -b -z nodefs -o $@ -e _start -I $(KRTLD) -M $(MAPFILE) \
e130ab53e992670e2a2ecf043976ac09f21358d1Automatic Updater# $(UNIX_O) $(MODSTUBS_O) $(GENUNIX_DIR)/$(GENUNIX)
d145b64cacc8d9cda51f9924ec70cd4661c3e2cfAutomatic Updater# $(POST_PROCESS)
1d4f4d2db2d69e48fec2dde5c1535853677d22a7Automatic Updater $(LD) -r -o $@ $(OBJECTS) $(OBJS_DIR)/vers.o
9c446b72069d0ab9f710502f4d7048e50875fccbAutomatic Updater# Special rules for generating assym.h for inclusion in assembly files.
59528addd704f8d5757b54e540520f74e588a7c7Automatic Updater @(cd $(GENLIB_DIR); pwd; $(MAKE) all.targ)
da82e232161d67b77df2d67898bdac693f647be1Automatic Updater# CPU_OBJ now comprises of 2 object files which come from sun4 common
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater# and from architecture dependent code. OBJS_DIR is prepended where
19b3dc94bce93fa76bd7e066f9298630dbc9dcb4Automatic Updater# CPU_DIR is defined to allow for building multiple CPU_OBJ's
5ecad47f69b3fd945472ab2900a9ff826a7ce2f6Automatic Updater# The global lint target builds the kernel lint library (llib-lunix.ln)
e130ab53e992670e2a2ecf043976ac09f21358d1Automatic Updater# which is equivalent to a lint of /unix.o. Then all kernel modules for
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater# this architecture are linted against the kernel lint library.
82447d835d3ff5c658749b4e9b4f66166407b3eaAutomatic Updater# Note: lint errors in the kernel lint library will be repeated for
7262eb86f2b465822206122921e2f357218f0cfdAutomatic Updater# each module. It is important that the kernel lint library
96ea71632887c58a9d00f47eb318bf76b35903c3Mark Andrews# be clean to keep the textual output to a reasonable level.
9cd5eb6fe0f26d65724b99216cb31dcdd12e4afdAutomatic Updater @-$(ECHO) "\n$(UNIX): (library construction):"
8711e5c73ca872d59810760af0332194cbdd619bAutomatic Updater# Include common targets.