Closed Shreeshrii closed 5 years ago
Did you try a clean build? I cannot reproduce this linker error.
It builds ok with c++17 on ppc64le
ubuntu@tesseract-ocr:~/tesseract$ tesseract -v
tesseract 5.0.0-alpha-213-g0ac59d
leptonica-1.78.0
libgif 5.1.4 : libjpeg 8d (libjpeg-turbo 1.4.2) : libpng 1.2.54 : libtiff 4.0.9 : zlib 1.2.11 : libwebp 0.4.4 : libopenjp2 2.3.0
ubuntu@tesseract-ocr:~/tesseract$ uname -a
Linux tesseract-ocr 4.15.0-52-generic #56-Ubuntu SMP Tue Jun 4 22:53:08 UTC 2019 ppc64le ppc64le ppc64le GNU/Linux
It failed, even after make clean
with c++14 on ppc64 with the current commit.
It built ok using an older commit.
[shreeshrii@rh-power-vm61 tesseract]$ uname -a
Linux rh-power-vm61.fit.vutbr.cz 4.16.3-301.fc28.ppc64 #1 SMP Mon Apr 23 21:44:46 UTC 2018 ppc64 ppc64 ppc64 GNU/Linux
[shreeshrii@rh-power-vm61 tesseract]$ tesseract -v
tesseract 5.0.0-alpha-161-gfad96d
leptonica-1.76.0
libgif 5.1.4 : libjpeg 6b (libjpeg-turbo 1.5.3) : libpng 1.6.34 : libtiff 4.0.9 : zlib 1.2.11 : libwebp 1.0.0
I will try to see if I can identify when it started failing.
I recently introduced new code using std::function
and std::bind
. Both should work with C++-11, but maybe there are differences to C++-17. I'll test that and look for a fix.
3871caae86e02c0f194bd334f4314dd59ac73c6a is the first bad commit commit 3871caae86e02c0f194bd334f4314dd59ac73c6a Date: Fri Jun 21 16:52:55 2019 +0200
Simplify indirect call of LMPainPoints::GeneratePainPoint
A C++-11 build with x86_64-linux-gnu-g++ has no such problems. C++-14 with sparc64-linux-gnu-g++ works, too. So does ppc64le-redhat-linux-g++.
The error is related to config options used. It builds ok with:
../configure --enable-openmp --disable-debug --disable-opencl --disable-graphics --disable-shared
It fails when --disable-legacy is used
../configure --enable-openmp --disable-debug --disable-opencl --disable-graphics --disable-shared --disable-legacy
This should be fixed now. I removed the function which used the unresolved symbol from builds without legacy code.
Thanks!