Home | History | Annotate | Download | only in nfsv4
      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 #
     23 # Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
     24 # Use is subject to license terms.
     25 #
     26 # ident	"@(#)Makefile	1.1	08/11/14 SMI"
     27 #
     28 # nfsv4-test Top Level Test Suite Makefile
     29 #
     30 
     31 # $TESTROOT must be set or current directory must be at the suite level
     32 TESTROOT:sh=	pwd
     33 SUBDIRS=	tests server nfsv4shell
     34 
     35 all :=          TARGET= all
     36 install :=      TARGET= install
     37 clean :=        TARGET= clean
     38 clobber :=      TARGET= clobber
     39 
     40 SHFILES=	runit runtests go_setup srv_setup go_cleanup
     41 DATAFILES=	README nfs4test.env tcl.init libsmf.sh STC.INFO
     42 MAKEFILES=	Makefile Makefile.master Makefile.targets
     43 NFSHFILES=	nfsh tclprocs
     44 
     45 CLEANFILES=	$(SHFILES)
     46 CLOBBERFILES=	core $(NFSHFILES)
     47 
     48 include 	Makefile.master
     49 
     50 all: 		$(SUBDIRS) $(SHFILES)
     51 
     52 install:  	$(SUBDIRS) $(SHFILES) $(EXEDIR) \
     53 		$(TOPSHFILES) $(TOPDATAFILES) $(TOPMAKEFILES) \
     54 		$(NFSHFILES)
     55 
     56 package:  	$(EXEDIR) $(PKGNAME)
     57 
     58 $(EXEDIR):
     59 	$(INS.dir)
     60 
     61 $(NFSHFILES): nfsv4shell
     62 	$(RM) $(EXEDIR)/$@
     63 	$(CP) nfsv4shell/bin/$@ $(EXEDIR)
     64 	$(CHMOD) $(FILEMODE) $(EXEDIR)/$@
     65 
     66 $(PKGNAME): pkgs FRC
     67 	cd pkgs; pwd; $(MAKE) install TESTROOT=${TESTROOT}
     68 
     69 clean: $(SUBDIRS)
     70 	-$(RM) $(CLEANFILES)
     71 
     72 clobber: $(SUBDIRS) pkgs
     73 	-$(RM) $(CLEANFILES) $(CLOBBERFILES)
     74 
     75 uninstall:
     76 	-[ -d $(EXEDIR) ] && $(RM) $(EXEDIR)
     77 
     78 unpackage:
     79 	-[ -d $(PKG_PATH)/$(PKGNAME) ] && $(RM) $(PKG_PATH)/$(PKGNAME)
     80 
     81 $(SUBDIRS) pkgs: FRC
     82 	if [ -d $@ ]; then \
     83 		(cd $@; pwd; \
     84 		$(MAKE) -e $(TARGET) TESTROOT=$(TESTROOT) \
     85 			__GNUC=$(__GNUC) __SS12=$(__SS12) );\
     86 	fi
     87 
     88 FRC:
     89