Skip to content

Fixing Compile Issue on macOS 10.13 High Sierra and GCC 7.2.0 #5

@gabecfernandez

Description

@gabecfernandez

When compiling using gcc 7.2.0 on macOS 10.13 High Sierra, I encountered the following error:

graphlet_utils.cpp: In function 'bool fexists(const char*)':
graphlet_utils.cpp:42:12: error: cannot convert 'std::ifstream {aka std::basic_ifstream<char>}' to 'bool' in return
     return ifile;
            ^~~~~
make: *** [pgd] Error 1

I changed 'return ifile;' to be 'return (bool)ifile;' and was able to compile successfully.

Reference: https://stackoverflow.com/questions/38659115/make-fails-with-error-cannot-convert-stdistream-aka-stdbasic-istreamchar

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions