# $Id: PKGBUILD 72545 2010-03-18 13:05:20Z ibiru $ # Maintainer: kevin # Contributor: Giovanni Scafora # TU: Kritoke # Contributor: Luca Roccia pkgname=('boost' 'boost-libs') pkgbase='boost' pkgver=1.41.0 _boostver=1_41_0 pkgrel=1 pkgdesc="Free peer-reviewed portable C++ source libraries" arch=('i686' 'x86_64') url="http://www.boost.org/" depends=('bzip2' 'zlib') makedepends=('python>=2.6') optdepends=('python: for python bindings') source=(http://downloads.sourceforge.net/sourceforge/${pkgbase}/${pkgbase}_${_boostver}.tar.gz fix-gzip-crc.patch serialization_fix.patch) license=('custom') options=('!ccache' 'force') _stagedir=$srcdir/stagedir package_boost() { install -dm 755 ${pkgdir}/usr/{include,lib} # headers/source files cp -r ${_stagedir}/include/ ${pkgdir}/usr/ # static libs cp -r ${_stagedir}/lib/*.a ${pkgdir}/usr/lib/ # utilities (bjam, bcp, pyste), license cp -r ${_stagedir}/usr/* ${pkgdir}/usr/ } package_boost-libs() { install -dm 755 ${pkgdir}/usr/{share/licenses/${pkgbase}-libs,lib} # license cp ${_stagedir}/usr/share/licenses/${pkgbase}/* \ ${pkgdir}/usr/share/licenses/${pkgbase}-libs/ # shared libs cp -r ${_stagedir}/lib/*.so{,.*} ${pkgdir}/usr/lib/ } build() { cd "${srcdir}/${pkgbase}_${_boostver}" # patch -Np1 -i ${srcdir}/fix-gzip-crc.patch || return 1 # patch -Np1 -i ${srcdir}/serialization_fix.patch || return 1 # build bjam cd ${srcdir}/${pkgbase}_${_boostver}/tools/jam/src ./build.sh cc || return 1 _bindir="bin.linuxx86" [ "${CARCH}" = "x86_64" ] && _bindir="bin.linuxx86_64" install -m755 -d ${_stagedir}/usr/bin install -m755 ${_bindir}/bjam ${_stagedir}/usr/bin/bjam || return 1 # build bcp cd ${srcdir}/${pkgbase}_${_boostver}/tools/bcp ../jam/src/${_bindir}/bjam || return 1 install -m755 ${srcdir}/${pkgbase}_${_boostver}/dist/bin/bcp \ ${_stagedir}/usr/bin/bcp || return 1 # build libs cd ${srcdir}/${pkgbase}_${_boostver} # default "minimal" install: "release link=shared,static # runtime-link=shared threading=multi" # --layout=tagged will add the "-mt" suffix for multithreaded libraries # and installs includes in /usr/include/boost. # --layout=system no longer adds the -mt suffix for multi-threaded libs. # install to ${_stagedir} in preparation for split packaging ./tools/jam/src/${_bindir}/bjam \ release debug-symbols=off threading=single,multi \ runtime-link=shared link=shared,static \ cflags=-fno-strict-aliasing \ --prefix=${_stagedir} \ -sPYTHON_ROOT=/usr \ -sPYTHON_VERSION=2.6 \ -sTOOLS=gcc \ --layout=tagged \ install || return 1 # build pyste cd ${srcdir}/${pkgbase}_${_boostver}/libs/python/pyste/install python setup.py install --root=${_stagedir} || return 1 # license install -m755 -d ${_stagedir}/usr/share/licenses/${pkgbase} install -m644 ${srcdir}/${pkgbase}_${_boostver}/LICENSE_1_0.txt \ ${_stagedir}/usr/share/licenses/${pkgbase}/ || return 1 } md5sums=('ddb04c9b9164a36a91dcf36819666dd9' '682f124a765b2935c7352f38c08848cc' '01337211d40a4a4c9b83c481baade701')