git clone compile errors on isnan

Michael Stahl mstahl at redhat.com
Fri Aug 5 13:24:13 UTC 2016


On 05.08.2016 14:48, Larry Evans wrote:
> On 08/05/2016 05:21 AM, Michael Stahl wrote:
>> On 04.08.2016 22:24, Larry Evans wrote:
> [snip]
>>> /home/evansl/dwnlds/LibreOffice/libreoffice/workdir/UnpackedTarball/boost/boost/math/special_functions/fpclassify.hpp:137:75:
>>> error: ‘::isnan’ has not been declared
>>>   inline bool is_nan_helper(__float128 f, const boost::true_type&) {
>>> return ::isnan(static_cast<double>(f)); }
>>>
>>>     ^
>>> /home/evansl/dwnlds/LibreOffice/libreoffice/workdir/UnpackedTarball/boost/boost/math/special_functions/fpclassify.hpp:137:75:
>>> note: suggested alternatives:
>>> In file included from /usr/local/include/c++/4.9.0/random:38:0,
>>>                   from /usr/local/include/c++/4.9.0/bits/stl_algo.h:66,
>>>                   from /usr/local/include/c++/4.9.0/algorithm:62,
>>>                   from
>>> /home/evansl/dwnlds/LibreOffice/libreoffice/workdir/UnpackedTarball/boost/boost/smart_ptr/shared_ptr.hpp:38,
>>>                   from
>>> /home/evansl/dwnlds/LibreOffice/libreoffice/workdir/UnpackedTarball/boost/boost/shared_ptr.hpp:17,
>>>                   from
>>> /home/evansl/dwnlds/LibreOffice/libreoffice/external/boost/include/boost/shared_ptr.hpp:22,
>>>                   from
>>> /home/evansl/dwnlds/LibreOffice/libreoffice/workdir/UnpackedTarball/boost/boost/date_time/gregorian/greg_month.hpp:14,
>>>                   from
>>> /home/evansl/dwnlds/LibreOffice/libreoffice/workdir/UnpackedTarball/boost/libs/date_time/src/gregorian/greg_month.cpp:14:
>>> /usr/local/include/c++/4.9.0/cmath:632:5: note:   ‘std::isnan’
>>>       isnan(_Tp __x)
>>>       ^
>>
>> you are using a custom toolchain installed in /usr/local that is not set
>> up correctly.
>>
> [snip]
>>  you could just use the GCC shipped
>> in your distribution which presumably works.
> 
> Tried that by running ./configure as follows:
> 
> evansl at lje-OptiPlex-9020:~/dwnlds/LibreOffice/git-clone/libreoffice$ 
> ./configure --with-gcc-home=/usr

i have never heard of --with-gcc-home, but according to configure.ac it
should set the variables CC=/usr/bin/gcc and CXX=/usr/bin/g++ which is
what i would set manually anyway, so looks like it does the right thing
(you can double-check the values in config_host.mk)

> after that, ran make; however, now getting undefined reference error 
> during collect2:
> 
> [DEP] LNK:Executable/regview
> [LNK] Executable/regview
> /home/evansl/dwnlds/LibreOffice/git-clone/libreoffice/workdir/CxxObject/registry/tools/regmerge.o: 
> In function `main':
> regmerge.cxx:(.text.startup+0xaf): undefined reference to 
> `registry::tools::Options::checkArgument(std::vector<std::__cxx11::basic_string<char, 
> std::char_traits<char>, std::allocator<char> >, 
> std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, 
> std::allocator<char> > > >&, char const*, unsigned long)'
> regmerge.cxx:(.text.startup+0x11c): undefined reference to 
> `registry::tools::Options::initOptions(std::vector<std::__cxx11::basic_string<char, 
> std::char_traits<char>, std::allocator<char> >, 
> std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, 
> std::allocator<char> > > >&)'
> collect2: error: ld returned 1 exit status

very odd... i bet there is some inconsistency somewhere wrt. setting of
the macro _GLIBCXX_USE_CXX11_ABI and the libstdc++ being linked.

did you do a "make clean" after your previous build attempt?  if there
are still object files around built by the compiler in /usr/local then
problems like that are expected.

in case "make clean" doesn't fix it try "make verbose=t
LDFLAGS="-Wl,--trace"" to see what libraries are being linked.



More information about the LibreOffice mailing list