forked from bartvdbraak/blender
Cleanup: cmake
This commit is contained in:
parent
284726baec
commit
9ebe44bc9c
@ -354,7 +354,7 @@ mark_as_advanced(
|
|||||||
WITH_GL_PROFILE_ES20
|
WITH_GL_PROFILE_ES20
|
||||||
)
|
)
|
||||||
|
|
||||||
if (WITH_GL_PROFILE_COMPAT)
|
if(WITH_GL_PROFILE_COMPAT)
|
||||||
set(WITH_GLU ON)
|
set(WITH_GLU ON)
|
||||||
else()
|
else()
|
||||||
set(WITH_GLU OFF)
|
set(WITH_GLU OFF)
|
||||||
@ -378,14 +378,14 @@ endif()
|
|||||||
|
|
||||||
# By default we want to install to the directory we are compiling our executables
|
# By default we want to install to the directory we are compiling our executables
|
||||||
# unless specified otherwise, which we currently do not allow
|
# unless specified otherwise, which we currently do not allow
|
||||||
IF(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
|
if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
|
||||||
if(MSVC)
|
if(MSVC)
|
||||||
set(CMAKE_INSTALL_PREFIX ${EXECUTABLE_OUTPUT_PATH}/\${BUILD_TYPE} CACHE PATH "default install path" FORCE )
|
set(CMAKE_INSTALL_PREFIX ${EXECUTABLE_OUTPUT_PATH}/\${BUILD_TYPE} CACHE PATH "default install path" FORCE)
|
||||||
elseif(APPLE)
|
elseif(APPLE)
|
||||||
set(CMAKE_INSTALL_PREFIX ${EXECUTABLE_OUTPUT_PATH}/\${BUILD_TYPE} CACHE PATH "default install path" FORCE )
|
set(CMAKE_INSTALL_PREFIX ${EXECUTABLE_OUTPUT_PATH}/\${BUILD_TYPE} CACHE PATH "default install path" FORCE)
|
||||||
else()
|
else()
|
||||||
if (WITH_INSTALL_PORTABLE)
|
if(WITH_INSTALL_PORTABLE)
|
||||||
set(CMAKE_INSTALL_PREFIX ${EXECUTABLE_OUTPUT_PATH} CACHE PATH "default install path" FORCE )
|
set(CMAKE_INSTALL_PREFIX ${EXECUTABLE_OUTPUT_PATH} CACHE PATH "default install path" FORCE)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
@ -1154,12 +1154,12 @@ elseif(WIN32)
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Add each of our libraries to our cmake_prefix_path so find_package() could work
|
# Add each of our libraries to our cmake_prefix_path so find_package() could work
|
||||||
FILE(GLOB children RELATIVE ${LIBDIR} ${LIBDIR}/*)
|
file(GLOB children RELATIVE ${LIBDIR} ${LIBDIR}/*)
|
||||||
FOREACH(child ${children})
|
foreach(child ${children})
|
||||||
IF(IS_DIRECTORY ${LIBDIR}/${child})
|
if(IS_DIRECTORY ${LIBDIR}/${child})
|
||||||
LIST(APPEND CMAKE_PREFIX_PATH ${LIBDIR}/${child})
|
list(APPEND CMAKE_PREFIX_PATH ${LIBDIR}/${child})
|
||||||
ENDIF()
|
endif()
|
||||||
ENDFOREACH()
|
endforeach()
|
||||||
|
|
||||||
set(ZLIB_INCLUDE_DIRS ${LIBDIR}/zlib/include)
|
set(ZLIB_INCLUDE_DIRS ${LIBDIR}/zlib/include)
|
||||||
set(ZLIB_LIBRARIES ${LIBDIR}/zlib/lib/libz_st.lib)
|
set(ZLIB_LIBRARIES ${LIBDIR}/zlib/lib/libz_st.lib)
|
||||||
@ -1329,7 +1329,7 @@ elseif(WIN32)
|
|||||||
set(Boost_USE_MULTITHREADED ON) # suffix -mt
|
set(Boost_USE_MULTITHREADED ON) # suffix -mt
|
||||||
set(Boost_USE_STATIC_LIBS ON) # suffix -s
|
set(Boost_USE_STATIC_LIBS ON) # suffix -s
|
||||||
find_package(Boost COMPONENTS date_time filesystem thread regex system ${boost_extra_libs})
|
find_package(Boost COMPONENTS date_time filesystem thread regex system ${boost_extra_libs})
|
||||||
IF(NOT Boost_FOUND)
|
if(NOT Boost_FOUND)
|
||||||
message(WARNING "USING HARDCODED boost locations")
|
message(WARNING "USING HARDCODED boost locations")
|
||||||
set(BOOST ${LIBDIR}/boost)
|
set(BOOST ${LIBDIR}/boost)
|
||||||
set(BOOST_INCLUDE_DIR ${BOOST}/include)
|
set(BOOST_INCLUDE_DIR ${BOOST}/include)
|
||||||
@ -2170,7 +2170,7 @@ elseif(WITH_GL_PROFILE_ES20)
|
|||||||
|
|
||||||
list(APPEND BLENDER_GL_LIBRARIES "${OPENGLES_LIBRARY}")
|
list(APPEND BLENDER_GL_LIBRARIES "${OPENGLES_LIBRARY}")
|
||||||
|
|
||||||
if (NOT OPENGLES_LIBRARY)
|
if(NOT OPENGLES_LIBRARY)
|
||||||
message(FATAL_ERROR "To compile WITH_GL_EGL you need to set OPENGLES_LIBRARY to the file path of an OpenGL ES 2.0 library.")
|
message(FATAL_ERROR "To compile WITH_GL_EGL you need to set OPENGLES_LIBRARY to the file path of an OpenGL ES 2.0 library.")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@ -2196,7 +2196,7 @@ elseif(WITH_GL_PROFILE_ES20)
|
|||||||
|
|
||||||
mark_as_advanced(D3DCOMPILER_DLL)
|
mark_as_advanced(D3DCOMPILER_DLL)
|
||||||
|
|
||||||
if (D3DCOMPILER_DLL STREQUAL "")
|
if(D3DCOMPILER_DLL STREQUAL "")
|
||||||
message(FATAL_ERROR "To compile WITH_GL_ANGLE you need to set D3DCOMPILER_DLL to the file path of a copy of the DirectX redistributable DLL file: D3DCompiler_46.dll")
|
message(FATAL_ERROR "To compile WITH_GL_ANGLE you need to set D3DCOMPILER_DLL to the file path of a copy of the DirectX redistributable DLL file: D3DCompiler_46.dll")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
@ -2222,7 +2222,7 @@ if(WITH_GL_EGL)
|
|||||||
|
|
||||||
list(APPEND BLENDER_GL_LIBRARIES "${OPENGLES_LIBRARY}" "${OPENGLES_EGL_LIBRARY}")
|
list(APPEND BLENDER_GL_LIBRARIES "${OPENGLES_LIBRARY}" "${OPENGLES_EGL_LIBRARY}")
|
||||||
|
|
||||||
if (NOT OPENGLES_EGL_LIBRARY)
|
if(NOT OPENGLES_EGL_LIBRARY)
|
||||||
message(FATAL_ERROR "To compile WITH_GL_EGL you need to set OPENGLES_EGL_LIBRARY to the file path of an EGL library.")
|
message(FATAL_ERROR "To compile WITH_GL_EGL you need to set OPENGLES_EGL_LIBRARY to the file path of an EGL library.")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
@ -152,7 +152,7 @@ elseif(APPLE AND NOT WITH_X11)
|
|||||||
intern/GHOST_WindowCocoa.h
|
intern/GHOST_WindowCocoa.h
|
||||||
)
|
)
|
||||||
|
|
||||||
if (NOT WITH_GL_EGL)
|
if(NOT WITH_GL_EGL)
|
||||||
list(APPEND SRC
|
list(APPEND SRC
|
||||||
intern/GHOST_ContextCGL.mm
|
intern/GHOST_ContextCGL.mm
|
||||||
|
|
||||||
@ -192,7 +192,7 @@ elseif(WITH_X11)
|
|||||||
intern/GHOST_WindowX11.h
|
intern/GHOST_WindowX11.h
|
||||||
)
|
)
|
||||||
|
|
||||||
if (NOT WITH_GL_EGL)
|
if(NOT WITH_GL_EGL)
|
||||||
list(APPEND SRC
|
list(APPEND SRC
|
||||||
intern/GHOST_ContextGLX.cpp
|
intern/GHOST_ContextGLX.cpp
|
||||||
|
|
||||||
@ -272,7 +272,7 @@ elseif(WIN32)
|
|||||||
intern/GHOST_TaskbarWin32.h
|
intern/GHOST_TaskbarWin32.h
|
||||||
)
|
)
|
||||||
|
|
||||||
if (NOT WITH_GL_EGL)
|
if(NOT WITH_GL_EGL)
|
||||||
list(APPEND SRC
|
list(APPEND SRC
|
||||||
intern/GHOST_ContextWGL.cpp
|
intern/GHOST_ContextWGL.cpp
|
||||||
|
|
||||||
|
@ -38,7 +38,9 @@ set(SRC
|
|||||||
|
|
||||||
if(APPLE)
|
if(APPLE)
|
||||||
# Cocoa code to read the locale on OSX
|
# Cocoa code to read the locale on OSX
|
||||||
list(APPEND SRC osx_user_locale.mm)
|
list(APPEND SRC
|
||||||
|
osx_user_locale.mm
|
||||||
|
)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(WITH_HEADLESS)
|
if(WITH_HEADLESS)
|
||||||
|
Loading…
Reference in New Issue
Block a user