Browse Source

CMake: Migrate FreeType package detection

Sam Edwards 7 years ago
parent
commit
17d56279f5
2 changed files with 11 additions and 9 deletions
  1. 0 6
      dtool/LocalSetup.cmake
  2. 11 3
      dtool/Package.cmake

+ 0 - 6
dtool/LocalSetup.cmake

@@ -207,12 +207,6 @@ else()
   message("- Did not find gtk+-2")
   message("- Did not find gtk+-2")
 endif()
 endif()
 
 
-if(HAVE_FREETYPE)
-  message("+ Freetype")
-else()
-  message("- Did not find Freetype")
-endif()
-
 if(HAVE_WX)
 if(HAVE_WX)
   message("+ WxWidgets")
   message("+ WxWidgets")
 else()
 else()

+ 11 - 3
dtool/Package.cmake

@@ -205,10 +205,18 @@ package_option(OPENAL
   LICENSE "LGPL")
   LICENSE "LGPL")
 config_package(OPENAL "OpenAL sound library")
 config_package(OPENAL "OpenAL sound library")
 
 
-# Find and configure Freetype
+
+#
+# ------------ FreeType ------------
+#
+
 find_package(Freetype QUIET)
 find_package(Freetype QUIET)
-#config_package(FREETYPE "Freetype")
-package_option(FREETYPE)
+
+package_option(FREETYPE
+  "This enables support for the FreeType font-rendering library. If disabled,
+  Panda3D will only be able to read fonts specially made with egg-mkfont.")
+
+config_package(FREETYPE "FreeType")
 
 
 # Find and configure GTK
 # Find and configure GTK
 set(Freetype_FIND_QUIETLY TRUE) # Fix for builtin FindGTK2
 set(Freetype_FIND_QUIETLY TRUE) # Fix for builtin FindGTK2