Home | History | Annotate | Download | only in pkgdefs
      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	"%Z%%M%	%I%	%E% SMI"
     27 #
     28 
     29 pkginfo: pkginfo.tmpl $(PKGDEFS)/awk_pkginfo
     30 	$(RM) $@; nawk -f $(PKGDEFS)/awk_pkginfo $@.tmpl > $@
     31 
     32 pkg: $(PKGARCHIVE) FRC
     33 	pkgmk -f prototype_$(MACH) -d $(PKGARCHIVE) \
     34 	    -r "$(ROOT) $(PARENT_ROOT)" -o $(PACKAGE)
     35 
     36 optpkg: $(PKGARCHIVE) FRC
     37 	pkgmk -f prototype_$(MACH) -d $(PKGARCHIVE) \
     38 	    -r "$(ROOT) $(PARENT_ROOT)" -b opt -o $(PACKAGE)
     39 
     40 $(PKGARCHIVE):
     41 	[ -d $(PKGARCHIVE) ] || mkdir -p $(PKGARCHIVE)
     42 
     43 $(CHKINSTALL): $(PKGDEFS)/common_files/$(CHKINSTALLSRC)
     44 	$(RM) $(CHKINSTALL)
     45 	cp $(PKGDEFS)/common_files/$(CHKINSTALLSRC) $(CHKINSTALL)
     46 
     47 
     48 copyright: $(BUILDPKGCR) $(LICENSEFILES)
     49 	@$(DO_BUILDPKGCR)
     50 
     51 # If the file is under SCCS, then it should not be destroyed
     52 # by an install rule here.  This is a mistake in package makefile.
     53 $(DATAFILES): $(PKGDEFS)/common_files/$$@
     54 	@[ ! -f SCCS/s.$@ ] || \
     55 		( $(ECHO) "DATAFILES list is incorrect for $@">&2 && false )
     56 	$(RM) $@; cp $(PKGDEFS)/common_files/$@ $@
     57 
     58 $(MACHDATAFILES): $(PKGDEFS)/common_files/$$@_$(MACH)
     59 	$(RM) $@; cp $(PKGDEFS)/common_files/$@_$(MACH) $@
     60 
     61 clean: 
     62 	-$(RM) $(CLEANFILES)
     63 
     64 clobber: clean
     65 	-$(RM) $(CLOBBERFILES)
     66 
     67 FRC:
     68