Home | History | Annotate | Download | only in lib
      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, Version 1.0 only
      6 # (the "License").  You may not use this file except in compliance
      7 # with the License.
      8 #
      9 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
     10 # or http://www.opensolaris.org/os/licensing.
     11 # See the License for the specific language governing permissions
     12 # and limitations under the License.
     13 #
     14 # When distributing Covered Code, include this CDDL HEADER in each
     15 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
     16 # If applicable, add the following below this CDDL HEADER, with the
     17 # fields enclosed by brackets "[]" replaced with your own identifying
     18 # information: Portions Copyright [yyyy] [name of copyright owner]
     19 #
     20 # CDDL HEADER END
     21 #
     22 #
     23 # Copyright 2004 Sun Microsystems, Inc.  All rights reserved.
     24 # Use is subject to license terms.
     25 #
     26 # ident	"%Z%%M%	%I%	%E% SMI"
     27 #
     28 
     29 include Makefile.com
     30 
     31 i386_SUBDIRS = fs/pcfs fs/compfs
     32 sparc_SUBDIRS = md5 nvpair scrypt wanboot crypto ssl
     33 SUBDIRS = fakeboot fs/hsfs fs/nfs fs/ufs inet sa sock tcpstubs xdr \
     34 	tcp $($(MACH)_SUBDIRS)
     35 
     36 #
     37 # It would be groovy if everything was lint-clean, but the crypto and ssl
     38 # code is third-party swill out of our jurisdiction.  Also, don't lint
     39 # fakeboot since it doesn't have any source files.
     40 #
     41 # If someone can come up with a more elegant way to strip these
     42 # directories out, please make it so.
     43 #
     44 LINTSUBDIRS1 = $(SUBDIRS:ssl=)
     45 LINTSUBDIRS2 = $(LINTSUBDIRS1:crypto=)
     46 LINTSUBDIRS  = $(LINTSUBDIRS2:fakeboot=)
     47 
     48 #
     49 # We can get away with this since we're only building .a's, and by the
     50 # time we run lint all of the lint libraries have already been built.
     51 #
     52 .PARALLEL: $(SUBDIRS)
     53 
     54 .KEEP_STATE:
     55 
     56 all	:=	TARGET = all
     57 clean	:=	TARGET = clean
     58 clobber	:=	TARGET = clobber
     59 install	:=	TARGET = install
     60 lint	:=	TARGET = lint
     61 
     62 all clean clobber install: $(SUBDIRS)
     63 
     64 lint: $(LINTSUBDIRS)
     65 
     66 #
     67 # The reason this rule checks for the existence of the
     68 # Makefile is that some of the directories do not exist
     69 # in our exportable source builds.
     70 #
     71 $(SUBDIRS): FRC
     72 	@if [ -f $@/Makefile  ]; then \
     73 		cd $@; pwd; $(MAKE) $(TARGET); \
     74 	else \
     75 		true; \
     76 	fi
     77 
     78 FRC:
     79 
     80 #
     81 # Cross-reference customization: set the include path to be reasonable.
     82 #
     83 XRINCDIRS = $(CPPINCS:-YI,%=-I%)
     84