From 6ac6715da59bfacaa1e3643aa2b6a9e1e027b70a Mon Sep 17 00:00:00 2001 From: Martin Pulec Date: Thu, 24 Jun 2021 16:13:43 +0200 Subject: [PATCH] Small cross-compile fixes - $GENICAM_GENTL64_PATH may be defined in Linux but the path inside the dir is then invalid when cross-compiling for Windows - rang.hpp included transitively from video_frame_pool.cpp needs _WIN32_WINNT at least to _WIN32_WINNT_VISTA prior including other headers - it is defined in config_win32.h --- configure.ac | 2 +- src/utils/video_frame_pool.cpp | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 6174b6263..2a8d616dd 100644 --- a/configure.ac +++ b/configure.ac @@ -1120,7 +1120,7 @@ else XI_LIB_PREF="lib" XIMEA_CFLAGS="-I$XIAPI_PATH/../include" else - if test -n "$GENICAM_GENTL64_PATH"; then + if test -d "$GENICAM_GENTL64_PATH/../../API/xiAPI"; then # the env var contains actually something like "C:\XIMEA\GenTL Producer\64bit" XIAPI_PATH=$(realpath "$GENICAM_GENTL64_PATH/../../API/xiAPI") else diff --git a/src/utils/video_frame_pool.cpp b/src/utils/video_frame_pool.cpp index 0930e3f9a..ef1a74906 100644 --- a/src/utils/video_frame_pool.cpp +++ b/src/utils/video_frame_pool.cpp @@ -35,6 +35,12 @@ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif // defined HAVE_CONFIG_H +#include "config_unix.h" +#include "config_win32.h" + #include #include #include