Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

g++ 6.3 build failure is still happening for 5.0.0-rc3 #3661

Closed
sflitman opened this issue Nov 27, 2021 · 4 comments
Closed

g++ 6.3 build failure is still happening for 5.0.0-rc3 #3661

sflitman opened this issue Nov 27, 2021 · 4 comments

Comments

@sflitman
Copy link

This is a request to reopen #3255

Environment

  • Tesseract Version: 5.00-rc3
  • Commit Number: ?
  • Platform: Linux server 4.9.0-14-amd64 defect issue #1 SMP Debian 4.9.240-2 (2020-10-30) x86_64 GNU/Linux

Current Behavior: Compile fails after successful configure on Debian Stretch:

Making all in .
make[1]: Entering directory '/dsk/src/tesseract-5.0.0-rc3'
  CXX      src/api/libtesseract_la-baseapi.lo
In file included from ./src/ccutil/elst.h:24:0,
                 from ./src/ccstruct/points.h:22,
                 from ./src/ccstruct/rect.h:22,
                 from ./src/ccstruct/boxword.h:22,
                 from src/api/baseapi.cpp:26:
./src/ccutil/serialis.h: In member function ‘bool tesseract::TFile::DeSerialize(std::vector<T>&)’:
./src/ccutil/serialis.h:107:15: error: expected ‘(’ before ‘constexpr’
     } else if constexpr (std::is_same_v<T, std::string>) {
               ^~~~~~~~~
./src/ccutil/serialis.h:151:3: error: expected ‘}’ at end of input
   }
   ^
./src/ccutil/serialis.h: In member function ‘bool tesseract::TFile::Serialize(const std::vector<T>&)’:
./src/ccutil/serialis.h:166:15: error: expected ‘(’ before ‘constexpr’
     } else if constexpr (std::is_same_v<T, std::string>) {
               ^~~~~~~~~
./src/ccutil/serialis.h:198:3: error: expected ‘}’ at end of input
   }
   ^
In file included from ./src/ccstruct/matrix.h:28:0,
                 from ./src/ccstruct/ratngs.h:31,
                 from ./src/dict/dawg.h:33,
                 from ./src/dict/dawg_cache.h:23,
                 from src/api/baseapi.cpp:28:
./src/ccutil/helpers.h: In function ‘bool tesseract::Serialize(FILE*, const std::vector<T>&)’:
./src/ccutil/helpers.h:255:13: error: expected ‘(’ before ‘constexpr’
   } else if constexpr (std::is_class_v<T>) {
             ^~~~~~~~~
src/api/baseapi.cpp:2365:1: error: expected ‘}’ at end of input
 } // namespace tesseract
 ^
src/api/baseapi.cpp: At global scope:
src/api/baseapi.cpp:2365:1: error: expected ‘}’ at end of input
Makefile:4693: recipe for target 'src/api/libtesseract_la-baseapi.lo' failed
make[1]: *** [src/api/libtesseract_la-baseapi.lo] Error 1
make[1]: Leaving directory '/dsk/src/tesseract-5.0.0-rc3'
Makefile:7798: recipe for target 'all-recursive' failed
make: *** [all-recursive] Error 1

Expected Behavior: Successful compilation with g++ version 6.3

Suggested Fix: Add -std=c++14 to CXXFLAGS, but tried it and it didn't work

It would be nice for my client to get Tesseract working on a server he is afraid to upgrade from Debian Stretch, but I understand if it would be too much work to get it to work for an old OS.
Thanks,
SSF

@stweil
Copy link
Member

stweil commented Nov 27, 2021

This is a request to reopen #3255

Then please don't open new issues, but add your comments there.

@amitdo
Copy link
Collaborator

amitdo commented Nov 29, 2021

Debian Stretch LTS EOL is June 2022. Use 4.1.3 instead of 5.0.0 or upgrade to a newer Debian version.

We are not going to support GCC 6.x in Tesseract 5.0.0.

@amitdo
Copy link
Collaborator

amitdo commented Nov 29, 2021

Another option:
#3210 (comment)

@sflitman
Copy link
Author

sflitman commented Nov 29, 2021 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants