components/stdcxx/Makefile
author Mike Sullivan <Mike.Sullivan@Oracle.COM>
Wed, 29 Aug 2012 11:05:56 -0700
changeset 957 255465c5756f
parent 800 2ad056ed89ec
child 1058 34d7aaa03423
permissions -rw-r--r--
Close of build 04.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
402
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     1
#
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     2
# CDDL HEADER START
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     3
#
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     4
# The contents of this file are subject to the terms of the
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     5
# Common Development and Distribution License (the "License").
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     6
# You may not use this file except in compliance with the License.
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     7
#
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     8
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     9
# or http://www.opensolaris.org/os/licensing.
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    10
# See the License for the specific language governing permissions
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    11
# and limitations under the License.
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    12
#
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    13
# When distributing Covered Code, include this CDDL HEADER in each
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    14
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    15
# If applicable, add the following below this CDDL HEADER, with the
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    16
# fields enclosed by brackets "[]" replaced with your own identifying
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    17
# information: Portions Copyright [yyyy] [name of copyright owner]
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    18
#
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    19
# CDDL HEADER END
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    20
#
774
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 609
diff changeset
    21
# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
402
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    22
#
774
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 609
diff changeset
    23
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 609
diff changeset
    24
# we really need to use studio so we don't like that
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 609
diff changeset
    25
# parfait is g++ in disguise
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 609
diff changeset
    26
PARFAIT_BUILD=no
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 609
diff changeset
    27
402
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    28
include ../../make-rules/shared-macros.mk
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    29
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    30
PATH=$(dir $(CC)):/usr/gnu/bin:/usr/bin
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    31
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    32
COMPONENT_NAME=		stdcxx
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    33
COMPONENT_VERSION=	4.2.1
609
775168282b2f 7037821 Userland migration of data from Makefile to manifest may have been a little overzealous
Rich Burridge <rich.burridge@oracle.com>
parents: 459
diff changeset
    34
COMPONENT_PROJECT_URL=	http://stdcxx.apache.org/
402
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    35
COMPONENT_SRC=		$(COMPONENT_NAME)-$(COMPONENT_VERSION)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    36
COMPONENT_PROJECT_URL=	http://stdcxx.apache.org/
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    37
COMPONENT_ARCHIVE=	$(COMPONENT_SRC).tar.gz
800
2ad056ed89ec 7163771 sha1 should not be used in userland-fetch and userland component/*/Makefile
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 774
diff changeset
    38
COMPONENT_ARCHIVE_HASH=	\
2ad056ed89ec 7163771 sha1 should not be used in userland-fetch and userland component/*/Makefile
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 774
diff changeset
    39
    sha256:00854223cbd947bf1bd85d9dabd1b2829706d9062e0007d5022082a5e4b7e15e
402
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    40
COMPONENT_ARCHIVE_URL=	http://www.apache.org/dist/stdcxx/$(COMPONENT_ARCHIVE)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    41
774
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 609
diff changeset
    42
CLOBBER_PATHS += install.sh
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 609
diff changeset
    43
