Home | History | Annotate | Download | only in dosbox
      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 2009 Sun Microsystems, Inc.  All rights reserved.
     24 # Use is subject to license terms.
     25 #
     26 #ident	"@(#)Makefile.sfw	1.2	09/08/23 SMI"
     27 #
     28 
     29 include ../Makefile.cmd
     30 
     31 VER =		$(COMPONENT_NAME:sh)-$(COMPONENT_VERSION:sh)
     32 TARBALL =	$(VER).tar.gz
     33 PATCHES:sh =    echo Patches/*.diff
     34 PATCHES:sh +=   uname -p | grep sparc > /dev/null && echo Patches/*.diff_sparc || echo
     35 
     36 GPATCH_FLAGS=-p1
     37 
     38 #       configure(1) options to use
     39 # a default --prefix and --mandir are set in Makefile.master
     40 
     41 
     42 TARGET_ENV +=   CC="$(GCC)"
     43 TARGET_ENV +=   CXX="$(GXX)"
     44 TARGET_ENV +=   LD_OPTIONS="-M $(SRC)/cmd/mapfile_noexstk"
     45 TARGET_ENV +=   MAKE="$(CCSMAKE)"
     46 TARGET_ENV +=   PATH=$(SFW_PATH)
     47 TARGET_ENV +=	INSTALL="$(INSTALL_PROTO)"
     48 TARGET_ENV +=   MANSCRIPT="$(COMPONENT_TOP)/sunman-stability"
     49 
     50 all:=		TARGET = all
     51 install:=	TARGET = install
     52 install:=	TARGET_ENV += DESTDIR=$(ROOT)
     53 install:=	TARGET_ENV += localedir="$(CFGLOCALE)"
     54 
     55 all: $(VER)/config.status
     56 	(cd $(VER); env - $(CCSMAKE) $(TARGET) $(TARGET_ENV))
     57 
     58 install: install-protofix
     59 
     60 install-target: $(VER)/config.status
     61 	(cd $(VER); env - $(CCSMAKE) $(TARGET) $(TARGET_ENV))
     62 
     63 install-protofix: install-target
     64 	for pkg in $(COMPONENT_PACKAGES:sh) ; do \
     65 		$(SRC)/tools/protofix --pkg $$pkg --perm ; \
     66 	done
     67 	
     68 $(VER)/config.status: $(VER)/.patched
     69 	(cd $(VER); env - \
     70 	    ./configure $(CONFIGURE_OPTIONS) $(TARGET_ENV))
     71 
     72 clean:
     73 	-rm -rf $(VER)
     74 
     75 include ../Makefile.targ
     76 
     77 FRC:
     78