1 # CDDL HEADER START
   2 #
   3 # The contents of this file are subject to the terms of the
   4 # Common Development and Distribution License (the "License").
   5 # You may not use this file except in compliance with the License.
   6 #
   7 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
   8 # or http://www.opensolaris.org/os/licensing.
   9 # See the License for the specific language governing permissions
  10 # and limitations under the License.
  11 #
  12 # When distributing Covered Code, include this CDDL HEADER in each
  13 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  14 # If applicable, add the following below this CDDL HEADER, with the
  15 # fields enclosed by brackets "[]" replaced with your own identifying
  16 # information: Portions Copyright [yyyy] [name of copyright owner]
  17 #
  18 # CDDL HEADER END
  19 #
  20 #
  21 # Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  22 # Use is subject to license terms.
  23 #
  24 # lib/libunistat/Makefile
  25 
  26 include         ../Makefile.lib
  27 
  28 UTSBASE= ../../uts
  29 
  30 SUBDIRS=        $(MACH)
  31 
  32 all :=          TARGET= all
  33 clean :=        TARGET= clean
  34 clobber :=      TARGET= clobber
  35 delete :=       TARGET= delete
  36 install :=      TARGET= install
  37 lint :=         TARGET= lint
  38 lintinter :=            TARGET= lintinter
  39 _msg :=         TARGET= _msg
  40 package :=      TARGET= package
  41 
  42 LIBRARY=        libunistat.a
  43 
  44 HDRS=           spcs_dtrinkets.h \
  45                 spcs_etrinkets.h \
  46                 spcs_errors.h \
  47                 spcs_etext.h
  48 HDRDIR=         common
  49 
  50 ROOTHDRDIR=     $(ROOT)/usr/include/sys/unistat
  51 ROOTHDRS=       $(HDRS:%=$(ROOTHDRDIR)/%)
  52 
  53 .KEEP_STATE:
  54 
  55 all clean clobber delete lint package lintinter: $(SUBDIRS)
  56 
  57 install: $(SUBDIRS)
  58 install_h: $(ROOTHDRDIR) $(ROOTHDRS)
  59 
  60 check:
  61 
  62 # install rule for install_h target
  63 $(ROOTHDRDIR):
  64         $(INS.dir)
  65 
  66 $(ROOTHDRDIR)/spcs_errors.h: $(MACH)/spcs_errors.h
  67         $(INS.file) $(MACH)/spcs_errors.h
  68 
  69 $(MACH)/spcs_errors.h:  FRC
  70         @ cd $(MACH); pwd; $(MAKE) spcs_errors.h
  71 
  72 $(ROOTHDRDIR)/spcs_s_u.h: common/spcs_s_u.h
  73         $(INS.file) common/spcs_s_u.h
  74 
  75 $(ROOTHDRDIR)/spcs_etext.h: $(MACH)/spcs_etext.h
  76         $(INS.file) $(MACH)/spcs_etext.h
  77 
  78 $(MACH)/spcs_etext.h:   FRC
  79         @ cd $(MACH); pwd; $(MAKE) spcs_etext.h
  80 
  81 $(ROOTHDRDIR)/spcs_dtrinkets.h: $(MACH)/spcs_dtrinkets.h
  82         $(INS.file) $(MACH)/spcs_dtrinkets.h
  83 
  84 $(MACH)/spcs_dtrinkets.h:       FRC
  85         @ cd $(MACH); pwd; $(MAKE) spcs_dtrinkets.h
  86 
  87 $(ROOTHDRDIR)/spcs_etrinkets.h: $(MACH)/spcs_etrinkets.h
  88         $(INS.file) $(MACH)/spcs_etrinkets.h
  89 
  90 $(MACH)/spcs_etrinkets.h:       FRC
  91         @ cd $(MACH); pwd; $(MAKE) spcs_etrinkets.h
  92 
  93 $(MACH) $(MACH64):      FRC
  94         @cd $@; pwd; $(MAKE) $(TARGET)
  95 
  96 FRC: