Bug#962533: mlpack FTBFS on mips64el: relocation truncated to fit

Adrian Bunk bunk at debian.org
Fri Jun 12 07:15:00 BST 2020


On Fri, Jun 12, 2020 at 05:56:39AM +0800, YunQiang Su wrote:
> Adrian Bunk <bunk at debian.org> 于 2020年6月9日周二 下午11:18写道:
>...
> just add -mxgot to cxxflags.
> there are 2 type of GOT in mips: one use fewer insn while has a length
> limitaion; another uses more insns while has a big address space support.
>...

That's what I tried:

> > I tried "export DEB_CXXFLAGS_MAINT_APPEND += -mxgot" which gave me:
> >
> > ...
> > /usr/bin/c++  -g -O2 -fdebug-prefix-map=/home/bunk/build/mlpack-3.3.1=.
> > -fstack-protector-strong -Wformat -Werror=format-security -mxgot
> > -Wdate-time -D_FORTIFY_SOURCE=2 -Wall -Wextra -ftemplate-depth=1000
> > -Wno-unused-function -O3 -fopenmp  -Wl,-z,relro -Wl,-z,now -rdynamic
> > CMakeFiles/mlpack_cf.dir/cf_main.cpp.o  -o ../../../../bin/mlpack_cf
> > -Wl,-rpath,/home/bunk/build/mlpack-3.3.1/obj-mips64el-linux-gnuabi64/lib:
> > ../../../../lib/libmlpack.so.3.3 /usr/lib/libarmadillo.so
> > /usr/lib/mips64el-linux-gnuabi64/libboost_program_options.so
> > /usr/lib/mips64el-linux-gnuabi64/libboost_unit_test_framework.so
> > /usr/lib/mips64el-linux-gnuabi64/libboost_serialization.so -lpthread
> > CMakeFiles/mlpack_cf.dir/cf_main.cpp.o: in function
> > `std::mersenne_twister_engine<unsigned long, 64ul, 312ul, 156ul, 31ul,
> > 13043109905998158313ul, 29ul, 6148914691236517205ul, 17ul,
> > 8202884508482404352ul, 37ul, 18444473444759240704ul, 43ul,
> > 6364136223846793005ul>::seed(unsigned long)':
> > /usr/include/c++/9/bits/random.tcc:329:(.text._ZN6mlpack4math10RandomSeedEm[_ZN6mlpack4math10RandomSeedEm]+0xb8):
> > relocation truncated to fit: R_MIPS_TLS_GOTTPREL against
> > `arma::arma_rng_cxx11_instance'
> > CMakeFiles/mlpack_cf.dir/cf_main.cpp.o: in function
> > `std::mersenne_twister_engine<unsigned long, 64ul, 312ul, 156ul, 31ul,
> > 13043109905998158313ul, 29ul, 6148914691236517205ul, 17ul,
> > 8202884508482404352ul, 37ul, 18444473444759240704ul, 43ul,
> > 6364136223846793005ul>::operator()()':
> > /usr/include/c++/9/bits/random.tcc:458:(.text._ZN4arma8arma_rng5randuIdE4fillEPdy[_ZN4arma8arma_rng5randuIdE4fillEPdy]+0x70):
> > relocation truncated to fit: R_MIPS_TLS_GOTTPREL against
> > `arma::arma_rng_cxx11_instance'
> > /usr/include/c++/9/bits/random.tcc:457:(.text._ZN4arma8arma_rng5randuIdE4fillEPdy[_ZN4arma8arma_rng5randuIdE4fillEPdy]+0x354):
> > relocation truncated to fit: R_MIPS_TLS_GOTTPREL against
> > `arma::arma_rng_cxx11_instance'
> > collect2: error: ld returned 1 exit status
> >
> >
> > debian-mips is Cc'ed, can a mips porter please have a look?

What are these R_MIPS_TLS_GOTTPREL relocations?

cu
Adrian



More information about the debian-science-maintainers mailing list