402
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    44
include ../../make-rules/prep.mk
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    45
include ../../make-rules/configure.mk
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    46
include ../../make-rules/ips.mk
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    47
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    48
ISA_PATCH_DIR_32 = $(WS_TOP)/components/stdcxx/isa_patches/$(MACH)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    49
ISA_PATCH_DIR_64 = $(WS_TOP)/components/stdcxx/isa_patches/$(MACH64)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    50
ISA_PATCH_DIR = $(ISA_PATCH_DIR_$(BITS))
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    51
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    52
ISA_PATCHES_$(MACH) = \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    53
    $(ISA_PATCH_DIR)/1034-sunpro.config.$(MACH).patch \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    54
    $(ISA_PATCH_DIR)/1035-GNUmakefile.tst.$(MACH).patch \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    55
    $(ISA_PATCH_DIR)/1036-GNUmakefile.rwt.$(MACH).patch \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    56
    $(ISA_PATCH_DIR)/1037-GNUmakefile.lib.$(MACH).patch \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    57
    $(ISA_PATCH_DIR)/1038-GNUmakefile.ph.$(MACH).patch \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    58
    $(ISA_PATCH_DIR)/1039-GNUmakefile.exm.$(MACH).patch \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    59
    $(ISA_PATCH_DIR)/1040-GNUmakefile.cfg.$(MACH).patch \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    60
    $(ISA_PATCH_DIR)/1041-GNUmakefile.bin.$(MACH).patch
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    61
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    62
ISA_PATCHES_$(MACH64) = \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    63
    $(ISA_PATCH_DIR)/1034-sunpro.config.$(MACH64).patch \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    64
    $(ISA_PATCH_DIR)/1035-GNUmakefile.tst.$(MACH64).patch \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    65
    $(ISA_PATCH_DIR)/1036-GNUmakefile.rwt.$(MACH64).patch \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    66
    $(ISA_PATCH_DIR)/1037-GNUmakefile.lib.$(MACH64).patch \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    67
    $(ISA_PATCH_DIR)/1038-GNUmakefile.ph.$(MACH64).patch \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    68
    $(ISA_PATCH_DIR)/1039-GNUmakefile.exm.$(MACH64).patch \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    69
    $(ISA_PATCH_DIR)/1040-GNUmakefile.cfg.$(MACH64).patch \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    70
    $(ISA_PATCH_DIR)/1041-GNUmakefile.bin.$(MACH64).patch
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    71
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    72
ISA_PATCHES_32 = $(ISA_PATCHES_$(MACH))
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    73
ISA_PATCHES_64 = $(ISA_PATCHES_$(MACH64))
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    74
ISA_PATCHES = $(ISA_PATCHES_$(BITS))
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    75
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    76
PATCH_LEVEL = 1
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    77
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    78
TOPDIR = $(COMPONENT_DIR)/$(COMPONENT_SRC)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    79
LOCAL_BUILDDIR = $(TOPDIR)/build
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    80
MARG = -m$(BITS)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    81
PICFLAG = -KPIC -DPIC
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    82
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    83
# Please see the README file in this directory for a detailed explanation
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    84
# about these flags, what they do, and why we need them.
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    85
FLAGS_sparc = -m32 -xarch=sparcvis -xmemalign=8i
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    86
FLAGS_sparcv9 = -m64 -xarch=sparcvis -xmemalign=16i
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    87
FLAGS_i386 = -m32 -xarch=386
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    88
FLAGS_amd64 = -m64 -xarch=generic
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    89
CFLAGS_sparc = -Xc -features=extinl  -xvis=yes
459
c7579764bc73 7071286 workaround 7030022 (-xregs=no%appl not working on sparc)
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 402
diff changeset
    90
