Boost logo

Boost :

Subject: Re: [boost] [predef] Using predef-check on 'develop' problem
From: Edward Diener (eldiener_at_[hidden])
Date: 2015-07-03 21:25:04

On 7/3/2015 11:55 AM, Rene Rivera wrote:
> After some investigation...
> On Thu, Jul 2, 2015 at 11:07 PM, Edward Diener <eldiener_at_[hidden]>
> wrote:
>> Closer but not quite there.
>> The predef-check is now working with Windows msvc-14.0 and with the SunOS
>> tests but there is still a problem with Android.
> Technically it's working on all ;-)
>> The problem occurs in the VMD tests but can be illustrated by predef tests
>> also. Look at the "CrystaX.NET-apilevel-21-x86" predef tests, which have
>> your latest June 29 commit you mention just above. If you look at the
>> "clang-linux-3.6" tests you will see that the "info_as_cpp" test shows
>> everything correctly but the "check_value" test shows "CHECK_VALUE ==
>> undefined" where it should be "CHECK_VALUE == 1".
>> Similarly my corresponding VMD Android tests, which relies on predef-check
>> to pass "-std=c++0x" for the gcc tests, are not doing so there.
>> So there is still a problem with Android although Sun-OS and VC++14 tests
>> are working fine now with predef-check.
> Some good news and bad news.. I know what the last problem is now. It's
> because Android is a cross-compiler, it build on Linux but targets Android
> in this case. The good news is that the BB check builds and runs fine, on
> the host-os Linux build machine. The bad news is that the result of running
> that on the host-os machine is useless for making a determination of the
> target-os build for the libraries.
> And the really bad news.. Is that this is something that is not immediately
> fixable. Further it's something that is really hard to fix as it would
> involve creating a whole bunch of code for running those tests on the
> target-os remotely.
> Hence, my suggestion would be to change your build file to also check the
> "target-os" build property. You might want to bring this up, how to check
> the target-os in your use case, on another thread and perhaps on the Boost
> Build list (so that it gets more immediate attention).

My test in the VMD jamfile is:

[ predef-check "BOOST_COMP_GNUC >= 4.3" "BOOST_OS_QNX == 0" : :
<cxxflags>-std=c++0x ]

but despite Android telling me that it is using gcc 4.8 and gcc 4.9 the
"-std=c++0x" option never gets added to the command line. This has
nothing to do with the build OS/target OS issue you are mentioning. Your
predef test for the same Android tests shows

BOOST_COMP_GNUC = 40800000 (4,8,0) | Gnu GCC C/C++


BOOST_COMP_GNUC = 40900000 (4,9,0) | Gnu GCC C/C++

What is further odd is that I also have these predef-check setups in the

[ predef-check "BOOST_COMP_GNUC >= 4.8.1" : :
<cxxflags>-ftrack-macro-expansion=0 ]
[ predef-check "BOOST_COMP_GNUC >= 4.3.0" : :
<cxxflags>-Wno-variadic-macros ]

Yet neither of those options are showing up on the command line for the
tests. It seems to me that for the Android maybe the cause is that
despite compiling with g++ the compile is being treated as a C compile
and not a C++ compile so that cxxflags does not take effect.

On all other tests with gcc all the appropriate options are working fine.

>> As always I appreciate your efforts to get this working, especially on OSs
>> like SunOS and Android rather than the usual Windows, Linux, Macintosh
>> triplet.
> Thanks.. I appreciate the gratitude. As it's some times hard to tell if
> people actually care :-)

Boost list run by bdawes at, gregod at, cpdaniel at, john at