# SliTaz package receipt. # Boost is a set of two types of libraries. Most of them are just # headers with inline functions, these are included in this package # named libboost-dev. Some few set of libraries require build and # installation steps. These will be relocated and have their own two # packages : libboost-name and libboost-name-dev. PACKAGE="libboost-dev" VERSION="1.78.0" CATEGORY="development" SHORT_DESC="Free peer-reviewed portable C++ source libraries." MAINTAINER="chadi.elahmad@gmail.com" LICENSE="MIT" WEB_SITE="https://www.boost.org/" # We have to do it this way because of the underscores # to get a package with the slitaz version numbering SOURCE="boost" WGET_SOURCE="boost_1_78_0" TARBALL="$WGET_SOURCE.tar.bz2" #EXTRA_SOURCE_FILES="boost_changeset_75540.u" WGET_URL="$SF_MIRROR/$SOURCE/$TARBALL" DEPENDS="gcc-lib-base libboost-chrono-dev libboost-date-time-dev \ libboost-math-dev" BUILD_DEPENDS="bzip2-dev expat expat-dev python python-dev zlib-dev" RELOCATE_LIBS="{ date_time filesystem graph iostreams \ math program_options python regex serialization \ signal system test thread tr1 wave }" # What is the latest version available today? current_version() { wget -O - https://sourceforge.net/projects/boost/files/boost/ 2>/dev/null | \ sed '/scope="row/!d;s|.*href="|"https://sourceforge.net|;q' | xargs wget -O - 2>/dev/null | \ sed '/scope="row/!d;s|.*/boost/||;s|/.*||;q' } # Rules to configure and make the package. # Uses boost:build building tool for the compilation: # Doesn't use DESTDIR. # Doesn't recognize the $CONFIGURE_ARGS, gives an error back # Have to add some params to get static libs compiled too compile_rules() { # Determine if TOOLPREFIX has been defined in tazwok.conf as it should if [ -z "$TOOLPREFIX" ] ; then # Provide a default TOOLPREFIX value TOOLPREFIX=$ARCH-pc-linux-gnu- fi # [ -s $SOURCES_REPOSITORY/boost_changeset_75540.u ] || # wget -O $SOURCES_REPOSITORY/boost_changeset_75540.u --no-check-certificate \ # 'https://svn.boost.org/trac/boost/changeset/75540?format=diff&new=75540' # patch -p2 < $SOURCES_REPOSITORY/boost_changeset_75540.u || return 1 ./bootstrap.sh \ --prefix=$DESTDIR/usr \ --exec-prefix=$DESTDIR/usr \ --libdir=$DESTDIR/usr/lib \ --includedir=$DESTDIR/usr/include \ --with-toolset=gcc \ --without-icu && EXPAT_INCLUDE=/usr/include \ EXPAT_LIBPATH=/usr/lib \ ./b2 \ --prefix=$DESTDIR/usr \ --exec-prefix=$DESTDIR/usr \ --libdir=$DESTDIR/usr/lib \ --includedir=$DESTDIR/usr/include \ --build-type=minimal \ install # create the missing links to the shared libs cd $DESTDIR/usr/lib #for i in `ls *-mt.so`; do # boost_tmp=`echo $i | sed s/-gcc.*-mt//g` # boost_tmp_mt=`echo $i | sed s/-gcc.*-mt/-mt/g` # ln -s $i $boost_tmp # ln -s $i $boost_tmp_mt #done #for i in `ls *-mt.a`; do # boost_tmp=`echo $i | sed s/-gcc.*-mt//g` # boost_tmp_mt=`echo $i | sed s/-gcc.*-mt/-mt/g` # ln -s $i $boost_tmp # ln -s $i $boost_tmp_mt #done } # Rules to gen a SliTaz package suitable for Tazpkg. genpkg_rules() { mkdir -p $fs/usr cp -a $install/usr/lib $fs/usr cp -a $install/usr/include $fs/usr for i in $RELOCATE_LIBS; do rm -f $fs/usr/lib/*$i* rm -r -f $fs/usr/include/boost/*$i* done # libboost-chrono{-dev} rm $fs/usr/lib/libboost_chrono* rm $fs/usr/include/boost/chrono* rm -r $fs/usr/include/boost/chrono # Ensure remove .la files find $fs -name "*.la" -delete }