Home | History | Annotate | Download | only in tools
      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 2007 Sun Microsystems, Inc.  All rights reserved.
     23 # Use is subject to license terms.
     24 #
     25 # ident	"%Z%%M%	%I%	%E% SMI"
     26 #
     27 # Definitions common to tool source.
     28 #
     29 include $(SRC)/Makefile.master
     30 
     31 FILEMODE=	0555
     32 
     33 TOOLS=			$(SRC)/tools
     34 TOOLS_PROTO=		$(TOOLS)/proto
     35 ROOTONBLD=		$(TOOLS_PROTO)/opt/onbld
     36 ROOTONBLDBIN=		$(ROOTONBLD)/bin
     37 ROOTONBLDBINMACH=	$(ROOTONBLD)/bin/$(MACH)
     38 ROOTONBLDLIB=		$(ROOTONBLD)/lib
     39 ROOTONBLDLIBMACH=	$(ROOTONBLD)/lib/$(MACH)
     40 ROOTONBLDENV=		$(ROOTONBLD)/env
     41 ROOTONBLDGK=		$(ROOTONBLD)/gk
     42 ROOTONBLDMAN=		$(ROOTONBLD)/man
     43 ROOTONBLDMAN1=		$(ROOTONBLD)/man/man1
     44 ROOTONBLDETCABI=	$(ROOTONBLD)/etc/abi
     45 
     46 CPPFLAGS=		-D_TS_ERRNO
     47 ELFSIGN_O=		$(TRUE)
     48 LDLIBS=
     49 LDFLAGS=		$(MAPFILE.NES:%=-M%) $(MAPFILE.NED:%=-M%) \
     50 			    $(MAPFILE.PGA:%=-M%)
     51 
     52 ROOTONBLDPROG=		$(PROG:%=$(ROOTONBLDBIN)/%)
     53 ROOTONBLDMACHPROG=	$(PROG:%=$(ROOTONBLDBINMACH)/%)
     54 ROOTONBLDSHFILES=	$(SHFILES:%=$(ROOTONBLDBIN)/%)
     55 ROOTONBLDMAKEFILES=	$(MAKEFILES:%=$(ROOTONBLDBIN)/%)
     56 ROOTONBLDMACHSHFILES=	$(SHFILES:%=$(ROOTONBLDBINMACH)/%)
     57 ROOTONBLDMACHBINARIES=	$(BINARIES:%=$(ROOTONBLDBINMACH)/%)
     58 ROOTONBLDENVFILES=	$(ENVFILES:%=$(ROOTONBLDENV)/%)
     59 ROOTONBLDGKFILES=	$(GKFILES:%=$(ROOTONBLDGK)/.%)
     60 ROOTONBLDPERLFILES=	$(PERLFILES:%=$(ROOTONBLDBIN)/%)
     61 ROOTONBLDPYFILES=	$(PYFILES:%=$(ROOTONBLDBIN)/%)
     62 ROOTONBLDMAN1FILES=	$(MAN1FILES:%=$(ROOTONBLDMAN1)/%)
     63 ROOTONBLDABIAUDITFILES=	$(ABI_AUDITFILES:%=$(ROOTONBLDETCABI)/%)
     64 
     65 # Break a chicken-and-egg dependency cycle for the tools build
     66 SCCSCHECK=@echo would sccscheck
     67 
     68 $(ROOTONBLDETCABI)/%: %
     69 	$(INS.file)
     70 
     71 $(ROOTONBLDBIN)/%: %
     72 	$(INS.file)
     73 
     74 $(ROOTONBLDBINMACH)/%: %
     75 	$(INS.file)
     76 
     77 $(ROOTONBLDMAN1)/%: %
     78 	$(INS.file)
     79 
     80 $(ROOTONBLDENV)/%: %
     81 	$(INS.file)
     82 
     83 $(ROOTONBLDGK)/.%: %
     84 	$(INS.rename)
     85