diff options
author | Rob Hughes <robert.hughes@arm.com> | 2020-08-17 15:47:20 +0100 |
---|---|---|
committer | TeresaARM <teresa.charlinreyes@arm.com> | 2020-08-17 17:35:13 +0000 |
commit | 35c31c04a9805082be32474211dcd62b7629ed2b (patch) | |
tree | 69acbe73bb18a235d34e3acf256f84b3633f595a | |
parent | ec01fb79f15de76f41bd74fac09c2ffb25b7ada6 (diff) | |
download | armnn-35c31c04a9805082be32474211dcd62b7629ed2b.tar.gz |
Fix Windows build
Change-Id: I145d220c73313e31c184b6a75ab7f4823df99919
Signed-off-by: Robert Hughes <robert.hughes@arm.com>
-rw-r--r-- | cmake/GlobalConfig.cmake | 2 | ||||
-rw-r--r-- | profiling/common/src/NetworkSockets.cpp | 8 | ||||
-rw-r--r-- | src/armnn/Logging.cpp | 2 | ||||
-rw-r--r-- | src/armnn/test/UnitTests.cpp | 2 | ||||
-rw-r--r-- | src/armnnUtils/Filesystem.hpp | 5 | ||||
-rw-r--r-- | src/armnnUtils/Processes.cpp | 2 | ||||
-rw-r--r-- | src/armnnUtils/Threads.cpp | 2 |
7 files changed, 11 insertions, 12 deletions
diff --git a/cmake/GlobalConfig.cmake b/cmake/GlobalConfig.cmake index e5a586631c..b093e5d527 100644 --- a/cmake/GlobalConfig.cmake +++ b/cmake/GlobalConfig.cmake @@ -347,7 +347,7 @@ endif() # This is the root for the dynamic backend tests to search for dynamic # backends. By default it will be the project build directory. -add_definitions('-DDYNAMIC_BACKEND_BUILD_DIR="${PROJECT_BINARY_DIR}"') +add_definitions(-DDYNAMIC_BACKEND_BUILD_DIR="${PROJECT_BINARY_DIR}") # ArmNN dynamic backend if(DYNAMIC_BACKEND_PATHS) diff --git a/profiling/common/src/NetworkSockets.cpp b/profiling/common/src/NetworkSockets.cpp index 2a656552f1..15ad087d1e 100644 --- a/profiling/common/src/NetworkSockets.cpp +++ b/profiling/common/src/NetworkSockets.cpp @@ -8,17 +8,11 @@ #if defined(__unix__) || defined(__APPLE__) #include <unistd.h> #include <fcntl.h> -#include <common/include/Conversion.hpp> -#endif - -#if defined(__APPLE__) || defined(_MSC_VER) || defined(__MINGW32__) -#include <common/include/IgnoreUnused.hpp> #endif -#if defined(__MINGW32__) #include <common/include/Conversion.hpp> +#include <common/include/IgnoreUnused.hpp> #include <common/include/NumericCast.hpp> -#endif namespace arm { diff --git a/src/armnn/Logging.cpp b/src/armnn/Logging.cpp index 8b46a77b79..0cdcdc58ea 100644 --- a/src/armnn/Logging.cpp +++ b/src/armnn/Logging.cpp @@ -9,7 +9,7 @@ #include <armnn/utility/Assert.hpp> #if defined(_MSC_VER) -#include <commons/include/WindowsWrapper.hpp> +#include <common/include/WindowsWrapper.hpp> #endif #if defined(__ANDROID__) diff --git a/src/armnn/test/UnitTests.cpp b/src/armnn/test/UnitTests.cpp index 5d9211e44f..032a49fb90 100644 --- a/src/armnn/test/UnitTests.cpp +++ b/src/armnn/test/UnitTests.cpp @@ -24,7 +24,7 @@ BOOST_GLOBAL_FIXTURE(ConfigureLoggingFixture); #include <boost/iostreams/filtering_stream.hpp> #include <boost/iostreams/tee.hpp> #include <iostream> -#include <commons/include/WindowsWrapper.hpp> +#include <common/include/WindowsWrapper.hpp> using namespace boost::iostreams; using namespace std; diff --git a/src/armnnUtils/Filesystem.hpp b/src/armnnUtils/Filesystem.hpp index 3d93ce610d..ba0d97a272 100644 --- a/src/armnnUtils/Filesystem.hpp +++ b/src/armnnUtils/Filesystem.hpp @@ -5,6 +5,11 @@ #pragma once +#if defined(_MSC_VER) +// ghc includes Windows.h directly, bringing in macros that we don't want (e.g. min/max). +// By including Windows.h ourselves first (with appropriate options), we prevent this. +#include <common/include/WindowsWrapper.hpp> +#endif #include <ghc/filesystem.hpp> namespace fs = ghc::filesystem; diff --git a/src/armnnUtils/Processes.cpp b/src/armnnUtils/Processes.cpp index eb68dd9dff..8b401d4145 100644 --- a/src/armnnUtils/Processes.cpp +++ b/src/armnnUtils/Processes.cpp @@ -8,7 +8,7 @@ #if defined(__unix__) || defined(__APPLE__) #include <unistd.h> #elif defined(_MSC_VER) -#include <commons/include/WindowsWrapper.hpp> +#include <common/include/WindowsWrapper.hpp> #endif namespace armnnUtils diff --git a/src/armnnUtils/Threads.cpp b/src/armnnUtils/Threads.cpp index 3ee8174d01..64a84812d2 100644 --- a/src/armnnUtils/Threads.cpp +++ b/src/armnnUtils/Threads.cpp @@ -10,7 +10,7 @@ #include <sys/syscall.h> #define gettid() syscall(SYS_gettid) #elif defined(_MSC_VER) -#include <commons/include/WindowsWrapper.hpp> +#include <common/include/WindowsWrapper.hpp> #elif defined(__APPLE__) #include "AvailabilityMacros.h" #include <sys/syscall.h> |