1 #
   2 # CDDL HEADER START
   3 #
   4 # The contents of this file are subject to the terms of the
   5 # Common Development and Distribution License (the "License").
   6 # You may not use this file except in compliance with the License.
   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 #
  21 #
  22 # Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved.
  23 #
  24 #       This makefile drives the production of the sun4u snowbird platform
  25 #       module.
  26 #
  27 #       sun4u snowbird implementation architecture dependent
  28 #
  29 
  30 #
  31 #       Path to the base of the uts directory tree (usually /usr/src/uts).
  32 #
  33 UTSBASE = ../..
  34 
  35 include $(UTSBASE)/sun4u/snowbird/Makefile.snowbird
  36 
  37 #
  38 #
  39 #
  40 
  41 def             :=      TARGET= def
  42 all             :=      TARGET= all
  43 install         :=      TARGET= install
  44 install_h       :=      TARGET= install_h
  45 clean           :=      TARGET= clean
  46 clobber         :=      TARGET= clobber
  47 lint            :=      TARGET= lint
  48 lintlib         :=      TARGET= lintlib
  49 modlintlib      :=      TARGET= modlintlib
  50 modlist         :=      TARGET= modlist
  51 modlist         :=      NO_STATE= -K $$MODSTATE$$$$
  52 clean.lint      :=      TARGET= clean.lint
  53 check           :=      TARGET= check
  54 
  55 IMPLEMENTED_PLATFORM    = SUNW,Netra-CP2300
  56 
  57 #
  58 #       Default build targets.
  59 #
  60 .KEEP_STATE:
  61 
  62 .PARALLEL:      $(SNOWBIRD_KMODS)
  63 
  64 def all clean clobber clean.lint modlist:       $(SNOWBIRD_KMODS)
  65 
  66 install:        $(ROOT_SNOWBIRD_DIR) $(USR_SNOWBIRD_DIR) \
  67                 $(USR_SNOWBIRD_INC_DIR) \
  68                 $(USR_SNOWBIRD_SBIN_DIR) \
  69                 $(USR_SNOWBIRD_SBIN_PRTDIAG) \
  70                 $(USR_SNOWBIRD_SBIN_FRUADM) \
  71                 $(USR_SNOWBIRD_LIB_DIR) \
  72                 .WAIT $(SNOWBIRD_KMODS) \
  73                 ttymux_dacf ttymux.conf
  74 
  75 modlintlib:     $(SNOWBIRD_KMODS)
  76 
  77 $(SNOWBIRD_KMODS):      FRC
  78         @cd $@; pwd; $(MAKE) $(NO_STATE) $(TARGET)
  79 
  80 ttymux_dacf:    $(ROOT_SNOWBIRD_DACF_DIR_64) 
  81                 -@$(RM) $(ROOT_SNOWBIRD_DACF_DIR_64)/$@
  82                 $(SYMLINK) $(ROOT_SNOWBIRD_DACF_LINK_64)/$@ \
  83                 $(ROOT_SNOWBIRD_DACF_DIR_64)/$@
  84 
  85 
  86 ttymux.conf:    $(ROOT_SNOWBIRD_DRV_DIR)
  87                 -@$(RM) $(ROOT_SNOWBIRD_DRV_DIR_32)/$@
  88                 $(SYMLINK) $(ROOT_SNOWBIRD_DRV_LINK_32)/$@ \
  89                 $(ROOT_SNOWBIRD_DRV_DIR_32)/$@
  90 
  91 install_h check:        FRC
  92         @cd sys; pwd; $(MAKE) $(TARGET)
  93 
  94 lint:   modlintlib
  95  
  96 LINT_LIBS       = $(LINT_LIB) \
  97                         -L$(SNOWBIRD_LINT_LIB_DIR) \
  98                         -L$(LINT_LIB_DIR) $(LINT_KMODS:%=-l%) \
  99                             $(CLOSED_LINT_KMODS:%=-l%) \
 100                         -L$(SPARC_LIB_DIR) $(SPARC_LINTS:%=-l%)
 101 
 102 lint.platmod:   modlintlib
 103         @-$(ECHO) "\nSnowbird Platform-dependent module: global crosschecks:"
 104         @-$(LINT) $(LINTFLAGS) $(LINT_LIBS) 2>&1 | $(LGREP.2)
 105 
 106 #
 107 #       Include common targets.
 108 #
 109 include $(UTSBASE)/sun4u/snowbird/Makefile.targ