From a2c95fd54ba85609df061ea917af82f6b62e41ab Mon Sep 17 00:00:00 2001 From: Daniel Joseph Barnhart Clark Date: Sun, 9 Jul 2006 20:39:58 +0000 Subject: Initial checkin of bcfg2-encap-boostrap code to mcs svn. git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@1917 ce84e21b-d406-0410-9b95-82705330c041 --- encap/bcfg2-libstdc++-0.1.sh | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100755 encap/bcfg2-libstdc++-0.1.sh (limited to 'encap/bcfg2-libstdc++-0.1.sh') diff --git a/encap/bcfg2-libstdc++-0.1.sh b/encap/bcfg2-libstdc++-0.1.sh new file mode 100755 index 000000000..6b3fe4a98 --- /dev/null +++ b/encap/bcfg2-libstdc++-0.1.sh @@ -0,0 +1,34 @@ +#!/bin/sh +# $Id$ + +# Creates encap of libstdc++ libraries from build machine so other machines +# don't need to have g++ installed, or in the case of GNU/Linux so we're +# using a consistant libstdc++ version everywhere. + +ENCAP_SOURCE=${ENCAPDIR} +ENCAP_PKGNAME=bcfg2-libstdc++-0.1 +PATH=$PATH:/usr/local/bin +export PATH + +if [ "${ENCAP_SOURCE}x" = "x" ]; then + printf "Error in ${ENCAP_PKGNAME}.sh : ENCAPDIR not set, exiting...\n" + exit 1 +fi + +umask 022 + +CXXBASE=`which g++ | xargs dirname | xargs dirname` +for LIB in `cd ${CXXBASE} && find lib | grep libstdc++`; do + cd ${CXXBASE} + LIBDIR=`dirname ${LIB}` + NEWDIR=${ENCAP_SOURCE}/${ENCAP_PKGNAME}/lib/bcfg2/${LIBDIR} + if [ ! -d ${NEWDIR} ]; then mkdir -p ${NEWDIR}; fi + cp -p ${LIB} ${NEWDIR} +done + +SDIR=${ENCAP_SOURCE}/${ENCAP_PKGNAME}/var/encap +mkdir -p ${SDIR} +touch ${SDIR}/${ENCAP_PKGNAME} + +exit 0 + -- cgit v1.2.3-1-g7c22