mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-27 23:34:57 -04:00
CMake: Update FindLibSquish.cmake, support looking in thirdparty dir
This commit is contained in:
parent
59f422c056
commit
e716dba8d4
@ -14,42 +14,62 @@
|
|||||||
# LIBSQUISH_DEBUG_LIBRARY - the filepath of the libsquish debug library
|
# LIBSQUISH_DEBUG_LIBRARY - the filepath of the libsquish debug library
|
||||||
#
|
#
|
||||||
|
|
||||||
# Find the libsquish include files
|
if(LibSquish_ROOT)
|
||||||
find_path(LIBSQUISH_INCLUDE_DIR
|
# Search exclusively under the root
|
||||||
NAMES "squish.h"
|
find_path(LIBSQUISH_INCLUDE_DIR
|
||||||
PATHS "/usr/include"
|
NAMES "squish.h"
|
||||||
"/usr/local/include"
|
PATHS ${LibSquish_ROOT}
|
||||||
"/sw/include"
|
PATH_SUFFIXES "include"
|
||||||
"/opt/include"
|
)
|
||||||
"/opt/local/include"
|
|
||||||
"/opt/csw/include"
|
|
||||||
PATH_SUFFIXES "" "cppunit"
|
|
||||||
)
|
|
||||||
|
|
||||||
# Find the libsquish library built for release
|
find_library(LIBSQUISH_RELEASE_LIBRARY
|
||||||
find_library(LIBSQUISH_RELEASE_LIBRARY
|
NAMES "squish" "libsquish"
|
||||||
NAMES "squish" "libsquish"
|
PATHS ${LibSquish_ROOT}
|
||||||
PATHS "/usr"
|
PATH_SUFFIXES "lib"
|
||||||
"/usr/local"
|
)
|
||||||
"/usr/freeware"
|
|
||||||
"/sw"
|
|
||||||
"/opt"
|
|
||||||
"/opt/csw"
|
|
||||||
PATH_SUFFIXES "lib" "lib32" "lib64"
|
|
||||||
)
|
|
||||||
|
|
||||||
# Find the libsquish library built for debug
|
find_library(LIBSQUISH_DEBUG_LIBRARY
|
||||||
find_library(LIBSQUISH_DEBUG_LIBRARY
|
NAMES "squishd" "libsquishd"
|
||||||
NAMES "squishd" "libsquishd"
|
PATHS ${LibSquish_ROOT}
|
||||||
PATHS "/usr"
|
PATH_SUFFIXES "lib"
|
||||||
"/usr/local"
|
)
|
||||||
"/usr/freeware"
|
else()
|
||||||
"/sw"
|
# Find the libsquish include files
|
||||||
"/opt"
|
find_path(LIBSQUISH_INCLUDE_DIR
|
||||||
"/opt/csw"
|
NAMES "squish.h"
|
||||||
PATH_SUFFIXES "lib" "lib32" "lib64"
|
PATHS "/usr/include"
|
||||||
)
|
"/usr/local/include"
|
||||||
|
"/sw/include"
|
||||||
|
"/opt/include"
|
||||||
|
"/opt/local/include"
|
||||||
|
"/opt/csw/include"
|
||||||
|
PATH_SUFFIXES "" "cppunit"
|
||||||
|
)
|
||||||
|
|
||||||
|
# Find the libsquish library built for release
|
||||||
|
find_library(LIBSQUISH_RELEASE_LIBRARY
|
||||||
|
NAMES "squish" "libsquish"
|
||||||
|
PATHS "/usr"
|
||||||
|
"/usr/local"
|
||||||
|
"/usr/freeware"
|
||||||
|
"/sw"
|
||||||
|
"/opt"
|
||||||
|
"/opt/csw"
|
||||||
|
PATH_SUFFIXES "lib" "lib32" "lib64"
|
||||||
|
)
|
||||||
|
|
||||||
|
# Find the libsquish library built for debug
|
||||||
|
find_library(LIBSQUISH_DEBUG_LIBRARY
|
||||||
|
NAMES "squishd" "libsquishd"
|
||||||
|
PATHS "/usr"
|
||||||
|
"/usr/local"
|
||||||
|
"/usr/freeware"
|
||||||
|
"/sw"
|
||||||
|
"/opt"
|
||||||
|
"/opt/csw"
|
||||||
|
PATH_SUFFIXES "lib" "lib32" "lib64"
|
||||||
|
)
|
||||||
|
endif()
|
||||||
|
|
||||||
mark_as_advanced(LIBSQUISH_INCLUDE_DIR)
|
mark_as_advanced(LIBSQUISH_INCLUDE_DIR)
|
||||||
mark_as_advanced(LIBSQUISH_RELEASE_LIBRARY)
|
mark_as_advanced(LIBSQUISH_RELEASE_LIBRARY)
|
||||||
|
@ -397,7 +397,7 @@ package_option(OpenEXR "Enable support for loading .exr images.")
|
|||||||
package_status(OpenEXR "OpenEXR")
|
package_status(OpenEXR "OpenEXR")
|
||||||
|
|
||||||
# libsquish
|
# libsquish
|
||||||
find_package(LibSquish QUIET)
|
find_package(LibSquish QUIET MODULE)
|
||||||
|
|
||||||
package_option(SQUISH
|
package_option(SQUISH
|
||||||
"Enables support for automatic compression of DXT textures."
|
"Enables support for automatic compression of DXT textures."
|
||||||
|
Loading…
x
Reference in New Issue
Block a user