diff --git a/CMakeLists.txt b/CMakeLists.txt index a4dcf97d9f..a767693bd9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -353,9 +353,7 @@ if(NOT ANDROID) if(NOT USE_GLES3) include(FindOpenGL) include_directories(${OPENGL_INCLUDE_DIR}) - if(NOT OPENGL_GLU_FOUND) - message(FATAL_ERROR "GLU is required but not found") - endif() + add_definitions(-DGLEW_NO_GLU) else() set(X11_FOUND 1) endif() @@ -519,6 +517,21 @@ include_directories(Source/Core/VideoUICommon/Src) add_subdirectory(Externals/Bochs_disasm) include_directories(Externals/Bochs_disasm) +# If zlib has already been found on a previous run of cmake don't check again +# as the check seems to take a long time. +if(NOT ZLIB_FOUND) + include(FindZLIB OPTIONAL) +endif() +if(ZLIB_FOUND) + set(ZLIB_FOUND 1 CACHE INTERNAL "") + message("Using shared zlib") + include_directories(${ZLIB_INCLUDE_DIRS}) +else(ZLIB_FOUND) + message("Shared zlib not found, falling back to the static library") + add_subdirectory(Externals/zlib) + include_directories(Externals/zlib) +endif(ZLIB_FOUND) + if(NOT ${CMAKE_SYSTEM_NAME} MATCHES "Darwin" AND NOT ANDROID) check_lib(LZO lzo2 lzo/lzo1x.h QUIET) endif() @@ -640,21 +653,6 @@ else() include_directories(Externals/SOIL) endif() -# If zlib has already been found on a previous run of cmake don't check again -# as the check seems to take a long time. -if(NOT ZLIB_FOUND) - include(FindZLIB OPTIONAL) -endif() -if(ZLIB_FOUND) - set(ZLIB_FOUND 1 CACHE INTERNAL "") - message("Using shared zlib") - include_directories(${ZLIB_INCLUDE_DIRS}) -else(ZLIB_FOUND) - message("Shared zlib not found, falling back to the static library") - add_subdirectory(Externals/zlib) - include_directories(Externals/zlib) -endif(ZLIB_FOUND) - if(WIN32) find_library(GLEW glew32s PATHS Externals/GLew) include_directories(Externals/GLew/include) diff --git a/Externals/zlib/CMakeLists.txt b/Externals/zlib/CMakeLists.txt index cb45d91b0e..c95e282e00 100644 --- a/Externals/zlib/CMakeLists.txt +++ b/Externals/zlib/CMakeLists.txt @@ -76,4 +76,4 @@ set(ZLIB_SRCS zutil.c ) -add_library(libz STATIC ${ZLIB_SRCS} ${ZLIB_DLL_SRCS} ${ZLIB_PUBLIC_HDRS} ${ZLIB_PRIVATE_HDRS}) +add_library(z STATIC ${ZLIB_SRCS} ${ZLIB_DLL_SRCS} ${ZLIB_PUBLIC_HDRS} ${ZLIB_PRIVATE_HDRS}) diff --git a/Source/Core/VideoBackends/OGL/Src/TextureCache.cpp b/Source/Core/VideoBackends/OGL/Src/TextureCache.cpp index 0666679ae9..fa3093c30d 100644 --- a/Source/Core/VideoBackends/OGL/Src/TextureCache.cpp +++ b/Source/Core/VideoBackends/OGL/Src/TextureCache.cpp @@ -69,7 +69,7 @@ bool SaveTexture(const std::string filename, u32 textarget, u32 tex, int virtual const GLenum err = GL_REPORT_ERROR(); if (GL_NO_ERROR != err) { - PanicAlert("Can't save texture, GL Error: %s", gluErrorString(err)); + PanicAlert("Can't save texture, GL Error: %d", err); delete[] data; return false; }