Look for libjpeg in a more proper manner and don't just assume it's in a
standard path.


git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@4314 3789f03b-4d11-0410-bbf8-ca57d06f2519
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 04c7697..112aa8d 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -93,6 +93,9 @@
   set(USE_INCLUDED_ZLIB 1)
 endif()
 
+# Check for libjpeg
+find_package(JPEG REQUIRED)
+
 # Check for GNUTLS library
 find_package(GnuTLS)
 if(GNUTLS_FOUND)