cmake/gsdx: check png++ is installed to support png image

Otherwise fallback to bmp file
This commit is contained in:
Gregory Hainaut 2015-05-11 11:32:13 +02:00
parent 797e3d81da
commit 286fe4db8c
3 changed files with 6 additions and 1 deletions

View File

@ -72,6 +72,7 @@ endif()
check_lib(EGL EGL EGL/egl.h) check_lib(EGL EGL EGL/egl.h)
check_lib(PORTAUDIO portaudio portaudio.h pa_linux_alsa.h) check_lib(PORTAUDIO portaudio portaudio.h pa_linux_alsa.h)
check_lib(SOUNDTOUCH SoundTouch soundtouch/SoundTouch.h) check_lib(SOUNDTOUCH SoundTouch soundtouch/SoundTouch.h)
check_lib(PNGPP FALSE png++/png.hpp)
if(SDL2_API) if(SDL2_API)
check_lib(SDL2 SDL2 SDL.h PATH_SUFFIXES SDL2) check_lib(SDL2 SDL2 SDL.h PATH_SUFFIXES SDL2)

View File

@ -38,6 +38,10 @@ if(XDG_STD)
set(GSdxFinalFlags ${GSdxFinalFlags} -DXDG_STD) set(GSdxFinalFlags ${GSdxFinalFlags} -DXDG_STD)
endif() endif()
if(PNGPP_FOUND)
set(GSdxFinalFlags ${GSdxFinalFlags} -DPNGPP_SUPPORTED)
endif()
#Clang doesn't support a few common flags that GCC does. #Clang doesn't support a few common flags that GCC does.
if(NOT USE_CLANG) if(NOT USE_CLANG)
set(GSdxFinalFlags ${GSdxFinalFlags} -fabi-version=6) set(GSdxFinalFlags ${GSdxFinalFlags} -fabi-version=6)

View File

@ -49,7 +49,7 @@
//#define ENABLE_OPENCL //#define ENABLE_OPENCL
#endif #endif
#if defined(ENABLE_OGL_DEBUG) && defined(__linux__) #if defined(ENABLE_OGL_DEBUG) && defined(__linux__) && defined(PNGPP_SUPPORTED)
// Allow to dump texture as PNG (require libpng++). It reduces the size of the dump // Allow to dump texture as PNG (require libpng++). It reduces the size of the dump
// and alpha is well supported (on linux) // and alpha is well supported (on linux)
#define ENABLE_OGL_PNG #define ENABLE_OGL_PNG