Boost logo

Boost-Build :

Subject: Re: [Boost-build] [boost] [gil][test] HOWTO set up the Boost testing process for projects with extra prerequisites ?
From: Stefan Seefeld (stefan_at_[hidden])
Date: 2017-11-24 02:26:13


Hi,

I'm following up with a technical Boost.Build question, so this mailing
list seems more appropriate...

On 17.11.2017 12:02, Rene Rivera via Boost wrote:
> On Fri, Nov 17, 2017 at 10:42 AM, Steven Watanabe via Boost <
> boost_at_[hidden]> wrote:
>
>> AMDG
>>
>> On 11/17/2017 09:29 AM, Stefan Seefeld via Boost wrote:
>>> I just merged some work to GIL's `develop` branch. This notably involves
>>> improvements to the testing infrastructure. Testing GIL is a bit
>>> involved, as it requires various backend libraries (PNG, JPEG, TIFF,
>>> etc.) to be installed. While the stand-alone testing works fine
>>> (https://github.com/boostorg/gil/blob/develop/.travis.yml#L304-L306),
>>> the integrated testing will thus fail, until the testing logic is
>>> augmented by the necessary instructions to a) install the prerequisites
>>> and b) invoke the build system with the appropriate flags
>>> (https://github.com/boostorg/gil/blob/develop/io/test/Jamfile#L13-L22)
>>>
>> Please use the Boost.Build modules for these libraries
>> instead. You can make the tests run only when the
>> corresponding libraries are available, like this:
>>
>> using zlib ;
>>
>> run png_test.cpp
>> : # args
>> : # input-files
>> : # requirements
>> [ ac.check-library /zlib//zlib : <library>/zlib//zlib : <build>no ]
>> # in English, if the library is found, use it, otherwise,
>> # skip this test
>> ;
>>
> Although ideally it should be:
>
> import zlib ;
>
> run ... ;
>
> And then ask the testers to add the appropriate "using zlib ... ;" to their
> configuration. And that should also include any CI testing you do also.

Is there a way for the Jamfile to add a "using zlib ;" or similar that
will serve as a default, i.e. whenever the user-config.jam file doesn't
contain a "using zlib " statement ? I'd like to be able to write a valid
Jamfile that works (and finds prerequisite libs in default locations)
without a user-config.jam, but allow users to override the paths. But
right now it seems I have to add "using zlib ;" to either my
user-config.jam, or the Jamfile, but not both.

Thanks,

Stefan

-- 
      ...ich hab' noch einen Koffer in Berlin...
    



signature.png

Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk