diff --git a/include/nana/filesystem/filesystem.hpp b/include/nana/filesystem/filesystem.hpp index 36f8776d..8aab0cea 100644 --- a/include/nana/filesystem/filesystem.hpp +++ b/include/nana/filesystem/filesystem.hpp @@ -560,7 +560,7 @@ namespace std { #endif } } // std -#else +#else //#if NANA_USING_NANA_FILESYSTEM //Implements the missing functions for various version of experimental/filesystem namespace std { @@ -568,7 +568,7 @@ namespace std { { //Visual Studio 2017 #if (defined(NANA_USING_STD_EXPERIMENTAL_FILESYSTEM) && defined(_MSC_VER) && (_MSC_VER > 1912)) || \ - (!defined(__clang__) && defined(__GNUC__) && (__cplusplus < 201603)) + (!defined(__clang__) && defined(__GNUC__) && (__cplusplus < 201603 || (__GNUC__* 100 + __GNUC_MINOR__ < 801))) path weakly_canonical(const path& p); path weakly_canonical(const path& p, std::error_code& err); #endif diff --git a/source/filesystem/filesystem.cpp b/source/filesystem/filesystem.cpp index ae812104..bcd5957c 100644 --- a/source/filesystem/filesystem.cpp +++ b/source/filesystem/filesystem.cpp @@ -1407,7 +1407,7 @@ namespace std namespace filesystem { #if (defined(NANA_USING_STD_EXPERIMENTAL_FILESYSTEM) && defined(_MSC_VER) && (_MSC_VER > 1912)) || \ - (!defined(__clang__) && defined(__GNUC__) && (__cplusplus < 201603)) + (!defined(__clang__) && defined(__GNUC__) && (__cplusplus < 201603 || (__GNUC__* 100 + __GNUC_MINOR__ < 801))) namespace detail {