1 # 2 # 3 # CDDL HEADER START 4 # 5 # The contents of this file are subject to the terms of the 6 # Common Development and Distribution License (the "License"). 7 # You may not use this file except in compliance 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 # Copyright 2008 Sun Microsystems, Inc. All rights reserved. 23 # Use is subject to license terms. 24 # 25 #ident "@(#)Makefile.sfw 1.9 08/02/09 SMI" 26 # 27 28 VER=bison-2.3 29 VER64=$(VER)-64 30 31 include ../Makefile.cmd 32 33 SFW_PATH="$(SPRO_VROOT)/bin:/usr/perl5/bin:/usr/sfw/bin:/usr/bin:/usr/ccs/bin" 34 35 all: real-all 36 37 all32: $(VER)/config.status 38 (cd $(VER); env - \ 39 CC=$(CC) \ 40 "CFLAGS=$(CFLAGS)" \ 41 PATH=$(SFW_PATH) \ 42 LD_OPTIONS="-M $(SRC)/cmd/mapfile_noexstk" \ 43 MAKE=$(CCSMAKE) $(CCSMAKE)) 44 @find . -name core -exec rm -f {} \; 45 46 all64: $(VER64)/config.status 47 (cd $(VER64)/lib; env - \ 48 CC=$(CC64) \ 49 "CFLAGS=$(CFLAGS64)" \ 50 PATH=$(SFW_PATH) \ 51 LD_OPTIONS="-M $(SRC)/cmd/mapfile_noexstk" \ 52 MAKE=$(CCSMAKE) $(CCSMAKE) liby.so.1) 53 @find . -name core -exec rm -f {} \; 54 55 install: all 56 $(SH) ./install-bison 57 MACH64=$(MACH64) $(SH) ./install-bison-64 58 59 real-all: all32 all64 60 61 $(VER)/config.status: $(VER)/configure 62 (cd $(VER); env - \ 63 CC=$(CC) \ 64 "CFLAGS=$(CFLAGS)" \ 65 PATH=$(SFW_PATH) \ 66 MAKE=$(CCSMAKE) \ 67 ./configure --prefix=/usr) 68 69 $(VER64)/config.status: $(VER64)/configure 70 (cd $(VER64); env - \ 71 CC=$(CC64) \ 72 "CFLAGS=$(CFLAGS64)" \ 73 PATH=$(SFW_PATH) \ 74 MAKE=$(CCSMAKE) \ 75 ./configure --prefix=/usr) 76 77 $(VER)/configure: $(VER).tar.gz 78 mkdir -p tmp; gzip -dc $(VER).tar.gz | \ 79 (cd tmp; $(GTAR) xpf - --no-same-owner) 80 mv tmp/$(VER) $(VER); rmdir tmp 81 touch $(VER)/configure 82 find $(VER) -type d -exec /usr/bin/chmod 755 "{}" \; 83 find $(VER) -type f -exec /usr/bin/chmod ugo+r "{}" \; 84 (cd $(VER); gpatch -p1 <../patch) 85 86 $(VER64)/configure: $(VER).tar.gz 87 mkdir -p tmp; gzip -dc $(VER).tar.gz | \ 88 (cd tmp; $(GTAR) xpf - --no-same-owner) 89 mv tmp/$(VER) $(VER64); rmdir tmp 90 touch $(VER64)/configure 91 find $(VER64) -type d -exec /usr/bin/chmod 755 "{}" \; 92 find $(VER64) -type f -exec /usr/bin/chmod ugo+r "{}" \; 93 (cd $(VER64); gpatch -p1 <../patch) 94 95 clean: 96 -rm -rf $(VER) 97 -rm -rf $(VER64) 98 99 include ../Makefile.targ 100 101 FRC: 102