aboutsummaryrefslogtreecommitdiff
path: root/community/supertuxkart/find-directfb-include.patch
blob: e0b1f7a8df69ad6e85eef34cd0fd00bc3ce04e2b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
diff --git a/CMakeLists.txt b/CMakeLists.txt
index e4db9ca94..313ee4c9e 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -295,11 +295,13 @@ if (NOT SERVER_ONLY)
     # SDL2
     find_library(SDL2_LIBRARY NAMES SDL2 libSDL2)
     find_path(SDL2_INCLUDEDIR NAMES SDL.h PATH_SUFFIXES SDL2 include/SDL2 include PATHS)
+    find_path(DIRECTFB_INCLUDEDIR NAMES directfb.h directfb++.h PATH_SUFFIXES directfb include/directfb include PATHS)
     if (NOT SDL2_LIBRARY OR NOT SDL2_INCLUDEDIR)
         message(FATAL_ERROR "SDL2 not found. "
             "SDL2 is required to handle gamepad in SuperTuxKart.")
     else()
-        include_directories("${SDL2_INCLUDEDIR}")
+        include_directories(${SDL2_INCLUDEDIR})
+	include_directories(${DIRECTFB_INCLUDEDIR})
         MESSAGE(STATUS "Use system SDL2: ${SDL2_LIBRARY}")
     endif()
 endif()