30990c446eca5b0d16d42171a6b30da9456ff6b4trawick# CDDL HEADER START
30990c446eca5b0d16d42171a6b30da9456ff6b4trawick# The contents of this file are subject to the terms of the
0fd9de72e2a1be5a6134ee70703324be80d816b7trawick# Common Development and Distribution License (the "License").
0fd9de72e2a1be5a6134ee70703324be80d816b7trawick# You may not use this file except in compliance with the License.
0fd9de72e2a1be5a6134ee70703324be80d816b7trawick# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
f36d2c405b5a9bcc22c67577995560e7d1b616c0aaron# See the License for the specific language governing permissions
2213cc395cb461faf7bfeb187ebb61d97cd457efjerenkrantz# and limitations under the License.
854c7bc4128fa2ad9fdfe0fc307d5ef30bcb5bb9wrowe# When distributing Covered Code, include this CDDL HEADER in each
854c7bc4128fa2ad9fdfe0fc307d5ef30bcb5bb9wrowe# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
854c7bc4128fa2ad9fdfe0fc307d5ef30bcb5bb9wrowe# If applicable, add the following below this CDDL HEADER, with the
854c7bc4128fa2ad9fdfe0fc307d5ef30bcb5bb9wrowe# fields enclosed by brackets "[]" replaced with your own identifying
854c7bc4128fa2ad9fdfe0fc307d5ef30bcb5bb9wrowe# information: Portions Copyright [yyyy] [name of copyright owner]
854c7bc4128fa2ad9fdfe0fc307d5ef30bcb5bb9wrowe# CDDL HEADER END
854c7bc4128fa2ad9fdfe0fc307d5ef30bcb5bb9wrowe# Copyright (c) 2009, 2011, Oracle and/or its affiliates. All rights reserved.
2a6e98ba4ffa30ded5d8831664c5cb2a170a56b6coar export LD_LIBRARY_PATH="${BUILDDIR}/lib:${LD_LIBRARY_PATH}"
1f279dc92a60df9f61bf58468162aab0eef072e4brianp if [ -f config.done ] ; then
2fd0edbd8b2f47a8458322bedd3b82f825faf336trawick if [ "x${BUILDTYPE}" = "x" ] || [ "x${TOPLEVELDIR}" = "x" ] ; then
39021cf8b495cdb94013ca73531ccb32658fb793rederpj if [ "$PRINT_HELP" = "yes" ] || [ "$UNKNOWN_ARG" = "yes" ] ; then
39021cf8b495cdb94013ca73531ccb32658fb793rederpj echo "Usage: `basename $0` [ -m32 | -m64 ] --topdir=[ \$(top_srcdir) ]"
fa16f10bc02e46bc5a6c2c2c6371926cd1dbe2edwrowe if [ ! -d Solaris ] ; then
fa16f10bc02e46bc5a6c2c2c6371926cd1dbe2edwrowe echo "Make sure this directory exists in the stdcxx toplevel."
6e119e632566d69798ce6cf4e714ed374b72914frederpj echo "\$CXXFLAGS is not set. Make sure you have set -library=no%Cstd."
a5ca705e053a6c754c5958aafcd6f0aa60a2e67frbb echo "\$MAKE is not set. Please use GNU make to build stdcxx."
481c1206b6065a8f37ab75ca1fc26c947cb37852ianh echo "\$MAKE is not GNU make. stdcxx requires GNU make."
7e31ef4870c7ef94838585004405e8854fefcc51ianh if [ -f ./include/ansi/$file ] ; then
a8c401eadf77822e851f19c7740e7ec6dca03daastoddard if [ -f ./include/tr1/$file ] ; then
2ffa5829cad36f12b0a1fc3481592e85bc210a5bjerenkrantz if [ -f ./include/tr1/${file} ] ; then
61202a45487668abad788c02e339f626176e645fianh echo "${CXX} ${CPPFLAGS} ${CXXFLAGS} -c ${TOPLEVELDIR}/etc/config/src/${file}.cpp -o ${LIBDIR}/${file}.o"
61202a45487668abad788c02e339f626176e645fianh ${CXX} ${CPPFLAGS} ${CXXFLAGS} -c ${TOPLEVELDIR}/etc/config/src/${file}.cpp -o ${LIBDIR}/${file}.o
02c49e1f35a4d1a171df2d319e76af0c5163dc4dmartin echo "${CXX} ${CXXFLAGS} ${LDFLAGS} -G -hlib${file}.so ${LIBDIR}/${file}.o -o ${LIBDIR}/lib${file}.so"
02c49e1f35a4d1a171df2d319e76af0c5163dc4dmartin ${CXX} ${CXXFLAGS} ${LDFLAGS} -G -h${file}.so ${LIBDIR}/${file}.o -o ${LIBDIR}/lib${file}.so
6deb8bcfb8511ac38243a8274fc589842841b398ianh export LD_OPTIONS="-L${TOPLEVELDIR}/lib -R${TOPLEVELDIR}/lib"
49bbbd1939208be54a3eb00b95e61d90d180a606ianh export LD_OPTIONS="${LD_OPTIONS} -L${BUILDDIR}/include -R${BUILDDIR}/include"
93d7153aa172665f55b04463b831ad556269c3efbrianp echo $MAKE SHELL=/bin/bash CC=${CC} CXX=${CXX} LD_OPTIONS="${LD_OPTIONS}" LDFLAGS="${LDFLAGS} ${LD_OPTIONS}" TOPDIR=${TOPLEVELDIR} BUILDTYPE=${BUILDTYPE} BUILDMODE=${BUILDMODE} CONFIG=${CONFIG} config
93d7153aa172665f55b04463b831ad556269c3efbrianp ${MAKE} SHELL=/bin/bash CC="${CC}" CXX="${CXX}" LD_OPTIONS="${LD_OPTIONS}" LDFLAGS="${LDFLAGS} ${LD_OPTIONS}" TOPDIR="${TOPLEVELDIR}" BUILDTYPE="${BUILDTYPE}" BUILDMODE="${BUILDMODE}" CONFIG="${CONFIG}" config
bc6600a6207e5d15b895294e370e4e3320a803d8stoddard if [ ! -f ../Solaris/atomic-cxx.d ] ; then
9f20717d827f2113a23dfa45539813171cf626eaianh if [ -f config.h ] ; then
0bbb249eafe9ef9508821f0ef58e7440625ecd62trawick if [ ! -f ../../Solaris/${HEADER_FILE} ] ; then
61afed048a4d67ed923d52e5c865c0f10a8e9e73trawick echo "Required configuration header file ${HEADER_FILE} not found!"
7a23067e782dd5612d4d4b539906e1733b664df7jwoolley echo "Using configuration header file ${HEADER_FILE}"
ec69fc6e323eb1f3112966e06e9e37be608d052cianh if [ -f "${TOPLEVELDIR}/../Solaris/rwconfig_std.h" ] ; then
749011213737e8d0cd6ca78d5eb532ec6f6b9fdfianh echo "Removing configuration phase core files [expected]."
e7bf4d6f15d04e86e20002e65f60d7fbf80e5974stoddard echo "Standard configuration file ${TOPLEVELDIR}/../Solaris/rwconfig_std.h not found!"
de42d3dfd83a4cc62f0dd6b79ee5cbcfa69fd503brianp echo "Initial configuration file 'config.h' has not been created."
39dde7f4cd79d701cc14e5beac8ea528bc58d038wrowe echo "stdcxx has been configured. You can now type '$MAKE' to build."