[prev in list] [next in list] [prev in thread] [next in thread] 

List:       boost-users
Subject:    Re: [Boost-users] autoconf/automake and boost
From:       Riccardo Murri <riccardo.murri () gmail ! com>
Date:       2012-09-26 13:36:32
Message-ID: CAJGE3zWZvdz96irGQ5_v+eF=gBMgCBEseRfdVfa4AirVJ7eK+Q () mail ! gmail ! com
[Download RAW message or body]

On Tue, Sep 25, 2012 at 11:55 PM, ilya shlyakhter <ilyawebmail@gmail.com> wrote:
> Can you point me to instructions for specifying dependency on Boost in
> an autoconf/automake project?  I'd like the configure script to have
> an option --with-boost=... to point to a Boost installation, to specify a minimum
> required Boost version, and to require the presence of particular
> Boost libraries.

I use Tsuna's `boost.m4`, which allows you to do what you want with
code like the following:

    # check for needed Boost libraries
    BOOST_REQUIRE([1.45])
    BOOST_STATIC
    BOOST_SERIALIZATION
    BOOST_STATICASSERT
    BOOST_TEST([],
        [have_boost_test=no;
            AC_MSG_WARN([Could not find a usable Boost.Test library;
not compiling test programs.])],
        [have_boost_test=yes])
    AM_CONDITIONAL([HAVE_BOOST_TEST], [test "_$have_boost_test" = '_yes'])

You can download `boost.m4` from its Guthub repo:
https://github.com/tsuna/boost.m4

Cheers,
Riccardo
_______________________________________________
Boost-users mailing list
Boost-users@lists.boost.org
http://lists.boost.org/mailman/listinfo.cgi/boost-users
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic