aboutsummaryrefslogtreecommitdiff
path: root/ports/dlib/force_finding_packages.patch
blob: 558b75f1fe881d73c4587bcba8b19a6c478a0db4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
diff --git a/dlib/cmake_utils/find_libjpeg.cmake b/dlib/cmake_utils/find_libjpeg.cmake
index 3b9e656..d741f31 100644
--- a/dlib/cmake_utils/find_libjpeg.cmake
+++ b/dlib/cmake_utils/find_libjpeg.cmake
@@ -14,7 +14,7 @@ if (DEFINED JPEG_FOUND)
    return()
 endif()
 
-find_package(JPEG QUIET)
+find_package(JPEG REQUIRED)
 
 if(JPEG_FOUND)
    set(JPEG_TEST_CMAKE_FLAGS 
@@ -31,7 +31,7 @@ if(JPEG_FOUND)
    message (STATUS "Found system copy of libjpeg: ${JPEG_LIBRARY}")
    if(NOT test_for_libjpeg_worked)
       set(JPEG_FOUND 0)
-      message (STATUS "System copy of libjpeg is broken or too old.  Will build our own libjpeg and use that instead.")
+      message (FATAL_ERROR "System copy of libjpeg is broken or too old.  Will build our own libjpeg and use that instead.")
    endif()
 endif()
 
diff --git a/dlib/cmake_utils/find_libpng.cmake b/dlib/cmake_utils/find_libpng.cmake
index 1b35604..489a4c8 100644
--- a/dlib/cmake_utils/find_libpng.cmake
+++ b/dlib/cmake_utils/find_libpng.cmake
@@ -14,7 +14,7 @@ if (DEFINED PNG_FOUND)
    return()
 endif()
 
-find_package(PNG QUIET)
+find_package(PNG REQUIRED)
 
 if(PNG_FOUND)
    set(PNG_TEST_CMAKE_FLAGS 
@@ -31,7 +31,7 @@ if(PNG_FOUND)
    message (STATUS "Found system copy of libpng: ${PNG_LIBRARIES}")
    if(NOT test_for_libpng_worked)
       set(PNG_FOUND 0)
-      message (STATUS "System copy of libpng is broken.  Will build our own libpng and use that instead.")
+      message (FATAL_ERROR "System copy of libpng is broken.  Will build our own libpng and use that instead.")
    endif()
 endif()