On 9/2/2016 2:06 PM, Billy O'Neal (VC LIBS) wrote:
Hello, Boost folks. :)
I tried to remove this undocumented internal macro from our STL because we used it in only one place, but this broke Boost:
#define _FPOSOFF(fp) ((long long)(fp))
...patience... ...found 722 targets... ...updating 18 targets... common.mkdir build\boost\bin.v2\libs common.mkdir build\boost\bin.v2\libs\iostreams common.mkdir build\boost\bin.v2\libs\iostreams\build common.mkdir build\boost\bin.v2\libs\iostreams\build\msvc-99 common.mkdir build\boost\bin.v2\libs\iostreams\build\msvc-99\debug common.mkdir build\boost\bin.v2\libs\iostreams\build\msvc-99\debug\link-static common.mkdir build\boost\bin.v2\libs\iostreams\build\msvc-99\debug\link-static\threading-multi compile-c-c++ build\boost\bin.v2\libs\iostreams\build\msvc-99\debug\link-static\threading-multi\file_descriptor.obj file_descriptor.cpp d:\src\vc\wcfb01\qa\vc\FE\3rdpartycomp\boost_1_60_0\boost/iostreams/positioning.hpp(107): error C3861: '_FPOSOFF': identifier not found libs\iostreams\src\file_descriptor.cpp(265): warning C4244: 'argument': conversion from 'std::streamsize' to 'DWORD', possible loss of data libs\iostreams\src\file_descriptor.cpp(289): warning C4244: 'argument': conversion from 'std::streamsize' to 'DWORD', possible loss of data
cl /Zm800 -nologo @"build\boost\bin.v2\libs\iostreams\build\msvc-99\debug\link-static\threading-multi\file_descriptor.obj.rsp"
...failed compile-c-c++ build\boost\bin.v2\libs\iostreams\build\msvc-99\debug\link-static\threading-multi\file_descriptor.obj... compile-c-c++ build\boost\bin.v2\libs\iostreams\build\msvc-99\debug\link-static\threading-multi\mapped_file.obj mapped_file.cpp d:\src\vc\wcfb01\qa\vc\FE\3rdpartycomp\boost_1_60_0\boost/iostreams/positioning.hpp(107): error C3861: '_FPOSOFF': identifier not found libs\iostreams\src\mapped_file.cpp(59): warning C4244: 'return': conversion from 'const boost::iostreams::stream_offset' to '::size_t', possible loss of data libs\iostreams\src\mapped_file.cpp(325): warning C4244: 'argument': conversion from 'boost::iostreams::stream_offset' to 'SIZE_T', possible loss of data
cl /Zm800 -nologo @"build\boost\bin.v2\libs\iostreams\build\msvc-99\debug\link-static\threading-multi\mapped_file.obj.rsp"
...failed compile-c-c++ build\boost\bin.v2\libs\iostreams\build\msvc-99\debug\link-static\threading-multi\mapped_file.obj... ...skipped
libboost_iostreams-vc-mt-gd-1_60.lib for lack of file_descriptor.obj... ...skipped libboost_iostreams-vc-mt-gd-1_60.lib for lack of libboost_iostreams-vc-mt-gd-1_60.lib... common.mkdir build\boost\bin.v2\libs\iostreams\build\msvc-99\release common.mkdir build\boost\bin.v2\libs\iostreams\build\msvc-99\release\link-static common.mkdir build\boost\bin.v2\libs\iostreams\build\msvc-99\release\link-static\threading-multi compile-c-c++ build\boost\bin.v2\libs\iostreams\build\msvc-99\release\link-static\threading-multi\file_descriptor.obj file_descriptor.cpp .\boost/iostreams/positioning.hpp(107): error C3861: '_FPOSOFF': identifier not found libs\iostreams\src\file_descriptor.cpp(265): warning C4244: 'argument': conversion from 'std::streamsize' to 'DWORD', possible loss of data libs\iostreams\src\file_descriptor.cpp(289): warning C4244: 'argument': conversion from 'std::streamsize' to 'DWORD', possible loss of data cl /Zm800 -nologo @"build\boost\bin.v2\libs\iostreams\build\msvc-99\release\link-static\threading-multi\file_descriptor.obj.rsp"
...failed compile-c-c++ build\boost\bin.v2\libs\iostreams\build\msvc-99\release\link-static\threading-multi\file_descriptor.obj... compile-c-c++ build\boost\bin.v2\libs\iostreams\build\msvc-99\release\link-static\threading-multi\mapped_file.obj mapped_file.cpp .\boost/iostreams/positioning.hpp(107): error C3861: '_FPOSOFF': identifier not found libs\iostreams\src\mapped_file.cpp(59): warning C4244: 'return': conversion from 'const boost::iostreams::stream_offset' to '::size_t', possible loss of data libs\iostreams\src\mapped_file.cpp(325): warning C4244: 'argument': conversion from 'boost::iostreams::stream_offset' to 'SIZE_T', possible loss of data
cl /Zm800 -nologo @"build\boost\bin.v2\libs\iostreams\build\msvc-99\release\link-static\threading-multi\mapped_file.obj.rsp"
...failed compile-c-c++ build\boost\bin.v2\libs\iostreams\build\msvc-99\release\link-static\threading-multi\mapped_file.obj... ...skipped
libboost_iostreams-vc-mt-1_60.lib for lack of file_descriptor.obj... ...skipped libboost_iostreams-vc-mt-1_60.lib for lack of libboost_iostreams-vc-mt-1_60.lib... ...failed updating 4 targets... ...skipped 4 targets... ...updated 10 targets... failed
I have pushed a fix for this on the 'develop' branch of iostreams. In the fix basically iostreams uses _FPOSOFF for versions of VC++ prior to VC++14 but uses '((long long)(fp))' for VC++14 on up. This won't get in the upcoming release but it should get in the subsequent Boost release.
Billy3