mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-25 07:35:38 +00:00
Improve CMake file and FindOpenGLES script
CMake should now add proper library files and paths to the build files. FindOpenGLES.cmake should now hopefully find GLES on Raspberry Pi.
This commit is contained in:
parent
fb1e2d8595
commit
1d9cee83a5
5
.gitignore
vendored
5
.gitignore
vendored
|
@ -19,3 +19,8 @@ emulationstation
|
||||||
|
|
||||||
#build directory
|
#build directory
|
||||||
EmulationStation_vs2010
|
EmulationStation_vs2010
|
||||||
|
build
|
||||||
|
Debug
|
||||||
|
Release
|
||||||
|
MinSizeRel
|
||||||
|
RelWithDebInfo
|
|
@ -24,12 +24,11 @@ IF (WIN32)
|
||||||
|
|
||||||
ELSE (CYGWIN)
|
ELSE (CYGWIN)
|
||||||
|
|
||||||
IF(BORLAND)
|
IF(MSVC)
|
||||||
|
#The user hast to provide this atm. GLES can be emulated via Desktop OpenGL
|
||||||
|
#using the ANGLE project found at: http://code.google.com/p/angleproject/
|
||||||
SET (OPENGLES_gl_LIBRARY import32 CACHE STRING "OpenGL ES 1.x library for win32")
|
SET (OPENGLES_gl_LIBRARY import32 CACHE STRING "OpenGL ES 1.x library for win32")
|
||||||
ELSE(BORLAND)
|
ENDIF(MSVC)
|
||||||
#MS compiler - todo - fix the following line:
|
|
||||||
SET (OPENGLES_gl_LIBRARY ${OGRE_SOURCE_DIR}/Dependencies/lib/release/libgles_cm.lib CACHE STRING "OpenGL ES 1.x library for win32")
|
|
||||||
ENDIF(BORLAND)
|
|
||||||
|
|
||||||
ENDIF (CYGWIN)
|
ENDIF (CYGWIN)
|
||||||
|
|
||||||
|
@ -47,6 +46,7 @@ ELSE (WIN32)
|
||||||
/usr/openwin/share/include
|
/usr/openwin/share/include
|
||||||
/opt/graphics/OpenGL/include /usr/X11R6/include
|
/opt/graphics/OpenGL/include /usr/X11R6/include
|
||||||
/usr/include
|
/usr/include
|
||||||
|
/opt/vc/include
|
||||||
)
|
)
|
||||||
|
|
||||||
FIND_LIBRARY(OPENGLES_gl_LIBRARY
|
FIND_LIBRARY(OPENGLES_gl_LIBRARY
|
||||||
|
@ -55,6 +55,7 @@ ELSE (WIN32)
|
||||||
/usr/openwin/lib
|
/usr/openwin/lib
|
||||||
/usr/shlib /usr/X11R6/lib
|
/usr/shlib /usr/X11R6/lib
|
||||||
/usr/lib
|
/usr/lib
|
||||||
|
/opt/vc/lib
|
||||||
)
|
)
|
||||||
|
|
||||||
# On Unix OpenGL most certainly always requires X11.
|
# On Unix OpenGL most certainly always requires X11.
|
||||||
|
|
|
@ -164,19 +164,29 @@ endif()
|
||||||
|
|
||||||
#-------------------------------------------------------------------------------
|
#-------------------------------------------------------------------------------
|
||||||
#define libraries and directories
|
#define libraries and directories
|
||||||
|
if(DEFINED BCMHOST)
|
||||||
|
link_directories(
|
||||||
|
${Boost_LIBRARY_DIRS}
|
||||||
|
"/opt/vc/lib"
|
||||||
|
)
|
||||||
|
else()
|
||||||
|
link_directories(
|
||||||
|
${Boost_LIBRARY_DIRS}
|
||||||
|
)
|
||||||
|
endif()
|
||||||
|
|
||||||
set(ES_LIBRARIES
|
set(ES_LIBRARIES
|
||||||
freetype
|
${Boost_LIBRARIES}
|
||||||
freeimage
|
${FREETYPE_LIBRARIES}
|
||||||
SDL
|
${FreeImage_LIBRARIES}
|
||||||
boost_filesystem
|
${SDL_LIBRARY}
|
||||||
boost_system
|
${SDLMAIN_LIBRARY}
|
||||||
)
|
)
|
||||||
|
|
||||||
if(DEFINED BCMHOST)
|
if(DEFINED BCMHOST)
|
||||||
LIST(APPEND ES_LIBRARIES
|
LIST(APPEND ES_LIBRARIES
|
||||||
bcm_host
|
bcm_host
|
||||||
EGL
|
EGL
|
||||||
GLESv1_CM
|
|
||||||
)
|
)
|
||||||
else()
|
else()
|
||||||
if(${GLSystem} MATCHES "Desktop OpenGL")
|
if(${GLSystem} MATCHES "Desktop OpenGL")
|
||||||
|
@ -190,10 +200,6 @@ else()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(DEFINED BCMHOST)
|
|
||||||
LINK_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR} "/opt/vc/lib")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
#-------------------------------------------------------------------------------
|
#-------------------------------------------------------------------------------
|
||||||
#set up build directories
|
#set up build directories
|
||||||
set(dir ${CMAKE_CURRENT_SOURCE_DIR})
|
set(dir ${CMAKE_CURRENT_SOURCE_DIR})
|
||||||
|
|
Loading…
Reference in a new issue