From 9414936e62ed8cd18cc33c0390bb605a782556c6 Mon Sep 17 00:00:00 2001 From: Colm Donelan Date: Mon, 3 Jul 2023 16:19:44 +0100 Subject: Replacing use of std::filesystem with ghc::filesystem. Even though we're using C++ 17 we still do a Debian buster build. This prevents using some new libraries. In this case std::filesystem. Signed-off-by: Colm Donelan Change-Id: Icdf3460cb5dd0e3ed2f07fccc5b89bd8975d488d --- tests/ExecuteNetwork/FileComparisonExecutor.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/ExecuteNetwork/FileComparisonExecutor.cpp b/tests/ExecuteNetwork/FileComparisonExecutor.cpp index 1675440e8c..e4699acd2e 100644 --- a/tests/ExecuteNetwork/FileComparisonExecutor.cpp +++ b/tests/ExecuteNetwork/FileComparisonExecutor.cpp @@ -6,7 +6,7 @@ #include "FileComparisonExecutor.hpp" #include #include -#include +#include #include using namespace armnn; @@ -166,14 +166,14 @@ void ReadData(const std::vector& buffer, */ Tensor ReadTensorFromFile(const std::string fileName) { - if (!std::filesystem::exists(fileName)) + if (!ghc::filesystem::exists(fileName)) { throw FileNotFoundException("The file \"" + fileName + "\" could not be found."); } // The format we are reading in is based on NetworkExecutionUtils::WriteToFile. This could potentially // be an enormous tensor. We'll limit what we can read in to 1Mb. std::uintmax_t maxFileSize = 1048576; - std::uintmax_t fileSize = std::filesystem::file_size(fileName); + std::uintmax_t fileSize = ghc::filesystem::file_size(fileName); if (fileSize > maxFileSize) { throw InvalidArgumentException("The file \"" + fileName + "\" exceeds max size of 1 Mb."); @@ -263,7 +263,7 @@ std::vector FileComparisonExecutor::Execute() std::string substr; getline(ss, substr, ','); // Check the file exist. - if (!std::filesystem::exists(substr)) + if (!ghc::filesystem::exists(substr)) { errorString += substr + " "; } -- cgit v1.2.1