Ensure that libjpeg-turbo headers are included
On some systems, the build was picking up jpeglib.h from the system
include directories, and if the system's version of libjpeg[-turbo] used
a different API/ABI version than the one specified in JPEG_LIBRARY, this
led to a "Wrong JPEG library version" error at run time.
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 08ef25c..904809c 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -199,6 +199,8 @@
message(STATUS "WARNING: You are not using libjpeg-turbo. Performance will suffer.")
endif()
+include_directories(${JPEG_INCLUDE_DIR})
+
option(BUILD_JAVA "Build Java version of the TigerVNC Viewer" FALSE)
if(BUILD_JAVA)
add_subdirectory(java)