CFLAGS_sparc += -Qoption cg -xregs=no%appl -xbuiltin=%none -xO4 $(PICFLAG)
402
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    91
CFLAGS_i386 = -Xc -features=extinl -xregs=no%frameptr
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    92
CFLAGS_i386 += -xO3 -xbuiltin=%none $(PICFLAG)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    93
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    94
CFLAGS_32 = $(FLAGS_$(MACH)) $(CFLAGS_$(MACH))
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    95
CFLAGS_64 = $(FLAGS_$(MACH64)) $(CFLAGS_$(MACH))
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    96
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    97
CXXFLAGS_sparc = -xvis=yes -xregs=no%appl -xO4
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    98
CXXFLAGS_sparc +=  -xbuiltin=%none $(PICFLAG)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    99
CXXFLAGS_i386 = -xregs=no%frameptr -xO3  -xbuiltin=%none $(PICFLAG)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   100
CFLAGS_GENERIC += -xc99=%all 
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   101
CFLAGS_GENERIC += -mt -D_REENTRANT -DNDEBUG
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   102
CFLAGS_GENERIC += -D__EXTENSIONS__ -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   103
CFLAGS_GENERIC += -D_XPG6 -D_XOPEN_SOURCE=600 -D_POSIX_PTHREAD_SEMANTICS
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   104
CFLAGS_GENERIC += -D_POSIX_C_SOURCE=200112L -D__XOPEN_OR_POSIX
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   105
CFLAGS_GENERIC += -D_STRICT_STDC -D_STRICT_STDC__ -D_STDC_C99 -D_ISOC99_SOURCE
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   106
CFLAGS_GENERIC += -D_IN_BUILD_STDCXX
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   107
CFLAGS_GENERIC += $(CFLAGS_$(BITS))
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   108
CFLAGS = $(CFLAGS_GENERIC)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   109
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   110
CXXFLAGS_GENERIC = -library=Cstd -library=Crun -norunpath
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   111
CXXFLAGS_GENERIC += -Qoption ccfe ++boolflag:sunwcch=false
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   112
CXXFLAGS_GENERIC += -Qoption ccfe +d2,-xgeninl=system
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   113
CXXFLAGS_GENERIC += -Qoption ccfe -expand=10000
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   114
CXXFLAGS_GENERIC += -features=except,rtti,export,extensions,nestedaccess,tmplife,tmplrefstatic
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   115
CXXFLAGS_GENERIC += -instances=global
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   116
CXXFLAGS_GENERIC += -template=geninlinefuncs
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   117
CXXFLAGS_GENERIC += -verbose=template
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   118
CXXFLAGS_GENERIC += $(CXXFLAGS_$(MACH))
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   119
CXXFLAGS_GENERIC += -xlang=c99
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   120
CXXFLAGS_GENERIC += -xbuiltin=%none
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   121
CXXFLAGS_GENERIC += -xinline=
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   122
CXXFLAGS_GENERIC += -xlibmieee
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   123
CXXFLAGS_GENERIC += -xustr=ascii_utf16_ushort
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   124
CXXFLAGS_GENERIC += -z ignore $(PICFLAG)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   125
CXXFLAGS_GENERIC += -mt -D_REENTRANT -DNDEBUG
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   126
CXXFLAGS_GENERIC += -D_IN_BUILD_STDCXX
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   127
CXXFLAGS_GENERIC += -D__EXTENSIONS__
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   128
CXXFLAGS_GENERIC += -D_LARGEFILE_SOURCE
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   129
CXXFLAGS_GENERIC += -D_FILE_OFFSET_BITS=64
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   130
CXXFLAGS_GENERIC += -D_XOPEN_SOURCE=500
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   131
CXXFLAGS_GENERIC += -D_XPG5
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   132
CXXFLAGS_GENERIC += -D_POSIX_PTHREAD_SEMANTICS -s
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   133
CXXFLAGS_GENERIC += +w2 -errtags -erroff=hidef
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   134
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   135
CXXFLAGS_32 = $(FLAGS_$(MACH))
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   136
CXXFLAGS_64 = $(FLAGS_$(MACH64))
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   137
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   138
CXXFLAGS = $(CXXFLAGS_$(BITS)) $(CXXFLAGS_$(MACH)) $(CXXFLAGS_GENERIC)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   139
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   140
CPPFLAGS = -I$(TOPDIR)/include/ansi
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   141
CPPFLAGS += -I$(TOPDIR)/include/tr1
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   142
CPPFLAGS += -I$(TOPDIR)/include
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   143
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   144
# -mt will automatically pass -lthread unless we pass -lpthread
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   145
#  on link line. -lthread causes regressions. see man CC(1) and -mt.
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   146
#  -lumem must be passed before -lc.
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   147
LDFLAGS = -lpthread -lumem -lm -lc -s -z ignore
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   148
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   149
# We cannot have -B direct
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   150
LD_OPTIONS = -M /usr/lib/ld/map.noexstk -M /usr/lib/ld/map.noexdata 
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   151
LD_OPTIONS += -M /usr/lib/ld/map.pagealign
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   152
LD_OPTIONS += -lpthread -lumem -lm -lc -s -z ignore
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   153
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   154
# If I name it NLSPATH, gmake insists on getting its value from the
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   155
# running environment. Also, it all has to be on one line. += prepends
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   156
# a whitespace.
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   157
BUILD_NLSPATH = :%N.cat:/usr/lib/locale/%L/%N.cat:/usr/share/locale/%L/%N.cat:$(BUILD_DIR_$(BITS))/lib/rwstderr.cat
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   158
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   159
CONFIGURE_ENV = 	CC="$(CC)"
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   160
CONFIGURE_ENV +=	CXX="$(CXX)"
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   161
CONFIGURE_ENV +=	CFLAGS="$(CFLAGS)"
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   162
CONFIGURE_ENV +=	CPPFLAGS="$(CPPFLAGS)"
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   163
CONFIGURE_ENV +=	CXXFLAGS="$(CXXFLAGS)"
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   164
CONFIGURE_ENV +=	LDFLAGS="$(LDFLAGS)"
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   165
CONFIGURE_ENV +=	LD_OPTIONS="$(LD_OPTIONS)"
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   166
CONFIGURE_ENV +=	LD="$(CXX) $(CXXFLAGS) $(LDFLAGS)"
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   167
CONFIGURE_ENV +=	MAKE="$(MAKE)"
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   168
CONFIGURE_ENV +=	TOPDIR="$(TOPDIR)"
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   169
CONFIGURE_ENV +=	MAKEFLAGS=""
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   170
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   171
CONFIGURE_OPTIONS  =		$(MARG)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   172
CONFIGURE_OPTIONS  +=		-topdir=$(TOPDIR)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   173
CONFIGURE_OPTIONS  +=		-builddir=$(LOCAL_BUILDDIR)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   174
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   175
GCP = /usr/gnu/bin/cp
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   176
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   177
COMPONENT_BUILD_ENV =	MAKEFLAGS=""
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   178
COMPONENT_BUILD_ENV +=	MAKELEVEL=""
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   179
COMPONENT_BUILD_ENV +=	SHELL="/bin/bash"
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   180
COMPONENT_BUILD_ENV +=	NLSPATH="$(BUILD_NLSPATH)"
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   181
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   182
PKG_PROTO_DIRS += $(COMPONENT_DIR)/$(COMPONENT_SRC)-32
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   183
PKG_PROTO_DIRS += $(COMPONENT_DIR)/$(COMPONENT_SRC)-64
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   184
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   185
COMPONENT_PREP_ACTION = \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   186
    ( if test -f $(TOPDIR)/.unpacked ; then \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   187
	cd $(TOPDIR) ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   188
	else $(UNPACK) $(UNPACK_ARGS) $(COMPONENT_ARCHIVE) ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   189
	    $(TOUCH) $(TOPDIR)/.unpacked ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   190
	    cd $(TOPDIR) ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   191
	    fi ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   192
	list='$(ISA_PATCHES)' ; for f in $$list ; do \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   193
	$(GPATCH) $(GPATCH_FLAGS) <$$f ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   194
	    done  )
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   195
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   196
COMPONENT_PRE_CONFIGURE_ACTION = \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   197
    ( if test -f $(TOPDIR)/.unpacked ; then \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   198
	cd $(TOPDIR) ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   199
	else $(UNPACK) $(UNPACK_ARGS) $(COMPONENT_ARCHIVE) ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   200
	    $(TOUCH) $(TOPDIR)/.unpacked ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   201
	    cd $(TOPDIR) ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   202
	    list1='$(ISA_PATCHES)' ; for f in $$list1 ; do \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   203
	    $(GPATCH) $(GPATCH_FLAGS) <$$f ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   204
	    done ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   205
	    list2='$(PATCHES)' ; for f in $$list2 ; do \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   206
	    $(GPATCH) $(GPATCH_FLAGS) <$(COMPONENT_DIR)/$$f ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   207
	    done ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   208
	    $(TOUCH) $(TOPDIR)/.patched ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   209
	    fi ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   210
	$(CP) -Rp $(COMPONENT_DIR)/Solaris . ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   211
	$(CP) -p ./Solaris/configure . ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   212
	$(TOUCH) -acm ./configure ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   213
	$(CHMOD) 0755 ./configure )
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   214
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   215
COMPONENT_POST_CONFIGURE_ACTION = \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   216
    ( $(CLONEY) $(TOPDIR) $(@D) ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   217
    find ./$(COMPONENT_SRC) -type f -name "*.~1~" \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   218
	-exec chmod 0644 {} \; > /dev/null 2>&1 )
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   219
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   220
COMPONENT_POST_BUILD_ACTION = \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   221
    ( cd $(BUILD_DIR_$(BITS))/build ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   222
	$(GMAKE) locales ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   223
	cd $(TOPDIR) ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   224
	$(CP) -p $(COMPONENT_DIR)/Solaris/fix_nls_symlinks.sh . ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   225
	$(CHMOD) 0755 fix_nls_symlinks.sh ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   226
	$(SHELL) ./fix_nls_symlinks.sh ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   227
	cd $(COMPONENT_DIR) ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   228
	$(GCP) -rpd $(COMPONENT_SRC) $(COMPONENT_SRC)-$(BITS) ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   229
	$(RM) -rf $(COMPONENT_SRC) )
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   230
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   231
build: $(BUILD_32) $(BUILD_64)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   232
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   233
install: $(BUILD_DIR_32)/.built $(BUILD_DIR_64)/.built
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   234
	$(CP) $(COMPONENT_DIR)/Solaris/install.sh $(COMPONENT_DIR)/
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   235
	$(CHMOD) 0755 $(COMPONENT_DIR)/install.sh
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   236
	$(MKDIR) $(PROTO_DIR)/usr
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   237
	( $(SHELL) $(COMPONENT_DIR)/install.sh \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   238
	    -prefix=$(PROTO_DIR)/usr \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   239
	    -builddir=$(BUILD_DIR_32) \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   240
	    -componentdir=$(COMPONENT_DIR) \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   241
	    -componentsrc=$(COMPONENT_SRC) \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   242
	    -srcdir=$(TOPDIR)-32 )
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   243
	( $(SHELL) $(COMPONENT_DIR)/install.sh \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   244
	    -prefix=$(PROTO_DIR)/usr \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   245
	    -builddir=$(BUILD_DIR_64) \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   246
	    -componentdir=$(COMPONENT_DIR) \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   247
	    -componentsrc=$(COMPONENT_SRC) \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   248
	    -srcdir=$(TOPDIR)-64 \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   249
	    -mach64=$(MACH64) )
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   250
	test -d $(TOPDIR) || $(MKDIR) $(TOPDIR)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   251
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   252
test:
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   253
	test -d $(BUILD_DIR_32) || echo "$(BUILD_DIR_32) does not exist!"
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   254
	test -d $(BUILD_DIR_64) || echo "$(BUILD_DIR_64) does not exist!"
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   255
	$(CP) -p $(COMPONENT_DIR)/Solaris/prep_build_area.sh \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   256
	    $(COMPONENT_DIR)/
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   257
	$(CHMOD) 0755 $(COMPONENT_DIR)/prep_build_area.sh
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   258
	$(SHELL) $(COMPONENT_DIR)/prep_build_area.sh -m32 \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   259
	    -builddir=$(BUILD_DIR_32) \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   260
	    -srcdir=$(TOPDIR)-32
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   261
	$(SHELL) $(COMPONENT_DIR)/prep_build_area.sh -m64 \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   262
	    -builddir=$(BUILD_DIR_64) \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   263
	    -srcdir=$(TOPDIR)-64
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   264
	( cd $(BUILD_DIR_32)/build/tests ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   265
	    $(CP) -p $(COMPONENT_DIR)/Solaris/run_tests.sh . ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   266
	    $(CHMOD) 0755 run_tests.sh ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   267
	    $(SHELL) ./run_tests.sh > \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   268
		$(COMPONENT_DIR)/runtests-$(MACH).out 2>&1 )
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   269
	( cd $(BUILD_DIR_64)/build/tests ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   270
	    $(CP) -p $(COMPONENT_DIR)/Solaris/run_tests.sh . ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   271
	    $(CHMOD) 0755 run_tests.sh ; \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   272
	    $(SHELL) ./run_tests.sh > \
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   273
		$(COMPONENT_DIR)/runtests-$(MACH64).out 2>&1 )
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   274
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   275
clean::
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   276
	$(RM) -r $(COMPONENT_SRC) $(COMPONENT_SRC)-32 $(COMPONENT_SRC)-64
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   277
	$(RM) -f *.sed *.out
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   278
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   279
BUILD_PKG_DEPENDENCIES = $(BUILD_TOOLS)
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   280
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   281
include ../../make-rules/depend.mk
94ae4d75524c 7064836 stdcxx to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
   282