stefanhaustein / TerminalImageViewer

Small C++ program to display images in a (modern) terminal using RGB ANSI codes and unicode block graphics characters
Other
1.56k stars 111 forks source link

Build from source crashes with `error: ‘std::experimental’ has not been declared` #101

Closed rjpadilla closed 3 years ago

rjpadilla commented 3 years ago

Describe the bug

Trying to install TIV using make, but crashes with error: ‘std::experimental’ has not been declared OS: "Ubuntu 20.04.2 LTS"

To Reproduce Steps to reproduce the behavior: From the Build From Source instructions: https://github.com/stefanhaustein/TerminalImageViewer#build-from-source at the make step.

Expected behavior Installed TIV

Actual behavior After running make:


g++ -O2 -fpermissive -std=c++17 -Wall -fexceptions   -c -o tiv.o tiv.cpp
tiv.cpp: In function ‘int main(int, char**)’:
tiv.cpp:580:16: error: ‘std::experimental’ has not been declared
  580 |       if (std::experimental::filesystem::is_directory(arg)) {
      |                ^~~~~~~~~~~~
tiv.cpp:581:31: error: ‘std::experimental’ has not been declared
  581 |          for (auto & p : std::experimental::filesystem::directory_iterator(arg)) {
      |                               ^~~~~~~~~~~~
tiv.cpp:582:21: error: ‘std::experimental’ has not been declared
  582 |            if (std::experimental::filesystem::is_regular_file(p.path())) {
      |                     ^~~~~~~~~~~~
make: *** [<builtin>: tiv.o] Error 1